I added a mechanism to deliver new-view callbacks to the user-provided objects that define each subgroup (i.e. the T in a Replicated) so that these objects can react to a view change if they want to. If a user-provided object inherits from GetsViewChangeCallback, and implements a method named new_view_callback, that method will be called by ViewManager during the last phase of a view change (along with the other "view upcalls"). The existing view_upcalls parameter to the Group constructor can't be used to provide this feature because the user-provided replicated objects are constructed within the Group constructor, and thus don't yet exist at the time you would need to declare a callback function for that parameter.
I added a mechanism to deliver new-view callbacks to the user-provided objects that define each subgroup (i.e. the T in a Replicated) so that these objects can react to a view change if they want to. If a user-provided object inherits from GetsViewChangeCallback, and implements a method named
new_view_callback
, that method will be called by ViewManager during the last phase of a view change (along with the other "view upcalls"). The existingview_upcalls
parameter to the Group constructor can't be used to provide this feature because the user-provided replicated objects are constructed within the Group constructor, and thus don't yet exist at the time you would need to declare a callback function for that parameter.