/* Definitions for the LDAP client interface for XEmacs. Copyright (C) 1998 Free Software Foundation, Inc.This file is part of XEmacs.XEmacs is free software; you can redistribute it and/or modify itunder the terms of the GNU General Public License as published by theFree Software Foundation; either version 2, or (at your option) anylater version.XEmacs is distributed in the hope that it will be useful, but WITHOUTANY WARRANTY; without even the implied warranty of MERCHANTABILITY orFITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public Licensefor more details.You should have received a copy of the GNU General Public Licensealong with XEmacs; see the file COPYING. If not, write tothe Free Software Foundation, Inc., 59 Temple Place - Suite 330,Boston, MA 02111-1307, USA. */#ifndef _XEMACS_ELDAP_H_#define _XEMACS_ELDAP_H_#include <lber.h>#include <ldap.h>/* * The following structure records pertinent information about a * LDAP connection. */structLisp_LDAP{/* lcrecord header */structlcrecord_headerheader;/* The LDAP connection handle used by the LDAP API */LDAP*ld;/* Name of the host we connected to */Lisp_Objecthost;};DECLARE_LRECORD(ldap,structLisp_LDAP);#define XLDAP(x) XRECORD (x, ldap, struct Lisp_LDAP)#define XSETLDAP(x, p) XSETRECORD (x, p, ldap)#define LDAPP(x) RECORDP (x, ldap)#define GC_LDAPP(x) GC_RECORDP (x, ldap)#define CHECK_LDAP(x) CHECK_RECORD (x, ldap)#define CONCHECK_LDAP(x) CONCHECK_RECORD (x, ldap)#define CHECK_LIVE_LDAP(ldap) do { \ CHECK_LDAP (ldap); \ if (!XLDAP (ldap)->ld) \ signal_simple_error ("Attempting to access closed LDAP connection", \ ldap); \} while (0)Lisp_ObjectFldapp(Lisp_Objectobject);Lisp_ObjectFldap_host(Lisp_Objectldap);Lisp_ObjectFldap_status(Lisp_Objectldap);Lisp_ObjectFldap_open(Lisp_Objecthost,Lisp_Objectldap_plist);Lisp_ObjectFldap_close(Lisp_Objectldap);Lisp_ObjectFldap_search_internal(Lisp_Objectldap,Lisp_Objectfilter,Lisp_Objectbase,Lisp_Objectscope,Lisp_Objectattrs,Lisp_Objectattrsonly);#endif /* _XEMACS_ELDAP_H_ */