public class FieldsScanner extends Object
| Modifier and Type | Class and Description |
|---|---|
static interface |
FieldsScanner.CalcOffset
Determines the offset (in bytes) of a field.
|
static class |
FieldsScanner.DefaultCalcOffset
Determines the offset (in bytes) of a field using
Unsafe.objectFieldOffset(Field). |
static class |
FieldsScanner.FieldInfo
Describes a field in a class during scanning.
|
| Modifier and Type | Field and Description |
|---|---|
ArrayList<FieldsScanner.FieldInfo> |
data
Fields not belonging to a more specific category defined by scanner subclasses are added to
this list.
|
| Constructor and Description |
|---|
FieldsScanner(FieldsScanner.CalcOffset calc) |
| Modifier and Type | Method and Description |
|---|---|
void |
scan(Class<?> clazz,
Class<?> endClazz,
boolean includeTransient)
Scans the fields in a class hierarchy.
|
protected void |
scanField(Field field,
long offset) |
public final ArrayList<FieldsScanner.FieldInfo> data
public FieldsScanner(FieldsScanner.CalcOffset calc)
public void scan(Class<?> clazz, Class<?> endClazz, boolean includeTransient)
clazz - the class at which to start scanningendClazz - scanning stops when this class is encountered (i.e. endClazz is not
scanned)protected void scanField(Field field, long offset)