In many cases, we want to register multiple events, each with its own callback. Currently, we need to do a call to RegisterLocal for each pair we want to register.
An easier way that would allow us to avoid repetition would be to add a method that receives an array of pairs and calls RegisterLocal. For example, we could implement it as an overload of the RegisterLocal:
RegisterLocal(List<Pair<string, callback>> items) {
foreach (event, callback) in items {
RegisterLocal(event, callback)
}
}
As an idea, we could also implement a similar method to register multiple local reply callbacks (we should wait for #28 to be closed in that case).
As a note: we could replace the current RegisterLocal with this one.
In many cases, we want to register multiple events, each with its own callback. Currently, we need to do a call to
RegisterLocalfor each pair we want to register.An easier way that would allow us to avoid repetition would be to add a method that receives an array of pairs and calls RegisterLocal. For example, we could implement it as an overload of the
RegisterLocal:As an idea, we could also implement a similar method to register multiple local reply callbacks (we should wait for #28 to be closed in that case).
As a note: we could replace the current
RegisterLocalwith this one.