[swift-corelibs-dev] NSCoding methods

Luke Howard lukeh at padl.com
Thu Dec 24 17:10:00 CST 2015

NSKeyedUnarchiver is working, at least for a few classes for which I’ve implemented initWithCoder:. Promisingly encoding and decoding nested Swift classes works, using name mangling we discussed yesterday.

It does use NSPropertyListSerialization to read the entire property list into memory, whereas it appears Foundation incrementally decodes the archive directly. I’m not sure if I’ll have time to implement incremental decoding but at least this should be a start.

— Luke

> On 24 Dec 2015, at 1:51 PM, Luke Howard via swift-corelibs-dev <swift-corelibs-dev at swift.org> wrote:
> I’m planning to use this for now:
> https://github.com/lhoward/swift-corelibs-foundation/commit/177e7d9f945db58217edec70d90d5cb53cba0245 <https://github.com/lhoward/swift-corelibs-foundation/commit/177e7d9f945db58217edec70d90d5cb53cba0245>
> Noted that it won’t work for non-public symbols, but at least I can see how far I can get with NSKeyedArchiver/Unarchiver in the meantime.
> — Luke
> _______________________________________________
> swift-corelibs-dev mailing list
> swift-corelibs-dev at swift.org
> https://lists.swift.org/mailman/listinfo/swift-corelibs-dev


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.swift.org/pipermail/swift-corelibs-dev/attachments/20151225/178b0ea5/attachment.html>

More information about the swift-corelibs-dev mailing list