diff --git a/Ghidra/Features/Base/src/main/java/ghidra/app/util/cparser/C/CParserUtils.java b/Ghidra/Features/Base/src/main/java/ghidra/app/util/cparser/C/CParserUtils.java index cd2861fc5c..4e1f7ad5b2 100644 --- a/Ghidra/Features/Base/src/main/java/ghidra/app/util/cparser/C/CParserUtils.java +++ b/Ghidra/Features/Base/src/main/java/ghidra/app/util/cparser/C/CParserUtils.java @@ -274,7 +274,7 @@ public class CParserUtils { * * @deprecated Use {@link #parseHeaderFiles(String[], String[], String[],String, DataTypeManager[], TaskMonitor)} instead. */ - @Deprecated(since = "12.2", forRemoval = true) + @Deprecated(since = "12.3", forRemoval = true) public static FileDataTypeManager parseHeaderFiles(DataTypeManager[] openDTMgrs, String[] filenames, String[] args, String dataFileName, TaskMonitor monitor) throws ghidra.app.util.cparser.C.ParseException, @@ -356,7 +356,7 @@ public class CParserUtils { * * @deprecated Use {@link #parseHeaderFiles(String[], String[], String[],String, DataTypeManager[], TaskMonitor)} instead. */ - @Deprecated(since = "12.2", forRemoval = true) + @Deprecated(since = "12.3", forRemoval = true) public static FileDataTypeManager parseHeaderFiles(DataTypeManager[] openDTMgrs, String[] filenames, String[] includePaths, String[] args, String dataFileName, TaskMonitor monitor) throws ghidra.app.util.cparser.C.ParseException, @@ -445,7 +445,7 @@ public class CParserUtils { * @throws IOException if there io are errors saving the archive * @deprecated Use {@link #parseHeaderFiles(String[], String[], String[], String, String, String, DataTypeManager[], Object,TaskMonitor)} instead. */ - @Deprecated(since = "12.2", forRemoval = true) + @Deprecated(since = "12.3", forRemoval = true) public static FileDataTypeManager parseHeaderFiles(DataTypeManager[] openDTMgrs, String[] filenames, String[] includePaths, String[] args, String dataFileName, String languageId, String compileSpecId, TaskMonitor monitor) diff --git a/Ghidra/Features/Base/src/main/java/ghidra/program/flatapi/FlatProgramAPI.java b/Ghidra/Features/Base/src/main/java/ghidra/program/flatapi/FlatProgramAPI.java index ba10022a12..e1622c8980 100644 --- a/Ghidra/Features/Base/src/main/java/ghidra/program/flatapi/FlatProgramAPI.java +++ b/Ghidra/Features/Base/src/main/java/ghidra/program/flatapi/FlatProgramAPI.java @@ -2552,7 +2552,7 @@ public class FlatProgramAPI { * @deprecated Use {@link #openFileDataTypeArchive(File, boolean)} instead. Then use * {@link PersistentDataTypeArchive#getDataTypeManager()} */ - @Deprecated(since = "12.2", forRemoval = true) + @Deprecated(since = "12.3", forRemoval = true) public final FileDataTypeManager openDataTypeArchive(File archiveFile, boolean readOnly) throws Exception { return FileDataTypeManager.openFileArchive(archiveFile, !readOnly); diff --git a/Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/program/database/data/FileDataTypeManagerDB.java b/Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/program/database/data/FileDataTypeManagerDB.java index fb02b8ffc6..f1463df375 100644 --- a/Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/program/database/data/FileDataTypeManagerDB.java +++ b/Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/program/database/data/FileDataTypeManagerDB.java @@ -15,8 +15,6 @@ */ package ghidra.program.database.data; -import static ghidra.program.model.dtarchive.FileDataTypeArchive.*; - import java.io.File; import java.io.IOException; @@ -173,7 +171,7 @@ public class FileDataTypeManagerDB extends ArchiveDataTypeManagerDB } @Override - @Deprecated(since = "12.2", forRemoval = true) + @Deprecated(since = "12.3", forRemoval = true) public void close() { if (!archive.isClosed()) { getDataStore().releaseDefaultConsumers(); diff --git a/Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/program/database/dtarchive/DefaultConsumer.java b/Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/program/database/dtarchive/DefaultConsumer.java index 3702d87752..5d70e0ab46 100644 --- a/Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/program/database/dtarchive/DefaultConsumer.java +++ b/Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/program/database/dtarchive/DefaultConsumer.java @@ -23,7 +23,7 @@ import ghidra.program.model.data.FileDataTypeManager; * can specifically look for DefaultConsumer and safely close them. This class can be removed * when the deprecated FileDataTypeManager interface is deleted. */ -@Deprecated(since = "12.2", forRemoval = true) +@Deprecated(since = "12.3", forRemoval = true) public class DefaultConsumer { // marker class } diff --git a/Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/program/model/data/ArchiveDataTypeManager.java b/Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/program/model/data/ArchiveDataTypeManager.java index 6b6322a263..e3bbb6e97a 100644 --- a/Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/program/model/data/ArchiveDataTypeManager.java +++ b/Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/program/model/data/ArchiveDataTypeManager.java @@ -42,7 +42,7 @@ public interface ArchiveDataTypeManager extends DataTypeManager { * @return path name or null if not applicable * @deprecated use {@link DataTypeStore#getPath()} instead. (After calling getDataStore()) */ - @Deprecated(since = "12.2", forRemoval = true) + @Deprecated(since = "12.3", forRemoval = true) public default String getPath() { return null; } @@ -70,7 +70,7 @@ public interface ArchiveDataTypeManager extends DataTypeManager { * @deprecated use {@link PersistentDataTypeArchive#setProgramArchitecture(Language, CompilerSpecID, LanguageUpdateOption, TaskMonitor)} * on the associated archive. */ - @Deprecated(since = "12.2", forRemoval = true) + @Deprecated(since = "12.3", forRemoval = true) public default void setProgramArchitecture(Language language, CompilerSpecID compilerSpecId, LanguageUpdateOption updateOption, TaskMonitor monitor) throws CompilerSpecNotFoundException, LanguageNotFoundException, IOException, diff --git a/Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/program/model/data/DataTypeManager.java b/Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/program/model/data/DataTypeManager.java index 51e2f04801..5eeb8402ec 100644 --- a/Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/program/model/data/DataTypeManager.java +++ b/Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/program/model/data/DataTypeManager.java @@ -20,8 +20,8 @@ import java.util.*; import db.Transaction; import ghidra.framework.model.DomainObject; import ghidra.program.database.SpecExtension; -import ghidra.program.model.dtarchive.PersistentDataTypeArchive; import ghidra.program.model.dtarchive.DataTypeStore; +import ghidra.program.model.dtarchive.PersistentDataTypeArchive; import ghidra.program.model.lang.*; import ghidra.program.model.listing.Function; import ghidra.program.model.listing.Program; @@ -515,7 +515,7 @@ public interface DataTypeManager { * archive closed out from under it, can add a consumer to the archive which then would need * to be released when done with it. */ - @Deprecated(since = "12.2", forRemoval = true) + @Deprecated(since = "12.3", forRemoval = true) public void close(); /** diff --git a/Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/program/model/data/FileDataTypeManager.java b/Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/program/model/data/FileDataTypeManager.java index a290de9e5e..433ea1b9ce 100644 --- a/Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/program/model/data/FileDataTypeManager.java +++ b/Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/program/model/data/FileDataTypeManager.java @@ -35,15 +35,29 @@ import ghidra.util.task.TaskMonitor; * Create or open a {@link FileDataTypeArchive}, then call * {@link PersistentDataTypeArchive#getDataTypeManager()}. */ -@Deprecated(since = "12.2", forRemoval = true) +@Deprecated(since = "12.3", forRemoval = true) public interface FileDataTypeManager extends ArchiveDataTypeManager, AutoCloseable { - @Deprecated(since = "12.2", forRemoval = true) + @Deprecated(since = "12.3", forRemoval = true) final static String OLD_EXTENSION = "dtf"; - @Deprecated(since = "12.2", forRemoval = true) + @Deprecated(since = "12.3", forRemoval = true) final static String OLD_SUFFIX = "." + OLD_EXTENSION; + /** + * File extension for a datatype archive file. "gdt" + * @deprecated use {@link FileDataTypeArchive#EXTENSION} instead + */ + @Deprecated(since = "12.3", forRemoval = true) + public final static String EXTENSION = FileDataTypeArchive.EXTENSION; + + /** + * Filename suffix for a datatype archive file. ".gdt" + * @deprecated use {@link FileDataTypeArchive#SUFFIX} instead + */ + @Deprecated(since = "12.3", forRemoval = true) + public final static String SUFFIX = FileDataTypeArchive.SUFFIX; + /** * Create a new data-type file archive using the default data organization * @param packedDbfile archive file (filename must end with DataTypeFileManager.SUFFIX) @@ -52,7 +66,7 @@ public interface FileDataTypeManager extends ArchiveDataTypeManager, AutoCloseab * @deprecated Use {@link DataTypeArchiveFactory#createFileArchive(File, Object)} to create a * file base archive, then call {@link PersistentDataTypeArchive#getDataTypeManager()} */ - @Deprecated(since = "12.2", forRemoval = true) + @Deprecated(since = "12.3", forRemoval = true) public static FileDataTypeManager createFileArchive(File packedDbfile) throws IOException { FileDataTypeArchive archive = DataTypeArchiveFactory.createFileArchive(packedDbfile, new DefaultConsumer()); @@ -74,7 +88,7 @@ public interface FileDataTypeManager extends ArchiveDataTypeManager, AutoCloseab * {@link DataTypeArchiveFactory#createFileArchive(File, LanguageID, CompilerSpecID, Object)} to * create a file based archive, then call {@link PersistentDataTypeArchive#getDataTypeManager()} */ - @Deprecated(since = "12.2", forRemoval = true) + @Deprecated(since = "12.3", forRemoval = true) public static FileDataTypeManager createFileArchive(File packedDbFile, LanguageID languageId, CompilerSpecID compilerSpecId) throws LanguageNotFoundException, CompilerSpecNotFoundException, IOException { @@ -101,7 +115,7 @@ public interface FileDataTypeManager extends ArchiveDataTypeManager, AutoCloseab * {@link DataTypeArchiveFactory#createFileArchive(File, String, String, Object)} to create * a file based archive, then call {@link PersistentDataTypeArchive#getDataTypeManager()} */ - @Deprecated(since = "12.2", forRemoval = true) + @Deprecated(since = "12.3", forRemoval = true) public static FileDataTypeManager createFileArchive(File packedDbfile, String languageId, String compilerSpecId) throws IOException { FileDataTypeArchive archive = @@ -127,7 +141,7 @@ public interface FileDataTypeManager extends ArchiveDataTypeManager, AutoCloseab * {@link DataTypeArchiveFactory#openForUpdate(File, boolean, Object, TaskMonitor)} to open * a file based archive, then call {@link PersistentDataTypeArchive#getDataTypeManager()} */ - @Deprecated(since = "12.2", forRemoval = true) + @Deprecated(since = "12.3", forRemoval = true) public static FileDataTypeManager openFileArchive(File file, boolean openForUpdate) throws IOException { return openFileArchive(new ResourceFile(file), openForUpdate); @@ -150,7 +164,7 @@ public interface FileDataTypeManager extends ArchiveDataTypeManager, AutoCloseab * or {@link DataTypeArchiveFactory#openForUpdate(ResourceFile, boolean, Object, TaskMonitor)} * to open a file based archive, then call {@link PersistentDataTypeArchive#getDataTypeManager()} */ - @Deprecated(since = "12.2", forRemoval = true) + @Deprecated(since = "12.3", forRemoval = true) public static FileDataTypeManager openFileArchive(ResourceFile file, boolean openForUpdate) throws IOException { FileDataTypeArchive archive; @@ -185,14 +199,14 @@ public interface FileDataTypeManager extends ArchiveDataTypeManager, AutoCloseab * {@return true if the archive has changed} * @deprecated Use {@link PersistentDataTypeArchive#isChanged} */ - @Deprecated(since = "12.2", forRemoval = true) + @Deprecated(since = "12.3", forRemoval = true) public boolean isChanged(); /** * {@return true if the archive containing this datatype manager has been closed} * @deprecated Use {@link PersistentDataTypeArchive#isClosed()} */ - @Deprecated(since = "12.2", forRemoval = true) + @Deprecated(since = "12.3", forRemoval = true) public boolean isClosed(); /** @@ -200,7 +214,7 @@ public interface FileDataTypeManager extends ArchiveDataTypeManager, AutoCloseab * @throws IOException if IO error occurs * @deprecated Use {@link FileDataTypeArchive#save(String, TaskMonitor)} */ - @Deprecated(since = "12.2", forRemoval = true) + @Deprecated(since = "12.3", forRemoval = true) public void save() throws IOException; /** @@ -212,7 +226,7 @@ public interface FileDataTypeManager extends ArchiveDataTypeManager, AutoCloseab * @throws IOException if IO error occurs * @deprecated Use {@link FileDataTypeArchive#saveAs(File, UniversalID)} */ - @Deprecated(since = "12.2", forRemoval = true) + @Deprecated(since = "12.3", forRemoval = true) public void saveAs(File outFile, UniversalID newFileID) throws DuplicateFileException, IOException; @@ -223,7 +237,7 @@ public interface FileDataTypeManager extends ArchiveDataTypeManager, AutoCloseab * @throws DuplicateFileException if a file with that name already exists. * @deprecated Use {@link FileDataTypeArchive#saveAs(File, TaskMonitor)} */ - @Deprecated(since = "12.2", forRemoval = true) + @Deprecated(since = "12.3", forRemoval = true) public void saveAs(File outFile) throws DuplicateFileException, IOException; }