Top Description Fields Methods
io.vertx.core.spi.transport

public Interface Transport

Known Direct Implementers
io.vertx.core.impl.transports.EpollTransport, io.vertx.core.impl.transports.JDKTransport, io.vertx.core.impl.transports.KQueueTransport
Imports
io.netty.bootstrap.Bootstrap, .ServerBootstrap, io.netty.channel.*, io.netty.channel.socket.DatagramChannel, .InternetProtocolFamily, io.vertx.core.datagram.DatagramSocketOptions, io.vertx.core.net.ClientOptionsBase, .NetServerOptions, io.vertx.core.buffer.impl.PartialPooledByteBufAllocator, io.vertx.core.net.impl.SocketAddressImpl, io.vertx.core.impl.transports.JDKTransport, java.net.InetAddress, .InetSocketAddress, .NetworkInterface, .SocketAddress, .SocketException, java.util.concurrent.ThreadFactory

The transport used by a io.vertx.core.Vertx instance.

Author
Julien Viet

Field Summary

Modifier and TypeField and Description
public static final int
public static final int

Method Summary

Modifier and TypeMethod and Description
public ChannelFactory<? extends Channel>

Returns:

the type for channel
channelFactory
(boolean
whether to create a unix domain channel or a socket channel
domainSocket
)
References Deprecated ChannelFactory is deprecated or references (maybe indirectly) at least one deprecated element.

public default void
public default void
configure(ClientOptionsBase options, boolean domainSocket, Bootstrap bootstrap)

public default void
configure(NetServerOptions options, boolean domainSocket, ServerBootstrap bootstrap)

public default SocketAddress
public default SocketAddress
public DatagramChannel

Returns:

a new datagram channel
datagramChannel
()

public DatagramChannel

Returns:

a new datagram channel
datagramChannel
(InternetProtocolFamily family)

public EventLoopGroup

Returns:

a new event loop group
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
)

public default boolean

Returns:

true when the transport is available.
isAvailable
()

public ChannelFactory<? extends ServerChannel>

Returns:

the type for server channel
serverChannelFactory
(boolean
whether to create a server unix domain channel or a regular server socket channel
domainSocket
)
References Deprecated ChannelFactory is deprecated or references (maybe indirectly) at least one deprecated element.

public default boolean
public default boolean
public default Throwable

Returns:

the error that cause the unavailability when isAvailable() returns null.
unavailabilityCause
()

Field Detail

ACCEPTOR_EVENT_LOOP_GROUPback to summary
public static final int ACCEPTOR_EVENT_LOOP_GROUP
IO_EVENT_LOOP_GROUPback to summary
public static final int IO_EVENT_LOOP_GROUP

Method Detail

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

References Deprecated

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

See corresponding docs for further information.

Parameters
domainSocket:boolean

whether to create a unix domain channel or a socket channel

Returns:ChannelFactory<? extends Channel>

the type for channel

configureback to summary
public default void configure(DatagramChannel channel, DatagramSocketOptions options)
configureback to summary
public default void configure(ClientOptionsBase options, boolean domainSocket, Bootstrap bootstrap)
configureback to summary
public default void configure(NetServerOptions options, boolean domainSocket, ServerBootstrap bootstrap)
convertback to summary
public default SocketAddress convert(SocketAddress address)
convertback to summary
public default SocketAddress convert(SocketAddress address)
datagramChannelback to summary
public DatagramChannel datagramChannel()
Returns:DatagramChannel

a new datagram channel

datagramChannelback to summary
public DatagramChannel datagramChannel(InternetProtocolFamily family)
Returns:DatagramChannel

a new datagram channel

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

one of ACCEPTOR_EVENT_LOOP_GROUP or IO_EVENT_LOOP_GROUP.

nThreads:int

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

threadFactory:ThreadFactory

the ThreadFactory to use.

ioRatio:int

the IO ratio

Returns:EventLoopGroup

a new event loop group

isAvailableback to summary
public default boolean isAvailable()
Returns:boolean

true when the transport is available.

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

References Deprecated

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

See corresponding docs for further information.

Parameters
domainSocket:boolean

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

Returns:ChannelFactory<? extends ServerChannel>

the type for server channel

supportFileRegionback to summary
public default boolean supportFileRegion()
supportsDomainSocketsback to summary
public default boolean supportsDomainSockets()
unavailabilityCauseback to summary
public default Throwable unavailabilityCause()
Returns:Throwable

the error that cause the unavailability when isAvailable() returns null.