Dean Hamstead > BZ-Client-1.072 > BZ::Client::Bug

Download:
BZ-Client-1.072.tar.gz

Dependencies

Annotate this POD

Website

CPAN RT

New  1
Open  1
View/Report Bugs
Module Version: 1.072   Source   Latest Release: BZ-Client-2.0_12

NAME ^

BZ::Client::Bug - Client side representation of a bug in Bugzilla

VERSION ^

version 1.072

SYNOPSIS ^

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

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

  my $bugs = BZ::Client::Bug->get( $client, $ids );

CLASS METHODS ^

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

fields

legal_values

  my $values = BZ::Client::Bug->legal_values( $client, $field )

Tells you what values are allowed for a particular field.

Note: This is deprecated in Bugzilla, use fields instead.

Params:

$field

The name of the field you want information about. This should be the same as the name you would use in create, below.

Returns:

$values

An arrayref of strings: the legal values for this field. The values will be sorted as they normally would be in Bugzilla.

Errors:

106 - Invalid Product

You were required to specify a product, and either you didn't, or you specified an invalid product (or a product that you can't access).

108 - Invalid Field Name

You specified a field that doesn't exist or isn't a drop-down field.

get

  $ids = 101; or $ids = [ 69, 101 ]; or $ids = '69,101';

  my $bugs = BZ::Client::Bug->get( $client, $ids );

$ids is an arrayref of ids, or a scalar containing comma delimiteed ids

Returns a list of bug instances with the given ID's.

new

  my $bug = BZ::Client::Bug->new( id => $id );

Creates a new instance with the given ID.

create

  my $id = BZ::Client::Bug->create( $client, $params );

Creates a new bug and returns the bug ID.

search

  my $bugs = BZ::Client::Bug->search( $client, $params );

Searches for bugs matching the given parameters.

INSTANCE METHODS ^

This section lists the modules instance methods.

id

  my $id = $bug->id();
  $bug->id( $id );

Gets or sets the bugs ID.

alias

  my $alias = $bug->alias();
  $bug->alias( $alias );

Gets or sets the bugs alias. If there is no alias or aliases are disabled in Bugzilla, this will be an empty string.

assigned_to

  my $assigned_to = $bug->assigned_to();
  $bug->assigned_to( $assigned_to );

Gets or sets the login name of the user to whom the bug is assigned.

component

  my $component = $bug->component();
  $bug->component( $component );

Gets or sets the name of the current component of this bug.

creation_time

  my $dateTime = $bug->creation_time();
  $bug->creation_time( $dateTime );

Gets or sets the date and time, when the bug was created.

dupe_of

  my $dupeOf = $bug->dupe_of();
  $bug->dupe_of( $dupeOf );

Gets or sets the bug ID of the bug that this bug is a duplicate of. If this bug isn't a duplicate of any bug, this will be an empty int.

is_open

  my $isOpen = $bug->is_open();
  $bug->is_open( $isOpen );

Gets or sets, whether this bug is closed. The return value, or parameter value is true (1) if this bug is open, false (0) if it is closed.

last_change_time

  my $lastChangeTime = $bug->last_change_time();
  $bug->last_change_time( $lastChangeTime );

Gets or sets the date and time, when the bug was last changed.

priority

  my $priority = $bug->priority();
  $bug->priority( $priority );

Gets or sets the priority of the bug.

product

  my $product = $bug->product();
  $bug->product( $product );

Gets or sets the name of the product this bug is in.

resolution

  my $resolution = $bug->resolution();
  $bug->resolution( $resolution );

Gets or sets the current resolution of the bug, or an empty string if the bug is open.

severity

  my $severity = $bug->severity();
  $bug->severity( $severity );

Gets or sets the current severity of the bug.

status

  my $status = $bug->status();
  $bug->status( $status );

Gets or sets the current status of the bug.

summary

  my $summary = $bug->summary();
  $bug->summary( $summary );

Gets or sets the summary of this bug.

SEE ALSO ^

  L<BZ::Client>, L<BZ::Client::API>

AUTHORS ^

COPYRIGHT AND LICENSE ^

This software is copyright (c) 2015 by Dean Hamstad.

This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.

syntax highlighting: