Method: Cosmos::StructureItem#as_json

Defined in:
lib/cosmos/packets/structure_item.rb

#as_jsonObject



304
305
306
307
308
309
310
311
312
313
314
# File 'lib/cosmos/packets/structure_item.rb', line 304

def as_json
  hash = {}
  hash['name'] = self.name
  hash['bit_offset'] = self.bit_offset
  hash['bit_size'] = self.bit_size
  hash['data_type'] = self.data_type
  hash['endianness'] = self.endianness
  hash['array_size'] = self.array_size
  hash['overflow'] = self.overflow
  hash
end