public class UpdateCommand extends BasicCommand implements TemporaryFileCreator
| Constructor and Description |
|---|
UpdateCommand()
Construct a new update command.
|
| Modifier and Type | Method and Description |
|---|---|
Builder |
createBuilder(EventManager eventManager)
Method that is called while the command is being executed.
|
java.io.File |
createTempFile(java.lang.String filename)
Method that creates a temporary file.
|
void |
execute(ClientServices client,
EventManager eventManager)
Execute the command.
|
java.lang.String |
getCVSArguments()
Returns the arguments of the command in the command-line style.
|
java.lang.String |
getCVSCommand()
This method returns how the command would looklike when typed on the
command line.
|
KeywordSubstitutionOptions |
getKeywordSubst()
Getter for property keywordSubst.
|
java.lang.String |
getMergeRevision1()
Getter for property mergeRevision1.
|
java.lang.String |
getMergeRevision2()
Getter for property mergeRevision2.
|
java.lang.String |
getOptString()
String returned by this method defines which options are available for this particular command
|
java.lang.String |
getUpdateByDate()
Getter for property updateByDate.
|
java.lang.String |
getUpdateByRevision()
Getter for property updateByRevision.
|
boolean |
isBuildDirectories()
Returns whether to build directories.
|
boolean |
isCleanCopy()
Returns whether to get a clean copy from the server.
|
boolean |
isPipeToOutput()
Getter for property pipeToOutput.
|
boolean |
isPruneDirectories()
Returns whether to prune directories.
|
boolean |
isResetStickyOnes()
Getter for property resetStickyOnes.
|
boolean |
isUseHeadIfNotFound()
Getter for property useHeadIfNotFound.
|
void |
messageSent(MessageEvent e)
Called when the server wants to send a message to be displayed to
the user.
|
void |
resetCVSCommand()
Resets all switches in the command.
|
void |
setBuildDirectories(boolean buildDirectories)
Set whether to build directories.
|
void |
setCleanCopy(boolean cleanCopy)
Sets whether to get a clean copy from the server.
|
boolean |
setCVSCommand(char opt,
java.lang.String optArg)
Takes the arguments and by parsing them, sets the command.
|
void |
setKeywordSubst(KeywordSubstitutionOptions keywordSubst)
Setter for property keywordSubst.
|
void |
setMergeRevision1(java.lang.String mergeRevision1)
Setter for property mergeRevision1.
|
void |
setMergeRevision2(java.lang.String mergeRevision2)
Setter for property mergeRevision2.
|
void |
setPipeToOutput(boolean pipeToOutput)
Setter for property pipeToOutput.
|
void |
setPruneDirectories(boolean pruneDirectories)
Set whether to prune directories.
|
void |
setResetStickyOnes(boolean resetStickyOnes)
Setter for property resetStickyOnes.
|
void |
setUpdateByDate(java.lang.String updateByDate)
Setter for property updateByDate.
|
void |
setUpdateByRevision(java.lang.String updateByRevision)
Setter for property updateByRevision.
|
void |
setUseHeadIfNotFound(boolean useHeadIfNotFound)
Setter for property useHeadIfNotFound.
|
getFileEndingWith, getFiles, getRecursive, getXthFile, isRecursive, setFiles, setRecursivecommandTerminated, messageSent, setBuilderclone, fileAdded, fileInfoGenerated, fileRemoved, fileToRemove, fileUpdated, getDisplayName, getGlobalOptions, getLocalDirectory, getLocalPath, getRelativeToLocalPathInUnixStyle, hasFailed, moduleExpanded, setDisplayNamepublic Builder createBuilder(EventManager eventManager)
createBuilder in class BuildableCommandpublic void setBuildDirectories(boolean buildDirectories)
public boolean isBuildDirectories()
public void setCleanCopy(boolean cleanCopy)
public boolean isCleanCopy()
public void setPruneDirectories(boolean pruneDirectories)
public boolean isPruneDirectories()
public void execute(ClientServices client, EventManager eventManager) throws CommandException, AuthenticationException
execute in class BasicCommandclient - the client services object that provides any necessary
services to this command, including the ability to actually
process all the requestsCommandException - if an error occurs executing the commandAuthenticationExceptionpublic boolean isPipeToOutput()
public void setPipeToOutput(boolean pipeToOutput)
pipeToOutput - New value of property pipeToOutput.public boolean isResetStickyOnes()
public void setResetStickyOnes(boolean resetStickyOnes)
resetStickyOnes - New value of property resetStickyOnes.public boolean isUseHeadIfNotFound()
public void setUseHeadIfNotFound(boolean useHeadIfNotFound)
useHeadIfNotFound - New value of property useHeadIfNotFound.public java.lang.String getUpdateByDate()
public void setUpdateByDate(java.lang.String updateByDate)
updateByDate - New value of property updateByDate.public java.lang.String getUpdateByRevision()
public void setUpdateByRevision(java.lang.String updateByRevision)
updateByRevision - New value of property updateByRevision.public KeywordSubstitutionOptions getKeywordSubst()
public void setKeywordSubst(KeywordSubstitutionOptions keywordSubst)
keywordSubst - New value of property keywordSubst.public java.io.File createTempFile(java.lang.String filename)
throws java.io.IOException
createTempFile in interface TemporaryFileCreatorjava.io.IOExceptionpublic java.lang.String getCVSCommand()
getCVSCommand in class Commandpublic java.lang.String getCVSArguments()
getCVSArguments in class Commandpublic boolean setCVSCommand(char opt,
java.lang.String optArg)
setCVSCommand in class Commandpublic void resetCVSCommand()
resetCVSCommand in class Commandpublic void messageSent(MessageEvent e)
messageSent in interface CVSListenermessageSent in class BuildableCommande - the eventpublic java.lang.String getOptString()
getOptString in class Commandpublic java.lang.String getMergeRevision1()
public void setMergeRevision1(java.lang.String mergeRevision1)
mergeRevision1 - New value of property mergeRevision1.public java.lang.String getMergeRevision2()
public void setMergeRevision2(java.lang.String mergeRevision2)
mergeRevision2 - New value of property mergeRevision2.