have a requirement to copy files from my Mac OS app. I find:
success=[NSWorkSpace performFileOperation:NSWorkSpaceCopyOperation
 source:nsstring*  // source directory path
 destination:nsstring* // target directory path
 file:nsarray* // nsstring array containing short paths of files or
directories
 tag:nsinteger* // on return, <0 on failure, 0 if sync finish, >0 if async
]
My question relates to asynchronousness (is that a word)? It looks like a
synchronous method as it returns a success or failure. But the documentation
says of the tag variable "a positive integer if the operation was performed
asynchronously. If the value is a positive integer, the value is a tag that
identifies the requested file operation." This confuses me. The examples
I've
seen don't do anything special with the tag.

I may be just missing a document giving a context to this...

Its in the past tense.  If it said "has been started asynchronously" of
course I
would be looking for a method to wait for completion.

So what does "was performed asychronously" mean?
Do I need to care? In what sense was it asynchronous if my API is waiting
for completion? What is the requested file operation identifier and what API
might I use it with? Do I need to release it?

Thanks in advance
_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to