4 * Rendezvous network controller
6 * Original Author : Kent Sutherland <ksuther@ithinksw.com>
7 * Responsibility : Kent Sutherland <ksuther@ithinksw.com>
9 * Copyright (c) 2003 iThink Software.
14 #import <Foundation/Foundation.h>
16 #define SERVER_PORT 5712
20 @interface NetworkController : NSObject
22 NSNetService *service;
23 NSNetServiceBrowser *browser;
24 NSMutableArray *remoteServices;
26 NSConnection *serverConnection, *clientConnection;
27 NSSocketPort *serverPort, *clientPort;
29 BOOL serverOn, clientConnected, connectedToServer;
30 NSData *serverPass, *clientPass;
31 NetworkObject *clientProxy;
33 + (NetworkController *)sharedController;
35 - (void)startRemoteServerSearch;
36 - (void)stopRemoteServerSearch;
38 - (void)setServerStatus:(BOOL)status;
39 - (int)connectToHost:(NSString *)host;
40 - (BOOL)checkForServerAtHost:(NSString *)host;
43 - (BOOL)isClientConnected;
44 - (BOOL)isConnectedToServer;
45 - (NSString *)remoteHost;
47 - (NetworkObject *)networkObject;
48 - (NSArray *)remoteServices;