Daniel G. Taylor 6ed3b09f44 Initial commit
2019-10-05 08:47:14 -07:00

25 lines
647 B
Python

# Generated by the protocol buffer compiler. DO NOT EDIT!
# source: {{ description.filename }}
from dataclasses import dataclass
from typing import List
import betterproto
{% for message in description.messages %}
@dataclass
class {{ message.name }}(betterproto.Message):
{% if message.comment %}
{{ message.comment }}
{% endif %}
{% for field in message.properties %}
{% if field.comment %}
{{ field.comment }}
{% endif %}
{{ field.name }}: {{ field.type }} = betterproto.{{ field.field_type }}_field({{ field.number }}{% if field.zero %}, default={{ field.zero }}{% endif %})
{% endfor %}
{% endfor %}