public static final class LightningApi.Invoice extends com.google.protobuf.GeneratedMessageV3 implements LightningApi.InvoiceOrBuilder
lnrpc.Invoice
Modifier and Type | Class and Description |
---|---|
static class |
LightningApi.Invoice.Builder
Protobuf type
lnrpc.Invoice |
com.google.protobuf.GeneratedMessageV3.BuilderParent, com.google.protobuf.GeneratedMessageV3.ExtendableBuilder<MessageType extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage,BuilderType extends com.google.protobuf.GeneratedMessageV3.ExtendableBuilder<MessageType,BuilderType>>, com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageType extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage>, com.google.protobuf.GeneratedMessageV3.ExtendableMessageOrBuilder<MessageType extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage>, com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
Modifier and Type | Field and Description |
---|---|
static int |
ADD_INDEX_FIELD_NUMBER |
static int |
AMT_PAID_FIELD_NUMBER |
static int |
AMT_PAID_MSAT_FIELD_NUMBER |
static int |
AMT_PAID_SAT_FIELD_NUMBER |
static int |
CLTV_EXPIRY_FIELD_NUMBER |
static int |
CREATION_DATE_FIELD_NUMBER |
static int |
DESCRIPTION_HASH_FIELD_NUMBER |
static int |
EXPIRY_FIELD_NUMBER |
static int |
FALLBACK_ADDR_FIELD_NUMBER |
static int |
MEMO_FIELD_NUMBER |
static int |
PAYMENT_REQUEST_FIELD_NUMBER |
static int |
PRIVATE_FIELD_NUMBER |
static int |
R_HASH_FIELD_NUMBER |
static int |
R_PREIMAGE_FIELD_NUMBER |
static int |
RECEIPT_FIELD_NUMBER |
static int |
ROUTE_HINTS_FIELD_NUMBER |
static int |
SETTLE_DATE_FIELD_NUMBER |
static int |
SETTLE_INDEX_FIELD_NUMBER |
static int |
SETTLED_FIELD_NUMBER |
static int |
VALUE_FIELD_NUMBER |
Modifier and Type | Method and Description |
---|---|
boolean |
equals(java.lang.Object obj) |
long |
getAddIndex()
The "add" index of this invoice.
|
long |
getAmtPaid()
Deprecated.
|
long |
getAmtPaidMsat()
The amount that was accepted for this invoice, in millisatoshis.
|
long |
getAmtPaidSat()
The amount that was accepted for this invoice, in satoshis.
|
long |
getCltvExpiry()
/ Delta to use for the time-lock of the CLTV extended to the final hop.
|
long |
getCreationDate()
/ When this invoice was created
|
static LightningApi.Invoice |
getDefaultInstance() |
LightningApi.Invoice |
getDefaultInstanceForType() |
com.google.protobuf.ByteString |
getDescriptionHash()
Hash (SHA-256) of a description of the payment.
|
static com.google.protobuf.Descriptors.Descriptor |
getDescriptor() |
long |
getExpiry()
/ Payment request expiry time in seconds.
|
java.lang.String |
getFallbackAddr()
/ Fallback on-chain address.
|
com.google.protobuf.ByteString |
getFallbackAddrBytes()
/ Fallback on-chain address.
|
java.lang.String |
getMemo()
An optional memo to attach along with the invoice.
|
com.google.protobuf.ByteString |
getMemoBytes()
An optional memo to attach along with the invoice.
|
com.google.protobuf.Parser<LightningApi.Invoice> |
getParserForType() |
java.lang.String |
getPaymentRequest()
A bare-bones invoice for a payment within the Lightning Network.
|
com.google.protobuf.ByteString |
getPaymentRequestBytes()
A bare-bones invoice for a payment within the Lightning Network.
|
boolean |
getPrivate()
/ Whether this invoice should include routing hints for private channels.
|
com.google.protobuf.ByteString |
getReceipt()
/ An optional cryptographic receipt of payment
|
com.google.protobuf.ByteString |
getRHash()
/ The hash of the preimage
|
LightningApi.RouteHint |
getRouteHints(int index)
Route hints that can each be individually used to assist in reaching the
invoice's destination.
|
int |
getRouteHintsCount()
Route hints that can each be individually used to assist in reaching the
invoice's destination.
|
java.util.List<LightningApi.RouteHint> |
getRouteHintsList()
Route hints that can each be individually used to assist in reaching the
invoice's destination.
|
LightningApi.RouteHintOrBuilder |
getRouteHintsOrBuilder(int index)
Route hints that can each be individually used to assist in reaching the
invoice's destination.
|
java.util.List<? extends LightningApi.RouteHintOrBuilder> |
getRouteHintsOrBuilderList()
Route hints that can each be individually used to assist in reaching the
invoice's destination.
|
com.google.protobuf.ByteString |
getRPreimage()
The hex-encoded preimage (32 byte) which will allow settling an incoming
HTLC payable to this preimage
|
int |
getSerializedSize() |
boolean |
getSettled()
/ Whether this invoice has been fulfilled
|
long |
getSettleDate()
/ When this invoice was settled
|
long |
getSettleIndex()
The "settle" index of this invoice.
|
com.google.protobuf.UnknownFieldSet |
getUnknownFields() |
long |
getValue()
/ The value of this invoice in satoshis
|
int |
hashCode() |
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable |
internalGetFieldAccessorTable() |
boolean |
isInitialized() |
static LightningApi.Invoice.Builder |
newBuilder() |
static LightningApi.Invoice.Builder |
newBuilder(LightningApi.Invoice prototype) |
LightningApi.Invoice.Builder |
newBuilderForType() |
protected LightningApi.Invoice.Builder |
newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) |
static LightningApi.Invoice |
parseDelimitedFrom(java.io.InputStream input) |
static LightningApi.Invoice |
parseDelimitedFrom(java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static LightningApi.Invoice |
parseFrom(byte[] data) |
static LightningApi.Invoice |
parseFrom(byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static LightningApi.Invoice |
parseFrom(java.nio.ByteBuffer data) |
static LightningApi.Invoice |
parseFrom(java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static LightningApi.Invoice |
parseFrom(com.google.protobuf.ByteString data) |
static LightningApi.Invoice |
parseFrom(com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static LightningApi.Invoice |
parseFrom(com.google.protobuf.CodedInputStream input) |
static LightningApi.Invoice |
parseFrom(com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static LightningApi.Invoice |
parseFrom(java.io.InputStream input) |
static LightningApi.Invoice |
parseFrom(java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static com.google.protobuf.Parser<LightningApi.Invoice> |
parser() |
LightningApi.Invoice.Builder |
toBuilder() |
void |
writeTo(com.google.protobuf.CodedOutputStream output) |
computeStringSize, computeStringSizeNoTag, getAllFields, getDescriptorForType, getField, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, hasField, hasOneof, internalGetMapField, makeExtensionsImmutable, newBuilderForType, parseDelimitedWithIOException, parseDelimitedWithIOException, parseUnknownField, parseUnknownFieldProto3, parseWithIOException, parseWithIOException, parseWithIOException, parseWithIOException, serializeBooleanMapTo, serializeIntegerMapTo, serializeLongMapTo, serializeStringMapTo, writeReplace, writeString, writeStringNoTag
findInitializationErrors, getInitializationErrorString, hashBoolean, hashEnum, hashEnumList, hashFields, hashLong, toString
addAll, addAll, checkByteStringIsUtf8, toByteArray, toByteString, writeDelimitedTo, writeTo
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
public static final int MEMO_FIELD_NUMBER
public static final int RECEIPT_FIELD_NUMBER
public static final int R_PREIMAGE_FIELD_NUMBER
public static final int R_HASH_FIELD_NUMBER
public static final int VALUE_FIELD_NUMBER
public static final int SETTLED_FIELD_NUMBER
public static final int CREATION_DATE_FIELD_NUMBER
public static final int SETTLE_DATE_FIELD_NUMBER
public static final int PAYMENT_REQUEST_FIELD_NUMBER
public static final int DESCRIPTION_HASH_FIELD_NUMBER
public static final int EXPIRY_FIELD_NUMBER
public static final int FALLBACK_ADDR_FIELD_NUMBER
public static final int CLTV_EXPIRY_FIELD_NUMBER
public static final int ROUTE_HINTS_FIELD_NUMBER
public static final int PRIVATE_FIELD_NUMBER
public static final int ADD_INDEX_FIELD_NUMBER
public static final int SETTLE_INDEX_FIELD_NUMBER
public static final int AMT_PAID_FIELD_NUMBER
public static final int AMT_PAID_SAT_FIELD_NUMBER
public static final int AMT_PAID_MSAT_FIELD_NUMBER
public final com.google.protobuf.UnknownFieldSet getUnknownFields()
getUnknownFields
in interface com.google.protobuf.MessageOrBuilder
getUnknownFields
in class com.google.protobuf.GeneratedMessageV3
public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
internalGetFieldAccessorTable
in class com.google.protobuf.GeneratedMessageV3
public java.lang.String getMemo()
An optional memo to attach along with the invoice. Used for record keeping purposes for the invoice's creator, and will also be set in the description field of the encoded payment request if the description_hash field is not being used.
string memo = 1[json_name = "memo"];
getMemo
in interface LightningApi.InvoiceOrBuilder
public com.google.protobuf.ByteString getMemoBytes()
An optional memo to attach along with the invoice. Used for record keeping purposes for the invoice's creator, and will also be set in the description field of the encoded payment request if the description_hash field is not being used.
string memo = 1[json_name = "memo"];
getMemoBytes
in interface LightningApi.InvoiceOrBuilder
public com.google.protobuf.ByteString getReceipt()
/ An optional cryptographic receipt of payment
bytes receipt = 2[json_name = "receipt"];
getReceipt
in interface LightningApi.InvoiceOrBuilder
public com.google.protobuf.ByteString getRPreimage()
The hex-encoded preimage (32 byte) which will allow settling an incoming HTLC payable to this preimage
bytes r_preimage = 3[json_name = "r_preimage"];
getRPreimage
in interface LightningApi.InvoiceOrBuilder
public com.google.protobuf.ByteString getRHash()
/ The hash of the preimage
bytes r_hash = 4[json_name = "r_hash"];
getRHash
in interface LightningApi.InvoiceOrBuilder
public long getValue()
/ The value of this invoice in satoshis
int64 value = 5[json_name = "value"];
getValue
in interface LightningApi.InvoiceOrBuilder
public boolean getSettled()
/ Whether this invoice has been fulfilled
bool settled = 6[json_name = "settled"];
getSettled
in interface LightningApi.InvoiceOrBuilder
public long getCreationDate()
/ When this invoice was created
int64 creation_date = 7[json_name = "creation_date"];
getCreationDate
in interface LightningApi.InvoiceOrBuilder
public long getSettleDate()
/ When this invoice was settled
int64 settle_date = 8[json_name = "settle_date"];
getSettleDate
in interface LightningApi.InvoiceOrBuilder
public java.lang.String getPaymentRequest()
A bare-bones invoice for a payment within the Lightning Network. With the details of the invoice, the sender has all the data necessary to send a payment to the recipient.
string payment_request = 9[json_name = "payment_request"];
getPaymentRequest
in interface LightningApi.InvoiceOrBuilder
public com.google.protobuf.ByteString getPaymentRequestBytes()
A bare-bones invoice for a payment within the Lightning Network. With the details of the invoice, the sender has all the data necessary to send a payment to the recipient.
string payment_request = 9[json_name = "payment_request"];
getPaymentRequestBytes
in interface LightningApi.InvoiceOrBuilder
public com.google.protobuf.ByteString getDescriptionHash()
Hash (SHA-256) of a description of the payment. Used if the description of payment (memo) is too long to naturally fit within the description field of an encoded payment request.
bytes description_hash = 10[json_name = "description_hash"];
getDescriptionHash
in interface LightningApi.InvoiceOrBuilder
public long getExpiry()
/ Payment request expiry time in seconds. Default is 3600 (1 hour).
int64 expiry = 11[json_name = "expiry"];
getExpiry
in interface LightningApi.InvoiceOrBuilder
public java.lang.String getFallbackAddr()
/ Fallback on-chain address.
string fallback_addr = 12[json_name = "fallback_addr"];
getFallbackAddr
in interface LightningApi.InvoiceOrBuilder
public com.google.protobuf.ByteString getFallbackAddrBytes()
/ Fallback on-chain address.
string fallback_addr = 12[json_name = "fallback_addr"];
getFallbackAddrBytes
in interface LightningApi.InvoiceOrBuilder
public long getCltvExpiry()
/ Delta to use for the time-lock of the CLTV extended to the final hop.
uint64 cltv_expiry = 13[json_name = "cltv_expiry"];
getCltvExpiry
in interface LightningApi.InvoiceOrBuilder
public java.util.List<LightningApi.RouteHint> getRouteHintsList()
Route hints that can each be individually used to assist in reaching the invoice's destination.
repeated .lnrpc.RouteHint route_hints = 14[json_name = "route_hints"];
getRouteHintsList
in interface LightningApi.InvoiceOrBuilder
public java.util.List<? extends LightningApi.RouteHintOrBuilder> getRouteHintsOrBuilderList()
Route hints that can each be individually used to assist in reaching the invoice's destination.
repeated .lnrpc.RouteHint route_hints = 14[json_name = "route_hints"];
getRouteHintsOrBuilderList
in interface LightningApi.InvoiceOrBuilder
public int getRouteHintsCount()
Route hints that can each be individually used to assist in reaching the invoice's destination.
repeated .lnrpc.RouteHint route_hints = 14[json_name = "route_hints"];
getRouteHintsCount
in interface LightningApi.InvoiceOrBuilder
public LightningApi.RouteHint getRouteHints(int index)
Route hints that can each be individually used to assist in reaching the invoice's destination.
repeated .lnrpc.RouteHint route_hints = 14[json_name = "route_hints"];
getRouteHints
in interface LightningApi.InvoiceOrBuilder
public LightningApi.RouteHintOrBuilder getRouteHintsOrBuilder(int index)
Route hints that can each be individually used to assist in reaching the invoice's destination.
repeated .lnrpc.RouteHint route_hints = 14[json_name = "route_hints"];
getRouteHintsOrBuilder
in interface LightningApi.InvoiceOrBuilder
public boolean getPrivate()
/ Whether this invoice should include routing hints for private channels.
bool private = 15[json_name = "private"];
getPrivate
in interface LightningApi.InvoiceOrBuilder
public long getAddIndex()
The "add" index of this invoice. Each newly created invoice will increment this index making it monotonically increasing. Callers to the SubscribeInvoices call can use this to instantly get notified of all added invoices with an add_index greater than this one.
uint64 add_index = 16[json_name = "add_index"];
getAddIndex
in interface LightningApi.InvoiceOrBuilder
public long getSettleIndex()
The "settle" index of this invoice. Each newly settled invoice will increment this index making it monotonically increasing. Callers to the SubscribeInvoices call can use this to instantly get notified of all settled invoices with an settle_index greater than this one.
uint64 settle_index = 17[json_name = "settle_index"];
getSettleIndex
in interface LightningApi.InvoiceOrBuilder
@Deprecated public long getAmtPaid()
/ Deprecated, use amt_paid_sat or amt_paid_msat.
int64 amt_paid = 18[json_name = "amt_paid", deprecated = true];
getAmtPaid
in interface LightningApi.InvoiceOrBuilder
public long getAmtPaidSat()
The amount that was accepted for this invoice, in satoshis. This will ONLY be set if this invoice has been settled. We provide this field as if the invoice was created with a zero value, then we need to record what amount was ultimately accepted. Additionally, it's possible that the sender paid MORE that was specified in the original invoice. So we'll record that here as well.
int64 amt_paid_sat = 19[json_name = "amt_paid_sat"];
getAmtPaidSat
in interface LightningApi.InvoiceOrBuilder
public long getAmtPaidMsat()
The amount that was accepted for this invoice, in millisatoshis. This will ONLY be set if this invoice has been settled. We provide this field as if the invoice was created with a zero value, then we need to record what amount was ultimately accepted. Additionally, it's possible that the sender paid MORE that was specified in the original invoice. So we'll record that here as well.
int64 amt_paid_msat = 20[json_name = "amt_paid_msat"];
getAmtPaidMsat
in interface LightningApi.InvoiceOrBuilder
public final boolean isInitialized()
isInitialized
in interface com.google.protobuf.MessageLiteOrBuilder
isInitialized
in class com.google.protobuf.GeneratedMessageV3
public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException
writeTo
in interface com.google.protobuf.MessageLite
writeTo
in class com.google.protobuf.GeneratedMessageV3
java.io.IOException
public int getSerializedSize()
getSerializedSize
in interface com.google.protobuf.MessageLite
getSerializedSize
in class com.google.protobuf.GeneratedMessageV3
public boolean equals(java.lang.Object obj)
equals
in interface com.google.protobuf.Message
equals
in class com.google.protobuf.AbstractMessage
public int hashCode()
hashCode
in interface com.google.protobuf.Message
hashCode
in class com.google.protobuf.AbstractMessage
public static LightningApi.Invoice parseFrom(java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferException
public static LightningApi.Invoice parseFrom(java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferException
public static LightningApi.Invoice parseFrom(com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferException
public static LightningApi.Invoice parseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferException
public static LightningApi.Invoice parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferException
public static LightningApi.Invoice parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferException
public static LightningApi.Invoice parseFrom(java.io.InputStream input) throws java.io.IOException
java.io.IOException
public static LightningApi.Invoice parseFrom(java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException
java.io.IOException
public static LightningApi.Invoice parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException
java.io.IOException
public static LightningApi.Invoice parseDelimitedFrom(java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException
java.io.IOException
public static LightningApi.Invoice parseFrom(com.google.protobuf.CodedInputStream input) throws java.io.IOException
java.io.IOException
public static LightningApi.Invoice parseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException
java.io.IOException
public LightningApi.Invoice.Builder newBuilderForType()
newBuilderForType
in interface com.google.protobuf.Message
newBuilderForType
in interface com.google.protobuf.MessageLite
public static LightningApi.Invoice.Builder newBuilder()
public static LightningApi.Invoice.Builder newBuilder(LightningApi.Invoice prototype)
public LightningApi.Invoice.Builder toBuilder()
toBuilder
in interface com.google.protobuf.Message
toBuilder
in interface com.google.protobuf.MessageLite
protected LightningApi.Invoice.Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)
newBuilderForType
in class com.google.protobuf.GeneratedMessageV3
public static LightningApi.Invoice getDefaultInstance()
public static com.google.protobuf.Parser<LightningApi.Invoice> parser()
public com.google.protobuf.Parser<LightningApi.Invoice> getParserForType()
getParserForType
in interface com.google.protobuf.Message
getParserForType
in interface com.google.protobuf.MessageLite
getParserForType
in class com.google.protobuf.GeneratedMessageV3
public LightningApi.Invoice getDefaultInstanceForType()
getDefaultInstanceForType
in interface com.google.protobuf.MessageLiteOrBuilder
getDefaultInstanceForType
in interface com.google.protobuf.MessageOrBuilder