All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.zusmart.base.network.support.DefaultChannelOption Maven / Gradle / Ivy

Go to download

提供基础的工具类及方法类,Logging,Scanner,Buffer,NetWork,Future,Thread

There is a newer version: 1.0.6
Show newest version
package com.zusmart.base.network.support;

import com.zusmart.base.network.ChannelOption;

public class DefaultChannelOption implements ChannelOption {

	private int backLog = 256;
	private int soTimeout = 0;
	private int bufferSize = 8192;
	private boolean directBuffer = false;
	private boolean reuseAddress = true;
	private int nioSelectorSize = Runtime.getRuntime().availableProcessors();
	private String nioSelectorName = "selector";
	private String nioAcceptorName = "accpetor";

	@Override
	public int getBackLog() {
		return this.backLog;
	}

	@Override
	public int getSoTimeout() {
		return this.soTimeout;
	}

	@Override
	public int getBufferSize() {
		return this.bufferSize;
	}

	@Override
	public boolean isDirectBuffer() {
		return this.directBuffer;
	}

	@Override
	public boolean isReuseAddress() {
		return this.reuseAddress;
	}

	@Override
	public int getNioSelectorSize() {
		return this.nioSelectorSize;
	}

	@Override
	public String getNioAcceptorName() {
		return this.nioAcceptorName;
	}

	@Override
	public String getNioSelectorName() {
		return this.nioSelectorName;
	}

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy