All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class com.arcsinc.hardwarehost.coff.ExtVariableSpec

java.lang.Object
   |
   +----com.arcsinc.hardwarehost.coff.ExtVariableSpec

public class ExtVariableSpec
extends Object
implements Serializable, Cloneable
The ExtVariableSpec class provides a description of symbols within a COFF file. All symbols have a name and a module. For example, if the following line appears in the source file foo.c: int bar; the symbol name is _bar and the module name is either foo.c or foo.asm (the particular name depends on compilation options; within AIDE, it will be xxx.c). This class also contains typing and location information for the symbol.

he symbol.

See Also:
SymbolParams

Constructor Index

 o ExtVariableSpec()
 o ExtVariableSpec(ExtVariableSpec)
This is the copy constructor.
 o ExtVariableSpec(String, String, byte, byte)
This is a constructor with the value and offset unknown or not applicable.
 o ExtVariableSpec(String, String, byte, byte, Number)
This is a constructor with the offset unknown or not applicable.
 o ExtVariableSpec(String, String, byte, byte, Number, int)
This is a constructor.

Method Index

 o clone()
This function supports the Cloneable interface
 o getAddress()
Get the value of address.
 o getBasicType()
Get the value of basicTyp the value of basicType.
 o getBasicType(Vector, String, String)
This is a static accessor method which accepts a Vector of ExtVariableSpec, the symbol's name and module.
 o getDerivedType()
Get the value of derivedType.
 o getDerivedType(Vector, String, String)
This is a static accessor method which accepts a Vector of ExtVariableSpec, the symbol's name and module.
 o getIndex(Vector, String, String)
This is a static accessor method which accepts a Vector of ExtVariableSpec, the symbol's name and module.
 o getModule()
Get the value of module.
 o ght=6 alt=" o "> getName()
Get the value of name.
 o getOffset()
Get the value of offset.
 o getValue()
Get the value of value.
 o isBasicType(Vector, String, String)
This is a static accessor method which accepts a Vector of ExtVariableSpec, the symbol's name and module.
 o isSymbolArray()
Determines whether or not this symbol is of array (DT_ARY) type.
 o isSymbolPointer()
Determines whether or not this symbol is of pointer (DT_PTR) type.
 o setAddress(int)
Set the value of address.
 o setBasicTypeb>setBasicType(byte)
Set the value of basicType.
 o setDerivedType(byte)
Set the value of derivedType.
 o setOffset(int)
Set the value of offset.
 o setValue(Number)
Set the value of value.

Constructors

 o ExtVariableSpec
 public ExtVariableSpec()
 o ExtVariableSpec
 public ExtVariableSpec(ExtVariableSpec a)
This is the copy constructor.

Parameters:
a - the ExtVariableSpec to copy.
 o ExtVariableSpec =" o "> ExtVariableSpec
 public ExtVariableSpec(String name,
                        String module,
                        byte basicType,
                        byte derivedType)
This is a constructor with the value and offset unknown or not applicable.

Parameteb>Parameters:
name - the symbol name.
module - the symbol module.
basicType - the symbol basicType, e.g. T_INT
derivedType - the symbol derivedType, e.g. DT_NON
 o ExtVariableSpec
 public ExtVariableSpec(String name,
                        String module,
                        byte basicType,
                        byte derivedType,
                        Number value)
This is a constructor with the offset unknown or not applicable.

Parameters:
name - the symbol name.
module - the symbol module.
basicType - the symbol basicType, e.g. T_INT
derivedType - the symbol derivedType, e.g. DT_NON
value - the current value of the symbol in the application
 o ExtVariableSpec
 public ExtVariableSpec(String name,
                        String module,
                        byte basicType,
                        byte derivedType,
                        Number value,
                        int offset)

This is a constructor.

Parameters:
name - the symbol name.
module - the symbol module.
basicType - the symbol basicType, e.g. T_INT
derivedType - the symbol derivedType, e.g. DT_ARY
value - the current value of the symbol in the application
offset - the offset for the symbol, int a[5]; a[3], offset is 3

Methods

 o isBasicType
 public static boolean isBasicType(Vector vec,
                                   String name,
                                   String module)
This is a static accessor method which accepts a Vector of ExtVariableSpec, the symbol's name and module. It returns true if the symbol is DT_NON type. For example, the corresponding symbol entry for "int foo;" returns true; however, int* bar; returns false.

Parameters:
vec - a Vector of ExtVariableSpec
name - the symbol name (standard notation prepends "_" to the name.
module - the module name in which the symbol is defined.
Returns:
a boolean, true if the symbol is a basic type.
 o getBasicType
 public static byte getBasicType(Vector vec,
                                 String name,
                                 String module)
This is a static accessor method which accepts a Vector of ExtVariabl of ExtVariableSpec, the symbol's name and module. It returns the basic type for the symbol (void, int, float, etc.).

Parameters:
vec - a Vector of ExtVariableSpec
name - the symbol name (standard notation prepends "_" to the name.
module - the module name in which the symbol is defined.
Returns:
a byte representing the basic type as defined in SymbolParams
 o getDerivedType
 public static int getDerivedType(Vector vec,
                                  String name,
                                  String module)
This is a static accessor method which accepts a Vector of ExtVariableSpec, the symbol's name and module. It returns the derived type for the symbol (none, pointer, array, or function).

Parameters:
vec - a Vector of ExtVariableSpec
name - the symbol name (standard notation prepends "_" to the name.
module - the module name in which the symbol is defined.
Returns:
a byte representing the derived type as defined in SymbolParams
 o getIndex
 public static int getIndex(Vector vec,
                            String name,
                            String module)
This is a static accessor method which accepts a Vector of ExtVariableSpec, the symbol's name and module. It returns the index for the symbol in the Vector.

Parameters:
Parameters:
vec - a Vector of ExtVariableSpec
name - the symbol name (standard notation prepends "_" to the name.
module - the module name in which the symbol is defined.
Returns:
an integer with the index into the Vector, -1 if the symbol is not found.
 o clone
 public Object clone()
This function supports the Cloneable interface

p>
Returns:
an Object which is cloned.
Overrides:
clone in class Object
 o getAddress
 public int getAddress()
Get the value of address.

Returns:
Value of address.
 o setAddress
 public void setAddress(int v)
Set the value of address.

Parameters:
v - Value to assign to address.
 o getOffset
 public int getOffset()
Get the value of offset.

Returns:
Value of offset.
 o setOffset
 public void setOffset(int v)
Set the value of offset.

Parameters:
v - Value to assign to offset.
 o getName
 public String getName()
Get the value of name.

Returns:
Value of name.
 o getModule
 public String getModule()
Get the value of module.

Returns:
Value of module.
 o getBasicType
 public byte getBasicType()
Get the value of basicType.

Returns:
Value of basicType.
 o setBasicType
 public void setBasicType(byte v)
Set the value of basicType.

Parameters:
v - Value to assign to basicType.
 o getDerivedType
 public byte getDerivedType()
Get the value of derivedType.

Returns:
Value of derivedType.
 o setDerivedType
 public void setDerivedType(byte v)
Set the value of derivedType.

Parameters:
v - Value to assign to derivedType.
 o h=12 height=12 alt=" o "> getValue
 public Number getValue()
Get the value of value.

Returns:
Value of value.
 o setValue
 public void setValue(Number v)
Set the value of value.

Parameters:
v - Value to assign to value.
 o isSymbolArray
 public boolean isSymbolArray()
Determines whether or not this symbol is of array (DT_ARY) type.

Returns:
true if symbol is of array type
 o isSymbolPointer
 public boolean isSymbolPointer()
Determines whether or not this symbol is of pointer (DT_PTR) type.

Returns:
true if symbol is of array type

All Packages  Class Hierarchy  This Package  Previous  Next  Index
x