lwsearch.h revision ab023a65562e62b85a824509d829b6fad87e00b1
/*
* Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC")
* Copyright (C) 2000, 2001 Internet Software Consortium.
*
* Permission to use, copy, modify, and distribute this software for any
* purpose with or without fee is hereby granted, provided that the above
* copyright notice and this permission notice appear in all copies.
*
* THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH
* REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
* AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
* INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
* LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
* OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
* PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: lwsearch.h,v 1.6 2005/04/27 04:55:59 sra Exp $ */
#ifndef NAMED_LWSEARCH_H
#define NAMED_LWSEARCH_H 1
/*! \file
* \brief
* Lightweight resolver search list types and routines.
*
* An ns_lwsearchlist_t holds a list of search path elements.
*
* An ns_lwsearchctx stores the state of search list during a lookup
* operation.
*/
/*% An ns_lwsearchlist_t holds a list of search path elements. */
struct ns_lwsearchlist {
unsigned int magic;
unsigned int refs;
};
/*% An ns_lwsearchctx stores the state of search list during a lookup operation. */
struct ns_lwsearchctx {
unsigned int ndots;
};
/*%<
* Create an empty search list object.
*/
void
/*%<
* Attach to a search list object.
*/
void
/*%<
* Detach from a search list object.
*/
/*%<
* Append an element to a search list. This creates a copy of the name.
*/
void
/*%<
* Creates a search list context structure.
*/
void
/*%<
* Moves the search list context iterator to the first element, which
* is usually the exact name.
*/
/*%<
* Moves the search list context iterator to the next element.
*/
/*%<
* Obtains the current name to be looked up. This involves either
* concatenating the name with a search path element, making an
* exact name absolute, or doing nothing.
*/
#endif /* NAMED_LWSEARCH_H */