Class LabelSummary
- java.lang.Object
-
- com.perforce.p4java.impl.generic.core.ServerResource
-
- com.perforce.p4java.impl.generic.core.LabelSummary
-
- All Implemented Interfaces:
ILabelSummary,IServerResource
- Direct Known Subclasses:
Label
public class LabelSummary extends ServerResource implements ILabelSummary
Default implementation of the ILabelSumamry interface.
-
-
Field Summary
Fields Modifier and Type Field Description protected booleanautoreloadprotected static java.lang.StringAUTORELOAD_VALUEprotected java.lang.Stringdescriptionprotected java.util.DatelastAccessprotected java.util.DatelastUpdateprotected booleanlockedprotected static java.lang.StringLOCKED_VALUEprotected java.lang.Stringnameprotected static java.lang.StringNOAUTORELOAD_VALUEprotected java.lang.StringownerNameprotected java.lang.StringrevisionSpecprotected booleanunloadedprotected static java.lang.StringUNLOCKED_VALUE-
Fields inherited from class com.perforce.p4java.impl.generic.core.ServerResource
refreshable, server, updateable
-
-
Constructor Summary
Constructors Constructor Description LabelSummary()Default constructor -- set all fields to null or false.LabelSummary(boolean summaryOnly)Construct an empty LabelSummary and appropriately initialize the ServerResource superclass fields according to whether this summary a summary only or part of the full Label class.LabelSummary(java.util.Map<java.lang.String,java.lang.Object> map)Construct a LabelSummary from a map returned from the Perforce server's getLabelSummaryList.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.StringgetDescription()Get the description associated with this label.java.util.DategetLastAccess()Get the date and time of the last 'labelsync' or use of '@label' on this label.java.util.DategetLastUpdate()Get the date and time the label specification was last updated.java.lang.StringgetName()Get the label's name (the label's label, so to speak).java.lang.StringgetOwnerName()Get the name of the owner of this label.java.lang.StringgetRevisionSpec()Get the optional revision specification for this label.booleanisAutoReload()Return the "autoreload/noautoreload" status for this label.booleanisLocked()Return the "locked/unlocked" status for this label.booleanisUnloaded()Return the "unloaded" status for this label.voidsetAutoReload(boolean autoreload)Set the "autoreload/noautoreload" status for this label.voidsetDescription(java.lang.String description)Set the description associated with this label.voidsetLastAccess(java.util.Date lastAccess)Set the date and time of the last 'labelsync' or use of '@label' on this label.voidsetLastUpdate(java.util.Date lastUpdate)Set the date and time the label specification was last updated.voidsetLocked(boolean locked)Set the "locked/unlocked" status for this label.voidsetName(java.lang.String name)Set the label's name.voidsetOwnerName(java.lang.String ownerName)Set the name of the owner of this label.voidsetRevisionSpec(java.lang.String revisionSpec)Set the optional revision specification for this label.-
Methods inherited from class com.perforce.p4java.impl.generic.core.ServerResource
canRefresh, canUpdate, clearRawFields, complete, getRawField, getRawFields, hasRawField, parseDate, refresh, setRawField, setRawFields, setRefreshable, setServer, toDateString, update, update, update
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.perforce.p4java.core.IServerResource
canRefresh, canUpdate, clearRawFields, complete, getRawField, getRawFields, hasRawField, refresh, setRawField, setRawFields, setServer, update, update, update
-
-
-
-
Field Detail
-
LOCKED_VALUE
protected static final java.lang.String LOCKED_VALUE
- See Also:
- Constant Field Values
-
UNLOCKED_VALUE
protected static final java.lang.String UNLOCKED_VALUE
- See Also:
- Constant Field Values
-
AUTORELOAD_VALUE
protected static final java.lang.String AUTORELOAD_VALUE
- See Also:
- Constant Field Values
-
NOAUTORELOAD_VALUE
protected static final java.lang.String NOAUTORELOAD_VALUE
- See Also:
- Constant Field Values
-
name
protected java.lang.String name
-
ownerName
protected java.lang.String ownerName
-
lastAccess
protected java.util.Date lastAccess
-
lastUpdate
protected java.util.Date lastUpdate
-
description
protected java.lang.String description
-
revisionSpec
protected java.lang.String revisionSpec
-
locked
protected boolean locked
-
unloaded
protected boolean unloaded
-
autoreload
protected boolean autoreload
-
-
Constructor Detail
-
LabelSummary
public LabelSummary()
Default constructor -- set all fields to null or false.
-
LabelSummary
public LabelSummary(boolean summaryOnly)
Construct an empty LabelSummary and appropriately initialize the ServerResource superclass fields according to whether this summary a summary only or part of the full Label class.- Parameters:
summaryOnly- summary only
-
LabelSummary
public LabelSummary(java.util.Map<java.lang.String,java.lang.Object> map)
Construct a LabelSummary from a map returned from the Perforce server's getLabelSummaryList.If the map is null, this is equivalent to calling the default constructor.
- Parameters:
map- spec map
-
-
Method Detail
-
getName
public java.lang.String getName()
Description copied from interface:ILabelSummaryGet the label's name (the label's label, so to speak).- Specified by:
getNamein interfaceILabelSummary- Returns:
- possibly-null label name (should only be null if the underlying label object has just been created on the client and has no server-side counterpart yet).
- See Also:
ILabelSummary.getName()
-
setName
public void setName(java.lang.String name)
Description copied from interface:ILabelSummarySet the label's name.- Specified by:
setNamein interfaceILabelSummary- Parameters:
name- the label's (new) name.- See Also:
ILabelSummary.setName(java.lang.String)
-
getOwnerName
public java.lang.String getOwnerName()
Description copied from interface:ILabelSummaryGet the name of the owner of this label.- Specified by:
getOwnerNamein interfaceILabelSummary- Returns:
- possibly-null owner name.
- See Also:
ILabelSummary.getOwnerName()
-
setOwnerName
public void setOwnerName(java.lang.String ownerName)
Description copied from interface:ILabelSummarySet the name of the owner of this label.- Specified by:
setOwnerNamein interfaceILabelSummary- Parameters:
ownerName- the new owner name.- See Also:
ILabelSummary.setOwnerName(java.lang.String)
-
getLastAccess
public java.util.Date getLastAccess()
Description copied from interface:ILabelSummaryGet the date and time of the last 'labelsync' or use of '@label' on this label.- Specified by:
getLastAccessin interfaceILabelSummary- Returns:
- possibly-null Date
- See Also:
ILabelSummary.getLastAccess()
-
setLastAccess
public void setLastAccess(java.util.Date lastAccess)
Description copied from interface:ILabelSummarySet the date and time of the last 'labelsync' or use of '@label' on this label.- Specified by:
setLastAccessin interfaceILabelSummary- Parameters:
lastAccess- new last access date.- See Also:
ILabelSummary.setLastAccess(java.util.Date)
-
getLastUpdate
public java.util.Date getLastUpdate()
Description copied from interface:ILabelSummaryGet the date and time the label specification was last updated.- Specified by:
getLastUpdatein interfaceILabelSummary- Returns:
- possibly-null Date
- See Also:
ILabelSummary.getLastUpdate()
-
setLastUpdate
public void setLastUpdate(java.util.Date lastUpdate)
Description copied from interface:ILabelSummarySet the date and time the label specification was last updated.- Specified by:
setLastUpdatein interfaceILabelSummary- Parameters:
lastUpdate- Date last updated.- See Also:
ILabelSummary.setLastUpdate(java.util.Date)
-
getDescription
public java.lang.String getDescription()
Description copied from interface:ILabelSummaryGet the description associated with this label.- Specified by:
getDescriptionin interfaceILabelSummary- Returns:
- possibly-null description string.
- See Also:
ILabelSummary.getDescription()
-
setDescription
public void setDescription(java.lang.String description)
Description copied from interface:ILabelSummarySet the description associated with this label.- Specified by:
setDescriptionin interfaceILabelSummary- Parameters:
description- new label description string.- See Also:
ILabelSummary.setDescription(java.lang.String)
-
getRevisionSpec
public java.lang.String getRevisionSpec()
Description copied from interface:ILabelSummaryGet the optional revision specification for this label.- Specified by:
getRevisionSpecin interfaceILabelSummary- Returns:
- possibly-null revision spec string.
- See Also:
ILabelSummary.getRevisionSpec()
-
setRevisionSpec
public void setRevisionSpec(java.lang.String revisionSpec)
Description copied from interface:ILabelSummarySet the optional revision specification for this label.- Specified by:
setRevisionSpecin interfaceILabelSummary- Parameters:
revisionSpec- new revision spec string- See Also:
ILabelSummary.setRevisionSpec(java.lang.String)
-
isLocked
public boolean isLocked()
Description copied from interface:ILabelSummaryReturn the "locked/unlocked" status for this label.- Specified by:
isLockedin interfaceILabelSummary- Returns:
- true iff the label is locked else it is unlocked.
- See Also:
ILabelSummary.isLocked()
-
setLocked
public void setLocked(boolean locked)
Description copied from interface:ILabelSummarySet the "locked/unlocked" status for this label.- Specified by:
setLockedin interfaceILabelSummary- Parameters:
locked- true iff the label is locked else it is unlocked.- See Also:
ILabelSummary.setLocked(boolean)
-
isAutoReload
public boolean isAutoReload()
Description copied from interface:ILabelSummaryReturn the "autoreload/noautoreload" status for this label.- Specified by:
isAutoReloadin interfaceILabelSummary- Returns:
- true iff the label is "autoreload" else it is "noautoreload".
- See Also:
ILabelSummary.isAutoReload()
-
setAutoReload
public void setAutoReload(boolean autoreload)
Description copied from interface:ILabelSummarySet the "autoreload/noautoreload" status for this label.- Specified by:
setAutoReloadin interfaceILabelSummary- Parameters:
autoreload- true iff the label is "autoreload" else it is "noautoreload".- See Also:
ILabelSummary.setAutoReload(boolean)
-
isUnloaded
public boolean isUnloaded()
Description copied from interface:ILabelSummaryReturn the "unloaded" status for this label.- Specified by:
isUnloadedin interfaceILabelSummary- Returns:
- true iff the label is unloaded.
- See Also:
ILabelSummary.isUnloaded()
-
-