@PublicApi public interface

ResolutionManager

com.atlassian.jira.config.ResolutionManager
Known Indirect Subclasses

@PublicApi

This interface is designed for plugins to consume (call its methods).

Clients of @PublicApi can expect that programs compiled against a given version will remain binary compatible with later versions of the @PublicApi as per each product's API policy as long as the client does not implement/extend @PublicApi interfaces or classes (refer to each product's API policy for the exact guarantee---usually binary compatibility is guaranteed at least across minor versions).

Note: since @PublicApi interfaces and classes are not designed to be implemented or extended by clients, we may perform certain types of binary-incompatible changes to these classes and interfaces, but these will not affect well-behaved clients that do not extend/implement these types (in general, only classes and interfaces annotated with @PublicSpi are safe to extend/implement).

Class Overview

Manager for Resolutions.

Summary

Public Methods
Resolution createResolution(String name, String description)
Adds a new resolution.
void editResolution(Resolution resolution, String name, String description)
Edits an existing resolution.
Resolution getDefaultResolution()
Returns the default resolution.
Resolution getResolution(String id)
Returns a resolution with the specified id.
Resolution getResolutionByName(String name)
Returns the resolution with the specified name.
List<Resolution> getResolutions()
Return all resolutions.
void moveResolutionDown(String id)
Move the resolution down in the order.
void moveResolutionUp(String id)
Move the resolution up in the order.
void removeResolution(String resolutionId, String newResolutionId)
Removes a resolution with the specified id.
void setDefaultResolution(String id)
Sets the default resolution.

Public Methods

public Resolution createResolution (String name, String description)

Adds a new resolution. The new resolution must have a unique name.

Parameters
name resolution name. Cannot be null or blank.
description the resolution description. Can be null or blank.
Returns

public void editResolution (Resolution resolution, String name, String description)

Edits an existing resolution.

Parameters
resolution resolution to edit.
name the new name.
description the new description

public Resolution getDefaultResolution ()

Returns the default resolution.

Will return null if no default is set.

Returns
  • the default resolution.

public Resolution getResolution (String id)

Returns a resolution with the specified id.

Parameters
id resolution id.
Returns
  • a Resolution with the specified id or null if no resolution whith this id exists.

public Resolution getResolutionByName (String name)

Returns the resolution with the specified name. It is case insensitive.

Parameters
name the name of the resolution.
Returns

public List<Resolution> getResolutions ()

Return all resolutions. The list is ordered by the sequence. The order can be modified by calling moveResolutionDown(String) or moveResolutionUp(String).

Returns

public void moveResolutionDown (String id)

Move the resolution down in the order.

Parameters
id id of the resolution.

public void moveResolutionUp (String id)

Move the resolution up in the order.

Parameters
id id of the resolution.

public void removeResolution (String resolutionId, String newResolutionId)

Removes a resolution with the specified id. When removing a resolution all issues which have this resolution will have to be migrated to use a different resultion specified by the second argument.

Parameters
resolutionId resolution to remove.
newResolutionId new resolution for issues which have the resolution which has been removed. Cannot be null.

public void setDefaultResolution (String id)

Sets the default resolution.

You can pass null to clear the default.

Parameters
id resolution id or null.