|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Object
|
+--com.starbase.starteam.CacheRef
|
+--com.starbase.starteam.Label
Represents a named configuration of Items. Labels may be
applied to an entire View or to individual item versions.
| Field Summary | |
static int |
NEXT_BUILD_ID
The value of this field is the "magic" value to provide for Item properties such as a ChangeRequest's "Addressed In" whose value represents a label ID. |
static int |
SCOPE_ITEM_AND_CONTENTS
When applying a label to a folder you can specify the scope of the operation. |
static int |
SCOPE_ITEM_ONLY
When applying a label to a folder you can specify the scope of the operation. |
static int |
SCOPE_ITEM_TREE
When applying a label to a folder you can specify the scope of the operation. |
| Constructor Summary | |
Label(View view,
java.lang.String name,
java.lang.String description)
Deprecated. Use View.createRevisionLabel() instead. |
|
Label(View view,
java.lang.String name,
java.lang.String description,
boolean isBuildLabel)
Deprecated. Use View.createViewLabel() instead. |
|
Label(View view,
java.lang.String name,
java.lang.String description,
Label cloneFrom)
Deprecated. Use View.cloneViewLabel() or View.cloneRevisionLabel() instead. |
|
Label(View view,
java.lang.String name,
java.lang.String description,
OLEDate time,
boolean isBuildLabel)
Deprecated. Use View.createViewLabel() instead. |
|
| Method Summary | |
void |
attachItem(Item item,
boolean recurse)
Deprecated. Use attachToItem or
attachToFolder. |
void |
attachItem(Item item,
int objectID,
OLEDate revisionTime,
boolean recurse)
Deprecated. Use one of attachToItem,
attachToFolder, attachToItemRevision or
attachToFolderRevision. |
void |
attachToFolder(Folder folder,
int scope)
Attaches the label to the specified folder. |
void |
attachToItem(Item item)
Associate a new item with this label. |
void |
attachToItems(int[] itemIDs,
ViewConfiguration configuration)
Attach this label to the specified items as of the specified configuration. |
Label |
copy()
Creates a copy of this Label object. |
void |
detachFromFolder(Folder item,
int scope)
Removes the label from the specified folder. |
void |
detachFromItems(int[] itemIDs)
Detaches this label from a collection of items. |
void |
detachItem(Item item)
Removes the label from the specified item. |
boolean |
equals(java.lang.Object another)
Returns true if the other object is a Label and has the same id (from getID()) and the same server object otherwise returns false. |
java.lang.String |
getDescription()
Returns the label's description. |
int |
getID()
Returns this label's unique integer identifier. |
int[] |
getLabeledItemIDs(int[] itemIDs)
Determines which items from a given list have been labeled with this label in the current view. |
java.lang.String |
getName()
Return's the label's name. |
int |
getOwningProjectID()
Returns the ID of the project that owns the view that owns this label. |
int |
getOwningViewID()
Returns the ID of the view that owns this label. |
OLEDate |
getRevisionTime()
Returns the label's revision time. |
OLEDate |
getTime()
Returns the label's primary rollback time. |
View |
getView()
Returns this label's View context. |
int |
hashCode()
Return a hash code for this object. |
boolean |
isBuildLabel()
Returns true if the label as being a StarTeam "Build" label. |
boolean |
isDeleted()
Returns true if this label has been deleted. |
boolean |
isEqualTo(Label label)
Compares two Label objects. |
boolean |
isLocked()
Return true if the label is locked or frozen. |
boolean |
isModified()
Returns true if this label has been modified but not yet saved. |
boolean |
isNew()
Returns true if the label has not been created on the server (using update()) |
boolean |
isRevisionLabel()
Returns true if the label is a revision label. |
boolean |
isViewLabel()
Returns true if the label is a view label. |
void |
moveItem(Item item)
Associates the label with a different version of an item. |
void |
moveItem(Item item,
int objectID,
OLEDate revisionTime)
Associates the label with a different version of an item. |
void |
remove()
Removes (deletes) this label from the view. |
void |
setDescription(java.lang.String description)
Sets the label's description. |
void |
setLocked(boolean isLocked)
Set the label's locked state. |
void |
setName(java.lang.String name)
Sets the label's name. |
void |
setTime(OLEDate time)
Sets the label's primary rollback time. |
java.lang.String |
toDebugString()
Returns a string containing various properties of this label. |
java.lang.String |
toString()
Returns the name of the label. |
void |
update()
Stores all changed to a new or modified label to the StarTeam repository. |
| Methods inherited from class java.lang.Object |
getClass, notify, notifyAll, wait, wait, wait |
| Field Detail |
public static final int SCOPE_ITEM_ONLY
public static final int SCOPE_ITEM_AND_CONTENTS
public static final int SCOPE_ITEM_TREE
public static final int NEXT_BUILD_ID
Label.isBuildLabel(),
PropertyNames.CR_ADDRESSED_IN,
Constant Field Values| Constructor Detail |
public Label(View view,
java.lang.String name,
java.lang.String description,
OLEDate time,
boolean isBuildLabel)
view - The view in which this label will be created.name - The label name.description - The label description.time - The as-of time for this view label.isBuildLabel - True if the label is to be a build label.Label.isBuildLabel(),
createViewLabel
public Label(View view,
java.lang.String name,
java.lang.String description,
boolean isBuildLabel)
view - The view in which this label will be created.name - The label name.description - The label description.isBuildLabel - True if the label is to be a build label.Label.isBuildLabel(),
createViewLabel
public Label(View view,
java.lang.String name,
java.lang.String description)
view - the view in which this label will be createdname - the label namedescription - the label descriptioncreateRevisionLabel
public Label(View view,
java.lang.String name,
java.lang.String description,
Label cloneFrom)
view - the view in which this label will be createdname - the label namedescription - the label descriptioncloneFrom - the label whose properties and members will be copied. For view labels, must
reside in the same view.cloneViewLabel,
cloneRevisionLabel| Method Detail |
public Label copy()
Label.isEqualTo(com.starbase.starteam.Label)public boolean isEqualTo(Label label)
label - The Label to be compared with this one.
Label.copy()public View getView()
View.fetchAllLabelsFromView(int, int)public int getID()
public int getOwningProjectID()
View.fetchAllLabelsFromView(int, int)public int getOwningViewID()
View.fetchAllLabelsFromView(int, int)public boolean isModified()
Label.update()public boolean isNew()
Label.update()public java.lang.String getName()
public void setName(java.lang.String name)
name - the new label namepublic java.lang.String getDescription()
public void setDescription(java.lang.String description)
description - the new label description.public boolean isBuildLabel()
PropertyNames.CR_ADDRESSED_INpublic OLEDate getTime()
public void setTime(OLEDate time)
time - the rollback timepublic OLEDate getRevisionTime()
public boolean isViewLabel()
Label.isRevisionLabel()public boolean isRevisionLabel()
public boolean isDeleted()
public boolean isLocked()
public void setLocked(boolean isLocked)
isLocked - true if the label is to be locked.
public void attachItem(Item item,
int objectID,
OLEDate revisionTime,
boolean recurse)
attachToItem,
attachToFolder, attachToItemRevision or
attachToFolderRevision.
item - the item to which the label is to be attachedobjectID - the object ID of the item being labeledrevisionTime - the time specifying to which revision the label
should be attachedrecurse - if true will recursively attach the label to all
sub items and folders.PropertyNames.OBJECT_ID,
PropertyNames.MODIFIED_TIME,
attachToItem,
attachToFolder
public void attachItem(Item item,
boolean recurse)
attachToItem or
attachToFolder.
item - the item to which the label is to be attachedrecurse - if true will recursively attach the label to all
sub items and folders.attachToItem,
attachToFolderpublic void attachToItem(Item item)
item - the item to which the label is to be attached
public void attachToItems(int[] itemIDs,
ViewConfiguration configuration)
itemIDs - the collection of items to which the label
should be attachedpublic void detachFromItems(int[] itemIDs)
itemIDs - the collection of items to which the label should be detached (may not be null)
public void attachToFolder(Folder folder,
int scope)
scope - for folder items this is the scope of the label detachmentLabel.SCOPE_ITEM_ONLY,
Label.SCOPE_ITEM_AND_CONTENTS,
Label.SCOPE_ITEM_TREE
public void moveItem(Item item,
int objectID,
OLEDate revisionTime)
item - the item to which the label is to be attachedobjectID - the object ID of the item being labeledrevisionTime - the time specifying to which revision the label
should be attachedPropertyNames.OBJECT_ID,
PropertyNames.MODIFIED_TIME,
Item.getObjectID(),
Item.getModifiedTime()public void moveItem(Item item)
item - the item to which the label is to be attachedpublic void detachItem(Item item)
item - the item from which the label is to be removed.
public void detachFromFolder(Folder item,
int scope)
item - the folder item from which the label is to be removed.scope - for folder items this is the scope of the label detachmentLabel.SCOPE_ITEM_ONLY,
Label.SCOPE_ITEM_AND_CONTENTS,
Label.SCOPE_ITEM_TREEpublic int[] getLabeledItemIDs(int[] itemIDs)
itemIDs - A list of item IDs.
Label.attachItem(Item, boolean)public void update()
Label.setName(java.lang.String),
Label.setDescription(java.lang.String),
Label.setLocked(boolean)public java.lang.String toDebugString()
public java.lang.String toString()
toString in class java.lang.Objectpublic boolean equals(java.lang.Object another)
equals in class java.lang.Objectanother - the object being compared to
public int hashCode()
hashCode in class java.lang.Objectpublic void remove()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||