Skip to content

struct Athena::Framework::Config::ViewHandler
inherits Struct #

Configuration options for ATH::Listeners::View. See .configure.

Constructors#

.configure : self#

This method should be overridden in order to provide configuration overrides for ATH::View::ViewHandlerInterface. See the external documentation for more details.

Note

The #failed_validation_status is currently not used. Included for future work.

def ATH::Config::ViewHandler.configure : ATH::Config::ViewHandler
  new(
    empty_content_status: :ok
  )
end
View source

.new(empty_content_status : HTTP::Status = HTTP::Status::NO_CONTENT, failed_validation_status : HTTP::Status = HTTP::Status::UNPROCESSABLE_ENTITY, emit_nil : Bool = false)#

See .configure.

View source

Methods#

#emit_nil? : Bool#

If nil values should be serialized.

View source

#empty_content_status : HTTP::Status#

The HTTP::Status used when there is no response content.

View source

#failed_validation_status : HTTP::Status#

The HTTP::Status used when validations fail.

Currently not used. Included for future work.

View source