Package wt.maturity
Interface MaturityService
The interface describing the services available for the maturity package.
Supported API: true
Extendable: false
Supported API: true
Extendable: false
- See Also:
-
Method Summary
Modifier and TypeMethodDescriptionDeletes a PromotionNotice.deletePromotionSeeds(PromotionNotice pn, WTSet promotables) Deletes the PromotionSeed link between the PromotionNotice and the Promotable.deletePromotionTargets(PromotionNotice pn, WTSet promotables) Deletes the PromotionTarget link between the PromotionNotice and the Promotable.voidgenerateViewables(WTCollection collection, PromotionNotice thePN, ConfigSpec configSpec, boolean defaultRep) Generates ProductView viewables for the objects in the collection.getBaselineItems(PromotionNotice promotionNotice) Returns a QueryResult of MaturityVersioned, Baselineable item iterations that are part of the Maturity Baseline associated to the PromotionNotice.getBaselines(Promotable promotable) Returns a QueryResult of MaturityVersioned Baseline objects that this MaturityVersioned Baselineable item iteration is part of.getBaselines(Baselineable promotable, Class promotionNoticeClass) Returns a QueryResult of MaturityVersioned Baseline objects of a specified class that this Baselineable item iteration is part of.getInvalidTargets(WTCollection promotionTargets, boolean includeLocks) Returns the set of invalid promotion targets of a given promotion notice.getPromotionNotices(WTCollection promotables)
Supported API: truegetPromotionNotices(WTSet promotables, State state) This method returns a WTKeyedHashMap containing the passed in Promotable as the key and any PromotionNotices that match the passed in state as the values which are contained in a WTSet.getPromotionNoticesMap(WTCollection promotables) This method returns a WTKeyedHashMap containing the passed in Promotable as the key and any PromotionNotices as the values which are contained in a WTSet.
Supported API: trueReturns the PromotionTargets associated to the PromotionNotice.getPromotionTargets(PromotionNotice pn, boolean onlyOtherSide) Returns the PromotionTargets associated to the PromotionNotice.Returns a WTKeyedHashSet where the keys are the values of pSet and the values are a WTArrayList of PromotionTargets.booleanisAnyIterationInBaseline(Promotable promotable, PromotionNotice promotionNotice) Returns true, if for this Maturity Baselineable, any items with the same Master are part of the MaturityBaseline associated to the PromotionNotice.booleanisInBaseline(Promotable promotable, PromotionNotice promotionNotice) Returns true, if the MaturityVersioned item iteration is part of the MaturityBaseline associated to the PromotionNotice.Persists the PromotionNotice.savePromotionSeeds(WTSet psSet) Persists PromotionSeeds in the psVector.voidsavePromotionSeeds(PromotionNotice pn, WTSet promotables) Creates and persists PromotionSeeds between the PromotionNotice and the Promotables.savePromotionTargets(WTSet ptSet) Persists all promotables that are associated to each PromotionTarget contained in the ptSet set.voidsavePromotionTargets(PromotionNotice pn, WTKeyedHashMap promotables) Creates and persists PromotionTargets between the PromotionNotice and the Promotables.voidsavePromotionTargets(PromotionNotice pn, WTSet promotables) Creates and persists PromotionTargets between the PromotionNotice and the Promotables.voidstartPromotionProcess(PromotionNotice notice, WfProcessTemplate template) This method starts the workflow process defined by template on the PromotionNotice notice.voidunattachPromotable(Promotable refObject, PromotionNotice promotionNotice, Class linkClass, String maturityRole) Deletes the association between a PromotionNotice and a Promotable.
-
Method Details
-
deletePromotionNotice
Deletes a PromotionNotice.
Supported API: true- Parameters:
pn-- Returns:
- PromotionNotice
- Throws:
WTExceptionMaturityException
-
savePromotionNotice
Persists the PromotionNotice.
Supported API: true- Parameters:
pn-- Returns:
- PromotionNotice
- Throws:
WTExceptionMaturityException
-
deletePromotionTargets
PromotionNotice deletePromotionTargets(PromotionNotice pn, WTSet promotables) throws WTException, MaturityException Deletes the PromotionTarget link between the PromotionNotice and the Promotable.
Supported API: true- Parameters:
pn-promotables-- Returns:
- PromotionNotice
- Throws:
WTExceptionMaturityException
-
getPromotionTargets
Returns the PromotionTargets associated to the PromotionNotice.
Supported API: true- Parameters:
pn-- Returns:
- QueryResult
- Throws:
WTExceptionMaturityException
-
savePromotionTargets
void savePromotionTargets(PromotionNotice pn, WTSet promotables) throws WTException, MaturityException, WTPropertyVetoException Creates and persists PromotionTargets between the PromotionNotice and the Promotables.
Supported API: true- Parameters:
pn-promotables-- Throws:
WTExceptionMaturityExceptionWTPropertyVetoException
-
savePromotionTargets
Creates and persists PromotionTargets between the PromotionNotice and the Promotables. Takes in a map which is a map of promotables to promotion target attributes
Supported API: true- Parameters:
pn-promotables- - Map of promotables to promotion target attributes- Throws:
WTException
-
unattachPromotable
void unattachPromotable(Promotable refObject, PromotionNotice promotionNotice, Class linkClass, String maturityRole) throws WTException, MaturityException Deletes the association between a PromotionNotice and a Promotable.
Supported API: true- Parameters:
refObject- A MaturityVersioned object to be disassociatd from a PromotionNoticepromotionNotice- The PromotionNotice associated to the MaturityVersioned.linkClass- The associated link Class, which has a PromotionNotice as role A.maturityRole- The role name.- Throws:
WTExceptionMaturityException
-
savePromotionTargets
WTSet savePromotionTargets(WTSet ptSet) throws WTException, MaturityException, WTPropertyVetoException Persists all promotables that are associated to each PromotionTarget contained in the ptSet set. Returns the persisted promotables.
Supported API: true- Parameters:
ptSet-- Returns:
- WTSet
- Throws:
WTExceptionMaturityExceptionWTPropertyVetoException
-
savePromotionSeeds
void savePromotionSeeds(PromotionNotice pn, WTSet promotables) throws WTException, MaturityException Creates and persists PromotionSeeds between the PromotionNotice and the Promotables.
Supported API: true- Parameters:
pn-promotables-- Throws:
WTExceptionMaturityException
-
savePromotionSeeds
Persists PromotionSeeds in the psVector.
Supported API: true- Parameters:
psSet-- Returns:
- WTSet
- Throws:
WTExceptionMaturityException
-
getPromotionSeeds
Supported API: true- Parameters:
pn-- Returns:
- QueryResult
- Throws:
WTExceptionMaturityException
-
deletePromotionSeeds
PromotionNotice deletePromotionSeeds(PromotionNotice pn, WTSet promotables) throws WTException, MaturityException Deletes the PromotionSeed link between the PromotionNotice and the Promotable.
Supported API: true- Parameters:
pn-promotables-- Returns:
- PromotionNotice
- Throws:
WTExceptionMaturityException
-
getBaselines
Returns a QueryResult of MaturityVersioned Baseline objects that this MaturityVersioned Baselineable item iteration is part of. If the iteration is not part of any MaturityBaselines, then a QueryResult of size zero is returned.
Supported API: true- Parameters:
promotable-- Returns:
- QueryResult
- Throws:
WTException
-
getBaselines
Returns a QueryResult of MaturityVersioned Baseline objects of a specified class that this Baselineable item iteration is part of. If the iteration is not part of any Baselines of that class, then a QueryResult of size zero is returned.
Supported API: true- Parameters:
promotable-promotionNoticeClass-- Returns:
- QueryResult
- Throws:
WTException
-
getBaselineItems
Returns a QueryResult of MaturityVersioned, Baselineable item iterations that are part of the Maturity Baseline associated to the PromotionNotice. If the Baseline contains no items, then a QueryResult of size zero is returned.
Supported API: true- Parameters:
promotionNotice-- Returns:
- QueryResult
- Throws:
WTException
-
isInBaseline
Returns true, if the MaturityVersioned item iteration is part of the MaturityBaseline associated to the PromotionNotice.
Supported API: true- Parameters:
promotable-promotionNotice-- Returns:
- boolean
- Throws:
WTException
-
isAnyIterationInBaseline
boolean isAnyIterationInBaseline(Promotable promotable, PromotionNotice promotionNotice) throws WTException Returns true, if for this Maturity Baselineable, any items with the same Master are part of the MaturityBaseline associated to the PromotionNotice.
Supported API: true- Parameters:
promotable-promotionNotice-- Returns:
- boolean
- Throws:
WTException
-
getPromotionTargets
QueryResult getPromotionTargets(PromotionNotice pn, boolean onlyOtherSide) throws WTException, MaturityException Returns the PromotionTargets associated to the PromotionNotice. If the onlyOtherSide is true, the roleB objects are returned. If the onlyOtherSide is false, the PromotionTarget Links are returned.
Supported API: true- Parameters:
pn-onlyOtherSide-- Returns:
- QueryResult
- Throws:
WTExceptionMaturityException
-
getInvalidTargets
Returns the set of invalid promotion targets of a given promotion notice. A promotion target is invalid if its current state is not the valid locking state, if this is defined, or the initial state from when the promotion notice was created.
Supported API: true- Parameters:
promotionTargets-includeLocks- If true, validate considering lock states. If false, validate without considering lock states.- Returns:
- WTSet
- Throws:
WTException
-
getPromotionNotices
Supported API: true- Parameters:
promotables-- Returns:
- WTCollection
- Throws:
WTException
-
generateViewables
void generateViewables(WTCollection collection, PromotionNotice thePN, ConfigSpec configSpec, boolean defaultRep) throws WTException Generates ProductView viewables for the objects in the collection.
Supported API: true- Parameters:
collection- Collection of objects that will have viewables generated.thePN- PromotionNotice associated to the collection of objects.configSpec- ConfigSpec used by ProductView viewable generationdefaultRep-- Throws:
WTException
-
getTargetPromotionNotices
Returns a WTKeyedHashSet where the keys are the values of pSet and the values are a WTArrayList of PromotionTargets.
Supported API: true- Parameters:
pSet- Set of Promotables- Returns:
- WTKeyedHashMap
- Throws:
WTException
-
getPromotionNotices
This method returns a WTKeyedHashMap containing the passed in Promotable as the key and any PromotionNotices that match the passed in state as the values which are contained in a WTSet.
Supported API: true- Parameters:
promotables-state-- Returns:
- WTKeyedHashMap
- Throws:
WTException
-
getPromotionNoticesMap
This method returns a WTKeyedHashMap containing the passed in Promotable as the key and any PromotionNotices as the values which are contained in a WTSet.
Supported API: true- Parameters:
promotables-- Returns:
- WTKeyedHashMap
- Throws:
WTException
-
startPromotionProcess
This method starts the workflow process defined by template on the PromotionNotice notice.
Supported API: true- Parameters:
notice-template-- Throws:
WTException
-