Class: Peach::App::Request

Inherits:
Object
  • Object
show all
Defined in:
lib/peach/app/request.rb

Overview

:nodoc:

Constant Summary collapse

APP_EXECUTION_TYPES =
{
  init: 'app_execution.init',
  in_progress: 'app_execution.in_progress'
}.freeze

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(raw_params) ⇒ Request

Returns a new instance of Request.



15
16
17
18
19
# File 'lib/peach/app/request.rb', line 15

def initialize(raw_params)
  params = parse_params raw_params
  validate_params params
  instantiate_instance_variables_from params
end

Instance Attribute Details

#contactObject (readonly)

Returns the value of attribute contact.



8
9
10
# File 'lib/peach/app/request.rb', line 8

def contact
  @contact
end

#contextObject (readonly)

Returns the value of attribute context.



8
9
10
# File 'lib/peach/app/request.rb', line 8

def context
  @context
end

#current_screenObject (readonly)

Returns the value of attribute current_screen.



8
9
10
# File 'lib/peach/app/request.rb', line 8

def current_screen
  @current_screen
end

#paramsObject (readonly)

Returns the value of attribute params.



8
9
10
# File 'lib/peach/app/request.rb', line 8

def params
  @params
end

Instance Method Details

#in_progress?Boolean

Returns:

  • (Boolean)


25
26
27
# File 'lib/peach/app/request.rb', line 25

def in_progress?
  in_progress_request? @type
end

#init?Boolean

Returns:

  • (Boolean)


21
22
23
# File 'lib/peach/app/request.rb', line 21

def init?
  init_request? @type
end