Package org.tmatesoft.svn.cli.svn
Class SVNCommandEnvironment
- java.lang.Object
-
- org.tmatesoft.svn.cli.AbstractSVNCommandEnvironment
-
- org.tmatesoft.svn.cli.svn.SVNCommandEnvironment
-
- All Implemented Interfaces:
ISVNCanceller
,ISVNCommitHandler
public class SVNCommandEnvironment extends AbstractSVNCommandEnvironment implements ISVNCommitHandler
- Version:
- 1.3
-
-
Field Summary
Fields Modifier and Type Field Description private static java.lang.String
DEFAULT_LOG_MESSAGE_HEADER
private java.lang.String
myAuthorOfInterest
private java.lang.String
myChangelist
private java.util.Collection
myChangelists
private java.lang.String
myConfigDir
private java.util.Map
myConfigOptions
private SVNConflictStats
myConflictStats
private SVNDepth
myDepth
private java.lang.String
myDiffCommand
private java.lang.String
myEditorCommand
private java.lang.String
myEncoding
private SVNRevision
myEndRevision
private java.util.Collection
myExtensions
private byte[]
myFileData
private java.lang.String
myFilePath
private boolean
myIsAllowMixedRevisions
private boolean
myIsAutoProps
private boolean
myIsChangeOptionUsed
private boolean
myIsDescend
private boolean
myIsDryRun
private boolean
myIsForce
private boolean
myIsForceInteractive
private boolean
myIsForceLog
private boolean
myIsGitDiffFormat
private boolean
myIsHelp
private boolean
myIsIgnoreAncestry
private boolean
myIsIgnoreExternals
private boolean
myIsIgnoreKeywords
private boolean
myIsIgnoreProperties
private boolean
myIsIgnoreWhitespace
private boolean
myIsIncludeExternals
private boolean
myIsIncremental
private boolean
myIsKeepChangelist
private boolean
myIsKeepLocal
private boolean
myIsNoAuthCache
private boolean
myIsNoAutoProps
private boolean
myIsNoDiffAdded
private boolean
myIsNoDiffDeleted
private boolean
myIsNoIgnore
private boolean
myIsNoNewLine
private boolean
myIsNonInteractive
private boolean
myIsNoticeAncestry
private boolean
myIsNoUnlock
private boolean
myIsParents
private boolean
myIsPinExternals
private boolean
myIsPropertiesOnly
private boolean
myIsQuiet
private boolean
myIsRecordOnly
private boolean
myIsReIntegrate
private boolean
myIsRelocate
private boolean
myIsRemove
private boolean
myIsRemoveIgnored
private boolean
myIsRemoveUnversioned
private boolean
myIsReverseDiff
private boolean
myIsRevisionOptionUsed
private boolean
myIsRevprop
private boolean
myIsShowCopiesAsAdds
private boolean
myIsShowDiff
private boolean
myIsShowInhertiedProps
private boolean
myIsStopOnCopy
private boolean
myIsStrict
private boolean
myIsSummarize
private boolean
myIsTrustServerCertificate
private java.util.EnumSet<SVNCertificateFailureKind>
myIsTrustServerCertificateFailures
private boolean
myIsUpdate
private boolean
myIsUseMergeHistory
private boolean
myIsVerbose
private boolean
myIsVersion
private boolean
myIsWithAllRevprops
private boolean
myIsXML
private long
myLimit
private java.lang.String
myMessage
private java.lang.String
myNativeEOL
private java.lang.String
myNewTarget
private java.lang.String
myOldTarget
private java.lang.String
myPassword
private java.lang.String
myRegularExpression
private SVNConflictAcceptPolicy
myResolveAccept
private SVNProperties
myRevisionProperties
private java.util.List
myRevisionRanges
private java.util.Map
myServersOptions
private SVNDepth
mySetDepth
private java.lang.String
myShowItem
private SVNShowRevisionType
myShowRevsType
private SVNRevision
myStartRevision
private int
myStripCount
private java.util.List
myTargets
private java.lang.String
myUserName
-
Fields inherited from interface org.tmatesoft.svn.core.ISVNCanceller
NULL
-
-
Constructor Summary
Constructors Constructor Description SVNCommandEnvironment(java.lang.String programName, java.io.PrintStream out, java.io.PrintStream err, java.io.InputStream in)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected ISVNAuthenticationManager
createClientAuthenticationManager()
protected DefaultSVNOptions
createClientOptions()
private java.lang.String
createCommitMessageTemplate(SVNCommitItem[] items)
java.lang.String
getAuthorOfInterest()
java.lang.String
getChangelist()
java.lang.String[]
getChangelists()
java.util.Collection
getChangelistsCollection()
protected java.lang.String
getCommandLineClientName()
java.lang.String
getCommitMessage(java.lang.String message, SVNCommitItem[] commitables)
Handles the incoming initial log message and items intended for a commit and returns a new commit log message.SVNConflictStats
getConflictStats()
SVNDepth
getDepth()
java.lang.String
getDiffCommand()
SVNDiffOptions
getDiffOptions()
java.lang.String
getEditorCommand()
java.lang.String
getEncoding()
SVNRevision
getEndRevision()
java.util.Collection
getExtensions()
byte[]
getFileData()
long
getLimit()
java.lang.String
getMessage()
java.lang.String
getNativeEOL()
java.lang.String
getNewTarget()
java.lang.String
getOldTarget()
java.lang.String
getRegularExpression()
SVNConflictAcceptPolicy
getResolveAccept()
SVNProperties
getRevisionProperties()
SVNProperties
getRevisionProperties(java.lang.String message, SVNCommitItem[] commitables, SVNProperties revisionProperties)
Handles the incoming revision properties and returns filtered revision properties given the paths (represented bycommitables
) collected for committing and the commit log message.java.util.List
getRevisionRanges()
SVNDepth
getSetDepth()
java.lang.String
getShowItem()
SVNShowRevisionType
getShowRevisionType()
SVNRevision
getStartRevision()
int
getStripCount()
protected SVNCommand
getSVNCommand()
java.util.List
getTargets()
void
initClientManager()
protected void
initOption(SVNOptionValue optionValue)
protected void
initOptions(SVNCommandLine commandLine)
boolean
isAllowMixedRevisions()
boolean
isAllRevisionProperties()
boolean
isChangeOptionUsed()
boolean
isDryRun()
boolean
isForce()
boolean
isForceLog()
boolean
isGitDiffFormat()
boolean
isIgnoreAncestry()
boolean
isIgnoreKeywords()
boolean
isIgnoreProperties()
boolean
isIgnoreWhitespace()
boolean
isIncludeExternals()
boolean
isIncremental()
boolean
isKeepChangelist()
boolean
isKeepLocal()
boolean
isNoAutoProps()
boolean
isNoDiffAdded()
boolean
isNoDiffDeleted()
boolean
isNoIgnore()
boolean
isNoNewLine()
boolean
isNoticeAncestry()
boolean
isNoUnlock()
boolean
isParents()
boolean
isPinExternals()
boolean
isPropertiesOnly()
boolean
isQuiet()
boolean
isRecordOnly()
boolean
isReIntegrate()
boolean
isRelocate()
boolean
isRemove()
boolean
isRemoveIgnored()
boolean
isRemoveUnversioned()
boolean
isReverseDiff()
boolean
isRevisionOptionUsed()
boolean
isRevprop()
boolean
isShowCopiesAsAdds()
boolean
isShowDiff()
boolean
isShowInheritedProps()
boolean
isStopOnCopy()
boolean
isStrict()
boolean
isSummarize()
boolean
isUpdate()
boolean
isUseMergeHistory()
boolean
isVerbose()
boolean
isVersion()
boolean
isXML()
private void
parseRevisionProperty(SVNOptionValue optionValue)
protected java.lang.String
refineCommandName(java.lang.String commandName, SVNCommandLine commandLine)
protected void
validateOptions(SVNCommandLine commandLine)
-
Methods inherited from class org.tmatesoft.svn.cli.AbstractSVNCommandEnvironment
checkCancelled, combineTargets, createClientManager, dispose, getArguments, getClientManager, getCommand, getCommandName, getCommandName, getErr, getIn, getOptions, getOut, getProgramName, getRelativePath, getURLFromTarget, handleError, handleWarning, init, initCommand, isVersioned, parseRevision, popArgument, printCommitInfo, readFromFile, run, setArguments, setCancelled
-
-
-
-
Field Detail
-
DEFAULT_LOG_MESSAGE_HEADER
private static final java.lang.String DEFAULT_LOG_MESSAGE_HEADER
- See Also:
- Constant Field Values
-
myDepth
private SVNDepth myDepth
-
mySetDepth
private SVNDepth mySetDepth
-
myIsVerbose
private boolean myIsVerbose
-
myIsUpdate
private boolean myIsUpdate
-
myIsQuiet
private boolean myIsQuiet
-
myIsIncremental
private boolean myIsIncremental
-
myIsHelp
private boolean myIsHelp
-
myIsIgnoreExternals
private boolean myIsIgnoreExternals
-
myIsIgnoreKeywords
private boolean myIsIgnoreKeywords
-
myIsXML
private boolean myIsXML
-
myIsVersion
private boolean myIsVersion
-
myChangelist
private java.lang.String myChangelist
-
myIsNonInteractive
private boolean myIsNonInteractive
-
myIsForceInteractive
private boolean myIsForceInteractive
-
myIsNoAuthCache
private boolean myIsNoAuthCache
-
myUserName
private java.lang.String myUserName
-
myPassword
private java.lang.String myPassword
-
myConfigDir
private java.lang.String myConfigDir
-
myIsDescend
private boolean myIsDescend
-
myIsNoIgnore
private boolean myIsNoIgnore
-
myIsRevprop
private boolean myIsRevprop
-
myIsStrict
private boolean myIsStrict
-
myStartRevision
private SVNRevision myStartRevision
-
myEndRevision
private SVNRevision myEndRevision
-
myIsForce
private boolean myIsForce
-
myFilePath
private java.lang.String myFilePath
-
myFileData
private byte[] myFileData
-
myTargets
private java.util.List myTargets
-
myEncoding
private java.lang.String myEncoding
-
myMessage
private java.lang.String myMessage
-
myIsForceLog
private boolean myIsForceLog
-
myEditorCommand
private java.lang.String myEditorCommand
-
myDiffCommand
private java.lang.String myDiffCommand
-
myRevisionProperties
private SVNProperties myRevisionProperties
-
myIsNoUnlock
private boolean myIsNoUnlock
-
myIsDryRun
private boolean myIsDryRun
-
myIsRecordOnly
private boolean myIsRecordOnly
-
myIsUseMergeHistory
private boolean myIsUseMergeHistory
-
myExtensions
private java.util.Collection myExtensions
-
myIsIgnoreAncestry
private boolean myIsIgnoreAncestry
-
myIsShowCopiesAsAdds
private boolean myIsShowCopiesAsAdds
-
myNativeEOL
private java.lang.String myNativeEOL
-
myIsRelocate
private boolean myIsRelocate
-
myIsNoAutoProps
private boolean myIsNoAutoProps
-
myIsAutoProps
private boolean myIsAutoProps
-
myIsKeepChangelist
private boolean myIsKeepChangelist
-
myIsParents
private boolean myIsParents
-
myIsKeepLocal
private boolean myIsKeepLocal
-
myResolveAccept
private SVNConflictAcceptPolicy myResolveAccept
-
myIsRemove
private boolean myIsRemove
-
myNewTarget
private java.lang.String myNewTarget
-
myOldTarget
private java.lang.String myOldTarget
-
myIsNoticeAncestry
private boolean myIsNoticeAncestry
-
myIsSummarize
private boolean myIsSummarize
-
myIsNoDiffDeleted
private boolean myIsNoDiffDeleted
-
myIsNoDiffAdded
private boolean myIsNoDiffAdded
-
myLimit
private long myLimit
-
myIsStopOnCopy
private boolean myIsStopOnCopy
-
myIsChangeOptionUsed
private boolean myIsChangeOptionUsed
-
myIsRevisionOptionUsed
private boolean myIsRevisionOptionUsed
-
myIsWithAllRevprops
private boolean myIsWithAllRevprops
-
myIsReIntegrate
private boolean myIsReIntegrate
-
myIsTrustServerCertificate
private boolean myIsTrustServerCertificate
-
myIsTrustServerCertificateFailures
private java.util.EnumSet<SVNCertificateFailureKind> myIsTrustServerCertificateFailures
-
myIsAllowMixedRevisions
private boolean myIsAllowMixedRevisions
-
myRevisionRanges
private java.util.List myRevisionRanges
-
myShowRevsType
private SVNShowRevisionType myShowRevsType
-
myChangelists
private java.util.Collection myChangelists
-
myAuthorOfInterest
private java.lang.String myAuthorOfInterest
-
myRegularExpression
private java.lang.String myRegularExpression
-
myConfigOptions
private java.util.Map myConfigOptions
-
myServersOptions
private java.util.Map myServersOptions
-
myIsGitDiffFormat
private boolean myIsGitDiffFormat
-
myIsShowDiff
private boolean myIsShowDiff
-
myIsPropertiesOnly
private boolean myIsPropertiesOnly
-
myIsIgnoreProperties
private boolean myIsIgnoreProperties
-
myIsReverseDiff
private boolean myIsReverseDiff
-
myIsIgnoreWhitespace
private boolean myIsIgnoreWhitespace
-
myStripCount
private int myStripCount
-
myIsShowInhertiedProps
private boolean myIsShowInhertiedProps
-
myIsIncludeExternals
private boolean myIsIncludeExternals
-
myShowItem
private java.lang.String myShowItem
-
myIsNoNewLine
private boolean myIsNoNewLine
-
myIsPinExternals
private boolean myIsPinExternals
-
myIsRemoveUnversioned
private boolean myIsRemoveUnversioned
-
myIsRemoveIgnored
private boolean myIsRemoveIgnored
-
myConflictStats
private SVNConflictStats myConflictStats
-
-
Method Detail
-
initClientManager
public void initClientManager() throws SVNException
- Overrides:
initClientManager
in classAbstractSVNCommandEnvironment
- Throws:
SVNException
-
refineCommandName
protected java.lang.String refineCommandName(java.lang.String commandName, SVNCommandLine commandLine) throws SVNException
- Specified by:
refineCommandName
in classAbstractSVNCommandEnvironment
- Throws:
SVNException
-
createClientOptions
protected DefaultSVNOptions createClientOptions() throws SVNException
- Specified by:
createClientOptions
in classAbstractSVNCommandEnvironment
- Throws:
SVNException
-
createClientAuthenticationManager
protected ISVNAuthenticationManager createClientAuthenticationManager()
- Specified by:
createClientAuthenticationManager
in classAbstractSVNCommandEnvironment
-
initOptions
protected void initOptions(SVNCommandLine commandLine) throws SVNException
- Overrides:
initOptions
in classAbstractSVNCommandEnvironment
- Throws:
SVNException
-
initOption
protected void initOption(SVNOptionValue optionValue) throws SVNException
- Specified by:
initOption
in classAbstractSVNCommandEnvironment
- Throws:
SVNException
-
getSVNCommand
protected SVNCommand getSVNCommand()
-
validateOptions
protected void validateOptions(SVNCommandLine commandLine) throws SVNException
- Overrides:
validateOptions
in classAbstractSVNCommandEnvironment
- Throws:
SVNException
-
getCommandLineClientName
protected java.lang.String getCommandLineClientName()
- Specified by:
getCommandLineClientName
in classAbstractSVNCommandEnvironment
-
isReIntegrate
public boolean isReIntegrate()
-
getShowRevisionType
public SVNShowRevisionType getShowRevisionType()
-
isChangeOptionUsed
public boolean isChangeOptionUsed()
-
isRevisionOptionUsed
public boolean isRevisionOptionUsed()
-
getChangelist
public java.lang.String getChangelist()
-
getChangelists
public java.lang.String[] getChangelists()
-
getChangelistsCollection
public java.util.Collection getChangelistsCollection()
-
isIgnoreKeywords
public boolean isIgnoreKeywords()
-
getDepth
public SVNDepth getDepth()
-
getSetDepth
public SVNDepth getSetDepth()
-
isVerbose
public boolean isVerbose()
-
isNoIgnore
public boolean isNoIgnore()
-
isUpdate
public boolean isUpdate()
-
isQuiet
public boolean isQuiet()
-
isIncremental
public boolean isIncremental()
-
isRevprop
public boolean isRevprop()
-
isStrict
public boolean isStrict()
-
getRevisionRanges
public java.util.List getRevisionRanges()
-
getStartRevision
public SVNRevision getStartRevision()
-
getEndRevision
public SVNRevision getEndRevision()
-
isXML
public boolean isXML()
-
isVersion
public boolean isVersion()
-
isForce
public boolean isForce()
-
getEncoding
public java.lang.String getEncoding()
-
getFileData
public byte[] getFileData()
-
getTargets
public java.util.List getTargets()
-
isForceLog
public boolean isForceLog()
-
getEditorCommand
public java.lang.String getEditorCommand()
-
getDiffCommand
public java.lang.String getDiffCommand()
-
getMessage
public java.lang.String getMessage()
-
getRevisionProperties
public SVNProperties getRevisionProperties()
-
isDryRun
public boolean isDryRun()
-
isIgnoreAncestry
public boolean isIgnoreAncestry()
-
isShowCopiesAsAdds
public boolean isShowCopiesAsAdds()
-
isGitDiffFormat
public boolean isGitDiffFormat()
-
isPropertiesOnly
public boolean isPropertiesOnly()
-
isIgnoreProperties
public boolean isIgnoreProperties()
-
isReverseDiff
public boolean isReverseDiff()
-
isIgnoreWhitespace
public boolean isIgnoreWhitespace()
-
isShowDiff
public boolean isShowDiff()
-
isUseMergeHistory
public boolean isUseMergeHistory()
-
isRecordOnly
public boolean isRecordOnly()
-
getExtensions
public java.util.Collection getExtensions()
-
getNativeEOL
public java.lang.String getNativeEOL()
-
isRelocate
public boolean isRelocate()
-
isNoUnlock
public boolean isNoUnlock()
-
isKeepChangelist
public boolean isKeepChangelist()
-
isParents
public boolean isParents()
-
isKeepLocal
public boolean isKeepLocal()
-
getResolveAccept
public SVNConflictAcceptPolicy getResolveAccept()
-
isRemove
public boolean isRemove()
-
isSummarize
public boolean isSummarize()
-
isNoticeAncestry
public boolean isNoticeAncestry()
-
isNoDiffDeleted
public boolean isNoDiffDeleted()
-
isNoDiffAdded
public boolean isNoDiffAdded()
-
getOldTarget
public java.lang.String getOldTarget()
-
getNewTarget
public java.lang.String getNewTarget()
-
getAuthorOfInterest
public java.lang.String getAuthorOfInterest()
-
isNoAutoProps
public boolean isNoAutoProps()
-
getRegularExpression
public java.lang.String getRegularExpression()
-
getLimit
public long getLimit()
-
isStopOnCopy
public boolean isStopOnCopy()
-
isAllRevisionProperties
public boolean isAllRevisionProperties()
-
getStripCount
public int getStripCount()
-
getDiffOptions
public SVNDiffOptions getDiffOptions() throws SVNException
- Throws:
SVNException
-
isAllowMixedRevisions
public boolean isAllowMixedRevisions()
-
isShowInheritedProps
public boolean isShowInheritedProps()
-
getShowItem
public java.lang.String getShowItem()
-
isNoNewLine
public boolean isNoNewLine()
-
isPinExternals
public boolean isPinExternals()
-
isRemoveUnversioned
public boolean isRemoveUnversioned()
-
isRemoveIgnored
public boolean isRemoveIgnored()
-
isIncludeExternals
public boolean isIncludeExternals()
-
getConflictStats
public SVNConflictStats getConflictStats()
-
getRevisionProperties
public SVNProperties getRevisionProperties(java.lang.String message, SVNCommitItem[] commitables, SVNProperties revisionProperties) throws SVNException
Description copied from interface:ISVNCommitHandler
Handles the incoming revision properties and returns filtered revision properties given the paths (represented bycommitables
) collected for committing and the commit log message.Only the returned filtered revision properties will be set on a new committed revision.
- Specified by:
getRevisionProperties
in interfaceISVNCommitHandler
- Parameters:
message
- log message for commitcommitables
- paths to commitrevisionProperties
- initial revision properties- Returns:
- filtered revision properties
- Throws:
SVNException
-
getCommitMessage
public java.lang.String getCommitMessage(java.lang.String message, SVNCommitItem[] commitables) throws SVNException
Description copied from interface:ISVNCommitHandler
Handles the incoming initial log message and items intended for a commit and returns a new commit log message.- Specified by:
getCommitMessage
in interfaceISVNCommitHandler
- Parameters:
message
- an initial log messagecommitables
- an array of items to be committed- Returns:
- a new log message string or NULL to cancel commit operation.
- Throws:
SVNException
-
parseRevisionProperty
private void parseRevisionProperty(SVNOptionValue optionValue) throws SVNException
- Throws:
SVNException
-
createCommitMessageTemplate
private java.lang.String createCommitMessageTemplate(SVNCommitItem[] items)
-
-