lnrpc.ChannelCloseSummary.scala Maven / Gradle / Ivy
The newest version!
// Generated by the Scala Plugin for the Protocol Buffer Compiler.
// Do not edit!
//
// Protofile syntax: PROTO3
package lnrpc
import org.bitcoins.lnd.rpc.LndUtils._
/** @param channelPoint
* The outpoint (txid:index) of the funding transaction.
* @param chanId
* The unique channel ID for the channel.
* @param chainHash
* The hash of the genesis block that this channel resides within.
* @param closingTxHash
* The txid of the transaction which ultimately closed this channel.
* @param remotePubkey
* Public key of the remote peer that we formerly had a channel with.
* @param capacity
* Total capacity of the channel.
* @param closeHeight
* Height at which the funding transaction was spent.
* @param settledBalance
* Settled balance at the time of channel closure
* @param timeLockedBalance
* The sum of all the time-locked outputs at the time of channel closure
* @param closeType
* Details on how the channel was closed.
* @param openInitiator
*
* Open initiator is the party that initiated opening the channel. Note that
* this value may be unknown if the channel was closed before we migrated to
* store open channel information after close.
* @param closeInitiator
*
* Close initiator indicates which party initiated the close. This value will
* be unknown for channels that were cooperatively closed before we started
* tracking cooperative close initiators. Note that this indicates which party
* initiated a close, and it is possible for both to initiate cooperative or
* force closes, although only one party's close will be confirmed on chain.
* @param aliasScids
*
* This lists out the set of alias short channel ids that existed for the
* closed channel. This may be empty.
* @param zeroConfConfirmedScid
* The confirmed SCID for a zero-conf channel.
*/
@SerialVersionUID(0L)
final case class ChannelCloseSummary(
channelPoint: _root_.scala.Predef.String = "",
chanId: org.bitcoins.core.number.UInt64 = lnrpc.ChannelCloseSummary._typemapper_chanId.toCustom(0L),
chainHash: _root_.scala.Predef.String = "",
closingTxHash: _root_.scala.Predef.String = "",
remotePubkey: _root_.scala.Predef.String = "",
capacity: _root_.scala.Long = 0L,
closeHeight: org.bitcoins.core.number.UInt32 = lnrpc.ChannelCloseSummary._typemapper_closeHeight.toCustom(0),
settledBalance: _root_.scala.Long = 0L,
timeLockedBalance: _root_.scala.Long = 0L,
closeType: lnrpc.ChannelCloseSummary.ClosureType = lnrpc.ChannelCloseSummary.ClosureType.COOPERATIVE_CLOSE,
openInitiator: lnrpc.Initiator = lnrpc.Initiator.INITIATOR_UNKNOWN,
closeInitiator: lnrpc.Initiator = lnrpc.Initiator.INITIATOR_UNKNOWN,
resolutions: _root_.scala.Seq[lnrpc.Resolution] = _root_.scala.Seq.empty,
aliasScids: _root_.scala.Seq[org.bitcoins.core.number.UInt64] = _root_.scala.Seq.empty,
zeroConfConfirmedScid: org.bitcoins.core.number.UInt64 = lnrpc.ChannelCloseSummary._typemapper_zeroConfConfirmedScid.toCustom(0L),
unknownFields: _root_.scalapb.UnknownFieldSet = _root_.scalapb.UnknownFieldSet.empty
) extends scalapb.GeneratedMessage with scalapb.lenses.Updatable[ChannelCloseSummary] {
private[this] def aliasScidsSerializedSize = {
if (__aliasScidsSerializedSizeField == 0) __aliasScidsSerializedSizeField = {
var __s: _root_.scala.Int = 0
aliasScids.foreach(__i => __s += _root_.com.google.protobuf.CodedOutputStream.computeUInt64SizeNoTag(lnrpc.ChannelCloseSummary._typemapper_aliasScids.toBase(__i)))
__s
}
__aliasScidsSerializedSizeField
}
@transient private[this] var __aliasScidsSerializedSizeField: _root_.scala.Int = 0
@transient
private[this] var __serializedSizeMemoized: _root_.scala.Int = 0
private[this] def __computeSerializedSize(): _root_.scala.Int = {
var __size = 0
{
val __value = channelPoint
if (!__value.isEmpty) {
__size += _root_.com.google.protobuf.CodedOutputStream.computeStringSize(1, __value)
}
};
{
val __value = lnrpc.ChannelCloseSummary._typemapper_chanId.toBase(chanId)
if (__value != 0L) {
__size += _root_.com.google.protobuf.CodedOutputStream.computeUInt64Size(2, __value)
}
};
{
val __value = chainHash
if (!__value.isEmpty) {
__size += _root_.com.google.protobuf.CodedOutputStream.computeStringSize(3, __value)
}
};
{
val __value = closingTxHash
if (!__value.isEmpty) {
__size += _root_.com.google.protobuf.CodedOutputStream.computeStringSize(4, __value)
}
};
{
val __value = remotePubkey
if (!__value.isEmpty) {
__size += _root_.com.google.protobuf.CodedOutputStream.computeStringSize(5, __value)
}
};
{
val __value = capacity
if (__value != 0L) {
__size += _root_.com.google.protobuf.CodedOutputStream.computeInt64Size(6, __value)
}
};
{
val __value = lnrpc.ChannelCloseSummary._typemapper_closeHeight.toBase(closeHeight)
if (__value != 0) {
__size += _root_.com.google.protobuf.CodedOutputStream.computeUInt32Size(7, __value)
}
};
{
val __value = settledBalance
if (__value != 0L) {
__size += _root_.com.google.protobuf.CodedOutputStream.computeInt64Size(8, __value)
}
};
{
val __value = timeLockedBalance
if (__value != 0L) {
__size += _root_.com.google.protobuf.CodedOutputStream.computeInt64Size(9, __value)
}
};
{
val __value = closeType.value
if (__value != 0) {
__size += _root_.com.google.protobuf.CodedOutputStream.computeEnumSize(10, __value)
}
};
{
val __value = openInitiator.value
if (__value != 0) {
__size += _root_.com.google.protobuf.CodedOutputStream.computeEnumSize(11, __value)
}
};
{
val __value = closeInitiator.value
if (__value != 0) {
__size += _root_.com.google.protobuf.CodedOutputStream.computeEnumSize(12, __value)
}
};
resolutions.foreach { __item =>
val __value = __item
__size += 1 + _root_.com.google.protobuf.CodedOutputStream.computeUInt32SizeNoTag(__value.serializedSize) + __value.serializedSize
}
if (aliasScids.nonEmpty) {
val __localsize = aliasScidsSerializedSize
__size += 1 + _root_.com.google.protobuf.CodedOutputStream.computeUInt32SizeNoTag(__localsize) + __localsize
}
{
val __value = lnrpc.ChannelCloseSummary._typemapper_zeroConfConfirmedScid.toBase(zeroConfConfirmedScid)
if (__value != 0L) {
__size += _root_.com.google.protobuf.CodedOutputStream.computeUInt64Size(15, __value)
}
};
__size += unknownFields.serializedSize
__size
}
override def serializedSize: _root_.scala.Int = {
var __size = __serializedSizeMemoized
if (__size == 0) {
__size = __computeSerializedSize() + 1
__serializedSizeMemoized = __size
}
__size - 1
}
def writeTo(`_output__`: _root_.com.google.protobuf.CodedOutputStream): _root_.scala.Unit = {
{
val __v = channelPoint
if (!__v.isEmpty) {
_output__.writeString(1, __v)
}
};
{
val __v = lnrpc.ChannelCloseSummary._typemapper_chanId.toBase(chanId)
if (__v != 0L) {
_output__.writeUInt64(2, __v)
}
};
{
val __v = chainHash
if (!__v.isEmpty) {
_output__.writeString(3, __v)
}
};
{
val __v = closingTxHash
if (!__v.isEmpty) {
_output__.writeString(4, __v)
}
};
{
val __v = remotePubkey
if (!__v.isEmpty) {
_output__.writeString(5, __v)
}
};
{
val __v = capacity
if (__v != 0L) {
_output__.writeInt64(6, __v)
}
};
{
val __v = lnrpc.ChannelCloseSummary._typemapper_closeHeight.toBase(closeHeight)
if (__v != 0) {
_output__.writeUInt32(7, __v)
}
};
{
val __v = settledBalance
if (__v != 0L) {
_output__.writeInt64(8, __v)
}
};
{
val __v = timeLockedBalance
if (__v != 0L) {
_output__.writeInt64(9, __v)
}
};
{
val __v = closeType.value
if (__v != 0) {
_output__.writeEnum(10, __v)
}
};
{
val __v = openInitiator.value
if (__v != 0) {
_output__.writeEnum(11, __v)
}
};
{
val __v = closeInitiator.value
if (__v != 0) {
_output__.writeEnum(12, __v)
}
};
resolutions.foreach { __v =>
val __m = __v
_output__.writeTag(13, 2)
_output__.writeUInt32NoTag(__m.serializedSize)
__m.writeTo(_output__)
};
if (aliasScids.nonEmpty) {
_output__.writeTag(14, 2)
_output__.writeUInt32NoTag(aliasScidsSerializedSize)
aliasScids.foreach((_output__.writeUInt64NoTag _).compose(lnrpc.ChannelCloseSummary._typemapper_aliasScids.toBase))
};
{
val __v = lnrpc.ChannelCloseSummary._typemapper_zeroConfConfirmedScid.toBase(zeroConfConfirmedScid)
if (__v != 0L) {
_output__.writeUInt64(15, __v)
}
};
unknownFields.writeTo(_output__)
}
def withChannelPoint(__v: _root_.scala.Predef.String): ChannelCloseSummary = copy(channelPoint = __v)
def withChanId(__v: org.bitcoins.core.number.UInt64): ChannelCloseSummary = copy(chanId = __v)
def withChainHash(__v: _root_.scala.Predef.String): ChannelCloseSummary = copy(chainHash = __v)
def withClosingTxHash(__v: _root_.scala.Predef.String): ChannelCloseSummary = copy(closingTxHash = __v)
def withRemotePubkey(__v: _root_.scala.Predef.String): ChannelCloseSummary = copy(remotePubkey = __v)
def withCapacity(__v: _root_.scala.Long): ChannelCloseSummary = copy(capacity = __v)
def withCloseHeight(__v: org.bitcoins.core.number.UInt32): ChannelCloseSummary = copy(closeHeight = __v)
def withSettledBalance(__v: _root_.scala.Long): ChannelCloseSummary = copy(settledBalance = __v)
def withTimeLockedBalance(__v: _root_.scala.Long): ChannelCloseSummary = copy(timeLockedBalance = __v)
def withCloseType(__v: lnrpc.ChannelCloseSummary.ClosureType): ChannelCloseSummary = copy(closeType = __v)
def withOpenInitiator(__v: lnrpc.Initiator): ChannelCloseSummary = copy(openInitiator = __v)
def withCloseInitiator(__v: lnrpc.Initiator): ChannelCloseSummary = copy(closeInitiator = __v)
def clearResolutions = copy(resolutions = _root_.scala.Seq.empty)
def addResolutions(__vs: lnrpc.Resolution *): ChannelCloseSummary = addAllResolutions(__vs)
def addAllResolutions(__vs: Iterable[lnrpc.Resolution]): ChannelCloseSummary = copy(resolutions = resolutions ++ __vs)
def withResolutions(__v: _root_.scala.Seq[lnrpc.Resolution]): ChannelCloseSummary = copy(resolutions = __v)
def clearAliasScids = copy(aliasScids = _root_.scala.Seq.empty)
def addAliasScids(__vs: org.bitcoins.core.number.UInt64 *): ChannelCloseSummary = addAllAliasScids(__vs)
def addAllAliasScids(__vs: Iterable[org.bitcoins.core.number.UInt64]): ChannelCloseSummary = copy(aliasScids = aliasScids ++ __vs)
def withAliasScids(__v: _root_.scala.Seq[org.bitcoins.core.number.UInt64]): ChannelCloseSummary = copy(aliasScids = __v)
def withZeroConfConfirmedScid(__v: org.bitcoins.core.number.UInt64): ChannelCloseSummary = copy(zeroConfConfirmedScid = __v)
def withUnknownFields(__v: _root_.scalapb.UnknownFieldSet) = copy(unknownFields = __v)
def discardUnknownFields = copy(unknownFields = _root_.scalapb.UnknownFieldSet.empty)
def getFieldByNumber(__fieldNumber: _root_.scala.Int): _root_.scala.Any = {
(__fieldNumber: @_root_.scala.unchecked) match {
case 1 => {
val __t = channelPoint
if (__t != "") __t else null
}
case 2 => {
val __t = lnrpc.ChannelCloseSummary._typemapper_chanId.toBase(chanId)
if (__t != 0L) __t else null
}
case 3 => {
val __t = chainHash
if (__t != "") __t else null
}
case 4 => {
val __t = closingTxHash
if (__t != "") __t else null
}
case 5 => {
val __t = remotePubkey
if (__t != "") __t else null
}
case 6 => {
val __t = capacity
if (__t != 0L) __t else null
}
case 7 => {
val __t = lnrpc.ChannelCloseSummary._typemapper_closeHeight.toBase(closeHeight)
if (__t != 0) __t else null
}
case 8 => {
val __t = settledBalance
if (__t != 0L) __t else null
}
case 9 => {
val __t = timeLockedBalance
if (__t != 0L) __t else null
}
case 10 => {
val __t = closeType.javaValueDescriptor
if (__t.getNumber() != 0) __t else null
}
case 11 => {
val __t = openInitiator.javaValueDescriptor
if (__t.getNumber() != 0) __t else null
}
case 12 => {
val __t = closeInitiator.javaValueDescriptor
if (__t.getNumber() != 0) __t else null
}
case 13 => resolutions
case 14 => aliasScids.iterator.map(lnrpc.ChannelCloseSummary._typemapper_aliasScids.toBase(_)).toSeq
case 15 => {
val __t = lnrpc.ChannelCloseSummary._typemapper_zeroConfConfirmedScid.toBase(zeroConfConfirmedScid)
if (__t != 0L) __t else null
}
}
}
def getField(__field: _root_.scalapb.descriptors.FieldDescriptor): _root_.scalapb.descriptors.PValue = {
_root_.scala.Predef.require(__field.containingMessage eq companion.scalaDescriptor)
(__field.number: @_root_.scala.unchecked) match {
case 1 => _root_.scalapb.descriptors.PString(channelPoint)
case 2 => _root_.scalapb.descriptors.PLong(lnrpc.ChannelCloseSummary._typemapper_chanId.toBase(chanId))
case 3 => _root_.scalapb.descriptors.PString(chainHash)
case 4 => _root_.scalapb.descriptors.PString(closingTxHash)
case 5 => _root_.scalapb.descriptors.PString(remotePubkey)
case 6 => _root_.scalapb.descriptors.PLong(capacity)
case 7 => _root_.scalapb.descriptors.PInt(lnrpc.ChannelCloseSummary._typemapper_closeHeight.toBase(closeHeight))
case 8 => _root_.scalapb.descriptors.PLong(settledBalance)
case 9 => _root_.scalapb.descriptors.PLong(timeLockedBalance)
case 10 => _root_.scalapb.descriptors.PEnum(closeType.scalaValueDescriptor)
case 11 => _root_.scalapb.descriptors.PEnum(openInitiator.scalaValueDescriptor)
case 12 => _root_.scalapb.descriptors.PEnum(closeInitiator.scalaValueDescriptor)
case 13 => _root_.scalapb.descriptors.PRepeated(resolutions.iterator.map(_.toPMessage).toVector)
case 14 => _root_.scalapb.descriptors.PRepeated(aliasScids.iterator.map(__e => _root_.scalapb.descriptors.PLong(lnrpc.ChannelCloseSummary._typemapper_aliasScids.toBase(__e))).toVector)
case 15 => _root_.scalapb.descriptors.PLong(lnrpc.ChannelCloseSummary._typemapper_zeroConfConfirmedScid.toBase(zeroConfConfirmedScid))
}
}
def toProtoString: _root_.scala.Predef.String = _root_.scalapb.TextFormat.printToUnicodeString(this)
def companion: lnrpc.ChannelCloseSummary.type = lnrpc.ChannelCloseSummary
// @@protoc_insertion_point(GeneratedMessage[lnrpc.ChannelCloseSummary])
}
object ChannelCloseSummary extends scalapb.GeneratedMessageCompanion[lnrpc.ChannelCloseSummary] {
implicit def messageCompanion: scalapb.GeneratedMessageCompanion[lnrpc.ChannelCloseSummary] = this
def parseFrom(`_input__`: _root_.com.google.protobuf.CodedInputStream): lnrpc.ChannelCloseSummary = {
var __channelPoint: _root_.scala.Predef.String = ""
var __chanId: _root_.scala.Long = 0L
var __chainHash: _root_.scala.Predef.String = ""
var __closingTxHash: _root_.scala.Predef.String = ""
var __remotePubkey: _root_.scala.Predef.String = ""
var __capacity: _root_.scala.Long = 0L
var __closeHeight: _root_.scala.Int = 0
var __settledBalance: _root_.scala.Long = 0L
var __timeLockedBalance: _root_.scala.Long = 0L
var __closeType: lnrpc.ChannelCloseSummary.ClosureType = lnrpc.ChannelCloseSummary.ClosureType.COOPERATIVE_CLOSE
var __openInitiator: lnrpc.Initiator = lnrpc.Initiator.INITIATOR_UNKNOWN
var __closeInitiator: lnrpc.Initiator = lnrpc.Initiator.INITIATOR_UNKNOWN
val __resolutions: _root_.scala.collection.immutable.VectorBuilder[lnrpc.Resolution] = new _root_.scala.collection.immutable.VectorBuilder[lnrpc.Resolution]
val __aliasScids: _root_.scala.collection.immutable.VectorBuilder[org.bitcoins.core.number.UInt64] = new _root_.scala.collection.immutable.VectorBuilder[org.bitcoins.core.number.UInt64]
var __zeroConfConfirmedScid: _root_.scala.Long = 0L
var `_unknownFields__`: _root_.scalapb.UnknownFieldSet.Builder = null
var _done__ = false
while (!_done__) {
val _tag__ = _input__.readTag()
_tag__ match {
case 0 => _done__ = true
case 10 =>
__channelPoint = _input__.readStringRequireUtf8()
case 16 =>
__chanId = _input__.readUInt64()
case 26 =>
__chainHash = _input__.readStringRequireUtf8()
case 34 =>
__closingTxHash = _input__.readStringRequireUtf8()
case 42 =>
__remotePubkey = _input__.readStringRequireUtf8()
case 48 =>
__capacity = _input__.readInt64()
case 56 =>
__closeHeight = _input__.readUInt32()
case 64 =>
__settledBalance = _input__.readInt64()
case 72 =>
__timeLockedBalance = _input__.readInt64()
case 80 =>
__closeType = lnrpc.ChannelCloseSummary.ClosureType.fromValue(_input__.readEnum())
case 88 =>
__openInitiator = lnrpc.Initiator.fromValue(_input__.readEnum())
case 96 =>
__closeInitiator = lnrpc.Initiator.fromValue(_input__.readEnum())
case 106 =>
__resolutions += _root_.scalapb.LiteParser.readMessage[lnrpc.Resolution](_input__)
case 112 =>
__aliasScids += lnrpc.ChannelCloseSummary._typemapper_aliasScids.toCustom(_input__.readUInt64())
case 114 => {
val length = _input__.readRawVarint32()
val oldLimit = _input__.pushLimit(length)
while (_input__.getBytesUntilLimit > 0) {
__aliasScids += lnrpc.ChannelCloseSummary._typemapper_aliasScids.toCustom(_input__.readUInt64())
}
_input__.popLimit(oldLimit)
}
case 120 =>
__zeroConfConfirmedScid = _input__.readUInt64()
case tag =>
if (_unknownFields__ == null) {
_unknownFields__ = new _root_.scalapb.UnknownFieldSet.Builder()
}
_unknownFields__.parseField(tag, _input__)
}
}
lnrpc.ChannelCloseSummary(
channelPoint = __channelPoint,
chanId = lnrpc.ChannelCloseSummary._typemapper_chanId.toCustom(__chanId),
chainHash = __chainHash,
closingTxHash = __closingTxHash,
remotePubkey = __remotePubkey,
capacity = __capacity,
closeHeight = lnrpc.ChannelCloseSummary._typemapper_closeHeight.toCustom(__closeHeight),
settledBalance = __settledBalance,
timeLockedBalance = __timeLockedBalance,
closeType = __closeType,
openInitiator = __openInitiator,
closeInitiator = __closeInitiator,
resolutions = __resolutions.result(),
aliasScids = __aliasScids.result(),
zeroConfConfirmedScid = lnrpc.ChannelCloseSummary._typemapper_zeroConfConfirmedScid.toCustom(__zeroConfConfirmedScid),
unknownFields = if (_unknownFields__ == null) _root_.scalapb.UnknownFieldSet.empty else _unknownFields__.result()
)
}
implicit def messageReads: _root_.scalapb.descriptors.Reads[lnrpc.ChannelCloseSummary] = _root_.scalapb.descriptors.Reads{
case _root_.scalapb.descriptors.PMessage(__fieldsMap) =>
_root_.scala.Predef.require(__fieldsMap.keys.forall(_.containingMessage eq scalaDescriptor), "FieldDescriptor does not match message type.")
lnrpc.ChannelCloseSummary(
channelPoint = __fieldsMap.get(scalaDescriptor.findFieldByNumber(1).get).map(_.as[_root_.scala.Predef.String]).getOrElse(""),
chanId = lnrpc.ChannelCloseSummary._typemapper_chanId.toCustom(__fieldsMap.get(scalaDescriptor.findFieldByNumber(2).get).map(_.as[_root_.scala.Long]).getOrElse(0L)),
chainHash = __fieldsMap.get(scalaDescriptor.findFieldByNumber(3).get).map(_.as[_root_.scala.Predef.String]).getOrElse(""),
closingTxHash = __fieldsMap.get(scalaDescriptor.findFieldByNumber(4).get).map(_.as[_root_.scala.Predef.String]).getOrElse(""),
remotePubkey = __fieldsMap.get(scalaDescriptor.findFieldByNumber(5).get).map(_.as[_root_.scala.Predef.String]).getOrElse(""),
capacity = __fieldsMap.get(scalaDescriptor.findFieldByNumber(6).get).map(_.as[_root_.scala.Long]).getOrElse(0L),
closeHeight = lnrpc.ChannelCloseSummary._typemapper_closeHeight.toCustom(__fieldsMap.get(scalaDescriptor.findFieldByNumber(7).get).map(_.as[_root_.scala.Int]).getOrElse(0)),
settledBalance = __fieldsMap.get(scalaDescriptor.findFieldByNumber(8).get).map(_.as[_root_.scala.Long]).getOrElse(0L),
timeLockedBalance = __fieldsMap.get(scalaDescriptor.findFieldByNumber(9).get).map(_.as[_root_.scala.Long]).getOrElse(0L),
closeType = lnrpc.ChannelCloseSummary.ClosureType.fromValue(__fieldsMap.get(scalaDescriptor.findFieldByNumber(10).get).map(_.as[_root_.scalapb.descriptors.EnumValueDescriptor]).getOrElse(lnrpc.ChannelCloseSummary.ClosureType.COOPERATIVE_CLOSE.scalaValueDescriptor).number),
openInitiator = lnrpc.Initiator.fromValue(__fieldsMap.get(scalaDescriptor.findFieldByNumber(11).get).map(_.as[_root_.scalapb.descriptors.EnumValueDescriptor]).getOrElse(lnrpc.Initiator.INITIATOR_UNKNOWN.scalaValueDescriptor).number),
closeInitiator = lnrpc.Initiator.fromValue(__fieldsMap.get(scalaDescriptor.findFieldByNumber(12).get).map(_.as[_root_.scalapb.descriptors.EnumValueDescriptor]).getOrElse(lnrpc.Initiator.INITIATOR_UNKNOWN.scalaValueDescriptor).number),
resolutions = __fieldsMap.get(scalaDescriptor.findFieldByNumber(13).get).map(_.as[_root_.scala.Seq[lnrpc.Resolution]]).getOrElse(_root_.scala.Seq.empty),
aliasScids = __fieldsMap.get(scalaDescriptor.findFieldByNumber(14).get).map(_.as[_root_.scala.Seq[_root_.scala.Long]]).getOrElse(_root_.scala.Seq.empty).iterator.map(lnrpc.ChannelCloseSummary._typemapper_aliasScids.toCustom(_)).toSeq,
zeroConfConfirmedScid = lnrpc.ChannelCloseSummary._typemapper_zeroConfConfirmedScid.toCustom(__fieldsMap.get(scalaDescriptor.findFieldByNumber(15).get).map(_.as[_root_.scala.Long]).getOrElse(0L))
)
case _ => throw new RuntimeException("Expected PMessage")
}
def javaDescriptor: _root_.com.google.protobuf.Descriptors.Descriptor = LightningProto.javaDescriptor.getMessageTypes().get(47)
def scalaDescriptor: _root_.scalapb.descriptors.Descriptor = LightningProto.scalaDescriptor.messages(47)
def messageCompanionForFieldNumber(__number: _root_.scala.Int): _root_.scalapb.GeneratedMessageCompanion[_] = {
var __out: _root_.scalapb.GeneratedMessageCompanion[_] = null
(__number: @_root_.scala.unchecked) match {
case 13 => __out = lnrpc.Resolution
}
__out
}
lazy val nestedMessagesCompanions: Seq[_root_.scalapb.GeneratedMessageCompanion[_ <: _root_.scalapb.GeneratedMessage]] = Seq.empty
def enumCompanionForFieldNumber(__fieldNumber: _root_.scala.Int): _root_.scalapb.GeneratedEnumCompanion[_] = {
(__fieldNumber: @_root_.scala.unchecked) match {
case 10 => lnrpc.ChannelCloseSummary.ClosureType
case 11 => lnrpc.Initiator
case 12 => lnrpc.Initiator
}
}
lazy val defaultInstance = lnrpc.ChannelCloseSummary(
channelPoint = "",
chanId = lnrpc.ChannelCloseSummary._typemapper_chanId.toCustom(0L),
chainHash = "",
closingTxHash = "",
remotePubkey = "",
capacity = 0L,
closeHeight = lnrpc.ChannelCloseSummary._typemapper_closeHeight.toCustom(0),
settledBalance = 0L,
timeLockedBalance = 0L,
closeType = lnrpc.ChannelCloseSummary.ClosureType.COOPERATIVE_CLOSE,
openInitiator = lnrpc.Initiator.INITIATOR_UNKNOWN,
closeInitiator = lnrpc.Initiator.INITIATOR_UNKNOWN,
resolutions = _root_.scala.Seq.empty,
aliasScids = _root_.scala.Seq.empty,
zeroConfConfirmedScid = lnrpc.ChannelCloseSummary._typemapper_zeroConfConfirmedScid.toCustom(0L)
)
sealed abstract class ClosureType(val value: _root_.scala.Int) extends _root_.scalapb.GeneratedEnum {
type EnumType = ClosureType
def isCooperativeClose: _root_.scala.Boolean = false
def isLocalForceClose: _root_.scala.Boolean = false
def isRemoteForceClose: _root_.scala.Boolean = false
def isBreachClose: _root_.scala.Boolean = false
def isFundingCanceled: _root_.scala.Boolean = false
def isAbandoned: _root_.scala.Boolean = false
def companion: _root_.scalapb.GeneratedEnumCompanion[ClosureType] = lnrpc.ChannelCloseSummary.ClosureType
final def asRecognized: _root_.scala.Option[lnrpc.ChannelCloseSummary.ClosureType.Recognized] = if (isUnrecognized) _root_.scala.None else _root_.scala.Some(this.asInstanceOf[lnrpc.ChannelCloseSummary.ClosureType.Recognized])
}
object ClosureType extends _root_.scalapb.GeneratedEnumCompanion[ClosureType] {
sealed trait Recognized extends ClosureType
implicit def enumCompanion: _root_.scalapb.GeneratedEnumCompanion[ClosureType] = this
@SerialVersionUID(0L)
case object COOPERATIVE_CLOSE extends ClosureType(0) with ClosureType.Recognized {
val index = 0
val name = "COOPERATIVE_CLOSE"
override def isCooperativeClose: _root_.scala.Boolean = true
}
@SerialVersionUID(0L)
case object LOCAL_FORCE_CLOSE extends ClosureType(1) with ClosureType.Recognized {
val index = 1
val name = "LOCAL_FORCE_CLOSE"
override def isLocalForceClose: _root_.scala.Boolean = true
}
@SerialVersionUID(0L)
case object REMOTE_FORCE_CLOSE extends ClosureType(2) with ClosureType.Recognized {
val index = 2
val name = "REMOTE_FORCE_CLOSE"
override def isRemoteForceClose: _root_.scala.Boolean = true
}
@SerialVersionUID(0L)
case object BREACH_CLOSE extends ClosureType(3) with ClosureType.Recognized {
val index = 3
val name = "BREACH_CLOSE"
override def isBreachClose: _root_.scala.Boolean = true
}
@SerialVersionUID(0L)
case object FUNDING_CANCELED extends ClosureType(4) with ClosureType.Recognized {
val index = 4
val name = "FUNDING_CANCELED"
override def isFundingCanceled: _root_.scala.Boolean = true
}
@SerialVersionUID(0L)
case object ABANDONED extends ClosureType(5) with ClosureType.Recognized {
val index = 5
val name = "ABANDONED"
override def isAbandoned: _root_.scala.Boolean = true
}
@SerialVersionUID(0L)
final case class Unrecognized(unrecognizedValue: _root_.scala.Int) extends ClosureType(unrecognizedValue) with _root_.scalapb.UnrecognizedEnum
lazy val values = scala.collection.immutable.Seq(COOPERATIVE_CLOSE, LOCAL_FORCE_CLOSE, REMOTE_FORCE_CLOSE, BREACH_CLOSE, FUNDING_CANCELED, ABANDONED)
def fromValue(__value: _root_.scala.Int): ClosureType = __value match {
case 0 => COOPERATIVE_CLOSE
case 1 => LOCAL_FORCE_CLOSE
case 2 => REMOTE_FORCE_CLOSE
case 3 => BREACH_CLOSE
case 4 => FUNDING_CANCELED
case 5 => ABANDONED
case __other => Unrecognized(__other)
}
def javaDescriptor: _root_.com.google.protobuf.Descriptors.EnumDescriptor = lnrpc.ChannelCloseSummary.javaDescriptor.getEnumTypes().get(0)
def scalaDescriptor: _root_.scalapb.descriptors.EnumDescriptor = lnrpc.ChannelCloseSummary.scalaDescriptor.enums(0)
}
implicit class ChannelCloseSummaryLens[UpperPB](_l: _root_.scalapb.lenses.Lens[UpperPB, lnrpc.ChannelCloseSummary]) extends _root_.scalapb.lenses.ObjectLens[UpperPB, lnrpc.ChannelCloseSummary](_l) {
def channelPoint: _root_.scalapb.lenses.Lens[UpperPB, _root_.scala.Predef.String] = field(_.channelPoint)((c_, f_) => c_.copy(channelPoint = f_))
def chanId: _root_.scalapb.lenses.Lens[UpperPB, org.bitcoins.core.number.UInt64] = field(_.chanId)((c_, f_) => c_.copy(chanId = f_))
def chainHash: _root_.scalapb.lenses.Lens[UpperPB, _root_.scala.Predef.String] = field(_.chainHash)((c_, f_) => c_.copy(chainHash = f_))
def closingTxHash: _root_.scalapb.lenses.Lens[UpperPB, _root_.scala.Predef.String] = field(_.closingTxHash)((c_, f_) => c_.copy(closingTxHash = f_))
def remotePubkey: _root_.scalapb.lenses.Lens[UpperPB, _root_.scala.Predef.String] = field(_.remotePubkey)((c_, f_) => c_.copy(remotePubkey = f_))
def capacity: _root_.scalapb.lenses.Lens[UpperPB, _root_.scala.Long] = field(_.capacity)((c_, f_) => c_.copy(capacity = f_))
def closeHeight: _root_.scalapb.lenses.Lens[UpperPB, org.bitcoins.core.number.UInt32] = field(_.closeHeight)((c_, f_) => c_.copy(closeHeight = f_))
def settledBalance: _root_.scalapb.lenses.Lens[UpperPB, _root_.scala.Long] = field(_.settledBalance)((c_, f_) => c_.copy(settledBalance = f_))
def timeLockedBalance: _root_.scalapb.lenses.Lens[UpperPB, _root_.scala.Long] = field(_.timeLockedBalance)((c_, f_) => c_.copy(timeLockedBalance = f_))
def closeType: _root_.scalapb.lenses.Lens[UpperPB, lnrpc.ChannelCloseSummary.ClosureType] = field(_.closeType)((c_, f_) => c_.copy(closeType = f_))
def openInitiator: _root_.scalapb.lenses.Lens[UpperPB, lnrpc.Initiator] = field(_.openInitiator)((c_, f_) => c_.copy(openInitiator = f_))
def closeInitiator: _root_.scalapb.lenses.Lens[UpperPB, lnrpc.Initiator] = field(_.closeInitiator)((c_, f_) => c_.copy(closeInitiator = f_))
def resolutions: _root_.scalapb.lenses.Lens[UpperPB, _root_.scala.Seq[lnrpc.Resolution]] = field(_.resolutions)((c_, f_) => c_.copy(resolutions = f_))
def aliasScids: _root_.scalapb.lenses.Lens[UpperPB, _root_.scala.Seq[org.bitcoins.core.number.UInt64]] = field(_.aliasScids)((c_, f_) => c_.copy(aliasScids = f_))
def zeroConfConfirmedScid: _root_.scalapb.lenses.Lens[UpperPB, org.bitcoins.core.number.UInt64] = field(_.zeroConfConfirmedScid)((c_, f_) => c_.copy(zeroConfConfirmedScid = f_))
}
final val CHANNEL_POINT_FIELD_NUMBER = 1
final val CHAN_ID_FIELD_NUMBER = 2
final val CHAIN_HASH_FIELD_NUMBER = 3
final val CLOSING_TX_HASH_FIELD_NUMBER = 4
final val REMOTE_PUBKEY_FIELD_NUMBER = 5
final val CAPACITY_FIELD_NUMBER = 6
final val CLOSE_HEIGHT_FIELD_NUMBER = 7
final val SETTLED_BALANCE_FIELD_NUMBER = 8
final val TIME_LOCKED_BALANCE_FIELD_NUMBER = 9
final val CLOSE_TYPE_FIELD_NUMBER = 10
final val OPEN_INITIATOR_FIELD_NUMBER = 11
final val CLOSE_INITIATOR_FIELD_NUMBER = 12
final val RESOLUTIONS_FIELD_NUMBER = 13
final val ALIAS_SCIDS_FIELD_NUMBER = 14
final val ZERO_CONF_CONFIRMED_SCID_FIELD_NUMBER = 15
@transient
private[lnrpc] val _typemapper_chanId: _root_.scalapb.TypeMapper[_root_.scala.Long, org.bitcoins.core.number.UInt64] = implicitly[_root_.scalapb.TypeMapper[_root_.scala.Long, org.bitcoins.core.number.UInt64]]
@transient
private[lnrpc] val _typemapper_closeHeight: _root_.scalapb.TypeMapper[_root_.scala.Int, org.bitcoins.core.number.UInt32] = implicitly[_root_.scalapb.TypeMapper[_root_.scala.Int, org.bitcoins.core.number.UInt32]]
@transient
private[lnrpc] val _typemapper_aliasScids: _root_.scalapb.TypeMapper[_root_.scala.Long, org.bitcoins.core.number.UInt64] = implicitly[_root_.scalapb.TypeMapper[_root_.scala.Long, org.bitcoins.core.number.UInt64]]
@transient
private[lnrpc] val _typemapper_zeroConfConfirmedScid: _root_.scalapb.TypeMapper[_root_.scala.Long, org.bitcoins.core.number.UInt64] = implicitly[_root_.scalapb.TypeMapper[_root_.scala.Long, org.bitcoins.core.number.UInt64]]
def of(
channelPoint: _root_.scala.Predef.String,
chanId: org.bitcoins.core.number.UInt64,
chainHash: _root_.scala.Predef.String,
closingTxHash: _root_.scala.Predef.String,
remotePubkey: _root_.scala.Predef.String,
capacity: _root_.scala.Long,
closeHeight: org.bitcoins.core.number.UInt32,
settledBalance: _root_.scala.Long,
timeLockedBalance: _root_.scala.Long,
closeType: lnrpc.ChannelCloseSummary.ClosureType,
openInitiator: lnrpc.Initiator,
closeInitiator: lnrpc.Initiator,
resolutions: _root_.scala.Seq[lnrpc.Resolution],
aliasScids: _root_.scala.Seq[org.bitcoins.core.number.UInt64],
zeroConfConfirmedScid: org.bitcoins.core.number.UInt64
): _root_.lnrpc.ChannelCloseSummary = _root_.lnrpc.ChannelCloseSummary(
channelPoint,
chanId,
chainHash,
closingTxHash,
remotePubkey,
capacity,
closeHeight,
settledBalance,
timeLockedBalance,
closeType,
openInitiator,
closeInitiator,
resolutions,
aliasScids,
zeroConfConfirmedScid
)
// @@protoc_insertion_point(GeneratedMessageCompanion[lnrpc.ChannelCloseSummary])
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy