public interface VCS extends FileFilter
| Modifier and Type | Interface and Description |
|---|---|
static class |
VCS.Status
VCS Status type.
|
| Modifier and Type | Field and Description |
|---|---|
static String |
TYPE_CVS
CVS VCS Type
|
static String |
TYPE_NONE
None CVS Type
|
static String |
TYPE_SVN
SVN VCS Type
|
static String |
VCS_HOST_NAME
remote server adresse (ip or serveur name) ex: svn.forge.codelutin.com
|
static String |
VCS_PATH
remote repository path ex: /svnroot/isis-fish-data
|
static String |
VCS_PROTOCOL
can be http, ssh, pserver, ...
|
static String |
VCS_TYPE
can be None, CVS or SVN.
|
static String |
VCS_USER_NAME
user login to access vcs ex: bpoussin
|
static String |
VCS_USER_PASSWORD
user passwd or passphrase (protocol dependent) to access vcs ex: xxxxxxxx
|
| Modifier and Type | Method and Description |
|---|---|
void |
add(List<File> files,
String msg)
Add and commit file in server repository.
|
void |
addVetoableActionListener(VetoableActionListener l)
Ajout un listener pouvant interdire les actions du vcs
|
List<File> |
checkFileStatus()
Verifie si tous les fichiers du repository local sont les dernieres
version par rapport au serveur.
|
void |
checkout(org.nuiton.util.Version tag,
boolean recurse)
get repository on server and put it in localdir.
|
void |
checkProtocol()
Verifie la connexion et si le protocole a change, switch le repository
pour utiliser le nouveau protocole.
|
void |
cleanup(File path)
Cleanup a directory, removing all lock.
|
void |
commit(List<File> files,
String msg)
Commit specified files, if files is null, all files are committed.
|
void |
delete(List<File> files,
String msg)
Delete and commit files in server repository.
|
Map<File,String> |
getChanglog(List<File> files)
Return all changelog between local file version and remote repository
file version.
|
String |
getDiff(File file)
show diff between local file and repository file.
|
List<String> |
getFileList(File directory)
Return list of all file on directory on remote server.
|
String |
getHost()
Get host.
|
File |
getLocalRepository()
Get local repository directory
|
VCS.Status |
getLocalStatus(File file)
Get file local status.
|
String |
getLogin()
Get login.
|
String |
getPassword()
Get password.
|
String |
getPath()
Get repository path.
|
String |
getProtocol()
Get protocol.
|
File |
getSshKeyFile()
Get ssh key file.
|
String |
getTag()
Retourne le tag reellement utilise, par exemple si on a fait un
setTag(3.2.0) cette methode retourne "/tags/3.2.0", pour setTag(null)
on retourne "/trunk"
|
List<File> |
getUpdatedFile()
get list of new or modified files on server.
|
boolean |
haveUpdate()
Ask if there are some new or modified files on server.
|
boolean |
isConnected()
Get connection state.
|
boolean |
isOnRemote(File file)
Check if file is available on server.
|
boolean |
isTag(org.nuiton.util.Version version)
Look on server if version is tag repository.
|
boolean |
isUpToDate(File file)
Check if file is up-to-date.
|
boolean |
isValidLocalRepository()
Return true, if local repository is valid repository for actual vcs.
|
boolean |
isVersionnableFile(File file)
Check if file can be put in vcs repository.
|
boolean |
isWriteable()
Return true, if local repository is writable.
|
void |
remoteVetoableActionListener(VetoableActionListener l)
Supprime un listener pouvant interdire les actions du vcs
|
void |
setHost(String host)
Change host.
|
void |
setLogin(String login)
Change login.
|
void |
setPassword(String password)
Change password.
|
void |
setPath(String path)
Change path.
|
void |
setProtocol(String protocol)
Change protocol.
|
void |
setSshKeyFile(File sshKeyFile)
Change ssk key file to use.
|
List<File> |
setTag(org.nuiton.util.Version version)
Change repository tag, used when we use some tag and we want to go to
trunk.
|
void |
setWriteable(boolean value)
Permit to force repository to read-only if value is false, otherwise
use normal rules.
|
List<File> |
update(File file,
boolean recurse)
Update file.
|
acceptstatic final String TYPE_CVS
static final String TYPE_NONE
static final String TYPE_SVN
static final String VCS_TYPE
static final String VCS_PROTOCOL
static final String VCS_HOST_NAME
static final String VCS_PATH
static final String VCS_USER_NAME
static final String VCS_USER_PASSWORD
void addVetoableActionListener(VetoableActionListener l)
l - listener to addvoid remoteVetoableActionListener(VetoableActionListener l)
l - listener to removeFile getLocalRepository()
boolean isValidLocalRepository()
boolean isWriteable()
throws VCSException
VCSExceptionvoid setWriteable(boolean value)
value - writablevoid cleanup(File path) throws VCSException
path - path to cleanupVCSExceptionvoid commit(List<File> files, String msg) throws VCSException
files - files to commitmsg - message used to commitVCSExceptionvoid add(List<File> files, String msg) throws VCSException
files - list of file to addmsg - message for commitVCSExceptionvoid checkout(org.nuiton.util.Version tag,
boolean recurse)
throws VCSException
tag - tag to used, null = /trunk other is tags/[tag]recurse - if file is directory checkout sub fileVCSExceptionvoid delete(List<File> files, String msg) throws VCSException
files - file to deletemsg - message for commitVCSExceptionMap<File,String> getChanglog(List<File> files) throws VCSException
files - VCSExceptionString getDiff(File file) throws VCSException
file - file to get diffVCSExceptionVCS.Status getLocalStatus(File file) throws VCSException
file - file to get statusVCSExceptionList<String> getFileList(File directory) throws VCSException
directory - VCSExceptionList<File> getUpdatedFile() throws VCSException
VCSExceptionboolean haveUpdate()
throws VCSException
VCSExceptionboolean isConnected()
boolean isOnRemote(File file) throws VCSException
file - file to checkVCSExceptionboolean isTag(org.nuiton.util.Version version)
throws VCSException
version - version number like 3.2VCSExceptionboolean isUpToDate(File file) throws VCSException
file - file to checkVCSExceptionboolean isVersionnableFile(File file)
default refused .svn, CVS and ~ filename Must be override, this default implementation return true.
file - true if file is versionnableList<File> update(File file, boolean recurse) throws VCSException
file - files to updaterecurse - VCSExceptionvoid checkProtocol()
throws VCSException
VCSExceptionList<File> checkFileStatus() throws VCSException
VCSExceptionString getHost()
String getLogin()
String getPassword()
String getPath()
String getProtocol()
File getSshKeyFile()
String getTag() throws VCSException
VCSExceptionList<File> setTag(org.nuiton.util.Version version) throws VCSException
version - version to go, if null trunk is used, otherwize
tags/version is usedVCSExceptionvoid setHost(String host) throws VCSException
host - new host.VCSExceptionvoid setLogin(String login) throws VCSException
login - new loginVCSExceptionvoid setPassword(String password)
password - passwordvoid setPath(String path) throws VCSException
path - new pathVCSExceptionvoid setProtocol(String protocol) throws VCSException
protocol - VCSExceptionvoid setSshKeyFile(File sshKeyFile)
sshKeyFile - new ssh kay fileCopyright © 1999–2013 CodeLutin. All rights reserved.