Object

fr.acinq.eclair.transactions

Scripts

Related Doc: package transactions

Permalink

object Scripts

Created by PM on 02/12/2016.

Linear Supertypes
AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. Scripts
  2. AnyRef
  3. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Value Members

  1. final def !=(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  4. def applyFees(amount_us: Satoshi, amount_them: Satoshi, fee: Satoshi): (Satoshi, Satoshi)

    Permalink
  5. final def asInstanceOf[T0]: T0

    Permalink
    Definition Classes
    Any
  6. def clone(): AnyRef

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @HotSpotIntrinsicCandidate() @throws( ... )
  7. def cltvTimeout(tx: Transaction): Long

    Permalink

    This function interprets the locktime for the given transaction, and returns the block height before which this tx cannot be published.

    This function interprets the locktime for the given transaction, and returns the block height before which this tx cannot be published. By convention in bitcoin, depending of the value of locktime it might be a number of blocks or a number of seconds since epoch. This function does not support the case when the locktime is a number of seconds that is not way in the past. NB: We use this property in lightning to store data in this field.

    returns

    the block height before which this tx cannot be published.

  8. def csvTimeout(tx: Transaction): Long

    Permalink

    returns

    the number of confirmations of the tx parent before which it can be published

  9. def der(sig: ByteVector64): ByteVector

    Permalink
  10. def encodeNumber(n: Long): ScriptElt

    Permalink

    minimal encoding of a number into a script element: - OP_0 to OP_16 if 0 <= n <= 16 - OP_PUSHDATA(encodeNumber(n)) otherwise

    minimal encoding of a number into a script element: - OP_0 to OP_16 if 0 <= n <= 16 - OP_PUSHDATA(encodeNumber(n)) otherwise

    n

    input number

    returns

    a script element that represents n

  11. final def eq(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  12. def equals(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  13. final def getClass(): Class[_]

    Permalink
    Definition Classes
    AnyRef → Any
    Annotations
    @HotSpotIntrinsicCandidate()
  14. def hashCode(): Int

    Permalink
    Definition Classes
    AnyRef → Any
    Annotations
    @HotSpotIntrinsicCandidate()
  15. def htlcOffered(localHtlcPubkey: PublicKey, remoteHtlcPubkey: PublicKey, revocationPubKey: PublicKey, paymentHash: ByteVector): Seq[ScriptElt]

    Permalink
  16. def htlcReceived(localHtlcPubkey: PublicKey, remoteHtlcPubkey: PublicKey, revocationPubKey: PublicKey, paymentHash: ByteVector, lockTime: CltvExpiry): List[ScriptElt]

    Permalink
  17. final def isInstanceOf[T0]: Boolean

    Permalink
    Definition Classes
    Any
  18. def multiSig2of2(pubkey1: PublicKey, pubkey2: PublicKey): Seq[ScriptElt]

    Permalink
  19. final def ne(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  20. final def notify(): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @HotSpotIntrinsicCandidate()
  21. final def notifyAll(): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @HotSpotIntrinsicCandidate()
  22. final def synchronized[T0](arg0: ⇒ T0): T0

    Permalink
    Definition Classes
    AnyRef
  23. def toLocalDelayed(revocationPubkey: PublicKey, toSelfDelay: CltvExpiryDelta, localDelayedPaymentPubkey: PublicKey): List[ScriptElt]

    Permalink
  24. def toString(): String

    Permalink
    Definition Classes
    AnyRef → Any
  25. final def wait(arg0: Long, arg1: Int): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  26. final def wait(arg0: Long): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  27. final def wait(): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  28. def witness2of2(sig1: ByteVector64, sig2: ByteVector64, pubkey1: PublicKey, pubkey2: PublicKey): ScriptWitness

    Permalink

    returns

    a script witness that matches the msig 2-of-2 pubkey script for pubkey1 and pubkey2

  29. def witnessClaimHtlcSuccessFromCommitTx(localSig: ByteVector64, paymentPreimage: ByteVector32, htlcOfferedScript: ByteVector): ScriptWitness

    Permalink

    If local publishes its commit tx where there was a local->remote htlc, then remote uses this script to claim its funds using a payment preimage (consumes htlcOffered script from commit tx)

  30. def witnessClaimHtlcTimeoutFromCommitTx(localSig: ByteVector64, htlcReceivedScript: ByteVector): ScriptWitness

    Permalink

    If local publishes its commit tx where there was a remote->local htlc, then remote uses this script to claim its funds after timeout (consumes htlcReceived script from commit tx)

  31. def witnessHtlcSuccess(localSig: ByteVector64, remoteSig: ByteVector64, paymentPreimage: ByteVector32, htlcOfferedScript: ByteVector): ScriptWitness

    Permalink

    This is the witness script of the 2nd-stage HTLC Success transaction (consumes htlcOffered script from commit tx)

  32. def witnessHtlcTimeout(localSig: ByteVector64, remoteSig: ByteVector64, htlcReceivedScript: ByteVector): ScriptWitness

    Permalink

    This is the witness script of the 2nd-stage HTLC Timeout transaction (consumes htlcReceived script from commit tx)

  33. def witnessHtlcWithRevocationSig(revocationSig: ByteVector64, revocationPubkey: PublicKey, htlcScript: ByteVector): ScriptWitness

    Permalink

    This witness script spends (steals) a htlcOffered or htlcReceived output using a revocation key as a punishment for having published a revoked transaction

  34. def witnessToLocalDelayedAfterDelay(localSig: ByteVector64, toLocalDelayedScript: ByteVector): ScriptWitness

    Permalink

    This witness script spends a toLocalDelayed output using a local sig after a delay

  35. def witnessToLocalDelayedWithRevocationSig(revocationSig: ByteVector64, toLocalScript: ByteVector): ScriptWitness

    Permalink

    This witness script spends (steals) a toLocalDelayed output using a revocation key as a punishment for having published a revoked transaction

Deprecated Value Members

  1. def finalize(): Unit

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @Deprecated @deprecated @throws( classOf[java.lang.Throwable] )
    Deprecated

    (Since version ) see corresponding Javadoc for more information.

Inherited from AnyRef

Inherited from Any

Ungrouped