Skip to content

Add NSSecureCoding to PFFileObject #1736

Open
@dhoerl

Description

@dhoerl

New Feature / Enhancement Checklist

Current Limitation

PFFileObject does not implement NSSecureCoding.

Feature / Enhancement Description

Directly add NSSecureCoding to PFFileObject. The code to do this is less than 50 lines of code. Essentially, you have PFEncoder encode the file object first, then the NSSecureCoder just encodes the dictionary returned by PFEncoder. Creating an instance is just the inverse.

Since I have the code, I could create a Pull Request with it, if there is an understanding that it would be merged at some point.

Example Use Case

I create a PFFileObject in an app, in some class. I want to then serialize that object using NSSecureCoding. I can do this with a class extension in Objective-C, but now that the app is being converted to Swift, I will need to keep the Objective-C code around forever.

Alternatives / Workarounds

Use a class extension in Objective-C

3rd Party References

NSSecureCoding is widely used.

Metadata

Metadata

Assignees

No one assigned

    Labels

    type:featureNew feature or improvement of existing feature

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions