gpt4 book ai didi

iphone - 找不到 'xxxxx' 的协议(protocol)声明;你是说 'yyyyy'

转载 作者:行者123 更新时间:2023-11-28 18:21:49 27 4
gpt4 key购买 nike

我在 Xcode 项目中有多个协议(protocol),它会给出这样的错误。帮我错误如:-> 找不到“ButtonDelegate”的协议(protocol)声明您是说“CustomDelegate”吗?提前致谢 Image

委托(delegate)头文件

#import <UIKit/UIKit.h>
#import "Constant.h"

@protocol ButtonDelegate <NSObject>
-(void)ChatButtonClicked;
@end

@interface DonttreadonmeCell : UITableViewCell<UIGestureRecognizerDelegate,UITextViewDelegate>{

id <ButtonDelegate> Buttondelegate;

.h File

#import <UIKit/UIKit.h>
#import <Twitter/Twitter.h>
#import "JSONParsing.h"
#import "Facebook.h"
#import "DonttreadonmeCell.h"
#import "Constant.h"



@class DonttreadonmeCell;

@interface BookTextPeregraphselectedViewController : UIViewController<MFMailComposeViewControllerDelegate,FBSessionDelegate,FBRequestDelegate,ButtonDelegate,FBLoginDialogDelegate,FBDialogDelegate,JSONParsingDelegate,UITableViewDataSource,UITableViewDelegate,UIGestureRecognizerDelegate,UITextViewDelegate>{

最佳答案

我在导入文件的顶部声明了我的协议(protocol)声明部分...感谢上帝,它成功了。

  @protocol ButtonDelegate <NSObject>
-(void)ChatButtonClicked;
@end


#import <UIKit/UIKit.h>
#import "Constant.h"

像这样

关于iphone - 找不到 'xxxxx' 的协议(protocol)声明;你是说 'yyyyy',我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/18929191/

27 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com