示例#1
0
文件: NetRole.java 项目: eiasy/DouPo
	public void releaseNet() {
		if (netSession != null) {
			netSession.releaseSession(sessionId);
			netSession.releaseNet();
			netSession = null;
		}
		// releaseResource();
	}
示例#2
0
文件: NetRole.java 项目: eiasy/DouPo
	public void sendData(IoBuffer packet) {
		if (netSession != null) {
			netSession.sendData(sessionId, packet);
		} else {
			PacketBufferPool.freePacketBuffer(packet);
		}
	}
示例#3
0
文件: NetRole.java 项目: eiasy/DouPo
	public boolean isNetConnected() {
		return netSession != null && netSession.isConnected();
	}
示例#4
0
文件: NetRole.java 项目: eiasy/DouPo
	public void bindPhoneRemote(int eventId, String phone, String pwd, String vcode) {
		if (netSession != null) {
			netSession.bindPhone(this, eventId, phone, pwd, vcode);
		}
	}
示例#5
0
文件: NetRole.java 项目: eiasy/DouPo
	/**
	 * 反向注册验证码
	 */
	public void reverseSecurityCode() {
		if (netSession != null) {
			netSession.reverseSecurityCode();
		}
	}
示例#6
0
文件: NetRole.java 项目: eiasy/DouPo
	public void validateSecurityCoide(int eventId, String securityCode) {
		if (netSession != null) {
			netSession.validateSecurityCode(eventId, securityCode);
		}
	}
示例#7
0
文件: NetRole.java 项目: eiasy/DouPo
	public void validatePhoneRemote(int eventId, String phone, boolean binded) {
		if (netSession != null) {
			netSession.validatePhone(this, eventId, phone, binded);
		}
	}
示例#8
0
文件: NetRole.java 项目: eiasy/DouPo
	/**
	 * 修改密码
	 * 
	 * @param eventId
	 *            事件编号
	 * @param oldPwd
	 *            旧密码
	 * @param newPwd
	 *            新密码
	 */
	public void alterPasswordRemote(int eventId, String oldPwd, String newPwd) {
		if (netSession != null) {
			netSession.alterPassword(this, eventId, oldPwd, newPwd);
		}
	}
示例#9
0
文件: NetRole.java 项目: eiasy/DouPo
	/**
	 * 验证兑换码
	 * 
	 * @param eventId
	 *            事件编号
	 * @param exchangeCode
	 *            兑换码
	 * @type 类别
	 */
	public void validateExchangeRemote(int eventId, String exchangeCode) {
		if (netSession != null) {
			netSession.validateExchange(this, eventId, exchangeCode);
		}
	}
示例#10
0
文件: NetRole.java 项目: eiasy/DouPo
	public void pushData() {
		if (netSession != null) {
			netSession.pushData();
		}
	}
示例#11
0
文件: NetRole.java 项目: eiasy/DouPo
	public final void close(boolean immediately) {
		if (netSession != null) {
			netSession.close(immediately);
		}
	}