com.wewebu.ow.server.servlets
Interface OwMultifileDownload.OwContentArchiveEntry

All Known Implementing Classes:
OwMultifileDownload.OwBufferedSingleContentEntry, OwMultifileDownload.OwContentElementEntry, OwMultifileDownload.OwFolderArchiveEntry
Enclosing class:
OwMultifileDownload

protected static interface OwMultifileDownload.OwContentArchiveEntry

A content archive entry.
Each entry contains 0 or more files, can be zipped on a ZipOutputStream under a specified path and can be "served" on a HttpServletResponse.

Alfresco Workdesk
Copyright (c) Alfresco Software, Inc.
All rights reserved.

For licensing information read the license.txt file or
go to: http://wiki.alfresco.com


Method Summary
 int fileCount()
           
 void serveSingleFileOn(javax.servlet.http.HttpServletRequest request_p, javax.servlet.http.HttpServletResponse response_p, String fileName_p)
          Serializes the content on the response output stream of the HttpServletResponse parameter
 void zipIt(org.apache.tools.zip.ZipOutputStream zipOutputStream_p, String path_p)
          Adds the content represented by this archive entry to the specified ZipOutputStream
 

Method Detail

zipIt

void zipIt(org.apache.tools.zip.ZipOutputStream zipOutputStream_p,
           String path_p)
           throws Exception
Adds the content represented by this archive entry to the specified ZipOutputStream

Parameters:
zipOutputStream_p - the ZipOutputStream to serialize the content on
path_p - the path under which the content should be serialized on the ZipOutputStream
Throws:
Exception - if an error occurs during ZIP serialization (content access related errors should not be treated locally and logged)
Since:
3.1.0.0

serveSingleFileOn

void serveSingleFileOn(javax.servlet.http.HttpServletRequest request_p,
                       javax.servlet.http.HttpServletResponse response_p,
                       String fileName_p)
                       throws OwInvalidOperationException
Serializes the content on the response output stream of the HttpServletResponse parameter

Parameters:
request_p - HttpServletRequest
response_p - the HTTP response to serialize the content on
fileName_p - the name under which the content should be serialized
Throws:
OwInvalidOperationException - if the response serialization is not possible (for example because this entry contains multiple files)

fileCount

int fileCount()
Returns:
the number of files contained by this entry and all its sub entries


Copyright © 2013 Alfresco Business Solutions. All Rights Reserved.