Class: Google::Apis::DatamigrationV1::TriggerEntity

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
lib/google/apis/datamigration_v1/classes.rb,
lib/google/apis/datamigration_v1/representations.rb,
lib/google/apis/datamigration_v1/representations.rb

Overview

Trigger is not used as an independent entity, it is retrieved as part of a Table entity.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ TriggerEntity

Returns a new instance of TriggerEntity.



4747
4748
4749
# File 'lib/google/apis/datamigration_v1/classes.rb', line 4747

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#custom_featuresHash<String,Object>

Custom engine specific features. Corresponds to the JSON property customFeatures

Returns:

  • (Hash<String,Object>)


4724
4725
4726
# File 'lib/google/apis/datamigration_v1/classes.rb', line 4724

def custom_features
  @custom_features
end

#nameString

The name of the trigger. Corresponds to the JSON property name

Returns:

  • (String)


4729
4730
4731
# File 'lib/google/apis/datamigration_v1/classes.rb', line 4729

def name
  @name
end

#sql_codeString

The SQL code which creates the trigger. Corresponds to the JSON property sqlCode

Returns:

  • (String)


4734
4735
4736
# File 'lib/google/apis/datamigration_v1/classes.rb', line 4734

def sql_code
  @sql_code
end

#trigger_typeString

Indicates when the trigger fires, for example BEFORE STATEMENT, AFTER EACH ROW. Corresponds to the JSON property triggerType

Returns:

  • (String)


4739
4740
4741
# File 'lib/google/apis/datamigration_v1/classes.rb', line 4739

def trigger_type
  @trigger_type
end

#triggering_eventsArray<String>

The DML, DDL, or database events that fire the trigger, for example INSERT, UPDATE. Corresponds to the JSON property triggeringEvents

Returns:

  • (Array<String>)


4745
4746
4747
# File 'lib/google/apis/datamigration_v1/classes.rb', line 4745

def triggering_events
  @triggering_events
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



4752
4753
4754
4755
4756
4757
4758
# File 'lib/google/apis/datamigration_v1/classes.rb', line 4752

def update!(**args)
  @custom_features = args[:custom_features] if args.key?(:custom_features)
  @name = args[:name] if args.key?(:name)
  @sql_code = args[:sql_code] if args.key?(:sql_code)
  @trigger_type = args[:trigger_type] if args.key?(:trigger_type)
  @triggering_events = args[:triggering_events] if args.key?(:triggering_events)
end