-
-
Notifications
You must be signed in to change notification settings - Fork 105
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
4 changed files
with
110 additions
and
125 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
27 changes: 27 additions & 0 deletions
27
...r-legacy/src/main/java/net/kyori/adventure/text/serializer/legacy/CharacterAndFormat.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,27 @@ | ||
package net.kyori.adventure.text.serializer.legacy; | ||
|
||
import net.kyori.adventure.text.format.TextFormat; | ||
import org.jetbrains.annotations.NotNull; | ||
|
||
/** | ||
* A pair containing a text format and its legacy character equivalent. | ||
* @since 4.14.0 | ||
*/ | ||
public final class CharacterAndFormat { | ||
private final char character; | ||
private final @NotNull TextFormat format; | ||
|
||
public CharacterAndFormat(final char character, final @NotNull TextFormat format) { | ||
this.character = character; | ||
this.format = format; | ||
} | ||
|
||
public char getCharacter() { | ||
return character; | ||
} | ||
|
||
@NotNull | ||
public TextFormat getFormat() { | ||
return format; | ||
} | ||
} |
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