Class: Hive2::Thrift::TTypeQualifierValue

Inherits:
Thrift::Union
  • Object
show all
Includes:
Thrift::Struct_Union
Defined in:
lib/thrift/t_c_l_i_service_types.rb

Constant Summary collapse

I32VALUE =
1
STRINGVALUE =
2
FIELDS =
{
  I32VALUE => {:type => ::Thrift::Types::I32, :name => 'i32Value', :optional => true},
  STRINGVALUE => {:type => ::Thrift::Types::STRING, :name => 'stringValue', :optional => true}
}

Class Method Summary collapse

Instance Method Summary collapse

Class Method Details

.i32Value(val) ⇒ Object


151
152
153
# File 'lib/thrift/t_c_l_i_service_types.rb', line 151

def i32Value(val)
  TTypeQualifierValue.new(:i32Value, val)
end

.stringValue(val) ⇒ Object


155
156
157
# File 'lib/thrift/t_c_l_i_service_types.rb', line 155

def stringValue(val)
  TTypeQualifierValue.new(:stringValue, val)
end

Instance Method Details

#struct_fieldsObject


168
# File 'lib/thrift/t_c_l_i_service_types.rb', line 168

def struct_fields; FIELDS; end

#validateObject

Raises:

  • (StandardError)

170
171
172
# File 'lib/thrift/t_c_l_i_service_types.rb', line 170

def validate
  raise(StandardError, 'Union fields are not set.') if get_set_field.nil? || get_value.nil?
end