JIRA::REST::Class::Issue - A helper class for JIRA::REST::Class that represents an
version 0.12
This object represents a JIRA issue as an object. It is overloaded so it returns the key of the issue when stringified, and the id of the issue when it is used in a numeric context. If two of these objects are compared as strings, the key of the issues will be used for the comparison, while numeric comparison will compare the ids of the issues.
key
id
Accepts a list of filenames to be added to the issue as attachments.
Accepts a single filename to be added to the issue as an attachment.
Accepts a fake filename and a scalar representing the contents of a file and adds it to the issue as an attachment.
Adds whatever is passed in as a comment on the issue.
Adds whatever is passed in as a label for the issue.
Removes whatever is passed in from the labels for the issue.
Returns true if the issue has the specified label.
Adds whatever is passed in as a component for the issue.
Removes whatever is passed in from the components for the issue.
Sets the assignee for the issue to be the user passed in. Can either be a string representing the name or a JIRA::REST::Class::User object.
Sets the reporter for the issue to be the user passed in. Can either be a string representing the name or a JIRA::REST::Class::User object.
Adds a link from this issue to another one. Accepts the link type (either a string representing the name or a JIRA::REST::Class::Issue::LinkType), the issue to be linked to, and (optionally) the direction of the link (inward/outward). If the direction cannot be determined from the name of the link type, the default direction is 'inward';
Adds a subtask to the current issue. Accepts a hashref with named parameters summary and description. If the parameter issuetype is specified, then a subtask of the specified type is created. If no issuetype is specified, then the project is queried for valid subtask types, and, if there is only one, that type is used. If the project has more than one valid subtask type, an issuetype MUST be specified.
summary
description
issuetype
The remaining named parameters are passed to the create issue call as fields.
Puts an update to JIRA. Accepts a hash of fields => values to be put.
Puts a value to a field. Accepts the field name and the value as parameters.
Reload the issue from the JIRA server.
Generates a list of JIRA::REST::Class::Sprint objects from the fields for an issue. Uses the field_name() accessor on the JIRA::REST::Class::Project object to determine the name of the custom sprint field. Currently, this only really works if you're using Atlassian GreenHopper.
Returns a list of issue objects that are children of the issue. Currently requires the ScriptRunner plugin.
Moves the status of the issue to 'In Progress', regardless of what the current status is.
Moves the status of the issue to 'In QA', regardless of what the current status is.
Moves the status of the issue to 'Resolved', regardless of what the current status is.
Moves the status of the issue to 'Open', regardless of what the current status is.
Moves the status of the issue to 'Closed', regardless of what the current status is.
A comma-separated list of fields in the issue that weren't expanded in the initial REST call.
Returns a reference to the fields hash for the issue.
Returns the aggregate progress for the issue as a hash reference.
TODO: Turn this into an object.
Returns the aggregate time estimate for the issue.
TODO: Turn this into an object that can return either seconds or a w/d/h/m/s string.
Returns the aggregate time original estimate for the issue.
Returns the aggregate time spent for the issue.
Returns the issue's assignee as a JIRA::REST::Class::User object.
Returns the issue's change log as a JIRA::REST::Class::Issue::Changelog object.
Returns a list of the issue's comments as JIRA::REST::Class::Issue::Comment objects. If called in a scalar context, returns an array reference to the list, not the number of elements in the list.
Returns a list of the issue's components as JIRA::REST::Class::Project::Component objects. If called in a scalar context, returns an array reference to the list, not the number of elements in the list.
Returns a count of the issue's components.
Returns the issue's creation date as a DateTime object.
Returns the description of the issue.
Returns the issue's due date as a DateTime object.
Returns the issue's environment as a hash reference.
Returns a list of the issue's fixVersions.
TODO: Turn this into a list of objects.
Returns a list of the issue's links.
Returns the issue type as a JIRA::REST::Class::Issue::Type object.
Returns the issue's labels as an array reference.
Returns the issue's last view date as a DateTime object.
Returns the issue's parent as a JIRA::REST::Class::Issue object.
Returns a boolean indicating whether the issue has a parent.
Returns the issue's priority as a hash reference.
Returns the issue's progress as a hash reference.
Returns the issue's project as a JIRA::REST::Class::Project object.
Returns the issue's reporter as a JIRA::REST::Class::User object.
Returns the issue's resolution.
Returns the issue's resolution date as a DateTime object.
Returns the issue's status as a JIRA::REST::Class::Issue::Status object.
Returns the summary of the issue.
Returns the time estimate for the issue.
Returns the time original estimate for the issue.
Returns the time spent for the issue.
Returns the time tracking of the issue as a JIRA::REST::Class::Issue::TimeTracking object.
Returns the valid transitions for the issue as a JIRA::REST::Class::Issue::Transitions object.
Returns the issue's updated date as a DateTime object.
versions
votes
watches
Returns the issue's change log as a JIRA::REST::Class::Worklog object.
workratio
Returns the issue ID.
Returns the issue key.
Returns the JIRA REST API's full URL for this issue.
Returns the JIRA REST API's URL for this issue in a form used by JIRA::REST::Class.
A pass-through method that calls JIRA::REST::Class::Factory::make_object(), but adds a weakened link to this issue in the object as well.
Wrapper around JIRA::REST::Class' get method that defaults to this issue's URL. Allows for extra parameters to be specified.
JIRA::REST::Class
Wrapper around JIRA::REST::Class' post method that defaults to this issue's URL. Allows for extra parameters to be specified.
Wrapper around JIRA::REST::Class' put method that defaults to this issue's URL. Allows for extra parameters to be specified.
Wrapper around JIRA::REST::Class' delete method that defaults to this issue's URL. Allows for extra parameters to be specified.
JIRA::REST::Class::Abstract
JIRA::REST::Class::Factory
JIRA::REST::Class::Factory::make_object
JIRA::REST::Class::Issue::Changelog
JIRA::REST::Class::Issue::Comment
JIRA::REST::Class::Issue::LinkType
JIRA::REST::Class::Issue::Status
JIRA::REST::Class::Issue::TimeTracking
JIRA::REST::Class::Issue::Transitions
JIRA::REST::Class::Issue::Type
JIRA::REST::Class::Project
JIRA::REST::Class::Project::Component
JIRA::REST::Class::Sprint
JIRA::REST::Class::User
JIRA::REST::Class::Worklog
Packy Anderson <packy@cpan.org>
This software is Copyright (c) 2017 by Packy Anderson.
This is free software, licensed under:
The Artistic License 2.0 (GPL Compatible)
To install JIRA::REST::Class, copy and paste the appropriate command in to your terminal.
cpanm
cpanm JIRA::REST::Class
CPAN shell
perl -MCPAN -e shell install JIRA::REST::Class
For more information on module installation, please visit the detailed CPAN module installation guide.