Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Replace most method overloads of writeData and writeIntoBuffer with a UZKFileInfo instance #89

Closed
abbeycode opened this issue Jul 2, 2019 · 1 comment
Assignees
Milestone

Comments

@abbeycode
Copy link
Owner

abbeycode commented Jul 2, 2019

There are far too many overloads of the -writeData:... and -writeInfoBuffer:... methods, which causes friction, complexity, and unnecessary bugs (e.g. #81, #85) due to incorrect and/or inconsistent values being passed as defaults from the shorter overloads.

Instead, add public initializers to UZKFileInfo, and update the most complicated overload to take that as the only argument, reading the required properties out of it. There should still be one more overload for each, covering the simplest case of only a file path and the data being written.

@abbeycode
Copy link
Owner Author

The PR, as written, went in a different direction, keeping UZKFileInfo a class that's read-only to API consumers, and introducing a new ZipFileProperties class (written in Swift), which can be modified and passed to the new overloads of -writeData:... and -writeIntoBuffer:....

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant