Commit 9cc833ff authored by Lukáš Marek's avatar Lukáš Marek

Reintroduce static C methods where applicable

Stub for class information
parent dbbb33de
This diff is collapsed.
......@@ -8,7 +8,9 @@
static const jint MSG_CLOSE = 0;
// sending analysis
static const jint MSG_ANALYZE = 1;
// sending analysis
static const jint MSG_OBJFREE = 2;
// sending object free
static const jint MSG_OBJ_FREE = 2;
// sending new class
static const jint MSG_NEW_CLASS = 3;
#endif /* _MESSAGETYPE_H */
......@@ -65,7 +65,6 @@ public class AnalysisHandler implements RequestHandler {
// *** invoke method ***
try {
// TODO re ! support static methods
analysisMethod.invoke(amh.getAnalysisInstance(), args.toArray());
}
catch(InvocationTargetException e) {
......
package ch.usi.dag.dislreserver.msg.newclass;
import java.io.DataInputStream;
import java.io.DataOutputStream;
import java.io.IOException;
import ch.usi.dag.dislreserver.exception.DiSLREServerException;
import ch.usi.dag.dislreserver.reqdispatch.RequestHandler;
public class NewClassHandler implements RequestHandler {
public void handle(DataInputStream is, DataOutputStream os, boolean debug)
throws DiSLREServerException {
try {
String className = is.readUTF();
long classLoderId = is.readLong();
int classCodeLength = is.readInt();
byte[] classCode = new byte[classCodeLength];
is.readFully(classCode);
// TODO re ! new class
}
catch (IOException e) {
throw new DiSLREServerException(e);
}
}
}
......@@ -9,6 +9,7 @@ import ch.usi.dag.dislreserver.exception.DiSLREServerException;
import ch.usi.dag.dislreserver.exception.DiSLREServerFatalException;
import ch.usi.dag.dislreserver.msg.analyze.AnalysisHandler;
import ch.usi.dag.dislreserver.msg.close.CloseHandler;
import ch.usi.dag.dislreserver.msg.newclass.NewClassHandler;
import ch.usi.dag.dislreserver.msg.objfree.ObjectFreeHandler;
public class RequestDispatcher {
......@@ -26,6 +27,8 @@ public class RequestDispatcher {
requestMap.put(1, new AnalysisHandler());
// object free
requestMap.put(2, new ObjectFreeHandler());
// new class
requestMap.put(3, new NewClassHandler());
}
public static boolean dispatch(int requestNo, DataInputStream is,
......
Markdown is supported
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