module Ldap_ooclient: sig
.. end
an object oriented ldap client interface
type
op = string * string list
type
op_lst = op list
type
referral_policy = [ `FOLLOW | `RETURN ]
type
changetype = [ `ADD | `DELETE | `MODDN | `MODIFY | `MODRDN ]
class type ldapentry_t = object
.. end
class ldapentry :
object
.. end
this object represents a remote object within local memory.
val to_entry : [< `Entry of Ldap_types.search_result_entry | `Referral of string list ] ->
ldapentry
given a search_result_entry as returned by ldap_funclient, produce an
ldapentry containing either the entry, or the referral object
val of_entry : ldapentry -> Ldap_types.search_result_entry
given an ldapentry as returned by ldapcon, or constructed manually,
produce a search_result_entry suitable for ldap_funclient, or
ldap_funserver.
val iter : (ldapentry -> unit) ->
(unit -> ldapentry) -> unit
given a source of ldapentry objects (unit -> ldapentry), such as
the return value of ldapcon#search_a apply f (first arg) to each entry
See List.iter
val rev_map : (ldapentry -> 'a) ->
(unit -> ldapentry) -> 'a list
given a source of ldapentry objects (unit -> ldapentry), such as
the return value of ldapcon#search_a apply f (first arg) to each
entry in reverse, and return a list containing the result of each
application. See List.map
val map : (ldapentry -> 'a) ->
(unit -> ldapentry) -> 'a list
same as rev_map, but does it in order
val fold : ('a -> 'b -> 'b) -> 'b -> (unit -> 'a) -> 'b
given a source of ldapentry objects (unit -> ldapentry), such as
the return value of ldapcon#search_a compute (f eN ... (f e2 (f e1
intial))) see List.fold_right.
class ldapcon : ?referral_policy:[> `RETURN ] -> ?version:int -> string list ->
object
.. end
module OrdStr: sig
.. end
module Setstr: sig
.. end
type
scflavor =
| |
Optimistic |
| |
Pessimistic |
val attrToOid : Ldap_schemaparser.schema ->
Ldap_schemaparser.Lcstring.t -> Ldap_schemaparser.Oid.t
given a name of an attribute, return its oid
val oidToAttr : Ldap_schemaparser.schema -> Ldap_schemaparser.Oid.t -> string
given the oid of an attribute, return its canonical name
val ocToOid : Ldap_schemaparser.schema ->
Ldap_schemaparser.Lcstring.t -> Ldap_schemaparser.Oid.t
given a name of an objectclass, return its oid
val oidToOc : Ldap_schemaparser.schema -> Ldap_schemaparser.Oid.t -> string
given the oid of an objectclass, return its canonical name
val getOc : Ldap_schemaparser.schema ->
Ldap_schemaparser.Lcstring.t -> Ldap_schemaparser.objectclass
get an objectclass structure by one of its names
val getAttr : Ldap_schemaparser.schema ->
Ldap_schemaparser.Lcstring.t -> Ldap_schemaparser.attribute
get an attr structure by one of its names
val equateAttrs : Ldap_schemaparser.schema ->
Ldap_schemaparser.Lcstring.t -> Ldap_schemaparser.Lcstring.t -> bool
equate attributes by oid. This allows aliases to be handled
correctly, for example "uid" and "userID" are actually the same
attribute.
exception Invalid_objectclass of string
exception Invalid_attribute of string
exception Single_value of string
class scldapentry : Ldap_schemaparser.schema ->
object
.. end
type
generator = {
|
gen_name : string ; |
|
required : string list ; |
|
genfun : ldapentry_t -> string list ; |
}
type
service = {
|
svc_name : string ; |
|
static_attrs : (string * string list) list ; |
|
generate_attrs : string list ; |
|
depends : string list ; |
}
type
generation_error =
| |
Missing_required of string list |
| |
Generator_error of string |
exception No_generator of string
exception Generation_failed of generation_error
exception No_service of string
exception Service_dep_unsatisfiable of string
exception Generator_dep_unsatisfiable of string * string
exception Cannot_sort_dependancies of string list
class ldapaccount : Ldap_schemaparser.schema -> (string, generator) Hashtbl.t -> (string, service) Hashtbl.t ->
object
.. end