hexresearch / hschain

Other
4 stars 0 forks source link

Build dictionaries of function then interpret them #532

Closed Shimuuar closed 4 years ago

Shimuuar commented 4 years ago

Instead of passing handler directly to handlerGeneric/issuedGossipHandlerGeneric first build dictionaries of functions and pass this dictionaries to functions. Only reason for such transformation is ease of documentation. Dictionary fields are natural place to describe logic of handler and current/lagging/ahead functions becomes self-documenting to a degree