Top Fields Constructors Methods
io.vertx.core.impl.transports

public Class JDKTransport

extends Object
implements Transport
Class Inheritance
All Implemented Interfaces
io.vertx.core.spi.transport.Transport
Imports
io.netty.channel.Channel, .ChannelFactory, .EventLoopGroup, .ServerChannel, io.netty.channel.nio.NioEventLoopGroup, io.netty.channel.socket.DatagramChannel, .InternetProtocolFamily, io.netty.channel.socket.nio.NioDatagramChannel, .NioServerSocketChannel, .NioSocketChannel, io.vertx.core.spi.transport.Transport, java.util.concurrent.ThreadFactory

Field Summary

Modifier and TypeField and Description
public static final Transport
INSTANCE

The JDK transport, always there.

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
public ChannelFactory<? extends Channel>
channelFactory(boolean
whether to create a unix domain channel or a socket channel
domainSocket
)

Implements io.vertx.core.spi.transport.Transport.channelFactory.

References Deprecated ChannelFactory is deprecated or references (maybe indirectly) at least one deprecated element.

public DatagramChannel
public DatagramChannel
public EventLoopGroup
eventLoopGroup(int type, int
the number of threads that will be used by this instance.
nThreads
,
ThreadFactory
the ThreadFactory to use.
threadFactory
,
int
the IO ratio
ioRatio
)

Implements io.vertx.core.spi.transport.Transport.eventLoopGroup.

public ChannelFactory<? extends ServerChannel>
serverChannelFactory(boolean
whether to create a server unix domain channel or a regular server socket channel
domainSocket
)

Implements io.vertx.core.spi.transport.Transport.serverChannelFactory.

References Deprecated ChannelFactory is deprecated or references (maybe indirectly) at least one deprecated element.

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

INSTANCEback to summary
public static final Transport INSTANCE

The JDK transport, always there.

Constructor Detail

JDKTransportback to summary
public JDKTransport()

Method Detail

channelFactoryback to summary
public ChannelFactory<? extends Channel> channelFactory(boolean domainSocket)

Implements io.vertx.core.spi.transport.Transport.channelFactory.

References Deprecated

ChannelFactory is deprecated or references (maybe indirectly) at least one deprecated element.

See corresponding docs for further information.

Parameters
domainSocket:boolean

Doc from io.vertx.core.spi.transport.Transport.channelFactory.

whether to create a unix domain channel or a socket channel

Returns:ChannelFactory<? extends Channel>

Doc from io.vertx.core.spi.transport.Transport.channelFactory.

the type for channel

datagramChannelback to summary
public DatagramChannel datagramChannel()

Implements io.vertx.core.spi.transport.Transport.datagramChannel.

Returns:DatagramChannel

Doc from io.vertx.core.spi.transport.Transport.datagramChannel.

a new datagram channel

datagramChannelback to summary
public DatagramChannel datagramChannel(InternetProtocolFamily family)

Implements io.vertx.core.spi.transport.Transport.datagramChannel.

Returns:DatagramChannel

Doc from io.vertx.core.spi.transport.Transport.datagramChannel.

a new datagram channel

eventLoopGroupback to summary
public EventLoopGroup eventLoopGroup(int type, int nThreads, ThreadFactory threadFactory, int ioRatio)

Implements io.vertx.core.spi.transport.Transport.eventLoopGroup.

Parameters
type:int

Doc from io.vertx.core.spi.transport.Transport.eventLoopGroup.

one of ACCEPTOR_EVENT_LOOP_GROUP or IO_EVENT_LOOP_GROUP.

nThreads:int

Doc from io.vertx.core.spi.transport.Transport.eventLoopGroup.

the number of threads that will be used by this instance.

threadFactory:ThreadFactory

Doc from io.vertx.core.spi.transport.Transport.eventLoopGroup.

the ThreadFactory to use.

ioRatio:int

Doc from io.vertx.core.spi.transport.Transport.eventLoopGroup.

the IO ratio

Returns:EventLoopGroup

Doc from io.vertx.core.spi.transport.Transport.eventLoopGroup.

a new event loop group

serverChannelFactoryback to summary
public ChannelFactory<? extends ServerChannel> serverChannelFactory(boolean domainSocket)

Implements io.vertx.core.spi.transport.Transport.serverChannelFactory.

References Deprecated

ChannelFactory is deprecated or references (maybe indirectly) at least one deprecated element.

See corresponding docs for further information.

Parameters
domainSocket:boolean

Doc from io.vertx.core.spi.transport.Transport.serverChannelFactory.

whether to create a server unix domain channel or a regular server socket channel

Returns:ChannelFactory<? extends ServerChannel>

Doc from io.vertx.core.spi.transport.Transport.serverChannelFactory.

the type for server channel