Package com.microstrategy.webapi
Class StreamingContext
- java.lang.Object
-
- com.microstrategy.webapi.StreamingContext
-
- All Implemented Interfaces:
IContentConsumer
- Direct Known Subclasses:
AbstractExportTransform.IServerPlaintextExportStreamingContext
,EncodeSpecialStreamingContext
,TranscodingStreamingContext
public class StreamingContext extends java.lang.Object implements IContentConsumer
- Since:
- MicroStrategy Web 9.0.0
-
-
Field Summary
Fields Modifier and Type Field Description protected boolean
_canRedirect
protected ContainerServices
_containerServices
protected int
_contentLength
protected java.lang.Exception
_ex
static java.lang.String
CONTENT_LENGTH_NAME
protected static int
STREAMING_BUF_SIZE
-
Constructor Summary
Constructors Constructor Description StreamingContext(ContainerServices cs)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
canRedirect()
void
consume(int contentLength, java.io.InputStream src)
Request to a consumer to consume specified number of bytes from the input streamvoid
consume(java.lang.String decode, int contentLength, java.io.InputStream src)
Request to a consumer to consume specified number of bytes from the input streamint
getContextLength()
java.lang.Exception
getException()
Returns the exception that caused consumption interruption.protected void
setContentLength(int contentLength)
-
-
-
Field Detail
-
_ex
protected java.lang.Exception _ex
-
STREAMING_BUF_SIZE
protected static final int STREAMING_BUF_SIZE
- See Also:
- Constant Field Values
-
CONTENT_LENGTH_NAME
public static final java.lang.String CONTENT_LENGTH_NAME
- See Also:
- Constant Field Values
-
_containerServices
protected ContainerServices _containerServices
-
_canRedirect
protected boolean _canRedirect
-
_contentLength
protected int _contentLength
-
-
Constructor Detail
-
StreamingContext
public StreamingContext(ContainerServices cs)
-
-
Method Detail
-
consume
public void consume(int contentLength, java.io.InputStream src) throws java.lang.Exception
Description copied from interface:IContentConsumer
Request to a consumer to consume specified number of bytes from the input stream- Specified by:
consume
in interfaceIContentConsumer
- Parameters:
contentLength
- number of bytes to consume.src
- source input stream- Throws:
java.lang.Exception
-
consume
public void consume(java.lang.String decode, int contentLength, java.io.InputStream src) throws java.lang.Exception
Description copied from interface:IContentConsumer
Request to a consumer to consume specified number of bytes from the input stream- Specified by:
consume
in interfaceIContentConsumer
- Parameters:
decode
- decoder charset namecontentLength
- number of bytes to consume.src
- source input stream- Throws:
java.lang.Exception
-
getException
public java.lang.Exception getException()
Description copied from interface:IContentConsumer
Returns the exception that caused consumption interruption.- Specified by:
getException
in interfaceIContentConsumer
- Returns:
- the exception that caused consumption interruption.
-
canRedirect
public boolean canRedirect()
-
getContextLength
public int getContextLength()
- Specified by:
getContextLength
in interfaceIContentConsumer
-
setContentLength
protected void setContentLength(int contentLength)
-
-