Package ghidra.trace.database.address
Class DBTraceOverlaySpaceAdapter.AddressDBFieldCodec<OT extends DBAnnotatedObject & DBTraceOverlaySpaceAdapter.DecodesAddresses>
java.lang.Object
ghidra.util.database.DBCachedObjectStoreFactory.AbstractDBFieldCodec<Address,OT,FixedField10>
ghidra.trace.database.address.DBTraceOverlaySpaceAdapter.AddressDBFieldCodec<OT>
- Type Parameters:
OT- the type of object containing the field
- All Implemented Interfaces:
DBCachedObjectStoreFactory.DBFieldCodec<Address,OT, FixedField10>
- Enclosing class:
DBTraceOverlaySpaceAdapter
public static class DBTraceOverlaySpaceAdapter.AddressDBFieldCodec<OT extends DBAnnotatedObject & DBTraceOverlaySpaceAdapter.DecodesAddresses>
extends DBCachedObjectStoreFactory.AbstractDBFieldCodec<Address,OT,FixedField10>
Used for objects having an
Address field.
Most managers storing things by address will actually have a table per space, so the address
is encoded only as an offset. However, any other Address field (not constrained to
the same space) will need to encode the space information as well. This codec can do that.
The object will need to return its trace's space adapter, though.
-
Field Summary
Fields inherited from class ghidra.util.database.DBCachedObjectStoreFactory.AbstractDBFieldCodec
column, field, fieldType, objectType, valueType -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic Addressdecode(byte[] enc, DBTraceOverlaySpaceAdapter osa) protected voidSame asDBCachedObjectStoreFactory.AbstractDBFieldCodec.load(DBAnnotatedObject, DBRecord), but permits exceptionsprotected voidSame asDBCachedObjectStoreFactory.AbstractDBFieldCodec.store(DBAnnotatedObject, DBRecord), but permits exceptionsstatic byte[]voidstore(Address value, FixedField10 f) Encode the given field value into the given fieldMethods inherited from class ghidra.util.database.DBCachedObjectStoreFactory.AbstractDBFieldCodec
getFieldType, getObjectType, getValue, getValueType, load, setValue, storeMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface ghidra.util.database.DBCachedObjectStoreFactory.DBFieldCodec
encodeField
-
Constructor Details
-
AddressDBFieldCodec
-
-
Method Details
-
encode
-
decode
-
store
Description copied from interface:DBCachedObjectStoreFactory.DBFieldCodecEncode the given field value into the given field- Parameters:
value- the valuef- the field
-
doStore
protected void doStore(OT obj, DBRecord record) throws IllegalArgumentException, IllegalAccessException Description copied from class:DBCachedObjectStoreFactory.AbstractDBFieldCodecSame asDBCachedObjectStoreFactory.AbstractDBFieldCodec.store(DBAnnotatedObject, DBRecord), but permits exceptions- Specified by:
doStorein classDBCachedObjectStoreFactory.AbstractDBFieldCodec<Address,OT extends DBAnnotatedObject & DBTraceOverlaySpaceAdapter.DecodesAddresses, FixedField10> - Throws:
IllegalArgumentExceptionIllegalAccessException
-
doLoad
protected void doLoad(OT obj, DBRecord record) throws IllegalArgumentException, IllegalAccessException Description copied from class:DBCachedObjectStoreFactory.AbstractDBFieldCodecSame asDBCachedObjectStoreFactory.AbstractDBFieldCodec.load(DBAnnotatedObject, DBRecord), but permits exceptions- Specified by:
doLoadin classDBCachedObjectStoreFactory.AbstractDBFieldCodec<Address,OT extends DBAnnotatedObject & DBTraceOverlaySpaceAdapter.DecodesAddresses, FixedField10> - Throws:
IllegalArgumentExceptionIllegalAccessException
-