Class: ThriftSourceProtocol::Append_result

Inherits:
Object
  • Object
show all
Includes:
Thrift::Struct, Thrift::Struct_Union
Defined in:
lib/flume-logger/flume-ng/thrift_source_protocol.rb

Constant Summary collapse

SUCCESS =
0
FIELDS =
{
  SUCCESS => {:type => ::Thrift::Types::I32, :name => 'success', :enum_class => ::Status}
}

Instance Method Summary collapse

Instance Method Details

#struct_fieldsObject



91
# File 'lib/flume-logger/flume-ng/thrift_source_protocol.rb', line 91

def struct_fields; FIELDS; end

#validateObject



93
94
95
96
97
# File 'lib/flume-logger/flume-ng/thrift_source_protocol.rb', line 93

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