Post

Replies

Boosts

Views

Activity

Comment on How can I read a dataless file from within the same or another FileProvider extension?
Whole file ? As per the documentation, If the device has not yet downloaded the file at the given URL, this method blocks (potentially for a long time) while the file is downloaded. If the file cannot be downloaded, this method fails.. I need a method to pass a URL to AVAsset and ensure that only the specified offset range is read from the AVFoundation library
Topic: App & System Services SubTopic: Core OS Tags:
Sep ’24
Comment on How can I access the download status of an NSFileProviderItem from the File Provider extension?
Yes. This is what I do after enumerate the received URL. let stop = fileURL.startAccessingSecurityScopedResource() defer { if stop { fileURL.stopAccessingSecurityScopedResource() } } let permissions: mode_t = 0o644 let err = chmod(fileURL.path, permissions) if err != 0 { print("chmod failed: \(String(cString: strerror(errno)))") }
Topic: App & System Services SubTopic: Core OS Tags:
Sep ’24
Comment on How can I read a dataless file from within the same or another FileProvider extension?
Thanks.
Topic: App & System Services SubTopic: Core OS Tags:
Replies
Boosts
Views
Activity
Sep ’24
Comment on How can I read a dataless file from within the same or another FileProvider extension?
Whole file ? As per the documentation, If the device has not yet downloaded the file at the given URL, this method blocks (potentially for a long time) while the file is downloaded. If the file cannot be downloaded, this method fails.. I need a method to pass a URL to AVAsset and ensure that only the specified offset range is read from the AVFoundation library
Topic: App & System Services SubTopic: Core OS Tags:
Replies
Boosts
Views
Activity
Sep ’24
Comment on How can I access the download status of an NSFileProviderItem from the File Provider extension?
Yes. This is what I do after enumerate the received URL. let stop = fileURL.startAccessingSecurityScopedResource() defer { if stop { fileURL.stopAccessingSecurityScopedResource() } } let permissions: mode_t = 0o644 let err = chmod(fileURL.path, permissions) if err != 0 { print("chmod failed: \(String(cString: strerror(errno)))") }
Topic: App & System Services SubTopic: Core OS Tags:
Replies
Boosts
Views
Activity
Sep ’24
Comment on How can I access the download status of an NSFileProviderItem from the File Provider extension?
First option, There is a warning sign :( Only use waitForStabilization(completionHandler:) for testing and debugging. Don’t call this method in a production app, due to its high performance cost.
Topic: App & System Services SubTopic: Core OS Tags:
Replies
Boosts
Views
Activity
Sep ’24
Comment on How can I access the download status of an NSFileProviderItem from the File Provider extension?
Second option didn't work. chmod throws Operation not permitted error, both in code and in the terminal (even with sudo).
Topic: App & System Services SubTopic: Core OS Tags:
Replies
Boosts
Views
Activity
Sep ’24