Class: PgDiff::Trigger

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

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(table_name, name, df) ⇒ Trigger

Returns a new instance of Trigger.


5
6
7
8
9
# File 'lib/trigger.rb', line 5

def initialize(table_name, name, df)
  @table_name = table_name
  @name = name
  @definition = df + ";"
end

Instance Attribute Details

#definitionObject (readonly)

Returns the value of attribute definition.


3
4
5
# File 'lib/trigger.rb', line 3

def definition
  @definition
end

#nameObject (readonly)

Returns the value of attribute name.


3
4
5
# File 'lib/trigger.rb', line 3

def name
  @name
end

#table_nameObject (readonly)

Returns the value of attribute table_name.


3
4
5
# File 'lib/trigger.rb', line 3

def table_name
  @table_name
end

Instance Method Details

#==(other) ⇒ Object


11
12
13
# File 'lib/trigger.rb', line 11

def == (other)
  other.definition == definition
end