Interface RepositoryServerHandle

  • All Known Subinterfaces:
    RemoteRepositoryServerHandle

    public interface RepositoryServerHandle
    RepositoryServerHandle provides access to a repository server.
    • Method Detail

      • anonymousAccessAllowed

        boolean anonymousAccessAllowed()
                                throws java.io.IOException
        Throws:
        java.io.IOException - if an IO error occurs
      • isReadOnly

        boolean isReadOnly()
                    throws java.io.IOException
        Throws:
        java.io.IOException - if an IO error occurs
      • createRepository

        RepositoryHandle createRepository​(java.lang.String name)
                                   throws java.io.IOException
        Create a new repository on the server. The newly created RepositoryHandle will contain a unique project ID for the client.
        Parameters:
        name - repository name. This ID will be used to identify and maintain checkout data.
        Returns:
        handle to new repository.
        Throws:
        DuplicateFileException
        UserAccessException
        java.io.IOException - if an IO error occurs
      • getRepository

        RepositoryHandle getRepository​(java.lang.String name)
                                throws java.io.IOException
        Get a handle to an existing repository.
        Parameters:
        name - repository name.
        Returns:
        repository handle or null if repository does not exist.
        Throws:
        UserAccessException - if user does not have permission to access repository
        java.io.IOException - if an IO error occurs
      • deleteRepository

        void deleteRepository​(java.lang.String name)
                       throws java.io.IOException
        Delete a repository.
        Parameters:
        name - repository name.
        Throws:
        UserAccessException - if user does not have permission to delete repository
        java.io.IOException - if an IO error occurs
      • getRepositoryNames

        java.lang.String[] getRepositoryNames()
                                       throws java.io.IOException
        Returns a list of all repository names which are accessable by the current user.
        Throws:
        java.io.IOException - if an IO error occurs
      • getUser

        java.lang.String getUser()
                          throws java.io.IOException
        Returns current user for which this handle belongs.
        Throws:
        java.io.IOException - if an IO error occurs
      • getAllUsers

        java.lang.String[] getAllUsers()
                                throws java.io.IOException
        Returns a list of all known users.
        Throws:
        java.io.IOException - if an IO error occurs
      • canSetPassword

        boolean canSetPassword()
                        throws java.io.IOException
        Returns true if the user's password can be changed.
        Throws:
        java.io.IOException - if an IO error occurs
      • getPasswordExpiration

        long getPasswordExpiration()
                            throws java.io.IOException
        Returns the amount of time in milliseconds until the user's password will expire.
        Returns:
        time until expiration or -1 if it will not expire
        Throws:
        java.io.IOException - if an IO error occurs
      • setPassword

        boolean setPassword​(char[] saltedSHA256PasswordHash)
                     throws java.io.IOException
        Set the password for the user.
        Parameters:
        saltedSHA256PasswordHash - SHA256 salted password hash
        Throws:
        java.io.IOException - if an IO error occurs
      • connected

        void connected()
                throws java.io.IOException
        Verify that server is alive and connected.
        Throws:
        java.io.IOException - if connection verification fails