All Implemented Interfaces:
ContentDescriptor ,
AbstractWriteHandle ,
BinaryWriteHandle ,
CtsQueryWriteHandle ,
DocumentMetadataWriteHandle ,
DocumentPatchHandle ,
GenericWriteHandle ,
JSONWriteHandle ,
QueryOptionsWriteHandle ,
RuleWriteHandle ,
StructureWriteHandle ,
TextWriteHandle ,
TriplesWriteHandle ,
XMLWriteHandle
An OutputStreamHandle generates output during
writing. You define a class that implements the OutputStreamSender
interface. When the client is ready to write to the server, it
calls the write() method of the class with an OutputStream. That
is, the write() method generates the output to be written to the
server. The OutputStreamSender implementer is typically an
anonymous class. Initialize the OutputStreamHandle with the
OutputStreamSender implementer before passing the
OutputStreamHandle to the write() method of a document
manager.
Field Summary
Constructor Summary
Constructors
Zero-argument constructor.
Initializes the handle with an outputstream
sender providing the callback that writes content to the database
via an output stream.
Method Summary
All Methods Instance Methods Concrete Methods
Returns the output stream sender that writes the
content.
boolean
Returns whether the content can be resent to the
output stream if the request must be retried.
void
Assigns an output stream sender providing the
callback that writes content to the database via an output
stream.
void
Specifies whether the content can be resent to
the output stream if the request must be retried.
Assigns an output stream sender providing the
callback that writes content to the database and returns the handle
as a fluent convenience.
Specifies the format of the content and returns
the handle as a fluent convenience.
Specifies the mime type of the content and
returns the handle as a fluent convenience.
Specifies whether the content can be resent to
the output stream and returns the handle as a fluent
convenience.
Methods inherited from
class com.marklogic.client.impl.HandleImplementation
getPointInTimeQueryTimestamp, receiveAs, receiveContent,
setPointInTimeQueryTimestamp,
setResponseServerTimestamp
Methods
inherited from class java.lang.Object
clone , equals , finalize , getClass , hashCode , notify , notifyAll , toString , wait , wait , wait
Constructor Details
OutputStreamHandle
public OutputStreamHandle ()
Zero-argument constructor.
OutputStreamHandle
Initializes the handle with an outputstream
sender providing the callback that writes content to the database
via an output stream.
Parameters:
sender - the processor that sends content to the
database
Method Details
withFormat
Specifies the format of the content and returns
the handle as a fluent convenience.
Parameters:
format - the format of the content
Returns:
this handle
withMimetype
Specifies the mime type of the content and
returns the handle as a fluent convenience.
Parameters:
mimetype - the mime type of the content
Returns:
this handle
isResendable
public boolean isResendable ()
Returns whether the content can be resent to the
output stream if the request must be retried. The default is
false.
Overrides:
isResendable in
class com.marklogic.client.impl.HandleImplementation<OperationNotSupported ,OutputStreamSender >
setResendable
public void setResendable (boolean resendable)
Specifies whether the content can be resent to
the output stream if the request must be retried.
Overrides:
setResendable in
class com.marklogic.client.impl.HandleImplementation<OperationNotSupported ,OutputStreamSender >
withResendable
Specifies whether the content can be resent to
the output stream and returns the handle as a fluent
convenience.
Parameters:
resendable - true if the content can be sent
again
Returns:
this handle
get
Returns the output stream sender that writes the
content.
Returns:
the output stream sender
set
Assigns an output stream sender providing the
callback that writes content to the database via an output
stream.
Parameters:
sender - the output stream sender
with
Assigns an output stream sender providing the
callback that writes content to the database and returns the handle
as a fluent convenience.
Parameters:
sender - the output stream sender
Returns:
this handle
sendContent
Overrides:
sendContent in
class com.marklogic.client.impl.HandleImplementation<OperationNotSupported ,OutputStreamSender >
Copyright (c) 2010-2025 Progress
Software Corporation and/or its subsidiaries or affiliates. All
Rights Reserved.