public class NumericTextFieldAdapter extends DefaultFieldAdapter
| Constructor and Description |
|---|
NumericTextFieldAdapter() |
| Modifier and Type | Method and Description |
|---|---|
BigInteger |
getBigInteger(byte[] buf,
int offset,
int length,
int startBit,
int stopBit)
Gets the field value as a Java BigInteger.
|
byte |
getByte(byte[] buf,
int offset,
int length,
int startBit,
int stopBit)
Gets the field value as a Java byte.
|
double |
getDouble(byte[] buf,
int offset,
int length,
int startBit,
int stopBit)
Gets the field value as a Java double.
|
float |
getFloat(byte[] buf,
int offset,
int length,
int startBit,
int stopBit)
Gets the field value as a Java float.
|
int |
getInt(byte[] buf,
int offset,
int length,
int startBit,
int stopBit)
Gets the field value as a Java int.
|
long |
getLong(byte[] buf,
int offset,
int length,
int startBit,
int stopBit)
Gets the field value as a Java long.
|
short |
getShort(byte[] buf,
int offset,
int length,
int startBit,
int stopBit)
Gets the field value as a Java short.
|
void |
setBigInteger(BigInteger value,
int offset,
int length,
ByteBuffer buffer,
boolean isRightJustified)
Sets the field value as a Java BigInteger.
|
void |
setByte(byte value,
int offset,
int length,
ByteBuffer buffer,
boolean isRightJustified)
Sets the field value as a Java byte.
|
void |
setDouble(double value,
int offset,
int length,
ByteBuffer buffer,
boolean isRightJustified)
Sets the field value as a Java double.
|
void |
setFloat(float value,
int offset,
int length,
ByteBuffer buffer,
boolean isRightJustified)
Sets the field value as a Java float.
|
void |
setInt(int value,
int offset,
int length,
ByteBuffer buffer,
boolean isRightJustified)
Sets the field value as a Java int.
|
void |
setLong(long value,
int offset,
int length,
ByteBuffer buffer,
boolean isRightJustified)
Sets the field value as a Java long.
|
void |
setShort(short value,
int offset,
int length,
ByteBuffer buffer,
boolean isRightJustified)
Sets the field value as a Java short.
|
public byte getByte(byte[] buf,
int offset,
int length,
int startBit,
int stopBit)
FieldAdaptergetByte in interface FieldAdaptergetByte in class DefaultFieldAdapterbuf - the byte array containing the fieldoffset - the field offsetlength - the length of the field datastartBit - the start bit, for bit fieldsstopBit - the stop bit, for bit fieldspublic short getShort(byte[] buf,
int offset,
int length,
int startBit,
int stopBit)
FieldAdaptergetShort in interface FieldAdaptergetShort in class DefaultFieldAdapterbuf - the byte array containing the fieldoffset - the field offsetlength - the length of the field datastartBit - the start bit, for bit fieldsstopBit - the stop bit, for bit fieldspublic int getInt(byte[] buf,
int offset,
int length,
int startBit,
int stopBit)
FieldAdaptergetInt in interface FieldAdaptergetInt in class DefaultFieldAdapterbuf - the byte array containing the fieldoffset - the field offsetlength - the length of the field datastartBit - the start bit, for bit fieldsstopBit - the stop bit, for bit fieldspublic long getLong(byte[] buf,
int offset,
int length,
int startBit,
int stopBit)
FieldAdaptergetLong in interface FieldAdaptergetLong in class DefaultFieldAdapterbuf - the byte array containing the fieldoffset - the field offsetlength - the length of the field datastartBit - the start bit, for bit fieldsstopBit - the stop bit, for bit fieldspublic float getFloat(byte[] buf,
int offset,
int length,
int startBit,
int stopBit)
FieldAdaptergetFloat in interface FieldAdaptergetFloat in class DefaultFieldAdapterbuf - the byte array containing the fieldoffset - the field offsetlength - the length of the field datastartBit - the start bit, for bit fieldsstopBit - the stop bit, for bit fieldspublic double getDouble(byte[] buf,
int offset,
int length,
int startBit,
int stopBit)
FieldAdaptergetDouble in interface FieldAdaptergetDouble in class DefaultFieldAdapterbuf - the byte array containing the fieldoffset - the field offsetlength - the length of the field datastartBit - the start bit, for bit fieldsstopBit - the stop bit, for bit fieldspublic BigInteger getBigInteger(byte[] buf, int offset, int length, int startBit, int stopBit)
FieldAdaptergetBigInteger in interface FieldAdaptergetBigInteger in class DefaultFieldAdapterbuf - the byte array containing the fieldoffset - the field offsetlength - the length of the field datastartBit - the start bit, for bit fieldsstopBit - the stop bit, for bit fieldsBigIntegerpublic void setByte(byte value,
int offset,
int length,
ByteBuffer buffer,
boolean isRightJustified)
FieldAdaptersetByte in interface FieldAdaptersetByte in class DefaultFieldAdaptervalue - the field valueoffset - the field offsetlength - the length of the valuebuffer - the byte buffer into which to set the valueisRightJustified - true, if the string value should be right-justifiedpublic void setShort(short value,
int offset,
int length,
ByteBuffer buffer,
boolean isRightJustified)
FieldAdaptersetShort in interface FieldAdaptersetShort in class DefaultFieldAdaptervalue - the field valueoffset - the field offsetlength - the length of the valuebuffer - the byte buffer into which to set the valueisRightJustified - true, if the string value should be right-justifiedpublic void setInt(int value,
int offset,
int length,
ByteBuffer buffer,
boolean isRightJustified)
FieldAdaptersetInt in interface FieldAdaptersetInt in class DefaultFieldAdaptervalue - the field valueoffset - the field offsetlength - the length of the valuebuffer - the byte buffer into which to set the valueisRightJustified - true, if the string value should be right-justifiedpublic void setLong(long value,
int offset,
int length,
ByteBuffer buffer,
boolean isRightJustified)
FieldAdaptersetLong in interface FieldAdaptersetLong in class DefaultFieldAdaptervalue - the field valueoffset - the field offsetlength - the length of the valuebuffer - the byte buffer into which to set the valueisRightJustified - true, if the string value should be right-justifiedpublic void setFloat(float value,
int offset,
int length,
ByteBuffer buffer,
boolean isRightJustified)
FieldAdaptersetFloat in interface FieldAdaptersetFloat in class DefaultFieldAdaptervalue - the field valueoffset - the field offsetlength - the length of the valuebuffer - the byte buffer into which to set the valueisRightJustified - true, if the string value should be right-justifiedpublic void setDouble(double value,
int offset,
int length,
ByteBuffer buffer,
boolean isRightJustified)
FieldAdaptersetDouble in interface FieldAdaptersetDouble in class DefaultFieldAdaptervalue - the field valueoffset - the field offsetlength - the length of the valuebuffer - the byte buffer into which to set the valueisRightJustified - true, if the string value should be right-justifiedpublic void setBigInteger(BigInteger value, int offset, int length, ByteBuffer buffer, boolean isRightJustified)
FieldAdaptersetBigInteger in interface FieldAdaptersetBigInteger in class DefaultFieldAdaptervalue - the field valueoffset - the field offsetlength - the length of the valuebuffer - the byte buffer into which to set the valueisRightJustified - true, if the string value should be right-justifiedCopyright © 2010–2017 Planetary Data System. All rights reserved.