I want an object with two inlets.
I want the first inlet to be able to accept any message.
I want to bind functions to the second inlet, accepting several specific messages (symbol messagename, symbol argument), and reject any others. Rejected messages should not be passed to the first inlet.
The first inlet should also be able to accept the same specific messages, but pass them through, not executing the bound function.
Given the above, is it possible to avoid testing the inlet number every time a message arrives at an inlet – especially for the first inlet?
What’s the best way to deal with this sort of thing?
Let me ask you a question: why don’t you want to test? If you have to
use the words "clean" or "efficient" or "optimize" in your answer,
you are likely spending your time chasing a spectre.
Your bottleneck, if it exists, is not, and will never be, an if or
switch testing the origin of messages as they arrive.
Am 21.06.2007 um 03:13 schrieb John Pitcairn:
> Given the above, is it possible to avoid testing the inlet number
> every time a message arrives at an inlet – especially for the first
Yeah, fair enough. I was just interested to know if there was an alternate way to do this sort of thing. The docs imply that there isn’t, but that may just be my mis-reading.