|
Hi,
I just realized that I can't use the 'typeof' expression when writing a WF rule condition.
Let's say I have a method called 'foo', that looks like this: bool foo(Type someType) {}
When writing the rule condition, I tried to write: foo(typeof(MyObj)) == true. No luck.
I also tried ommiting the 'typeof' expression and just write it like this: foo(MyObj) == true.
When writing it in the second form, the Rule Condition dialog will display a message telling you that it does not support CodeTypeReference expressions.
I know I can use the 'Type.GetType' method but I'd hate to write the fully qualified type name everytime I need to use this functionality.
So, has anyone found a better solution to this problem?
Have I overlooked something (C'mon, say yes :))
Thanks in advance,
PS - I'm guessing this is also why I can't really use generics in the rule editor.. Just out of curiousity, will there be support for generics in the future?
when it comes to security - if it works both ways, it doesn't work :) |