|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectwt.vc.config.ConfigHelper
This helper for the ConfigService
provides convenience APIs useful
for converting lists of links into lists of masters or iterations and
for filtering lists.
Supported API: true
Extendable: false
ConfigSpec
,
ConfigService
,
Serialized FormField Summary | |
private static String |
CLASSNAME
|
static long |
EXTERNALIZATION_VERSION_UID
|
protected static long |
OLD_FORMAT_VERSION_UID
|
private static String |
RESOURCE
|
(package private) static long |
serialVersionUID
|
static ConfigService |
service
Supported API: true |
Constructor Summary | |
ConfigHelper()
|
Method Summary | |
static QueryResult |
buildConfigResultFromLinks(QueryResult linksToMasters,
String role,
QueryResult configResults)
Given a QueryResult of links to masters and the iterations for those masters, this method returns a new QueryResult of Persistable[] in which each element is a Persistable[] containing the link in the 0th position and the iteration (or master, if no iteration was found) for the master specified in the link in the 1th position. |
static QueryResult |
iterationsOf(QueryResult arrayedElements,
int index)
Returns a QueryResult of iterations found at the index position of the Persistable[] elements in the provided QueryResult. |
static QueryResult |
iterationsOf(QueryResult links,
String role)
Returns a QueryResult of iterations by applying the role to the QueryResult of Links. |
static QueryResult |
mastersOf(QueryResult arrayedElements,
int index)
Returns a QueryResult of masters found at the index position of the Persistable[] elements in the provided QueryResult. |
static QueryResult |
mastersOf(QueryResult links,
String role)
Returns a QueryResult of masters by applying the role to the QueryResult of Links. |
void |
readExternal(ObjectInput input)
Reads the non-transient fields of this class from an external source. |
private boolean |
readOldVersion(ObjectInput input,
long readSerialVersionUID,
boolean passThrough,
boolean superDone)
Reads the non-transient fields of this class from an external source, which is not the current version. |
protected boolean |
readVersion(ConfigHelper thisObject,
ObjectInput input,
long readSerialVersionUID,
boolean passThrough,
boolean superDone)
Reads the non-transient fields of this class from an external source. |
static QueryResult |
recoverMissingMasters(QueryResult masters,
QueryResult iterations)
Given a QueryResult of masters and a QueryResult of the iterations for those masters, this method returns a (new) QueryResult containing the iterations and any masters for which no corresponding iterations were found. |
private static QueryResult |
removeDuplicates(QueryResult qr)
|
static QueryResult |
removeExtraLinks(QueryResult linksToIterations,
String role,
QueryResult configResults)
Given a QueryResult of links to iterations and a QueryResult of filtered iterations, return a new QueryResult of only those links for which their iterations matched. |
void |
writeExternal(ObjectOutput output)
Writes the non-transient fields of this class to an external source. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
private static final String RESOURCE
private static final String CLASSNAME
public static final ConfigService service
static final long serialVersionUID
public static final long EXTERNALIZATION_VERSION_UID
protected static final long OLD_FORMAT_VERSION_UID
Constructor Detail |
public ConfigHelper()
Method Detail |
public void writeExternal(ObjectOutput output) throws IOException
writeExternal
in interface Externalizable
output
-
IOException
public void readExternal(ObjectInput input) throws IOException, ClassNotFoundException
readExternal
in interface Externalizable
input
-
IOException
ClassNotFoundException
protected boolean readVersion(ConfigHelper thisObject, ObjectInput input, long readSerialVersionUID, boolean passThrough, boolean superDone) throws IOException, ClassNotFoundException
thisObject
- input
- readSerialVersionUID
- passThrough
- superDone
-
IOException
ClassNotFoundException
private boolean readOldVersion(ObjectInput input, long readSerialVersionUID, boolean passThrough, boolean superDone) throws IOException, ClassNotFoundException
input
- readSerialVersionUID
- passThrough
- superDone
-
IOException
ClassNotFoundException
public static QueryResult mastersOf(QueryResult links, String role) throws WTException
links
- A QueryResult of links.role
- The role the masters play in the link.
WTException
Mastered
,
BinaryLink
,
QueryResult
public static QueryResult mastersOf(QueryResult arrayedElements, int index) throws WTException
arrayedElements
- A QueryResult of elements of type Persistable[].index
- The position in the Persistable[] the masters can be found in.
WTException
Mastered
,
Persistable
,
QueryResult
,
Persistable
public static QueryResult iterationsOf(QueryResult links, String role) throws WTException
links
- A QueryResult of links.role
- The role the iterations play in the link.
WTException
Iterated
,
BinaryLink
,
QueryResult
public static QueryResult iterationsOf(QueryResult arrayedElements, int index) throws WTException
arrayedElements
- A QueryResult of elements of type Persistable[].index
- The position in the Persistable[] the iterations can be found in.
WTException
Iterated
,
Persistable
,
QueryResult
,
Persistable
public static QueryResult recoverMissingMasters(QueryResult masters, QueryResult iterations) throws WTException
masters
- The masters the iterations belong to.iterations
- The iterations for the masters.
WTException
Mastered
,
Iterated
,
QueryResult
public static QueryResult buildConfigResultFromLinks(QueryResult linksToMasters, String role, QueryResult configResults) throws WTException
linksToMasters
- The links to masters.role
- The role those masters play in the links.configResults
- The iterations for those masters.
WTException
Mastered
,
Iterated
,
BinaryLink
,
Persistable
,
QueryResult
public static QueryResult removeExtraLinks(QueryResult linksToIterations, String role, QueryResult configResults) throws WTException
linksToIterations
- The links to iterations.role
- The role those iterations play in the links.configResults
- The iterations for those links. These are typically the iterations that matched given a ConfigSpec.
WTException
Iterated
,
BinaryLink
,
QueryResult
private static QueryResult removeDuplicates(QueryResult qr)
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |