|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface ClientAPI
Define the QVCS-Enterprise client API interface.
A vanilla Java application can use this API to retrieve data from a QVCS-Enterprise server. Currently, the API only supports retrieval of version control history information from the server; it does not support performing any version control operations, nor does it support fetching actual files or file revisions. All calls on this API are fully synchronous.
If you need to perform version control operations, you should try using the custom ant task included with QVCS-Enterprise.
In typical use, a client would:
ClientFactory.createClientAPIContext()
static method to create a ClientAPIContext object, and fill in the username/password, serverIP address, and port number values in that
object.ClientFactory.createClientAPI()
static method to create an instance of a class that implements this
ClientAPI interface.getProjectList(ClientAPIContext)
method on the ClientAPI object returned by the factory to get a list of projects available from the
QVCS-Enterprise server, passing in the ClientAPIContext object that you have filled in with the username/password, etc. data.getViewList(ClientAPIContext)
method on this interface to get a list of available views for the given project.getProjectDirectoryList(ClientAPIContext)
method on this interface to get a list of all the directories for the given
project/view.getFileInfoList(ClientAPIContext)
method on this interface to get a list of FileInfo
objects; each
object provides summary information for one file.getRevisionInfoList(ClientAPIContext)
to get a list of RevisionInfo
objects; each object
provides summary information about a revision associated with the selected file.The recurse flag in the ClientAPIContext can be used when you want to see all the files in a given directory tree. When the flag is true, then the List of FileInfo objects returned from the getFileInfoList method will include all the files in the appendedPath directory and all the files in all sub-directories beneath the appended path directory.
Method Summary | |
---|---|
java.util.List<FileInfo> |
getFileInfoList(ClientAPIContext clientAPIContext)
Get the list of FileInfo objects for the directory specified via the ClientAPIContext.setAppendedPath(java.lang.String) attribute on the clientAPIContext object. |
java.util.List<java.lang.String> |
getProjectDirectoryList(ClientAPIContext clientAPIContext)
Get the list of directories for the given project/view. |
java.util.List<java.lang.String> |
getProjectList(ClientAPIContext clientAPIContext)
Get the list of projects from the QVCS-Enterprise server. |
java.util.List<RevisionInfo> |
getRevisionInfoList(ClientAPIContext clientAPIContext)
Get the list of RevisionInfo objects for the file specified by the clientAPIContext. |
java.util.List<java.lang.String> |
getViewList(ClientAPIContext clientAPIContext)
Get the list of views for a given project. |
Method Detail |
---|
java.util.List<java.lang.String> getProjectList(ClientAPIContext clientAPIContext) throws ClientAPIException
clientAPIContext
- the client API context object used to define the username/password and server connection information.
ClientAPIException
- if there are any problems.java.util.List<java.lang.String> getViewList(ClientAPIContext clientAPIContext) throws ClientAPIException
clientAPIContext
- the client API context object used to define the username/password, server connection information, and project name.
ClientAPIException
- if there are any problems, or if the requested project is not found.java.util.List<java.lang.String> getProjectDirectoryList(ClientAPIContext clientAPIContext) throws ClientAPIException
clientAPIContext
- the client API context object used to define the username/password, server connection information, project name, and view name.
ClientAPIException
- if there are any problems.java.util.List<FileInfo> getFileInfoList(ClientAPIContext clientAPIContext) throws ClientAPIException
FileInfo
objects for the directory specified via the ClientAPIContext.setAppendedPath(java.lang.String)
attribute on the clientAPIContext object. If you set
the recurse flag to true (via the ClientAPIContext.setRecurseFlag(boolean)
attribute), then the returned List will contain elements for the directory identified by the appended path,
as well as all the directories beneath that directory.
clientAPIContext
- the client API context object used to define the username/password, server connection information, project name, view name, appended path, and optionally, the recurse
flag.
FileInfo
objects; one per file.
ClientAPIException
- if there are any problems.java.util.List<RevisionInfo> getRevisionInfoList(ClientAPIContext clientAPIContext) throws ClientAPIException
RevisionInfo
objects for the file specified by the clientAPIContext.
clientAPIContext
- the client API context object used to define the username/password, server connection information, project name, view name, appended path, and the file name.
RevisionInfo
objects for the file specified by the clientAPIContext. The List could be empty if the file is not under version control. Be careful to identify the
location of the file correctly -- i.e. the project name, view name, appended path, and file name must be correct in order for the server to find the file and report its revision information.
ClientAPIException
- if there are any problems.
|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |