HTTPServer.h.svn-base
上传用户:kc0325
上传日期:2020-06-20
资源大小:204k
文件大小:1k
源码类别:

iPhone

开发平台:

Objective-C

  1. #import <Foundation/Foundation.h>
  2. @class AsyncSocket;
  3. @interface HTTPServer : NSObject
  4. {
  5. // Underlying asynchronous TCP/IP socket
  6. AsyncSocket *asyncSocket;
  7. // Standard delegate
  8. id delegate;
  9. // HTTP server configuration
  10. NSURL *documentRoot;
  11. Class connectionClass;
  12. // NSNetService and related variables
  13. NSNetService *netService;
  14.     NSString *domain;
  15. NSString *type;
  16.     NSString *name;
  17. UInt16 port;
  18. NSDictionary *txtRecordDictionary;
  19. NSMutableArray *connections;
  20. }
  21. - (id)delegate;
  22. - (void)setDelegate:(id)newDelegate;
  23. - (NSURL *)documentRoot;
  24. - (void)setDocumentRoot:(NSURL *)value;
  25. - (Class)connectionClass;
  26. - (void)setConnectionClass:(Class)value;
  27. - (NSString *)domain;
  28. - (void)setDomain:(NSString *)value;
  29. - (NSString *)type;
  30. - (void)setType:(NSString *)value;
  31. - (NSString *)name;
  32. - (void)setName:(NSString *)value;
  33. - (UInt16)port;
  34. - (void)setPort:(UInt16)value;
  35. - (NSDictionary *)TXTRecordDictionary;
  36. - (void)setTXTRecordDictionary:(NSDictionary *)dict;
  37. - (BOOL)start:(NSError **)error;
  38. - (BOOL)stop;
  39. - (int)numberOfHTTPConnections;
  40. @end