<commit_before>/**
 *****************************************************************************
 Copyright (c) 2016 IBM Corporation and other Contributors.
 All rights reserved. This program and the accompanying materials
 are made available under the terms of the Eclipse Public License v1.0
 which accompanies this distribution, and is available at
 http://www.eclipse.org/legal/epl-v10.html
 Contributors:
 <NAME> - Initial Contribution
 *****************************************************************************
 *
 */
package com.ibm.iotf.client.application;

import java.io.IOException;
import java.io.InputStream;
import java.io.OutputStream;
import java.net.ServerSocket;
import java.net.Socket;
import java.util.logging.Logger;
import com.ibm.iotf.client.application.AutoReconnect;

public class CommunicationProxyServer implements Runnable {
	static final Class<?> cclass = AutoReconnect.class;
	private static final String className = cclass.getName();
	private static final Logger log = Logger.getLogger(className);
	private int localDevicePort;
	private boolean portNumberSet = false;
	private String host;
	private int remoteServerPort;
	private Thread proxyThread;
	private Object enableLock = new Object();
	private boolean enableProxy = true;
	private boolean running = true;
	Socket client = null, server = null;
	ServerSocket serverSocket = null;
	private volatile int delayInServerResponse = 0;
	private volatile int delayInClientPublish = 0;
//	private static final String CLASS_NAME = AbstractClient.class.getName();
//	final String METHOD = "connect";
	

	public CommunicationProxyServer(String host, int remoteServerPort, int localDevicePort) {
		this.localDevicePort = this.remoteServerPort = remoteServerPort;
		this.host = host;
		proxyThread = new Thread(this);

	}
	<commit_msg>Modified localDevicePort value<commit_after>/**
 *****************************************************************************
 Copyright (c) 2016 IBM Corporation and other Contributors.
 All rights reserved. This program and the accompanying materials
 are made available under the terms of the Eclipse Public License v1.0
 which accompanies this distribution, and is available at
 http://www.eclipse.org/legal/epl-v10.html
 Contributors:
 <NAME> - Initial Contribution
 *****************************************************************************
 *
 */
package com.ibm.iotf.client.application;

import java.io.IOException;
import java.io.InputStream;
import java.io.OutputStream;
import java.net.ServerSocket;
import java.net.Socket;
import java.util.logging.Logger;
import com.ibm.iotf.client.application.AutoReconnect;

public class CommunicationProxyServer implements Runnable {
	static final Class<?> cclass = AutoReconnect.class;
	private static final String className = cclass.getName();
	private static final Logger log = Logger.getLogger(className);
	private int localDevicePort;
	private boolean portNumberSet = false;
	private String host;
	private int remoteServerPort;
	private Thread proxyThread;
	private Object enableLock = new Object();
	private boolean enableProxy = true;
	private boolean running = true;
	Socket client = null, server = null;
	ServerSocket serverSocket = null;
	private volatile int delayInServerResponse = 0;
	private volatile int delayInClientPublish = 0;
//	private static final String CLASS_NAME = AbstractClient.class.getName();
//	final String METHOD = "connect";
	

	public CommunicationProxyServer(String host, int remoteServerPort, int localDevicePort) {
		this.localDevicePort = localDevicePort;
		this.remoteServerPort = remoteServerPort;
		this.host = host;
		proxyThread = new Thread(this);
	}
	
{'fraction_non_alphanumeric': 0.1560535665482372, 'fraction_numerical': 0.005465974309920744, 'mean_word_length': 5.715596330275229, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 7, 'https://': 0, 'lorem ipsum': 0, 'www.': 2, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2372941', 'n_tokens_mistral': 951, 'n_tokens_neox': 893, 'n_words': 309}