| 1 | package WWW::VastAI::Object; | ||
| 2 | 11 | our $VERSION = '0.001'; | |
| 3 | # ABSTRACT: Base entity wrapper for Vast.ai API resources | ||
| 4 | |||
| 5 | 11 | ▶ | use Moo; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 6 | |||
| 7 | 11 | has _client => ( | |
| 8 | is => 'ro', | ||
| 9 | required => 1, | ||
| 10 | weak_ref => 1, | ||
| 11 | init_arg => 'client', | ||
| 12 | ); | ||
| 13 | |||
| 14 | 11 | has data => ( | |
| 15 | is => 'rw', | ||
| 16 | required => 1, | ||
| 17 | ); | ||
| 18 | |||
| 19 | 21 | ▶ | sub id { shift->data->{id} } |
|
Subroutine
id: called CC=1 SCAR=0.0
Pod
documented
| |||
| 20 | 4 | ▶ | sub raw { shift->data } |
|
Subroutine
raw: called CC=1 SCAR=0.0
Pod
documented
| |||
| 21 | |||
| 22 | 3 | ▶ | sub _replace_data { |
|
Subroutine
_replace_data: called CC=1 SCAR=0.0
| |||
| 23 | 3 | my ($self, $data) = @_; | |
| 24 | 3 | $self->data($data); | |
| 25 | 3 | return $self; | |
| 26 | } | ||
| 27 | |||
| 28 | 11 | 1; | |
| 29 | |||
| 30 | __END__ | ||