gnu.kawa.reflect

Class FieldLocation

Known Direct Subclasses:
StaticFieldLocation

public class FieldLocation
extends ClassMemberLocation

Field Summary

static int
KIND_FLAGS_SET
True if the flags PROCEDURE|SYNTAX|INDIRECT_LOCATION|CONSTANT are valid.
static int
PROCEDURE
static int
SYNTAX

Fields inherited from class gnu.mapping.Location

UNBOUND

Constructor Summary

FieldLocation(Object instance, String cname, String fname)
FieldLocation(Object instance, ClassType type, String mname)

Method Summary

Object
get(Object defaultValue)
Declaration
getDeclaration()
Type
getFType()
Get the type of the field.
Field
getField()
boolean
isBound()
boolean
isConstant()
boolean
isIndirectLocation()
boolean
isProcedureOrSyntax()
static FieldLocation
make(Object instance, String cname, String fldName)
static FieldLocation
make(Object instance, Declaration decl)
void
set(Object newValue)
void
setDeclaration(Declaration decl)
void
setProcedure()
void
setSyntax()
String
toString()

Methods inherited from class gnu.kawa.reflect.ClassMemberLocation

define, defineAll, get, getDeclaringClass, getInstance, getMemberName, getRField, isBound, isConstant, set, setInstance

Methods inherited from class gnu.mapping.Location

entered, get, get, getBase, getKeyProperty, getKeySymbol, getValue, isBound, isConstant, make, make, make, print, set, setRestore, setValue, setWithSave, toString, undefine

Field Details

KIND_FLAGS_SET

public static final int KIND_FLAGS_SET
True if the flags PROCEDURE|SYNTAX|INDIRECT_LOCATION|CONSTANT are valid.
Field Value:
64

PROCEDURE

public static final int PROCEDURE
Field Value:
16

SYNTAX

public static final int SYNTAX
Field Value:
32

Constructor Details

FieldLocation

public FieldLocation(Object instance,
                     String cname,
                     String fname)

FieldLocation

public FieldLocation(Object instance,
                     ClassType type,
                     String mname)

Method Details

get

public Object get(Object defaultValue)
Overrides:
get in interface ClassMemberLocation

getDeclaration

public Declaration getDeclaration()

getFType

public Type getFType()
Get the type of the field.

getField

public Field getField()

isBound

public boolean isBound()
Overrides:
isBound in interface ClassMemberLocation

isConstant

public boolean isConstant()
Overrides:
isConstant in interface ClassMemberLocation

isIndirectLocation

public boolean isIndirectLocation()

isProcedureOrSyntax

public boolean isProcedureOrSyntax()

make

public static FieldLocation make(Object instance,
                                 String cname,
                                 String fldName)

make

public static FieldLocation make(Object instance,
                                 Declaration decl)

set

public void set(Object newValue)
Overrides:
set in interface ClassMemberLocation

setDeclaration

public void setDeclaration(Declaration decl)

setProcedure

public void setProcedure()

setSyntax

public void setSyntax()

toString

public String toString()
Overrides:
toString in interface Location