|
||||||||||
| 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.NamedCacheRef
|
+--com.starbase.starteam.TypedResource
|
+--com.starbase.starteam.SimpleTypedResource
|
+--com.starbase.starteam.Item
Contextual reference to an object in a StarTeam repository. Items provide transparent access to the underlying entity (e.g., modifying the description of an item by calling Item.put("Description", "some text") actually modifies the Desription property of the underlying entity the Item references. An Item consists of the underlying entity and its context within a view. Therefore, an Item has direct knowledge of the items to which it is related. Items also maintain state information to determine if the underlying object is is new or modified relative to instances of the object stored in the repository. An Item also has a temporal aspect in that it represents a single development path (linear history) of the underlying object as of a moment in time.
| Nested Class Summary | |
static interface |
Item.LockType
Defines the constants representing the valid lock operations on items. |
| Method Summary | |
void |
acquireOwnership()
Sets ownership of this securable object to the logged in user. |
void |
addAttachment(java.lang.String name,
int attachmentID)
Add new attachment information to this item. |
Item |
copy()
Creates a copy of the Item and all of its properties. |
int |
createAttachment(java.lang.String name,
java.io.InputStream source)
Creates a new attachment and returns the new attachment ID. |
int |
createAttachmentFromFile(java.lang.String name,
java.io.File source)
Creates a new attachment and returns the new attachment ID. |
static Item |
createItem(java.lang.String typeName,
Folder parent)
This factory method will create a new StarTeam item of the specified type. |
void |
deleteMergePoint(MergePoint mergePoint)
Deletes the specified merge point for this item. |
void |
discard()
Discards all of the cached properties for this Item. |
boolean |
equals(java.lang.Object another)
Returns true if the specified Object identifies
the same exact Item. |
java.lang.Object |
get(java.lang.String propertyName)
Returns the value of the named property. |
AclEntry[] |
getACL()
Returns the Access Control List for this item. |
Label[] |
getAllLabels()
Returns all labels attached to any version of this item. |
Label[] |
getAttachedLabels()
Returns labels attached to any version of this item. |
void |
getAttachment(int attachmentID,
java.io.OutputStream out)
Retrieves the specified attachment and copies it to the specified output stream. |
int[] |
getAttachmentIDs()
Returns the attachment IDs for this item. |
java.lang.String[] |
getAttachmentNames()
Returns the attachment names for this item. |
void |
getAttachmentToFile(int attachmentID,
java.io.File outFile)
Retrieves the specified attachment and copies it to the specified output stream. |
ItemBehavior |
getBehavior()
Returns ItemBehavior object associated with this Item. |
static int |
getBranchRevisionFromDotNotation(java.lang.String dotNotation)
Computes the "branch revision" from the specified dot notation. |
java.lang.Object |
getByProperty(Property property)
Returns the value of the specified property. |
java.lang.Object |
getByPropertyID(int propertyID)
Returns the value of the specified property. |
byte[] |
getByteArray(java.lang.String propertyName)
A convenience method for returning byte[] valued properties. |
Property[] |
getCachedProperties()
Returns an array of Properties whose values are cached locally, i.e either retrieved from persistent store or set by the client |
java.lang.String |
getComment()
Returns the comment describing this revision of the item. |
Item |
getCommonAncestor(Item other)
Gets the most recent common ancestor between this item and the given item. |
int |
getCreatedBy()
Returns the user ID of the user that created the first revision of the item. |
OLEDate |
getCreatedTime()
Returns the time at which the first revision of the item was created. |
OLEDate |
getDeletedTime()
For deleted items, returns the time the item was deleted. |
int |
getDeletedUserID()
For deleted items, returns the UserID of the user who deleted the item. |
java.lang.String |
getDisplayValue(Property prop)
Gets the value of a property in a form suitable for display. |
java.lang.String |
getDotNotation()
Returns the dot notation identification of this version. |
double |
getDouble(java.lang.String propertyName)
A convenience method for returning double valued properties. |
java.lang.String |
getEnumDisplayName(java.lang.String propertyName,
int value)
A convenience method for returning the display name for a given value of an enumerated property. |
int |
getFlag()
Returns whether or not this item is "flagged" for the currently logged in user. |
java.lang.String |
getFlagDisplayName(int value)
Returns a user-friendly display name for the given "Flag" value. |
Item |
getFromHistoryByDate(OLEDate date)
Returns the most recent version of this item as of the specified date. |
Item |
getFromHistoryByLabelID(int labelID)
Returns the specified version of this item based on the given label ID. |
Item |
getFromHistoryByVersion(int viewVersion)
Returns the specified version of this item based on the view version number. |
Item[] |
getHistory()
Returns the past versions of this item. |
int |
getID()
Return the identifier for the Item. |
int |
getInt(java.lang.String propertyName)
A convenience method for returning integer valued properties. |
int[] |
getIntArray(java.lang.String propertyName)
A convenience method for returning int[] valued properties. |
int |
getItemID()
Returns an identifier representing this item, that is, the underlying entity represented by this item in this specific context. |
ItemRevision[] |
getItemRevisions()
Returns the Item revisions for this item. |
int |
getLocker()
Returns the user ID of the user that has this item exclusively locked, or -1 if no one has it locked. |
MergePoint[] |
getMergeHistory()
Returns the merge points for this item. |
int |
getModifiedBy()
Returns the user ID of the user that created this revision of the item. |
OLEDate |
getModifiedTime()
Returns the time at which this revision of the item was created. |
int |
getMyLock()
Returns the lock status of this item for the currently logged in user. |
java.lang.String |
getNewRevisionComment()
Returns the empty string. |
int |
getObjectID()
Returns the object ID property for this item. |
OLEDate |
getOLEDate(java.lang.String propertyName)
A convenience method for returning OLEDate valued properties. |
int |
getOwner()
If there are no access rights explicitly assigned to this object, then the effective access rights come from a parent container. |
ISecurableContainer |
getParentContainer()
If there are no access rights explicitly assigned to this object, then the effective access rights come from a parent container. |
Folder |
getParentFolder()
Returns the folder in which this item exists. |
java.lang.String |
getParentFolderHierarchy()
Gets the fully-qualified name of this item's parent folder. |
java.lang.String |
getParentFolderName()
Returns the name of the item's parent folder. |
java.lang.String |
getParentFolderPath()
Returns the working directory path for the item's parent folder. |
java.lang.String |
getParentFolderQualifiedName()
Gets the fully-qualified name of this item's parent folder. |
int |
getParentRevision()
Returns the revision number at which this item was branched. |
int[] |
getPossibleFlag()
Returns the possible enum codes that are valid values for the "Flag" property. |
int[] |
getPossibleReadStatus()
Returns the possible enum codes that are valid values for the ReadStatus property. |
int[] |
getPossibleValues(java.lang.String propertyName)
A convenience method for returning an array of the possible values of an enumerated property. |
PropertyNames |
getPropertyNames()
A convenience method for getting the PropertyNames object from the owning server for the associated Type. |
int |
getReadStatus()
A flag indicating whether or not the user has read this item before. |
java.lang.String |
getReadStatusDisplayName(int value)
Returns a user-friendly display name for the given ReadStatus value. |
ItemReference |
getReference(ViewConfiguration config)
Returns the Item reference for this item, as of the configuration specified by the config argument, whether the item is live or deleted. |
ItemReference[] |
getReferences()
Returns the Item references for this item. |
int |
getRevisionNumber()
Returns the branch revision number for this item revision. |
int |
getRootObjectID()
Returns the root object ID property for this item. |
Server |
getServer()
Returns the server object to which this item belongs. |
java.lang.String |
getString(java.lang.String propertyName)
A convenience method for returning String valued properties. |
Type |
getType()
Returns the Type describing this item. |
TypeNames |
getTypeNames()
A convenience method for getting the TypeNames object from the owning server for the associated Type. |
View |
getView()
Returns the View in which this item exists. |
int |
getViewVersion()
The version number of this item calculated by counting direct ancestors of this item from this version to the initial version. |
static int |
getViewVersionFromDotNotation(java.lang.String dotNotation)
Computes the "view version" from the specified dot notation. |
int |
hashCode()
Return a hashcode for this item. |
boolean |
hasPermission(int permissions)
Returns true if desired permissions are granted |
boolean |
hasValues(java.lang.String[] propertyNames)
Returns true if every property specified contains a value,
either retrieved from persistent store or set by the client; otherwise,
returns false. |
boolean |
isBranchable()
Returns true if this item is a type that is branchable. |
boolean |
isDeleted()
Determines whether or not this item has been deleted. |
boolean |
isDirty()
Returns true if any property has been modified from
the original value (including properties set on new items). |
boolean |
isDisembodied()
A disembodied Item is one which does not have its full View and Folder context. |
boolean |
isEqualTo(Item item)
Compares two Items. |
boolean |
isFromHistory()
Determines whether or not this is a historical item obtained from the history. |
boolean |
isNew()
Returns true if this item has not yet been stored in the server. |
boolean |
isRefreshRequired()
Returns true if a refresh() operation might have resulted in any Item properties being updated; returns false if and only if it is known that the Item properties had not been changed since the last refresh. |
boolean |
isRefreshRequired(java.lang.String[] propertyNames)
Returns true if a refresh() operation might have resulted in any of the given Item properties being updated; returns false if and only if it is known that the given Item properties had not been changed since the last refresh. |
boolean |
isReverseShareRecommended(Folder target)
Determines whether share or reverse-share is the more appropriate operation when sharing this item to the given target folder. |
boolean |
isRootShare()
Determines whether or not this item is the root share of its share tree. |
void |
lock()
Obtains an exclusive lock on this item without attempting to break an existing lock. |
void |
modifyFlagForUser(boolean setFlagged)
Modifies this item's flag for the logged-in user. |
void |
modifyReadStatusForUser(boolean bSetAsRead)
Modifies this item's read status for the logged-in user. |
void |
move(Folder toFolder)
Deprecated. Use moveTo(). |
void |
moveTo(Folder toFolder)
Moves this item to the specified folder. |
void |
populate()
Ensures that all item properties have been populated. |
void |
populate(java.lang.String[] propertyNames)
Ensures that the given item properties have been populated. |
java.lang.Object |
put(java.lang.String propertyName,
java.lang.Object propertyValue)
Sets the value of the property specified by propertyName. |
java.lang.Object |
putByPropertyID(int propertyID,
java.lang.Object propertyValue)
Sets the value of the property specified by propertyID. |
void |
putLock(int lockType,
boolean breakLock)
Sets the current user's lock for this item. |
void |
recordMergePoint(Item source)
Records the merge point used to create this revision of the item with respect to the specified source item. |
void |
refresh()
Updates cached properties to reflect recent changes made on the server. |
void |
refresh(java.lang.String[] propertyNames)
Updates cached properties to reflect recent changes made on the server. |
void |
remove()
Removes this item from its current folder. |
void |
removeAttachment(int attachmentID)
Removes the specified attachment from this item. |
MergePoint |
resolveMergePoint(Item source)
Returns the merge point used to create this revision of the item with respect to the specified source item. |
Item |
reverseShareTo(Folder toFolder)
Transfers ownership of the root share of an item to a new view or folder, sharing a copy back to the original location. |
void |
setACL(AclEntry[] acl)
Modify the Access Control List for this item. |
void |
setBehavior(ItemBehavior behavior)
Changes the behavior of this item. |
void |
setBranchOnChange(boolean bBranchOnChange)
Sets the "Branch On Change" behavior. |
void |
setComment(java.lang.String comment)
Sets the comment describing this revision of the item. |
void |
setFixedConfig(ViewConfiguration config)
Changes the behavior of this item such that it is fixed at the given configuration. |
void |
setFloatingConfig()
Changes the behavior of this item to "floating". |
Item |
shareTo(Folder toFolder)
Shares this item to a new folder. |
Item |
smartShareTo(Folder target)
Shares or reverse-shares this item to the given target folder, as appropriate. |
java.lang.String |
toDebugString()
Returns a String that is potentially useful while
debugging. |
java.lang.String |
toString()
Returns a string representation of this object. |
void |
unlock()
Removes the current user's lock from this item. |
void |
update()
Stores the underlying entity in the server. |
void |
updateRevisionComment(java.lang.String comment)
This method changes the stored revision comment on the specified item revision. |
| Methods inherited from class com.starbase.starteam.TypedResource |
addToIntArray, removeFromIntArray |
| Methods inherited from class java.lang.Object |
getClass, notify, notifyAll, wait, wait, wait |
| Method Detail |
public static Item createItem(java.lang.String typeName,
Folder parent)
typeName - the name of item type to be createdparent - the folder in which the new item will be created. This
may not be null.TypeNamespublic Item copy()
Item.isEqualTo(com.starbase.starteam.Item)public boolean isEqualTo(Item item)
item - The Item to be compared to this one.
Item.copy()public Folder getParentFolder()
DisembodiedItemException - if the Item is disembodiedItem.isDisembodied()public void move(Folder toFolder)
toFolder - the new folder to which this item is to be moved.
DisembodiedItemException - if the Item is disembodiedItem.isDisembodied()public void moveTo(Folder toFolder)
toFolder - the new folder to which this item is to be moved.
DisembodiedItemException - if the Item is disembodiedItem.isDisembodied()public boolean isReverseShareRecommended(Folder target)
target - The target folder.
Item.smartShareTo(com.starbase.starteam.Folder)public Item smartShareTo(Folder target)
target - The target folder.
Item.isReverseShareRecommended(com.starbase.starteam.Folder)public Item shareTo(Folder toFolder)
If this is a deleted item, shareTo() will create a new item with the same properties, but in the state it was in prior to being deleted. This provides a way to recover content from the recycle bin.
toFolder - The new parent folder.
DisembodiedItemException - if the Folder is disembodied.Item.isDisembodied(),
Item.moveTo(com.starbase.starteam.Folder),
Item.reverseShareTo(com.starbase.starteam.Folder),
Item.isDeleted(),
RecycleBinpublic Item reverseShareTo(Folder toFolder)
In its basic form, this is simply a move followed by a share. However, reverse share is permitted from a rolled-back view. This is supported by finding the corresponding item in the tip view configuration, and reverse sharing that one.
When reverse sharing from a rolled back view, it is possible that the desired item revision in the target is not the tip revision of the item being shared. The reverse share operation compensates for this by moving the item to the target, sharing it back to the source, and then rolling back the target by creating a new revision whose user-modifiable properties (and content, if applicable) match the desired revision.
Sharing replaces the original item in the source view with a new share of the same underlying object. Since this is a new item with a new item ID, it initially has no attached labels. The reverse share operation will attempt to apply the same labels to the corresponding revisions of the new item. However, the label operations may be unsuccessful (for example, because of access rights, or because a label may be frozen). Any server exceptions that occur while re-applying labels to the new share are silently ignored, and will not cause the reverse share operation to fail.
toFolder - The new parent folder.
DisembodiedItemException - if either this item or the Folder is disembodied.Item.isDisembodied(),
Item.moveTo(com.starbase.starteam.Folder),
Item.shareTo(com.starbase.starteam.Folder),
#reverseShareTo(Folder,View)public boolean isRootShare()
public void remove()
public boolean isDeleted()
As of StarTeam 9.0, we can determine from an Item's properties whether or not it has been deleted. In older servers, we can only tell whether the remove() method was called on this Item.
SupportedFeatures.hasDeletedItems(),
Item.getDeletedTime(),
Item.getDeletedUserID()public OLEDate getDeletedTime()
Note that this method is supported for StarTeam Server 9.0 or later.
java.lang.UnsupportedOperationException - if the StarTeam Server does not support deleted items.SupportedFeatures.hasDeletedItems(),
PropertyNames.ITEM_DELETED_TIME,
DateTimeProperty.VALUE_NOT_SET,
Item.isDeleted(),
Item.getDeletedUserID()public int getDeletedUserID()
Note that this method is supported for StarTeam Server 9.0 or later.
java.lang.UnsupportedOperationException - if the StarTeam Server does not support deleted items.SupportedFeatures.hasDeletedItems(),
PropertyNames.ITEM_DELETED_USER_ID,
ObjectProperty.VALUE_NOT_SET,
Item.isDeleted(),
Item.getDeletedTime()public ItemReference[] getReferences()
DisembodiedItemException - if the Item is disembodiedItem.isDisembodied(),
Item.getObjectID(),
Item.getRevisionNumber()public ItemReference getReference(ViewConfiguration config)
config - the ItemConfig that describes the desired configuration, only "Current" and "Time" configurations are supported.
DisembodiedItemException - if the Item is disembodiedItem.isDisembodied(),
ViewConfigurationpublic ItemRevision[] getItemRevisions()
DisembodiedItemException - if the Item is disembodiedItem.isDisembodied(),
Item.getObjectID(),
ViewConfiguration,
ItemRevisionpublic int getItemID()
public int getID()
getID in class SimpleTypedResourcepublic int getObjectID()
PropertyNames.OBJECT_IDpublic boolean isBranchable()
public int getRootObjectID()
PropertyNames.ROOT_OBJECT_IDpublic int getRevisionNumber()
PropertyNames.REVISION_NUMBERpublic int getParentRevision()
PropertyNames.PATH_REVISIONpublic int getLocker()
PropertyNames.EXCLUSIVE_LOCKERpublic java.lang.String getComment()
PropertyNames.COMMENTpublic void setComment(java.lang.String comment)
comment - The comment for the next revision of this item.public OLEDate getModifiedTime()
PropertyNames.MODIFIED_TIMEpublic int getModifiedBy()
PropertyNames.MODIFIED_USER_IDpublic OLEDate getCreatedTime()
PropertyNames.CREATED_TIMEpublic int getCreatedBy()
PropertyNames.MODIFIED_USER_IDpublic java.lang.String getDotNotation()
"1.0". Each new revision will increment the version
number portion so the second revision would be "1.1".
When an item branches a new branch number will be issued and revision
will start counting from 0 again. For example, branching from version
"1.2" might result in "1.2.5.0" after which
the next version will be "1.2.5.1". The value 5 in the
previous example was assigned by the server based on the number of
branches already made from the revision being branched.
PropertyNames.DOTNOTATIONpublic int getViewVersion()
public static int getViewVersionFromDotNotation(java.lang.String dotNotation)
dotNotation - A dot notation.
getViewVersionpublic static int getBranchRevisionFromDotNotation(java.lang.String dotNotation)
dotNotation - A dot notation.
public Server getServer()
public View getView()
View in which this item exists.
For a disembodied item this will be the View from which the
Item was obtained and may not be the actual view in which
the item exists.
View in which this item exists.Item.isDisembodied()public void lock()
Item.LockType,
Item.putLock(int, boolean)public void unlock()
Item.LockType,
Item.putLock(int, boolean)
public void putLock(int lockType,
boolean breakLock)
lockType - the type of lock to be obtainedbreakLock - true if the server should break an exclusive lockItem.LockTypepublic boolean isFromHistory()
public Item[] getHistory()
public Item getFromHistoryByVersion(int viewVersion)
null if a version is not
found matching the specified version number. The view version
number starts with 1 for the first version of the item and
monitonically increases for each new version of the item, even
across branches.
viewVersion - The desired version of the item.
null if not found.Item.getViewVersion(),
Item.getHistory()public Item getFromHistoryByLabelID(int labelID)
null if a version is not found that is associated
with the given label ID.
labelID - The label ID to be used for finding the specified revision.
null if no version of the item has the label attached.Label,
Item.getHistory()public Item getFromHistoryByDate(OLEDate date)
null if a version is not found that existed as of the
given date.
date - The date specifying which historical version to return.
null if the date is prior to the first version of the item.public Label[] getAttachedLabels()
null but an empty array if
no labels are attached.
DisembodiedItemException - if the Item is disembodiedItem.isDisembodied()public Label[] getAllLabels()
null but an empty array if no labels are attached.
DisembodiedItemException - if the Item is disembodiedItem.isDisembodied()public boolean equals(java.lang.Object another)
Object identifies
the same exact Item.
equals in class SimpleTypedResourceanother - the object to be compared to for equality
public int hashCode()
hashCode in class SimpleTypedResourcepublic java.lang.String toString()
toString in class TypedResourcepublic void update()
public java.lang.String toDebugString()
String that is potentially useful while
debugging.
public boolean hasPermission(int permissions)
hasPermission in interface ISecurablepermissions - the desired permissions
DisembodiedItemException - if the Item is disembodiedItem.isDisembodied(),
Permissionpublic AclEntry[] getACL()
getACL in interface ISecurableDisembodiedItemException - if the Item is disembodiedItem.isDisembodied()public void setACL(AclEntry[] acl)
setACL in interface ISecurableacl - the new access control list or null if to be dropped.
DisembodiedItemException - if the Item is disembodiedItem.isDisembodied()
public void getAttachment(int attachmentID,
java.io.OutputStream out)
throws java.io.IOException
attachmentID - the attachment ID to retrieveout - the output to write to write the attachment to
java.io.IOException - is any error occur writing to the
output stream
public int createAttachment(java.lang.String name,
java.io.InputStream source)
throws java.io.IOException
name - the name of the attachmentsource - the input stream source to use for the attachment contents
java.io.IOException - is any error occur trying to read from
the source stream
public void getAttachmentToFile(int attachmentID,
java.io.File outFile)
throws java.io.IOException
attachmentID - the attachment ID to retrieveoutFile - the file in which to save the attachment
java.io.IOException - is any error occur writing to the
output stream
public int createAttachmentFromFile(java.lang.String name,
java.io.File source)
throws java.io.IOException
name - the name of the attachmentsource - the file to use as the source for the attachment
java.io.IOException - is any error occur trying to read from
the source streampublic int[] getAttachmentIDs()
Item.getAttachment(int, java.io.OutputStream),
Item.getAttachmentToFile(int, java.io.File)public java.lang.String[] getAttachmentNames()
public void addAttachment(java.lang.String name,
int attachmentID)
name - the name of the attachment. The name cannot contain a
newline character.attachmentID - the id of the attachment being addedItem.createAttachment(java.lang.String, java.io.InputStream),
Item.createAttachmentFromFile(java.lang.String, java.io.File),
PropertyNames.ATTACHMENT_COUNT,
PropertyNames.ATTACHMENT_IDS,
PropertyNames.ATTACHMENT_NAMESpublic void removeAttachment(int attachmentID)
attachmentID - the id of the attachment to removeItem.getAttachmentIDs(),
PropertyNames.ATTACHMENT_COUNT,
PropertyNames.ATTACHMENT_IDS,
PropertyNames.ATTACHMENT_NAMES
public int getInt(java.lang.String propertyName)
throws NoSuchPropertyException,
java.lang.ClassCastException
getInt in class SimpleTypedResourcepropertyName - the name of the property to be retrieved
NoSuchPropertyException - if the named property does not exist
java.lang.ClassCastException - if the value of the specified property cannot be coerced to an integer typeTypedResource.getInt(java.lang.String)
public java.lang.String getString(java.lang.String propertyName)
throws NoSuchPropertyException,
java.lang.ClassCastException
getString in class SimpleTypedResourcepropertyName - the name of the property to be retrieved
NoSuchPropertyException - if the named property does not exist
java.lang.ClassCastException - if the value of the specified property cannot be coerced to a String typeTypedResource.getString(java.lang.String)
public OLEDate getOLEDate(java.lang.String propertyName)
throws NoSuchPropertyException,
java.lang.ClassCastException
getOLEDate in class SimpleTypedResourcepropertyName - the name of the property to be retrieved
NoSuchPropertyException - if the named property does not exist
java.lang.ClassCastException - if the value of the specified property cannot be coerced to an OLEDate typeTypedResource.getOLEDate(java.lang.String)
public double getDouble(java.lang.String propertyName)
throws NoSuchPropertyException,
java.lang.ClassCastException
getDouble in class SimpleTypedResourcepropertyName - the name of the property to be retrieved
NoSuchPropertyException - if the named property does not exist
java.lang.ClassCastException - if the value of the specified property cannot be coerced to a double typeTypedResource.getDouble(java.lang.String)
public byte[] getByteArray(java.lang.String propertyName)
throws NoSuchPropertyException,
java.lang.ClassCastException
getByteArray in class SimpleTypedResourcepropertyName - the name of the property to be retrieved
NoSuchPropertyException - if the named property does not exist
java.lang.ClassCastException - if the value of the specified property cannot be coerced to a byte array typeTypedResource.getByteArray(java.lang.String)
public int[] getIntArray(java.lang.String propertyName)
throws NoSuchPropertyException,
java.lang.ClassCastException
getIntArray in class SimpleTypedResourcepropertyName - the name of the property to be retrieved
NoSuchPropertyException - if the named property does not exist
java.lang.ClassCastException - if the value of the specified property cannot be coerced to an int array typeTypedResource.getIntArray(java.lang.String)public PropertyNames getPropertyNames()
getPropertyNames in class SimpleTypedResourcePropertyNames object from this items'
server object.TypedResource.getPropertyNames()public TypeNames getTypeNames()
getTypeNames in class SimpleTypedResourceTypeNames object from the owning server.TypedResource.getTypeNames()public int[] getPossibleValues(java.lang.String propertyName)
getPossibleValues in class SimpleTypedResourcepropertyName - the name of the property
Property.getEnumValues(),
TypedResource.getPossibleValues(java.lang.String)
public java.lang.String getEnumDisplayName(java.lang.String propertyName,
int value)
getEnumDisplayName in class SimpleTypedResourcepropertyName - the name of the propertyvalue - one of the possible enumerated values of the indicated property
Property.getEnumDisplayName(int),
TypedResource.getEnumDisplayName(java.lang.String, int)public MergePoint resolveMergePoint(Item source)
source - the source Item that was the "merge" origin of the
revision specified by this item.
public void recordMergePoint(Item source)
source - the source Item that is to be the "merge" origin of the
revision specified by this item.public void deleteMergePoint(MergePoint mergePoint)
mergePoint - the merge point to be deletedpublic MergePoint[] getMergeHistory()
public java.lang.String getParentFolderName()
Item.getParentFolder(),
Folder.getName()public java.lang.String getParentFolderPath()
Item.getParentFolder(),
Folder.getPath()public java.lang.String getParentFolderHierarchy()
Item.getParentFolder(),
Folder.getFolderHierarchy(),
ClientContext.getFilePathDelimiter(),
#getParentFolderFullNamepublic java.lang.String getParentFolderQualifiedName()
Item.getParentFolder(),
Folder.getQualifiedName(),
PropertyNames.FOLDER_PATH,
Item.getParentFolderHierarchy()public java.lang.String getDisplayValue(Property prop)
prop - A property of this item.
public int getReadStatus()
Item.getPossibleReadStatus(),
Item.getReadStatusDisplayName(int),
PropertyNames.READ_STATUS,
Item.modifyReadStatusForUser(boolean)public void modifyReadStatusForUser(boolean bSetAsRead)
bSetAsRead - this item's new read statusItem.getReadStatus(),
PropertyNames.READ_STATUS_USER_LISTpublic int[] getPossibleReadStatus()
Item.getReadStatus(),
Item.getReadStatusDisplayName(int),
TypedResource.getPossibleValues(java.lang.String),
PropertyNames.READ_STATUS,
Item.modifyReadStatusForUser(boolean)public java.lang.String getReadStatusDisplayName(int value)
value - The ReadStatus value to be converted to a display name.
Item.getReadStatus(),
Item.getPossibleReadStatus(),
TypedResource.getEnumDisplayName(java.lang.String, int),
PropertyNames.READ_STATUS,
Item.modifyReadStatusForUser(boolean)public int getFlag()
Item.getPossibleFlag(),
Item.getFlagDisplayName(int),
PropertyNames.FLAG,
Item.modifyFlagForUser(boolean),
PropertyEnums.FLAG_YES,
PropertyEnums.FLAG_NOpublic void modifyFlagForUser(boolean setFlagged)
setFlagged - this item's new flag valueItem.getFlag(),
Item.getPossibleFlag(),
Item.getFlagDisplayName(int),
PropertyNames.FLAGpublic int[] getPossibleFlag()
Item.getFlag(),
Item.getFlagDisplayName(int),
TypedResource.getPossibleValues(java.lang.String),
PropertyNames.FLAG,
Item.modifyFlagForUser(boolean)public java.lang.String getFlagDisplayName(int value)
value - The Flag value to be converted to a display name.
Item.getFlag(),
Item.getPossibleFlag(),
TypedResource.getEnumDisplayName(java.lang.String, int),
PropertyNames.FLAG,
Item.modifyFlagForUser(boolean)public java.lang.String getNewRevisionComment()
public int getMyLock()
Item.LockType.EXCLUSIVE,
Item.LockType.NONEXCLUSIVE,
Item.LockType.UNLOCKED,
PropertyNames.MY_LOCKpublic ItemBehavior getBehavior()
DisembodiedItemException - if the Item is disembodiedItem.isDisembodied()public void setFloatingConfig()
DisembodiedItemException - if the Item is disembodied.Item.setFixedConfig(com.starbase.starteam.ViewConfiguration),
Item.setBehavior(com.starbase.starteam.ItemBehavior),
Item.isDisembodied()public void setFixedConfig(ViewConfiguration config)
config - The fixed configuration to be set.
DisembodiedItemException - if the Item is disembodied.Item.setFloatingConfig(),
Item.setBehavior(com.starbase.starteam.ItemBehavior),
Item.isDisembodied()public void setBranchOnChange(boolean bBranchOnChange)
DisembodiedItemException - if the Item is disembodiedItem.isDisembodied()public void setBehavior(ItemBehavior behavior)
behavior - The new behavior.
DisembodiedItemException - if the Item is disembodied.Item.setFixedConfig(com.starbase.starteam.ViewConfiguration),
Item.setFloatingConfig(),
ItemBehavior,
Item.isDisembodied()public void updateRevisionComment(java.lang.String comment)
comment - the new revision comment (may not be null)Item.getObjectID(),
Item.getRevisionNumber()public boolean isDisembodied()
View.getDisembodiedItem(int, com.starbase.starteam.Type),
View.getHistoryForItemID(int, com.starbase.starteam.Type),
Item.getView()public Type getType()
Type describing this item. This type
object is the aggregate of the type of the underlying entity
and the type object describing the context specific properties.
getType in interface ISecurablegetType in class SimpleTypedResourceISecurable.getParentContainer(),
Type
public java.lang.Object get(java.lang.String propertyName)
throws NoSuchPropertyException
get in class SimpleTypedResourcepropertyName - the name of the desired property
java.lang.Object
NoSuchPropertyException - if the specified name does not represent a valid property for this itemPropertyNames,
Item.getByPropertyID(int),
Item.getByProperty(com.starbase.starteam.Property)
public java.lang.Object getByPropertyID(int propertyID)
throws NoSuchPropertyException
propertyID - the internal ID of the desired property
java.lang.Object
NoSuchPropertyException - if the specified ID does not represent a valid property for this itemItem.get(java.lang.String),
Item.getByProperty(com.starbase.starteam.Property)
public java.lang.Object getByProperty(Property property)
throws NoSuchPropertyException
property - the desired property
java.lang.Object
NoSuchPropertyException - if the specified property is not valid for this itemItem.get(java.lang.String),
Item.getByPropertyID(int)public Property[] getCachedProperties()
hasValues(Property[])
public java.lang.Object put(java.lang.String propertyName,
java.lang.Object propertyValue)
throws java.lang.ClassCastException,
NoSuchPropertyException
propertyName.
put in class SimpleTypedResourcepropertyName - the name of the property to setpropertyValue - the value of the property to set
java.lang.ClassCastException - if the Object passed in is not an instance of a
type appropriate for the specified property
NoSuchPropertyException - if no valid property of this item is identified by the string propertyName
public java.lang.Object putByPropertyID(int propertyID,
java.lang.Object propertyValue)
throws java.lang.ClassCastException,
NoSuchPropertyException
propertyID.
putByPropertyID in class SimpleTypedResourcepropertyID - the integer ID of the property to setpropertyValue - the value of the property to set
java.lang.ClassCastException - if the Object passed in is not an instance of a
type appropriate for the specified property
NoSuchPropertyException - if no valid property of this item is identified by the integer propertyIDProperty.getID()public boolean hasValues(java.lang.String[] propertyNames)
true if every property specified contains a value,
either retrieved from persistent store or set by the client; otherwise,
returns false. A null properties array
will be interpretted as meaning "all properties". Ignores any
properties that are not cachable.
propertyNames - the names of the properties being checked for
cached values
public boolean isDirty()
true if any property has been modified from
the original value (including properties set on new items).
Modified properties are saved by a call to update().
Item.update()public boolean isNew()
Item.update()public void discard()
If the properties of an Item are changed, and discard() is called without first calling update(), the changes will be lost.
Item.refresh()public void populate()
Item.populate(String[]),
Item.refresh(),
Item.discard()public void populate(java.lang.String[] propertyNames)
propertyNames - The properties to populate, or null to populate
all properties.Item.populate(),
Item.refresh(),
Item.discard()public boolean isRefreshRequired()
Item.isRefreshRequired(String[]),
Item.refresh(),
Item.populate(),
Server.enableMPX()public boolean isRefreshRequired(java.lang.String[] propertyNames)
propertyNames - The item properties to be tested.
Item.isRefreshRequired(),
Item.refresh(),
Item.populate(),
Server.enableMPX()public void refresh()
Item.refresh(String[]),
Item.isRefreshRequired(),
Item.populate(),
Item.discard(),
Server.enableMPX()public void refresh(java.lang.String[] propertyNames)
propertyNames - The properties to be refreshed, or null to refresh
all properties.Item.refresh(),
Item.isRefreshRequired(),
Item.populate(),
Item.discard(),
Server.enableMPX()public Item getCommonAncestor(Item other)
other - The item to be compared with this one.
Item.isBranchable()public int getOwner()
getOwner in interface ISecurableObjectSupportedFeatures.hasObjectOwnership()public void acquireOwnership()
acquireOwnership in interface ISecurableObjectSupportedFeatures.hasObjectOwnership()public ISecurableContainer getParentContainer()
getParentContainer in interface ISecurableISecurableContainer
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||