1
Vote

ResourceGroup base type should be Generic Class

description

Hi,

Maybe I'm implementing something wrong, but when I try to define a Resource Group with my own custom Resource interface and implementation (call it myResource), I am unable to use the Resource Base Type because its not a genetic class.

I looked at the ResourceGroup code, file Preactor.ObjectModel.BaseTypes.ResourceGroup in method GetResources(), line 38.

It calls a method GetResourceByName which is essentially forcing the Resource Group to always implement IResourceGroup<IResource>

The solution to this would be to make the base type ResourceGroup generic and on line 38 to change GetResourceByName to GetRecordByName<ImyResource> with correct Cast

As a workaround, I'm implementing my own ResourceGroup.

Regards,
Marius

comments