class WorldType implements StringType<World> {

    @Override
    public World parse(StringReader reader) throws CommandSyntaxException {
        var name = reader.readString();
        var world = Bukkit.getWorld(name);
        
        if (world == null) {
            throw WORLD.createWithContext(reader, name);
        }
        
        return world;
    }

}