Class: Impala::Protocol::Hive::TOpenSessionResp
- Inherits:
-
Object
- Object
- Impala::Protocol::Hive::TOpenSessionResp
- Includes:
- Thrift::Struct, Thrift::Struct_Union
- Defined in:
- lib/impala/protocol/cli_service_types.rb
Constant Summary collapse
- STATUS =
1
- SERVERPROTOCOLVERSION =
2
- SESSIONHANDLE =
3
- CONFIGURATION =
4
- FIELDS =
{ STATUS => {:type => ::Thrift::Types::STRUCT, :name => 'status', :class => ::Impala::Protocol::Hive::TStatus}, SERVERPROTOCOLVERSION => {:type => ::Thrift::Types::I32, :name => 'serverProtocolVersion', :default => 0, :enum_class => ::Impala::Protocol::Hive::TProtocolVersion}, SESSIONHANDLE => {:type => ::Thrift::Types::STRUCT, :name => 'sessionHandle', :class => ::Impala::Protocol::Hive::TSessionHandle, :optional => true}, CONFIGURATION => {:type => ::Thrift::Types::MAP, :name => 'configuration', :key => {:type => ::Thrift::Types::STRING}, :value => {:type => ::Thrift::Types::STRING}, :optional => true} }
Instance Method Summary collapse
Instance Method Details
#struct_fields ⇒ Object
760 |
# File 'lib/impala/protocol/cli_service_types.rb', line 760 def struct_fields; FIELDS; end |
#validate ⇒ Object
762 763 764 765 766 767 768 |
# File 'lib/impala/protocol/cli_service_types.rb', line 762 def validate raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field status is unset!') unless @status raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Required field serverProtocolVersion is unset!') unless @serverProtocolVersion unless @serverProtocolVersion.nil? || ::Impala::Protocol::Hive::TProtocolVersion::VALID_VALUES.include?(@serverProtocolVersion) raise ::Thrift::ProtocolException.new(::Thrift::ProtocolException::UNKNOWN, 'Invalid value of field serverProtocolVersion!') end end |