public static MessageTCP getTCPInput(BufferedInputStream input, int argNum, boolean size) throws IOException{
		byte[] inputBuff = readFile(input);
		byte[] resultBuff = null;
		System.out.println(new String(inputBuff, "UTF-8"));
		Scanner sc = new Scanner(new ByteArrayInputStream(inputBuff));
		String[] args = new String[argNum];
		
		try{		
			args[0] = sc.next();
	
			if(argNum == 2){
				args[1] = sc.next();
			}
			
			if(argNum == 3){
				args[1] = sc.next();
			}
			
			if(size){
				int fileSize = 0;
				int offset = 0;
				
				if(argNum == 1){
					args[0] = sc.next();
				}
				else{
					args[args.length-1] = sc.next(Pattern.compile("([0-9]+)"));
					for(String s: args){
						offset += s.length() + 1;
					}
				}
				
				resultBuff = new byte[inputBuff.length - offset];
				System.arraycopy(inputBuff, offset, resultBuff, 0, resultBuff.length);
				
				if((char) resultBuff[resultBuff.length - 1] != '\n'){
					System.err.println(Errors.INVALID_PROTOCOL);
					System.exit(-1);
				}
				
				fileSize = Integer.parseInt(args[args.length-1]);
	
			}
		} catch (InputMismatchException e){
			System.err.println(Errors.INVALID_PROTOCOL);
			System.exit(-1);
		} catch (NoSuchElementException e){
			System.err.println(Errors.INVALID_PROTOCOL);
			System.exit(-1);
		}
		return new MessageTCP(args, resultBuff);
	}