<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Patricio Ignacio Fariña Valdivia on Medium]]></title>
        <description><![CDATA[Stories by Patricio Ignacio Fariña Valdivia on Medium]]></description>
        <link>https://medium.com/@Pfarinav?source=rss-d8d6849fbbd2------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*MdIgImmpQIvCzQ8FEcGGBQ.jpeg</url>
            <title>Stories by Patricio Ignacio Fariña Valdivia on Medium</title>
            <link>https://medium.com/@Pfarinav?source=rss-d8d6849fbbd2------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Sun, 06 Dec 2026 09:49:19 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@Pfarinav/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[CodingKeys: Beyond the name matching.]]></title>
            <link>https://medium.com/@Pfarinav/codingkeys-beyond-the-name-matching-1ff16b24fd86?source=rss-d8d6849fbbd2------2</link>
            <guid isPermaLink="false">https://medium.com/p/1ff16b24fd86</guid>
            <category><![CDATA[programming]]></category>
            <category><![CDATA[coding]]></category>
            <category><![CDATA[codingkeys]]></category>
            <category><![CDATA[swift]]></category>
            <category><![CDATA[ios]]></category>
            <dc:creator><![CDATA[Patricio Ignacio Fariña Valdivia]]></dc:creator>
            <pubDate>Mon, 14 Nov 2022 14:55:00 GMT</pubDate>
            <atom:updated>2022-11-14T14:55:00.618Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1000/1*ucoHbr9u2SlkAVPLxXj55A.jpeg" /></figure><p>Since Codable arrived to Swift, the work to encode or decode our object became way more simple.</p><p>Let’s try to forget the times when we have to serialize into a dictionary, then manually map the values into the properties and cast to the expected types. Those were dark times and we don’t want to come back there.</p><p>But Codable not only bring to us the Encodable and Decodable protocols, it also came with the CodingKey protocol.</p><p>If you have worked with Codable is highly probably that you have used CodingKeys as property/key matcher between your custom structure and a JSON.</p><h4>An example.</h4><p>For this JSON</p><pre>{<br>    &quot;name&quot;: &quot;Bruce&quot;,<br>    &quot;lastname&quot;: &quot;Wayne&quot;,<br>    &quot;age&quot;: 36,<br>    &quot;alias&quot;: &quot;Batman&quot;,<br>    &quot;is_human&quot;: true<br>}</pre><p>We create a struct like this</p><pre>struct Superheroe: Decodable {<br>    let name: String<br>    let lastname: String<br>    let age: Int<br>    let alias: String<br>    let isHuman: Bool<br>}</pre><p>As we are not savages and we don’t want snake_case properties in our beloved model, we change it to camelCase. Of course, the decoder will fail.</p><p>Let’s try it in a Playground</p><pre>import Foundation<br><br>//A string representing a JSON<br>let json = &quot;&quot;&quot;<br>{<br>    &quot;name&quot;: &quot;Bruce&quot;,<br>    &quot;lastname&quot;: &quot;Wayne&quot;,<br>    &quot;age&quot;: 36,<br>    &quot;alias&quot;: &quot;Batman&quot;,<br>    &quot;is_human&quot;: true<br>}<br>&quot;&quot;&quot;<br><br>//That string as Data<br>let data = Data(json.utf8)<br><br>//Our beloved model<br>struct Superheroe: Decodable {<br>    let name: String<br>    let lastname: String<br>    let age: Int<br>    let alias: String<br>    let isHuman: Bool<br>}<br><br>//Our try<br>do {<br>    let superheroe = try JSONDecoder().decode(Superheroe.self, from: data)<br>    print(superheroe)<br>} catch {<br>    print(error)<br>}</pre><p>As the decoder fails, the catch capture the error</p><pre>keyNotFound(<br>  CodingKeys(stringValue: &quot;isHuman&quot;, intValue: nil), <br>  Swift.DecodingError.Context(<br>    codingPath: [], <br>    debugDescription: &quot;No value associated with key CodingKeys(stringValue: &quot;isHuman&quot;, intValue: nil) (&quot;isHuman&quot;).&quot;, <br>    underlyingError: nil)<br>)</pre><p>In simple words, the decoder told us that the key <strong>isHuman </strong>doesn’t exist in the JSON.</p><p>We use CodingKey to solve this, changing our model</p><pre>//Our beloved model<br>struct Superheroe: Decodable {<br>    let name: String<br>    let lastname: String<br>    let age: Int<br>    let alias: String<br>    let isHuman: Bool<br><br>    enum CodingKeys: String, CodingKey {<br>        case name<br>        case lastname<br>        case age<br>        case alias<br>        case isHuman = &quot;is_human&quot;<br>    }<br>}</pre><blockquote><strong>Note</strong>: It must be named <strong>CodingKeys</strong> (in plural) and must have a case for every property in our model (not in the JSON) even if it has an exact match</blockquote><p>We add an enum that is <a href="https://developer.apple.com/documentation/swift/rawrepresentable">RawRepresentable</a> by a String and conforms CodingKey (in singular) protocol. Now the decoder knows that the property <strong>isHuman</strong> should match with the key <strong>is_human</strong>.</p><p>Our playground now prints</p><pre>Superheroe(name: &quot;Bruce&quot;, lastname: &quot;Wayne&quot;, age: 36, alias: &quot;Batman&quot;, isHuman: true)</pre><p>Yai!</p><h3>More than a name matcher</h3><p>Just like <a href="https://www.imdb.com/name/nm0748973/">Maya Rudolph</a> in Hollywood, CodingKey could be very underrated and it’s potential not be used.<br>#JusticeForMaya</p><p>Let spice the JSON a little</p><pre>{<br>   &quot;status&quot;: &quot;success&quot;,<br>   &quot;response&quot;: {<br>      &quot;name&quot;: &quot;Bruce&quot;,<br>      &quot;lastname&quot;: &quot;Wayne&quot;,<br>      &quot;age&quot;: 36,<br>      &quot;alias&quot;: &quot;Batman&quot;,<br>      &quot;is_human&quot;: true<br>   }<br>}</pre><p>Now we don’t just have our desired model in the response, but it is inside a property of a root object. So we have some approaches.</p><h4>1st Approach</h4><p>One way to treat with this is make the decoder <strong>not</strong> decode into our struct, but into a dictionary which have the struct inside.</p><pre>//Our try<br>do {<br>    let superheroe = try JSONDecoder().decode([String: Superheroe].self, from: data)<br>    print(superheroe)<br>} catch {<br>    print(error)<br>}</pre><p>This will not work, because the JSON object have 2 properties and only one of those is a Superheroe object, the other one is a String.</p><p>No problemo, we gonna use <strong>Any</strong></p><pre>//Our try<br>do {<br>    let superheroe = try JSONDecoder().decode([String: Any].self, from: data)<br>    print(superheroe)<br>} catch {<br>    print(error)<br>}</pre><p>Nope!</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/349/1*0TEp4ypUTT6mC2bEOcdecQ.png" /></figure><blockquote><strong>Note</strong>: The same goes for <strong>AnyObject</strong></blockquote><p>The are multiples solutions to make <strong>Any </strong>work with a decoder. Like create a wrapper, create extensions, create mappers, etc… Those are not in the scope of this article and in most cases would be a <strong>huge</strong> case of overengineering</p><p>This approach didn’t work and job to make it work doesn’t worth it (we could be in a situation where it worth it, but those are not very common)</p><h4>2nd Approach</h4><p>If you make me bet, I’d bet that this approach is the one you have seen (and done) more.</p><p>Create a new model, that represents the exact match with the response and the get our model from the property containing it.</p><pre>//Our not so beloved model<br>struct SuperheroeResponse: Decodable {<br>    let response: Superheroe<br>}</pre><blockquote><strong>Note</strong>: We just dont’ add <strong>success</strong> key, because we are not using it and the decoder will ignore it.</blockquote><p>and change the decode method first parameter to this new model</p><pre>//Our try<br>do {<br>    let superheroeResponse = try JSONDecoder().decode(SuperheroeResponse.self, from: data)<br>    print(superheroeResponse.response)<br>} catch {<br>    print(error)<br>}</pre><p>This prints</p><pre>Superheroe(name: &quot;Bruce&quot;, lastname: &quot;Wayne&quot;, age: 36, alias: &quot;Batman&quot;, isHuman: true)</pre><p>It worked! But it feels like a victory? Eh…<br>We make it work, but we have to create another model just for this.<br><strong>.response</strong> is not very descriptive and if we want to fix that we need to use CodingKeys in this new model.</p><p>Let’s change that and see the full Playground</p><pre>import Foundation<br><br>//A string representing a JSON<br>let json = &quot;&quot;&quot;<br>{<br>    &quot;status&quot;: &quot;success&quot;,<br>    &quot;response&quot;: {<br>        &quot;name&quot;: &quot;Bruce&quot;,<br>        &quot;lastname&quot;: &quot;Wayne&quot;,<br>        &quot;age&quot;: 36,<br>        &quot;alias&quot;: &quot;Batman&quot;,<br>        &quot;is_human&quot;: true<br>    }<br>}<br>&quot;&quot;&quot;<br><br>//That string as Data<br>let data = Data(json.utf8)<br><br>//Our not so beloved model<br>struct SuperheroeResponse: Decodable {<br>    let superheroe: Superheroe<br><br>    enum CodingKeys: String, CodingKey {<br>        case superheroe = &quot;response&quot;<br>    }<br>}<br><br>//Our beloved model<br>struct Superheroe: Decodable {<br>    let name: String<br>    let lastname: String<br>    let age: Int<br>    let alias: String<br>    let isHuman: Bool<br><br>    enum CodingKeys: String, CodingKey {<br>        case name<br>        case lastname<br>        case age<br>        case alias<br>        case isHuman = &quot;is_human&quot;<br>    }<br>}<br><br>//Our try<br>do {<br>    let superheroeResponse = try JSONDecoder().decode(SuperheroeResponse.self, from: data)<br>    print(superheroeResponse.superheroe)<br>} catch {<br>    print(error)<br>}</pre><p>A little better.</p><p>Before going with the 3rd approach, let see what happens in a worse scenario.</p><p>The new JSON</p><pre>{<br>  &quot;status&quot;: &quot;success&quot;,<br>  &quot;response&quot;: {<br>    &quot;name&quot;: &quot;Bruce&quot;,<br>    &quot;lastname&quot;: &quot;Wayne&quot;,<br>    &quot;age&quot;: 36,<br>    &quot;alias&quot;: &quot;Batman&quot;,<br>    &quot;is_human&quot;: true<br>  },<br>  &quot;is_valid&quot;: true<br>}</pre><p>No problem, our decoder just will ignore <strong>is_valid </strong>and everything will keep working.<br>Yes! But for a reason beyond our power, business says that <strong>is_valid, </strong>must be part of superheroe model.</p><p>Let’s modify our models</p><pre>//Our not so beloved model<br>struct SuperheroeResponse: Decodable {<br>    let superheroe: Superheroe<br>    let isValid: Bool<br><br>    enum CodingKeys: String, CodingKey {<br>        case superheroe = &quot;response&quot;<br>        case isValid = &quot;is_valid&quot;<br>    }<br>}<br><br>//Our beloved model<br>struct Superheroe: Decodable {<br>    let name: String<br>    let lastname: String<br>    let age: Int<br>    let alias: String<br>    let isHuman: Bool<br>    var isValid: Bool?<br><br>    enum CodingKeys: String, CodingKey {<br>        case name<br>        case lastname<br>        case age<br>        case alias<br>        case isHuman = &quot;is_human&quot;<br>    }<br>}</pre><p>We added an optional variable (<strong>var</strong>) to our <strong>Superheroe</strong> model, because we gonna have to set it after creation and we add the <strong>isValid</strong> property to our <strong>SuperheroeResponse </strong>(with the CodingKey).</p><p>With this changes our Playground still works, but the Superheroe will have a nil <strong>isValid</strong> property.</p><p>The Playground now prints</p><pre>Superheroe(name: &quot;Bruce&quot;, lastname: &quot;Wayne&quot;, age: 36, alias: &quot;Batman&quot;, isHuman: true, isValid: nil)</pre><p>We have to add some logic into our code to fix this</p><pre>//Our try<br>do {<br>    let superheroeResponse = try JSONDecoder().decode(SuperheroeResponse.self, from: data)<br>    var superheroe = superheroeResponse.superheroe<br>    superheroe.isValid = superheroeResponse.isValid<br>    print(superheroe)<br>} catch {<br>    print(error)<br>}</pre><p>And this will print</p><pre>Superheroe(name: &quot;Bruce&quot;, lastname: &quot;Wayne&quot;, age: 36, alias: &quot;Batman&quot;, isHuman: true, isValid: Optional(true))</pre><p>Yes, it works, but the Neanderthals became extinct for us to do things like this?<br>I don’t think so. <br>#MakeItForTheNeanderthals</p><h4>3rd Approach</h4><p>Our 3rd approach will be using the power of CodingKeys.</p><p>As said before, CodingKeys are more than a name matcher, it could be used for complex mapping.<br>For this, we need to add some extra CodingKeys an write our custom decoding logic. Sounds hard, but is not.</p><p>We delete the SuperheroeResponse model and modify our Superheroe model.</p><pre>//Our beloved model<br>struct Superheroe: Decodable {<br>    let name: String<br>    let lastname: String<br>    let age: Int<br>    let alias: String<br>    let isHuman: Bool<br>    let isValid: Bool<br><br>    enum CodingKeys: String, CodingKey {<br>        case response<br>        case isValid = &quot;is_valid&quot;<br>    }<br><br>    enum ResponseKeys: String, CodingKey {<br>        case name<br>        case lastname<br>        case age<br>        case alias<br>        case isHuman = &quot;is_human&quot;<br>    }<br>}</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/477/1*Vf-zyuIKLQqPHHa1QT1Dzw.png" /><figcaption>We gonna see this error. Ignore it for now</figcaption></figure><p>What we did?</p><p>First of all, we change <strong>isValid</strong> to be a let again, not optional.</p><p>And then we add the CodingKeys based on the format of the JSON.<br>While the first enum has to be named CodingKeys, we can have any enums of CodingKeys we want and the naming restriction is only for the first one, the second could be named BBQChikenWings (please don’t name it like this)</p><p>So, let check the JSON again</p><pre>{<br>    &quot;status&quot;: &quot;success&quot;,<br>    &quot;response&quot;: {<br>        &quot;name&quot;: &quot;Bruce&quot;,<br>        &quot;lastname&quot;: &quot;Wayne&quot;,<br>        &quot;age&quot;: 36,<br>        &quot;alias&quot;: &quot;Batman&quot;,<br>        &quot;is_human&quot;: true<br>    },<br>    &quot;is_valid&quot;: true<br>}</pre><p>We have an object that have 3 properties: status, response and is_valid</p><p>As we are not interested on <strong>status</strong>, we just ignore it an create the base CodingKeys based on this object</p><pre>enum CodingKeys: String, CodingKey {<br>  case response<br>  case isValid = &quot;is_valid&quot;<br>}</pre><p>Inside this object, with the key response, we have our desired model (without isValid, which is in the root object)</p><pre>&quot;response&quot;: {<br>        &quot;name&quot;: &quot;Bruce&quot;,<br>        &quot;lastname&quot;: &quot;Wayne&quot;,<br>        &quot;age&quot;: 36,<br>        &quot;alias&quot;: &quot;Batman&quot;,<br>        &quot;is_human&quot;: true<br>    }</pre><p>We add a second set of CodingKeys based on this object</p><pre>enum ResponseKeys: String, CodingKey {<br>    case name<br>    case lastname<br>    case age<br>    case alias<br>    case isHuman = &quot;is_human&quot;<br>}</pre><p>Now we have to deal with the error we saw before</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/477/1*Vf-zyuIKLQqPHHa1QT1Dzw.png" /></figure><p>Why is this happening?<br>Because besides having the CodingKeys, the decoder doesn’t know how to map them and we have to explain to it. For this, we need to implement</p><pre> init(from decoder: Decoder) throws {}</pre><p>in our model. This init will be used by de decoder.<br>In the very moment we implement it, the error goes away, but doesn’t means that the problem is solved.</p><p>I’m gonna go step by step, sorry if it becomes tedious</p><ol><li>We create a baseContainer container using the base CodingKeys</li></ol><pre>init(from decoder: Decoder) throws {<br>    let baseContainer = try decoder.container(keyedBy: CodingKeys.self)<br>}</pre><p>2. From the baseContainer we create a responseContainer using ResponseKeys and we have to say from which key of baseContainer are we creating it.</p><pre>init(from decoder: Decoder) throws {<br>    let baseContainer = try decoder.container(keyedBy: CodingKeys.self)<br>    let responseContainer = try baseContainer.nestedContainer(keyedBy: ResponseKeys.self, forKey: .response)<br>}</pre><p>3. We map!</p><pre>init(from decoder: Decoder) throws {<br>    let baseContainer = try decoder.container(keyedBy: CodingKeys.self)<br>    let responseContainer = try baseContainer.nestedContainer(keyedBy: ResponseKeys.self, forKey: .response)<br><br>    name = try responseContainer.decode(String.self, forKey: .name)<br>    lastname = try responseContainer.decode(String.self, forKey: .lastname)<br>    age = try responseContainer.decode(Int.self, forKey: .age)<br>    alias = try responseContainer.decode(String.self, forKey: .alias)<br>    isHuman = try responseContainer.decode(Bool.self, forKey: .isHuman)<br>    isValid = try baseContainer.decode(Bool.self, forKey: .isValid)<br>}</pre><p>We just map every property of our Superheroe model to a key from our containers. <br>Notice that <strong>isValid</strong> is being decoded from <strong>baseContainer</strong>, while the others are decoded from <strong>responseContainer</strong>.<br>Also notice that everything has a <strong>try</strong> in front, if anything fail to decode, it will throw a <a href="https://developer.apple.com/documentation/swift/decodingerror">DecodingError</a>.</p><p>The full Playground</p><pre>import Foundation<br><br>//A string representing a JSON<br>let json = &quot;&quot;&quot;<br>{<br>    &quot;status&quot;: &quot;success&quot;,<br>    &quot;response&quot;: {<br>        &quot;name&quot;: &quot;Bruce&quot;,<br>        &quot;lastname&quot;: &quot;Wayne&quot;,<br>        &quot;age&quot;: 36,<br>        &quot;alias&quot;: &quot;Batman&quot;,<br>        &quot;is_human&quot;: true<br>    },<br>    &quot;is_valid&quot;: true<br>}<br>&quot;&quot;&quot;<br><br>//That string as Data<br>let data = Data(json.utf8)<br><br>//Our beloved model<br>struct Superheroe: Decodable {<br>    let name: String<br>    let lastname: String<br>    let age: Int<br>    let alias: String<br>    let isHuman: Bool<br>    let isValid: Bool<br><br>    enum CodingKeys: String, CodingKey {<br>        case response<br>        case isValid = &quot;is_valid&quot;<br>    }<br><br>    enum ResponseKeys: String, CodingKey {<br>        case name<br>        case lastname<br>        case age<br>        case alias<br>        case isHuman = &quot;is_human&quot;<br>    }<br><br>    init(from decoder: Decoder) throws {<br>        let baseContainer = try decoder.container(keyedBy: CodingKeys.self)<br>        let responseContainer = try baseContainer.nestedContainer(keyedBy: ResponseKeys.self, forKey: .response)<br><br>        name = try responseContainer.decode(String.self, forKey: .name)<br>        lastname = try responseContainer.decode(String.self, forKey: .lastname)<br>        age = try responseContainer.decode(Int.self, forKey: .age)<br>        alias = try responseContainer.decode(String.self, forKey: .alias)<br>        isHuman = try responseContainer.decode(Bool.self, forKey: .isHuman)<br>        isValid = try baseContainer.decode(Bool.self, forKey: .isValid)<br>    }<br>}<br><br>//Our try<br>do {<br>    let superheroe = try JSONDecoder().decode(Superheroe.self, from: data)<br>    print(superheroe)<br>} catch {<br>    print(error)<br>}</pre><p>We can add as many nested containers as we need and map properties as we desire.</p><p>Let see the Playground with a more complex JSON, when <strong>race</strong> is an object nested in the response object and a new property named <strong>city </strong>is and object inside the base object</p><pre>import Foundation<br><br>//A string representing a JSON<br>let json = &quot;&quot;&quot;<br>{<br>    &quot;status&quot;: &quot;success&quot;,<br>    &quot;response&quot;: {<br>        &quot;name&quot;: &quot;Bruce&quot;,<br>        &quot;lastname&quot;: &quot;Wayne&quot;,<br>        &quot;age&quot;: 36,<br>        &quot;alias&quot;: &quot;Batman&quot;,<br>        &quot;race&quot;:{<br>            &quot;type&quot;: &quot;human&quot;<br>        }<br>    },<br>    &quot;is_valid&quot;: true,<br>    &quot;city&quot;: {<br>        &quot;name&quot;: &quot;Gotham&quot;,<br>        &quot;location&quot;: &quot;Earth&quot;<br>    }<br>}<br>&quot;&quot;&quot;<br><br>//That string as Data<br>let data = Data(json.utf8)<br><br>//Our beloved model<br>struct Superheroe: Decodable {<br>    let name: String<br>    let lastname: String<br>    let age: Int<br>    let alias: String<br>    let city: String<br>    let isHuman: Bool<br>    let isValid: Bool<br><br>    enum CodingKeys: String, CodingKey {<br>        case response<br>        case isValid = &quot;is_valid&quot;<br>        case city<br>    }<br><br>    enum ResponseKeys: String, CodingKey {<br>        case name<br>        case lastname<br>        case age<br>        case alias<br>        case race<br>    }<br><br>    enum RaceKeys: String, CodingKey {<br>        case type<br>    }<br><br>    enum CityKeys: String, CodingKey {<br>        case name<br>    }<br><br>    init(from decoder: Decoder) throws {<br>        let baseContainer = try decoder.container(keyedBy: CodingKeys.self)<br>        let responseContainer = try baseContainer.nestedContainer(keyedBy: ResponseKeys.self, forKey: .response)<br>        let raceContainer = try responseContainer.nestedContainer(keyedBy: RaceKeys.self, forKey: .race)<br>        let cityContainer = try baseContainer.nestedContainer(keyedBy: CityKeys.self, forKey: .city)<br><br>        name = try responseContainer.decode(String.self, forKey: .name)<br>        lastname = try responseContainer.decode(String.self, forKey: .lastname)<br>        age = try responseContainer.decode(Int.self, forKey: .age)<br>        alias = try responseContainer.decode(String.self, forKey: .alias)<br>        isValid = try baseContainer.decode(Bool.self, forKey: .isValid)<br><br>        isHuman = try raceContainer.decode(String.self, forKey: .type) == &quot;human&quot;<br>        city = try cityContainer.decode(String.self, forKey: .name)<br>    }<br>}<br><br>//Our try<br>do {<br>    let superheroe = try JSONDecoder().decode(Superheroe.self, from: data)<br>    print(superheroe)<br>} catch {<br>    print(error)<br>}</pre><p>And this prints</p><pre>Superheroe(name: &quot;Bruce&quot;, lastname: &quot;Wayne&quot;, age: 36, alias: &quot;Batman&quot;, city: &quot;Gotham&quot;, isHuman: true, isValid: true)</pre><p>Yai!<br>Now Neanderthals extinction wasn’t in vain!<br>The code that gets the data doesn’t have any mapping responsibility and we don’t need to add new models.</p><p>I hope this helps!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=1ff16b24fd86" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>