SmartUpdater

public struct SmartUpdater<T> where T : SmartDecodable, T : SmartEncodable

Undocumented

  • This method is used to parse JSON data from a Data object and use the resulting dictionary to update a target object.

    Declaration

    Swift

    public static func update(_ dest: inout T, from src: Data?)

    Parameters

    dest

    A reference to the target object (the inout keyword indicates that this object will be modified within the method).

    src

    A Data object containing the JSON data.

  • This method is used to parse JSON data from a Data object and use the resulting dictionary to update a target object.

    Declaration

    Swift

    public static func update(_ dest: inout T, from src: String?)

    Parameters

    dest

    A reference to the target object (the inout keyword indicates that this object will be modified within the method).

    src

    A String object containing the JSON data.

  • This method is used to parse JSON data from a Data object and use the resulting dictionary to update a target object.

    Declaration

    Swift

    public static func update(_ dest: inout T, from src: [String : Any]?)

    Parameters

    dest

    A reference to the target object (the inout keyword indicates that this object will be modified within the method).

    src

    A Dictionary object containing the JSON data.