|
Objective-C and Swift interoperability in the lldb console.
I have some utility classes with class methods in Objective-C and a copy in Swift. For now, I am using the Swift version, but calling one of the methods from a class that is Objective-C. While I
I have some utility classes with class methods in Objective-C and a copy in Swift. For now, I am using the Swift version, but calling one of the methods from a class that is Objective-C. While I
|
By
Alex Zavatone
·
#996
·
|
|
Re: Usage Question concerning [weak self]
By my analysis the capture list in the DispatchQueue closure is unnecessary, because by that point `self` is already weak. You can prove this by adding a `weak var this = self` and change the `self`s
By my analysis the capture list in the DispatchQueue closure is unnecessary, because by that point `self` is already weak. You can prove this by adding a `weak var this = self` and change the `self`s
|
By
Ben Kennedy
·
#995
·
|
|
Usage Question concerning [weak self]
I am doing some processing of network requests, and the response is processed in a background thread using a closure.
The closure executes some logic on the background thread and then (possibly)
I am doing some processing of network requests, and the response is processed in a background thread using a closure.
The closure executes some logic on the background thread and then (possibly)
|
By
Rick Aurbach
·
#994
·
|
|
Re: NSFIleManager enumeratorAtPath problem
Jens,
Thanks for the info on the enumeratorAtURL: method. I take back my suggestion regarding the bug then.
Regarding my pseudo-security remarks: yes, I agree of course that some of the measures make
Jens,
Thanks for the info on the enumeratorAtURL: method. I take back my suggestion regarding the bug then.
Regarding my pseudo-security remarks: yes, I agree of course that some of the measures make
|
By
Leo
·
#993
·
|
|
Re: 'altool' cannot be found
Ok it was my first post and it took 2 days for it to arrive...
By now the issue is solved: I had to reset the Command Line Tools path with xcode-select -r
Ok it was my first post and it took 2 days for it to arrive...
By now the issue is solved: I had to reset the Command Line Tools path with xcode-select -r
|
By
Leo
·
#992
·
|
|
Re: NSFIleManager enumeratorAtPath problem
The OP was calling -[NSFileManager enumeratorAtPath:], which is an old API that predates NSError, so failing silently is all it can do. (Cocoa APIs do not throw exceptions except in the case of
The OP was calling -[NSFileManager enumeratorAtPath:], which is an old API that predates NSError, so failing silently is all it can do. (Cocoa APIs do not throw exceptions except in the case of
|
By
Jens Alfke
·
#991
·
|
|
Re: NSFIleManager enumeratorAtPath problem
I read this discussion with interest... that's good to know!
May I also suggest to submit it as a bug to Apple.
That is, if a function fails because of sandboxing then it shouldn't just fail silently.
I read this discussion with interest... that's good to know!
May I also suggest to submit it as a bug to Apple.
That is, if a function fails because of sandboxing then it shouldn't just fail silently.
|
By
Leo
·
#990
·
|
|
'altool' cannot be found
Hi all,
I wanted to start building a notarization automation script.
However, when I try to use the 'xcrun altool' in Terminal, I get the following error:
xcrun: error: unable to find utility
Hi all,
I wanted to start building a notarization automation script.
However, when I try to use the 'xcrun altool' in Terminal, I get the following error:
xcrun: error: unable to find utility
|
By
Leo
·
#989
·
|
|
[OT] Experienced freelance Mac/iOS Developer Looking for Work
Hi,
Experienced Mac and iOS developer with a lot experience in Objective-C and many other languages.
Experience of the following technologies:
XCode
Quartz Event
Hi,
Experienced Mac and iOS developer with a lot experience in Objective-C and many other languages.
Experience of the following technologies:
XCode
Quartz Event
|
By
Dave
·
#988
·
|
|
Re: How to get Extended File Info
No, I’ve used it with MP3 and AAC and AIFF; I’m pretty sure it supports every format there’s a system codec for (i.e. most audio formats except Ogg and FLAC, but you can get 3rd party components
No, I’ve used it with MP3 and AAC and AIFF; I’m pretty sure it supports every format there’s a system codec for (i.e. most audio formats except Ogg and FLAC, but you can get 3rd party components
|
By
Jens Alfke
·
#987
·
|
|
Re: How to get Extended File Info
Rumor (i.e. Stack Overflow) has it that AVFoundation will only work with AAC, but I have not confirmed that myself.
Keary Suska
Esoteritech, Inc.
"Demystifying technology for your home or business"
Rumor (i.e. Stack Overflow) has it that AVFoundation will only work with AAC, but I have not confirmed that myself.
Keary Suska
Esoteritech, Inc.
"Demystifying technology for your home or business"
|
By
Keary Suska
·
#986
·
|
|
Re: How to get Extended File Info
AVFoundation has a higher-level OOP API for this. Look for methods for accessing metadata, and constants defining the various metadata types like Title, Artist, etc.
—Jens
AVFoundation has a higher-level OOP API for this. Look for methods for accessing metadata, and constants defining the various metadata types like Title, Artist, etc.
—Jens
|
By
Jens Alfke
·
#985
·
|
|
Re: How to get Extended File Info
I believe there is a function where you can pull all available attributes/properties. You can look at that dict and see if it contains what you are looking for.
Keary Suska
Esoteritech,
I believe there is a function where you can pull all available attributes/properties. You can look at that dict and see if it contains what you are looking for.
Keary Suska
Esoteritech,
|
By
Keary Suska
·
#984
·
|
|
Re: How to get Extended File Info
In Obj-C (getting width and height of an image in pixels):
NSMetadataItem *mdItem = [[NSMetadataItem alloc] initWithURL:url];
NSDictionary *dict = [mdItem
In Obj-C (getting width and height of an image in pixels):
NSMetadataItem *mdItem = [[NSMetadataItem alloc] initWithURL:url];
NSDictionary *dict = [mdItem
|
By
Jon Gotow
·
#983
·
|
|
Re: How to get Extended File Info
Hi,
I’m looking at the Audio Toolbox, I assume you mean the AudioOpenFile, AudioFileGetProperty and AudioCloseFile C functions? If so, then I can’t see how to get the fields I mentioned? In the
Hi,
I’m looking at the Audio Toolbox, I assume you mean the AudioOpenFile, AudioFileGetProperty and AudioCloseFile C functions? If so, then I can’t see how to get the fields I mentioned? In the
|
By
Dave
·
#982
·
|
|
Re: NSFIleManager enumeratorAtPath problem
Hi,
Yes! It was sandboxing I turned it off and all works ok now!
Thanks
Dave
Hi,
Yes! It was sandboxing I turned it off and all works ok now!
Thanks
Dave
|
By
Dave
·
#981
·
|
|
Re: NSFIleManager enumeratorAtPath problem
Wait, is security getting in the way? Is the app sandboxed? If so, you can't just throw a folder at it and expect it to work. What if you choose the folder via NSOpenPanel or add Desktop as one of the
Wait, is security getting in the way? Is the app sandboxed? If so, you can't just throw a folder at it and expect it to work. What if you choose the folder via NSOpenPanel or add Desktop as one of the
|
By
Steve Mills
·
#980
·
|
|
Re: NSFIleManager enumeratorAtPath problem
I’ve already tried it, same result.
Can’t think of anything else that could be going wrong!
I’ve already tried it, same result.
Can’t think of anything else that could be going wrong!
|
By
Dave
·
#979
·
|
|
Re: How to get Extended File Info
AudioToolbox, especially Audio File Services (don’t have links but should be able to search docs easily), appear to have this capability.
Keary Suska
Esoteritech, Inc.
"Demystifying technology for
AudioToolbox, especially Audio File Services (don’t have links but should be able to search docs easily), appear to have this capability.
Keary Suska
Esoteritech, Inc.
"Demystifying technology for
|
By
Keary Suska
·
#978
·
|
|
Re: NSFIleManager enumeratorAtPath problem
Just for kicks, what if you remove the trailing '/'?
--
Steve Mills
Drummer, Mac geek
Just for kicks, what if you remove the trailing '/'?
--
Steve Mills
Drummer, Mac geek
|
By
Steve Mills
·
#977
·
|