0
如果我有一個類BFLocation
,我將這些對象的數組傳遞到我的applescript-objc中,如何訪問類屬性?Applescript-objc - 訪問類屬性
BFLocation.h
@property NSString *url;
BFManager.h
#import "BFLocation.h"
@interface script : NSObject
- (void)processLocations:(NSArray *)locations;
@end
BFManager.applescript
script BFManager
property parent : class "NSObject"
on processLocations_(locations)
repeat with location in locations
log location's url
end repeat
end processLocations
我得到 <NSAppleEventDescriptor: 'obj '{ 'form':'prop', 'want':'prop', 'seld':'url ', 'from':'obj '{ 'form':'ID ', 'want':'ocid', 'seld':'optr'($C0FF060080610000$), 'from':null() } }>
我是否需要投射位置以便知道它是一個BFLocation
對象?爲什麼我得到一個NSAppleEventDescriptor而不是預期的字符串?