目录
`uvm_do_callbacks(T, CB,METHOD)
`uvm_register_cb(T,CB)
Registers the given CB callback type with the given T object type. If a type-callback pair is not registered then a warning is issued if an attempt is made to use the pair (add, delete, etc.).
The registration will typically occur in the component that executes the given type of callback. For instance:
virtual class mycb extends uvm_callback;
virtual function void doit();
endclass
class my_comp extends uvm_component;
`uvm_register_cb(my_comp,mycb)
...
task run_phase(uvm_phase phase);
...
`uvm_do_callbacks(my_comp, mycb, doit())
endtask
endclass
`uvm_do_callbacks(T, CB,METHOD)
Calls the given METHOD of all callbacks of type CB