|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.perforce.api.SourceControlObject
com.perforce.api.Counter
public final class Counter
Representation of perforce counters. This class can be used to set and get the value of a counter. It can also be used to determine who reviews the changes represented by a particular value.
| Constructor Summary | |
|---|---|
Counter()
Default no-argument constructor. |
|
Counter(Env environ,
java.lang.String name)
|
|
Counter(java.lang.String name)
|
|
| Method Summary | |
|---|---|
void |
commit()
Stores this object back into Perforce, creating it if it didn't already exist. |
HashDecay |
getCache()
Returns the HashDecay instance for this class |
static Counter[] |
getCounters(Env env)
Returns an array of all the Counters established on the server. |
java.lang.String |
getName()
|
int |
getValue()
Returns the value of this Counter. |
static void |
main(java.lang.String[] argv)
Deprecated. Actually in use, but this keeps it out of the docs. |
Change[] |
review()
Determine the changelists that need to be reviewed. |
void |
setName(java.lang.String name)
|
void |
setValue(int value)
Sets the value for the Counter. |
void |
sync()
Brings this object back into sync with Perforce. |
java.lang.String |
toXML()
Returns a string containing the object in XML form. |
| Methods inherited from class com.perforce.api.SourceControlObject |
|---|
clearCache, getEnv, getSyncTime, getUpdateTime, inSync, invalidate, outOfSync, refreshUpdateTime, setEnv |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public Counter()
public Counter(java.lang.String name)
public Counter(Env environ,
java.lang.String name)
| Method Detail |
|---|
public HashDecay getCache()
SourceControlObject
getCache in interface CacheablegetCache in class SourceControlObjectpublic java.lang.String getName()
public void setName(java.lang.String name)
public void setValue(int value)
value - New counter valuepublic int getValue()
public void commit()
throws CommitException
SourceControlObject
commit in interface Cacheablecommit in class SourceControlObjectCommitException
public void sync()
throws PerforceException
SourceControlObject
sync in interface Cacheablesync in class SourceControlObjectPerforceException
public static Counter[] getCounters(Env env)
throws PerforceException
PerforceException
public Change[] review()
throws PerforceException
PerforceExceptionpublic java.lang.String toXML()
SourceControlObject
toXML in class SourceControlObjectpublic static void main(java.lang.String[] argv)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||