|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--com.perforce.api.SourceControlObject | +--com.perforce.api.Job
Representation of a source control job. This class can be used to determine information for a particular p4 job. It can be constructed using the job name, but will not contain any additional change information until the sync() method is called.
Field Summary | |
static int |
CLOSED
Indicates that the Job is closed. |
static int |
OPEN
Indicates that the Job is open. |
static int |
SUSPENDED
Indicates that the Job is suspended. |
Constructor Summary | |
Job()
|
|
Job(Env env)
Default no-argument constructor. |
|
Job(Env env,
String name)
|
|
Job(String name)
Constructor that accepts the job number. |
Method Summary | |
void |
commit()
Stores this object back into Perforce, creating it if it didn't already exist. |
static void |
fix(Env env,
String changelist,
boolean del,
String job)
|
static void |
fix(Env env,
String changelist,
boolean del,
Vector jobs)
|
HashDecay |
getCache()
Returns the HashDecay instance for this class |
static Change[] |
getChangeFixes(Env env,
String jobname,
String[] files)
Returns an array of changes that are fixed by the named job, limited to the list of files if specified. |
Change[] |
getChanges()
|
String |
getDescription()
Returns the description for the Job. |
String |
getField(String name)
|
Enumeration |
getFieldNames()
|
Vector |
getFileEntries()
|
static Job |
getJob(Env env,
String name)
Returns the job with the specified name. |
static Job |
getJob(String name)
Returns the job with the specified name. |
static Job[] |
getJobFixes(Env env,
String change,
String[] files)
Returns an array of jobs that fix the specified change, limited to the list of files if specified. |
static Job[] |
getJobs(Env env)
|
static Job[] |
getJobs(Env env,
String jobview,
int max,
boolean use_integs,
String[] files)
|
String |
getModtimeString()
Returns the job's modification time |
String |
getName()
Returns the name of this Job. |
int |
getStatus()
Returns the status for the Job. |
String |
getStatusName()
|
String |
getUser()
Returns the User that owns this Job. |
void |
removeFix(int changelist)
|
void |
setDescription(String description)
Sets the description for the job. |
void |
setField(String name,
String value)
|
void |
setModtimeString(String modtime)
Sets the job's modification time |
void |
setName(String name)
Sets the job name for the Job. |
void |
setStatus(int status)
Sets status for the Job. |
void |
setStatus(String status)
Sets status for the Job. |
void |
setUser(String user)
Sets the User that owns this Job. |
void |
sync()
Synchronizes the Job with the correct information from P4, using whatever job number has already been set in the Job. |
void |
sync(String name)
Sycnhronizes the Job with the correct information from P4. |
String |
toString()
Overrides the default toString() method. |
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, wait, wait, wait |
Field Detail |
public static final int CLOSED
public static final int OPEN
public static final int SUSPENDED
Constructor Detail |
public Job()
public Job(Env env)
public Job(Env env, String name)
public Job(String name)
name
- Job nameMethod Detail |
public void commit() throws CommitException
SourceControlObject
commit
in class SourceControlObject
public static void fix(Env env, String changelist, boolean del, String job)
public static void fix(Env env, String changelist, boolean del, Vector jobs)
public HashDecay getCache()
SourceControlObject
getCache
in class SourceControlObject
public static Change[] getChangeFixes(Env env, String jobname, String[] files)
env
- Perforce environment to use.jobname
- Named job to get fixes for.files
- array of files (including wildcards) used to limit to lookup.public Change[] getChanges()
public String getDescription()
public String getField(String name)
public Enumeration getFieldNames()
public Vector getFileEntries()
public static Job getJob(Env env, String name)
public static Job getJob(String name)
public static Job[] getJobFixes(Env env, String change, String[] files)
env
- Perforce environment to use.change
- Change number (as a String
) to lookup jobs for.files
- array of files (including wildcards) used to limit to lookup.public static Job[] getJobs(Env env)
public static Job[] getJobs(Env env, String jobview, int max, boolean use_integs, String[] files)
public String getModtimeString()
public String getName()
public int getStatus()
public String getStatusName()
public String getUser()
public void removeFix(int changelist)
public void setDescription(String description)
public void setField(String name, String value)
public void setModtimeString(String modtime)
public void setName(String name)
name
- Job namepublic void setStatus(int status)
public void setStatus(String status)
public void setUser(String user)
user
- Owning user.public void sync()
sync
in class SourceControlObject
public void sync(String name)
number
- Job numberpublic String toString()
toString
in class Object
public String toXML()
SourceControlObject
toXML
in class SourceControlObject
|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |