美文网首页
[3] Codable (Swift 4)

[3] Codable (Swift 4)

作者: coderzcj | 来源:发表于2017-09-20 15:34 被阅读22次

重点:

  1. Strategy
  • Date
  • Data
  • NonConformingFloat
  1. Container
  • Keyed Container
  • UnKeyed Container
  • Single Value Container
  1. Optional
  • encode(_:forKey:)
    如果可选类型的值是nil,包含对应的Key, Value 为null。
  • encodeIfPresent(_:forKey:)
    如果可选类型的值是nil,则不包含对应的Key 和 Value。
  1. UserInfo

参考资料:

相关文章

网友评论

      本文标题:[3] Codable (Swift 4)

      本文链接:https://www.haomeiwen.com/subject/ocdosxtx.html