Commit 87131815 authored by adwisatya's avatar adwisatya
Browse files

X

parent 305ddd1c
......@@ -3,29 +3,10 @@
<editor-bookmarks xmlns="http://www.netbeans.org/ns/editor-bookmarks/2" lastBookmarkId="0"/>
<open-files xmlns="http://www.netbeans.org/ns/projectui-open-files/2">
<group>
<<<<<<< HEAD
<file>file:/F:/z~edo/Kuliah/Semester%206/IF3230%20Sistem%20Paralel%20dan%20Terdistribusi/Tugas%20Akhir/src/client/TheAlchemistClient/src/thealchemist/gui/AlcMixItem.java</file>
<file>file:/F:/z~edo/Kuliah/Semester%206/IF3230%20Sistem%20Paralel%20dan%20Terdistribusi/Tugas%20Akhir/src/client/TheAlchemistClient/src/thealchemist/gui/AlcLogon.java</file>
<file>file:/F:/z~edo/Kuliah/Semester%206/IF3230%20Sistem%20Paralel%20dan%20Terdistribusi/Tugas%20Akhir/src/client/TheAlchemistClient/src/thealchemist/gui/AlcMap.java</file>
<file>file:/F:/z~edo/Kuliah/Semester%206/IF3230%20Sistem%20Paralel%20dan%20Terdistribusi/Tugas%20Akhir/src/client/TheAlchemistClient/src/thealchemist/gui/AlcFindItem.java</file>
<file>file:/F:/z~edo/Kuliah/Semester%206/IF3230%20Sistem%20Paralel%20dan%20Terdistribusi/Tugas%20Akhir/src/client/TheAlchemistClient/src/thealchemist/engine/Main.java</file>
<file>file:/F:/z~edo/Kuliah/Semester%206/IF3230%20Sistem%20Paralel%20dan%20Terdistribusi/Tugas%20Akhir/src/client/TheAlchemistClient/src/thealchemist/gui/AlcTradeBox.java</file>
<file>file:/F:/z~edo/Kuliah/Semester%206/IF3230%20Sistem%20Paralel%20dan%20Terdistribusi/Tugas%20Akhir/src/client/TheAlchemistClient/src/thealchemist/gui/AlcItem.java</file>
<file>file:/F:/z~edo/Kuliah/Semester%206/IF3230%20Sistem%20Paralel%20dan%20Terdistribusi/Tugas%20Akhir/src/client/TheAlchemistClient/src/thealchemist/engine/Response.java</file>
<file>file:/F:/z~edo/Kuliah/Semester%206/IF3230%20Sistem%20Paralel%20dan%20Terdistribusi/Tugas%20Akhir/src/client/TheAlchemistClient/src/thealchemist/engine/Connection.java</file>
=======
<file>file:/C:/Users/adwisatya/Documents/Semester%206/Tugas/IF3230%20Sister/IF3230-Tugas-Besar-Sister-2015/src/client/TheAlchemistClient/src/thealchemist/gui/AlcOffer.java</file>
<file>file:/C:/Users/adwisatya/Documents/Semester%206/Tugas/IF3230%20Sister/IF3230-Tugas-Besar-Sister-2015/src/client/TheAlchemistClient/src/thealchemist/gui/AlcItem.java</file>
<file>file:/C:/Users/adwisatya/Documents/Semester%206/Tugas/IF3230%20Sister/IF3230-Tugas-Besar-Sister-2015/src/client/TheAlchemistClient/src/thealchemist/gui/AlcFindItem.java</file>
<file>file:/C:/Users/adwisatya/Documents/Semester%206/Tugas/IF3230%20Sister/IF3230-Tugas-Besar-Sister-2015/src/client/TheAlchemistClient/src/thealchemist/gui/AlcMap.java</file>
<file>file:/C:/Users/adwisatya/Documents/Semester%206/Tugas/IF3230%20Sister/IF3230-Tugas-Besar-Sister-2015/src/client/TheAlchemistClient/src/thealchemist/engine/Connection.java</file>
<file>file:/C:/Users/adwisatya/Documents/Semester%206/Tugas/IF3230%20Sister/IF3230-Tugas-Besar-Sister-2015/src/client/TheAlchemistClient/src/thealchemist/engine/Main.java</file>
<file>file:/C:/Users/adwisatya/Documents/Semester%206/Tugas/IF3230%20Sister/IF3230-Tugas-Besar-Sister-2015/src/client/TheAlchemistClient/src/thealchemist/gui/AlcTradeBox.java</file>
<file>file:/C:/Users/adwisatya/Documents/Semester%206/Tugas/IF3230%20Sister/IF3230-Tugas-Besar-Sister-2015/src/client/TheAlchemistClient/src/thealchemist/gui/AlcTradeItem.java</file>
<file>file:/C:/Users/adwisatya/Documents/Semester%206/Tugas/IF3230%20Sister/IF3230-Tugas-Besar-Sister-2015/src/client/TheAlchemistClient/src/thealchemist/gui/AlcLogon.java</file>
<file>file:/C:/Users/adwisatya/Documents/Semester%206/Tugas/IF3230%20Sister/IF3230-Tugas-Besar-Sister-2015/src/client/TheAlchemistClient/src/thealchemist/gui/AlcMixItem.java</file>
<file>file:/C:/Users/adwisatya/Documents/Semester%206/Tugas/IF3230%20Sister/IF3230-Tugas-Besar-Sister-2015/src/client/TheAlchemistClient/src/thealchemist/gui/ImagePanel.java</file>
>>>>>>> ab35a18e11b0fab1af378a1ddb185a0c486fc47b
<file>file:/C:/Users/adwisatya/Documents/Semester%206/Tugas/IF3230%20Sister/IF3230-Tugas-Besar-Sister-2015/src/client/TheAlchemistClient/src/thealchemist/engine/Response.java</file>
</group>
</open-files>
</project-private>
......@@ -3,16 +3,9 @@
<editor-bookmarks xmlns="http://www.netbeans.org/ns/editor-bookmarks/2" lastBookmarkId="0"/>
<open-files xmlns="http://www.netbeans.org/ns/projectui-open-files/2">
<group>
<<<<<<< HEAD
<file>file:/F:/z~edo/Kuliah/Semester%206/IF3230%20Sistem%20Paralel%20dan%20Terdistribusi/Tugas%20Akhir/src/server/src/thealchemist/Client.java</file>
<file>file:/F:/z~edo/Kuliah/Semester%206/IF3230%20Sistem%20Paralel%20dan%20Terdistribusi/Tugas%20Akhir/src/server/src/thealchemist/TCPServer.java</file>
<file>file:/F:/z~edo/Kuliah/Semester%206/IF3230%20Sistem%20Paralel%20dan%20Terdistribusi/Tugas%20Akhir/src/server/src/thealchemist/Database.java</file>
=======
<file>file:/C:/Users/adwisatya/Documents/Semester%206/Tugas/IF3230%20Sister/IF3230-Tugas-Besar-Sister-2015/src/server/src/folder/map.json</file>
<file>file:/C:/Users/adwisatya/Documents/Semester%206/Tugas/IF3230%20Sister/IF3230-Tugas-Besar-Sister-2015/src/server/src/thealchemist/Client.java</file>
<file>file:/C:/Users/adwisatya/Documents/Semester%206/Tugas/IF3230%20Sister/IF3230-Tugas-Besar-Sister-2015/src/server/src/thealchemist/Database.java</file>
<file>file:/C:/Users/adwisatya/Documents/Semester%206/Tugas/IF3230%20Sister/IF3230-Tugas-Besar-Sister-2015/src/server/src/thealchemist/TCPServer.java</file>
>>>>>>> ab35a18e11b0fab1af378a1ddb185a0c486fc47b
</group>
</open-files>
</project-private>
......@@ -115,7 +115,6 @@ public class Client extends Thread{
System.out.println(database.getServers().toString());
break;
case "serverStatus":
System.out.println(JSONtoString("server",cmd));
cmdServerStatus(JSONtoString("server",cmd));
break;
/* 1 */
......@@ -138,7 +137,7 @@ public class Client extends Thread{
case "mixitem":
cmdMixitem(JSONtoString("token",cmd),JSONtoString("item1",cmd),JSONtoString("item2",cmd));
break;
/* 6 belum */
/* 6 */
case "map":
cmdMap(JSONtoString("token",cmd));
break;
......@@ -162,8 +161,9 @@ public class Client extends Thread{
case "sendfind":
cmdSendFind(JSONtoString("token",cmd), Integer.parseInt(JSONtoString("item",cmd)));
break;
case "12": System.out.println(cmdFindOffer("ece63df163ce1948008064c006f4900d",2));
/* 12 belum */
case "findoffer":
cmdFindOffer(new Integer(JSONtoString("itemid",cmd)));
break;
case "13": System.out.println(cmdSendAccept("ece63df163ce1948008064c006f4900d","ece63df163ce1948008064c006f4900d"));
break;
......@@ -197,7 +197,7 @@ public class Client extends Thread{
} catch (JSONException ex) {
Logger.getLogger(Client.class.getName()).log(Level.SEVERE, null, ex);
}
System.out.println("request");
System.out.println(request);
}
public void cmdJoin() throws IOException, JSONException{
String response = "";
......@@ -398,7 +398,7 @@ public class Client extends Thread{
sendToClient(obj.toString());
}
/* Sukses */
public String cmdFindOffer(String token,int itemId) throws IOException, NoSuchAlgorithmException, JSONException{
public void cmdFindOffer(int itemId) throws IOException, NoSuchAlgorithmException, JSONException{
String response = "";
String request= "";
Socket miniSocket = new Socket(URL,dbPort);
......@@ -416,8 +416,6 @@ public class Client extends Thread{
BufferedReader in = new BufferedReader(new InputStreamReader(miniSocket.getInputStream()));
response = org.apache.commons.io.IOUtils.toString(in);
in.close();
return response;
}
/* Sukses */
public String cmdSendAccept(String token, String offer_token) throws IOException, NoSuchAlgorithmException, JSONException{
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment