if( describeType(MyClass).implementsInterface.(@type) == interfaceName).length() ){
//do something;
}
but it's a bit expensive to iterate over the tags everytime you want to check.
Hi all,
I often use
if (obj is MyClassOrInterface)
{
// do whatever
}
but it appears that only works with Instances not Classes. With just a
Class, how can I tell if that class implements a particular interface
or is of a particular base type? Do I have to create an instance of
it and check the instance? I'm sure there must be another way...
thanks in advance,
Thunder
__________________________
var currentDomain:ApplicationDomain = ApplicationDomain.currentDomain;
var psClass:Class = null;
if (currentDomain.hasDefinition(sPropClass))
{
psClass = Class(currentDomain.getDefinition(sPropClass));
}
// below statement doesn't work!
if ( (psClass != null) && (psClass is IPropertySheet) )
{
// make a new one of these classes.
}
__._,_.___
--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com
![]()
YAHOO! GROUPS LINKS
- Visit your group "flexcoders" on the web.
- To unsubscribe from this group, send an email to:
[EMAIL PROTECTED]
- Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.
__,_._,___
- [flexcoders] Determine if a Class implements an Inte... thunderstumpgesatwork
- Re: [flexcoders] Determine if a Class implement... Jeremy Lu
- RE: [flexcoders] Determine if a Class implement... Matt Chotin
- RE: [flexcoders] Determine if a Class imple... Gordon Smith
- [flexcoders] Re: Determine if a Class i... thunderstumpgesatwork
- RE: [flexcoders] Re: Determine if a... Gordon Smith
Reply via email to

