Class: Telegram::BotManager::View

Inherits:
Object
  • Object
show all
Defined in:
lib/telegram/bot_manager/view.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(params = {}) ⇒ View

Returns a new instance of View.



9
10
11
12
13
14
15
# File 'lib/telegram/bot_manager/view.rb', line 9

def initialize(params={})
  raise 'You need to pass hash to new view' unless params.is_a?(Hash)

  @params = params
  @content = String.new
  @markup = Hash.new
end

Instance Attribute Details

#contentObject (readonly)

Returns the value of attribute content.



7
8
9
# File 'lib/telegram/bot_manager/view.rb', line 7

def content
  @content
end

#paramsObject (readonly)

Returns the value of attribute params.



7
8
9
# File 'lib/telegram/bot_manager/view.rb', line 7

def params
  @params
end