com.caucho.env.repository
Interface Repository

All Known Implementing Classes:
AbstractRepository, ClusterRepository, DeployClient, FileRepository, WebAppDeployClient

public interface Repository

The Repository is a collection of archives organized by a tag map. Each archive is equivalent to a .jar file or a directory, consisting of the binary data Blobs, the directory name Tree, and a .git Commit item to track versions. The tag map is a map of strings to tag entries, where the entry is the sha1 of the .git Commit root of the archive, and metadata.


Method Summary
 void addListener(java.lang.String tagName, RepositoryTagListener listener)
          Adds a tag change listener
 java.lang.String commitArchive(CommitBuilder commitTag, java.io.InputStream is)
          Adds and commits a jar/zip archive.
 java.lang.String commitArchive(CommitBuilder commitTag, Path contentArchive)
          Adds and commits a jar/zip archive
 java.lang.String commitPath(CommitBuilder commitTag, Path contentDirectory)
          Adds and commits a full path, recursively
 java.lang.String getTagContentHash(java.lang.String tag)
          Convenience method returning the tag's contentHash.
 java.util.Map<java.lang.String,RepositoryTagEntry> getTagMap()
          Returns the current read-only tag map.
 void removeListener(java.lang.String tagName, RepositoryTagListener listener)
          Adds a tag change listener
 boolean removeTag(CommitBuilder commitTag)
          Removes a tag
 

Method Detail

getTagMap

java.util.Map<java.lang.String,RepositoryTagEntry> getTagMap()
Returns the current read-only tag map.


getTagContentHash

java.lang.String getTagContentHash(java.lang.String tag)
Convenience method returning the tag's contentHash.


commitArchive

java.lang.String commitArchive(CommitBuilder commitTag,
                               Path contentArchive)
Adds and commits a jar/zip archive


commitArchive

java.lang.String commitArchive(CommitBuilder commitTag,
                               java.io.InputStream is)
Adds and commits a jar/zip archive.


commitPath

java.lang.String commitPath(CommitBuilder commitTag,
                            Path contentDirectory)
Adds and commits a full path, recursively


removeTag

boolean removeTag(CommitBuilder commitTag)
Removes a tag

Parameters:
tagName - the symbolic tag for the repository
user - the user adding a tag.
server - the server adding a tag.
message - user's message for the commit

addListener

void addListener(java.lang.String tagName,
                 RepositoryTagListener listener)
Adds a tag change listener


removeListener

void removeListener(java.lang.String tagName,
                    RepositoryTagListener listener)
Adds a tag change listener