SmartFlat

@propertyWrapper
public struct SmartFlat<T> : Codable where T : Decodable, T : Encodable

被属性包装器包裹的,不会调用didFinishMapping方法。 Swift的类型系统在运行时无法直接识别出wrappedValue的实际类型,需要各个属性包装器自行处理。

  • Undocumented

    Declaration

    Swift

    public var wrappedValue: T
  • Undocumented

    Declaration

    Swift

    public init(wrappedValue: T)
  • Declaration

    Swift

    public init(from decoder: Decoder) throws
  • Declaration

    Swift

    public func encode(to encoder: Encoder) throws