WWW::Dictionary - Interface with www.dictionary.com
Version 0.01
use WWW::Dictionary; my $dictionary = WWW::Dictionary->new(); my $meaning = $dictionary->meaning( $word );
Creates a new WWW::Dictionary object.
If passed an expression, sets that expression to the current one.
my $dictionary = WWW::Dictionary->new();
or
my $dictionary = WWW::Dictionary->new('current expression');
Sets the current expression to look for (doesn't look, merely sets the expression).
$dictionary->set_expression('new expression');
Returns the same expression.
Returns the current expression.
my $expression = $dictionary->get_expression();
Returns the meaning of the current expression by fetching from www.dictionary.com.
If the expression has already been fetched (if it still has the information stored), returns what is already on memory.
my $meaning = $dictionary->get_meaning();
You can also pass a new expression, which is set to be the current expression before fetching is made:
my $meaning = $dictionary->get_meaning('some other expression');
Sets a meaning in the object dictionary.
$dictionary->set_meaning( $word, $meaning );
From this point on (until a reset_dictionary is called), retrieving the meaning of $word will return whatever was on $meaning.
reset_dictionary
Returns the current dictionary inside the object.
my %dictionary = %{ $dictionary->get_dictionary };
Resets the current dictionary.
$dictionary->reset_dictionary;
Jose Castro, <cog at cpan.org>
<cog at cpan.org>
Please report any bugs or feature requests to bug-www-dictionary at rt.cpan.org, or through the web interface at http://rt.cpan.org/NoAuth/ReportBug.html?Queue=WWW-Dictionary. I will be notified, and then you'll automatically be notified of progress on your bug as I make changes.
bug-www-dictionary at rt.cpan.org
You can find documentation for this module with the perldoc command.
perldoc WWW::Dictionary
You can also look for information at:
AnnoCPAN: Annotated CPAN documentation
http://annocpan.org/dist/WWW-Dictionary
CPAN Ratings
http://cpanratings.perl.org/d/WWW-Dictionary
RT: CPAN's request tracker
http://rt.cpan.org/NoAuth/Bugs.html?Dist=WWW-Dictionary
Search CPAN
http://search.cpan.org/dist/WWW-Dictionary
Copyright 2005 Jose Castro, all rights reserved.
This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
To install WWW::Dictionary, copy and paste the appropriate command in to your terminal.
cpanm
cpanm WWW::Dictionary
CPAN shell
perl -MCPAN -e shell install WWW::Dictionary
For more information on module installation, please visit the detailed CPAN module installation guide.