Package com.mongodb.connection.netty
Class NettyStreamFactoryFactory
- java.lang.Object
-
- com.mongodb.connection.netty.NettyStreamFactoryFactory
-
- All Implemented Interfaces:
StreamFactoryFactory
public class NettyStreamFactoryFactory extends Object implements StreamFactoryFactory
AStreamFactoryFactory
implementation for Netty-based streams.- Since:
- 3.1
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
NettyStreamFactoryFactory.Builder
A builder for an instance ofNettyStreamFactoryFactory
.
-
Constructor Summary
Constructors Constructor Description NettyStreamFactoryFactory()
Deprecated.Usebuilder()
instead to construct theNettyStreamFactoryFactory
.NettyStreamFactoryFactory(io.netty.channel.EventLoopGroup eventLoopGroup, io.netty.buffer.ByteBufAllocator allocator)
Deprecated.Usebuilder()
instead to construct theNettyStreamFactoryFactory
.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static NettyStreamFactoryFactory.Builder
builder()
Gets a builder for an instance ofNettyStreamFactoryFactory
.StreamFactory
create(SocketSettings socketSettings, SslSettings sslSettings)
Create aStreamFactory
with the given settings.String
toString()
-
-
-
Constructor Detail
-
NettyStreamFactoryFactory
@Deprecated public NettyStreamFactoryFactory()
Deprecated.Usebuilder()
instead to construct theNettyStreamFactoryFactory
.Construct an instance with the defaultEventLoopGroup
andByteBufAllocator
.
-
NettyStreamFactoryFactory
@Deprecated public NettyStreamFactoryFactory(io.netty.channel.EventLoopGroup eventLoopGroup, io.netty.buffer.ByteBufAllocator allocator)
Deprecated.Usebuilder()
instead to construct theNettyStreamFactoryFactory
.Construct an instance with the givenEventLoopGroup
andByteBufAllocator
.- Parameters:
eventLoopGroup
- the non-null event loop groupallocator
- the non-null byte buf allocator
-
-
Method Detail
-
builder
public static NettyStreamFactoryFactory.Builder builder()
Gets a builder for an instance ofNettyStreamFactoryFactory
.- Returns:
- the builder
- Since:
- 3.3
-
create
public StreamFactory create(SocketSettings socketSettings, SslSettings sslSettings)
Description copied from interface:StreamFactoryFactory
Create aStreamFactory
with the given settings.- Specified by:
create
in interfaceStreamFactoryFactory
- Parameters:
socketSettings
- the socket settingssslSettings
- the SSL settings- Returns:
- a stream factory that will apply the given settins
-
-