se.datadosen.jalbum
Class AlbumManifest

java.lang.Object
  extended by se.datadosen.jalbum.AlbumManifest

public class AlbumManifest
extends java.lang.Object

Representation of the set of files in an album along with their size and modification date A manifest file is uploaded along with the album in order to facilitate publishing album udpdates. The manifest is stored as a zip file containing either a plain text representation or a DES encrypted text representation in order to prevent web users from figuring out what files an album consists of


Field Summary
static java.lang.String MANIFEST_NAME
           
 
Constructor Summary
AlbumManifest(RemoteFS remoteFS, java.lang.String remoteDir)
          Get existing manifest from remote server
AlbumManifest(java.util.Set<RemoteFile> content)
          Create based on local album files
 
Method Summary
 byte[] getBytes()
          Get the raw bytes, compressed using standard zip.
 java.util.Set<RemoteFile> getContent()
           
 java.lang.String toString()
           
 void write(RemoteFS remoteFS, java.lang.String remoteDir)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

MANIFEST_NAME

public static final java.lang.String MANIFEST_NAME
See Also:
Constant Field Values
Constructor Detail

AlbumManifest

public AlbumManifest(java.util.Set<RemoteFile> content)
Create based on local album files


AlbumManifest

public AlbumManifest(RemoteFS remoteFS,
                     java.lang.String remoteDir)
              throws java.io.IOException,
                     RemoteFSException
Get existing manifest from remote server

Throws:
java.io.IOException
RemoteFSException
Method Detail

getContent

public java.util.Set<RemoteFile> getContent()

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

getBytes

public byte[] getBytes()
                throws java.io.IOException
Get the raw bytes, compressed using standard zip. The content is either plain UTF-8 encoded text or DES encrypted UTF-8 encoded text

Throws:
java.io.IOException

write

public void write(RemoteFS remoteFS,
                  java.lang.String remoteDir)
           throws java.io.IOException,
                  RemoteFSException
Throws:
java.io.IOException
RemoteFSException