-
Notifications
You must be signed in to change notification settings - Fork 31
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add extensible crash report header system (#88)
- Loading branch information
1 parent
6277474
commit 9b239e3
Showing
3 changed files
with
41 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
21 changes: 21 additions & 0 deletions
21
loader/src/main/java/net/neoforged/fml/ICrashReportHeader.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
/* | ||
* Copyright (c) Forge Development LLC and contributors | ||
* SPDX-License-Identifier: LGPL-2.1-only | ||
*/ | ||
|
||
package net.neoforged.fml; | ||
|
||
import org.jetbrains.annotations.Nullable; | ||
|
||
/** | ||
* Supplies a header to add to crash reports. | ||
* @see CrashReportCallables#registerHeader(ICrashReportHeader) | ||
*/ | ||
@FunctionalInterface | ||
public interface ICrashReportHeader { | ||
/** | ||
* {@return the header to be displayed at the top of the crash report, or {@code null} if the header shouldn't be added} | ||
*/ | ||
@Nullable | ||
String getHeader(); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters