--- /dev/null
+package jp.sourceforge.stigmata.birthmarks.wsp;\r
+\r
+/*\r
+ * $Id$\r
+ */\r
+\r
+import jp.sourceforge.stigmata.birthmarks.Opcode;\r
+\r
+/**\r
+ *\r
+ *\r
+ * @author tamada\r
+ * @version $Revision$\r
+ */\r
+public class WSPOpcode extends Opcode {\r
+ private static final long serialVersionUID = 31469629831901737L;\r
+\r
+ private int weight;\r
+\r
+ public WSPOpcode(int opcode, String name, int argumentCount, int act, Category category) {\r
+ super(opcode, name, argumentCount, act, category);\r
+ }\r
+\r
+ public WSPOpcode(int opcode, String name, int argumentCount, int act, String category) {\r
+ super(opcode, name, argumentCount, act, category);\r
+ }\r
+\r
+ public WSPOpcode(Opcode opcode) {\r
+ super(opcode);\r
+ }\r
+\r
+ public WSPOpcode(int opcode, String name, int argumentCount, int act, Category category, int weight){\r
+ this(opcode, name, argumentCount, act, category);\r
+\r
+ setWeight(weight);\r
+ }\r
+\r
+ public WSPOpcode(Opcode opcode, int weight){\r
+ super(opcode);\r
+\r
+ setWeight(weight);\r
+ }\r
+\r
+ public void setWeight(int weight){\r
+ this.weight = weight;\r
+ }\r
+\r
+ public int getWeight(){\r
+ return weight;\r
+ }\r
+\r
+ public String toString(){\r
+ return String.format("%d:%s:%d:%f(%s)", getOpcode(), getName(), getWeight(), getAct(), getCategory());\r
+ }\r
+}\r