BaseMappable

public protocol BaseMappable

BaseMappable should not be implemented directly. Mappable or StaticMappable should be used instead

  • This function is where all variable mappings should occur. It is executed by Mapper during the mapping (serialization and deserialization) process.

    Declaration

    Swift

    mutating func mapping(map: Map)
  • init(JSONString:context:) Extension method

    Initializes object from a JSON String

    Declaration

    Swift

    public init?(JSONString: String, context: MapContext? = nil)
  • init(JSON:context:) Extension method

    Initializes object from a JSON Dictionary

    Declaration

    Swift

    public init?(JSON: [String: Any], context: MapContext? = nil)
  • toJSON() Extension method

    Returns the JSON Dictionary for the object

    Declaration

    Swift

    public func toJSON() -> [String: Any]
  • toJSONString(prettyPrint:) Extension method

    Returns the JSON String for the object

    Declaration

    Swift

    public func toJSONString(prettyPrint: Bool = false) -> String?