在我的头文件 GuiController.h 中:
#import <Cocoa/Cocoa.h>
#import <APPKit/NSTextField.h>
#import "ClientSocket.h"
#import "UploaderThread.h"
#import "DownloaderThread.h"
/**
* SER 321 Foundations of Distributed Applications
* see http://pooh.poly.asu.edu/Cst420
* @author Christopher Sosa (smoothpinkjazz@gmail.com), ASU Polytechnic, Software Engineering
* @version December 2012
*/
@class AppDelegate; //compiler error
@interface GuiController : NSObject {
AppDelegate * appDelegate;
NSSound *sound;
NSString *port;
NSString *host;
ClientSocket *mainSock;
ClientSocket *songSock;
UploaderThread *uploader;
int ident;
NSTextField *albTB;
NSComboBox *titCB;
NSTextField *authTB;
}
- (id) initWithDelegate: (AppDelegate*) theDelegate
host: (NSString*) hostName
port: (NSString*) portNum;
- (void) dealloc;
- (void) saveLib;
- (void) restoreLib;
- (void) addMD;
- (void) removeMD;
- (void) refreshMD;
- (void) playMD;
- (void) comboBoxSelectionDidChange: (NSNotification*)notification;
- (void) debug: (NSString*) aMessage;
@end
我标记了引发错误的行,即使似乎没有错误。我 99% 确定编译器抛出错误只是因为它感觉像它。你能找出问题所在吗?