diff options
author | SHsuperCM <shsupercm@gmail.com> | 2022-02-12 09:21:09 +0200 |
---|---|---|
committer | SHsuperCM <shsupercm@gmail.com> | 2022-02-12 09:21:09 +0200 |
commit | d51ec9fd6cde3ad393d4d0c91e30cc5d03945eaf (patch) | |
tree | 0f31635f43220e6a3ffcc9bc9390de7016242959 /src/main/java/shcm/shsupercm/fabric/citresewn/ex/CITParsingException.java | |
parent | ba570a6b2e37f6f45b149515cd41d10037cbda7f (diff) | |
download | CITResewn-d51ec9fd6cde3ad393d4d0c91e30cc5d03945eaf.tar.gz CITResewn-d51ec9fd6cde3ad393d4d0c91e30cc5d03945eaf.tar.bz2 CITResewn-d51ec9fd6cde3ad393d4d0c91e30cc5d03945eaf.zip |
More work on type registry/api
Diffstat (limited to 'src/main/java/shcm/shsupercm/fabric/citresewn/ex/CITParsingException.java')
-rw-r--r-- | src/main/java/shcm/shsupercm/fabric/citresewn/ex/CITParsingException.java | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/src/main/java/shcm/shsupercm/fabric/citresewn/ex/CITParsingException.java b/src/main/java/shcm/shsupercm/fabric/citresewn/ex/CITParsingException.java new file mode 100644 index 0000000..964b58d --- /dev/null +++ b/src/main/java/shcm/shsupercm/fabric/citresewn/ex/CITParsingException.java @@ -0,0 +1,13 @@ +package shcm.shsupercm.fabric.citresewn.ex; + +import shcm.shsupercm.fabric.citresewn.pack.format.PropertyGroup; + +public class CITParsingException extends Exception { + public CITParsingException(String message, PropertyGroup propertyGroup, int position) { + super("Errored while parsing CIT: " + descriptionOf(message, propertyGroup, position)); + } + + public static String descriptionOf(String message, PropertyGroup propertyGroup, int position) { + return message + " at " + position + " in " + propertyGroup.identifier.toString() + " from " + propertyGroup.packName; + } +} |