API-Handle
view release on metacpan or search on metacpan
lib/API/Handle/OpenX.pm view on Meta::CPAN
my $conf = $self->config;
$self->uri( $conf->{oauth}{api_url} );
# Uncomment this to view loaded configuration.
# $self->dumper( 'config', $conf );
# Steal UA from lib provided by OpenX.
my $oauth = new OX::OAuth ( $conf->{oauth} );
$oauth->login or carp $oauth->error;
$oauth->token or carp "no oauth token?";
$self->ua( $oauth->{_ua} );
# Put code that pre-empts API::Handle::BUILD before this $prev line.
$prev = $self->$next( @args );
# Put code that depends on API::Handle::BUILD after this $prev line.
# Setup match-spec vars for request_prepare.
my ( $scheme, $host, $path ) = $self->uri =~ /^(https?):\/\/([^\/]+)(\/.+)$/;
( run in 1.171 second using v1.01-cache-2.11-cpan-49f99fa48dc )