BZ-Client

 view release on metacpan or  search on metacpan

lib/BZ/Client/FlagType.pm  view on Meta::CPAN

#!/bin/false
# PODNAME: BZ::Client::FlagType
# ABSTRACT: The API for creating, changing, and getting info on Flags

use strict;
use warnings 'all';

package BZ::Client::FlagType;
$BZ::Client::FlagType::VERSION = '4.4004';

use parent qw( BZ::Client::API );

# See https://www.bugzilla.org/docs/tip/en/html/api/Bugzilla/WebService/FlagType.html

## functions

sub get {
    my($class, $client, $params) = @_;
    my $result = $class->api_call($client, 'FlagType.get', $params);
    return wantarray ? %$result : $result
}

sub create {
    my($class, $client, $params) = @_;
    return $class->_create($client, 'FlagType.create', $params, 'flag_id');
}

sub update {
    my($class, $client, $params) = @_;
    return $class->_returns_array($client, 'FlagType.update', $params, 'flagtypes');
}

1;

__END__

=pod

=encoding UTF-8

=head1 NAME

BZ::Client::FlagType - The API for creating, changing, and getting info on Flags

=head1 VERSION

version 4.4004

=head1 SYNOPSIS

This class provides methods for accessing and managing Flags in Bugzilla.

 my $client = BZ::Client->new( url       => $url,
                               user      => $user,
                               password  => $password );

 my %results     = BZ::Client::FlagType->get( $client, \%params );
 my $id = BZ::Client::FlagType->create( $client, \%params );
 my @updates = BZ::Client::FlagType->update( $client, \%params );

=head1 CLASS METHODS

This section lists the class methods, which are available in this module.

=head2 get

 $id = BZ::Client::FlagType->get( $client, \%params );

Get information about valid flag types that can be set for bugs and attachments.

=head3 History

Added in Bugzilla 5.0.

=head3 Parameters

You must pass a product L</name> and an optional L</component> name.

=over 4

=item product

I<product> (string) The name of a valid product.

=item component

I<component> (string) An optional valid component name associated with the product.



( run in 1.772 second using v1.01-cache-2.11-cpan-39bf76dae61 )