1
0
mirror of https://github.com/mastodon/mastodon-ios.git synced 2025-01-08 07:22:00 +01:00
mastodon-app-ufficiale-ipho.../MastodonSDK/Sources/CoreDataStack/Template/Stencil/AutoGenerateRelationship.stencil
2022-01-28 12:09:28 +08:00

30 lines
922 B
Plaintext

{% for type in types.implementing.AutoGenerateRelationship %}
// sourcery:inline:{{type.name}}.AutoGenerateRelationship
// Generated using Sourcery
// DO NOT EDIT
public struct Relationship {
{% for variable in type.storedVariables|annotated:"autoGenerateRelationship" %}
public let {{variable.name}}: {{variable.typeName}}
{% endfor %}
public init(
{% for variable in type.storedVariables|annotated:"autoGenerateRelationship" %}
{{variable.name}}: {{variable.typeName}}{% if not forloop.last %},{% endif %}
{% endfor %}
) {
{% for variable in type.storedVariables|annotated:"autoGenerateRelationship" %}
self.{{variable.name}} = {{variable.name}}
{% endfor %}
}
}
public func configure(relationship: Relationship) {
{% for variable in type.storedVariables|annotated:"autoGenerateRelationship" %}
self.{{variable.name}} = relationship.{{variable.name}}
{% endfor %}
}
// sourcery:end
{% endfor %}