class

CRails::OpenApiController

Inherits ActionController::Base < CRails::Routes::UrlHelpers < ActionController::ConditionalGet < ActionView::Helpers < ActionView::Helpers::RecordIdentifier < ActionView::Helpers::ViteHelper < ActionView::Helpers::CsrfHelper < ActionView::Helpers::CacheHelper < ActionView::Helpers::FormHelper < ActionView::Helpers::FormTagHelper < ActionView::Helpers::FormOptionsHelper < ActionView::Helpers::TagHelper < ActionView::Helpers::TagHelper < ActionView::Helpers::TagHelper < ActionView::Helpers::FormOptionsHelper < ActionView::Helpers::TagHelper < ActionView::Helpers::FormTagHelper < ActionView::Helpers::FormOptionsHelper < ActionView::Helpers::TagHelper < ActionView::Helpers::TagHelper < ActionView::Helpers::EmbedFileHelper < ActionView::Helpers::TagHelper < ActionView::Helpers::AssetTagHelper < ActionView::Helpers::TagHelper < ActionView::Helpers::UrlHelper < ActionView::Helpers::TagHelper < ActionView::Helpers::NumberHelper < ActiveSupport::NumberHelper < ActionView::Helpers::TextHelper < ActionView::Helpers::TagHelper < ERB::Rendering < ActionController::DataStreaming < ActionController::RequestForgeryProtection < ActionController::RateLimiting < Reference < Object

End-of-program codegen: runs after every controller class is defined.

Instance methods

__around_step_0(action : String, &)

Registered around_action filters for this controller (its own and inherited ones), run outside-in as nested blocks; each filter yields to continue the chain, the innermost block is the action itself. One generated method per step: a single recursive method would trip Crystal's "recursive block expansion" check.

Source
__jb_render_template(path : String) : String

render(template:) — .json.jbuilder этого контроллера: полный путь относительно корня вьюх с расширением или без ("posts/show.json.jbuilder" / "posts/show") либо имя экшена ("show.json.jbuilder" / "show").

Source
__jb_template?(action : String) : Bool

JSON-формат: #{action}.json.jbuilder (implicit render при format=json / Accept: application/json — см. __default_render).

Source
__render_layout
Source
__render_view(action : String, format : String = "html") : ActionView::SafeString

Render the action's ERB template with the controller as context (instance variables, params, helpers are visible). format = "html" (default) or "turbo_stream".

Source
__render_view_json(action : String) : String

Overwritten by codegen in concrete controllers.

Source
__render_view_turbo_stream(action : String) : ActionView::SafeString

Turbo-stream формат: #{action}.turbo_stream.erb без layout.

Source
__run_action(action : String) : Nil

rescue_from handlers for this controller (own + inherited).

Source
__run_action_dispatch(action : String) : Nil

Dispatch a routed action: run it, then default-render its template inside the layout unless the action already rendered. Around filters wrap the action (after before-filters, Rails order).

Source
__run_around_filters(action : String, &)
Source
__run_before_filters(action : String) : Nil

Registered before_action filters for this controller (its own and inherited ones). skip_before_action narrows the original filter to the complement of the skip's only/except/if/unless set (an unconditional skip disables it entirely) — Rails callback-skip semantics; the old code dropped the filter for ALL actions, ignoring the skip's conditions. Symbol#stringify here carries a leading ":" — normalized off.

Source
__ts_template?(action : String) : Bool

Есть ли #{action}.turbo_stream.erb: implicit render при turbo_stream-формате; иначе fallback на HTML (см. __default_render).

Source
show
Source