wt.vc.config
Class OwnershipIndependentLatestConfigSpec

java.lang.Object
  extended by wt.vc.config.OwnershipIndependentLatestConfigSpec
All Implemented Interfaces:
Externalizable, Serializable, ConfigSpec

public class OwnershipIndependentLatestConfigSpec
extends Object
implements ConfigSpec, Externalizable

This OwnershipIndependentLatestConfigSpec is similiar to the LatestConfigSpec, except that it does not take ownership into account. It simply returns the latest element regardless of ownership.

Supported API: true

Extendable: false

See Also:
Serialized Form

Method Summary
 QuerySpec appendSearchCriteria(QuerySpec querySpec)
          Appends a "latest = true" statement to the QuerySpec, indicating that only versions (latest iterations) should be considered.
 QueryResult process(QueryResult results)
          Returns the latest of the versions based on the version identifier (A.A is greater than A and B is greater than both, for example).
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

appendSearchCriteria

public QuerySpec appendSearchCriteria(QuerySpec querySpec)
                               throws WTException,
                                      QueryException
Appends a "latest = true" statement to the QuerySpec, indicating that only versions (latest iterations) should be considered.

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
Returns the latest of the versions based on the version identifier (A.A is greater than A and B is greater than both, for example). Only a single version per master is returned. Ownership is not taken into consideration.

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