I don't understand some of the details of how
liquidity stack works in Haircomb cryptocurrency. In the documentation it says that a stack is a
construct, and "Constructs are stored off-chain in your wallet".
Is the stack object supposed to be created on the payer's or the payee's machine?
What happens when I send funds to a multipay stack which was created on another machine which is currently offline? Does it mean that all the payments that are defined by the stack will not happen until that machine is back online?
I have also seen in a discussion:
"Only if the amount at the liquidity stack input reaches the stack internal threshold, the observer considers that liquidity stack as triggered. After triggering, the threshold amount is moved to stack output, and a stack transaction connects the liquidity stack to liquidity stack change. If users didn't honor this rule then Haircomb couldn't function as a currency. That's why all users do honor the rule."
I didn't understand some details in this explanation.
How is the stack able to implement the transfer of the input funds to two addresses? I thought that in Haircomb we can only have no more than one directed edge coming out of an address.
I did not understand who "the observer" who decides when the stack should trigger is, and I did not understand the statement "all users do honor the rule." Does it mean that all users can see that the stack splits the input correctly? Does it not require that they could see the input amount (which should be hidden from most users)?
Or does it only refer to the user who owns the stack object? If so, why should we all trust him?
Haircomb, like Bitcoin, is a protocol; the best comparison is to a secret handshake. If someone attempts to do a secret handshake with you, but at step 5 instead of high fiving you they try to chestbump you, you won't go along with it because you know what the correct sequence of actions is. Haircomb is also a privacy coin; when your stack "triggers", the proof of the triggering is broadcast out, but only the relevant people can read it. When you validate a transaction history, you go through and check that the proof of a stack triggering is real, for the entire transaction history. You don't have to trust that it triggered, you require your counterparty to prove it to you. In order to know a stack has triggered, you need to know a) that the stack exists, and b) the amount of verifiable funds have been transferred into it.
The best comparison to BTC is looking at when you figure out which funds are where; because BTC is a public ledger, everybody who receives a BTC block immediately verifies the blocks contents and updates their record of who has what money. With Haircomb, rather than keeping a constantly updated database, you only ever calculate fund that you own/are about to own, and instead of doing it every BTC block, you do it whenever your balance is about to be updated. BTC works off of constant data processing, Haircomb works off of delaying the data processing for you until it's required.
As for how the stack can split funds while each wallet can only have one output; the stack is not a wallet. It's its own type of smart contract that operates using different rules.