标签:ide span exception integer his als play code except
public Map<Integer,String> getCity(List<Integer> cityIds) throws Exception{ Map<Integer,String> cityNames = new LinkedHashMap<>(); List<CityMapping> citys = this.getAllCity(); for(Integer cityId : cityIds) { Optional<CityMapping> cityItem = citys.stream().filter(x -> x.getCityId().equals(cityId) ).findFirst(); if(cityItem.isPresent()){ cityNames.put(cityId,cityItem.get().getCityName()); } } return cityNames; }
标签:ide span exception integer his als play code except
原文地址:http://www.cnblogs.com/caohuimingfa/p/6761696.html