MCPcopy Create free account
hub / github.com/PCGen/pcgen / parseGameMode

Method parseGameMode

code/src/java/pcgen/io/PCGVer2Parser.java:2856–2869  ·  view source on GitHub ↗
(final String line)

Source from the content-addressed store, hash-verified

2854 }
2855
2856 private void parseGameMode(final String line) throws PCGParseException
2857 {
2858 final String requestedMode = line.substring(IOConstants.TAG_GAMEMODE.length() + 1);
2859
2860 final GameMode currentGameMode = SettingsHandler.getGameAsProperty().get();
2861 final String currentMode = currentGameMode.getName();
2862
2863 if (!requestedMode.equals(currentMode))
2864 {
2865 final String msg = LanguageBundle.getFormattedString("Exceptions.PCGenParser.WrongGameMode", //$NON-NLS-1$
2866 requestedMode, currentMode);
2867 throw new PCGParseException("ParseGameMode", line, msg); //$NON-NLS-1$
2868 }
2869 }
2870
2871 private void parseGenderLine(final String line)
2872 {

Callers 1

parseCachedLinesMethod · 0.95

Calls 5

getGameAsPropertyMethod · 0.95
getNameMethod · 0.95
getFormattedStringMethod · 0.95
getMethod · 0.65
equalsMethod · 0.65

Tested by

no test coverage detected