Here you can find the source of calendar2TimeStamp(Calendar cal)
public static int calendar2TimeStamp(Calendar cal)
//package com.java2s; /**/*w w w .j a v a2 s. co m*/ * Utils class for the stats * S23Y (2015). Licensed under the Apache License, Version 2.0. * Author: Thibaud Ledent */ import java.util.Calendar; public class Main { public static int calendar2TimeStamp(Calendar cal) { return (int) (cal.getTimeInMillis() / 1000L); } }