File tree Expand file tree Collapse file tree 1 file changed +6
-6
lines changed
boat-scaffold/src/main/templates/boat-swift5 Expand file tree Collapse file tree 1 file changed +6
-6
lines changed Original file line number Diff line number Diff line change 2525{ {/allVars} }
2626
2727{ {#hasVars} }
28- { {#nonPublicApi} }internal{ {/nonPublicApi} }{ {^nonPublicApi} }public{ {/nonPublicApi} } init() {
28+ internal init({ {#allVars} }{ {name} }: { {{datatypeWithEnum} }}{ {#required} }{ {#isNullable} }? = nil{ {/isNullable} }{ {/required} }{ {^required} }? = nil{ {/required} }{ {^-last} }, { {/-last} }{ {/allVars} }) {
29+ {{#allVars} }
30+ self.{ {name} } = { {name} }
31+ { {/allVars} }
2932 }
3033{ {/hasVars} }
3134
6669
6770 /// Builder initializer method for { {classname} } DTO.
6871 { {#nonPublicApi} }internal{ {/nonPublicApi} }{ {^nonPublicApi} }public{ {/nonPublicApi} } func build() -> { {classname} } {
69- var result = {{classname} }()
70- { {#allVars} }
71- result.{ {name} } = { {name} }
72- { {/allVars} }
73- return result
72+ return {{classname} }({ {#allVars} }{ {name} }: { {name} }{ {^-last} },
73+ { {/-last} }{ {/allVars} })
7474 }
7575
7676 public static func ==(lhs: Builder, rhs: Builder) -> Bool {
You can’t perform that action at this time.
0 commit comments