@SuppressWarnings("deprecation") private static long javaToDosTime(long time){
  Date d=new Date(time);
  int year=d.getYear() + 1900;
  if (year < 1980) {
    return ZipEntry.DOSTIME_BEFORE_1980;
  }
  return (year - 1980) << 25 | (d.getMonth() + 1) << 21 | d.getDate() << 16 | d.getHours() << 11 | d.getMinutes() << 5 | d.getSeconds() >> 1;
}

@ SuppressWarnings ( "deprecation" ) private static long javaToDosTime ( long time ) { Date d = new Date ( time ) ; int year = d . getYear ( ) + 1900 ; if ( year < 1980 ) { return ZipEntry . DOSTIME_BEFORE_1980 ; } return ( year - 1980 ) << 25 | ( d . getMonth ( ) + 1 ) << 21 | d . getDate ( ) << 16 | d . getHours ( ) << 11 | d . getMinutes ( ) << 5 | d . getSeconds ( ) > > 1 ; }
converts java time to dos time .
