GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — Finish the refactoring of bootstrap · netty/netty@ec1339d

File tree

Expand file treeCollapse file tree
Open diff view settings
Filter options
  • example/src/main/java/io/netty/example
    • discard
      • DiscardClient.java
      • DiscardServer.java
    • echo
      • EchoClient.java
      • EchoServer.java
    • factorial
      • FactorialClient.java
      • FactorialServer.java
    • http
      • file
        • HttpStaticFileServer.java
      • snoop
        • HttpSnoopClient.java
        • HttpSnoopServer.java
      • websocketx
        • autobahn
          • AutobahnServer.java
        • client
          • WebSocketClient.java
        • server
          • WebSocketServer.java
        • sslserver
          • WebSocketSslServer.java
    • localecho
      • LocalEcho.java
    • localtime
      • LocalTimeClient.java
      • LocalTimeServer.java
    • objectecho
      • ObjectEchoClient.java
      • ObjectEchoServer.java
    • portunification
      • PortUnificationServer.java
    • proxy
      • HexDumpProxy.java
      • HexDumpProxyFrontendHandler.java
    • qotm
      • QuoteOfTheMomentClient.java
      • QuoteOfTheMomentServer.java
    • sctp
      • SctpEchoClient.java
      • SctpEchoServer.java
    • securechat
      • SecureChatClient.java
      • SecureChatServer.java
    • telnet
      • TelnetClient.java
      • TelnetServer.java
    • uptime
      • UptimeClient.java
      • UptimeClientHandler.java
  • testsuite/src/test/java/io/netty/testsuite/transport/socket
    • AbstractClientSocketTest.java
    • AbstractDatagramTest.java
    • AbstractSocketTest.java
    • SocketEchoTest.java
    • SocketFixedLengthEchoTest.java
    • SocketObjectEchoTest.java
    • SocketShutdownOutputBySelfTest.java
    • SocketSpdyEchoTest.java
    • SocketSslEchoTest.java
    • SocketStringEchoTest.java
    • SocketTestPermutation.java
  • transport/src/main/java/io/netty/bootstrap
    • Bootstrap.java
    • ClientBootstrap.java

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
Dismiss banner
Expand file treeCollapse file tree
Open diff view settings
Collapse file

‎example/src/main/java/io/netty/example/discard/DiscardClient.java‎

Copy file name to clipboardExpand all lines: example/src/main/java/io/netty/example/discard/DiscardClient.java
+3-3Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
*/
1616
package io.netty.example.discard;
1717

18-
import io.netty.bootstrap.Bootstrap;
18+
import io.netty.bootstrap.ClientBootstrap;
1919
import io.netty.channel.ChannelFuture;
2020
import io.netty.channel.socket.nio.NioEventLoopGroup;
2121
import io.netty.channel.socket.nio.NioSocketChannel;
@@ -36,10 +36,10 @@ public DiscardClient(String host, int port, int firstMessageSize) {
3636
}
3737

3838
public void run() throws Exception {
39-
Bootstrap b = new Bootstrap();
39+
ClientBootstrap b = new ClientBootstrap();
4040
try {
4141
b.group(new NioEventLoopGroup())
42-
.channel(new NioSocketChannel())
42+
.channel(NioSocketChannel.class)
4343
.remoteAddress(host, port)
4444
.handler(new DiscardClientHandler(firstMessageSize));
4545

Collapse file

‎example/src/main/java/io/netty/example/discard/DiscardServer.java‎

Copy file name to clipboardExpand all lines: example/src/main/java/io/netty/example/discard/DiscardServer.java
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ public void run() throws Exception {
3737
ServerBootstrap b = new ServerBootstrap();
3838
try {
3939
b.group(new NioEventLoopGroup(), new NioEventLoopGroup())
40-
.channel(new NioServerSocketChannel())
40+
.channel(NioServerSocketChannel.class)
4141
.localAddress(port)
4242
.childHandler(new ChannelInitializer<SocketChannel>() {
4343
@Override
Collapse file

‎example/src/main/java/io/netty/example/echo/EchoClient.java‎

Copy file name to clipboardExpand all lines: example/src/main/java/io/netty/example/echo/EchoClient.java
+3-3Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
*/
1616
package io.netty.example.echo;
1717

18-
import io.netty.bootstrap.Bootstrap;
18+
import io.netty.bootstrap.ClientBootstrap;
1919
import io.netty.channel.ChannelFuture;
2020
import io.netty.channel.ChannelInitializer;
2121
import io.netty.channel.ChannelOption;
@@ -47,10 +47,10 @@ public EchoClient(String host, int port, int firstMessageSize) {
4747

4848
public void run() throws Exception {
4949
// Configure the client.
50-
Bootstrap b = new Bootstrap();
50+
ClientBootstrap b = new ClientBootstrap();
5151
try {
5252
b.group(new NioEventLoopGroup())
53-
.channel(new NioSocketChannel())
53+
.channel(NioSocketChannel.class)
5454
.option(ChannelOption.TCP_NODELAY, true)
5555
.remoteAddress(new InetSocketAddress(host, port))
5656
.handler(new ChannelInitializer<SocketChannel>() {
Collapse file

‎example/src/main/java/io/netty/example/echo/EchoServer.java‎

Copy file name to clipboardExpand all lines: example/src/main/java/io/netty/example/echo/EchoServer.java
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ public void run() throws Exception {
4343
ServerBootstrap b = new ServerBootstrap();
4444
try {
4545
b.group(new NioEventLoopGroup(), new NioEventLoopGroup())
46-
.channel(new NioServerSocketChannel())
46+
.channel(NioServerSocketChannel.class)
4747
.option(ChannelOption.SO_BACKLOG, 100)
4848
.localAddress(new InetSocketAddress(port))
4949
.childOption(ChannelOption.TCP_NODELAY, true)
Collapse file

‎example/src/main/java/io/netty/example/factorial/FactorialClient.java‎

Copy file name to clipboardExpand all lines: example/src/main/java/io/netty/example/factorial/FactorialClient.java
+3-3Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
*/
1616
package io.netty.example.factorial;
1717

18-
import io.netty.bootstrap.Bootstrap;
18+
import io.netty.bootstrap.ClientBootstrap;
1919
import io.netty.channel.ChannelFuture;
2020
import io.netty.channel.socket.nio.NioEventLoopGroup;
2121
import io.netty.channel.socket.nio.NioSocketChannel;
@@ -37,10 +37,10 @@ public FactorialClient(String host, int port, int count) {
3737
}
3838

3939
public void run() throws Exception {
40-
Bootstrap b = new Bootstrap();
40+
ClientBootstrap b = new ClientBootstrap();
4141
try {
4242
b.group(new NioEventLoopGroup())
43-
.channel(new NioSocketChannel())
43+
.channel(NioSocketChannel.class)
4444
.remoteAddress(host, port)
4545
.handler(new FactorialClientInitializer(count));
4646

Collapse file

‎example/src/main/java/io/netty/example/factorial/FactorialServer.java‎

Copy file name to clipboardExpand all lines: example/src/main/java/io/netty/example/factorial/FactorialServer.java
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ public void run() throws Exception {
3535
ServerBootstrap b = new ServerBootstrap();
3636
try {
3737
b.group(new NioEventLoopGroup(), new NioEventLoopGroup())
38-
.channel(new NioServerSocketChannel())
38+
.channel(NioServerSocketChannel.class)
3939
.localAddress(port)
4040
.childHandler(new FactorialServerInitializer());
4141

Collapse file

‎example/src/main/java/io/netty/example/http/file/HttpStaticFileServer.java‎

Copy file name to clipboardExpand all lines: example/src/main/java/io/netty/example/http/file/HttpStaticFileServer.java
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ public void run() throws Exception {
3131
ServerBootstrap b = new ServerBootstrap();
3232
try {
3333
b.group(new NioEventLoopGroup(), new NioEventLoopGroup())
34-
.channel(new NioServerSocketChannel())
34+
.channel(NioServerSocketChannel.class)
3535
.localAddress(port)
3636
.childHandler(new HttpStaticFileServerInitializer());
3737

Collapse file

‎example/src/main/java/io/netty/example/http/snoop/HttpSnoopClient.java‎

Copy file name to clipboardExpand all lines: example/src/main/java/io/netty/example/http/snoop/HttpSnoopClient.java
+3-3Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
*/
1616
package io.netty.example.http.snoop;
1717

18-
import io.netty.bootstrap.Bootstrap;
18+
import io.netty.bootstrap.ClientBootstrap;
1919
import io.netty.channel.Channel;
2020
import io.netty.channel.socket.nio.NioEventLoopGroup;
2121
import io.netty.channel.socket.nio.NioSocketChannel;
@@ -62,10 +62,10 @@ public void run() throws Exception {
6262
boolean ssl = scheme.equalsIgnoreCase("https");
6363

6464
// Configure the client.
65-
Bootstrap b = new Bootstrap();
65+
ClientBootstrap b = new ClientBootstrap();
6666
try {
6767
b.group(new NioEventLoopGroup())
68-
.channel(new NioSocketChannel())
68+
.channel(NioSocketChannel.class)
6969
.handler(new HttpSnoopClientInitializer(ssl))
7070
.remoteAddress(new InetSocketAddress(host, port));
7171

Collapse file

‎example/src/main/java/io/netty/example/http/snoop/HttpSnoopServer.java‎

Copy file name to clipboardExpand all lines: example/src/main/java/io/netty/example/http/snoop/HttpSnoopServer.java
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ public void run() throws Exception {
4040

4141
try {
4242
b.group(new NioEventLoopGroup(), new NioEventLoopGroup())
43-
.channel(new NioServerSocketChannel())
43+
.channel(NioServerSocketChannel.class)
4444
.childHandler(new HttpSnoopServerInitializer())
4545
.localAddress(new InetSocketAddress(port));
4646

Collapse file

‎example/src/main/java/io/netty/example/http/websocketx/autobahn/AutobahnServer.java‎

Copy file name to clipboardExpand all lines: example/src/main/java/io/netty/example/http/websocketx/autobahn/AutobahnServer.java
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ public void run() throws Exception {
3636
ServerBootstrap b = new ServerBootstrap();
3737
try {
3838
b.group(new NioEventLoopGroup(), new NioEventLoopGroup())
39-
.channel(new NioServerSocketChannel())
39+
.channel(NioServerSocketChannel.class)
4040
.localAddress(port)
4141
.childHandler(new AutobahnServerInitializer());
4242

0 commit comments

Comments
0 (0)
You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.