Class FSFS


  • public class FSFS
    extends java.lang.Object
    Version:
    1.3
    Author:
    TMate Software Ltd.
    • Constructor Detail

      • FSFS

        public FSFS​(java.io.File repositoryRoot)
    • Method Detail

      • setHooksEnabled

        public void setHooksEnabled​(boolean enabled)
      • isHooksEnabled

        public boolean isHooksEnabled()
      • getDBFormat

        public int getDBFormat()
      • getMaxFilesPerDirectory

        public long getMaxFilesPerDirectory()
      • getReposFormat

        public int getReposFormat()
      • isUseLogAddressing

        public boolean isUseLogAddressing()
      • getDBRoot

        public java.io.File getDBRoot()
      • getWriteLockFile

        public java.io.File getWriteLockFile()
      • getUUIDFile

        public java.io.File getUUIDFile()
      • getDBRevsDir

        public java.io.File getDBRevsDir()
      • getDBLocksDir

        public java.io.File getDBLocksDir()
      • getFSTypeFile

        public java.io.File getFSTypeFile()
      • getTransactionsParentDir

        public java.io.File getTransactionsParentDir()
      • getRepositoryRoot

        public java.io.File getRepositoryRoot()
      • getRevisionPropertiesRoot

        public java.io.File getRevisionPropertiesRoot()
      • getRepositoryFormatFile

        public java.io.File getRepositoryFormatFile()
      • getDBFormatFile

        public java.io.File getDBFormatFile()
      • getNodeOriginsDir

        public java.io.File getNodeOriginsDir()
      • getCurrentFile

        public java.io.File getCurrentFile()
      • getRepositoryCacheFile

        public java.io.File getRepositoryCacheFile()
      • writeDBFormat

        public void writeDBFormat​(int format,
                                  long maxFilesPerDir,
                                  boolean overwrite)
                           throws SVNException
        Throws:
        SVNException
      • listTransactions

        public java.util.Map listTransactions()
      • getNewRevisionFile

        public java.io.File getNewRevisionFile​(long newRevision)
      • getNewRevisionPropertiesFile

        public java.io.File getNewRevisionPropertiesFile​(long newRevision)
      • getTransactionDir

        public java.io.File getTransactionDir​(java.lang.String txnID)
      • setYoungestRevisionCache

        public void setYoungestRevisionCache​(long revision)
      • getRevisionPropertiesFile

        public java.io.File getRevisionPropertiesFile​(long revision,
                                                      boolean returnMissing)
                                               throws SVNException
        Throws:
        SVNException
      • getNextIDsFile

        public java.io.File getNextIDsFile​(java.lang.String txnID)
      • writeNextIDs

        public void writeNextIDs​(java.lang.String txnID,
                                 java.lang.String nodeID,
                                 java.lang.String copyID)
                          throws SVNException
        Throws:
        SVNException
      • getRevPropPackSize

        protected long getRevPropPackSize()
      • isRepSharingAllowed

        public boolean isRepSharingAllowed()
      • getBlockSize

        public long getBlockSize()
      • getL2PPageSize

        public long getL2PPageSize()
      • getP2LPageSize

        public long getP2LPageSize()
      • getTransactionPropertiesFile

        public java.io.File getTransactionPropertiesFile​(java.lang.String txnID)
      • getTransactionProtoRevsDir

        public java.io.File getTransactionProtoRevsDir()
      • getTransactionProtoRevFile

        public java.io.File getTransactionProtoRevFile​(java.lang.String txnID)
      • getTransactionProtoRevLockFile

        public java.io.File getTransactionProtoRevLockFile​(java.lang.String txnID)
      • getTransactionRevNodeFile

        public java.io.File getTransactionRevNodeFile​(FSID id)
      • writeTxnNodeRevision

        public void writeTxnNodeRevision​(java.io.OutputStream revNodeFile,
                                         FSRevisionNode revNode)
                                  throws java.io.IOException
        Throws:
        java.io.IOException
      • getLock

        public SVNLock getLock​(java.lang.String repositoryPath,
                               boolean haveWriteLock,
                               boolean throwError)
                        throws SVNException
        Throws:
        SVNException
      • fetchLockFromDigestFile

        public SVNLock fetchLockFromDigestFile​(java.io.File digestFile,
                                               java.lang.String repositoryPath,
                                               java.util.Collection children)
                                        throws SVNException
        Throws:
        SVNException
      • getDigestFileFromRepositoryPath

        public java.io.File getDigestFileFromRepositoryPath​(java.lang.String repositoryPath)
                                                     throws SVNException
        Throws:
        SVNException
      • getDigestFromRepositoryPath

        public java.lang.String getDigestFromRepositoryPath​(java.lang.String repositoryPath)
                                                     throws SVNException
        Throws:
        SVNException
      • unlockPath

        public void unlockPath​(java.lang.String path,
                               java.lang.String token,
                               java.lang.String username,
                               boolean breakLock,
                               boolean enableHooks)
                        throws SVNException
        Throws:
        SVNException
      • lockPath

        public SVNLock lockPath​(java.lang.String path,
                                java.lang.String token,
                                java.lang.String username,
                                java.lang.String comment,
                                java.util.Date expirationDate,
                                long currentRevision,
                                boolean stealLock,
                                boolean isDAVComment)
                         throws SVNException
        Throws:
        SVNException
      • getDeletedRevision

        public long getDeletedRevision​(java.lang.String path,
                                       long startRev,
                                       long endRev)
                                throws SVNException
        Throws:
        SVNException
      • getNodeOrigin

        public java.lang.String getNodeOrigin​(java.lang.String nodeID)
                                       throws SVNException
        Throws:
        SVNException
      • supportsMergeInfo

        public boolean supportsMergeInfo()
      • findRepositoryRoot

        public static java.io.File findRepositoryRoot​(java.io.File path)
      • findRepositoryRoot

        public static java.lang.String findRepositoryRoot​(java.lang.String host,
                                                          java.lang.String path)
      • getDefaultMaxFilesPerDirectory

        public static long getDefaultMaxFilesPerDirectory()
      • setDefaultMaxFilesPerDirectory

        public static void setDefaultMaxFilesPerDirectory​(long maxFilesPerDirectory)
      • isPackedRevision

        public boolean isPackedRevision​(long revision)
      • getPackedBaseRevision

        public long getPackedBaseRevision​(long revision)
      • getNodeOriginFile

        protected java.io.File getNodeOriginFile​(java.lang.String nodeID)
      • getTransactionRevisionPrototypeFile

        protected FSFile getTransactionRevisionPrototypeFile​(java.lang.String txnID)
      • getTransactionChangesFile

        protected FSFile getTransactionChangesFile​(java.lang.String txnID)
      • getTransactionRevisionNodeChildrenFile

        protected FSFile getTransactionRevisionNodeChildrenFile​(FSID txnID)
      • getAbsoluteRevisionPath

        protected java.io.File getAbsoluteRevisionPath​(long revision)
                                                throws SVNException
        Throws:
        SVNException
      • getTransactionRevisionNodePropertiesFile

        protected FSFile getTransactionRevisionNodePropertiesFile​(FSID id)
      • getPackedRevPath

        protected java.io.File getPackedRevPath​(long revision,
                                                java.lang.String kind)
                                         throws SVNException
        Throws:
        SVNException
      • getPackedRevPropsShardPath

        protected java.io.File getPackedRevPropsShardPath​(long revision)
                                                   throws SVNException
        Throws:
        SVNException
      • getPackDir

        protected java.io.File getPackDir​(long revision)
      • getPackFile

        protected java.io.File getPackFile​(long revision)
      • getManifestFile

        protected java.io.File getManifestFile​(long revision)
      • getMinUnpackedRevFile

        protected java.io.File getMinUnpackedRevFile()
      • getTransactionCurrentFile

        protected java.io.File getTransactionCurrentFile()
      • getTransactionCurrentLockFile

        protected java.io.File getTransactionCurrentLockFile()
      • getConfigFile

        public java.io.File getConfigFile()
      • writeCurrentFile

        protected void writeCurrentFile​(long revision,
                                        java.lang.String nextNodeID,
                                        java.lang.String nextCopyID)
                                 throws SVNException,
                                        java.io.IOException
        Throws:
        SVNException
        java.io.IOException
      • lookupOffsetInProtoIndex

        protected long lookupOffsetInProtoIndex​(FSFile file,
                                                java.lang.String txnId,
                                                long itemIndex)
                                         throws SVNException
        Throws:
        SVNException
      • getRevisionPropertiesDbPath

        public java.io.File getRevisionPropertiesDbPath()
      • getMinUnpackedRevPropPath

        public java.io.File getMinUnpackedRevPropPath()
      • isCompressPackedRevprops

        public boolean isCompressPackedRevprops()