mirror of
https://github.com/NationalSecurityAgency/ghidra
synced 2024-09-19 18:21:26 +00:00
spelling fixes
This commit is contained in:
parent
5e5b0790ad
commit
0248c4f1ba
|
@ -751,7 +751,7 @@ public class DataTypeMergeManager implements MergeResolver {
|
|||
/**
|
||||
* Set category path. If name conflict occurs within new category
|
||||
* the specified dt will remain within its current category
|
||||
* @param dt datatype whoose category is to changed
|
||||
* @param dt datatype whose category is to changed
|
||||
* @param newPath new category path
|
||||
*/
|
||||
private void setCategoryPath(DataType dt, CategoryPath newPath) {
|
||||
|
@ -2222,7 +2222,8 @@ public class DataTypeMergeManager implements MergeResolver {
|
|||
UniversalID resultDtUniversalID = resultDt.getUniversalID();
|
||||
UniversalID myDtUniversalID = myDt.getUniversalID();
|
||||
// UniversalID can be null if data type is BuiltIn.
|
||||
if (!resultSourceArchive.getSourceArchiveID().equals(
|
||||
if (!resultSourceArchive.getSourceArchiveID()
|
||||
.equals(
|
||||
mySourceArchive.getSourceArchiveID()) ||
|
||||
!Objects.equals(resultDtUniversalID, myDtUniversalID)) {
|
||||
return false;
|
||||
|
@ -2237,7 +2238,7 @@ public class DataTypeMergeManager implements MergeResolver {
|
|||
|
||||
private void cleanUpDataTypes() {
|
||||
// clean up data types
|
||||
List<Long> keys = new ArrayList<Long>(cleanupPlaceHolderList.keySet());
|
||||
List<Long> keys = new ArrayList<>(cleanupPlaceHolderList.keySet());
|
||||
for (long key : keys) {
|
||||
CleanUpInfo cleanUpInfo = cleanupPlaceHolderList.get(key);
|
||||
cleanUpInfo.cleanUp();
|
||||
|
@ -2649,11 +2650,6 @@ public class DataTypeMergeManager implements MergeResolver {
|
|||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @param compID
|
||||
* @param dataTypeManager
|
||||
* @return
|
||||
*/
|
||||
private DataType resolve(long id, DataTypeManager dtm,
|
||||
Map<Long, DataType> resolvedDataTypes) {
|
||||
DataType dt = getResolvedComponent(id, resolvedDataTypes);
|
||||
|
@ -2945,7 +2941,7 @@ public class DataTypeMergeManager implements MergeResolver {
|
|||
/**
|
||||
* Processes my data types that were added and determines whether each is actually a
|
||||
* conflict, an added data type, or a changed data type relative to the Latest check in.
|
||||
* @param myDtAdds
|
||||
* @param myDtAdds the data type IDs
|
||||
*/
|
||||
private void processAddIDs(long[] myDtAdds) {
|
||||
myDtAddedList = new ArrayList<>();
|
||||
|
|
|
@ -28,15 +28,16 @@ public class DatabaseUtils {
|
|||
/**
|
||||
* Reassign the long key assigned to a contiguous group of records within a table.
|
||||
* A shift in the key value is computed as the difference of oldStart and newStart.
|
||||
* Existing records whoose keys lie within the new range will be removed prior to
|
||||
* Existing records whose keys lie within the new range will be removed prior to
|
||||
* moving the target set of records.
|
||||
* @param table table within which records should be moved.
|
||||
* @param oldStart old key value for start of range
|
||||
* @param newStart new key value for start of range
|
||||
* @param size determines the range of keys to be moved (oldStart to oldStart+size-1, inclusive)
|
||||
* @throws IOException
|
||||
* @throws IOException if there is an error moving the records
|
||||
*/
|
||||
public static void moveRecords(Table table, long oldStart, long newStart, long size) throws IOException{
|
||||
public static void moveRecords(Table table, long oldStart, long newStart, long size)
|
||||
throws IOException {
|
||||
if (oldStart == newStart) {
|
||||
return;
|
||||
}
|
||||
|
@ -47,7 +48,6 @@ public class DatabaseUtils {
|
|||
throw new IllegalArgumentException("Illegal range: end range overflow");
|
||||
}
|
||||
|
||||
|
||||
DBHandle tmp = new DBHandle();
|
||||
Table tmpTable = tmp.createTable("tmp", table.getSchema());
|
||||
long txID = tmp.startTransaction();
|
||||
|
|
|
@ -20,7 +20,7 @@ import java.util.ArrayList;
|
|||
import java.util.NoSuchElementException;
|
||||
|
||||
/**
|
||||
* <code>FieldIndexTable</code> provides a simplified index table whoose key is
|
||||
* <code>FieldIndexTable</code> provides a simplified index table whose key is
|
||||
* a fixed or variable length {@link IndexField} which consists of a concatenation of
|
||||
* the index field value and associated primary table key.
|
||||
*/
|
||||
|
@ -40,7 +40,9 @@ public class FieldIndexTable extends IndexTable {
|
|||
* @throws IOException thrown if IO error occurs
|
||||
*/
|
||||
FieldIndexTable(Table primaryTable, int colIndex) throws IOException {
|
||||
this(primaryTable, primaryTable.getDBHandle().getMasterTable().createTableRecord(
|
||||
this(primaryTable, primaryTable.getDBHandle()
|
||||
.getMasterTable()
|
||||
.createTableRecord(
|
||||
primaryTable.getName(), getIndexTableSchema(primaryTable, colIndex), colIndex));
|
||||
}
|
||||
|
||||
|
|
|
@ -448,7 +448,7 @@ abstract class LongKeyRecordNode extends LongKeyNode implements RecordNode {
|
|||
abstract DBRecord getRecord(Schema schema, int index) throws IOException;
|
||||
|
||||
/**
|
||||
* Get the first record whoose key is less than the specified key.
|
||||
* Get the first record whose key is less than the specified key.
|
||||
* @param key record key
|
||||
* @param schema record data schema
|
||||
* @return Record requested or null if record not found.
|
||||
|
@ -470,7 +470,7 @@ abstract class LongKeyRecordNode extends LongKeyNode implements RecordNode {
|
|||
}
|
||||
|
||||
/**
|
||||
* Get the first record whoose key is greater than the specified key.
|
||||
* Get the first record whose key is greater than the specified key.
|
||||
* @param key record key
|
||||
* @param schema record data schema
|
||||
* @return Record requested or null if record not found.
|
||||
|
@ -492,7 +492,7 @@ abstract class LongKeyRecordNode extends LongKeyNode implements RecordNode {
|
|||
}
|
||||
|
||||
/**
|
||||
* Get the first record whoose key is less than or equal to the specified
|
||||
* Get the first record whose key is less than or equal to the specified
|
||||
* key.
|
||||
* @param key record key
|
||||
* @param schema record data schema
|
||||
|
@ -512,7 +512,7 @@ abstract class LongKeyRecordNode extends LongKeyNode implements RecordNode {
|
|||
}
|
||||
|
||||
/**
|
||||
* Get the first record whoose key is greater than or equal to the specified
|
||||
* Get the first record whose key is greater than or equal to the specified
|
||||
* key.
|
||||
* @param key record key
|
||||
* @param schema record data schema
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
/* ###
|
||||
* IP: GHIDRA
|
||||
* REVIEWED: YES
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
|
@ -16,14 +15,14 @@
|
|||
*/
|
||||
package db.buffers;
|
||||
|
||||
import ghidra.util.datastruct.IntIntHashtable;
|
||||
import ghidra.util.exception.AssertException;
|
||||
import ghidra.util.exception.NoValueException;
|
||||
|
||||
import java.io.File;
|
||||
import java.io.IOException;
|
||||
import java.util.*;
|
||||
|
||||
import ghidra.util.datastruct.IntIntHashtable;
|
||||
import ghidra.util.exception.AssertException;
|
||||
import ghidra.util.exception.NoValueException;
|
||||
|
||||
/**
|
||||
* <code>VersionFile</code> records buffer changes and parameters necessary to reconstruct an
|
||||
* older version of a LocalBufferFile.
|
||||
|
@ -44,7 +43,8 @@ class RecoveryFile {
|
|||
private static final String TIMESTAMP_HI_PARM = RECOVERY_PARM_PREFIX + "TimestampHi";
|
||||
private static final String TIMESTAMP_LOW_PARM = RECOVERY_PARM_PREFIX + "TimestampLow";
|
||||
private static final String MAP_BUFFER_INDEX_PARM = RECOVERY_PARM_PREFIX + "MapIndex";
|
||||
private static final String FREE_LIST_BUFFER_INDEX_PARM = RECOVERY_PARM_PREFIX + "FreeListIndex";
|
||||
private static final String FREE_LIST_BUFFER_INDEX_PARM =
|
||||
RECOVERY_PARM_PREFIX + "FreeListIndex";
|
||||
private static final String FREE_LIST_SIZE_PARM = RECOVERY_PARM_PREFIX + "FreeListSize";
|
||||
private static final String INDEX_COUNT_PARM = RECOVERY_PARM_PREFIX + "BufferCount";
|
||||
|
||||
|
@ -77,7 +77,8 @@ class RecoveryFile {
|
|||
* Construct a new recovery file for update/output.
|
||||
* @param srcBf the original source buffer file to which this file applies.
|
||||
* @param rfile version buffer file to be updated/created
|
||||
* @throws IOException if vfile already exists or an IO error occurs
|
||||
* @param create true to create the file
|
||||
* @throws IOException if the file already exists or an IO error occurs
|
||||
*/
|
||||
RecoveryFile(LocalBufferFile srcBf, File rfile, boolean create) throws IOException {
|
||||
|
||||
|
@ -94,7 +95,7 @@ class RecoveryFile {
|
|||
// Mark as invalid
|
||||
recoveryFile.setParameter(IS_VALID_PARM, INVALID);
|
||||
|
||||
// Save original and source file ID as user paramater values
|
||||
// Save original and source file ID as user parameter values
|
||||
srcFileId = srcBf.getFileId();
|
||||
recoveryFile.setParameter(SRC_FILE_ID_HI_PARM, (int) (srcFileId >>> 32));
|
||||
recoveryFile.setParameter(SRC_FILE_ID_LOW_PARM, (int) (srcFileId & 0xffffffffL));
|
||||
|
@ -117,7 +118,8 @@ class RecoveryFile {
|
|||
throw new IOException("Recovery file not associated with source file");
|
||||
}
|
||||
|
||||
vfIndexProvider = new IndexProvider(recoveryFile.getIndexCount(), recoveryFile.getFreeIndexes());
|
||||
vfIndexProvider =
|
||||
new IndexProvider(recoveryFile.getIndexCount(), recoveryFile.getFreeIndexes());
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -126,14 +128,14 @@ class RecoveryFile {
|
|||
* Construct a read-only recovery file
|
||||
* @param srcBf the original source buffer file to which this file applies.
|
||||
* @param rfile version buffer file to be updated/created
|
||||
* @throws IOException
|
||||
* @throws IOException if vfile already exists or an IO error occurs
|
||||
* @throws IOException if the file already exists or an IO error occurs
|
||||
*/
|
||||
RecoveryFile(LocalBufferFile srcBf, File rfile) throws IOException {
|
||||
recoveryFile = new LocalBufferFile(rfile, true);
|
||||
readOnly = true;
|
||||
parseFile();
|
||||
valid = (recoveryFile.getParameter(IS_VALID_PARM) == VALID && srcFileId == srcBf.getFileId());
|
||||
valid =
|
||||
(recoveryFile.getParameter(IS_VALID_PARM) == VALID && srcFileId == srcBf.getFileId());
|
||||
}
|
||||
|
||||
private void setModified() {
|
||||
|
@ -156,13 +158,11 @@ class RecoveryFile {
|
|||
return timestamp;
|
||||
}
|
||||
|
||||
/**
|
||||
* Close the version file.
|
||||
*/
|
||||
void close() throws IOException {
|
||||
|
||||
if (recoveryFile == null)
|
||||
if (recoveryFile == null) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (!readOnly && modified && !recoveryFile.isReadOnly()) {
|
||||
saveBufferMap();
|
||||
|
@ -190,7 +190,8 @@ class RecoveryFile {
|
|||
try {
|
||||
timestamp = ((long) recoveryFile.getParameter(TIMESTAMP_HI_PARM) << 32) |
|
||||
(recoveryFile.getParameter(TIMESTAMP_LOW_PARM) & 0xffffffffL);
|
||||
} catch (NoSuchElementException e) {
|
||||
}
|
||||
catch (NoSuchElementException e) {
|
||||
// Not as good - better than nothing
|
||||
timestamp = recoveryFile.getFile().lastModified();
|
||||
}
|
||||
|
@ -204,7 +205,8 @@ class RecoveryFile {
|
|||
|
||||
readFreeIndexList();
|
||||
|
||||
} catch (NoSuchElementException e) {
|
||||
}
|
||||
catch (NoSuchElementException e) {
|
||||
throw new IOException("Corrupt recovery file");
|
||||
}
|
||||
|
||||
|
@ -264,7 +266,8 @@ class RecoveryFile {
|
|||
try {
|
||||
offset = buf.putInt(offset, realIndexes[i]);
|
||||
offset = buf.putInt(offset, bufferIndexMap.get(realIndexes[i]));
|
||||
} catch (NoValueException e) {
|
||||
}
|
||||
catch (NoValueException e) {
|
||||
throw new AssertException();
|
||||
}
|
||||
}
|
||||
|
@ -414,18 +417,19 @@ class RecoveryFile {
|
|||
|
||||
/**
|
||||
* Set the current index count for the file
|
||||
* @param newIndexCnt
|
||||
* @param newIndexCount the count
|
||||
*/
|
||||
void setIndexCount(int newIndexCnt) {
|
||||
void setIndexCount(int newIndexCount) {
|
||||
setModified();
|
||||
for (int index = indexCnt; index < newIndexCnt; index++) {
|
||||
for (int index = indexCnt; index < newIndexCount; index++) {
|
||||
removeBuffer(index);
|
||||
}
|
||||
indexCnt = newIndexCnt;
|
||||
indexCnt = newIndexCount;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the index count for the file
|
||||
* @return the count
|
||||
*/
|
||||
int getIndexCount() {
|
||||
return indexCnt;
|
||||
|
@ -433,20 +437,20 @@ class RecoveryFile {
|
|||
|
||||
/**
|
||||
* Set the free index list
|
||||
* @param freeIndexes
|
||||
* @param freeIndexes the indexes
|
||||
*/
|
||||
void setFreeIndexList(int[] freeIndexes) {
|
||||
setModified();
|
||||
this.freeIndexes = freeIndexes.clone();
|
||||
Arrays.sort(this.freeIndexes);
|
||||
for (int i = 0; i < freeIndexes.length; i++) {
|
||||
removeBuffer(freeIndexes[i]);
|
||||
for (int index : freeIndexes) {
|
||||
removeBuffer(index);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the list of free indexes associated with the original
|
||||
* buffer file.
|
||||
* Returns the list of free indexes associated with the original buffer file.
|
||||
* @return the indexes
|
||||
*/
|
||||
int[] getFreeIndexList() {
|
||||
return freeIndexes;
|
||||
|
@ -455,7 +459,6 @@ class RecoveryFile {
|
|||
/**
|
||||
* Store buffer which has been modified in the target.
|
||||
* @param buf modified buffer
|
||||
* @param id buffer ID
|
||||
* @throws IOException if an IO error occurs
|
||||
*/
|
||||
void putBuffer(DataBuffer buf) throws IOException {
|
||||
|
@ -470,7 +473,8 @@ class RecoveryFile {
|
|||
int id = buf.getId();
|
||||
try {
|
||||
vfIndex = bufferIndexMap.get(id);
|
||||
} catch (NoValueException e) {
|
||||
}
|
||||
catch (NoValueException e) {
|
||||
vfIndex = vfIndexProvider.allocateIndex();
|
||||
bufferIndexMap.put(id, vfIndex);
|
||||
}
|
||||
|
@ -480,7 +484,7 @@ class RecoveryFile {
|
|||
/**
|
||||
* Remove a buffer previously stored to the snapshot
|
||||
* by removing it from the map. It is OK to invoke
|
||||
* this method for an index whoose buffer was never
|
||||
* this method for an index whose buffer was never
|
||||
* put into this file.
|
||||
* @param id buffer ID
|
||||
*/
|
||||
|
@ -489,7 +493,9 @@ class RecoveryFile {
|
|||
try {
|
||||
int vfIndex = bufferIndexMap.remove(id);
|
||||
vfIndexProvider.freeIndex(vfIndex);
|
||||
} catch (NoValueException e) {
|
||||
}
|
||||
catch (NoValueException e) {
|
||||
// ignore?
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -508,7 +514,8 @@ class RecoveryFile {
|
|||
int vfIndex;
|
||||
try {
|
||||
vfIndex = bufferIndexMap.get(id);
|
||||
} catch (NoValueException e) {
|
||||
}
|
||||
catch (NoValueException e) {
|
||||
return null;
|
||||
}
|
||||
recoveryFile.get(buf, vfIndex);
|
||||
|
@ -518,6 +525,7 @@ class RecoveryFile {
|
|||
/**
|
||||
* Returns list of buffer indexes stored within this file.
|
||||
* These indexes reflect those buffers which have been modified and stored.
|
||||
* @return the indexes
|
||||
*/
|
||||
int[] getBufferIndexes() {
|
||||
return bufferIndexMap.getKeys();
|
||||
|
@ -525,24 +533,26 @@ class RecoveryFile {
|
|||
|
||||
/**
|
||||
* Returns file ID for original source buffer file which may be produced with this version file.
|
||||
* @return the id
|
||||
*/
|
||||
long getSourceFileID() {
|
||||
return srcFileId;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns a list of parameters defined within the original beffer file.
|
||||
* @throws IOException
|
||||
* Returns a list of parameters defined within the original buffer file.
|
||||
* @return the names
|
||||
* @throws IOException if the recovery file is null
|
||||
*/
|
||||
String[] getUserParameterNames() throws IOException {
|
||||
if (recoveryFile == null) {
|
||||
throw new IOException("Version file is closed");
|
||||
}
|
||||
String[] allNames = recoveryFile.getParameterNames();
|
||||
ArrayList<String> list = new ArrayList<String>();
|
||||
for (int i = 0; i < allNames.length; i++) {
|
||||
if (!allNames[i].startsWith(RECOVERY_PARM_PREFIX)) {
|
||||
list.add(allNames[i]);
|
||||
ArrayList<String> list = new ArrayList<>();
|
||||
for (String name : allNames) {
|
||||
if (!name.startsWith(RECOVERY_PARM_PREFIX)) {
|
||||
list.add(name);
|
||||
}
|
||||
}
|
||||
String[] names = new String[list.size()];
|
||||
|
@ -554,7 +564,7 @@ class RecoveryFile {
|
|||
* Get a parameter value associated with the original buffer file.
|
||||
* @param name parameter name
|
||||
* @return parameter value
|
||||
* @throws IOException
|
||||
* @throws IOException if the recovery file is null
|
||||
*/
|
||||
int getParameter(String name) throws IOException {
|
||||
if (recoveryFile == null) {
|
||||
|
@ -571,10 +581,10 @@ class RecoveryFile {
|
|||
|
||||
// Remember recovery parameters
|
||||
String[] allNames = recoveryFile.getParameterNames();
|
||||
Hashtable<String,Integer> recoveryProps = new Hashtable<String,Integer>();
|
||||
for (int i = 0; i < allNames.length; i++) {
|
||||
if (allNames[i].startsWith(RECOVERY_PARM_PREFIX)) {
|
||||
recoveryProps.put(allNames[i], new Integer(recoveryFile.getParameter(allNames[i])));
|
||||
Hashtable<String, Integer> recoveryProps = new Hashtable<>();
|
||||
for (String name : allNames) {
|
||||
if (name.startsWith(RECOVERY_PARM_PREFIX)) {
|
||||
recoveryProps.put(name, recoveryFile.getParameter(name));
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -592,8 +602,8 @@ class RecoveryFile {
|
|||
|
||||
/**
|
||||
* Set user parameter
|
||||
* @param name
|
||||
* @param value
|
||||
* @param name the name
|
||||
* @param value the value
|
||||
*/
|
||||
void setParameter(String name, int value) {
|
||||
setModified();
|
||||
|
|
|
@ -287,7 +287,7 @@ public class VersionedDatabase extends Database {
|
|||
/**
|
||||
* Open a specific version of this database for non-update use.
|
||||
* @param version database version or LATEST_VERSION for current version
|
||||
* @param minChangeDataVer the minimum database version whoose change data
|
||||
* @param minChangeDataVer the minimum database version whose change data
|
||||
* should be associated with the returned buffer file. A value of -1 indicates that
|
||||
* change data is not required.
|
||||
* @return buffer file for non-update use.
|
||||
|
|
|
@ -256,7 +256,7 @@ abstract class CompositeDBAdapter {
|
|||
abstract Field[] getRecordIdsForSourceArchive(long archiveID) throws IOException;
|
||||
|
||||
/**
|
||||
* Get composite record whoose sourceID and datatypeID match the specified Universal IDs.
|
||||
* Get composite record whose sourceID and datatypeID match the specified Universal IDs.
|
||||
* @param sourceID universal source archive ID
|
||||
* @param datatypeID universal datatype ID
|
||||
* @return composite record found or null
|
||||
|
|
|
@ -159,16 +159,17 @@ abstract class EnumDBAdapter {
|
|||
/**
|
||||
* Updates the enumeration data type table with the provided record.
|
||||
* @param record the new record
|
||||
* @param setLastChangedTime true means change the last change time in the record to the
|
||||
* @param setLastChangeTime true means change the last change time in the record to the
|
||||
* current time before putting the record in the database.
|
||||
* @throws IOException if the database can't be accessed.
|
||||
*/
|
||||
abstract void updateRecord(DBRecord record, boolean setLastChangeTime) throws IOException;
|
||||
|
||||
/**
|
||||
* Remove the record for the given enumeration ID, and remove all of its
|
||||
* associated value records.
|
||||
* Remove the record for the given enumeration ID, and remove all of its associated value
|
||||
* records.
|
||||
* @param enumID ID of enumerated data type to delete
|
||||
* @return true if successful
|
||||
* @throws IOException if there was a problem accessing the database
|
||||
*/
|
||||
abstract boolean removeRecord(long enumID) throws IOException;
|
||||
|
@ -198,7 +199,7 @@ abstract class EnumDBAdapter {
|
|||
abstract Field[] getRecordIdsForSourceArchive(long archiveID) throws IOException;
|
||||
|
||||
/**
|
||||
* Get enum record whoose sourceID and datatypeID match the specified Universal IDs.
|
||||
* Get enum record whose sourceID and datatypeID match the specified Universal IDs.
|
||||
* @param sourceID universal source archive ID
|
||||
* @param datatypeID universal datatype ID
|
||||
* @return enum record found or null
|
||||
|
|
|
@ -187,7 +187,7 @@ abstract class FunctionDefinitionDBAdapter {
|
|||
/**
|
||||
* Updates the function definition data type table with the provided record.
|
||||
* @param record the new record
|
||||
* @param setLastChangedTime true means change the last change time in the record to the
|
||||
* @param setLastChangeTime true means change the last change time in the record to the
|
||||
* current time before putting the record in the database.
|
||||
* @throws IOException if the database can't be accessed.
|
||||
*/
|
||||
|
@ -218,7 +218,7 @@ abstract class FunctionDefinitionDBAdapter {
|
|||
abstract Field[] getRecordIdsForSourceArchive(long archiveID) throws IOException;
|
||||
|
||||
/**
|
||||
* Get function definition record whoose sourceID and datatypeID match the specified Universal IDs.
|
||||
* Get function definition record whose sourceID and datatypeID match the specified Universal IDs.
|
||||
* @param sourceID universal source archive ID
|
||||
* @param datatypeID universal datatype ID
|
||||
* @return function definition record found or null
|
||||
|
|
|
@ -156,7 +156,7 @@ abstract class TypedefDBAdapter {
|
|||
/**
|
||||
* Updates the type definition data type table with the provided record.
|
||||
* @param record the new record
|
||||
* @param setLastChangedTime true means change the last change time in the record to the
|
||||
* @param setLastChangeTime true means change the last change time in the record to the
|
||||
* current time before putting the record in the database.
|
||||
* @throws IOException if the database can't be accessed.
|
||||
*/
|
||||
|
@ -187,7 +187,7 @@ abstract class TypedefDBAdapter {
|
|||
abstract Field[] getRecordIdsForSourceArchive(long archiveID) throws IOException;
|
||||
|
||||
/**
|
||||
* Get typedef record whoose sourceID and datatypeID match the specified Universal IDs.
|
||||
* Get typedef record whose sourceID and datatypeID match the specified Universal IDs.
|
||||
* @param sourceID universal source archive ID
|
||||
* @param datatypeID universal datatype ID
|
||||
* @return typedef record found or null
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
/* ###
|
||||
* IP: GHIDRA
|
||||
* REVIEWED: YES
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
|
@ -16,13 +15,13 @@
|
|||
*/
|
||||
package ghidra.program.database.oldfunction;
|
||||
|
||||
import db.DBHandle;
|
||||
import ghidra.program.database.map.AddressMap;
|
||||
import ghidra.program.database.util.SharedRangeMapDB;
|
||||
import ghidra.program.model.address.AddressSet;
|
||||
import ghidra.program.model.address.AddressSetView;
|
||||
import ghidra.util.datastruct.IndexRange;
|
||||
import ghidra.util.datastruct.IndexRangeIterator;
|
||||
import db.DBHandle;
|
||||
|
||||
/**
|
||||
*
|
||||
|
@ -52,7 +51,8 @@ class OldFunctionMapDB {
|
|||
|
||||
/**
|
||||
* Get the address set which makes up a function.
|
||||
* @param functionKey
|
||||
* @param functionKey the function key
|
||||
* @return the addresses
|
||||
*/
|
||||
synchronized AddressSetView getBody(long functionKey) {
|
||||
AddressSet body = new AddressSet();
|
||||
|
@ -81,7 +81,7 @@ class OldFunctionMapDB {
|
|||
// }
|
||||
//
|
||||
// /**
|
||||
// * Get all function keys whoose body contains the specified address.
|
||||
// * Get all function keys whose body contains the specified address.
|
||||
// * @param addr
|
||||
// * @return a LongField function key iterator.
|
||||
// */
|
||||
|
@ -91,7 +91,7 @@ class OldFunctionMapDB {
|
|||
// }
|
||||
//
|
||||
// /**
|
||||
// * Get all function keys whoose body overlaps the specified address set.
|
||||
// * Get all function keys whose body overlaps the specified address set.
|
||||
// * @param set
|
||||
// * @return a LongField function key iterator.
|
||||
// */
|
||||
|
|
|
@ -38,7 +38,7 @@ public interface CompositeInternal extends Composite {
|
|||
public final static int DEFAULT_PACKING = 0;
|
||||
|
||||
/**
|
||||
* The stored packing value which corresponds to a composite whoose packing has been disabled.
|
||||
* The stored packing value which corresponds to a composite whose packing has been disabled.
|
||||
* In the case of structures this will permit explicit component placement by
|
||||
* offset within the structure and undefined filler components will be used.
|
||||
* This is the initial state of all newly instantiated structures.
|
||||
|
|
|
@ -102,7 +102,7 @@ public interface DataTypeManager {
|
|||
* This method provides the added benefit of equivalence caching
|
||||
* for improved performance.
|
||||
* <br>
|
||||
* WARNING: This is an experimental method whoose use may cause the GUI and
|
||||
* WARNING: This is an experimental method whose use may cause the GUI and
|
||||
* task monitor to become unresponsive due to extended hold times on the manager lock.
|
||||
* @param dataTypes collection of datatypes
|
||||
* @param handler conflict handler
|
||||
|
|
|
@ -194,7 +194,7 @@ public class VariableUtilities {
|
|||
|
||||
/**
|
||||
* Perform variable storage checks using the specified datatype.
|
||||
* @param storage variable storage whoose size must match the specified data type size
|
||||
* @param storage variable storage whose size must match the specified data type size
|
||||
* @param dataType a datatype checked using {@link #checkDataType(DataType, boolean, int, Program)}
|
||||
* @param allowSizeMismatch if true size mismatch will be ignore
|
||||
* @throws InvalidInputException
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
/* ###
|
||||
* IP: GHIDRA
|
||||
* REVIEWED: YES
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
|
@ -19,18 +18,20 @@ package ghidra.program.model.symbol;
|
|||
import ghidra.program.model.address.Address;
|
||||
|
||||
/**
|
||||
* <code>OffsetReference</code> is a memory reference whoose "to" address is
|
||||
* <code>OffsetReference</code> is a memory reference whose "to" address is
|
||||
* computed from a base address plus an offset.
|
||||
*/
|
||||
public interface OffsetReference extends Reference {
|
||||
|
||||
/**
|
||||
* Returns the offset.
|
||||
* @return the offset
|
||||
*/
|
||||
public long getOffset();
|
||||
|
||||
/**
|
||||
* Returns the base address.
|
||||
* @return the address
|
||||
*/
|
||||
public Address getBaseAddress();
|
||||
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
/* ###
|
||||
* IP: GHIDRA
|
||||
* REVIEWED: YES
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
|
@ -17,18 +16,20 @@
|
|||
package ghidra.program.model.symbol;
|
||||
|
||||
/**
|
||||
* <code>ShiftedReference</code> is a memory reference whoose "to" address is
|
||||
* <code>ShiftedReference</code> is a memory reference whose "to" address is
|
||||
* computed from a base value left shifted by a shift amount.
|
||||
*/
|
||||
public interface ShiftedReference extends Reference {
|
||||
|
||||
/**
|
||||
* Returns the left shift amount.
|
||||
* @return the shift
|
||||
*/
|
||||
public int getShift();
|
||||
|
||||
/**
|
||||
* Returns the base value.
|
||||
* @return the value
|
||||
*/
|
||||
public long getValue();
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue