digraph {
rankdir=LR;
node [shape=plaintext];
subgraph cluster__windows_resource_file {
label="WindowsResourceFile";
graph[style=dotted];
windows_resource_file__seq [label=<
pos | size | type | id |
0 | ... | Resource | resources |
repeat to end of stream |
>];
subgraph cluster__resource {
label="WindowsResourceFile::Resource";
graph[style=dotted];
resource__seq [label=<
pos | size | type | id |
0 | 4 | u4le | value_size |
4 | 4 | u4le | header_size |
8 | ... | UnicodeOrId | type |
... | ... | UnicodeOrId | name |
... | ((4 - _io.pos) % 4) | | padding1 |
... | 4 | u4le | format_version |
... | 2 | u2le | flags |
... | 2 | u2le | language |
... | 4 | u4le | value_version |
... | 4 | u4le | characteristics |
... | value_size | | value |
... | ((4 - _io.pos) % 4) | | padding2 |
>];
resource__inst__type_as_predef [label=<
id | value |
type_as_predef | Kaitai::Struct::Stream::resolve_enum(PREDEF_TYPES, type.as_numeric) |
>];
}
subgraph cluster__unicode_or_id {
label="WindowsResourceFile::UnicodeOrId";
graph[style=dotted];
unicode_or_id__seq [label=<
pos | size | type | id |
0 | 2 | u2le | first |
2 | 2 | u2le | as_numeric |
4 | 2 | u2le | rest |
repeat until _ == 0 |
... | 0 | | noop |
>];
unicode_or_id__inst__save_pos1 [label=<>];
unicode_or_id__inst__save_pos2 [label=<>];
unicode_or_id__inst__is_string [label=<
id | value |
is_string | first != 65535 |
>];
unicode_or_id__inst__as_string [label=<
pos | size | type | id |
save_pos1 | ((save_pos2 - save_pos1) - 2) | str(UTF-16LE) | as_string |
>];
}
}
windows_resource_file__seq:resources_type -> resource__seq [style=bold];
resource__seq:type_type -> unicode_or_id__seq [style=bold];
resource__seq:name_type -> unicode_or_id__seq [style=bold];
resource__seq:value_size_type -> resource__seq:value_size [color="#404040"];
unicode_or_id__seq:as_numeric_type -> resource__inst__type_as_predef [color="#404040"];
unicode_or_id__seq:first_type -> unicode_or_id__inst__is_string [color="#404040"];
unicode_or_id__inst__save_pos1:save_pos1_type -> unicode_or_id__inst__as_string:as_string_pos [color="#404040"];
unicode_or_id__inst__save_pos2:save_pos2_type -> unicode_or_id__inst__as_string:as_string_size [color="#404040"];
unicode_or_id__inst__save_pos1:save_pos1_type -> unicode_or_id__inst__as_string:as_string_size [color="#404040"];
}