public class FromHostPrimitiveResult<J> extends Object
| Constructor and Description |
|---|
FromHostPrimitiveResult(J value) |
FromHostPrimitiveResult(String message,
byte[] hostData,
int start,
int bytesLen) |
FromHostPrimitiveResult(String message,
byte[] hostData,
int start,
int curPos,
int bytesLen) |
| Modifier and Type | Method and Description |
|---|---|
protected static String |
formatMessage(String message,
byte[] hostData,
int start,
int curPos,
int bytesLen)
Format the data to make it easy to locate the error in the incoming byte
stream.
|
String |
getErrorMessage() |
J |
getValue() |
boolean |
isSuccess() |
public FromHostPrimitiveResult(J value)
public FromHostPrimitiveResult(String message, byte[] hostData, int start, int bytesLen)
public FromHostPrimitiveResult(String message, byte[] hostData, int start, int curPos, int bytesLen)
public boolean isSuccess()
public String getErrorMessage()
public J getValue()
protected static String formatMessage(String message, byte[] hostData, int start, int curPos, int bytesLen)
message - the text part of the message (explains the error)hostData - the incoming host data streamstart - the starting position of the primitive type value in the
byte streamcurPos - the position of the error itself (might be within the type
value)bytesLen - the size of the primitive typeCopyright © 2021 LegSem. All rights reserved.