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(java.lang.String uri)
           
 DownloadInfo createDownloadSession(java.lang.String uri)
           
 java.lang.String createUploadSession()
           
 byte[] downloadBytes(long sid, int size)
          Downloads the next 'size' bytes from the given download session.
 boolean hasStream(java.lang.String uri)
           
 void removeStream(java.lang.String uri)
           
 void uploadBytes(java.lang.String uri, byte[] bytes)
          Uploads the given bytes.
 

Method Detail

createDownloadSession

DownloadInfo createDownloadSession(java.lang.String uri)
                                   throws java.io.IOException
Throws:
java.io.IOException

closeDownloadSession

void closeDownloadSession(long sid)
                          throws java.io.IOException
Throws:
java.io.IOException

createUploadSession

java.lang.String createUploadSession()
                                     throws java.io.IOException
Throws:
java.io.IOException

closeUploadSession

void closeUploadSession(java.lang.String uri)
                        throws java.io.IOException
Throws:
java.io.IOException

hasStream

boolean hasStream(java.lang.String uri)

removeStream

void removeStream(java.lang.String uri)

uploadBytes

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

Parameters:
uri - the stream uri
bytes - the bytes to upload
Throws:
java.io.IOException

downloadBytes

byte[] downloadBytes(long sid,
                     int size)
                     throws java.io.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:
java.io.IOException

Nuxeo Enterprise Platform 5.4

Copyright © 2010 Nuxeo SAS. All Rights Reserved.