izzyparser-ios icon indicating copy to clipboard operation
izzyparser-ios copied to clipboard

More flexible serialization

Open GDXRepo opened this issue 4 years ago • 1 comments

https://github.com/undabot/izzyparser-ios/issues/6

GDXRepo avatar Jul 05 '21 02:07 GDXRepo

Just an example. Allows using nil values (they just will be skipped), and allows to customize multiple attributes and/or relationships in one calls sequence.

Usage may look like this (inside a class with customAttri and width optional non-objc properties, for example, of type Double?):

return IzzyBuilder(resource: self)
    .attribute("customAttri", value: customAttri)
    .attribute("width", value: width)
    .serialize()

GDXRepo avatar Jul 05 '21 02:07 GDXRepo