=head1 NAME

afsperlcell - Cell configuration functions

=head1 SYNOPIS

   use AFS;              # import all AFS names
   use AFS @AFS::CELL;   # import just the cell config names

   configdir
   expandcell
   getcell
   getcellinfo
   localcell

=head1 DESCRIPTION

This document describes the cell configuration functions
available in the AFS module.

=head1 configdir

  $configdir = configdir;
  $ok = configdir($dir);
  
  Get/Set configuration directory. Default is /usr/vice/etc. 

=head2 EXAMPLES

   $dir = configdir;

=head1 expandcell

  Expands cell to fully qualified cellname. Returns undef on error.

=head2 EXAMPLES

  $cellname = expandcell($cell);

=head1 getcell

  ($cell, @servers)  = getcell($index [,$ip=0]);

  Iterates through the Cache Manager's internal cell configuration,
  using $index as an index. The index starts at 0. $AFS::CODE will
  be set to a non-zero value when passed an invalid index. If $ip is
  set to 1 then IP addresses will be returned instead of hostnames.

  This call probably belongs with the cache manager returns, but is
  listed here since it deals with cell information.

=head2 EXAMPLES

  $index = 0;
  while ( ($cell, @servers)  = getcell($index) ) {
      printf "cell $cell\n";
      foreach $host (@hosts) {
           printf(" $host\n");
      }
  }

=head1 getcellinfo

  ($cell @servers) = getcellinfo([$cell [,$ip=0]]);

  Gets information on $cell using CellServDB. If $ip is
  set to 1 then IP addresses will be returned instead of hostnames.

=head2 EXAMPLES

  ($cell @servers) = getcellinfo(localcell);

=head1 localcell

  Returns local cellname. Returns undef on error.

=head2 EXAMPLES

  $cellname = localcell;

=head1 SEE ALSO

  afsperlcm    whichcell, wscell, setcellstatus, getcellstatus
  afsperlka    ka_CellToRealm, ka_ExpandCell, ka_LocalCell 

