serialize Derived
Writes the time-lock-specific fields in disk format. These bytes get appended after PayDestination.serializeTypeAndDerived has written the shared index: i64 framing every destination starts with — that framing runs unconditionally and is independent of this method.
Format written here: secret: varByteshdIndex: i64contractName: nullString
These values are everything needed to call the primary constructor on load. The pubkey is not persisted explicitly — it is derived from the secret on construction.
Does not call super.serializeDerived() (Pay2TemplateDestination's version), which would also persist template/constraint/visibleConstraint. Those are deterministic functions of (unlockValue, secret, hdIndex) — recomputed by init on load — so persisting them would be redundant and would risk drift if the helper scripts ever change shape.
Restricted to DISK format so the secret cannot be accidentally sent over the network.