-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathNetworkController.h
executable file
·47 lines (39 loc) · 1.04 KB
/
NetworkController.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
/*
* MenuTunes
* NetworkController.h
*
* Rendezvous network controller.
*
* Copyright (c) 2003 iThink Software
*
*/
#import <Foundation/Foundation.h>
#define SERVER_PORT 5712
@class NetworkObject;
@interface NetworkController : NSObject
{
NSNetService *service;
NSNetServiceBrowser *browser;
NSMutableArray *remoteServices;
NSConnection *serverConnection, *clientConnection;
NSSocketPort *clientPort, *serverPort;
NSString *remoteHost;
BOOL serverOn, clientConnected, connectedToServer;
NSData *serverPass, *clientPass;
NetworkObject *rootObject, *clientProxy;
}
+ (NetworkController *)sharedController;
- (void)startRemoteServerSearch;
- (void)stopRemoteServerSearch;
- (void)setServerStatus:(BOOL)status;
- (int)connectToHost:(NSString *)host;
- (BOOL)checkForServerAtHost:(NSString *)host;
- (BOOL)disconnect;
- (void)resetServerName;
- (BOOL)isServerOn;
- (BOOL)isClientConnected;
- (BOOL)isConnectedToServer;
- (NSString *)remoteHost;
- (NetworkObject *)networkObject;
- (NSArray *)remoteServices;
@end