Modifier | Constructor and Description |
---|---|
|
ProgramField() |
protected |
ProgramField(Object o)
Used for creating an instance of ProgramField to
read/store the additional ProgramFrame id in.
|
|
ProgramField(ProgramFieldType type,
byte[] data)
Deprecated.
use the factory method
|
|
ProgramField(ProgramFieldType type,
int value)
Deprecated.
use the factory method
|
|
ProgramField(ProgramFieldType type,
String text)
Deprecated.
use the factory method
|
Modifier and Type | Method and Description |
---|---|
static boolean |
arraysAreEqual(byte[] array1,
byte[] array2) |
Object |
clone() |
static ProgramField |
create(ProgramFieldType type,
byte[] data) |
static ProgramField |
create(ProgramFieldType type,
int value) |
static ProgramField |
create(ProgramFieldType type,
String text) |
boolean |
equals(Object obj) |
byte[] |
getBinaryData() |
String |
getDataAsString()
Gets a String representation of the data value.
|
int |
getIntData() |
String |
getTextData() |
int |
getTimeData() |
ProgramFieldType |
getType() |
int |
getTypeId() |
void |
readFromStream(InputStream stream) |
void |
removeData()
Is used for a field in an update file that should be deleted.
|
void |
setBinaryData(byte[] data) |
void |
setIntData(int value) |
void |
setTextData(String text) |
void |
setTimeData(int minutesAfter1970) |
void |
setType(ProgramFieldType type) |
void |
writeToStream(OutputStream stream) |
protected void |
writeToStream(OutputStream stream,
boolean check)
Writes the data to a stream.
|
public ProgramField()
protected ProgramField(Object o)
o
- Dummy parameter.public ProgramField(ProgramFieldType type, String text)
public ProgramField(ProgramFieldType type, byte[] data)
public ProgramField(ProgramFieldType type, int value)
public static ProgramField create(ProgramFieldType type, String text)
public static ProgramField create(ProgramFieldType type, byte[] data)
public static ProgramField create(ProgramFieldType type, int value)
public int getTypeId()
public ProgramFieldType getType()
public void setType(ProgramFieldType type)
type
- public void removeData()
public byte[] getBinaryData()
public void setBinaryData(byte[] data)
data
- public String getTextData()
public void setTextData(String text)
public int getIntData()
public void setIntData(int value)
public int getTimeData()
public void setTimeData(int minutesAfter1970)
public String getDataAsString()
public void readFromStream(InputStream stream) throws IOException, FileFormatException
IOException
FileFormatException
public void writeToStream(OutputStream stream) throws IOException, FileFormatException
IOException
FileFormatException
protected void writeToStream(OutputStream stream, boolean check) throws IOException, FileFormatException
stream
- The stream to write oncheck
- If the format should be checkedIOException
- Thrown if something goes wrong.FileFormatException
- Thrown if something goes wrong.public static boolean arraysAreEqual(byte[] array1, byte[] array2)
TV-Browser 2.7.6, Copyright (C) 04-2003 Martin Oberhauser (martin@tvbrowser.org)