Skip to content

Commit 32dd3a4

Browse files
ctruedenclaude
andcommitted
Deprecate the subsystems superseded by SciJava3
A second wave, covering what has been ported since the first: the annotation index (scijava-index), locations, data handles, byte banks and Bytes (scijava-io3), the event system (scijava-events), and the task package (scijava-progress). Pointers use {@code} rather than {@link} for the same reason as before: the replacements target Java 11 and cannot be on this project's classpath, and a dead {@link} is a doclint reference error, which matters because doclint is only disabled under the build-javadoc profile. Verified: javadoc with -Ddoclint=all,-missing reports the same 8 pre-existing messages as before this change. Where a class is not merely renamed, the tag says what changed -- LocationService and DataHandleService becoming ServiceLoader-backed facades that need no context, DataHandle no longer being a wrapper plugin, task.Task no longer carrying cancellation, EventBus taking lambdas instead of scanning annotated methods, and events needing no base type. Where there is no replacement at all -- EventHistory, NIOService, EclipseHelper, AnnotationCombiner, SciJavaEvent -- the tag says that plainly and says what to do instead. IndexReader and ByteCodeAnalyzer are deliberately untouched: both are package-private, so there is nothing for downstream code to migrate. No functional change. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_013gJpzGd3ksbME4CN6Tu2ni
1 parent b18849d commit 32dd3a4

60 files changed

Lines changed: 262 additions & 0 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

‎src/main/java/org/scijava/annotations/AbstractIndexWriter.java‎

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,12 @@
5555
* </p>
5656
*
5757
* @author Johannes Schindelin
58+
*
59+
* @deprecated Use {@code org.scijava.index.AbstractIndexWriter}
60+
* (scijava-index) instead. The index format is unchanged, so
61+
* indexes written by either are readable by both.
5862
*/
63+
@Deprecated
5964
public abstract class AbstractIndexWriter {
6065

6166
private final Map<String, Map<String, Object>> map =

‎src/main/java/org/scijava/annotations/AnnotationCombiner.java‎

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,11 @@
4848
* Combines annotation indexes from all JAR files on the classpath.
4949
*
5050
* @author Curtis Rueden
51+
*
52+
* @deprecated No replacement here: merging indexes for shaded JARs is build
53+
* tooling, and belongs in scijava-maven-plugin.
5154
*/
55+
@Deprecated
5256
public class AnnotationCombiner extends AbstractIndexWriter implements Combiner
5357
{
5458

‎src/main/java/org/scijava/annotations/AnnotationProcessor.java‎

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -89,8 +89,13 @@
8989
* </p>
9090
*
9191
* @author Johannes Schindelin
92+
*
93+
* @deprecated Use {@code org.scijava.index.AnnotationProcessor}
94+
* (scijava-index) instead. The index format is unchanged, so
95+
* indexes written by either are readable by both.
9296
*/
9397
@SupportedAnnotationTypes("*")
98+
@Deprecated
9499
public class AnnotationProcessor extends AbstractProcessor {
95100

96101
private RoundEnvironment roundEnv;

‎src/main/java/org/scijava/annotations/DirectoryIndexer.java‎

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,12 @@
5050
* </p>
5151
*
5252
* @author Johannes Schindelin
53+
*
54+
* @deprecated Use {@code org.scijava.index.DirectoryIndexer} (scijava-index)
55+
* instead. The index format is unchanged, so indexes written by
56+
* either are readable by both.
5357
*/
58+
@Deprecated
5459
public class DirectoryIndexer extends AbstractIndexWriter {
5560

5661
public void index(final File directory) throws IOException {

‎src/main/java/org/scijava/annotations/EclipseHelper.java‎

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,12 @@
9393
* </p>
9494
*
9595
* @author Johannes Schindelin
96+
*
97+
* @deprecated No replacement. Modern m2e generates the annotation processor
98+
* path itself; for indexing a directory, use
99+
* {@code org.scijava.index.DirectoryIndexer} (scijava-index).
96100
*/
101+
@Deprecated
97102
public class EclipseHelper extends DirectoryIndexer {
98103

99104
private static final String FORCE_ANNOTATION_INDEX_PROPERTY = "force.annotation.index";

‎src/main/java/org/scijava/annotations/Index.java‎

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,12 @@
5353
* </pre>
5454
*
5555
* @author Johannes Schindelin
56+
*
57+
* @deprecated Use {@code org.scijava.index.Index} (scijava-index) instead. The
58+
* index format is unchanged, so indexes written by either are
59+
* readable by both.
5660
*/
61+
@Deprecated
5762
public class Index<A extends Annotation> implements Iterable<IndexItem<A>> {
5863

5964
/**

‎src/main/java/org/scijava/annotations/IndexItem.java‎

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,12 @@
4141
* Allows access to individual annotations.
4242
*
4343
* @author Johannes Schindelin
44+
*
45+
* @deprecated Use {@code org.scijava.index.IndexItem} (scijava-index) instead.
46+
* The index format is unchanged, so indexes written by either are
47+
* readable by both.
4448
*/
49+
@Deprecated
4550
public class IndexItem<A extends Annotation> {
4651

4752
private final Class<A> annotation;

‎src/main/java/org/scijava/annotations/Indexable.java‎

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,12 @@
4242
* </p>
4343
*
4444
* @author Johannes Schindelin
45+
*
46+
* @deprecated Use {@code org.scijava.index.Indexable} (scijava-index) instead.
47+
* The index format is unchanged, so indexes written by either are
48+
* readable by both.
4549
*/
4650
@Retention(RetentionPolicy.RUNTIME)
4751
@Target({ ElementType.TYPE, ElementType.ANNOTATION_TYPE })
52+
@Deprecated
4853
public @interface Indexable {}

‎src/main/java/org/scijava/event/DefaultEventHistory.java‎

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,8 +41,11 @@
4141
* Default service for keeping a history of SciJava events.
4242
*
4343
* @author Curtis Rueden
44+
*
45+
* @deprecated No replacement; see {@link org.scijava.event.EventHistory}.
4446
*/
4547
@Plugin(type = Service.class)
48+
@Deprecated
4649
public class DefaultEventHistory extends AbstractService implements
4750
EventHistory
4851
{

‎src/main/java/org/scijava/event/DefaultEventService.java‎

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,8 +56,12 @@
5656
*
5757
* @author Curtis Rueden
5858
* @author Grant Harris
59+
*
60+
* @deprecated Use {@code org.scijava.events.DefaultEventBus} (scijava-events)
61+
* instead.
5962
*/
6063
@Plugin(type = Service.class, priority = DefaultEventService.PRIORITY)
64+
@Deprecated
6165
public class DefaultEventService extends AbstractService implements
6266
EventService
6367
{

0 commit comments

Comments
 (0)