blob: cade6212f407d4f4b582e9ca8db5370173ab204d [file] [log] [blame]
<!DOCTYPE HTML>
<html lang="en">
<head>
<!-- Generated by javadoc (17) -->
<title>StreamSenderMessage (Qpid ProtonJ2 Parent 1.0.0-M18 API)</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<meta name="description" content="declaration: package: org.apache.qpid.protonj2.client, interface: StreamSenderMessage">
<meta name="generator" content="javadoc/ClassWriterImpl">
<link rel="stylesheet" type="text/css" href="../../../../../stylesheet.css" title="Style">
<script type="text/javascript" src="../../../../../script.js"></script>
</head>
<body class="class-declaration-page">
<script type="text/javascript">var evenRowColor = "even-row-color";
var oddRowColor = "odd-row-color";
var tableTab = "table-tab";
var activeTableTab = "active-table-tab";
</script>
<noscript>
<div>JavaScript is disabled on your browser.</div>
</noscript>
<div class="flex-box">
<header role="banner" class="flex-header">
<nav role="navigation">
<!-- ========= START OF TOP NAVBAR ======= -->
<div class="top-nav" id="navbar-top">
<div class="skip-nav"><a href="#skip-navbar-top" title="Skip navigation links">Skip navigation links</a></div>
<ul id="navbar-top-firstrow" class="nav-list" title="Navigation">
<li><a href="../../../../../index.html">Overview</a></li>
<li><a href="package-summary.html">Package</a></li>
<li class="nav-bar-cell1-rev">Class</li>
<li><a href="class-use/StreamSenderMessage.html">Use</a></li>
<li><a href="package-tree.html">Tree</a></li>
<li><a href="../../../../../help-doc.html#class">Help</a></li>
</ul>
</div>
<div class="sub-nav">
<div>
<ul class="sub-nav-list">
<li>Summary:&nbsp;</li>
<li>Nested&nbsp;|&nbsp;</li>
<li>Field&nbsp;|&nbsp;</li>
<li>Constr&nbsp;|&nbsp;</li>
<li><a href="#method-summary">Method</a></li>
</ul>
<ul class="sub-nav-list">
<li>Detail:&nbsp;</li>
<li>Field&nbsp;|&nbsp;</li>
<li>Constr&nbsp;|&nbsp;</li>
<li><a href="#method-detail">Method</a></li>
</ul>
</div>
</div>
<!-- ========= END OF TOP NAVBAR ========= -->
<span class="skip-nav" id="skip-navbar-top"></span></nav>
</header>
<div class="flex-content">
<main role="main">
<!-- ======== START OF CLASS DATA ======== -->
<div class="header">
<div class="sub-title"><span class="package-label-in-type">Package</span>&nbsp;<a href="package-summary.html">org.apache.qpid.protonj2.client</a></div>
<h1 title="Interface StreamSenderMessage" class="title">Interface StreamSenderMessage</h1>
</div>
<section class="class-description" id="class-description">
<dl class="notes">
<dt>All Superinterfaces:</dt>
<dd><code><a href="AdvancedMessage.html" title="interface in org.apache.qpid.protonj2.client">AdvancedMessage</a>&lt;<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/io/OutputStream.html" title="class or interface in java.io" class="external-link">OutputStream</a>&gt;</code>, <code><a href="Message.html" title="interface in org.apache.qpid.protonj2.client">Message</a>&lt;<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/io/OutputStream.html" title="class or interface in java.io" class="external-link">OutputStream</a>&gt;</code></dd>
</dl>
<hr>
<div class="type-signature"><span class="modifiers">public interface </span><span class="element-name type-name-label">StreamSenderMessage</span><span class="extends-implements">
extends <a href="AdvancedMessage.html" title="interface in org.apache.qpid.protonj2.client">AdvancedMessage</a>&lt;<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/io/OutputStream.html" title="class or interface in java.io" class="external-link">OutputStream</a>&gt;</span></div>
<div class="block">Streaming Message Tracker object used to operate on and track the state of a streamed message
at the remote. The <a href="StreamSenderMessage.html" title="interface in org.apache.qpid.protonj2.client"><code>StreamSenderMessage</code></a> allows for local settlement and disposition management
as well as waiting for remote settlement of a streamed message.</div>
</section>
<section class="summary">
<ul class="summary-list">
<!-- ========== METHOD SUMMARY =========== -->
<li>
<section class="method-summary" id="method-summary">
<h2>Method Summary</h2>
<div id="method-summary-table">
<div class="table-tabs" role="tablist" aria-orientation="horizontal"><button id="method-summary-table-tab0" role="tab" aria-selected="true" aria-controls="method-summary-table.tabpanel" tabindex="0" onkeydown="switchTab(event)" onclick="show('method-summary-table', 'method-summary-table', 3)" class="active-table-tab">All Methods</button><button id="method-summary-table-tab2" role="tab" aria-selected="false" aria-controls="method-summary-table.tabpanel" tabindex="-1" onkeydown="switchTab(event)" onclick="show('method-summary-table', 'method-summary-table-tab2', 3)" class="table-tab">Instance Methods</button><button id="method-summary-table-tab3" role="tab" aria-selected="false" aria-controls="method-summary-table.tabpanel" tabindex="-1" onkeydown="switchTab(event)" onclick="show('method-summary-table', 'method-summary-table-tab3', 3)" class="table-tab">Abstract Methods</button></div>
<div id="method-summary-table.tabpanel" role="tabpanel">
<div class="summary-table three-column-summary" aria-labelledby="method-summary-table-tab0">
<div class="table-header col-first">Modifier and Type</div>
<div class="table-header col-second">Method</div>
<div class="table-header col-last">Description</div>
<div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="StreamSenderMessage.html" title="interface in org.apache.qpid.protonj2.client">StreamSenderMessage</a></code></div>
<div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#abort()" class="member-name-link">abort</a>()</code></div>
<div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3">
<div class="block">Marks the currently streaming message as being aborted.</div>
</div>
<div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code>boolean</code></div>
<div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#aborted()" class="member-name-link">aborted</a>()</code></div>
<div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3">&nbsp;</div>
<div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/io/OutputStream.html" title="class or interface in java.io" class="external-link">OutputStream</a></code></div>
<div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#body(org.apache.qpid.protonj2.client.OutputStreamOptions)" class="member-name-link">body</a><wbr>(<a href="OutputStreamOptions.html" title="class in org.apache.qpid.protonj2.client">OutputStreamOptions</a>&nbsp;options)</code></div>
<div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3">
<div class="block">Creates an <a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/io/OutputStream.html" title="class or interface in java.io" class="external-link"><code>OutputStream</code></a> instance configured with the given options which will
write the bytes as the payload of one or more AMQP <a href="../types/messaging/Data.html" title="class in org.apache.qpid.protonj2.types.messaging"><code>Data</code></a> sections based on the
provided configuration..</div>
</div>
<div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="StreamSenderMessage.html" title="interface in org.apache.qpid.protonj2.client">StreamSenderMessage</a></code></div>
<div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#complete()" class="member-name-link">complete</a>()</code></div>
<div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3">
<div class="block">Marks the currently streaming message as being complete.</div>
</div>
<div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code>boolean</code></div>
<div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#completed()" class="member-name-link">completed</a>()</code></div>
<div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3">&nbsp;</div>
<div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="StreamSenderMessage.html" title="interface in org.apache.qpid.protonj2.client">StreamSenderMessage</a></code></div>
<div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#messageFormat(int)" class="member-name-link">messageFormat</a><wbr>(int&nbsp;messageFormat)</code></div>
<div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3">
<div class="block">Sets the configured message format value that will be set on the first outgoing
AMQP <a href="../types/transport/Transfer.html" title="class in org.apache.qpid.protonj2.types.transport"><code>Transfer</code></a> frame for the delivery that comprises this streamed message.</div>
</div>
<div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/io/OutputStream.html" title="class or interface in java.io" class="external-link">OutputStream</a></code></div>
<div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#rawOutputStream()" class="member-name-link">rawOutputStream</a>()</code></div>
<div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3">
<div class="block">Creates an <a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/io/OutputStream.html" title="class or interface in java.io" class="external-link"><code>OutputStream</code></a> instance that writes the bytes given without additional
encoding or transformation.</div>
</div>
<div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="StreamSender.html" title="interface in org.apache.qpid.protonj2.client">StreamSender</a></code></div>
<div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#sender()" class="member-name-link">sender</a>()</code></div>
<div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3">&nbsp;</div>
<div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="StreamTracker.html" title="interface in org.apache.qpid.protonj2.client">StreamTracker</a></code></div>
<div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#tracker()" class="member-name-link">tracker</a>()</code></div>
<div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3">&nbsp;</div>
</div>
</div>
</div>
<div class="inherited-list">
<h3 id="methods-inherited-from-class-org.apache.qpid.protonj2.client.AdvancedMessage">Methods inherited from interface&nbsp;org.apache.qpid.protonj2.client.<a href="AdvancedMessage.html" title="interface in org.apache.qpid.protonj2.client">AdvancedMessage</a></h3>
<code><a href="AdvancedMessage.html#addBodySection(org.apache.qpid.protonj2.types.messaging.Section)">addBodySection</a>, <a href="AdvancedMessage.html#annotations()">annotations</a>, <a href="AdvancedMessage.html#annotations(org.apache.qpid.protonj2.types.messaging.MessageAnnotations)">annotations</a>, <a href="AdvancedMessage.html#applicationProperties()">applicationProperties</a>, <a href="AdvancedMessage.html#applicationProperties(org.apache.qpid.protonj2.types.messaging.ApplicationProperties)">applicationProperties</a>, <a href="AdvancedMessage.html#bodySections()">bodySections</a>, <a href="AdvancedMessage.html#bodySections(java.util.Collection)">bodySections</a>, <a href="AdvancedMessage.html#clearBodySections()">clearBodySections</a>, <a href="AdvancedMessage.html#encode(java.util.Map)">encode</a>, <a href="AdvancedMessage.html#encode(java.util.Map,org.apache.qpid.protonj2.buffer.ProtonBufferAllocator)">encode</a>, <a href="AdvancedMessage.html#footer()">footer</a>, <a href="AdvancedMessage.html#footer(org.apache.qpid.protonj2.types.messaging.Footer)">footer</a>, <a href="AdvancedMessage.html#forEachBodySection(java.util.function.Consumer)">forEachBodySection</a>, <a href="AdvancedMessage.html#header()">header</a>, <a href="AdvancedMessage.html#header(org.apache.qpid.protonj2.types.messaging.Header)">header</a>, <a href="AdvancedMessage.html#messageFormat()">messageFormat</a>, <a href="AdvancedMessage.html#properties()">properties</a>, <a href="AdvancedMessage.html#properties(org.apache.qpid.protonj2.types.messaging.Properties)">properties</a></code></div>
<div class="inherited-list">
<h3 id="methods-inherited-from-class-org.apache.qpid.protonj2.client.Message">Methods inherited from interface&nbsp;org.apache.qpid.protonj2.client.<a href="Message.html" title="interface in org.apache.qpid.protonj2.client">Message</a></h3>
<code><a href="Message.html#absoluteExpiryTime()">absoluteExpiryTime</a>, <a href="Message.html#absoluteExpiryTime(long)">absoluteExpiryTime</a>, <a href="Message.html#annotation(java.lang.String)">annotation</a>, <a href="Message.html#annotation(java.lang.String,java.lang.Object)">annotation</a>, <a href="Message.html#body()">body</a>, <a href="Message.html#body(E)">body</a>, <a href="Message.html#contentEncoding()">contentEncoding</a>, <a href="Message.html#contentEncoding(java.lang.String)">contentEncoding</a>, <a href="Message.html#contentType()">contentType</a>, <a href="Message.html#contentType(java.lang.String)">contentType</a>, <a href="Message.html#correlationId()">correlationId</a>, <a href="Message.html#correlationId(java.lang.Object)">correlationId</a>, <a href="Message.html#creationTime()">creationTime</a>, <a href="Message.html#creationTime(long)">creationTime</a>, <a href="Message.html#deliveryCount()">deliveryCount</a>, <a href="Message.html#deliveryCount(long)">deliveryCount</a>, <a href="Message.html#durable()">durable</a>, <a href="Message.html#durable(boolean)">durable</a>, <a href="Message.html#firstAcquirer()">firstAcquirer</a>, <a href="Message.html#firstAcquirer(boolean)">firstAcquirer</a>, <a href="Message.html#footer(java.lang.String)">footer</a>, <a href="Message.html#footer(java.lang.String,java.lang.Object)">footer</a>, <a href="Message.html#forEachAnnotation(java.util.function.BiConsumer)">forEachAnnotation</a>, <a href="Message.html#forEachFooter(java.util.function.BiConsumer)">forEachFooter</a>, <a href="Message.html#forEachProperty(java.util.function.BiConsumer)">forEachProperty</a>, <a href="Message.html#groupId()">groupId</a>, <a href="Message.html#groupId(java.lang.String)">groupId</a>, <a href="Message.html#groupSequence()">groupSequence</a>, <a href="Message.html#groupSequence(int)">groupSequence</a>, <a href="Message.html#hasAnnotation(java.lang.String)">hasAnnotation</a>, <a href="Message.html#hasAnnotations()">hasAnnotations</a>, <a href="Message.html#hasFooter(java.lang.String)">hasFooter</a>, <a href="Message.html#hasFooters()">hasFooters</a>, <a href="Message.html#hasProperties()">hasProperties</a>, <a href="Message.html#hasProperty(java.lang.String)">hasProperty</a>, <a href="Message.html#messageId()">messageId</a>, <a href="Message.html#messageId(java.lang.Object)">messageId</a>, <a href="Message.html#priority()">priority</a>, <a href="Message.html#priority(byte)">priority</a>, <a href="Message.html#property(java.lang.String)">property</a>, <a href="Message.html#property(java.lang.String,java.lang.Object)">property</a>, <a href="Message.html#removeAnnotation(java.lang.String)">removeAnnotation</a>, <a href="Message.html#removeFooter(java.lang.String)">removeFooter</a>, <a href="Message.html#removeProperty(java.lang.String)">removeProperty</a>, <a href="Message.html#replyTo()">replyTo</a>, <a href="Message.html#replyTo(java.lang.String)">replyTo</a>, <a href="Message.html#replyToGroupId()">replyToGroupId</a>, <a href="Message.html#replyToGroupId(java.lang.String)">replyToGroupId</a>, <a href="Message.html#subject()">subject</a>, <a href="Message.html#subject(java.lang.String)">subject</a>, <a href="Message.html#timeToLive()">timeToLive</a>, <a href="Message.html#timeToLive(long)">timeToLive</a>, <a href="Message.html#to()">to</a>, <a href="Message.html#to(java.lang.String)">to</a>, <a href="Message.html#toAdvancedMessage()">toAdvancedMessage</a>, <a href="Message.html#userId()">userId</a>, <a href="Message.html#userId(byte%5B%5D)">userId</a></code></div>
</section>
</li>
</ul>
</section>
<section class="details">
<ul class="details-list">
<!-- ============ METHOD DETAIL ========== -->
<li>
<section class="method-details" id="method-detail">
<h2>Method Details</h2>
<ul class="member-list">
<li>
<section class="detail" id="tracker()">
<h3>tracker</h3>
<div class="member-signature"><span class="return-type"><a href="StreamTracker.html" title="interface in org.apache.qpid.protonj2.client">StreamTracker</a></span>&nbsp;<span class="element-name">tracker</span>()</div>
<dl class="notes">
<dt>Returns:</dt>
<dd>The <a href="Tracker.html" title="interface in org.apache.qpid.protonj2.client"><code>Tracker</code></a> assigned to monitor the life-cycle of this <a href="StreamSenderMessage.html" title="interface in org.apache.qpid.protonj2.client"><code>StreamSenderMessage</code></a></dd>
</dl>
</section>
</li>
<li>
<section class="detail" id="sender()">
<h3>sender</h3>
<div class="member-signature"><span class="return-type"><a href="StreamSender.html" title="interface in org.apache.qpid.protonj2.client">StreamSender</a></span>&nbsp;<span class="element-name">sender</span>()</div>
<dl class="notes">
<dt>Returns:</dt>
<dd>the <a href="Sender.html" title="interface in org.apache.qpid.protonj2.client"><code>Sender</code></a> that was used to send the delivery that is being tracked.</dd>
</dl>
</section>
</li>
<li>
<section class="detail" id="messageFormat(int)">
<h3>messageFormat</h3>
<div class="member-signature"><span class="return-type"><a href="StreamSenderMessage.html" title="interface in org.apache.qpid.protonj2.client">StreamSenderMessage</a></span>&nbsp;<span class="element-name">messageFormat</span><wbr><span class="parameters">(int&nbsp;messageFormat)</span>
throws <span class="exceptions"><a href="exceptions/ClientException.html" title="class in org.apache.qpid.protonj2.client.exceptions">ClientException</a></span></div>
<div class="block">Sets the configured message format value that will be set on the first outgoing
AMQP <a href="../types/transport/Transfer.html" title="class in org.apache.qpid.protonj2.types.transport"><code>Transfer</code></a> frame for the delivery that comprises this streamed message.
This value can only be updated before write operation is attempted and will throw
an <a href="exceptions/ClientIllegalStateException.html" title="class in org.apache.qpid.protonj2.client.exceptions"><code>ClientIllegalStateException</code></a> if any attempt to alter the value is made
following a write.</div>
<dl class="notes">
<dt>Specified by:</dt>
<dd><code><a href="AdvancedMessage.html#messageFormat(int)">messageFormat</a></code>&nbsp;in interface&nbsp;<code><a href="AdvancedMessage.html" title="interface in org.apache.qpid.protonj2.client">AdvancedMessage</a>&lt;<a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/io/OutputStream.html" title="class or interface in java.io" class="external-link">OutputStream</a>&gt;</code></dd>
<dt>Parameters:</dt>
<dd><code>messageFormat</code> - The assigned AMQP message format for this streamed message.</dd>
<dt>Returns:</dt>
<dd>this <a href="StreamSenderMessage.html" title="interface in org.apache.qpid.protonj2.client"><code>StreamSenderMessage</code></a> instance.</dd>
<dt>Throws:</dt>
<dd><code><a href="exceptions/ClientException.html" title="class in org.apache.qpid.protonj2.client.exceptions">ClientException</a></code> - if an error occurs while attempting set the message format.</dd>
</dl>
</section>
</li>
<li>
<section class="detail" id="complete()">
<h3>complete</h3>
<div class="member-signature"><span class="return-type"><a href="StreamSenderMessage.html" title="interface in org.apache.qpid.protonj2.client">StreamSenderMessage</a></span>&nbsp;<span class="element-name">complete</span>()
throws <span class="exceptions"><a href="exceptions/ClientException.html" title="class in org.apache.qpid.protonj2.client.exceptions">ClientException</a></span></div>
<div class="block">Marks the currently streaming message as being complete.
<p>
Marking a message as complete finalizes the streaming send operation and causes a
final <a href="../types/transport/Transfer.html" title="class in org.apache.qpid.protonj2.types.transport"><code>Transfer</code></a> frame to be sent to the remote indicating that the ongoing
streaming delivery is done and no more message data will arrive.</div>
<dl class="notes">
<dt>Returns:</dt>
<dd>this <a href="StreamSenderMessage.html" title="interface in org.apache.qpid.protonj2.client"><code>StreamSenderMessage</code></a> instance.</dd>
<dt>Throws:</dt>
<dd><code><a href="exceptions/ClientException.html" title="class in org.apache.qpid.protonj2.client.exceptions">ClientException</a></code> - if an error occurs while initiating the completion operation.</dd>
</dl>
</section>
</li>
<li>
<section class="detail" id="completed()">
<h3>completed</h3>
<div class="member-signature"><span class="return-type">boolean</span>&nbsp;<span class="element-name">completed</span>()</div>
<dl class="notes">
<dt>Returns:</dt>
<dd>true if this message has been marked as being complete.</dd>
</dl>
</section>
</li>
<li>
<section class="detail" id="abort()">
<h3>abort</h3>
<div class="member-signature"><span class="return-type"><a href="StreamSenderMessage.html" title="interface in org.apache.qpid.protonj2.client">StreamSenderMessage</a></span>&nbsp;<span class="element-name">abort</span>()
throws <span class="exceptions"><a href="exceptions/ClientException.html" title="class in org.apache.qpid.protonj2.client.exceptions">ClientException</a></span></div>
<div class="block">Marks the currently streaming message as being aborted. Once aborted no further
writes regardless of whether any writes have yet been performed or not.</div>
<dl class="notes">
<dt>Returns:</dt>
<dd>this <a href="StreamSenderMessage.html" title="interface in org.apache.qpid.protonj2.client"><code>StreamSenderMessage</code></a> instance.</dd>
<dt>Throws:</dt>
<dd><code><a href="exceptions/ClientException.html" title="class in org.apache.qpid.protonj2.client.exceptions">ClientException</a></code> - if an error occurs while initiating the abort operation.</dd>
</dl>
</section>
</li>
<li>
<section class="detail" id="aborted()">
<h3>aborted</h3>
<div class="member-signature"><span class="return-type">boolean</span>&nbsp;<span class="element-name">aborted</span>()</div>
<dl class="notes">
<dt>Returns:</dt>
<dd>true if this <a href="StreamSenderMessage.html" title="interface in org.apache.qpid.protonj2.client"><code>StreamSenderMessage</code></a> has been marked as aborted previously.</dd>
</dl>
</section>
</li>
<li>
<section class="detail" id="body(org.apache.qpid.protonj2.client.OutputStreamOptions)">
<h3>body</h3>
<div class="member-signature"><span class="return-type"><a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/io/OutputStream.html" title="class or interface in java.io" class="external-link">OutputStream</a></span>&nbsp;<span class="element-name">body</span><wbr><span class="parameters">(<a href="OutputStreamOptions.html" title="class in org.apache.qpid.protonj2.client">OutputStreamOptions</a>&nbsp;options)</span>
throws <span class="exceptions"><a href="exceptions/ClientException.html" title="class in org.apache.qpid.protonj2.client.exceptions">ClientException</a></span></div>
<div class="block">Creates an <a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/io/OutputStream.html" title="class or interface in java.io" class="external-link"><code>OutputStream</code></a> instance configured with the given options which will
write the bytes as the payload of one or more AMQP <a href="../types/messaging/Data.html" title="class in org.apache.qpid.protonj2.types.messaging"><code>Data</code></a> sections based on the
provided configuration..
<p>
The returned <a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/io/OutputStream.html" title="class or interface in java.io" class="external-link"><code>OutputStream</code></a> can be used to write the payload of an AMQP Message in
chunks when the source is not readily available in memory or as part of a larger streams
based component. The <a href="../types/messaging/Data.html" title="class in org.apache.qpid.protonj2.types.messaging"><code>Data</code></a> section based stream allows for control over the AMQP
message <a href="../types/messaging/Section.html" title="interface in org.apache.qpid.protonj2.types.messaging"><code>Section</code></a> values that are sent but does the encoding itself. For stream
of message data where the content source already consists of an AMQP encoded message refer
to the <a href="#rawOutputStream()"><code>rawOutputStream()</code></a> method.</div>
<dl class="notes">
<dt>Parameters:</dt>
<dd><code>options</code> - The stream options to use to configure the returned <a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/io/OutputStream.html" title="class or interface in java.io" class="external-link"><code>OutputStream</code></a></dd>
<dt>Returns:</dt>
<dd>a <a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/io/OutputStream.html" title="class or interface in java.io" class="external-link"><code>OutputStream</code></a> instance configured using the given options.</dd>
<dt>Throws:</dt>
<dd><code><a href="exceptions/ClientException.html" title="class in org.apache.qpid.protonj2.client.exceptions">ClientException</a></code> - if an error occurs while creating the <a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/io/OutputStream.html" title="class or interface in java.io" class="external-link"><code>OutputStream</code></a>.</dd>
<dt>See Also:</dt>
<dd>
<ul class="see-list">
<li><a href="#rawOutputStream()"><code>rawOutputStream()</code></a></li>
</ul>
</dd>
</dl>
</section>
</li>
<li>
<section class="detail" id="rawOutputStream()">
<h3>rawOutputStream</h3>
<div class="member-signature"><span class="return-type"><a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/io/OutputStream.html" title="class or interface in java.io" class="external-link">OutputStream</a></span>&nbsp;<span class="element-name">rawOutputStream</span>()
throws <span class="exceptions"><a href="exceptions/ClientException.html" title="class in org.apache.qpid.protonj2.client.exceptions">ClientException</a></span></div>
<div class="block">Creates an <a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/io/OutputStream.html" title="class or interface in java.io" class="external-link"><code>OutputStream</code></a> instance that writes the bytes given without additional
encoding or transformation. Using this stream option disables use of any other <a href="Message.html" title="interface in org.apache.qpid.protonj2.client"><code>Message</code></a>
APIs and the message transfer is completed upon close of this <a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/io/OutputStream.html" title="class or interface in java.io" class="external-link"><code>OutputStream</code></a>.
<p>
The returned <a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/io/OutputStream.html" title="class or interface in java.io" class="external-link"><code>OutputStream</code></a> can be used to write the payload of an AMQP Message in
chunks when the source is not readily available in memory or as part of a larger streams
based component. The source of the bytes written to the <a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/io/OutputStream.html" title="class or interface in java.io" class="external-link"><code>OutputStream</code></a> should
consist of already encoded AMQP <a href="Message.html" title="interface in org.apache.qpid.protonj2.client"><code>Message</code></a> data. For an <a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/io/OutputStream.html" title="class or interface in java.io" class="external-link"><code>OutputStream</code></a> that
performs the encoding of message data refer to the <a href="#body(org.apache.qpid.protonj2.client.OutputStreamOptions)"><code>body(OutputStreamOptions)</code></a>
method.</div>
<dl class="notes">
<dt>Returns:</dt>
<dd>an <a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/io/OutputStream.html" title="class or interface in java.io" class="external-link"><code>OutputStream</code></a> instance that performs no encoding.</dd>
<dt>Throws:</dt>
<dd><code><a href="exceptions/ClientException.html" title="class in org.apache.qpid.protonj2.client.exceptions">ClientException</a></code> - if an error occurs while creating the <a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/io/OutputStream.html" title="class or interface in java.io" class="external-link"><code>OutputStream</code></a>.</dd>
<dt>See Also:</dt>
<dd>
<ul class="see-list-long">
<li><a href="#body(org.apache.qpid.protonj2.client.OutputStreamOptions)"><code>body(org.apache.qpid.protonj2.client.OutputStreamOptions)</code></a></li>
<li><a href="#body(org.apache.qpid.protonj2.client.OutputStreamOptions)"><code>body(OutputStreamOptions)</code></a></li>
</ul>
</dd>
</dl>
</section>
</li>
</ul>
</section>
</li>
</ul>
</section>
<!-- ========= END OF CLASS DATA ========= -->
</main>
<footer role="contentinfo">
<hr>
<p class="legal-copy"><small>Copyright &#169; 2023 <a href="https://www.apache.org/">The Apache Software Foundation</a>. All rights reserved.</small></p>
</footer>
</div>
</div>
</body>
</html>