Examples/AirlineFaresNew/src/main/java/com/cs6240/airline/FileEvaluator.java
/* 
	 * Create a map with key as flight Carrier and value as a list of prices 
	 */
Create a map with key as flight Carrier and value as a list of prices
Create a map with key as flight Carrier and value as a list of prices
private void createMapWithFlightDetails(AirlineDetailsPojo airline) {
		String key = airline.getMonth()+"\t"+airline.getCarrier();
		if(flightPriceMap.get(key) == null) { 
			List<Double> priceList = new ArrayList<Double>();
			priceList.add(airline.getPrice());
			flightPriceMap.put(key, priceList);
		}else {
			List<Double> priceList = flightPriceMap.get(key);
			priceList.add(airline.getPrice());
			flightPriceMap.put(key, priceList);
		}
	}
private void createMapWithFlightDetails ( AirlineDetailsPojo airline ) { String key = airline . getMonth ( ) + "\t" + airline . getCarrier ( ) ; if ( flightPriceMap . get ( key ) == null ) { List < Double > priceList = new ArrayList < Double > ( ) ; priceList . add ( airline . getPrice ( ) ) ; flightPriceMap . put ( key , priceList ) ; } else { List < Double > priceList = flightPriceMap . get ( key ) ; priceList . add ( airline . getPrice ( ) ) ; flightPriceMap . put ( key , priceList ) ; } }
Create a map with key as flight Carrier and value as a list of prices
Create a map with key as flight Carrier and value as a list of prices
//inserting list for first time 