Class: Naksh::Interfaces::Tab

Inherits:
Object
  • Object
show all
Defined in:
lib/naksh/interfaces/tab.rb

Constant Summary collapse

@@tabs =
Array.new

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(session = nil) ⇒ Tab

Returns a new instance of Tab.



34
35
36
37
38
39
40
41
42
# File 'lib/naksh/interfaces/tab.rb', line 34

def initialize session=nil

  @@tabs<<self

  @number  = @@tabs.length
  @session = session

  self
end

Instance Attribute Details

#numberObject (readonly)

Returns the value of attribute number.



45
46
47
# File 'lib/naksh/interfaces/tab.rb', line 45

def number
  @number
end

#sessionObject

Returns the value of attribute session.



44
45
46
# File 'lib/naksh/interfaces/tab.rb', line 44

def session
  @session
end

#textboxObject

Returns the value of attribute textbox.



45
46
47
# File 'lib/naksh/interfaces/tab.rb', line 45

def textbox
  @textbox
end

Class Method Details

.tabsObject



25
26
27
# File 'lib/naksh/interfaces/tab.rb', line 25

def Tab.tabs
  @@tabs
end

.tabs=(new_tab_set) ⇒ Object



29
30
31
# File 'lib/naksh/interfaces/tab.rb', line 29

def Tab.tabs= new_tab_set
  @@tabs=new_tab_set
end