I am trying to learn the parametrized class overriding/selection at run time but while printing using uvm_factory::get.print() i am seeing both requested type and override type is same.
please throw some inputs
Yes, if i use the above-mentioned component registry also override is Woking fine. But i was exploring the factory concept and get stuck at why factory. Print is not giving the override type and requested type names differently. is there anything do i need to take care?
To get the type names in the factory.print for overriding i am experimenting these.
You need to add these two additional functions when not using the `uvm_object_utils macro
// for type overrides
static function type_id get_type();
return type_id::get();
endfunction
// for string type name overrides
virtual function string get_type_name ();
return name;
endfunction
Also, I would use type_name instead of just name to distinguish it from the uvm_object’s name.