Class: CadenceThrift::DecisionTaskFailedEventAttributes

Inherits:
Object
  • Object
show all
Includes:
Thrift::Struct, Thrift::Struct_Union
Defined in:
lib/gen/thrift/shared_types.rb,
lib/gen/thrift/shared_types.rb

Constant Summary collapse

SCHEDULEDEVENTID =
10
STARTEDEVENTID =
20
CAUSE =
30
DETAILS =
35
IDENTITY =
40
REASON =
50
BASERUNID =
60
NEWRUNID =
70
FORKEVENTVERSION =
80
FIELDS =
{
  SCHEDULEDEVENTID => {:type => ::Thrift::Types::I64, :name => 'scheduledEventId', :optional => true},
  STARTEDEVENTID => {:type => ::Thrift::Types::I64, :name => 'startedEventId', :optional => true},
  CAUSE => {:type => ::Thrift::Types::I32, :name => 'cause', :optional => true, :enum_class => ::CadenceThrift::DecisionTaskFailedCause},
  DETAILS => {:type => ::Thrift::Types::STRING, :name => 'details', :binary => true, :optional => true},
  IDENTITY => {:type => ::Thrift::Types::STRING, :name => 'identity', :optional => true},
  REASON => {:type => ::Thrift::Types::STRING, :name => 'reason', :optional => true},
  BASERUNID => {:type => ::Thrift::Types::STRING, :name => 'baseRunId', :optional => true},
  NEWRUNID => {:type => ::Thrift::Types::STRING, :name => 'newRunId', :optional => true},
  FORKEVENTVERSION => {:type => ::Thrift::Types::I64, :name => 'forkEventVersion', :optional => true}
}

Instance Method Summary collapse

Instance Method Details

#struct_fieldsObject



1808
# File 'lib/gen/thrift/shared_types.rb', line 1808

def struct_fields; FIELDS; end

#validateObject



1810
1811
1812
1813
1814
# File 'lib/gen/thrift/shared_types.rb', line 1810

def validate
  unless @cause.nil? || ::CadenceThrift::DecisionTaskFailedCause::VALID_VALUES.include?(@cause)
    raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Invalid value of field cause!')
  end
end