Examples of option()


Examples of io.netty.bootstrap.ServerBootstrap.option()

    private void doRun(EventLoopGroup loupGroup, Class<? extends ServerChannel> serverChannelClass) throws InterruptedException {
  try {
      ServerBootstrap b = new ServerBootstrap();
      b.option(ChannelOption.SO_BACKLOG, 1024);
      b.option(ChannelOption.SO_REUSEADDR, true);
      b.group(loupGroup).channel(serverChannelClass).childHandler(new HelloServerInitializer(loupGroup.next()));
      b.option(ChannelOption.MAX_MESSAGES_PER_READ, Integer.MAX_VALUE);
      b.childOption(ChannelOption.ALLOCATOR, new PooledByteBufAllocator(true));
      b.childOption(ChannelOption.SO_REUSEADDR, true);
      b.childOption(ChannelOption.MAX_MESSAGES_PER_READ, Integer.MAX_VALUE);
View Full Code Here

Examples of io.netty.bootstrap.ServerBootstrap.option()

  try {
      ServerBootstrap b = new ServerBootstrap();
      b.option(ChannelOption.SO_BACKLOG, 1024);
      b.option(ChannelOption.SO_REUSEADDR, true);
      b.group(loupGroup).channel(serverChannelClass).childHandler(new HelloServerInitializer(loupGroup.next()));
      b.option(ChannelOption.MAX_MESSAGES_PER_READ, Integer.MAX_VALUE);
      b.childOption(ChannelOption.ALLOCATOR, new PooledByteBufAllocator(true));
      b.childOption(ChannelOption.SO_REUSEADDR, true);
      b.childOption(ChannelOption.MAX_MESSAGES_PER_READ, Integer.MAX_VALUE);

      Channel ch = b.bind(port).sync().channel();
View Full Code Here

Examples of io.netty.bootstrap.ServerBootstrap.option()

        ServerBootstrap bootstrap = null;
        ;

        try {
            bootstrap = new ServerBootstrap();
            bootstrap.option(ChannelOption.SO_RCVBUF, 128 * 1024);
            bootstrap.option(ChannelOption.TCP_NODELAY, true);
            bootstrap.group(new NioEventLoopGroup(), new NioEventLoopGroup());
            bootstrap.channel(NioServerSocketChannel.class);
            bootstrap.localAddress(port);
            bootstrap.childHandler(new ChannelInitializer<SocketChannel>() {
View Full Code Here

Examples of io.netty.bootstrap.ServerBootstrap.option()

        ;

        try {
            bootstrap = new ServerBootstrap();
            bootstrap.option(ChannelOption.SO_RCVBUF, 128 * 1024);
            bootstrap.option(ChannelOption.TCP_NODELAY, true);
            bootstrap.group(new NioEventLoopGroup(), new NioEventLoopGroup());
            bootstrap.channel(NioServerSocketChannel.class);
            bootstrap.localAddress(port);
            bootstrap.childHandler(new ChannelInitializer<SocketChannel>() {
                @Override
View Full Code Here

Examples of io.netty.bootstrap.ServerBootstrap.option()

    public CubeServer start() {
        workerGroup = new NioEventLoopGroup(8);

        try {
            final ServerBootstrap bootstrap = new ServerBootstrap();
            bootstrap
                .option(ChannelOption.SO_REUSEADDR, true)
                .option(ChannelOption.SO_SNDBUF, 1024)
                .option(ChannelOption.TCP_NODELAY, true)
                .group(workerGroup)
                .channel(NioServerSocketChannel.class)
View Full Code Here

Examples of io.netty.bootstrap.ServerBootstrap.option()

    public CollectorServer start() {
        workerGroup = new NioEventLoopGroup(8);

        try {
            final ServerBootstrap bootstrap = new ServerBootstrap();
            bootstrap
                .option(ChannelOption.SO_REUSEADDR, true)
                .option(ChannelOption.SO_SNDBUF, 1024)
                .option(ChannelOption.TCP_NODELAY, true)
                .group(workerGroup)
                .channel(NioServerSocketChannel.class)
View Full Code Here

Examples of io.netty.bootstrap.ServerBootstrap.option()

        public HttpServer start() {
            workerGroup = new NioEventLoopGroup(8);

            try {
                final ServerBootstrap bootstrap = new ServerBootstrap();
                bootstrap
                    .option(ChannelOption.SO_REUSEADDR, true)
                    .option(ChannelOption.SO_SNDBUF, 1024)
                    .option(ChannelOption.TCP_NODELAY, true)
                    .group(workerGroup)
                    .channel(NioServerSocketChannel.class)
View Full Code Here

Examples of jimm.util.Getopts.option()

    DataVision dv = new DataVision();

    // Language
    if (g.hasOption('g') || g.hasOption('i'))
  I18N.setLanguage(new Locale(g.option('g', "").toLowerCase(),
            g.option('i', "").toUpperCase()));

    dv.layoutEngineChoiceFromOptions(g);
    dv.dataSourceFromOptions(g);
View Full Code Here

Examples of jimm.util.Getopts.option()

    DataVision dv = new DataVision();

    // Language
    if (g.hasOption('g') || g.hasOption('i'))
  I18N.setLanguage(new Locale(g.option('g', "").toLowerCase(),
            g.option('i', "").toUpperCase()));

    dv.layoutEngineChoiceFromOptions(g);
    dv.dataSourceFromOptions(g);

    if (dv.hasLayoutEngine()) {
View Full Code Here

Examples of jimm.util.Getopts.option()

      ErrorHandler.useGUI(true);
  else if (!g.hasOption('n') && !g.hasOption('p') && !g.hasOption('e'))
      usage(I18N.get("DataVision.n_or_p"));
    }

    dv.paramXMLFile = g.option('r', null); // Parameter XML file name or null
    dv.reportDir = g.option('R', null); // Report Directory or null
    dv.outputDir = g.option('o', null); // Output Directory or null

    // Store the report directory in the preferences for this package
    // These values are stored in the root package jimm.datavision
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.