On Java Development

All things related to Java development, from the perspective of a caveman.

Archive for the ‘Date and Time’ Category

Displaying Date or Time

without comments

Introduction

Dates and Times on the iSeries are often stored as integers where the date will be in “yyyymmdd” format and the time will be in “hhmmss” format. This post shows how to properly format dates so that it appears on the web-page as “yyyy-dd-mm” and times as “hh:mm:ss”. For example, a date stored as “20120102” in the database needs to appear as “2012-01-02” when displayed on a web-page. A time stored as “210815” needs to appear as “21:08:15”. The post also presents information on managed beans, how they are referenced by a RichFaces DataTable and the RichFaces DataTable iterative process.
Read the rest of this entry »

Written by admin

March 10th, 2014 at 10:43 am

Date and Time Helper Class

without comments

Introduction

This post introduces the methods of a helper class designed to retrieve system dates and times and supports formatting of dates and times from other sources. Helper classes are used to provide a specific function to assist the overall goal of the application and are different from so-called Utility classes.
Read the rest of this entry »

Written by admin

January 23rd, 2014 at 6:01 pm