| line | stmt | bran | cond | sub | pod | time | code | 
| 1 |  |  |  |  |  |  | package WWW::TypePad::Error; | 
| 2 | 1 |  |  | 1 |  | 5 | use strict; | 
|  | 1 |  |  |  |  | 1 |  | 
|  | 1 |  |  |  |  | 29 |  | 
| 3 |  |  |  |  |  |  |  | 
| 4 | 1 |  |  | 1 |  | 4 | use Any::Moose; | 
|  | 1 |  |  |  |  | 1 |  | 
|  | 1 |  |  |  |  | 9 |  | 
| 5 |  |  |  |  |  |  |  | 
| 6 |  |  |  |  |  |  | sub throw { | 
| 7 | 0 |  |  | 0 | 0 |  | my( $class, @rest ) = @_; | 
| 8 | 0 |  |  |  |  |  | die $class->new( @rest ); | 
| 9 |  |  |  |  |  |  | } | 
| 10 |  |  |  |  |  |  |  | 
| 11 |  |  |  |  |  |  | package WWW::TypePad::Error::HTTP; | 
| 12 | 1 |  |  | 1 |  | 566 | use Any::Moose; | 
|  | 1 |  |  |  |  | 2 |  | 
|  | 1 |  |  |  |  | 3 |  | 
| 13 | 1 |  |  | 1 |  | 345 | use HTTP::Status; | 
|  | 1 |  |  |  |  | 8 |  | 
|  | 1 |  |  |  |  | 277 |  | 
| 14 |  |  |  |  |  |  | extends 'WWW::TypePad::Error'; | 
| 15 |  |  |  |  |  |  |  | 
| 16 | 1 |  |  | 1 |  | 5 | use overload q("") => sub { $_[0]->message }, fallback => 1; | 
|  | 1 |  |  | 0 |  | 1 |  | 
|  | 1 |  |  |  |  | 8 |  | 
|  | 0 |  |  |  |  |  |  | 
| 17 |  |  |  |  |  |  | has code => ( is => 'rw', isa => 'Int' ); | 
| 18 |  |  |  |  |  |  | has message => ( is => 'rw', isa => 'Str' ); | 
| 19 |  |  |  |  |  |  |  | 
| 20 |  |  |  |  |  |  | around BUILDARGS => sub { | 
| 21 |  |  |  |  |  |  | my $orig = shift; | 
| 22 |  |  |  |  |  |  | my( $class, $code, $msg ) = @_; | 
| 23 |  |  |  |  |  |  | $msg ||= HTTP::Status::status_message( $code ); | 
| 24 |  |  |  |  |  |  | $class->$orig( code => $code, message => $msg ); | 
| 25 |  |  |  |  |  |  | }; | 
| 26 |  |  |  |  |  |  |  | 
| 27 |  |  |  |  |  |  | package WWW::TypePad::Error; | 
| 28 |  |  |  |  |  |  |  | 
| 29 |  |  |  |  |  |  | 1; |