public abstract class Memo
extends java.lang.Object
The memo contains optional extra information. It is the responsibility of the client to interpret this value. Memos can be one of the following types:
MEMO_NONE: Empty memo.MEMO_TEXT: A string up to 28-bytes long.MEMO_ID: A 64 bit unsigned integer.MEMO_HASH: A 32 byte hash.MEMO_RETURN: A 32 byte hash intended to be interpreted as the hash of the transaction the sender is refunding.Use static methods to generate any of above types.
Transaction| Constructor and Description |
|---|
Memo() |
| Modifier and Type | Method and Description |
|---|---|
static MemoHash |
hash(byte[] bytes)
Creates new
MemoHash instance from byte array. |
static MemoHash |
hash(java.lang.String hexString)
Creates new
MemoHash instance from hex-encoded string |
static MemoId |
id(long id)
Creates new
MemoId instance. |
static MemoNone |
none()
Creates new MemoNone instance.
|
static MemoReturnHash |
returnHash(byte[] bytes)
Creates new
MemoReturnHash instance from byte array. |
static MemoReturnHash |
returnHash(java.lang.String hexString)
Creates new
MemoReturnHash instance from hex-encoded string. |
static MemoText |
text(java.lang.String text)
Creates new
MemoText instance. |
public static MemoNone none()
public static MemoText text(java.lang.String text)
MemoText instance.text - public static MemoHash hash(byte[] bytes)
MemoHash instance from byte array.bytes - public static MemoHash hash(java.lang.String hexString)
MemoHash instance from hex-encoded stringhexString - public static MemoReturnHash returnHash(byte[] bytes)
MemoReturnHash instance from byte array.bytes - public static MemoReturnHash returnHash(java.lang.String hexString)
MemoReturnHash instance from hex-encoded string.hexString -