Filters given array of targets by a given classes.
If classes are not given, then it returns array itself.
Type parameters
T: object
Parameters
array: T[]
Optional classes: any[]
Returns T[]
Static getInheritanceTree
getInheritanceTree(entity: Function): Function[]
Gets given's entity all inherited classes.
Gives in order from parents to children.
For example Post extends ContentModel which extends Unit it will give
[Unit, ContentModel, Post]
Metadata args utility functions.