public class ADEPT2UDTValue extends java.lang.Object implements UDTValue
| Modifier and Type | Field and Description |
|---|---|
protected java.io.InputStream |
stream
The input stream providing the data as long as the data has not been read
from the stream.
|
protected java.lang.String |
userDefinedTypeName
The name of the user-defined type.
|
protected byte[] |
value
The value of this UDTValue as byte array.
|
| Constructor and Description |
|---|
ADEPT2UDTValue(java.lang.String userDefinedType,
byte[] value)
Creates a new UDTValue with the designated name and the designated value
(byte array).
|
ADEPT2UDTValue(java.lang.String userDefinedType,
java.io.InputStream stream)
Creates a new UDTValue with the designated name and the designated value
(input stream).
|
ADEPT2UDTValue(java.lang.String userDefinedType,
java.io.InputStream stream,
boolean eager)
Creates a new UDTValue with the designated name and the designated value
(input stream).
|
ADEPT2UDTValue(java.lang.String userDefinedType,
java.io.InputStream stream,
int length)
Creates a new UDTValue with the designated name and the designated value
(input stream).
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(java.lang.Object obj) |
protected void |
finalize()
Closes the input stream if the stream still exists and thus the data has
not been read yet.
|
java.lang.String |
getUserDefinedType()
Gets the name (a string) of the user-defined type of this value.
|
byte[] |
getValueAsArray()
Gets the value as a byte array of this user-defined data type.
|
java.io.InputStream |
getValueAsStream()
Gets the value as an
InputStream of this user-defined data
type. |
int |
hashCode() |
protected void |
readStream()
Reads all the data provided by the stream if not done yet.
|
java.lang.String |
toString() |
protected java.lang.String userDefinedTypeName
protected byte[] value
null in case
an input stream for lazy retrieval has been provided and retrieval has not
occurred yet.protected java.io.InputStream stream
null.public ADEPT2UDTValue(java.lang.String userDefinedType,
byte[] value)
userDefinedType - The name of the user-defined type of the value.
the name of the user defined typevalue - The bytes representing the value of this
UDTValue. Please take care of the encoding.public ADEPT2UDTValue(java.lang.String userDefinedType,
java.io.InputStream stream)
userDefinedType - The name of the user-defined type of the value. the
name of the user defined typestream - The input stream containing the value of this
UDTValue. Please take care of the encoding. The
stream will be closed after the creation.public ADEPT2UDTValue(java.lang.String userDefinedType,
java.io.InputStream stream,
boolean eager)
userDefinedType - The name of the user-defined type of the value. the
name of the user defined typestream - The input stream containing the value of this
UDTValue. Please take care of the encoding.eager - Whether the data should be read from the stream now or lazily.public ADEPT2UDTValue(java.lang.String userDefinedType,
java.io.InputStream stream,
int length)
userDefinedType - The name of the user-defined type of the value. the
name of the user defined typestream - The input stream containing the value of this
UDTValue. Please take care of the encoding. The
stream will not be closed after the creation.length - The number of bytes to be read from the designated input
stream.java.lang.IllegalArgumentException - If the designated number of bytes cannot
be read from the stream, an IllegalArgumentException
will be thrown.public java.lang.String getUserDefinedType()
UDTValuegetUserDefinedType in interface UDTValuepublic java.io.InputStream getValueAsStream()
UDTValueInputStream of this user-defined data
type.getValueAsStream in interface UDTValueInputStream.public byte[] getValueAsArray()
UDTValuegetValueAsArray in interface UDTValuepublic java.lang.String toString()
toString in class java.lang.Objectprotected void readStream()
public boolean equals(java.lang.Object obj)
equals in class java.lang.Objectpublic int hashCode()
hashCode in class java.lang.Objectprotected void finalize()
throws java.io.IOException
finalize in class java.lang.Objectjava.io.IOException