amqplib icon indicating copy to clipboard operation
amqplib copied to clipboard

Make channel APIs polymorphic

Open squaremo opened this issue 11 years ago • 0 comments

The two channel APIs have a few methods for which proper polymorphism would be convenient, e.g., for missing out the options argument in favour of the callback.

Dispatching on the types seems like a reasonable way to do this, since the callback is usually a function. Maybe a tiny multiple dispatch module? It doesn't need to be very clever, just to make a wee state machine for each method.

squaremo avatar Jun 11 '14 09:06 squaremo