mirror of
https://git.huckle.dev/Huckles-Minecraft-Archive/jpexs-decompiler.git
synced 2026-06-01 19:04:38 +00:00
JPProxy update
This commit is contained in:
@@ -1,25 +1,19 @@
|
||||
package com.jpexs.proxy;
|
||||
|
||||
|
||||
import java.io.BufferedInputStream;
|
||||
import java.io.BufferedOutputStream;
|
||||
import java.io.IOException;
|
||||
import java.io.*;
|
||||
import java.net.Socket;
|
||||
|
||||
/**
|
||||
* Client which reads a Request and writes a Reply.
|
||||
*
|
||||
* @author Mark Boyns
|
||||
*/
|
||||
public class Client extends Connection {
|
||||
public class Client extends Connection
|
||||
{
|
||||
/**
|
||||
* Create a Client from a Socket.
|
||||
*/
|
||||
Client(Socket s) throws IOException {
|
||||
super(s);
|
||||
in = new BufferedInputStream(in);
|
||||
//out = new DebugOutputStream(new BufferedOutputStream(out));
|
||||
out = new BufferedOutputStream(out);
|
||||
Client(Socket s) throws IOException
|
||||
{
|
||||
super(s);
|
||||
in = new BufferedInputStream(in);
|
||||
//out = new DebugOutputStream(new BufferedOutputStream(out));
|
||||
out = new BufferedOutputStream(out);
|
||||
}
|
||||
|
||||
|
||||
@@ -27,17 +21,22 @@ public class Client extends Connection {
|
||||
* Read a Request.
|
||||
*
|
||||
* @returns a Request.
|
||||
* @see Request
|
||||
*/
|
||||
Request read() throws IOException {
|
||||
Request request = new Request(this);
|
||||
request.read(getInputStream());
|
||||
return request;
|
||||
Request read() throws IOException
|
||||
{
|
||||
Request request = new Request(this);
|
||||
request.read(getInputStream());
|
||||
return request;
|
||||
}
|
||||
|
||||
/**
|
||||
* Write a Reply
|
||||
*
|
||||
* @see Reply
|
||||
*/
|
||||
void write(Reply reply) throws IOException {
|
||||
reply.write(getOutputStream());
|
||||
void write(Reply reply) throws IOException
|
||||
{
|
||||
reply.write(getOutputStream());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user