Class: Hexspace::TGetInfoValue

Inherits:
Thrift::Union
  • Object
show all
Includes:
Thrift::Struct_Union
Defined in:
lib/hexspace/tcli_service_types.rb,
lib/hexspace/tcli_service_types.rb

Constant Summary collapse

STRINGVALUE =
1
SMALLINTVALUE =
2
INTEGERBITMASK =
3
INTEGERFLAG =
4
BINARYVALUE =
5
LENVALUE =
6
FIELDS =
{
  STRINGVALUE => {:type => ::Thrift::Types::STRING, :name => 'stringValue', :optional => true},
  SMALLINTVALUE => {:type => ::Thrift::Types::I16, :name => 'smallIntValue', :optional => true},
  INTEGERBITMASK => {:type => ::Thrift::Types::I32, :name => 'integerBitmask', :optional => true},
  INTEGERFLAG => {:type => ::Thrift::Types::I32, :name => 'integerFlag', :optional => true},
  BINARYVALUE => {:type => ::Thrift::Types::I32, :name => 'binaryValue', :optional => true},
  LENVALUE => {:type => ::Thrift::Types::I64, :name => 'lenValue', :optional => true}
}

Class Method Summary collapse

Instance Method Summary collapse

Class Method Details

.binaryValue(val) ⇒ Object



1224
1225
1226
# File 'lib/hexspace/tcli_service_types.rb', line 1224

def binaryValue(val)
  TGetInfoValue.new(:binaryValue, val)
end

.integerBitmask(val) ⇒ Object



1216
1217
1218
# File 'lib/hexspace/tcli_service_types.rb', line 1216

def integerBitmask(val)
  TGetInfoValue.new(:integerBitmask, val)
end

.integerFlag(val) ⇒ Object



1220
1221
1222
# File 'lib/hexspace/tcli_service_types.rb', line 1220

def integerFlag(val)
  TGetInfoValue.new(:integerFlag, val)
end

.lenValue(val) ⇒ Object



1228
1229
1230
# File 'lib/hexspace/tcli_service_types.rb', line 1228

def lenValue(val)
  TGetInfoValue.new(:lenValue, val)
end

.smallIntValue(val) ⇒ Object



1212
1213
1214
# File 'lib/hexspace/tcli_service_types.rb', line 1212

def smallIntValue(val)
  TGetInfoValue.new(:smallIntValue, val)
end

.stringValue(val) ⇒ Object



1208
1209
1210
# File 'lib/hexspace/tcli_service_types.rb', line 1208

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

Instance Method Details

#struct_fieldsObject



1249
# File 'lib/hexspace/tcli_service_types.rb', line 1249

def struct_fields; FIELDS; end

#validateObject

Raises:

  • (StandardError)


1251
1252
1253
# File 'lib/hexspace/tcli_service_types.rb', line 1251

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