libwww-perl-5.813 > WWW::RobotRules::AnyDBM_File
libwww-perl-5.813

名前

WWW::RobotRules::AnyDBM_File - Persistent RobotRules

WWW::RobotRules::AnyDBM_File - 永続 RobotRules

概要

 require WWW::RobotRules::AnyDBM_File;
 require LWP::RobotUA;

 # Create a robot useragent that uses a diskcaching RobotRules
 my $rules = new WWW::RobotRules::AnyDBM_File 'my-robot/1.0', 'cachefile';
 my $ua = new WWW::RobotUA 'my-robot/1.0', 'me@foo.com', $rules;

 # Then just use $ua as usual
 $res = $ua->request($req);

説明

This is a subclass of WWW::RobotRules that uses the AnyDBM_File package to implement persistent diskcaching of robots.txt and host visit information.

これは robots.txt とホスト訪問情報の永続的なディスク・キャッシュを 実装するために AnyDBM_File パッケージを使う WWW::RobotRules の サブクラスです。

The constructor (the new() method) takes an extra argument specifying the name of the DBM file to use. If the DBM file already exists, then you can specify undef as agent name as the name can be obtained from the DBM database.

コンストラクタ(new() メソッド)は使用する DBM ファイルの名前を指定する 特別な引数を取ります。 もし DBM ファイルが既にあれば、DBM データベースから名前を取得することが 出来るので、エージェント名に undef を指定することが出来ます。

SEE ALSO

WWW::RobotRules, LWP::RobotUA

作者

Hakan Ardo <hakan@munin.ub2.lu.se>, Gisle Aas <aas@sn.no>