1Net::LDAP::Control::PerUssiesrteCnotnSterairbcuht(e3d)PNeertl::DLoDcAuPm:e:nCtoanttiroonl::PersistentSearch(3)
2
3
4
6 Net::LDAP::Control::PersistentSearch - LDAPv3 Persistent Search control
7 object
8
10 use Net::LDAP;
11 use Net::LDAP::Control::PersistentSearch;
12
13 $ldap = Net::LDAP->new( "ldap.mydomain.eg" );
14
15 $persist = Net::LDAP::Control::PersistentSearch->new( changeTypes => 15,
16 changesOnly => 1,
17 returnECs => 1 );
18
19 $srch = $ldap->search( base => "cn=People,dc=mydomain,dc=eg",
20 filter => "(objectClass=person)",
21 callback => \&process_entry, # call for each entry
22 control => [ $persist ] );
23
24 die "error: ",$srch->code(),": ",$srch->error() if ($srch->code());
25
26 sub process_entry {
27 my $message = shift;
28 my $entry = shift;
29
30 print $entry->dn()."\n";
31
32 # reduce memory usage
33 $message->pop_entry();
34 }
35
37 "Net::LDAP::Control::PersistentSearch" provides an interface for the
38 creation and manipulation of objects that represent the
39 "PersistentSearch" control as described by
40 draft-smith-psearch-ldap-03.txt.
41
43 In addition to the constructor arguments described in
44 Net::LDAP::Control the following are provided.
45
46 changeTypes
47 An integer value determining the types of changes to look out for.
48 It is the bitwise OR of the following values (which represent the
49 LDAP operations indicated next to them):
50
51 1 = add
52 2 = delete
53 4 = modify
54 8 = modDN
55
56 If it is not given it defaults to 15 meaning all changes.
57
58 changesOnly
59 A Boolean value telling whether the server may return entries that
60 match the search criteria.
61
62 If "TRUE" the server must not return any existing entries that
63 match the search criteria. Entries are only returned when they are
64 changed (added, modified, deleted, or subject to a modifyDN
65 operation)
66
67 returnECs
68 If "TRUE", the server must return an Entry Change Notification
69 control with each entry returned as the result of changes.
70
71 See Net::LDAP::Control::EntryChange for details.
72
74 As with Net::LDAP::Control each constructor argument described above is
75 also available as a method on the object which will return the current
76 value for the attribute if called without an argument, and set a new
77 value for the attribute if called with an argument.
78
80 Net::LDAP, Net::LDAP::Control, Net::LDAP::Control::EntryChange
81
83 Peter Marschall <peter@adpm.de>, based on Net::LDAP::Control::Page from
84 Graham Barr <gbarr@pobox.com> and the preparatory work of Don Miller
85 <donm@uidaho.edu>.
86
87 Please report any bugs, or post any suggestions, to the perl-ldap
88 mailing list <perl-ldap@perl.org>
89
91 Copyright (c) 2004 Peter Marschall. All rights reserved. This program
92 is free software; you can redistribute it and/or modify it under the
93 same terms as Perl itself.
94
95
96
97perl v5.32.1 2021-0N2e-t1:6:LDAP::Control::PersistentSearch(3)