IMDB::BaseClass(3pm) | User Contributed Perl Documentation | IMDB::BaseClass(3pm) |
IMDB::BaseClass - a base class for IMDB::Film and IMDB::Persons.
use base qw(IMDB::BaseClass);
IMDB::BaseClass implements a base functionality for IMDB::Film and IMDB::Persons.
my $imdb = new IMDB::Film(crit => <some code>);
or
my $imdb = new IMDB::Film(crit => <some title>);
Also, you can specify following optional parameters:
- proxy - define proxy server name and port; - debug - switch on debug mode (on by default); - cache - cache or not of content retrieved pages.
my $code = $film->code();
my $id = $film->id();
my $imdb = new IMDB::Film(code => 111111, proxy => 'my.proxy.host:8080');
or you can define environment variable 'http_host'. For exanple, for Linux you shoud do a following:
export http_proxy=my.proxy.host:8080
my $imdb = new IMDB::Film(code => 111111, cache => 1);
my $imdb = new IMDB::Film(code => 111111, cache => 1, clear_cache => 1);
my $imdb = new IMDB::Film(code => 111111, cache_exp => '1 h');
For more details please see Cache::Cache documentation.
my $imdb = new IMDB::Film(code => 111111, host => 'us.imdb.com');
By default, it uses 'www.imdb.com'.
my $imdb = new IMDB::Film(code => 111111, query => 'some significant string');
Default value is 'title/tt'.
Note: this is a mainly service parameter. So, there is no reason to pass it in the real case.
my $imdb = new IMDB::Film(code => 111111, seach => 'some significant string');
Default value is 'Find?select=Titles&for='.
my $imdb = new IMDB::Film(code => 111111, debug => 1);
By default debug mode is switched off.
my @matched = @{ $film->matched() };
Note: if movie was matched by title unambiguously it won't be present in this array!
my $errors = $film->error();
Nothing
Please, send me any found bugs by email: stepanov.michael@gmail.com.
IMDB::Persons IMDB::Film WWW::Yahoo::Movies HTML::TokeParser
Mikhail Stepanov AKA nite_man (stepanov.michael@gmail.com)
Copyright (c) 2004 - 2007, Mikhail Stepanov. This module is free software. It may be used, redistributed and/or modified under the same terms as Perl itself.
2021-01-07 | perl v5.32.0 |