【发布时间】:2016-09-07 09:36:50
【问题描述】:
Facebook SDK 的标头已使用this repository 中的 SDKTransformAssistant 进行了转换。
不幸的是,该工具没有正确转换它们。 FBSDKShareLinkContent 应该从 FBSDKSharingContent 继承,所以它包含属性 contentURL,但它没有。
修复pascal标头的正确方法是什么?
Objective C 标头:
@protocol FBSDKSharingContent <FBSDKCopying, NSSecureCoding>
@property (nonatomic, copy) NSURL *contentURL;
@property (nonatomic, copy) FBSDKHashtag *hashtag;
@property (nonatomic, copy) NSArray *peopleIDs;
@property (nonatomic, copy) NSString *placeID;
@property (nonatomic, copy) NSString *ref;
@interface FBSDKShareLinkContent : NSObject <FBSDKSharingContent>
@property (nonatomic, copy) NSString *contentDescription;
@property (nonatomic, copy) NSString *contentTitle;
@property (nonatomic, copy) NSString *contentTitle;
@property (nonatomic, copy) NSURL *imageURL;
@property (nonatomic, copy) NSString *quote;
- (BOOL)isEqualToShareLinkContent:(FBSDKShareLinkContent *)content;
它们目前是如何转换的:
FBSDKSharingContent = interface(IObjectiveC)
['{BF1DBAD7-9326-44AA-A6BD-5E7F0515F925}']
procedure setContentURL(contentURL: NSURL); cdecl;
function contentURL: NSURL; cdecl;
procedure setHashtag(hashtag: FBSDKHashtag); cdecl;
function hashtag: FBSDKHashtag; cdecl;
procedure setPeopleIDs(peopleIDs: NSArray); cdecl;
function peopleIDs: NSArray; cdecl;
procedure setPlaceID(placeID: NSString); cdecl;
function placeID: NSString; cdecl;
procedure setRef(ref: NSString); cdecl;
function ref: NSString; cdecl;
end;
FBSDKShareLinkContent = interface(NSObject)
['{09744C48-BB8F-49AB-A42E-F2E2C2C6129E}']
procedure setContentDescription(contentDescription: NSString); cdecl;
function contentDescription: NSString; cdecl;
procedure setContentTitle(contentTitle: NSString); cdecl;
function contentTitle: NSString; cdecl;
procedure setImageURL(imageURL: NSURL); cdecl;
function imageURL: NSURL; cdecl;
procedure setQuote(quote: NSString); cdecl;
function quote: NSString; cdecl;
function isEqualToShareLinkContent(content: FBSDKShareLinkContent): Boolean; cdecl;
end;
TFBSDKShareLinkContent = class(TOCGenericImport<FBSDKShareLinkContentClass, FBSDKShareLinkContent>)
end;
【问题讨论】:
标签: ios objective-c facebook delphi