Java String to Timestamp toTimeStamp(String argS)

Here you can find the source of toTimeStamp(String argS)

Description

to Time Stamp

License

Open Source License

Declaration

public static java.util.Date toTimeStamp(String argS) 

Method Source Code

//package com.java2s;

import java.text.SimpleDateFormat;

public class Main {
    public static java.util.Date toTimeStamp(String argS) {
        java.util.Date date = null;
        SimpleDateFormat newFormat = new SimpleDateFormat("yyyy-MM-dd-HH.mm.ss");
        try {//from  ww w. j av a 2  s. com
            date = (java.util.Date) newFormat.parse(argS);
        } catch (Exception eException) {
        }
        return date;
    }
}

Related

  1. string2timestamp(String timeString)
  2. stringToTimestamp(String date)
  3. timestamp(String string)
  4. timeStamp2Date(String timestampString)
  5. timeStampToDate(String timeStamp)
  6. toTimeStamp(String myDate, String pattern, Locale language)
  7. toTimestamp(String source)
  8. ToTimestamp(String user_time)