Registers driver on the real ClassFactory under each of driverClasses, at priority or above
whatever is registered there (a real driver an earlier restore put back included), so every
CreateInstance(BaseDecision, name, …) returns that one instance. The
same technique as RegisterTestLLM: a real registration and a real new, whose constructor hands
back the shared instance.
restore, which registers each name's previous class above the stand-in again. A name with
no previous registration keeps resolving to the stand-in, which is why it can be disarmed.
Registers
driveron the real ClassFactory under each ofdriverClasses, atpriorityor above whatever is registered there (a real driver an earlier restore put back included), so everyCreateInstance(BaseDecision, name, …)returns that one instance. The same technique asRegisterTestLLM: a real registration and a realnew, whose constructor hands back the shared instance.