MCPcopy Create free account
hub / github.com/MultiMC/Launcher / read

Method read

libraries/classparser/src/annotations.cpp:22–41  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

20}
21
22annotation *annotation::read(util::membuffer &input, constant_pool &pool)
23{
24 uint16_t type_index = 0;
25 input.read_be(type_index);
26 annotation *ann = new annotation(type_index, pool);
27
28 uint16_t num_pairs = 0;
29 input.read_be(num_pairs);
30 while (num_pairs)
31 {
32 uint16_t name_idx = 0;
33 // read name index
34 input.read_be(name_idx);
35 auto elem = element_value::readElementValue(input, pool);
36 // read value
37 ann->add_pair(name_idx, elem);
38 num_pairs--;
39 }
40 return ann;
41}
42
43element_value *element_value::readElementValue(util::membuffer &input,
44 java::constant_pool &pool)

Callers 6

LegacyFrameMethod · 0.45
sendMessageMethod · 0.45
constantMethod · 0.45
GetMinecraftJarVersionFunction · 0.45
readElementValueMethod · 0.45
readFunction · 0.45

Calls 2

read_beMethod · 0.80
add_pairMethod · 0.80

Tested by

no test coverage detected