How do I get a list of classes that are subclasses of 2 unrelated classes?
I need to get a list of all classes that are subclasses of two unrelated classes.
For example I want to get a list of all classes that are both:
- Persistent (extends %Library.Persistent)
- XML-Enabled (extends %XML.Adaptor)
To get subclasses of one class I can use this query:
set rs = ##class(%Dictionary.ClassDefinitionQuery).SubclassOfFunc("%Library.Persistent")
But what about two classes?
I suppose I can run this query twice, build two $lb, then iterate over one of them and build a new $lb with classes that appear in both lists. Are there any better approaches?