* scheme/types.scm (ldap-session=?): new function

(ldap-message=?): ditto
(ldap-entry=?): ditto
This commit is contained in:
eknauel 2004-02-13 10:05:37 +00:00
parent 0af7276054
commit 4e107b0a11
1 changed files with 11 additions and 0 deletions

View File

@ -27,6 +27,9 @@
(define (ldap-session-messages-member? session message)
(memq message (ldap-session-messages session)))
(define (ldap-session=? session-a session-b)
(equal? (ldap-session-c-pointer session-a)
(ldap-session-c-pointer session-b)))
;;; This is the basic type
(define-record-type ldap-message :ldap-message
@ -36,6 +39,10 @@
(define-exported-binding "ldap-message" :ldap-message)
(define (ldap-message=? session-a session-b)
(equal? (ldap-message-c-pointer session-a)
(ldap-message-c-pointer session-b)))
;;; The C api does not distinguish ldap-message, ldap-entry and
;;; ldap-attribute as types, they all have the type LDAPMessage. We
;;; do.
@ -44,6 +51,10 @@
ldap-entry?
(message ldap-entry-message))
(define (ldap-entry=? entry-a entry-b)
(ldap-message=? (ldap-entry-message entry-a)
(ldap-entry-message entry-b)))
(define-record-type ldap-modification :ldap-modification
(make-ldap-modification c-pointer)
ldap-modification?