File tree Expand file tree Collapse file tree 3 files changed +8
-0
lines changed
src/main/java/org/cyberpwn/react Expand file tree Collapse file tree 3 files changed +8
-0
lines changed Original file line number Diff line number Diff line change 11package org .cyberpwn .react .network ;
22
3+ import org .cyberpwn .react .L ;
34import org .cyberpwn .react .util .GMap ;
45import org .json .JSONObject ;
56
@@ -24,10 +25,12 @@ public void run() {
2425 DataInputStream i = new DataInputStream (s .getInputStream ());
2526 DataOutputStream o = new DataOutputStream (s .getOutputStream ());
2627 PacketRequest pr = new PacketRequest (ns .getUsername (), ns .getPassword (), PacketRequestType .GET_SAMPLES .toString ());
28+ //L.n("OUT: " + pr.toString());
2729 o .writeUTF (pr .toString ());
2830 o .flush ();
2931 String response = i .readUTF ();
3032 PacketResponse ps = new PacketResponse (new JSONObject (response ));
33+ //L.n("IN: " + ps.toString());
3134 GMap <String , Double > data = new GMap <>();
3235 String console = "" ;
3336
Original file line number Diff line number Diff line change 11package org .cyberpwn .react .network ;
22
3+ import org .cyberpwn .react .L ;
34import org .cyberpwn .react .util .GMap ;
45import org .json .JSONObject ;
56
@@ -24,10 +25,12 @@ public void run() {
2425 DataInputStream i = new DataInputStream (s .getInputStream ());
2526 DataOutputStream o = new DataOutputStream (s .getOutputStream ());
2627 PacketRequest pr = new PacketRequest (ns .getUsername (), ns .getPassword (), PacketRequestType .GET_BASIC .toString ());
28+ L .n ("OUT: " + pr .toString ());
2729 o .writeUTF (pr .toString ());
2830 o .flush ();
2931 String response = i .readUTF ();
3032 PacketResponse ps = new PacketResponse (new JSONObject (response ));
33+ L .n ("IN: " + ps .toString ());
3134 GMap <String , String > data = new GMap <>();
3235
3336 if (ps .getString ("type" ).equals ("OK" )) {
Original file line number Diff line number Diff line change @@ -442,6 +442,8 @@ public void push(GList<String> actions) {
442442
443443 public void push (GMap <String , Double > sample , String console ) {
444444 sample .put ("rct" , sample .get ("rct" ) / 1000000.0 );
445+ sample .put ("mah/s" , sample .get ("mah/s" ) / 1024D / 1024D );
446+ sample .put ("mem" , sample .get ("mem" ) / 1024 / 1024 );
445447 lastConsole = StringUtils .repeat ("\n " , 40 ) + console ;
446448 lastLog = StringUtils .repeat ("\n " , 40 ) + L .log ;
447449
You can’t perform that action at this time.
0 commit comments