class Utils {

    public static String getValidityTime(String transactionTime) {

        if (transactionTime != null) {

            //2015-10-30 20:32:51
            String data[] = transactionTime.split(" ");
            if (data.length > 1) {

                try {
                    @SuppressLint("SimpleDateFormat")
                    SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyy-MM-dd");
                    Calendar calendar = Calendar.getInstance();
                    calendar.setTime(simpleDateFormat.parse(data[0]));
                    calendar.add(Calendar.DATE, 1);
                    String date = simpleDateFormat.format(calendar.getTime());

                    String splitedDate[] = date.split("-");
                    String month = getMonth(Integer.parseInt(splitedDate[1]));

                    String validityTime = "" + splitedDate[2] + " " + month + " " +
                            splitedDate[0] + ", " + data[1];

                    Logger.i("after parsing validity date becomes : " + date);
                    Logger.i("month is : " + month);
                    Logger.i("validity time is : " + validityTime);

                    return validityTime;

                } catch (ParseException ex) {
                    Logger.e("Error while parsing date : " + ex.getMessage());
                }

            }

        }

        return transactionTime;
    }

}