|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectinfo.bioinfweb.treegraph.document.IDManager
public class IDManager
| Field Summary | |
|---|---|
static java.lang.String |
RAND_CHARS
|
static int |
RAND_LENGTH
|
private static java.util.Comparator<java.lang.String> |
STRING_COMPARATOR
|
| Constructor Summary | |
|---|---|
IDManager()
|
|
| Method Summary | |
|---|---|
static boolean |
containsIDElements(Node root)
Test whether the subtree under root contains at least one ID element (label or
hidden data) |
static IconLabel |
getFirstIconLabel(Node root,
java.lang.String id)
|
static Label |
getFirstLabel(Node root,
java.lang.String id)
|
static TextLabel |
getFirstTextLabel(Node root,
java.lang.String id)
|
static java.lang.String[] |
getHiddenBranchDataIDs(Node root)
Searches for all the IDs of hidden data that is assigned to a branch present in the subtree under root. |
static java.util.Vector<java.lang.String> |
getHiddenBranchDataIDVector(Node root)
|
static java.lang.String[] |
getHiddenNodeDataIDs(Node root)
Searches for all the IDs of hidden data that is assigned to a node present in the subtree under root. |
static java.util.Vector<java.lang.String> |
getHiddenNodeDataIDVector(Node root)
|
static java.util.Vector<java.lang.String> |
getIconLabelIDVector(Node root)
|
static java.lang.String[] |
getIDs(Node root)
Searches for all IDs (hidden data and label IDs) present in the subtree under root. |
static java.util.Vector<java.lang.String> |
getIDVector(Node root)
Searches for all IDs present in the subtree under root. |
static java.lang.String[] |
getLabelIDs(Node root)
Searches for all label IDs present in the subtree under root. |
static java.util.Vector<java.lang.String> |
getLabelIDVector(Node root)
|
static java.lang.String[] |
getTextLabelIDs(Node root)
|
static java.util.Vector<java.lang.String> |
getTextLabelIDVector(Node root)
|
private static java.util.Vector<java.lang.String> |
getVector(Node root,
boolean includeTextLabels,
boolean includeIconLabels,
boolean includeNodeHiddenData,
boolean includeBranchHiddenData)
Returns a vector of IDs which is sorted alphabetically. |
static boolean |
idExists(Node root,
java.lang.String id)
|
static java.lang.String |
newID(java.util.Vector<java.lang.String> ids)
|
private static void |
renameHiddenDataID(HiddenDataElement element,
java.lang.String oldName,
java.lang.String newName)
|
static void |
renameID(java.lang.String oldName,
java.lang.String newName,
Node root)
Changes all accurences of the given ID in the subtree under root. |
private static void |
renameLabelIDInLabelBlock(java.lang.String oldName,
java.lang.String newName,
Labels labels,
boolean above)
|
private static void |
searchHiddenDataIDs(HiddenDataElement element,
java.util.Vector<java.lang.String> list)
|
private static void |
searchIDsInSubtree(Node root,
java.util.Vector<java.lang.String> list,
boolean includeTextLabels,
boolean includeIconLabels,
boolean includeNodeHiddenData,
boolean includeBranchHiddenData)
|
private static void |
searchLabelIDsInLabelBlock(Labels labels,
boolean above,
boolean includeTextLabels,
boolean includeIconLabels,
java.util.Vector<java.lang.String> list)
Adds all label IDs to the specified list. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final java.lang.String RAND_CHARS
public static final int RAND_LENGTH
private static final java.util.Comparator<java.lang.String> STRING_COMPARATOR
| Constructor Detail |
|---|
public IDManager()
| Method Detail |
|---|
private static void searchLabelIDsInLabelBlock(Labels labels,
boolean above,
boolean includeTextLabels,
boolean includeIconLabels,
java.util.Vector<java.lang.String> list)
labels - above - list -
private static void searchHiddenDataIDs(HiddenDataElement element,
java.util.Vector<java.lang.String> list)
private static void searchIDsInSubtree(Node root,
java.util.Vector<java.lang.String> list,
boolean includeTextLabels,
boolean includeIconLabels,
boolean includeNodeHiddenData,
boolean includeBranchHiddenData)
public static java.lang.String[] getIDs(Node root)
root - - the root node of the subtree to be searched.
public static boolean containsIDElements(Node root)
root contains at least one ID element (label or
hidden data)
root -
true if an ID element was foundpublic static java.lang.String[] getLabelIDs(Node root)
root - - the root node of the subtree to be searched.
public static java.lang.String[] getTextLabelIDs(Node root)
public static java.lang.String[] getHiddenBranchDataIDs(Node root)
root - - the root node of the subtree to be searched.
public static java.lang.String[] getHiddenNodeDataIDs(Node root)
root - - the root node of the subtree to be searched.
private static java.util.Vector<java.lang.String> getVector(Node root,
boolean includeTextLabels,
boolean includeIconLabels,
boolean includeNodeHiddenData,
boolean includeBranchHiddenData)
root - includeLabels - includeNodeHiddenData - includeBranchHiddenData -
public static java.util.Vector<java.lang.String> getIDVector(Node root)
root - - the root node of the subtree to be searched.
public static java.util.Vector<java.lang.String> getLabelIDVector(Node root)
public static java.util.Vector<java.lang.String> getTextLabelIDVector(Node root)
public static java.util.Vector<java.lang.String> getIconLabelIDVector(Node root)
public static java.util.Vector<java.lang.String> getHiddenBranchDataIDVector(Node root)
public static java.util.Vector<java.lang.String> getHiddenNodeDataIDVector(Node root)
private static void renameLabelIDInLabelBlock(java.lang.String oldName,
java.lang.String newName,
Labels labels,
boolean above)
private static void renameHiddenDataID(HiddenDataElement element,
java.lang.String oldName,
java.lang.String newName)
public static void renameID(java.lang.String oldName,
java.lang.String newName,
Node root)
root - - the root node of the subtree where the renaming should take placepublic static java.lang.String newID(java.util.Vector<java.lang.String> ids)
public static Label getFirstLabel(Node root,
java.lang.String id)
public static TextLabel getFirstTextLabel(Node root,
java.lang.String id)
public static IconLabel getFirstIconLabel(Node root,
java.lang.String id)
public static boolean idExists(Node root,
java.lang.String id)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||