| 1 | ##---------------------------------------------------------------------------- | ||||||||||
| 2 | ## Meta CPAN API - ~/lib/Net/API/CPAN/Cve.pm | ||||||||||
| 3 | ## Version v0.1.0 | ||||||||||
| 4 | ## Copyright(c) 2023 DEGUEST Pte. Ltd. | ||||||||||
| 5 | ## Author: Jacques Deguest <jack@deguest.jp> | ||||||||||
| 6 | ## Created 2023/07/25 | ||||||||||
| 7 | ## Modified 2023/09/26 | ||||||||||
| 8 | ## All rights reserved | ||||||||||
| 9 | ## | ||||||||||
| 10 | ## | ||||||||||
| 11 | ## This program is free software; you can redistribute it and/or modify it | ||||||||||
| 12 | ## under the same terms as Perl itself. | ||||||||||
| 13 | ##---------------------------------------------------------------------------- | ||||||||||
| 14 | # This module file has been automatically generated. Any change made here will be lost. | ||||||||||
| 15 | # Edit the script in ./build/build_modules.pl instead | ||||||||||
| 16 | package Net::API::CPAN::Cve; | ||||||||||
| 17 | BEGIN | ||||||||||
| 18 | { | ||||||||||
| 19 | 2 | ▶ | use strict; | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 20 | 2 | ▶ | use warnings; | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 21 | 2 | ▶ | use parent qw( Net::API::CPAN::Generic ); | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 22 | 2 | ▶ | use vars qw( $VERSION ); | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 23 | 2 | ▶ | our $VERSION = 'v0.1.0'; | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 24 | }; | ||||||||||
| 25 | |||||||||||
| 26 | 2 | ▶ | use strict; | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 27 | 2 | ▶ | use warnings; | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 28 | |||||||||||
| 29 | sub init | ||||||||||
| 30 | { | ||||||||||
| 31 | 1 | ▶ | my $self = shift( @_ ); | ||||||||
|
Subroutine
init: called CC=12 SCAR=27.2
Pod
documented
| |||||||||||
| 32 | 1 | ▶ | $self->{affected_versions} = undef unless( CORE::exists( $self->{affected_versions} ) ); | ||||||||
|
Branch: 1 branch
| |||||||||||
| 33 | 1 | ▶ | $self->{cpansa_id} = undef unless( CORE::exists( $self->{cpansa_id} ) ); | ||||||||
|
Branch: 1 branch
| |||||||||||
| 34 | 1 | ▶ | $self->{cves} = undef unless( CORE::exists( $self->{cves} ) ); | ||||||||
|
Branch: 1 branch
| |||||||||||
| 35 | 1 | ▶ | $self->{description} = undef unless( CORE::exists( $self->{description} ) ); | ||||||||
|
Branch: 1 branch
| |||||||||||
| 36 | 1 | ▶ | $self->{distribution} = undef unless( CORE::exists( $self->{distribution} ) ); | ||||||||
|
Branch: 1 branch
| |||||||||||
| 37 | 1 | $self->{object} = 'cve'; | |||||||||
| 38 | 1 | ▶ | $self->{references} = undef unless( CORE::exists( $self->{references} ) ); | ||||||||
|
Branch: 1 branch
| |||||||||||
| 39 | 1 | ▶ | $self->{releases} = undef unless( CORE::exists( $self->{releases} ) ); | ||||||||
|
Branch: 1 branch
| |||||||||||
| 40 | 1 | ▶ | $self->{reported} = undef unless( CORE::exists( $self->{reported} ) ); | ||||||||
|
Branch: 1 branch
| |||||||||||
| 41 | 1 | ▶ | $self->{severity} = undef unless( CORE::exists( $self->{severity} ) ); | ||||||||
|
Branch: 1 branch
| |||||||||||
| 42 | 1 | ▶ | $self->{versions} = undef unless( CORE::exists( $self->{versions} ) ); | ||||||||
|
Branch: 1 branch
| |||||||||||
| 43 | 1 | $self->{_init_strict_use_sub} = 1; | |||||||||
| 44 | 1 | $self->{_exception_class} = 'Net::API::CPAN::Exception'; | |||||||||
| 45 | 1 | ▶ | $self->SUPER::init( @_ ) || return( $self->pass_error ); | ||||||||
|
Branch: 1 branch
| |||||||||||
| 46 | 1 | $self->{fields} = [qw( | |||||||||
| 47 | affected_versions cpansa_id cves description distribution references releases | ||||||||||
| 48 | reported severity versions | ||||||||||
| 49 | )]; | ||||||||||
| 50 | 1 | return( $self ); | |||||||||
| 51 | } | ||||||||||
| 52 | |||||||||||
| 53 | 1 | ▶ | sub affected_versions { return( shift->_set_get_scalar_as_object( 'affected_versions', @_ ) ); } | ||||||||
|
Subroutine
affected_versions: called CC=1 SCAR=0.0
Pod
documented
| |||||||||||
| 54 | |||||||||||
| 55 | 1 | ▶ | sub cpansa_id { return( shift->_set_get_scalar_as_object( 'cpansa_id', @_ ) ); } | ||||||||
|
Subroutine
cpansa_id: called CC=1 SCAR=0.0
Pod
documented
| |||||||||||
| 56 | |||||||||||
| 57 | 1 | ▶ | sub cves { return( shift->_set_get_scalar_as_object( 'cves', @_ ) ); } | ||||||||
|
Subroutine
cves: called CC=1 SCAR=0.0
Pod
documented
| |||||||||||
| 58 | |||||||||||
| 59 | 1 | ▶ | sub description { return( shift->_set_get_scalar_as_object( 'description', @_ ) ); } | ||||||||
|
Subroutine
description: called CC=1 SCAR=0.0
Pod
documented
| |||||||||||
| 60 | |||||||||||
| 61 | 1 | ▶ | sub distribution { return( shift->_set_get_scalar_as_object( 'distribution', @_ ) ); } | ||||||||
|
Subroutine
distribution: called CC=1 SCAR=0.0
Pod
documented
| |||||||||||
| 62 | |||||||||||
| 63 | 0 | ▶ | sub object { return( shift->_set_get_scalar_as_object( 'object', @_ ) ); } | ||||||||
|
Subroutine
object: not called CC=1 SCAR=6.9
Pod
documented
| |||||||||||
| 64 | |||||||||||
| 65 | 1 | ▶ | sub references { return( shift->_set_get_scalar_as_object( 'references', @_ ) ); } | ||||||||
|
Subroutine
references: called CC=1 SCAR=0.0
Pod
documented
| |||||||||||
| 66 | |||||||||||
| 67 | 1 | ▶ | sub releases { return( shift->_set_get_scalar_as_object( 'releases', @_ ) ); } | ||||||||
|
Subroutine
releases: called CC=1 SCAR=0.0
Pod
documented
| |||||||||||
| 68 | |||||||||||
| 69 | 1 | ▶ | sub reported { return( shift->_set_get_datetime( 'reported', @_ ) ); } | ||||||||
|
Subroutine
reported: called CC=1 SCAR=0.0
Pod
documented
| |||||||||||
| 70 | |||||||||||
| 71 | 1 | ▶ | sub severity { return( shift->_set_get_scalar_as_object( 'severity', @_ ) ); } | ||||||||
|
Subroutine
severity: called CC=1 SCAR=0.0
Pod
documented
| |||||||||||
| 72 | |||||||||||
| 73 | 1 | ▶ | sub versions { return( shift->_set_get_scalar_as_object( 'versions', @_ ) ); } | ||||||||
|
Subroutine
versions: called CC=1 SCAR=0.0
Pod
documented
| |||||||||||
| 74 | |||||||||||
| 75 | 2 | 1; | |||||||||
| 76 | # NOTE: POD | ||||||||||
| 77 | __END__ | ||||||||||
| 78 | |||||||||||
| 79 | =encoding utf-8 | ||||||||||
| 80 | |||||||||||
| 81 | =head1 NAME | ||||||||||
| 82 | |||||||||||
| 83 | Net::API::CPAN::Cve - Meta CPAN API Cve Class | ||||||||||
| 84 | |||||||||||
| 85 | =head1 SYNOPSIS | ||||||||||
| 86 | |||||||||||
| 87 | use Net::API::CPAN::Cve; | ||||||||||
| 88 | my $string = $obj->affected_versions; | ||||||||||
| 89 | my $string = $obj->cpansa_id; | ||||||||||
| 90 | my $string = $obj->cves; | ||||||||||
| 91 | my $string = $obj->description; | ||||||||||
| 92 | my $string = $obj->distribution; | ||||||||||
| 93 | my $str = $obj->object; | ||||||||||
| 94 | my $string = $obj->references; | ||||||||||
| 95 | my $string = $obj->releases; | ||||||||||
| 96 | my $date = $obj->reported; | ||||||||||
| 97 | my $string = $obj->severity; | ||||||||||
| 98 | my $string = $obj->versions; | ||||||||||
| 99 | |||||||||||
| 100 | =head1 VERSION | ||||||||||
| 101 | |||||||||||
| 102 | v0.1.0 | ||||||||||
| 103 | |||||||||||
| 104 | =head1 DESCRIPTION | ||||||||||
| 105 | |||||||||||
| 106 | This class serves to retrieve and manipulate cves. | ||||||||||
| 107 | |||||||||||
| 108 | It inherits from L<Net::API::CPAN::Generic> | ||||||||||
| 109 | |||||||||||
| 110 | =head1 CONSTRUCTOR | ||||||||||
| 111 | |||||||||||
| 112 | =head2 new | ||||||||||
| 113 | |||||||||||
| 114 | Provided with an hash or hash reference of parameters, and this instantiates a new C<Net::API::CPAN::Cve> object. | ||||||||||
| 115 | |||||||||||
| 116 | The parameters that can be provided bear the same name and supports the same values as the methods below. | ||||||||||
| 117 | |||||||||||
| 118 | =head1 METHODS | ||||||||||
| 119 | |||||||||||
| 120 | =head2 affected_versions | ||||||||||
| 121 | |||||||||||
| 122 | Sets or gets a string and returns a L<scalar object|Module::Generic::Scalar>, even if there is no value. | ||||||||||
| 123 | |||||||||||
| 124 | =head2 cpansa_id | ||||||||||
| 125 | |||||||||||
| 126 | Sets or gets a string and returns a L<scalar object|Module::Generic::Scalar>, even if there is no value. | ||||||||||
| 127 | |||||||||||
| 128 | =head2 cves | ||||||||||
| 129 | |||||||||||
| 130 | Sets or gets a string and returns a L<scalar object|Module::Generic::Scalar>, even if there is no value. | ||||||||||
| 131 | |||||||||||
| 132 | =head2 description | ||||||||||
| 133 | |||||||||||
| 134 | Sets or gets a string and returns a L<scalar object|Module::Generic::Scalar>, even if there is no value. | ||||||||||
| 135 | |||||||||||
| 136 | =head2 distribution | ||||||||||
| 137 | |||||||||||
| 138 | Sets or gets a string and returns a L<scalar object|Module::Generic::Scalar>, even if there is no value. | ||||||||||
| 139 | |||||||||||
| 140 | =head2 object | ||||||||||
| 141 | |||||||||||
| 142 | Returns the object type for this class, which is C<cve> | ||||||||||
| 143 | |||||||||||
| 144 | =head2 references | ||||||||||
| 145 | |||||||||||
| 146 | Sets or gets a string and returns a L<scalar object|Module::Generic::Scalar>, even if there is no value. | ||||||||||
| 147 | |||||||||||
| 148 | =head2 releases | ||||||||||
| 149 | |||||||||||
| 150 | Sets or gets a string and returns a L<scalar object|Module::Generic::Scalar>, even if there is no value. | ||||||||||
| 151 | |||||||||||
| 152 | =head2 reported | ||||||||||
| 153 | |||||||||||
| 154 | Sets or gets a datetime value, and returns a L<DateTime object|DateTime> that stringifies to the format that was provided with the string set (usally an ISO 8601 datetime format) or C<undef> if no value is set. | ||||||||||
| 155 | |||||||||||
| 156 | =head2 severity | ||||||||||
| 157 | |||||||||||
| 158 | Sets or gets a string and returns a L<scalar object|Module::Generic::Scalar>, even if there is no value. | ||||||||||
| 159 | |||||||||||
| 160 | =head2 versions | ||||||||||
| 161 | |||||||||||
| 162 | Sets or gets a string and returns a L<scalar object|Module::Generic::Scalar>, even if there is no value. | ||||||||||
| 163 | |||||||||||
| 164 | =head1 AUTHOR | ||||||||||
| 165 | |||||||||||
| 166 | Jacques Deguest E<lt>F<jack@deguest.jp>E<gt> | ||||||||||
| 167 | |||||||||||
| 168 | =head1 SEE ALSO | ||||||||||
| 169 | |||||||||||
| 170 | L<Net::API::CPAN>, L<Net::API::CPAN::Activity>, L<Net::API::CPAN::Author>, L<Net::API::CPAN::Changes>, L<Net::API::CPAN::Changes::Release>, L<Net::API::CPAN::Contributor>, L<Net::API::CPAN::Cover>, L<Net::API::CPAN::Diff>, L<Net::API::CPAN::Distribution>, L<Net::API::CPAN::DownloadUrl>, L<Net::API::CPAN::Favorite>, L<Net::API::CPAN::File>, L<Net::API::CPAN::Module>, L<Net::API::CPAN::Package>, L<Net::API::CPAN::Permission>, L<Net::API::CPAN::Rating>, L<Net::API::CPAN::Release> | ||||||||||
| 171 | |||||||||||
| 172 | L<MetaCPAN::API>, L<MetaCPAN::Client> | ||||||||||
| 173 | |||||||||||
| 174 | L<https://github.com/metacpan/metacpan-api/blob/master/docs/API-docs.md> | ||||||||||
| 175 | |||||||||||
| 176 | =head1 COPYRIGHT & LICENSE | ||||||||||
| 177 | |||||||||||
| 178 | Copyright(c) 2023 DEGUEST Pte. Ltd. | ||||||||||
| 179 | |||||||||||
| 180 | All rights reserved | ||||||||||
| 181 | |||||||||||
| 182 | This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself. | ||||||||||
| 183 | |||||||||||
| 184 | =cut | ||||||||||
| 185 | |||||||||||