From 492851edfc1196cbb8487510a7c54dea9fa4a4a3 Mon Sep 17 00:00:00 2001 From: ryanRfox Date: Fri, 31 Aug 2018 10:49:53 -0400 Subject: [PATCH] Fixup: HTLC Object --- bsip-0044.md | 29 +++++++++++++---------------- 1 file changed, 13 insertions(+), 16 deletions(-) diff --git a/bsip-0044.md b/bsip-0044.md index 3bdc25e..6f30e4f 100644 --- a/bsip-0044.md +++ b/bsip-0044.md @@ -174,23 +174,20 @@ Bob has now observed the `preimage` Alice used to "unlock" his HTLC, and he will ## **Objects** ``` -htlc_obj - id // int - depositor // account object - quantity // int - symbol // string - recipient // account object - hash_algorithm // enum - preimage_hash // string - preimage_length // int - preimage_tx_id // reference to transaction object containing the preimage used for htlc_redeem - timeout_threshold // datetime + class htlc_object : public graphene::db::abstract_object { + public: + static const uint8_t space_id = implementation_ids; + static const uint8_t type_id = impl_htlc_object_type; - // Constructor - Set: id = next available - Initialize other fields = NULL - - return contract + account_id_type depositor; + account_id_type recipient; + asset amount; + fc::time_point_sec expiration; + asset pending_fee; + vector preimage_hash; + uint16_t preimage_size; + transaction_id_type preimage_tx_id; + }; ``` ## **Operations**