Java Doc for Instruction.java in  » Database-DBMS » db4o-6.4 » EDU » purdue » cs » bloat » editor » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » Database DBMS » db4o 6.4 » EDU.purdue.cs.bloat.editor 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


java.lang.Object
   EDU.purdue.cs.bloat.editor.Instruction

Instruction
public class Instruction implements Opcode(Code)
Instruction represents a single instruction in the JVM. All Instructions known their opcode. Some instructions have an operand. Operands are integers, floats, or one of the special classes that represent multiple operands such as IncOperand and Switch.
See Also:   IncOperand
See Also:   Switch
See Also:   MultiArrayOperand
author:
   Nate Nystrom (author:
   href="mailto:nystrom@cs.purdue.edu">nystrom@cs.purdue.edu)



Constructor Summary
public  Instruction(int opcode)
     Constructor.
public  Instruction(int opcode, Object operand)
     Constructor.
public  Instruction(byte[] code, int index, int[] targets, int[] lookups, LocalVariable[] locals, ConstantPool constants)
     Constructor.

Method Summary
public  intcategory()
     Returns the category of this instruction.
public  booleanisConditionalJump()
     Check if the instruction is a conditional jump.
public  booleanisGoto()
     Check if the instruction is a goto.
public  booleanisInc()
     Check if the instruction is an increment.
public  booleanisInvoke()
     Returns true if this instruction invokes a method.
public  booleanisJsr()
     Check if the instruction is a jsr.
public  booleanisJump()
     Check if the instruction is a jump.
public  booleanisLoad()
     Check if the instruction is a load.
public  booleanisRet()
     Check if the instruction is a subroutine return instruction.
public  booleanisReturn()
     Returns true if the instruction returns from a method.
public  booleanisStore()
     Check if the instruction is a store.
public  booleanisSwitch()
     Check if the instruction is a switch.
public  booleanisThrow()
     Check if the instruction is an exception throw instruction.
public  intopcodeClass()
     Get the opcode class of the instruction.
public  Objectoperand()
     Get the operand of the instruction.
public  intorigOpcode()
     Returns the original (non-mapped) opcode used to create this Instruction.
public  voidsetOpcodeClass(int opcode)
     Set the opcode class of the instruction.
public  voidsetOperand(Object operand)
     Set the operand of the instruction.
public  voidsetUseSlow(boolean useSlow)
     Sets a flag that determines whether or not the "slow" version of the instruction should be generated.
protected static  inttoInt(byte b1, byte b2, byte b3, byte b4)
     Utility function to join 4 bytes into an signed int.
Parameters:
  b1 - The upper byte.
Parameters:
  b2 - The next-to-upper byte.
Parameters:
  b3 - The next-to-lower byte.
Parameters:
  b4 - The lower byte.
protected static  shorttoShort(byte b1, byte b2)
     Utility function to join 2 bytes into an signed short.
Parameters:
  b1 - The upper byte.
Parameters:
  b2 - The lower byte.
public  StringtoString()
     Convert the instruction to a string.
protected static  inttoUByte(byte b)
     Utility function to convert a byte into an unsigned byte.
Parameters:
  b - The byte.
protected static  inttoUShort(byte b1, byte b2)
     Utility function to join 2 bytes into an unsigned short.
Parameters:
  b1 - The upper byte.
Parameters:
  b2 - The lower byte.
public  booleanuseSlow()
     Returns whether or not the "slow" version of this instruction is generated.
public  voidvisit(InstructionVisitor visitor)
     Big switch statement to call the appropriate method of an instruction visitor.


Constructor Detail
Instruction
public Instruction(int opcode)(Code)
Constructor.
Parameters:
  opcode - The opcode class of the instruction.



Instruction
public Instruction(int opcode, Object operand)(Code)
Constructor.
Parameters:
  opcode - The opcode class of the instruction.
Parameters:
  operand - The operand of the instruction, or null.



Instruction
public Instruction(byte[] code, int index, int[] targets, int[] lookups, LocalVariable[] locals, ConstantPool constants)(Code)
Constructor.
Parameters:
  code - The raw byte code array of the method.
Parameters:
  index - This index into the byte array of the instruction.
Parameters:
  targets - Indices of the branch targets of the instruction.
Parameters:
  lookups - Values of the switch lookups of the instruction.
Parameters:
  locals - The local variables defined at this index.
Parameters:
  constants - The constant pool for the class.




Method Detail
category
public int category()(Code)
Returns the category of this instruction. An instruction's category is basically the width of the value the instruction places on the stack. Types long and double are Category 2. All other types are Category 1.



isConditionalJump
public boolean isConditionalJump()(Code)
Check if the instruction is a conditional jump. true if the instruction is a conditional jump, false if not.



isGoto
public boolean isGoto()(Code)
Check if the instruction is a goto. true if the instruction is a goto, false if not.



isInc
public boolean isInc()(Code)
Check if the instruction is an increment. true if the instruction is an increment, false if not.



isInvoke
public boolean isInvoke()(Code)
Returns true if this instruction invokes a method.



isJsr
public boolean isJsr()(Code)
Check if the instruction is a jsr. true if the instruction is a jsr, false if not.



isJump
public boolean isJump()(Code)
Check if the instruction is a jump. true if the instruction is a jump, false if not.



isLoad
public boolean isLoad()(Code)
Check if the instruction is a load. true if the instruction is a load, false if not.



isRet
public boolean isRet()(Code)
Check if the instruction is a subroutine return instruction. true if the instruction is a ret, false if not.



isReturn
public boolean isReturn()(Code)
Returns true if the instruction returns from a method.



isStore
public boolean isStore()(Code)
Check if the instruction is a store. true if the instruction is a store, false if not.



isSwitch
public boolean isSwitch()(Code)
Check if the instruction is a switch. true if the instruction is a switch, false if not.



isThrow
public boolean isThrow()(Code)
Check if the instruction is an exception throw instruction. true if the instruction is a throw, false if not.



opcodeClass
public int opcodeClass()(Code)
Get the opcode class of the instruction. The opcode class of the instruction.



operand
public Object operand()(Code)
Get the operand of the instruction. The operand of the instruction.



origOpcode
public int origOpcode()(Code)
Returns the original (non-mapped) opcode used to create this Instruction.



setOpcodeClass
public void setOpcodeClass(int opcode)(Code)
Set the opcode class of the instruction.
Parameters:
  opcode - The opcode class of the instruction.



setOperand
public void setOperand(Object operand)(Code)
Set the operand of the instruction.
Parameters:
  operand - The operand of the instruction.



setUseSlow
public void setUseSlow(boolean useSlow)(Code)
Sets a flag that determines whether or not the "slow" version of the instruction should be generated. For example, if useSlow is true, "iload 2" is generated instead of "iload_2".



toInt
protected static int toInt(byte b1, byte b2, byte b3, byte b4)(Code)
Utility function to join 4 bytes into an signed int.
Parameters:
  b1 - The upper byte.
Parameters:
  b2 - The next-to-upper byte.
Parameters:
  b3 - The next-to-lower byte.
Parameters:
  b4 - The lower byte. The signed int.



toShort
protected static short toShort(byte b1, byte b2)(Code)
Utility function to join 2 bytes into an signed short.
Parameters:
  b1 - The upper byte.
Parameters:
  b2 - The lower byte. The signed short.



toString
public String toString()(Code)
Convert the instruction to a string. A string representation of the instruction.



toUByte
protected static int toUByte(byte b)(Code)
Utility function to convert a byte into an unsigned byte.
Parameters:
  b - The byte. The unsigned byte.



toUShort
protected static int toUShort(byte b1, byte b2)(Code)
Utility function to join 2 bytes into an unsigned short.
Parameters:
  b1 - The upper byte.
Parameters:
  b2 - The lower byte. The unsigned short.



useSlow
public boolean useSlow()(Code)
Returns whether or not the "slow" version of this instruction is generated.



visit
public void visit(InstructionVisitor visitor)(Code)
Big switch statement to call the appropriate method of an instruction visitor.
Parameters:
  visitor - The instruction visitor.



Methods inherited from java.lang.Object
native protected Object clone() throws CloneNotSupportedException(Code)(Java Doc)
public boolean equals(Object obj)(Code)(Java Doc)
protected void finalize() throws Throwable(Code)(Java Doc)
final native public Class getClass()(Code)(Java Doc)
native public int hashCode()(Code)(Java Doc)
final native public void notify()(Code)(Java Doc)
final native public void notifyAll()(Code)(Java Doc)
public String toString()(Code)(Java Doc)
final native public void wait(long timeout) throws InterruptedException(Code)(Java Doc)
final public void wait(long timeout, int nanos) throws InterruptedException(Code)(Java Doc)
final public void wait() throws InterruptedException(Code)(Java Doc)

www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.