class RegionResolversImpl implements RegionResolvers {

    @Override
    public DataFetcher<Region> getRegionDataFetcher() {
        return environment -> {
            long regionId = getRegionId(environment);
            if (regionId <= 0) {
                return null;
            }

            return regionService.getRegion(regionId);
        };
    }

}