-
-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
perf: Improved performance of Formatter class
- Loading branch information
Showing
3 changed files
with
77 additions
and
29 deletions.
There are no files selected for viewing
23 changes: 19 additions & 4 deletions
23
src/main/java/me/dreamerzero/chatregulator/placeholders/formatter/IFormatter.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 |
---|---|---|
@@ -1,15 +1,30 @@ | ||
package me.dreamerzero.chatregulator.placeholders.formatter; | ||
|
||
import org.jetbrains.annotations.NotNull; | ||
import org.jetbrains.annotations.Nullable; | ||
|
||
import net.kyori.adventure.audience.Audience; | ||
import net.kyori.adventure.text.Component; | ||
import net.kyori.adventure.text.minimessage.tag.resolver.TagResolver; | ||
|
||
public interface IFormatter { | ||
Component parse(String string); | ||
Component parse( | ||
final @NotNull String string | ||
); | ||
|
||
Component parse(String string, TagResolver extraResolver); | ||
Component parse( | ||
final @NotNull String string, | ||
final @NotNull TagResolver extraResolver | ||
); | ||
|
||
Component parse(String string, Audience audience); | ||
Component parse( | ||
final @NotNull String string, | ||
final @Nullable Audience audience | ||
); | ||
|
||
Component parse(String string, Audience audience, TagResolver extraResolver); | ||
Component parse( | ||
final @NotNull String string, | ||
final @Nullable Audience audience, | ||
final @NotNull TagResolver extraResolver | ||
); | ||
} |
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
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