• R/O
  • HTTP
  • SSH
  • HTTPS

jcfa: Commit

JavaClassFileAnalyzer (jcfa) のメインリポジトリです。


Commit MetaInfo

Revision1893470b46b9e0cd2d5702387e76ecc9a89fe842 (tree)
Time2014-04-03 20:45:24
Authoriga <tosiki.iga@nift...>
Commiteriga

Log Message

save

Change Summary

Incremental Difference

--- a/jcfa/src.generated/jp/igapyon/jcfa/JcfaVersionConstants.java
+++ b/jcfa/src.generated/jp/igapyon/jcfa/JcfaVersionConstants.java
@@ -3,7 +3,7 @@ package jp.igapyon.jcfa;
33 /* This source file is generated by JavaClassFileAnalyzer. */
44 /* Do not modify this source file. */
55 public class JcfaVersionConstants {
6- public static final String VERSION = "I201404030744";
6+ public static final String VERSION = "I201404032042";
77
88 public static final String getVersion() {
99 return VERSION;
--- a/jcfa/src/jp/igapyon/jcfa/util/JcfaWriteUtil.java
+++ b/jcfa/src/jp/igapyon/jcfa/util/JcfaWriteUtil.java
@@ -12,6 +12,7 @@ import jp.igapyon.jcfa.vo.JcfaField;
1212 import jp.igapyon.jcfa.vo.JcfaMethod;
1313 import jp.igapyon.jcfa.vo.JcfaUnit;
1414 import jp.igapyon.jcfa.vo.operandstack.JcfaOSLocalVariable;
15+import jp.igapyon.jcfa.vo.operandstack.JcfaOSRef;
1516
1617 import org.apache.bcel.Constants;
1718 import org.apache.bcel.classfile.JavaClass;
@@ -152,10 +153,13 @@ public class JcfaWriteUtil {
152153 break;
153154 }
154155 case Constants.GETSTATIC: {
155- jcfaCode.getComment()
156- .getCommentList()
157- .add(JcfaUtil.getConstantFieldrefString(jc, codes[1],
158- codes[2]));
156+ final JcfaOSRef osRef = new JcfaOSRef();
157+ jcfaMethod.getFrame().getOperandStack().push(osRef);
158+ osRef.setClassName(JcfaUtil.getConstantFieldrefString(jc,
159+ codes[1], codes[2]));
160+
161+ jcfaCode.getComment().getCommentList()
162+ .add(osRef.getClassName());
159163 break;
160164 }
161165 case Constants.LDC: {
--- a/jcfa/src/jp/igapyon/jcfa/vo/operandstack/JcfaOSClass.java
+++ b/jcfa/src/jp/igapyon/jcfa/vo/operandstack/JcfaOSRef.java
@@ -1,6 +1,6 @@
11 package jp.igapyon.jcfa.vo.operandstack;
22
3-public class JcfaOSClass extends JcfaOSNode {
3+public class JcfaOSRef extends JcfaOSNode {
44 protected String className;
55
66 public String getClassName() {
--- /dev/null
+++ b/jcfa/testJavaClass/output/jp/igapyon/jcfa/vo/operandstack/JcfaOSRef.jcfa
@@ -0,0 +1,54 @@
1+package jp.igapyon.jcfa.vo.operandstack;
2+
3+/** TODO import func. is missing. */
4+public class JcfaOSRef extends jp.igapyon.jcfa.vo.operandstack.JcfaOSNode {
5+ /** */
6+ protected java.lang.String className;
7+
8+ /** Constructor. */
9+ public JcfaOSRef() {
10+ /*
11+ * 0: aload_0 this
12+ */
13+
14+ /*
15+ * 1: invokespecial jp/igapyon/jcfa/vo/operandstack/JcfaOSNode#<init>()V
16+ */
17+
18+ /* 4: return */
19+ }
20+
21+ /** Method. */
22+ public java.lang.String getClassName() {
23+ /*
24+ * 0: aload_0 this
25+ */
26+
27+ /*
28+ * 1: getfield TODO unsupported opcode
29+ */
30+
31+ /*
32+ * 4: areturn TODO unsupported opcode
33+ */
34+ }
35+
36+ /**
37+ * Method. java.lang.String
38+ */
39+ public void setClassName(java.lang.String arg0) {
40+ /*
41+ * 0: aload_0 this
42+ */
43+
44+ /*
45+ * 1: aload_1 TODO unsupported opcode
46+ */
47+
48+ /*
49+ * 2: putfield TODO unsupported opcode
50+ */
51+
52+ /* 5: return */
53+ }
54+}
\ No newline at end of file
Show on old repository browser