Here you can find the source of timestamp2string()
public static String timestamp2string()
//package com.java2s; //License from project: Apache License public class Main { public static String timestamp2string() { return String.valueOf(System.currentTimeMillis() / 1000); }//from w ww .j a v a 2 s . c o m }