Class FormatableLongHolder
java.lang.Object
org.apache.derby.iapi.services.io.FormatableLongHolder
- All Implemented Interfaces:
Externalizable
,Serializable
,Formatable
,TypedFormat
A formatable holder for an long.
- See Also:
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionNiladic constructor for formatableFormatableLongHolder
(long theLong) Construct a FormatableLongHolder using the input integer. -
Method Summary
Modifier and TypeMethodDescriptionstatic FormatableLongHolder[]
getFormatableLongHolders
(long[] theLongs) Create and return an array of FormatableLongHolders given an array of ints.long
getLong()
Get the held int.int
Get the formatID which corresponds to this class.void
Read this formatable from a stream of stored objects.void
setLong
(int theLong) Set the held long to the input int.void
Write this formatable out
-
Field Details
-
theLong
private long theLong
-
-
Constructor Details
-
FormatableLongHolder
public FormatableLongHolder()Niladic constructor for formatable -
FormatableLongHolder
public FormatableLongHolder(long theLong) Construct a FormatableLongHolder using the input integer.- Parameters:
theLong
- the long to hold
-
-
Method Details
-
setLong
public void setLong(int theLong) Set the held long to the input int.- Parameters:
theLong
- the int to hold
-
getLong
public long getLong()Get the held int.- Returns:
- The held int.
-
getFormatableLongHolders
Create and return an array of FormatableLongHolders given an array of ints.- Parameters:
theLongs
- The array of longs- Returns:
- An array of FormatableLongHolders
-
writeExternal
Write this formatable out- Specified by:
writeExternal
in interfaceExternalizable
- Parameters:
out
- write bytes here- Throws:
IOException
- thrown on error
-
readExternal
Read this formatable from a stream of stored objects.- Specified by:
readExternal
in interfaceExternalizable
- Parameters:
in
- read this.- Throws:
IOException
- thrown on error
-
getTypeFormatId
public int getTypeFormatId()Get the formatID which corresponds to this class.- Specified by:
getTypeFormatId
in interfaceTypedFormat
- Returns:
- the formatID of this class
-