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

Download [pdffile]_updates.plist when appropriate #140

Closed
libreliodev opened this issue Mar 19, 2015 · 7 comments
Closed

Download [pdffile]_updates.plist when appropriate #140

libreliodev opened this issue Mar 19, 2015 · 7 comments
Labels

Comments

@libreliodev
Copy link
Owner

This is related to libreliodev/javascript#128

When [pdffile]_updates.plist is available, we should download it and store it with the other assets of the pdf file.

@AlirezaAlgo
Copy link
Collaborator

@libreliodev
Before adding update.plist as resources. We should get header field x-amz-meta-update and store it in meta file.
I followed the download code and It's NKAssetDownload.
I couldn't find a way to get its header fields.
Should i make another request to get that header field?

@libreliodev
Copy link
Owner Author

@serverfire

I couldn't find a way to get its header fields

Look at - (void)connection:(NSURLConnection *)connection didReceiveResponse:(NSHTTPURLResponse *)responsein WADocumentDownloader

- (void)connection:(NSURLConnection *)connection didReceiveResponse:(NSHTTPURLResponse *)response

@AlirezaAlgo
Copy link
Collaborator

@libreliodev I already tried that. Unfortunately that method is not called at downloading pdf document with NKAssetDownload.

@AlirezaAlgo
Copy link
Collaborator

At

- (void) launchConnectionWithUrlString:completeUrl{

@libreliodev
Copy link
Owner Author

@serverfire

I already tried that. Unfortunately that method is not called at downloading pdf document with NKAssetDownload.

You are right, sorry. Then, I think the best option is to make a direct query to [pdffile]_updates.plist. This should be done inside the shouldGetExtraInformationof the pdf parser.

@AlirezaAlgo
Copy link
Collaborator

Done with d897e6e

@libreliodev
Copy link
Owner Author

Successfully tested

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

No branches or pull requests

2 participants