Class: AbuseReport
- Inherits:
-
Object
- Object
- AbuseReport
- Includes:
- Thrift::Struct, Thrift::Struct_Union
- Defined in:
- lib/linerb/gen-rb/takagi_chan_types.rb,
lib/linerb/gen-rb/takagi_chan_types.rb
Constant Summary collapse
- REPORTSOURCE =
1
- APPLICATIONTYPE =
2
- SPAMMERREASONS =
3
- ABUSEMESSAGES =
4
- METADATA =
5
- FIELDS =
{ REPORTSOURCE => {:type => ::Thrift::Types::I32, :name => 'reportSource', :enum_class => ::J0_a_e_a_b_pf}, APPLICATIONTYPE => {:type => ::Thrift::Types::I32, :name => 'applicationType', :enum_class => ::J0_a_e_a_b_y}, SPAMMERREASONS => {:type => ::Thrift::Types::LIST, :name => 'spammerReasons', :element => {:type => ::Thrift::Types::I32, :enum_class => ::J0_a_e_a_b_lg}}, ABUSEMESSAGES => {:type => ::Thrift::Types::LIST, :name => 'abuseMessages', :element => {:type => ::Thrift::Types::STRUCT, :class => ::AbuseMessage}}, METADATA => {:type => ::Thrift::Types::MAP, :name => 'metadata', :key => {:type => ::Thrift::Types::STRING}, :value => {:type => ::Thrift::Types::STRING}} }
Instance Method Summary collapse
Instance Method Details
#struct_fields ⇒ Object
14944 |
# File 'lib/linerb/gen-rb/takagi_chan_types.rb', line 14944 def struct_fields; FIELDS; end |
#validate ⇒ Object
14946 14947 14948 14949 14950 14951 14952 14953 |
# File 'lib/linerb/gen-rb/takagi_chan_types.rb', line 14946 def validate unless @reportSource.nil? || ::J0_a_e_a_b_pf::VALID_VALUES.include?(@reportSource) raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Invalid value of field reportSource!') end unless @applicationType.nil? || ::J0_a_e_a_b_y::VALID_VALUES.include?(@applicationType) raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Invalid value of field applicationType!') end end |