Bonjour/MYBonjourQuery.h
author morrowa
Thu Jul 02 20:45:11 2009 -0700 (2009-07-02)
changeset 57 998dcacd4983
permissions -rw-r--r--
Merged Jens' latest changes.
     1 //
     2 //  MYBonjourQuery.h
     3 //  MYNetwork
     4 //
     5 //  Created by Jens Alfke on 4/24/09.
     6 //  Copyright 2009 Jens Alfke. All rights reserved.
     7 //
     8 
     9 #import "MYDNSService.h"
    10 @class MYBonjourService;
    11 
    12 
    13 /** A query for a particular DNS record (TXT, NULL, etc.) of a Bonjour service.
    14     This class is used internally by MYBonjourService to track the TXT record;
    15     you won't need to use it directly, unless you're interested in the contents of some other
    16     record (such as the NULL record that iChat's _presence._tcp service uses for buddy icons.) */
    17 @interface MYBonjourQuery : MYDNSService 
    18 {
    19     @private
    20     MYBonjourService *_bonjourService;
    21     uint16_t _recordType;
    22     NSData *_recordData;
    23 }
    24 
    25 /** Initializes a query for a particular service and record type.
    26     @param service  The Bonjour service to query
    27     @param recordType  The DNS record type, e.g. kDNSServiceType_TXT; see the enum in <dns_sd.h>. */
    28 - (id) initWithBonjourService: (MYBonjourService*)service 
    29                    recordType: (uint16_t)recordType;
    30 
    31 /** The data of the DNS record, once it's been found.
    32     This property is KV-observable. */
    33 @property (readonly,copy) NSData *recordData;
    34 
    35 @end