All Packages Class Hierarchy This Package Previous Next Index
Class com.ibm.as400.access.AS400DateTimeConverter
java.lang.Object
|
+----com.ibm.as400.access.AS400DateTimeConverter
- public class AS400DateTimeConverter
- extends Object
The AS400DateTimeConverter class represents a converted date and time.
The AS/400 System API QWCCVTDT is used to convert a date and time value
from one format to another format.
-
as400_
- The system.
-
AS400DateTimeConverter(AS400)
- Constructs a AS400DateTimeConverter object.
-
convert(AS400, byte[], String, String)
- Converts date and time values from the input format to the requested output format.
-
getByteArray(Date, String)
- Returns the converted date and time in a byte array.
-
getDate(byte[], String)
- Returns the Date object in the YYMD format.
as400_
protected static AS400 as400_
- The system.
AS400DateTimeConverter
public AS400DateTimeConverter(AS400 system)
- Constructs a AS400DateTimeConverter object.
- Parameters:
- system - The AS/400 system.
convert
public static byte[] convert(AS400 system,
byte in[],
String inFormat,
String outFormat)
- Converts date and time values from the input format to the requested output format.
- Parameters:
- system - The AS/400 system.
- in - The date and time value to be converted.
- inFormat - The input date and time format. Possible values are:
- *DTS
- *JOB
- *SYSVAL
- *YMD
- *YYMD
- *MDY
- *MDYY
- *DMY
- *DMYY
- *JUL
- *LONGJUL
- outFormat - The output date and time format. Possible values are:
- *DTS
- *JOB
- *SYSVAL
- *YMD
- *YYMD
- *MDY
- *MDYY
- *DMY
- *DMYY
- *JUL
- *LONGJUL
- Returns:
- The converted date and time value.
getDate
public static Date getDate(byte in[],
String format)
- Returns the Date object in the YYMD format.
- Parameters:
- in - The date and time value to be converted.
- format - The format of the date and time value being provided.
- Returns:
- The Date object in the YYMD format.
getByteArray
public static byte[] getByteArray(Date date,
String format)
- Returns the converted date and time in a byte array.
- Parameters:
- date - The Date object to be converted. It must be in the format YYMD.
- format - The output date and time format.
- Returns:
- The converted date and time in a byte array.
All Packages Class Hierarchy This Package Previous Next Index