use strict;
use warnings;
use Exporter;
-use Onis::Config qw#get_config#;
-use Onis::Data::Core qw(nick_to_ident);
-use Onis::Data::Persistent;
-
-@Onis::Users::EXPORT_OK = qw#host_to_username nick_to_username get_link get_image get_realname#;
+use Onis::Config (qw(get_config));
+use Onis::Data::Persistent ();
+
+@Onis::Users::EXPORT_OK =
+(qw(
+ ident_to_name chatter_to_name name_to_ident
+ get_realname get_link get_image
+));
@Onis::Users::ISA = ('Exporter');
=head1 NAME
=head1 USAGE
- use Onis::Users qw#ident_to_name chatter_to_name nick_to_name get_realname get_link get_image#;
+ use Onis::Users qw#ident_to_name chatter_to_name get_realname get_link get_image#;
# Functions to query the name
$name = ident_to_name ($ident);
$name = chatter_to_name ($chatter);
- $name = nick_to_name ($nick);
# Functions to query a name's properties
my $realname = get_realname ($name);
our $NameToIdent = {};
-my $VERSION = '$Id: Users.pm,v 1.2 2004/08/01 13:45:27 octo Exp $';
+my $VERSION = '$Id$';
print STDERR $/, __FILE__, ": $VERSION" if ($::DEBUG);
read_config ();
return (1);
+=head1 CONFIGURATION OPTIONS
+
+=over 4
+
+=item B<users_config>: I<users.conf>;
+
+Sets the file from which to read the user configuration.
+
+=back
+
+=cut
+
sub read_config
{
my $config_file = 'users.conf';
return (ident_to_name ($ident));
}
-=item B<nick_to_name> (I<$nick>)
-
-Return the name associated with I<$nick>. This function uses B<nick_to_ident>
-(see L<Onis::Data::Core>) to convert I<$nick> to an ident and then calls
-B<ident_to_name>.
-
-=cut
-
-sub nick_to_name
-{
- my $nick = shift;
- my $ident = nick_to_ident ($nick);
-
- if ($ident)
- {
- return (ident_to_name ($ident));
- }
- else
- {
- return ('');
- }
-}
-
=item B<name_to_ident> (I<$name>)
Does the reverse of B<ident_to_name>: Returns the most recent association of
=head1 AUTHOR
Florian octo Forster E<lt>octo at verplant.orgE<gt>
+
+=cut