I have method in factory class
internal Window GetWindow(int siteId)
{
Contract.Requires(siteId > 0);
Window result;
//some logic that create specific window
return result;
}
Lets assume i have [MyAttribute]
I need postcondition in GetWindow
which can prove that method returns object marked with [MyAttribute]
Is it possible?