public void close(){		
		if(this.requestWithFile != null && this.requestWithFile.isReadFile()){
			FileTransfer fr = requestWithFile.getFileReceiver();
			if(fr != null  && !fr.finishWrite()){
				fr.forceClose();// 强制关闭删除损害的文件
			}
		}
				
		// 关闭连接
		SocketChannel socketChannel = (SocketChannel) this.key.channel();
		try{
			this.sockectServer.clearSocket(index);// 清除
			unregiste();			
			this.key.attach(null);
			this.key.cancel();
		} catch (ClosedChannelException e) {
			e.printStackTrace();
		}finally{			
			try{
				//socketChannel.socket().getOutputStream().flush();
				socketChannel.close();
			}catch(IOException e){
				e.printStackTrace();
			}
		}
		
	}