Java tutorial
//package com.java2s; import java.util.Calendar; public class Main { public static void copyTime(Calendar dest, Calendar src) { dest.set(Calendar.HOUR_OF_DAY, src.get(Calendar.HOUR_OF_DAY)); dest.set(Calendar.MINUTE, src.get(Calendar.MINUTE)); dest.set(Calendar.SECOND, src.get(Calendar.SECOND)); dest.set(Calendar.MILLISECOND, src.get(Calendar.MILLISECOND)); } }