diff options
author | cvsadm <cvsadm> | 2005-01-21 00:44:34 +0000 |
---|---|---|
committer | cvsadm <cvsadm> | 2005-01-21 00:44:34 +0000 |
commit | b2093e3016027d6b5cf06b3f91f30769bfc099e2 (patch) | |
tree | cf58939393a9032182c4fbc4441164a9456e82f8 /include/libaccess/dnfstruct.h | |
download | ds-ldapserver7x.tar.gz ds-ldapserver7x.tar.xz ds-ldapserver7x.zip |
Moving NSCP Directory Server from DirectoryBranch to TRUNK, initial drop. (foxworth)ldapserver7x
Diffstat (limited to 'include/libaccess/dnfstruct.h')
-rw-r--r-- | include/libaccess/dnfstruct.h | 51 |
1 files changed, 51 insertions, 0 deletions
diff --git a/include/libaccess/dnfstruct.h b/include/libaccess/dnfstruct.h new file mode 100644 index 00000000..d1ab28a3 --- /dev/null +++ b/include/libaccess/dnfstruct.h @@ -0,0 +1,51 @@ +/** BEGIN COPYRIGHT BLOCK + * Copyright 2001 Sun Microsystems, Inc. + * Portions copyright 1999, 2001-2003 Netscape Communications Corporation. + * All rights reserved. + * END COPYRIGHT BLOCK **/ +#ifndef __dnfstruct_h +#define __dnfstruct_h + +/* + * Description (dnfstruct_h) + * + * This file defines types and structures used to represent a DNS + * name filter in memory. A DNS name filter contains specifications + * of fully or partially qualified DNS names. Each of these + * specifications can be associated with whatever information is + * appropriate for a particular use of a DNS name filter. + */ + +#include "nspr.h" +#include "plhash.h" + +NSPR_BEGIN_EXTERN_C + +/* + * Description (DNSLeaf_t) + * + * This type describes the structure of information associated with + * an entry in a DNS filter. The filter itself is implemented as a + * hash table, keyed by the DNS name specification string. The + * value associated with a key is a pointer to a DNSLeaf_t structure. + */ + +typedef struct DNSLeaf_s DNSLeaf_t; +struct DNSLeaf_s { + PLHashEntry dnl_he; /* NSPR hash table entry */ +}; + +#define dnl_next dnl_he.next /* hash table collision link */ +#define dnl_keyhash dnl_he.keyHash /* symbol hash value */ +#define dnl_key dnl_he.key /* pointer to Symbol_t structure */ +#define dnl_ref dnl_he.value /* pointer to named structure */ + +typedef struct DNSFilter_s DNSFilter_t; +struct DNSFilter_s { + DNSFilter_t * dnf_next; /* link to next filter */ + void * dnf_hash; /* pointer to constructed hash table */ +}; + +NSPR_END_EXTERN_C + +#endif /* __dnfstruct_h */ |