Class DfsRepository

    • Constructor Detail

      • DfsRepository

        protected DfsRepository​(DfsRepositoryBuilder builder)
        Initialize a DFS repository.
        Parameters:
        builder - description of the repository.
    • Method Detail

      • getObjectDatabase

        public abstract DfsObjDatabase getObjectDatabase()
        Get the object database which stores this repository's data.
        Specified by:
        getObjectDatabase in class Repository
        Returns:
        the object database which stores this repository's data.
      • getDescription

        public DfsRepositoryDescription getDescription()
        Get the description of this repository.
        Returns:
        the description of this repository.
      • exists

        public boolean exists()
                       throws IOException
        Check if the repository already exists.
        Returns:
        true if the repository exists; false if it is new.
        Throws:
        IOException - the repository cannot be checked.
      • create

        public void create​(boolean bare)
                    throws IOException
        Create a new Git repository initializing the necessary files and directories.
        Specified by:
        create in class Repository
        Parameters:
        bare - if true, a bare repository (a repository without a working directory) is created.
        Throws:
        IOException - in case of IO problem
      • getConfig

        public StoredConfig getConfig()
        Get the configuration of this repository.
        Specified by:
        getConfig in class Repository
        Returns:
        the configuration of this repository.
      • getIdentifier

        public String getIdentifier()
        Get repository identifier.
        Specified by:
        getIdentifier in class Repository
        Returns:
        repository identifier. The returned identifier has to be unique within a given Git server.
      • notifyIndexChanged

        public void notifyIndexChanged​(boolean internal)
        Notify that the index changed by firing an IndexChangedEvent.
        Specified by:
        notifyIndexChanged in class Repository
        Parameters:
        internal - true if the index was changed by the same JGit process