private static void addDataItem ( final DataSeries dataSeries , final SimpleDateFormat simpleDateFormat , final SimpleDateFormat parseIncomingDateFormat , final ViewRiksdagenOrgDocumentDailySummary item ) { if ( item != null && item . getEmbeddedId ( ) . getPublicDate ( ) . length ( ) > 0 ) { try { dataSeries . add ( simpleDateFormat . format ( parseIncomingDateFormat . parse ( item . getEmbeddedId ( ) . getPublicDate ( ) ) ) , item . getTotal ( ) ) ; } catch ( final ParseException e ) { LOGGER . warn ( "Problem parsing date:{}" , item . getEmbeddedId ( ) . getPublicDate ( ) ) ; } } }
Adds the data item .