wt.part
Class WTPartEffectivityConfigSpec

java.lang.Object
  extended by wt.part.WTPartEffectivityConfigSpec
All Implemented Interfaces:
Externalizable, Serializable, NetFactor, ObjectMappable, ConfigSpec

public class WTPartEffectivityConfigSpec
extends Object
implements ObjectMappable, ConfigSpec, Externalizable

A ConfigSpec used to filter WTParts based on their PDM Effectivity and membership in a view. This filtering can be done in different ways by populating various combinations of the class attributes. The following combinations are valid:

This ConfigSpec considers only versions (latest iterations), and returns at most one version per master (the latest eligible version).

Use the newWTPartEffectivityConfigSpec static factory method(s), not the WTPartEffectivityConfigSpec constructor, to construct instances of this class. Instances must be constructed using the static factory(s), in order to ensure proper initialization of the instance.



Supported API: true

Extendable: false

See Also:
Effectivity, Serialized Form

Field Summary
static String EFFECTIVE_CONFIG_ITEM
          Label for the attribute; Effective revisions will have effectivity which specifies this ConfigurationItem; A derived attribute.
static String EFFECTIVE_CONTEXT
          Label for the attribute; Effective revisions will have effectivity which specifies this effectivity context.
static String EFFECTIVE_DATE
          Label for the attribute; Effective revisions will have an effective date range which includes this date.
static String EFFECTIVE_PRODUCT
          Label for the attribute; Effective revisions will have effectivity which specifies this ConfigurationItem; A derived attribute.
static String EFFECTIVE_PRODUCT_INSTANCE
          Label for the attribute; Effective revisions will have effectivity which specifies this ConfigurationItem; A derived attribute.
static String EFFECTIVE_UNIT
          Label for the attribute; Effective revisions will have a unit number range which inclues this number.
static String EFFECTIVITY_TYPE
          Label for the attribute; The EffectivityType of the effectiveConfigItem attribute; A derived attribute.
static String VIEW
          Label for the attribute; If set, only those objects assigned to the view or view-independent are returned.
 
Method Summary
 QuerySpec appendSearchCriteria(QuerySpec querySpec)
          Appends to the supplied QuerySpec additional search criteria to reduce the resulting iterations to only those that will be considered by this ConfigSpec.
 ConfigurationItem getEffectiveConfigItem()
          Gets the value of the attribute: EFFECTIVE_CONFIG_ITEM.
 EffContext getEffectiveContext()
          Gets the value of the attribute: EFFECTIVE_CONTEXT.
 Timestamp getEffectiveDate()
          Gets the value of the attribute: EFFECTIVE_DATE.
 WTPartMaster getEffectiveProduct()
          Gets the value of the attribute: EFFECTIVE_PRODUCT.
 wt.effectivity.WTProductInstance getEffectiveProductInstance()
          Gets the value of the attribute: EFFECTIVE_PRODUCT_INSTANCE.
 String getEffectiveUnit()
          Gets the value of the attribute: EFFECTIVE_UNIT.
 EffectivityType getEffectivityType()
          Gets the value of the attribute: EFFECTIVITY_TYPE.
 View getView()
          Gets the value of the attribute: VIEW.
 QueryResult process(QueryResult results)
          Process the QueryResult of iterations, returning only those that "match" according to the algorithm.
 void setEffectiveConfigItem(ConfigurationItem a_EffectiveConfigItem)
          Sets the value of the attribute: EFFECTIVE_CONFIG_ITEM.
 void setEffectiveContext(EffContext a_EffectiveContext)
          Sets the value of the attribute: EFFECTIVE_CONTEXT.
 void setEffectiveDate(Timestamp a_EffectiveDate)
          Sets the value of the attribute: EFFECTIVE_DATE.
 void setEffectiveProduct(WTPartMaster a_EffectiveProduct)
          Sets the value of the attribute: EFFECTIVE_PRODUCT.
 void setEffectiveProductInstance(wt.effectivity.WTProductInstance a_EffectiveProductInstance)
          Sets the value of the attribute: EFFECTIVE_PRODUCT_INSTANCE.
 void setEffectiveUnit(String a_EffectiveUnit)
          Sets the value of the attribute: EFFECTIVE_UNIT.
 void setView(View a_View)
          Sets the value of the attribute: VIEW.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

EFFECTIVE_DATE

public static final String EFFECTIVE_DATE
Label for the attribute; Effective revisions will have an effective date range which includes this date.

Supported API: true

See Also:
Effectivity, Constant Field Values

EFFECTIVE_UNIT

public static final String EFFECTIVE_UNIT
Label for the attribute; Effective revisions will have a unit number range which inclues this number.

Supported API: true

See Also:
Effectivity, Constant Field Values

EFFECTIVITY_TYPE

public static final String EFFECTIVITY_TYPE
Label for the attribute; The EffectivityType of the effectiveConfigItem attribute; A derived attribute.

Supported API: true

See Also:
Effectivity, Constant Field Values

EFFECTIVE_CONTEXT

public static final String EFFECTIVE_CONTEXT
Label for the attribute; Effective revisions will have effectivity which specifies this effectivity context. A derived attribute.

Supported API: true

See Also:
Effectivity, Constant Field Values

EFFECTIVE_CONFIG_ITEM

public static final String EFFECTIVE_CONFIG_ITEM
Label for the attribute; Effective revisions will have effectivity which specifies this ConfigurationItem; A derived attribute.

Supported API: true

See Also:
Effectivity, Constant Field Values

EFFECTIVE_PRODUCT_INSTANCE

public static final String EFFECTIVE_PRODUCT_INSTANCE
Label for the attribute; Effective revisions will have effectivity which specifies this ConfigurationItem; A derived attribute.

Supported API: true

See Also:
Effectivity, Constant Field Values

EFFECTIVE_PRODUCT

public static final String EFFECTIVE_PRODUCT
Label for the attribute; Effective revisions will have effectivity which specifies this ConfigurationItem; A derived attribute.

Supported API: true

See Also:
Effectivity, Constant Field Values

VIEW

public static final String VIEW
Label for the attribute; If set, only those objects assigned to the view or view-independent are returned. If no WTParts match the view, the parent is checked (until there is either at least one match or no parent).

Supported API: true

See Also:
Constant Field Values
Method Detail

getEffectiveDate

public Timestamp getEffectiveDate()
Gets the value of the attribute: EFFECTIVE_DATE. Effective revisions will have an effective date range which includes this date.

Supported API: true

Returns:
Timestamp
See Also:
Effectivity

setEffectiveDate

public void setEffectiveDate(Timestamp a_EffectiveDate)
                      throws WTPropertyVetoException
Sets the value of the attribute: EFFECTIVE_DATE. Effective revisions will have an effective date range which includes this date.

Supported API: true

Parameters:
a_EffectiveDate -
Throws:
WTPropertyVetoException
See Also:
Effectivity

getEffectiveUnit

public String getEffectiveUnit()
Gets the value of the attribute: EFFECTIVE_UNIT. Effective revisions will have a unit number range which inclues this number.

Supported API: true

Returns:
String
See Also:
Effectivity

setEffectiveUnit

public void setEffectiveUnit(String a_EffectiveUnit)
                      throws WTPropertyVetoException
Sets the value of the attribute: EFFECTIVE_UNIT. Effective revisions will have a unit number range which inclues this number.

Supported API: true

Parameters:
a_EffectiveUnit -
Throws:
WTPropertyVetoException
See Also:
Effectivity

getEffectivityType

public EffectivityType getEffectivityType()
Gets the value of the attribute: EFFECTIVITY_TYPE. The EffectivityType of the effectiveConfigItem attribute; A derived attribute.

Supported API: true

Returns:
EffectivityType
See Also:
Effectivity

getEffectiveContext

public EffContext getEffectiveContext()
Gets the value of the attribute: EFFECTIVE_CONTEXT. Effective revisions will have effectivity which specifies this effectivity context. A derived attribute.

Supported API: true

Returns:
EffContext
See Also:
Effectivity

setEffectiveContext

public void setEffectiveContext(EffContext a_EffectiveContext)
                         throws WTPropertyVetoException
Sets the value of the attribute: EFFECTIVE_CONTEXT. Effective revisions will have effectivity which specifies this effectivity context. A derived attribute.

Supported API: true

Parameters:
a_EffectiveContext -
Throws:
WTPropertyVetoException
See Also:
Effectivity

getEffectiveConfigItem

public ConfigurationItem getEffectiveConfigItem()
Gets the value of the attribute: EFFECTIVE_CONFIG_ITEM. Effective revisions will have effectivity which specifies this ConfigurationItem; A derived attribute.

Supported API: true

Returns:
ConfigurationItem
See Also:
Effectivity

setEffectiveConfigItem

public void setEffectiveConfigItem(ConfigurationItem a_EffectiveConfigItem)
                            throws WTPropertyVetoException
Sets the value of the attribute: EFFECTIVE_CONFIG_ITEM. Effective revisions will have effectivity which specifies this ConfigurationItem; A derived attribute.

Supported API: true

Parameters:
a_EffectiveConfigItem -
Throws:
WTPropertyVetoException
See Also:
Effectivity

getEffectiveProductInstance

public wt.effectivity.WTProductInstance getEffectiveProductInstance()
Gets the value of the attribute: EFFECTIVE_PRODUCT_INSTANCE. Effective revisions will have effectivity which specifies this ConfigurationItem; A derived attribute.

Supported API: true

Returns:
WTProductInstance
See Also:
Effectivity

setEffectiveProductInstance

public void setEffectiveProductInstance(wt.effectivity.WTProductInstance a_EffectiveProductInstance)
                                 throws WTPropertyVetoException
Sets the value of the attribute: EFFECTIVE_PRODUCT_INSTANCE. Effective revisions will have effectivity which specifies this ConfigurationItem; A derived attribute.

Supported API: true

Parameters:
a_EffectiveProductInstance -
Throws:
WTPropertyVetoException
See Also:
Effectivity

getEffectiveProduct

public WTPartMaster getEffectiveProduct()
Gets the value of the attribute: EFFECTIVE_PRODUCT. Effective revisions will have effectivity which specifies this ConfigurationItem; A derived attribute.

Supported API: true

Returns:
WTPartMaster
See Also:
Effectivity

setEffectiveProduct

public void setEffectiveProduct(WTPartMaster a_EffectiveProduct)
                         throws WTPropertyVetoException
Sets the value of the attribute: EFFECTIVE_PRODUCT. Effective revisions will have effectivity which specifies this ConfigurationItem; A derived attribute.

Supported API: true

Parameters:
a_EffectiveProduct -
Throws:
WTPropertyVetoException
See Also:
Effectivity

getView

public View getView()
Gets the value of the attribute: VIEW. If set, only those objects assigned to the view or view-independent are returned. If no WTParts match the view, the parent is checked (until there is either at least one match or no parent).

Supported API: true

Returns:
View

setView

public void setView(View a_View)
             throws WTPropertyVetoException
Sets the value of the attribute: VIEW. If set, only those objects assigned to the view or view-independent are returned. If no WTParts match the view, the parent is checked (until there is either at least one match or no parent).

Supported API: true

Parameters:
a_View -
Throws:
WTPropertyVetoException

appendSearchCriteria

public QuerySpec appendSearchCriteria(QuerySpec querySpec)
                               throws WTException,
                                      QueryException
Appends to the supplied QuerySpec additional search criteria to reduce the resulting iterations to only those that will be considered by this ConfigSpec. Appending additional classes to the QuerySpec is allowed (for join purposes), but those that are marked as selectable will be trimmed by "filteredIterationsOf" prior to it calling the "process" API.

The QueryResult returned should be a copy of the passed in one (taking advantage of side-effects is not encouraged).



Supported API: true

Specified by:
appendSearchCriteria in interface ConfigSpec
Parameters:
querySpec - A QuerySpec with a target class that is Iterated.
Returns:
QuerySpec
Throws:
WTException
QueryException
See Also:
QuerySpec, SearchCondition

process

public QueryResult process(QueryResult results)
                    throws WTException
Process the QueryResult of iterations, returning only those that "match" according to the algorithm.

The QueryResult returned should be a copy of the passed-in QueryResult (side-effects should be avoided).



Supported API: true

Specified by:
process in interface ConfigSpec
Parameters:
results - QueryResult of iterations to filter. Assumed to be the result of a query that included the additional search conditions applied by appendSearchCriteria. Note that after enumerating through the elements of this QueryResult, it should be reset.
Returns:
QueryResult
Throws:
WTException
See Also:
QueryResult, Iterated