org.mozilla.javascript.optimizer
Class OptLocalVariable

java.lang.Object
  |
  +--org.mozilla.javascript.LocalVariable
        |
        +--org.mozilla.javascript.optimizer.OptLocalVariable

public class OptLocalVariable
extends LocalVariable


Constructor Summary
OptLocalVariable(java.lang.String name, boolean isParameter)
           
 
Method Summary
 void assignJRegister(short aJReg)
           
 boolean assignType(int aType)
           
 void clearLiveAcrossCall()
           
 short getJRegister()
          Return the Java register number or -1 if it is not a Java register.
 int getStartPC()
          Get the offset into the bytecode where the variable becomes live.
 int getTypeUnion()
           
 boolean isLiveAcrossCall()
           
 boolean isNumber()
          Return true if the local variable is a Java register with double type.
 void markLiveAcrossCall()
           
 void setIsNumber()
           
 void setStartPC(int pc)
          Set the offset into the bytecode where the variable becomes live.
 java.lang.String toString()
           
 
Methods inherited from class org.mozilla.javascript.LocalVariable
getIndex, getName, isParameter, setIndex, setIsParameter
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

OptLocalVariable

public OptLocalVariable(java.lang.String name,
                        boolean isParameter)
Method Detail

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

setIsNumber

public void setIsNumber()

isNumber

public boolean isNumber()
Description copied from class: LocalVariable
Return true if the local variable is a Java register with double type.
Overrides:
isNumber in class LocalVariable

markLiveAcrossCall

public void markLiveAcrossCall()

clearLiveAcrossCall

public void clearLiveAcrossCall()

isLiveAcrossCall

public boolean isLiveAcrossCall()

assignJRegister

public void assignJRegister(short aJReg)

getJRegister

public short getJRegister()
Description copied from class: LocalVariable
Return the Java register number or -1 if it is not a Java register.
Overrides:
getJRegister in class LocalVariable

assignType

public boolean assignType(int aType)

getTypeUnion

public int getTypeUnion()

getStartPC

public int getStartPC()
Get the offset into the bytecode where the variable becomes live. Used for generating the local variable table.
Overrides:
getStartPC in class LocalVariable

setStartPC

public void setStartPC(int pc)
Set the offset into the bytecode where the variable becomes live. Used for generating the local variable table.