Class OfBizCustomFieldValuePersister
java.lang.Object
com.atlassian.jira.issue.customfields.persistence.OfBizCustomFieldValuePersister
- All Implemented Interfaces:
IdentifiableComponent,CustomFieldValuePersister
- Direct Known Subclasses:
EagerLoadingOfBizCustomFieldPersister
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final Longstatic final Stringprotected final OfBizDelegatorprotected static final Stringstatic final Stringprotected static final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final String -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidcreateValues(CustomField field, Long issueId, PersistenceFieldType persistenceFieldType, Collection values) voidcreateValues(CustomField field, Long issueId, PersistenceFieldType persistenceFieldType, Collection values, String parentKey) getIssueIdsWithValue(CustomField field, PersistenceFieldType persistenceFieldType, Object value) Return a set of issue ids that have a certain value.getValues(CustomField field, Long issueId, PersistenceFieldType persistenceFieldType) Values returned in order by (UPDATED ASC, ID ASC)getValues(CustomField field, Long issueId, PersistenceFieldType persistenceFieldType, String parentKey) Values returned in order by (UPDATED ASC, ID ASC)Return custom field values of given issues batch.protected List<org.ofbiz.core.entity.GenericValue> getValuesForType(CustomField field, Long issueId) protected List<org.ofbiz.core.entity.GenericValue> getValuesForTypeAndParent(CustomField field, Long issueId, String parentKey) removeAllValues(String customFieldId) Called when removing a field.voidremoveDuplicateValues(CustomField field, Long issueId, PersistenceFieldType persistenceFieldType) Removes any duplicate values and keeps the most recent custom field value for the given custom field, from a given issue.removeValue(CustomField field, Long issueId, PersistenceFieldType persistenceFieldType, Object value) Removes a specific custom field value for the given custom field, from a given issue, of a particular type.voidupdateValues(CustomField field, Long issueId, PersistenceFieldType persistenceFieldType, Collection values) voidupdateValues(CustomField field, Long issueId, PersistenceFieldType persistenceFieldType, Collection values, String parentKey) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.atlassian.jira.issue.customfields.persistence.CustomFieldValuePersister
getValuesMethods inherited from interface com.atlassian.jira.com.rproxy.goskope.component.IdentifiableComponent
getIdentity
-
Field Details
-
delegator
-
ENTITY_VALUE_TYPE
- See Also:
-
ENTITY_ISSUE_ID
- See Also:
-
ENTITY_CUSTOMFIELD_ID
- See Also:
-
ENTITY_PARENT_KEY
- See Also:
-
DEFAULT_VALUE_TYPE
- See Also:
-
FIELD_TYPE_STRING
- See Also:
-
FIELD_TYPE_TEXT
- See Also:
-
FIELD_TYPE_DATE
- See Also:
-
FIELD_TYPE_NUMBER
- See Also:
-
TABLE_CUSTOMFIELD_VALUE
- See Also:
-
DEFAULT_VALUE_ISSUE_ID
-
-
Constructor Details
-
OfBizCustomFieldValuePersister
-
-
Method Details
-
getValues
public List<Object> getValues(CustomField field, Long issueId, PersistenceFieldType persistenceFieldType) Description copied from interface:CustomFieldValuePersisterValues returned in order by (UPDATED ASC, ID ASC)- Specified by:
getValuesin interfaceCustomFieldValuePersister
-
getValues
public List<Object> getValues(CustomField field, Long issueId, PersistenceFieldType persistenceFieldType, String parentKey) Description copied from interface:CustomFieldValuePersisterValues returned in order by (UPDATED ASC, ID ASC)- Specified by:
getValuesin interfaceCustomFieldValuePersister
-
getIssueIdsWithValue
public Set<Long> getIssueIdsWithValue(CustomField field, PersistenceFieldType persistenceFieldType, Object value) Description copied from interface:CustomFieldValuePersisterReturn a set of issue ids that have a certain value. This is used when you need to do a global 'swap' of a certain custom field value.- Specified by:
getIssueIdsWithValuein interfaceCustomFieldValuePersister- Parameters:
field- CustomFieldpersistenceFieldType- PersistenceFieldTypevalue- Value object- Returns:
- Set of Issue IDs
-
createValues
public void createValues(CustomField field, Long issueId, PersistenceFieldType persistenceFieldType, Collection values) - Specified by:
createValuesin interfaceCustomFieldValuePersister
-
createValues
public void createValues(CustomField field, Long issueId, PersistenceFieldType persistenceFieldType, Collection values, String parentKey) - Specified by:
createValuesin interfaceCustomFieldValuePersister
-
updateValues
public void updateValues(CustomField field, Long issueId, PersistenceFieldType persistenceFieldType, Collection values) - Specified by:
updateValuesin interfaceCustomFieldValuePersister
-
updateValues
public void updateValues(CustomField field, Long issueId, PersistenceFieldType persistenceFieldType, Collection values, String parentKey) - Specified by:
updateValuesin interfaceCustomFieldValuePersister
-
removeDuplicateValues
public void removeDuplicateValues(CustomField field, Long issueId, PersistenceFieldType persistenceFieldType) Description copied from interface:CustomFieldValuePersisterRemoves any duplicate values and keeps the most recent custom field value for the given custom field, from a given issue.- Specified by:
removeDuplicateValuesin interfaceCustomFieldValuePersister- Parameters:
field- the custom field.issueId- the issue.persistenceFieldType- the data type of the value
-
getValues
Description copied from interface:CustomFieldValuePersisterReturn custom field values of given issues batch.- Specified by:
getValuesin interfaceCustomFieldValuePersister
-
removeValue
public Set<Long> removeValue(CustomField field, Long issueId, PersistenceFieldType persistenceFieldType, Object value) Description copied from interface:CustomFieldValuePersisterRemoves a specific custom field value for the given custom field, from a given issue, of a particular type.- Specified by:
removeValuein interfaceCustomFieldValuePersister- Parameters:
field- the custom field.issueId- the issue.persistenceFieldType- the data type of the valuevalue- the value to delete.- Returns:
- returns the set of ids of issues that were affected for some reason (should be 1, just the given issue!).
-
removeAllValues
Description copied from interface:CustomFieldValuePersisterCalled when removing a field. Removes all the customfield values linked to the customfield Id provided.- Specified by:
removeAllValuesin interfaceCustomFieldValuePersister- Parameters:
customFieldId- the id of the custom field- Returns:
- issue IDs affected.
-
getValuesForTypeAndParent
protected List<org.ofbiz.core.entity.GenericValue> getValuesForTypeAndParent(CustomField field, Long issueId, String parentKey) -
getValuesForType
protected List<org.ofbiz.core.entity.GenericValue> getValuesForType(CustomField field, Long issueId)
-