# phpman > perldoc > Net::LDAP::Reference

## NAME
    [Net::LDAP::Reference](https://www.chedong.com/phpMan.php/perldoc/Net%3A%3ALDAP%3A%3AReference/markdown) - search reference

## SYNOPSIS
      use [Net::LDAP](https://www.chedong.com/phpMan.php/perldoc/Net%3A%3ALDAP/markdown);

      $ldap->search( @search_args, callback => \&process);

      sub process {
        my $mesg = shift;
        my $obj = shift;
        if (!$obj) {
          # Search complete
        }
        elsif ($obj->isa('[Net::LDAP::Reference](https://www.chedong.com/phpMan.php/perldoc/Net%3A%3ALDAP%3A%3AReference/markdown)')) {
          my $ref;

          foreach $ref ($obj->references) {
            # process ref
          }
        }
        else {
          # Process [Net::LDAP::Entry](https://www.chedong.com/phpMan.php/perldoc/Net%3A%3ALDAP%3A%3AEntry/markdown)
        }
      }

## DESCRIPTION
    The [Net::LDAP::Reference](https://www.chedong.com/phpMan.php/perldoc/Net%3A%3ALDAP%3A%3AReference/markdown) object represents a reference (sometimes called a "referral") returned
    by the directory from a search.

## METHODS
    references
        Returns a list of references from the server.

## SEE ALSO
    [Net::LDAP](https://www.chedong.com/phpMan.php/perldoc/Net%3A%3ALDAP/markdown), [Net::LDAP::Search](https://www.chedong.com/phpMan.php/perldoc/Net%3A%3ALDAP%3A%3ASearch/markdown)

## AUTHOR
    Graham Barr <<gbarr@pobox.com>>.

    Please report any bugs, or post any suggestions, to the perl-ldap mailing list
    <<perl-ldap@perl.org>>.

## COPYRIGHT
    Copyright (c) 1997-2004 Graham Barr. All rights reserved. This program is free software; you can
    redistribute it and/or modify it under the same terms as Perl itself.

