Package io.grpc.netty
Class SendGrpcFrameCommand
java.lang.Object
io.netty.buffer.DefaultByteBufHolder
io.grpc.netty.SendGrpcFrameCommand
- All Implemented Interfaces:
WriteQueue.QueuedCommand
,io.netty.buffer.ByteBufHolder
,io.netty.util.ReferenceCounted
final class SendGrpcFrameCommand
extends io.netty.buffer.DefaultByteBufHolder
implements WriteQueue.QueuedCommand
Command sent from the transport to the Netty channel to send a GRPC frame to the remote endpoint.
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final boolean
private final io.perfmark.Link
private io.netty.channel.ChannelPromise
private final StreamIdHolder
-
Constructor Summary
ConstructorsConstructorDescriptionSendGrpcFrameCommand
(StreamIdHolder stream, io.netty.buffer.ByteBuf content, boolean endStream) -
Method Summary
Modifier and TypeMethodDescription(package private) boolean
boolean
io.perfmark.Link
getLink()
int
hashCode()
io.netty.channel.ChannelPromise
promise()
Returns the promise beeing notified of the success/failure of the write.void
promise
(io.netty.channel.ChannelPromise promise) Sets the promise.io.netty.buffer.ByteBufHolder
replace
(io.netty.buffer.ByteBuf content) final void
run
(io.netty.channel.Channel channel) (package private) StreamIdHolder
stream()
toString()
Methods inherited from class io.netty.buffer.DefaultByteBufHolder
content, contentToString, copy, duplicate, refCnt, release, release, retain, retain, retainedDuplicate, touch, touch
-
Field Details
-
stream
-
endStream
private final boolean endStream -
link
private final io.perfmark.Link link -
promise
private io.netty.channel.ChannelPromise promise
-
-
Constructor Details
-
SendGrpcFrameCommand
SendGrpcFrameCommand(StreamIdHolder stream, io.netty.buffer.ByteBuf content, boolean endStream)
-
-
Method Details
-
getLink
public io.perfmark.Link getLink()- Specified by:
getLink
in interfaceWriteQueue.QueuedCommand
-
stream
StreamIdHolder stream() -
endStream
boolean endStream() -
replace
public io.netty.buffer.ByteBufHolder replace(io.netty.buffer.ByteBuf content) - Specified by:
replace
in interfaceio.netty.buffer.ByteBufHolder
- Overrides:
replace
in classio.netty.buffer.DefaultByteBufHolder
-
equals
- Overrides:
equals
in classio.netty.buffer.DefaultByteBufHolder
-
toString
- Overrides:
toString
in classio.netty.buffer.DefaultByteBufHolder
-
hashCode
public int hashCode()- Overrides:
hashCode
in classio.netty.buffer.DefaultByteBufHolder
-
promise
public io.netty.channel.ChannelPromise promise()Description copied from interface:WriteQueue.QueuedCommand
Returns the promise beeing notified of the success/failure of the write.- Specified by:
promise
in interfaceWriteQueue.QueuedCommand
-
promise
public void promise(io.netty.channel.ChannelPromise promise) Description copied from interface:WriteQueue.QueuedCommand
Sets the promise.- Specified by:
promise
in interfaceWriteQueue.QueuedCommand
-
run
public final void run(io.netty.channel.Channel channel) - Specified by:
run
in interfaceWriteQueue.QueuedCommand
-