Class: RubyCurses::TableModelEvent

Inherits:
Object
  • Object
show all
Defined in:
lib/rbcurse/rtable.rb

Overview

When an event is fired by TableModel, contents are changed, then this object will be passed to trigger type is :INSERT :UPDATE :DELETE :HEADER_ROW columns: number or :ALL_COLUMNS

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(firstrow, lastrow, column, source, type) ⇒ TableModelEvent

Returns a new instance of TableModelEvent.



1592
1593
1594
1595
1596
1597
1598
# File 'lib/rbcurse/rtable.rb', line 1592

def initialize firstrow, lastrow, column, source, type
  @firstrow = firstrow
  @lastrow = lastrow
  @column = column
  @source = source
  @type = type
end

Instance Attribute Details

#columnObject

Returns the value of attribute column.



1591
1592
1593
# File 'lib/rbcurse/rtable.rb', line 1591

def column
  @column
end

#firstrowObject

Returns the value of attribute firstrow.



1591
1592
1593
# File 'lib/rbcurse/rtable.rb', line 1591

def firstrow
  @firstrow
end

#lastrowObject

Returns the value of attribute lastrow.



1591
1592
1593
# File 'lib/rbcurse/rtable.rb', line 1591

def lastrow
  @lastrow
end

#sourceObject

Returns the value of attribute source.



1591
1592
1593
# File 'lib/rbcurse/rtable.rb', line 1591

def source
  @source
end

#typeObject

Returns the value of attribute type.



1591
1592
1593
# File 'lib/rbcurse/rtable.rb', line 1591

def type
  @type
end

Instance Method Details

#inspectObject



1602
1603
1604
# File 'lib/rbcurse/rtable.rb', line 1602

def inspect
  to_s
end

#to_sObject



1599
1600
1601
# File 'lib/rbcurse/rtable.rb', line 1599

def to_s
  "#{@type.to_s}, firstrow: #{@firstrow}, lastrow: #{@lastrow}, column: #{@column}, source: #{@source}"
end