Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 9 additions & 5 deletions bsip-0044.md
Original file line number Diff line number Diff line change
Expand Up @@ -172,6 +172,12 @@ Bob has now observed the `preimage` Alice used to "unlock" his HTLC, and he will
## **Objects**

```
typedef fc::static_variant<
htlc_algo_ripemd160,
htlc_algo_sha1,
htlc_algo_sha256
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Now you should mention what these three new types are... :-)

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do you think it best to put it in a descriptive note below this section or a //comment on each line? I'll give //comment a try.

> htlc_hash;

class htlc_object : public graphene::db::abstract_object<htlc_object> {
public:
static const uint8_t space_id = implementation_ids;
Expand All @@ -186,11 +192,9 @@ Bob has now observed the `preimage` Alice used to "unlock" his HTLC, and he will
};
```

Note 1: The preimage hash algorithm must be speceified as either ``SHA256``, ``RIPEMD160``, or ``SHA1``. The use of ``SHA1`` is added for compatibility to other chains, but its use is discouraged.

Note 2: The preimage size must be less than the maximum number of bytes as specified by the committee.
Note 1: The preimage size must be less than the maximum number of bytes as specified by the committee.

Note 3: The initial HTLC expiration can not be more than the maximum amount of time as specified by the committee. This can be extened, but not for more than the amount of time of (extension time + maximum amount of time as specified by the committee).
Note 2: The initial HTLC expiration can not be more than the maximum amount of time as specified by the committee. This can be extened, but not for more than the amount of time of (extension time + maximum amount of time as specified by the committee).

## **Operations**

Expand All @@ -213,7 +217,7 @@ transaction_obj htlc_create(from, to, quantity, symbol, hash_algorithm, preimage
Set: `contract.preimage_hash` = `preimage_hash`
Set: `contract.preimage_length` = `preimage_length`
Set: `contract.timeout_treshold` = `timeout_threshold`
Transfer: remove `contract.quantity` of `contract.symbol` from from` account
Transfer: remove `contract.quantity` of `contract.symbol` from `from` account
return results
```

Expand Down