class

Optarg::Parser

Inherits Reference < Object

Class methods

after_validate(name, proc : Proc(Optarg::Parser, Model, Nil))

Registers a callback for the validate group.

This method is automatically defined by the Crystal Callback library.

after_validate(proc : Proc(Optarg::Parser, Model, Nil))

Registers a callback for the validate group.

This method is automatically defined by the Crystal Callback library.

after_validate(name = nil, &block : Optarg::Parser, Model -> Nil)

Registers a callback for the validate group.

This method is automatically defined by the Crystal Callback library.

around_validate(name, proc : Proc(Optarg::Parser, Model, Nil))

Registers a callback for the validate group.

This method is automatically defined by the Crystal Callback library.

around_validate(proc : Proc(Optarg::Parser, Model, Nil))

Registers a callback for the validate group.

This method is automatically defined by the Crystal Callback library.

around_validate(name = nil, &block : Optarg::Parser, Model -> Nil)

Registers a callback for the validate group.

This method is automatically defined by the Crystal Callback library.

before_validate(name, proc : Proc(Optarg::Parser, Model, Nil))

Registers a callback for the validate group.

This method is automatically defined by the Crystal Callback library.

before_validate(proc : Proc(Optarg::Parser, Model, Nil))

Registers a callback for the validate group.

This method is automatically defined by the Crystal Callback library.

before_validate(name = nil, &block : Optarg::Parser, Model -> Nil)

Registers a callback for the validate group.

This method is automatically defined by the Crystal Callback library.

on_validate(name, proc : Proc(Optarg::Parser, Model, Nil))

Registers a callback for the validate group.

This method is automatically defined by the Crystal Callback library.

on_validate(proc : Proc(Optarg::Parser, Model, Nil))

Registers a callback for the validate group.

This method is automatically defined by the Crystal Callback library.

on_validate(name = nil, &block : Optarg::Parser, Model -> Nil)

Registers a callback for the validate group.

This method is automatically defined by the Crystal Callback library.

Instance methods

after_validate(name, proc : Proc(Optarg::Parser, Model, Nil))

Registers a dynamic callback for the validate group.

This method is automatically defined by the Crystal Callback library.

after_validate(proc : Proc(Optarg::Parser, Model, Nil))

Registers a dynamic callback for the validate group.

This method is automatically defined by the Crystal Callback library.

after_validate(name = nil, &block : Optarg::Parser, Model -> Nil)

Registers a dynamic callback for the validate group.

This method is automatically defined by the Crystal Callback library.

around_validate(name, proc : Proc(Optarg::Parser, Model, Nil))

Registers a dynamic callback for the validate group.

This method is automatically defined by the Crystal Callback library.

around_validate(proc : Proc(Optarg::Parser, Model, Nil))

Registers a dynamic callback for the validate group.

This method is automatically defined by the Crystal Callback library.

around_validate(name = nil, &block : Optarg::Parser, Model -> Nil)

Registers a dynamic callback for the validate group.

This method is automatically defined by the Crystal Callback library.

before_validate(name, proc : Proc(Optarg::Parser, Model, Nil))

Registers a dynamic callback for the validate group.

This method is automatically defined by the Crystal Callback library.

before_validate(proc : Proc(Optarg::Parser, Model, Nil))

Registers a dynamic callback for the validate group.

This method is automatically defined by the Crystal Callback library.

before_validate(name = nil, &block : Optarg::Parser, Model -> Nil)

Registers a dynamic callback for the validate group.

This method is automatically defined by the Crystal Callback library.

callback_results

Returns callback results.

This method is automatically defined by the Crystal Callback library.

callback_results_for_validate

Returns callback results of the validate group.

This method is automatically defined by the Crystal Callback library.

data

Returns a target model instance.

Source
invalidate!(message : String)

Creates and raises a new ValidationError with the message.

Source
on_validate(name, proc : Proc(Optarg::Parser, Model, Nil))

Registers a dynamic callback for the validate group.

This method is automatically defined by the Crystal Callback library.

on_validate(proc : Proc(Optarg::Parser, Model, Nil))

Registers a dynamic callback for the validate group.

This method is automatically defined by the Crystal Callback library.

on_validate(name = nil, &block : Optarg::Parser, Model -> Nil)

Registers a dynamic callback for the validate group.

This method is automatically defined by the Crystal Callback library.

run_callbacks_for_validate(*args, &)

Invokes all callbacks of the validate group.

This method is automatically defined by the Crystal Callback library.

Macros

define_callback_group(name, proc_type = ::Proc(::Nil))

Defines a new callback group.

This macro is automatically defined by the Crystal Callback library.

Source
inherit_callback_group(name, proc_type = ::Proc(::Nil))

Inherits an existing callback group that is defined in its ancestor class.

This macro is automatically defined by the Crystal Callback library.

Source