5.7.35. Bugzilla::Flag¶
5.7.35.1. NAME¶
Bugzilla::Flag - A module to deal with Bugzilla flag values.
5.7.35.2. SYNOPSIS¶
Flag.pm provides an interface to flags as stored in Bugzilla. See below for more information.
5.7.35.3. NOTES¶
*
Import relevant functions from that script.
*
Use of private functions / variables outside this module may lead to unexpected results after an upgrade. Please avoid using private functions in other files/modules. Private functions are functions whose names start with _ or a re specifically noted as being private.
METHODS¶
id
Returns the ID of the flag.
name
Returns the name of the flagtype the flag belongs to.
bug_id
Returns the ID of the bug this flag belongs to.
attach_id
Returns the ID of the attachment this flag belongs to, if any.
status
Returns the status '+', '-', '?' of the flag.
creation_date
Returns the timestamp when the flag was created.
modification_date
Returns the timestamp when the flag was last modified.
type
Returns the type of the flag, as a Bugzilla::FlagType object.
setter
Returns the user who set the flag, as a Bugzilla::User object.
requestee
Returns the user who has been requested to set the flag, as a Bugzilla::User object.
attachment
Returns the attachment object the flag belongs to if the flag is an attachment flag, else undefined.
match($criteria)
Queries the database for flags matching the given criteria (specified as a hash of field names and their matching values) and returns an array of matching records.
count($criteria)
Queries the database for flags matching the given criteria (specified as a hash of field names and their matching values) and returns an array of matching records.
create($flag, $timestamp)
Creates a flag record in the database.
extract_flags_from_cgi($bug, $attachment, $hr_vars)
Checks whether or not there are new flags to create and returns an array of hashes. This array is then passed to Flag::create().
multi_extract_flags_from_cgi($bug, $hr_vars)
Checks whether or not there are new flags to create and returns an array of hashes. This array is then passed to Flag::create(). This differs from the previous sub-routine as it is called for changing multiple bugs
notify($flag, $old_flag, $object, $timestamp)
Sends an email notification about a flag being created, fulfilled or deleted.