|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--allensoft.javacvs.client.CVSRequestBatch
Defines a sequential list of requests that should be performed. This allows a client to open only one connection to the server and perform all the requests for that server in a batch. This reduces the number of times that the user has to authenticate theirself to the server. For example, you could add requests to add new files, remove files and commit the changes all in one connection.
Inner Class Summary | |
static interface |
CVSRequestBatch.RequestInstantiator
Instantiates request objects for use by the addRequests
method. |
Constructor Summary | |
CVSRequestBatch()
|
|
CVSRequestBatch(CVSRequest request)
Creates a new request batch with the supplied request added to it. |
Method Summary | |
void |
addAddRequests(java.io.File[] files,
AddOptions options,
KeywordSubstitutionModeClassifier classifier)
A convenience method that adds AddRequest objects for all the repository locations that the files correspond to. |
void |
addCommitRequests(java.io.File[] files,
CommitOptions options)
A convenience method that adds CommitRequest objects for all the repository locations that the files correspond to. |
void |
addDiffRequests(java.io.File[] files,
DiffOptions options)
A convenience method that adds DiffRequest objects for all the repository locations that the files correspond to. |
void |
addLogRequests(java.io.File[] files,
LogOptions options)
A convenience method that adds LogRequest objects for all the repository locations that the files correspond to. |
void |
addRemoveRequests(java.io.File[] files,
RemoveOptions options)
A convenience method that adds RemoveRequest objects for all the repository locations that the files correspond to. |
void |
addRequest(CVSRequest request)
Adds a new request to the end of the list. |
void |
addRequests(java.io.File[] files,
CVSRequestBatch.RequestInstantiator instantiator)
Adds multiple requests to (possibly) different servers for the files specified. |
void |
addStatusRequests(java.io.File[] files)
A convenience method that adds StatusRequest objects for all the repository locations that the files correspond to. |
void |
addTagRequests(java.io.File[] files,
java.lang.String sTag,
TagOptions options)
A convenience method that adds CommitRequest objects for all the repository locations that the files correspond to. |
void |
addUpdateRequests(java.io.File[] files,
CheckoutOptions options)
A convenience method that adds UpdateRequest objects for all the repository locations that the files correspond to. |
int |
getRequestCount()
Gets the number of requests added to this CVSRequests object. |
CVSRequest[] |
getRequests()
Gets all requests added to this request batch. |
CVSResponse[] |
getResponsesOfType(java.lang.Class type)
Gets all responses of the specified type. |
void |
removeRequest(CVSRequest request)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public CVSRequestBatch()
public CVSRequestBatch(CVSRequest request)
Method Detail |
public int getRequestCount()
public CVSRequest[] getRequests()
public CVSResponse[] getResponsesOfType(java.lang.Class type)
public void addRequest(CVSRequest request)
public void removeRequest(CVSRequest request)
public void addRequests(java.io.File[] files, CVSRequestBatch.RequestInstantiator instantiator) throws java.io.IOException, CVSException
CVSRequest
can only correspond to one repository location it is necessary to
send multiple requests to the different servers. This method will determine how many different
repository locations all the files correspond to. It will build up one request for each
location using the RequestInstantiator
object to instantiate the type of request
that should be sent. Each request will then be added to the list of requests to perform.
The chances are that all the files correspond to one repository location so only one request will
be added but this can't always be guaranteed. The CVSClient will send all requests for one repository
at a time and connect to as many as needed to perform a batch of requests.files
- files that are to be operated on by requests.instantiator
- object that instantiates the type of request to perform on the files.public void addUpdateRequests(java.io.File[] files, CheckoutOptions options) throws java.io.IOException, CVSException
public void addCommitRequests(java.io.File[] files, CommitOptions options) throws java.io.IOException, CVSException
public void addAddRequests(java.io.File[] files, AddOptions options, KeywordSubstitutionModeClassifier classifier) throws java.io.IOException, CVSException
public void addRemoveRequests(java.io.File[] files, RemoveOptions options) throws java.io.IOException, CVSException
public void addStatusRequests(java.io.File[] files) throws java.io.IOException, CVSException
public void addDiffRequests(java.io.File[] files, DiffOptions options) throws java.io.IOException, CVSException
public void addLogRequests(java.io.File[] files, LogOptions options) throws java.io.IOException, CVSException
public void addTagRequests(java.io.File[] files, java.lang.String sTag, TagOptions options) throws java.io.IOException, CVSException
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |