Java Calendar Truncate trimCalendar(Calendar cal)

Here you can find the source of trimCalendar(Calendar cal)

Description

trim Calendar

License

Apache License

Declaration

public static void trimCalendar(Calendar cal) 

Method Source Code

//package com.java2s;
//License from project: Apache License 

import java.util.Calendar;

public class Main {
    public static void trimCalendar(Calendar cal) {
        cal.set(Calendar.HOUR_OF_DAY, 0);
        cal.set(Calendar.MINUTE, 0);
        cal.set(Calendar.SECOND, 0);
        cal.set(Calendar.MILLISECOND, 0);
    }//www.  ja v  a  2 s .  co m
}

Related

  1. trim(final Calendar cal)
  2. trunc(Calendar calendar)
  3. truncate(Calendar calendar)
  4. truncateCal(final Calendar cal)
  5. truncCalendar(Calendar c)