Class: Android::Resource::ResTableConfig

Inherits:
Chunk
  • Object
show all
Defined in:
lib/android/resource.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from Chunk

#current_position, #exec_parse, #initialize, #read_int16, #read_int32, #read_int8

Constructor Details

This class inherits a constructor from Android::Resource::Chunk

Instance Attribute Details

#imeiObject (readonly)

Returns the value of attribute imei.



344
345
346
# File 'lib/android/resource.rb', line 344

def imei
  @imei
end

#inputObject (readonly)

Returns the value of attribute input.



344
345
346
# File 'lib/android/resource.rb', line 344

def input
  @input
end

#locale_contryObject (readonly)

Returns the value of attribute locale_contry.



344
345
346
# File 'lib/android/resource.rb', line 344

def locale_contry
  @locale_contry
end

#locale_langObject (readonly)

Returns the value of attribute locale_lang.



344
345
346
# File 'lib/android/resource.rb', line 344

def locale_lang
  @locale_lang
end

#screen_configObject (readonly)

Returns the value of attribute screen_config.



345
346
347
# File 'lib/android/resource.rb', line 345

def screen_config
  @screen_config
end

#screen_inputObject (readonly)

Returns the value of attribute screen_input.



345
346
347
# File 'lib/android/resource.rb', line 345

def screen_input
  @screen_input
end

#sizeObject (readonly)

Returns the value of attribute size.



344
345
346
# File 'lib/android/resource.rb', line 344

def size
  @size
end

#versionObject (readonly)

Returns the value of attribute version.



345
346
347
# File 'lib/android/resource.rb', line 345

def version
  @version
end

Instance Method Details

#inspectObject



359
360
361
# File 'lib/android/resource.rb', line 359

def inspect
  "<ResTableConfig size:#{@size}, imei:#{@imei}, la:'#{@locale_lang}' cn:'#{@locale_contry}'"
end

#parseObject



346
347
348
349
350
351
352
353
354
355
356
357
358
# File 'lib/android/resource.rb', line 346

def parse
  @size = read_int32
  @imei = read_int32
  la = @data_io.read(2)
  @locale_lang = la unless la == "\x00\x00"
  cn = @data_io.read(2)
  @locale_contry = cn unless cn == "\x00\x00"
  @screen_type = read_int32
  @input = read_int32
  @screen_input = read_int32
  @version = read_int32
  @screen_config = read_int32
end