|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface ConstantsManager
Manager for issue types, statuses, priorities and resolutions. This manager is responsible for caching these constants as well as all the usual update, delete, add operations in the database.
Field Summary | |
---|---|
static java.lang.String |
ALL_ISSUE_TYPES
Used to retrieve all IssueTypes. |
static java.lang.String |
ALL_STANDARD_ISSUE_TYPES
Used to retrieve a standard IssueTypes. |
static java.lang.String |
ALL_SUB_TASK_ISSUE_TYPES
Used to retrieve a subtask IssueTypes. |
static java.lang.String |
ISSUE_TYPE_CONSTANT_TYPE
Used in the generic getConstant(String, String) method |
static java.lang.String |
PRIORITY_CONSTANT_TYPE
Used in the generic getConstant(String, String) method |
static java.lang.String |
RESOLUTION_CONSTANT_TYPE
Used in the generic getConstant(String, String) method |
static java.lang.String |
STATUS_CONSTANT_TYPE
Used in the generic getConstant(String, String) method |
Method Summary | |
---|---|
boolean |
constantExists(java.lang.String constantType,
java.lang.String name)
Checks if a constant exists. |
java.util.List |
convertToConstantObjects(java.lang.String constantType,
java.util.Collection ids)
Converts the list of ids to the objects of appropriate types |
org.ofbiz.core.entity.GenericValue |
createIssueType(java.lang.String name,
java.lang.Long sequence,
java.lang.String style,
java.lang.String description,
java.lang.String iconurl)
Note this metod does not validate the input - i.e. |
java.util.List<java.lang.String> |
expandIssueTypeIds(java.util.Collection<java.lang.String> issueTypeIds)
Converts the 'special' ids of issue types to a list of issue type ids For example, converts a special id to a list of all sub-task issue types Also see ALL_STANDARD_ISSUE_TYPES , ALL_SUB_TASK_ISSUE_TYPES and
ALL_ISSUE_TYPES . |
java.util.List<java.lang.String> |
getAllIssueTypeIds()
Returns all issueType Ids. |
java.util.Collection<IssueType> |
getAllIssueTypeObjects()
Returns a list of IssueTypes. |
java.util.List<org.ofbiz.core.entity.GenericValue> |
getAllIssueTypes()
Deprecated. Use getAllIssueTypeObjects() instead. Deprecated since v4.0 |
org.ofbiz.core.entity.GenericValue |
getConstant(java.lang.String constantType,
java.lang.String id)
Deprecated. Use getConstantObject(java.lang.String, java.lang.String) instead. Deprecated since v4.0 |
org.ofbiz.core.entity.GenericValue |
getConstantByName(java.lang.String constantType,
java.lang.String name)
Returns a constant by name. |
IssueConstant |
getConstantByNameIgnoreCase(java.lang.String constantType,
java.lang.String name)
Returns a constant by name ignoring the case of the name passed in. |
IssueConstant |
getConstantObject(java.lang.String constantType,
java.lang.String id)
Returns an IssueConstant object for the given type & id. |
java.util.Collection |
getConstantObjects(java.lang.String constantType)
Returns all IssueConstant objects for the given type. |
org.ofbiz.core.entity.GenericValue |
getDefaultPriority()
Deprecated. Use getDefaultPriorityObject() instead. Since v4.0 |
Priority |
getDefaultPriorityObject()
Returns the default priority configured in JIRA. |
java.util.List<org.ofbiz.core.entity.GenericValue> |
getEditableSubTaskIssueTypes()
Retrieves an editable list of sub-task issues. |
IssueConstant |
getIssueConstant(org.ofbiz.core.entity.GenericValue issueConstantGV)
Converts a constant GenericValue to an IssueConstant object. |
org.ofbiz.core.entity.GenericValue |
getIssueType(java.lang.String id)
Deprecated. Use getIssueTypeObject(String) instead |
IssueType |
getIssueTypeObject(java.lang.String id)
Given an IssueType ID this method retrieves that IssueType. |
java.util.Collection<org.ofbiz.core.entity.GenericValue> |
getIssueTypes()
Deprecated. Use getRegularIssueTypeObjects() instead. |
java.util.Collection<org.ofbiz.core.entity.GenericValue> |
getPriorities()
Deprecated. Use getPriorityObjects() instead |
org.ofbiz.core.entity.GenericValue |
getPriority(java.lang.String id)
Deprecated. Use getPriorityObject(String) instead. |
java.lang.String |
getPriorityName(java.lang.String id)
Returns the priority Name for a given priority ID. |
Priority |
getPriorityObject(java.lang.String id)
Given a priority ID, this method retrieves that priority. |
java.util.Collection<Priority> |
getPriorityObjects()
Retrieve all Priorities in JIRA. |
java.util.Collection<IssueType> |
getRegularIssueTypeObjects()
Retrieve regular (non-subtask) issue types. |
org.ofbiz.core.entity.GenericValue |
getResolution(java.lang.String id)
Deprecated. Use getResolutionObject(String) instead. |
Resolution |
getResolutionObject(java.lang.String id)
Given a resolution ID, this method retrieves that resolution. |
java.util.Collection<Resolution> |
getResolutionObjects()
Retrieve all Resolutions in JIRA. |
java.util.Collection<org.ofbiz.core.entity.GenericValue> |
getResolutions()
Deprecated. Use getResolutionObjects() instead. |
org.ofbiz.core.entity.GenericValue |
getStatus(java.lang.String id)
Deprecated. Use getStatusObject(java.lang.String) instead. Deprecated since v4.0 |
Status |
getStatusByName(java.lang.String name)
Searches for a given status by name. |
java.util.Collection<org.ofbiz.core.entity.GenericValue> |
getStatuses()
Deprecated. Use getStatusObjects() instead. Deprecated since v4.0 |
Status |
getStatusObject(java.lang.String id)
Returns a Status given an id. |
java.util.Collection<Status> |
getStatusObjects()
Returns all statuses |
java.util.Collection<IssueType> |
getSubTaskIssueTypeObjects()
Retrieves all the sub-task issue types |
java.util.Collection<org.ofbiz.core.entity.GenericValue> |
getSubTaskIssueTypes()
Deprecated. Use getSubTaskIssueTypeObjects() instead. Deprecated since v4.0 |
void |
refresh()
Sets all cached copies of constant to null. |
void |
refreshIssueTypes()
Reloads all IssueTypes from the DB. |
void |
refreshPriorities()
Reloads all priorities from the DB. |
void |
refreshResolutions()
Reloads all resolutions from the DB. |
void |
refreshStatuses()
Reloads all statuses from DB. |
void |
removeIssueType(java.lang.String id)
Removes an existing issueType. |
void |
storeIssueTypes(java.util.List<org.ofbiz.core.entity.GenericValue> issueTypes)
Bulk operation to store a list of issueTypes. |
void |
updateIssueType(java.lang.String id,
java.lang.String name,
java.lang.Long sequence,
java.lang.String style,
java.lang.String description,
java.lang.String iconurl)
Updates an existing issueType. |
void |
validateCreateIssueType(java.lang.String name,
java.lang.String style,
java.lang.String description,
java.lang.String iconurl,
ErrorCollection errors,
java.lang.String nameFieldName)
Validates creation of a new issuetype. |
Field Detail |
---|
static final java.lang.String ALL_STANDARD_ISSUE_TYPES
static final java.lang.String ALL_SUB_TASK_ISSUE_TYPES
static final java.lang.String ALL_ISSUE_TYPES
static final java.lang.String PRIORITY_CONSTANT_TYPE
getConstant(String, String)
method
static final java.lang.String STATUS_CONSTANT_TYPE
getConstant(String, String)
method
static final java.lang.String RESOLUTION_CONSTANT_TYPE
getConstant(String, String)
method
static final java.lang.String ISSUE_TYPE_CONSTANT_TYPE
getConstant(String, String)
method
Method Detail |
---|
@Deprecated java.util.Collection<org.ofbiz.core.entity.GenericValue> getPriorities()
getPriorityObjects()
instead
GenericValue
s.java.util.Collection<Priority> getPriorityObjects()
Priority
s.@Deprecated org.ofbiz.core.entity.GenericValue getPriority(java.lang.String id)
getPriorityObject(String)
instead.
id
- The id of the priority
GenericValue
Priority getPriorityObject(java.lang.String id)
id
- The id of the priority
Priority
object.java.lang.String getPriorityName(java.lang.String id)
id
- The id of a priority
org.ofbiz.core.entity.GenericValue getDefaultPriority()
getDefaultPriorityObject()
instead. Since v4.0
GenericValue
.Priority getDefaultPriorityObject()
void refreshPriorities()
@Deprecated java.util.Collection<org.ofbiz.core.entity.GenericValue> getResolutions()
getResolutionObjects()
instead.
GenericValue
s.java.util.Collection<Resolution> getResolutionObjects()
Resolution
objects.@Deprecated org.ofbiz.core.entity.GenericValue getResolution(java.lang.String id)
getResolutionObject(String)
instead.
id
- The id of the resolution
GenericValue
Resolution getResolutionObject(java.lang.String id)
id
- The id of the resolution
Resolution
object.void refreshResolutions()
@Deprecated org.ofbiz.core.entity.GenericValue getIssueType(java.lang.String id)
getIssueTypeObject(String)
instead
id
- The ID of the IssueType.
GenericValue
IssueType getIssueTypeObject(java.lang.String id)
id
- The ID of the IssueType.
IssueType
object@Deprecated java.util.Collection<org.ofbiz.core.entity.GenericValue> getIssueTypes()
getRegularIssueTypeObjects()
instead.
GenericValue
sjava.util.Collection<IssueType> getRegularIssueTypeObjects()
IssueType
sjava.util.Collection<IssueType> getAllIssueTypeObjects()
IssueType
objects.@Deprecated java.util.List<org.ofbiz.core.entity.GenericValue> getAllIssueTypes()
getAllIssueTypeObjects()
instead. Deprecated since v4.0
GenericValue
issueTypes.java.util.List<java.lang.String> getAllIssueTypeIds()
@Deprecated java.util.Collection<org.ofbiz.core.entity.GenericValue> getSubTaskIssueTypes()
getSubTaskIssueTypeObjects()
instead. Deprecated since v4.0
getEditableSubTaskIssueTypes()
instead if you require an editable list.
GenericValue
s.java.util.Collection<IssueType> getSubTaskIssueTypeObjects()
IssueType
s.java.util.List<org.ofbiz.core.entity.GenericValue> getEditableSubTaskIssueTypes()
GenericValue
sjava.util.List<java.lang.String> expandIssueTypeIds(java.util.Collection<java.lang.String> issueTypeIds)
ALL_STANDARD_ISSUE_TYPES
, ALL_SUB_TASK_ISSUE_TYPES
and
ALL_ISSUE_TYPES
.
issueTypeIds
- A collection of the issuetype Ids to retrieve.
void refreshIssueTypes()
org.ofbiz.core.entity.GenericValue createIssueType(java.lang.String name, java.lang.Long sequence, java.lang.String style, java.lang.String description, java.lang.String iconurl) throws CreateException
validateCreateIssueType(String, String, String, String, com.atlassian.jira.util.ErrorCollection, String)
name
- Name of the new IssueTypesequence
- Sequence number used for ordering the issuetypes in the UI.style
- Used to record the type of issue, such as SUBTASK. Null for regular issues.description
- A short description of the new issue type.iconurl
- A URL to an icon to be used for the new issueType.
CreateException
- If there is an error creating this Issue Type.void validateCreateIssueType(java.lang.String name, java.lang.String style, java.lang.String description, java.lang.String iconurl, ErrorCollection errors, java.lang.String nameFieldName)
name
- Name of the new IssueTypestyle
- Used to record the type of issue, such as SUBTASK. Null for regular issues.description
- A short description of the new issue type.iconurl
- A URL to an icon to be used for the new issueType.errors
- A collection of errors used to pass back any problems.nameFieldName
- The field to which the errors should be added.void updateIssueType(java.lang.String id, java.lang.String name, java.lang.Long sequence, java.lang.String style, java.lang.String description, java.lang.String iconurl) throws DataAccessException
id
- ID of the existing issuetype.name
- Name of the new IssueTypesequence
- Sequence number used for ordering the issuetypes in the UI.style
- Used to record the type of issue, such as SUBTASK. Null for regular issues.description
- A short description of the new issue type.iconurl
- A URL to an icon to be used for the new issueType.
DataAccessException
- indicates an error in the Data Access Layervoid removeIssueType(java.lang.String id) throws RemoveException
id
- ID of an existing issueType
RemoveException
- if the issueType with id doesn't exist, or an error occured removing the issue.void storeIssueTypes(java.util.List<org.ofbiz.core.entity.GenericValue> issueTypes) throws DataAccessException
issueTypes
- A list of IssueType GenericValue
s
DataAccessException
- indicates an error in the Data Access Layer@Deprecated org.ofbiz.core.entity.GenericValue getStatus(java.lang.String id)
getStatusObject(java.lang.String)
instead. Deprecated since v4.0
id
- The id of a status
GenericValue
Status getStatusObject(java.lang.String id)
id
- The id of a status
Status
object.@Deprecated java.util.Collection<org.ofbiz.core.entity.GenericValue> getStatuses()
getStatusObjects()
instead. Deprecated since v4.0
GenericValue
s.java.util.Collection<Status> getStatusObjects()
Status
objectsvoid refreshStatuses()
Status getStatusByName(java.lang.String name)
name
- The name of the status.
Status
object with the given name, or null
if none found.@Deprecated org.ofbiz.core.entity.GenericValue getConstant(java.lang.String constantType, java.lang.String id)
getConstantObject(java.lang.String, java.lang.String)
instead. Deprecated since v4.0
constantType
- See PRIORITY_CONSTANT_TYPE
, STATUS_CONSTANT_TYPE
, RESOLUTION_CONSTANT_TYPE
, ISSUE_TYPE_CONSTANT_TYPE
id
- The id of the constant.
GenericValue
containing the constant. Null if it doesn't exist.IssueConstant getConstantObject(java.lang.String constantType, java.lang.String id)
IssueConstant
object for the given type & id.
constantType
- See PRIORITY_CONSTANT_TYPE
, STATUS_CONSTANT_TYPE
, RESOLUTION_CONSTANT_TYPE
, ISSUE_TYPE_CONSTANT_TYPE
id
- The id of the constant.
IssueConstant
object. Null if it doesn't exist.java.util.Collection getConstantObjects(java.lang.String constantType)
IssueConstant
objects for the given type.
constantType
- See PRIORITY_CONSTANT_TYPE
, STATUS_CONSTANT_TYPE
, RESOLUTION_CONSTANT_TYPE
, ISSUE_TYPE_CONSTANT_TYPE
IssueConstant
object.java.util.List convertToConstantObjects(java.lang.String constantType, java.util.Collection ids)
constantType
- the constant type. Case insenstiveids
- list of constant ids or GenericValues
boolean constantExists(java.lang.String constantType, java.lang.String name)
constantType
- See PRIORITY_CONSTANT_TYPE
, STATUS_CONSTANT_TYPE
, RESOLUTION_CONSTANT_TYPE
, ISSUE_TYPE_CONSTANT_TYPE
name
- The name of the constant.
org.ofbiz.core.entity.GenericValue getConstantByName(java.lang.String constantType, java.lang.String name)
constantType
- See PRIORITY_CONSTANT_TYPE
, STATUS_CONSTANT_TYPE
, RESOLUTION_CONSTANT_TYPE
, ISSUE_TYPE_CONSTANT_TYPE
name
- The Name of the constant.
GenericValue
TODO: Create alternative to GenericValueIssueConstant getConstantByNameIgnoreCase(java.lang.String constantType, java.lang.String name)
constantType
- See PRIORITY_CONSTANT_TYPE
, STATUS_CONSTANT_TYPE
, RESOLUTION_CONSTANT_TYPE
, ISSUE_TYPE_CONSTANT_TYPE
name
- The Name of the constant, case-insensitive.
IssueConstant getIssueConstant(org.ofbiz.core.entity.GenericValue issueConstantGV)
GenericValue
to an IssueConstant
object.
issueConstantGV
- the constant GenericValue
.
IssueConstant
object.void refresh()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |