Class AbstractVCS

java.lang.Object
fr.ifremer.isisfish.vcs.AbstractVCS
All Implemented Interfaces:
VCS, FileFilter
Direct Known Subclasses:
VCSNone, VCSSVN

public abstract class AbstractVCS extends Object implements VCS
Abstract VCS implementation.
Version:
$Revision$ Last update : $Date$ By : $Author$
Author:
poussin
  • Field Details

    • listeners

      protected Set<VetoableActionListener> listeners
    • localRepository

      protected File localRepository
    • protocol

      protected String protocol
    • host

      protected String host
    • path

      protected String path
    • sshKeyFile

      protected File sshKeyFile
    • login

      protected String login
    • password

      protected String password
    • writeable

      protected boolean writeable
  • Constructor Details

  • Method Details

    • addVetoableActionListener

      public void addVetoableActionListener(VetoableActionListener l)
      Description copied from interface: VCS
      Ajout un listener pouvant interdire les actions du vcs
      Specified by:
      addVetoableActionListener in interface VCS
      Parameters:
      l - listener to add
    • remoteVetoableActionListener

      public void remoteVetoableActionListener(VetoableActionListener l)
      Description copied from interface: VCS
      Supprime un listener pouvant interdire les actions du vcs
      Specified by:
      remoteVetoableActionListener in interface VCS
      Parameters:
      l - listener to remove
    • setWriteable

      public void setWriteable(boolean value)
      Description copied from interface: VCS
      Permit to force repository to read-only if value is false, otherwise use normal rules.
      Specified by:
      setWriteable in interface VCS
      Parameters:
      value - writable
    • fireAction

      protected boolean fireAction(VCSActionEvent e, File... files)
    • getLocalRepository

      public File getLocalRepository()
      Description copied from interface: VCS
      Get local repository directory
      Specified by:
      getLocalRepository in interface VCS
      Returns:
      local repository
    • setLocalRepository

      public void setLocalRepository(File localRepository)
    • getProtocol

      public String getProtocol()
      Description copied from interface: VCS
      Get protocol.
      Specified by:
      getProtocol in interface VCS
      Returns:
      protocol
    • setProtocol

      public void setProtocol(String protocol) throws VCSException
      checkProtocol is automatically done
      Specified by:
      setProtocol in interface VCS
      Parameters:
      protocol -
      Throws:
      VCSException
    • getHost

      public String getHost()
      Description copied from interface: VCS
      Get host.
      Specified by:
      getHost in interface VCS
      Returns:
      host
    • setHost

      public void setHost(String host) throws VCSException
      checkProtocol is automatically done
      Specified by:
      setHost in interface VCS
      Parameters:
      host -
      Throws:
      VCSException
    • getPath

      public String getPath()
      Description copied from interface: VCS
      Get repository path.
      Specified by:
      getPath in interface VCS
      Returns:
      path
    • setPath

      public void setPath(String path) throws VCSException
      checkProtocol is automatically done
      Specified by:
      setPath in interface VCS
      Parameters:
      path -
      Throws:
      VCSException
    • getSshKeyFile

      public File getSshKeyFile()
      Description copied from interface: VCS
      Get ssh key file.
      Specified by:
      getSshKeyFile in interface VCS
      Returns:
      ssh key file
    • setSshKeyFile

      public void setSshKeyFile(File sshKeyFile)
      Description copied from interface: VCS
      Change ssk key file to use.
      Specified by:
      setSshKeyFile in interface VCS
      Parameters:
      sshKeyFile - new ssh kay file
    • getLogin

      public String getLogin()
      Description copied from interface: VCS
      Get login.
      Specified by:
      getLogin in interface VCS
      Returns:
      login
    • setLogin

      public void setLogin(String login) throws VCSException
      checkProtocol is automatically done
      Specified by:
      setLogin in interface VCS
      Parameters:
      login -
      Throws:
      VCSException
    • getPassword

      public String getPassword()
      Description copied from interface: VCS
      Get password.
      Specified by:
      getPassword in interface VCS
      Returns:
      password
    • setPassword

      public void setPassword(String password)
      Description copied from interface: VCS
      Change password.
      Specified by:
      setPassword in interface VCS
      Parameters:
      password - password
    • accept

      public boolean accept(File pathname)
      Specified by:
      accept in interface FileFilter
    • isVersionnableFile

      public boolean isVersionnableFile(File file)
      Description copied from interface: VCS
      Check if file can be put in vcs repository. For example when you used CVS, you must not put CVS file.

      default refused .svn, CVS and ~ filename Must be override, this default implementation return true.

      Specified by:
      isVersionnableFile in interface VCS
      Returns:
      true if file is versionnable