|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--com.ice.cvsc.CVSRequest
The CVSRequest class is used to encapsulate a complete description of a CVS server request. Capable of parsing a simple string to define a request, CVSRequests are often built by configuration properties. Once a CVRequest is built and filled in, it is handed to a CVSClient for processing. Once the processing is completed, the CVSClient will return a CVSResponse containing the results of the request.
CVSClient
,
CVSProject
Field Summary | |
boolean |
allowGzipFileMode
If true, allow gzip-file-contents mode, otherwise suppress it. |
boolean |
allowOverWrites
If true, reponses that try to overwrite existing updated files will be allowed to overwrite if the file is in the list of files sent to the server. |
boolean |
displayReponse
Determines if this request should display the reponse. |
static int |
ES_ALL
|
static int |
ES_ALLLOST
|
static int |
ES_ALLMOD
|
static int |
ES_ALLUNC
|
static int |
ES_NEW
|
static int |
ES_NONE
|
static int |
ES_POPUP
|
static int |
ES_SEL
|
static int |
ES_SELALL
|
static int |
ES_SELLOST
|
static int |
ES_SELMOD
|
static int |
ES_SELUNC
|
static int |
ES_USER
|
boolean |
execInCurDir
This determines where cvs commands are executed. |
boolean |
forceModifieds
Force every file to go up as 'Modified'. |
boolean |
guaranteeMsg
Determines if this request will guarantee a '-m message' argument. |
boolean |
gzipFileMode
If true, send all files using gzip-file-contents mode. |
int |
gzipStreamLevel
If > 0, sets Gzip-stream level. |
boolean |
handleCopyFile
Determines if this request will handle 'Copy-file' responses. |
boolean |
handleEntries
Determines if this request will handle all entries related responses ('New-entry', 'Remove-entry', etc.). |
boolean |
handleFlags
Determines if this request will handle all settings related responses ('Set-sticky', 'Clear-static-directory', etc.). |
boolean |
handleMerged
Determines if this request will handle 'Merged' responses. |
boolean |
handleUpdated
Determines if this request will handle 'Updated' responses. |
boolean |
ignoreResult
If true, the reponse's status will be ignored and assumed to be 'ok'. |
boolean |
includeNotifies
Determines if this request should include the 'Notify' requests. |
static int |
METHOD_INETD
|
static int |
METHOD_RSH
|
static int |
METHOD_SSH
|
java.util.Vector |
notifies
The 'Notification' vector. |
boolean |
queueResponse
Determines whether or not the server's reponse is queued. |
static java.lang.String |
RCS_ID
|
static java.lang.String |
RCS_REV
|
boolean |
redirectOutput
Determines if the output of the reponse (stderr & stdout) will be redirected to a user specified file. |
CVSResponseHandler |
responseHandler
The response handler. |
boolean |
saveTempFiles
If true, the temporary files generated by this request will not be deleted as usual. |
boolean |
sendArguments
Determines if this request will send 'Argument 's. |
boolean |
sendEmptyMods
Determines if this request will send the special empty 'Modified' requests when a file is to be uploaded. |
boolean |
sendEntries
Determines if this request will send the 'Entry' requests. |
boolean |
sendEntryFiles
Determines if this request will send the 'Entry' list as 'files...'. |
boolean |
sendModifieds
Determines if this request will send 'Modified' requests for files that are modified locally. |
boolean |
sendModule
Determines if this request will send the 'Repository' list as 'module'. |
boolean |
sendRootDirectory
Determines if this request will send the 'RootDirectory'. |
boolean |
staticDirIsSet
Reflects the current 'Static-directory' setting in this request. |
boolean |
stickyIsSet
Reflects the current 'Sticky' setting in this request. |
boolean |
traceProcessing
If true, the processing phase of the CVS command will be traced on stderr. |
boolean |
traceRequest
If true, the request phase of the CVS command will be traced on stderr. |
boolean |
traceResponse
If true, the response phase of the CVS command will be traced on stderr. |
boolean |
traceTCPData
If true, all input and output data (TCP bytes) will be traced. |
boolean |
useDirectory
This is set by the "Valid-requests" cvs request. |
boolean |
useUnchanged
This is set by the "Valid-requests" cvs request. |
java.lang.String |
validRequests
The 'Valid-requests' response string from the server. |
boolean |
verificationOnly
Determines if this request will only verify the login and then return. |
Constructor Summary | |
CVSRequest()
Constructs a new CVSRequest object. |
Method Summary | |
void |
appendArguments(CVSArgumentVector newArgs)
Appends an argument list to the request's argument list. |
void |
appendGlobalArguments(CVSArgumentVector newArgs)
Appends an argument list to the request's global argument list. |
void |
endRedirection()
|
protected void |
finalize()
|
CVSArgumentVector |
getArguments()
Returns the request's argument list as a vector. |
java.lang.String |
getCheckInProgram()
Returns the request's 'Checkin-prog' setting. |
java.lang.String |
getCommand()
Returns the request's command name. |
int |
getConnectionMethod()
|
static java.lang.String |
getConnMethodName(int method)
|
CVSEntry |
getDirEntry()
|
CVSEntryVector |
getEntries()
Returns the request's entry list as a vector. |
int |
getEntrySelector()
Returns the request's entry selector. |
CVSArgumentVector |
getGlobalArguments()
Returns the request's global argument list as a vector. |
int |
getGzipStreamLevel()
|
java.lang.String |
getHostName()
Returns the request's server hostname. |
java.lang.String |
getLocalDirectory()
Returns the request's local directory, which represents the project's local directory. |
java.io.File |
getLocalFile(CVSEntry entry)
Returns the request's entry's local file. |
java.lang.String |
getPassword()
|
int |
getPort()
Returns the request's server port number. |
java.lang.String |
getRepository()
Returns the request's repository, which represents the project's CVS module on the server. |
CVSResponseHandler |
getResponseHandler()
Returns the request's response handler. |
java.lang.String |
getRootDirectory()
Returns the request's root directory, which represents the project's CVS root directory on the server. |
java.lang.String |
getRootRepository()
Returns the request's ROOT repository. |
java.lang.String |
getRshProcess()
|
java.lang.String |
getServerCommand()
|
java.lang.String[] |
getSetVariables()
Returns the request's user set variables. |
java.util.Hashtable |
getStatics()
Returns the request's 'Static-directory' settings. |
java.util.Hashtable |
getStickys()
Returns the request's 'Sticky' settings. |
java.lang.String |
getUpdateProgram()
Returns the request's 'Update-prog' setting. |
CVSUserInterface |
getUserInterface()
|
java.lang.String |
getUserName()
|
java.lang.String |
getVerifyFailReason()
Returns the reason for the last verification failure. |
boolean |
isPServer()
|
boolean |
isRedirected()
|
void |
parseArgumentString(java.lang.String argStr)
Process a user provided, or command spec based, argument string. |
boolean |
parseControlString(java.lang.String specification)
Attempts to parse a CVS request specification string. |
static int |
parseEntriesSelector(char selectCh)
|
void |
redirectLine(java.lang.String line)
|
void |
setArguments(CVSArgumentVector arguments)
Sets the request's argument list. |
void |
setCheckInProgram(java.lang.String program)
Sets the request's 'Checkin-prog' setting. |
void |
setCommand(java.lang.String command)
Sets the request's command. |
void |
setConnectionMethod(int method)
|
void |
setDirEntry(CVSEntry dirEntry)
|
void |
setEntries(CVSEntryVector entries)
Sets the request's entry list. |
void |
setGlobalArguments(CVSArgumentVector arguments)
Sets the request's global argument list. |
void |
setGzipStreamLevel(int level)
|
void |
setHostName(java.lang.String hostName)
Sets the request's server hostname. |
void |
setLocalDirectory(java.lang.String localDirectory)
Sets the request's local directory. |
void |
setPassword(java.lang.String password)
|
void |
setPort(int port)
Sets the request's server port number. |
void |
setPServer(boolean isPServer)
|
void |
setRedirectWriter(java.io.PrintWriter writer)
|
void |
setRepository(java.lang.String repository)
Sets the request's repository (or module name). |
void |
setResponseHandler(CVSResponseHandler responseHandler)
Sets the request's response handler. |
void |
setRootDirectory(java.lang.String rootDirectory)
Sets the request's root directory. |
void |
setRootRepository(java.lang.String repository)
Sets the request's ROOT repository. |
void |
setRshProcess(java.lang.String rshProcess)
|
void |
setServerCommand(java.lang.String command)
|
void |
setSetVariables(java.lang.String[] vars)
Sets the request's user set variables. |
void |
setStatics(java.util.Hashtable statics)
Sets the request's 'Static-directory' settings. |
void |
setStickys(java.util.Hashtable stickys)
Sets the request's 'Sticky' settings. |
void |
setUpdateProgram(java.lang.String program)
Sets the request's 'Update-prog' setting. |
void |
setUserInterface(CVSUserInterface ui)
|
void |
setUserName(java.lang.String userName)
|
void |
setVerifyFailReason(java.lang.String reason)
Sets the reason for the current verification failure. |
java.lang.String |
toString()
Returns a string representation of this request. |
boolean |
verifyRequest()
Verify the current request. |
Methods inherited from class java.lang.Object |
clone, equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
public static final java.lang.String RCS_ID
public static final java.lang.String RCS_REV
public static final int METHOD_INETD
public static final int METHOD_RSH
public static final int METHOD_SSH
public static final int ES_NONE
public static final int ES_ALL
public static final int ES_SEL
public static final int ES_SELALL
public static final int ES_ALLMOD
public static final int ES_SELMOD
public static final int ES_ALLLOST
public static final int ES_SELLOST
public static final int ES_ALLUNC
public static final int ES_SELUNC
public static final int ES_USER
public static final int ES_NEW
public static final int ES_POPUP
public boolean traceRequest
public boolean traceResponse
public boolean traceProcessing
public boolean traceTCPData
public boolean useUnchanged
public boolean useDirectory
public boolean execInCurDir
public boolean sendEntries
public boolean sendModifieds
public boolean sendEmptyMods
public boolean sendArguments
public boolean sendEntryFiles
public boolean sendModule
public boolean sendRootDirectory
public boolean includeNotifies
public boolean verificationOnly
public boolean guaranteeMsg
public boolean redirectOutput
public boolean displayReponse
public boolean handleUpdated
public boolean handleMerged
public boolean handleCopyFile
public boolean handleEntries
public boolean handleFlags
public boolean ignoreResult
public boolean allowOverWrites
public boolean saveTempFiles
public boolean stickyIsSet
public boolean staticDirIsSet
public java.lang.String validRequests
public boolean queueResponse
public CVSResponseHandler responseHandler
public boolean forceModifieds
public int gzipStreamLevel
public boolean allowGzipFileMode
public boolean gzipFileMode
public java.util.Vector notifies
Constructor Detail |
public CVSRequest()
Method Detail |
public static java.lang.String getConnMethodName(int method)
protected void finalize() throws java.lang.Throwable
finalize
in class java.lang.Object
java.lang.Throwable
public java.lang.String getHostName()
public void setHostName(java.lang.String hostName)
hostName
- The new hostname for the request's CVS Server.public int getPort()
public void setPort(int port)
port
- The new port number for the request's CVS server.public boolean isPServer()
public void setPServer(boolean isPServer)
public CVSUserInterface getUserInterface()
public void setUserInterface(CVSUserInterface ui)
public java.lang.String getUserName()
public void setUserName(java.lang.String userName)
public java.lang.String getPassword()
public void setPassword(java.lang.String password)
public java.lang.String getServerCommand()
public void setServerCommand(java.lang.String command)
public int getConnectionMethod()
public void setConnectionMethod(int method)
public java.lang.String getRshProcess()
public void setRshProcess(java.lang.String rshProcess)
public int getGzipStreamLevel()
public void setGzipStreamLevel(int level)
public CVSEntry getDirEntry()
public void setDirEntry(CVSEntry dirEntry)
public java.lang.String getLocalDirectory()
public void setLocalDirectory(java.lang.String localDirectory)
localDirectory
- The new local directory for the request.public java.io.File getLocalFile(CVSEntry entry)
public java.lang.String getRootDirectory()
public void setRootDirectory(java.lang.String rootDirectory)
rootDirectory
- The new root directory for the request.public java.lang.String getRepository()
public void setRepository(java.lang.String repository)
repository
- The request's repository.public java.lang.String getRootRepository()
public void setRootRepository(java.lang.String repository)
repository
- The request's ROOT repository.public CVSResponseHandler getResponseHandler()
public void setResponseHandler(CVSResponseHandler responseHandler)
public CVSEntryVector getEntries()
public void setEntries(CVSEntryVector entries)
entries
- The new list of entries for this request.public int getEntrySelector()
public CVSArgumentVector getArguments()
public void setArguments(CVSArgumentVector arguments)
arguments
- The new list of argument for this request.public void appendArguments(CVSArgumentVector newArgs)
public CVSArgumentVector getGlobalArguments()
public void setGlobalArguments(CVSArgumentVector arguments)
arguments
- The new list of argument for this request.public void appendGlobalArguments(CVSArgumentVector newArgs)
public java.lang.String getCommand()
public void setCommand(java.lang.String command)
command
- The new command for this request.public java.lang.String[] getSetVariables()
public void setSetVariables(java.lang.String[] vars)
vars
- The new user set variables.public java.util.Hashtable getStickys()
public void setStickys(java.util.Hashtable stickys)
stickys
- The new Hashtable of this request's 'Sticky' settings.public java.util.Hashtable getStatics()
public void setStatics(java.util.Hashtable statics)
statics
- The new Hashtable of 'Static-directory' settings.public java.lang.String getCheckInProgram()
public void setCheckInProgram(java.lang.String program)
program
- The new checkin-program name.public java.lang.String getUpdateProgram()
public void setUpdateProgram(java.lang.String program)
program
- The new update-program name.public boolean isRedirected()
public void redirectLine(java.lang.String line)
public void setRedirectWriter(java.io.PrintWriter writer)
public void endRedirection()
public static int parseEntriesSelector(char selectCh)
public void parseArgumentString(java.lang.String argStr)
argStr
- The argument string to be parsed.public boolean parseControlString(java.lang.String specification)
:command:select:request:response:arguments Where: command - is a valid cvs command name (e.g., 'update', 'co', 'diff') select - specifies which entries to apply command to request - is a valid cvs request specification reponse - is a valid cvs reponse handling specification arguments - is the remainder of the string taken as command arguments Refer to the CVSRequest Specification for details.
specification
- The CVSRequest Specification string to parse.
public java.lang.String getVerifyFailReason()
verifyRequest()
,
setVerifyFailReason(java.lang.String)
public void setVerifyFailReason(java.lang.String reason)
reason
- The reason for the current verification failure.verifyRequest()
,
getVerifyFailReason()
public boolean verifyRequest()
verifyRequest()
,
getVerifyFailReason()
public java.lang.String toString()
toString
in class java.lang.Object
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |