Nuxeo Enterprise Platform 5.4

org.nuxeo.runtime.services.streaming
Interface StreamingServer

All Known Implementing Classes:
StreamManagerServer

public interface StreamingServer

Author:
Bogdan Stefanescu

Method Summary
 void closeDownloadSession(long sid)
           
 void closeUploadSession(String uri)
           
 DownloadInfo createDownloadSession(String uri)
           
 String createUploadSession()
           
 byte[] downloadBytes(long sid, int size)
          Downloads the next 'size' bytes from the given download session.
 boolean hasStream(String uri)
           
 void removeStream(String uri)
           
 void uploadBytes(String uri, byte[] bytes)
          Uploads the given bytes.
 

Method Detail

createDownloadSession

DownloadInfo createDownloadSession(String uri)
                                   throws IOException
Throws:
IOException

closeDownloadSession

void closeDownloadSession(long sid)
                          throws IOException
Throws:
IOException

createUploadSession

String createUploadSession()
                           throws IOException
Throws:
IOException

closeUploadSession

void closeUploadSession(String uri)
                        throws IOException
Throws:
IOException

hasStream

boolean hasStream(String uri)

removeStream

void removeStream(String uri)

uploadBytes

void uploadBytes(String uri,
                 byte[] bytes)
                 throws IOException
Uploads the given bytes.

Parameters:
uri - the stream uri
bytes - the bytes to upload
Throws:
IOException

downloadBytes

byte[] downloadBytes(long sid,
                     int size)
                     throws IOException
Downloads the next 'size' bytes from the given download session.

Parameters:
sid - the download session
size - the number of bytes to download
Returns:
the downloaded byte array or null if no more bytes are available
Throws:
IOException

Nuxeo Enterprise Platform 5.4

Copyright © 2011 Nuxeo SAS. All Rights Reserved.