3939 * provides access to the current state of the analysis in one thread. Depending on the current
4040 * {@link Hooks phase} only a subset of the state accessible via getters may be valid.
4141 *
42- * @see forEachRepository
43- * @see forEachCommit
42+ * @see # forEachRepository
43+ * @see # forEachCommit
4444 * @author Paul Bittner, Benjamin Moosherr
4545 */
4646public class Analysis {
@@ -54,7 +54,7 @@ public class Analysis {
5454 public static final String TOTAL_RESULTS_FILE_NAME = "totalresult" + EXTENSION ;
5555 /**
5656 * Default value for <code>commitsToProcessPerThread</code>
57- * @see forEachCommit(Supplier, int, int)
57+ * @see # forEachCommit(Supplier, int, int)
5858 */
5959 public static final int COMMITS_TO_PROCESS_PER_THREAD_DEFAULT = 1000 ;
6060
@@ -130,23 +130,23 @@ public Path getOutputFile() {
130130
131131 /**
132132 * The results of the analysis. This may be modified by any hook and should be initialized in
133- * {@link Hooks#initializeResults} (e.g. by using {@link append}).
133+ * {@link Hooks#initializeResults} (e.g. by using {@link # append}).
134134 * Always valid.
135135 */
136136 public AnalysisResult getResult () {
137137 return result ;
138138 }
139139
140140 /**
141- * Convenience getter for {@link AnalysisResult#get} on {@link getResult}.
141+ * Convenience getter for {@link AnalysisResult#get} on {@link # getResult}.
142142 * Always valid.
143143 */
144144 public <T extends Metadata <T >> T get (ResultKey <T > resultKey ) {
145145 return result .get (resultKey );
146146 }
147147
148148 /**
149- * Convenience function for {@link AnalysisResult#append} on {@link getResult}.
149+ * Convenience function for {@link AnalysisResult#append} on {@link # getResult}.
150150 * Always valid.
151151 */
152152 public <T extends Metadata <T >> void append (ResultKey <T > resultKey , T value ) {
@@ -176,13 +176,13 @@ public <T extends Metadata<T>> void append(ResultKey<T> resultKey, T value) {
176176 * end hooks).
177177 *
178178 * <p>An analysis implementing {@code Hooks} can perform various actions during each hook. This
179- * includes the {@link append creation} and {@link get modification} of {@link getResult
179+ * includes the {@link # append creation} and {@link # get modification} of {@link # getResult
180180 * analysis results}, modifying their internal state, performing IO operations and throwing
181181 * exceptions. In contrast, the only analysis state hooks are allowed to modify is the {@link
182- * getResult result} of an {@link Analysis}. All other state (e.g. {@link getCurrentCommit})
182+ * # getResult result} of an {@link Analysis}. All other state (e.g. {@link # getCurrentCommit})
183183 * must not be modified. Care must be taken to avoid the reliance of the internal state on a
184- * specific commit batch being processed as only the {@link getResult results} of each commit
185- * batch are merged and returned by {@link forEachCommit}.
184+ * specific commit batch being processed as only the {@link # getResult results} of each commit
185+ * batch are merged and returned by {@link # forEachCommit}.
186186 *
187187 * <p>Hooks that return a {@code boolean} are called filter hooks and can, in addition to the
188188 * above, skip any further processing in the current phase (including following inner phases) by
@@ -195,8 +195,8 @@ public <T extends Metadata<T>> void append(ResultKey<T> resultKey, T value) {
195195 */
196196 public interface Hooks {
197197 /**
198- * Initialization hook for {@link getResult}. All result types should be appended with a
199- * neutral value using {@link append}. No other side effects should be performed during this
198+ * Initialization hook for {@link # getResult}. All result types should be appended with a
199+ * neutral value using {@link # append}. No other side effects should be performed during this
200200 * methods as it might be called an arbitrary amount of times.
201201 */
202202 default void initializeResults (Analysis analysis ) {}
@@ -205,7 +205,7 @@ default void beginBatch(Analysis analysis) throws Exception {}
205205 /**
206206 * Signals a parsing failure of all patches in the current commit.
207207 * Called at most once during the commit phase. If this hook is called {@link
208- * onParsedCommit} and the following patch phase invocations are skipped.
208+ * # onParsedCommit} and the following patch phase invocations are skipped.
209209 */
210210 default void onFailedCommit (Analysis analysis ) throws Exception {}
211211 /**
@@ -232,9 +232,9 @@ default void endBatch(Analysis analysis) throws Exception {}
232232 /**
233233 * Runs {@code analyzeRepository} on each repository, skipping repositories where an analysis
234234 * was already run. This skipping mechanism doesn't distinguish between different analyses as it
235- * only checks for the existence of {@link TOTAL_RESULTS_FILE_NAME}. Delete this file to rerun
235+ * only checks for the existence of {@link # TOTAL_RESULTS_FILE_NAME}. Delete this file to rerun
236236 * the analysis.
237- *
237+ * <p>
238238 * For each repository a directory in {@code outputDir} is passed to {@code analyzeRepository}
239239 * where the results of the given repository should be written.
240240 *
@@ -336,8 +336,8 @@ public boolean beginPatch(Analysis analysis) {
336336 }
337337
338338 /**
339- * Same as {@link forEachCommit(Supplier<Analysis> , int, int)}.
340- * Defaults to {@link COMMITS_TO_PROCESS_PER_THREAD_DEFAULT} and a machine dependent number of
339+ * Same as {@link # forEachCommit(Supplier, int, int)}.
340+ * Defaults to {@link # COMMITS_TO_PROCESS_PER_THREAD_DEFAULT} and a machine dependent number of
341341 * {@link Diagnostics#getNumberOfAvailableProcessors}.
342342 */
343343 public static AnalysisResult forEachCommit (Supplier <Analysis > analysis ) {
@@ -443,10 +443,10 @@ public Analysis(
443443
444444 /**
445445 * Entry point into a sequential analysis of {@code commits} as one batch.
446- * Same as {@link processCommits(List<RevCommit> , GitDiffer)} with a default {@link GitDiffer}.
446+ * Same as {@link # processCommits(List, GitDiffer)} with a default {@link GitDiffer}.
447447 *
448448 * @param commits the commit batch to be processed
449- * @see forEachCommit
449+ * @see # forEachCommit
450450 */
451451 public AnalysisResult processCommits (List <RevCommit > commits ) throws Exception {
452452 return processCommits (commits , new GitDiffer (getRepository ()));
@@ -457,7 +457,7 @@ public AnalysisResult processCommits(List<RevCommit> commits) throws Exception {
457457 *
458458 * @param commits the commit batch to be processed
459459 * @param differ the differ to use
460- * @see forEachCommit
460+ * @see # forEachCommit
461461 */
462462 public AnalysisResult processCommits (List <RevCommit > commits , GitDiffer differ ) throws Exception {
463463 this .differ = differ ;
@@ -590,7 +590,7 @@ protected <Hook> void runReverseHook(ListIterator<Hook> hook, FailableBiConsumer
590590
591591 /**
592592 * Exports the given metadata object to a file named according
593- * {@link TOTAL_RESULTS_FILE_NAME} in the given directory.
593+ * {@link # TOTAL_RESULTS_FILE_NAME} in the given directory.
594594 * @param outputDir The directory into which the metadata object file should be written.
595595 * @param metadata The metadata to serialize
596596 * @param <T> Type of the metadata.
0 commit comments