| 1 | package Net::NicoVideo::Content::MylistPage; | ||||||||||
| 2 | |||||||||||
| 3 | 1 | ▶ | use strict; | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 4 | 1 | ▶ | use warnings; | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 5 | 1 | ▶ | use vars qw($VERSION); | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 6 | 1 | $VERSION = '0.28'; | |||||||||
| 7 | |||||||||||
| 8 | 1 | ▶ | use base qw(Net::NicoVideo::Content Class::Accessor::Fast); | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 9 | |||||||||||
| 10 | 1 | ▶ | use vars qw(@Members); | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 11 | 1 | @Members = qw( | |||||||||
| 12 | token | ||||||||||
| 13 | ); | ||||||||||
| 14 | |||||||||||
| 15 | 1 | __PACKAGE__->mk_accessors(@Members); | |||||||||
| 16 | |||||||||||
| 17 | 0 | ▶ | sub members { # implement | ||||||||
|
Subroutine
members: not called CC=1 SCAR=6.9
Pod
undocumented
| |||||||||||
| 18 | 0 | my @copy = @Members; | |||||||||
| 19 | 0 | @copy; | |||||||||
| 20 | } | ||||||||||
| 21 | |||||||||||
| 22 | 0 | ▶ | sub parse { # implement | ||||||||
|
Subroutine
parse: not called CC=4 SCAR=30.0
Pod
undocumented
| |||||||||||
| 23 | 0 | my $self = shift; | |||||||||
| 24 | 0 | ▶ | $self->load($_[0]) if( defined $_[0] ); | ||||||||
|
Branch: 1 branch
| |||||||||||
| 25 | |||||||||||
| 26 | 0 | my $content = $self->_decoded_content; | |||||||||
| 27 | 0 | ▶ | if( $content =~ /NicoAPI\.token\s*=\s*"([-\w]+)"/ ){ | ||||||||
|
Branch: 1 branch
| |||||||||||
| 28 | 0 | $self->token( $1 ); | |||||||||
| 29 | } | ||||||||||
| 30 | |||||||||||
| 31 | # status | ||||||||||
| 32 | 0 | ▶ | if( $self->token ){ | ||||||||
|
Branch: 1 branch
| |||||||||||
| 33 | 0 | $self->set_status_success; | |||||||||
| 34 | }else{ | ||||||||||
| 35 | 0 | $self->set_status_error; | |||||||||
| 36 | } | ||||||||||
| 37 | |||||||||||
| 38 | 0 | return $self; | |||||||||
| 39 | } | ||||||||||
| 40 | |||||||||||
| 41 | |||||||||||
| 42 | 1 | 1; | |||||||||
| 43 | __END__ | ||||||||||