Class ComponentConverter
java.lang.Object
com.atlassian.jira.bc.project.component.ComponentConverter
Originally this was part of the OfBizProjectComponentStore. I've extracted it to a separate class so that the logic
can be reused elsewhere.
- Since:
- 4.2
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionconvertToComponent(org.ofbiz.core.entity.GenericValue componentGV) Convert the specified GenericValue representing a MutableProjectComponent object to a MutableProjectComponent object.convertToComponents(Collection<org.ofbiz.core.entity.GenericValue> componentGVCollection) Convert the specified collection of GenericValues representing MutableProjectComponent object to a collection of MutableProjectComponent objects.Convert the specified MutableProjectComponent to a ProjectComponent object.Convert a collection of MutableProjectComponent objects to a collection of ProjectComponent objects.
-
Constructor Details
-
ComponentConverter
public ComponentConverter()
-
-
Method Details
-
convertToComponents
public Collection<MutableProjectComponent> convertToComponents(Collection<org.ofbiz.core.entity.GenericValue> componentGVCollection) Convert the specified collection of GenericValues representing MutableProjectComponent object to a collection of MutableProjectComponent objects.- Parameters:
componentGVCollection- collection of GenericValues - each GenericValue represents a ProjectComponent- Returns:
- collection of new MutableProjectComponent objects that represents the original collection of GenericValues
-
convertToComponent
Convert the specified GenericValue representing a MutableProjectComponent object to a MutableProjectComponent object.- Parameters:
componentGV- GenericValue object representing a MutableProjectComponent object to be converted to a MutableProjectComponent object- Returns:
- new MutableProjectComponent object that represents the original GenericValue object
-
convertToProjectComponents
public Collection<ProjectComponent> convertToProjectComponents(Collection<MutableProjectComponent> mutables) Convert a collection of MutableProjectComponent objects to a collection of ProjectComponent objects.- Parameters:
mutables- collection of MutableProjectComponent objects to convert- Returns:
- collection of new ProjectComponent objects that represent objects in the given MutableProjectComponent collection
-
convertToProjectComponent
Convert the specified MutableProjectComponent to a ProjectComponent object.- Parameters:
value- MutableProjectComponent to be converted into a ProjectComponent.- Returns:
- new instance of ProjectComponent with same values as given in the parameter object
-