Class: ExtendedProfileBirthday

Inherits:
Object
  • Object
show all
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

YEAR =
1
YEARPRIVACYLEVELTYPE =
2
YEARENABLED =
3
DAY =
5
DAYPRIVACYLEVELTYPE =
6
DAYENABLED =
7
FIELDS =
{
  YEAR => {:type => ::Thrift::Types::STRING, :name => 'year'},
  YEARPRIVACYLEVELTYPE => {:type => ::Thrift::Types::I32, :name => 'yearPrivacyLevelType', :enum_class => ::P0_a_e_a_b_xe},
  YEARENABLED => {:type => ::Thrift::Types::BOOL, :name => 'yearEnabled'},
  DAY => {:type => ::Thrift::Types::STRING, :name => 'day'},
  DAYPRIVACYLEVELTYPE => {:type => ::Thrift::Types::I32, :name => 'dayPrivacyLevelType', :enum_class => ::P0_a_e_a_b_xe},
  DAYENABLED => {:type => ::Thrift::Types::BOOL, :name => 'dayEnabled'}
}

Instance Method Summary collapse

Instance Method Details

#struct_fieldsObject



15376
# File 'lib/linerb/gen-rb/takagi_chan_types.rb', line 15376

def struct_fields; FIELDS; end

#validateObject



15378
15379
15380
15381
15382
15383
15384
15385
# File 'lib/linerb/gen-rb/takagi_chan_types.rb', line 15378

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