Package reactor.netty.http
Class HttpOperations.PostHeadersNettyOutbound
java.lang.Object
java.util.concurrent.atomic.AtomicBoolean
reactor.netty.http.HttpOperations.PostHeadersNettyOutbound
- All Implemented Interfaces:
Serializable,Publisher<Void>,NettyOutbound
- Enclosing class:
- HttpOperations<INBOUND extends NettyInbound,
OUTBOUND extends NettyOutbound>
protected static final class HttpOperations.PostHeadersNettyOutbound
extends AtomicBoolean
implements NettyOutbound
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionPostHeadersNettyOutbound(Mono<Void> source, HttpOperations<?, ?> parent, @Nullable ByteBuf msg) -
Method Summary
Modifier and TypeMethodDescriptionalloc()Returns the assignedByteBufAllocator.Sends data to the peer, listens for any error on write and closes on terminal signal (complete|error).sendObject(Object message) Sends data to the peer, listens for any error on write and closes on terminal signal (complete|error).sendObject(Publisher<?> dataStream, Predicate<Object> predicate) Sends an object through Netty pipeline.<S> NettyOutboundsendUsing(Callable<? extends S> sourceInput, BiFunction<? super Connection, ? super S, ?> mappedInput, Consumer<? super S> sourceCleanup) Binds a send to a starting/cleanup lifecyclethen()Obtains aMonoof pending outbound(s) write completion.withConnection(Consumer<? super Connection> withConnection) Call the passed callback with aConnectionto operate on the underlyingChannelstate.Methods inherited from class java.util.concurrent.atomic.AtomicBoolean
compareAndExchange, compareAndExchangeAcquire, compareAndExchangeRelease, compareAndSet, get, getAcquire, getAndSet, getOpaque, getPlain, lazySet, set, setOpaque, setPlain, setRelease, toString, weakCompareAndSet, weakCompareAndSetAcquire, weakCompareAndSetPlain, weakCompareAndSetRelease, weakCompareAndSetVolatileMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface reactor.netty.NettyOutbound
neverComplete, send, sendByteArray, sendFile, sendFile, sendFileChunked, sendGroups, sendObject, sendString, sendString, subscribe, then, then
-
Constructor Details
-
PostHeadersNettyOutbound
public PostHeadersNettyOutbound(Mono<Void> source, HttpOperations<?, ?> parent, @Nullable ByteBuf msg)
-
-
Method Details
-
then
Description copied from interface:NettyOutboundObtains aMonoof pending outbound(s) write completion.- Specified by:
thenin interfaceNettyOutbound- Returns:
- a
Monoof pending outbound(s) write completion
-
alloc
Description copied from interface:NettyOutboundReturns the assignedByteBufAllocator.- Specified by:
allocin interfaceNettyOutbound- Returns:
- the
ByteBufAllocator
-
send
Description copied from interface:NettyOutboundSends data to the peer, listens for any error on write and closes on terminal signal (complete|error).A new
NettyOutboundtype (or the same) for typed send sequences.Note: Nesting any send* method is not supported.
- Specified by:
sendin interfaceNettyOutbound- Parameters:
dataStream- the dataStream publishing OUT items to write on this channelpredicate- that returns true if explicit flush operation is needed after that buffer- Returns:
- A new
NettyOutboundto append further send. It will emit a complete signal successful sequence write (e.g. after "flush") or any error during write.
-
sendObject
Description copied from interface:NettyOutboundSends an object through Netty pipeline. If type ofPublisher, sends all signals, flushing on complete by default. Write occur in FIFO sequence.Note: Nesting any send* method is not supported.
- Specified by:
sendObjectin interfaceNettyOutbound- Parameters:
dataStream- the dataStream publishing items to write on this channel or a simple pojo supported by configured Netty handlerspredicate- that returns true if explicit flush operation is needed after that object- Returns:
- A Publisher to signal successful sequence write (e.g. after "flush") or any error during write
-
sendObject
Description copied from interface:NettyOutboundSends data to the peer, listens for any error on write and closes on terminal signal (complete|error).Note: Nesting any send* method is not supported.
- Specified by:
sendObjectin interfaceNettyOutbound- Parameters:
message- the object to publish- Returns:
- A
Monoto signal successful sequence write (e.g. after "flush") or any error during write
-
sendUsing
public <S> NettyOutbound sendUsing(Callable<? extends S> sourceInput, BiFunction<? super Connection, ? super S, ?> mappedInput, Consumer<? super S> sourceCleanup) Description copied from interface:NettyOutboundBinds a send to a starting/cleanup lifecycleNote: Nesting any send* method is not supported.
- Specified by:
sendUsingin interfaceNettyOutbound- Type Parameters:
S- state type- Parameters:
sourceInput- state generatormappedInput- input to sendsourceCleanup- state cleaner- Returns:
- a new
NettyOutbound
-
withConnection
Description copied from interface:NettyOutboundCall the passed callback with aConnectionto operate on the underlyingChannelstate.- Specified by:
withConnectionin interfaceNettyOutbound- Parameters:
withConnection- connection callback- Returns:
- the
Connection
-