2026-01-26 22:52:56 +08:00
|
|
|
{%- for benum in payload.iter_enums() %}
|
|
|
|
|
{%- if benum.get_enum_comment() is not none %}
|
2026-01-27 16:38:29 +08:00
|
|
|
{{ benum.get_enum_comment() | block_comment('/// ') }}
|
2026-02-11 22:49:54 +08:00
|
|
|
{%- endif %} {%- if benum.is_flag() %}
|
2026-01-27 17:23:58 +08:00
|
|
|
[Flags]{%- endif %}
|
2026-02-11 22:49:54 +08:00
|
|
|
public enum {{ benum.get_enum_name() }} : {% if benum.is_unsigned() -%} uint {%- else -%} int {%- endif %} {
|
2026-01-26 22:52:56 +08:00
|
|
|
{%- for entry in benum.iter_entries() %}
|
2026-02-06 10:21:23 +08:00
|
|
|
{%- if entry.get_entry_comment() is not none %}
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// {{ entry.get_entry_comment() | line_comment }}
|
|
|
|
|
/// </summary>
|
|
|
|
|
{%- endif %}
|
|
|
|
|
{{ entry.get_entry_name() }} {%- if entry.get_entry_value() is not none %} = {{ utils.to_cs_num_literal(entry.get_entry_value()) }} {%- endif %},
|
2026-01-26 22:52:56 +08:00
|
|
|
{%- endfor %}
|
|
|
|
|
};
|
|
|
|
|
{%- endfor %}
|