2 // ITServiceBrowserDelegate.m
5 // Created by Alexander Strange on Sat Mar 15 2003.
6 // Copyright (c) 2003 __MyCompanyName__. All rights reserved.
9 #import "ITServiceBrowserDelegate.h"
10 #import "ITInetSocket.h"
11 #import <Foundation/NSNetServices.h>
13 @implementation ITServiceBrowserDelegate
14 - (id) initWithDelegate:(id)_delegate
16 if (self = [super init])
23 - (void)netServiceBrowser:(NSNetServiceBrowser *)aNetServiceBrowser didFindService:(NSNetService *)aNetService moreComing:(BOOL)moreComing
28 [aNetServiceBrowser stop];
29 [aNetServiceBrowser release];
32 sock = [[ITInetSocket alloc] initWithDelegate:delegate];
33 NSLog(@"Detected a service! name %@ type %@",[aNetService name],[aNetService type]);
34 [sock connectWithSockaddrArray:[aNetService addresses]];