Class: Flydata::SourceMysql::QueryEvent
- Inherits:
-
Object
- Object
- Flydata::SourceMysql::QueryEvent
- Defined in:
- lib/flydata/source_mysql/table_ddl.rb
Overview
mimics RubyBinlog::QueryEvent
Instance Attribute Summary collapse
-
#database_name ⇒ Object
readonly
Returns the value of attribute database_name.
-
#event_length ⇒ Object
readonly
Returns the value of attribute event_length.
-
#event_table_name ⇒ Object
readonly
Returns the value of attribute event_table_name.
-
#event_type ⇒ Object
readonly
Returns the value of attribute event_type.
-
#next_position ⇒ Object
readonly
Returns the value of attribute next_position.
-
#query ⇒ Object
readonly
Returns the value of attribute query.
-
#timestamp ⇒ Object
readonly
Returns the value of attribute timestamp.
Instance Method Summary collapse
-
#initialize(event_type, database_name, event_table_name, next_position, event_length, query, timestamp) ⇒ QueryEvent
constructor
A new instance of QueryEvent.
- #to_s ⇒ Object
Constructor Details
#initialize(event_type, database_name, event_table_name, next_position, event_length, query, timestamp) ⇒ QueryEvent
Returns a new instance of QueryEvent.
86 87 88 89 90 91 92 93 94 95 |
# File 'lib/flydata/source_mysql/table_ddl.rb', line 86 def initialize(event_type, database_name, event_table_name, next_position, event_length, query, ) @event_type = event_type @database_name = database_name @event_table_name = event_table_name @next_position = next_position @event_length = event_length @query = query = end |
Instance Attribute Details
#database_name ⇒ Object (readonly)
Returns the value of attribute database_name.
96 97 98 |
# File 'lib/flydata/source_mysql/table_ddl.rb', line 96 def database_name @database_name end |
#event_length ⇒ Object (readonly)
Returns the value of attribute event_length.
96 97 98 |
# File 'lib/flydata/source_mysql/table_ddl.rb', line 96 def event_length @event_length end |
#event_table_name ⇒ Object (readonly)
Returns the value of attribute event_table_name.
96 97 98 |
# File 'lib/flydata/source_mysql/table_ddl.rb', line 96 def event_table_name @event_table_name end |
#event_type ⇒ Object (readonly)
Returns the value of attribute event_type.
96 97 98 |
# File 'lib/flydata/source_mysql/table_ddl.rb', line 96 def event_type @event_type end |
#next_position ⇒ Object (readonly)
Returns the value of attribute next_position.
96 97 98 |
# File 'lib/flydata/source_mysql/table_ddl.rb', line 96 def next_position @next_position end |
#query ⇒ Object (readonly)
Returns the value of attribute query.
96 97 98 |
# File 'lib/flydata/source_mysql/table_ddl.rb', line 96 def query @query end |
#timestamp ⇒ Object (readonly)
Returns the value of attribute timestamp.
96 97 98 |
# File 'lib/flydata/source_mysql/table_ddl.rb', line 96 def end |
Instance Method Details
#to_s ⇒ Object
99 100 101 102 103 |
# File 'lib/flydata/source_mysql/table_ddl.rb', line 99 def to_s "event_type;\#{event_type} database_name:\#{database_name} event_table_name:\#{event_table_name} next_position:\#{next_position} event_length:\#{event_length} timestamp:\#{timestamp} query:\#{query}\n" end |