public class AiffUtil
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
private static java.text.SimpleDateFormat |
dateFmt |
private static java.nio.charset.Charset |
LATIN1 |
Constructor and Description |
---|
AiffUtil() |
Modifier and Type | Method and Description |
---|---|
static java.lang.String |
bytesToPascalString(byte[] data)
Convert a byte array to a Pascal string.
|
static java.lang.String |
formatDate(java.util.Date dat)
Format a date as text
|
static java.lang.String |
read4Chars(java.io.RandomAccessFile raf)
Reads 4 bytes and concatenates them into a String.
|
static double |
read80BitDouble(java.io.RandomAccessFile raf) |
static java.lang.String |
readPascalString(java.io.RandomAccessFile raf)
Read a Pascal string from the file.
|
static long |
readUINT32(java.io.RandomAccessFile raf)
Reads 4 bytes from file and interprets them as UINT32.
|
static java.util.Date |
timestampToDate(long timestamp)
Converts a Macintosh-style timestamp (seconds since
January 1, 1904) into a Java date.
|
private static final java.text.SimpleDateFormat dateFmt
private static final java.nio.charset.Charset LATIN1
public static long readUINT32(java.io.RandomAccessFile raf) throws java.io.IOException
raf
- file to read from.java.io.IOException
- on I/O Errors.public static java.lang.String read4Chars(java.io.RandomAccessFile raf) throws java.io.IOException
java.io.IOException
public static double read80BitDouble(java.io.RandomAccessFile raf) throws java.io.IOException
java.io.IOException
public static java.util.Date timestampToDate(long timestamp)
public static java.lang.String formatDate(java.util.Date dat)
public static java.lang.String bytesToPascalString(byte[] data)
public static java.lang.String readPascalString(java.io.RandomAccessFile raf) throws java.io.IOException
java.io.IOException
Copyright © 2005-2013 java.net. All Rights Reserved.