@@ -256,6 +256,8 @@ class ClassDefinition extends @class_definition, ClassOrInterface, AST::ValueNod
256256 ClassDefinition getSuperClassDefinition ( ) {
257257 result = getSuperClass ( ) .analyze ( ) .getAValue ( ) .( AbstractClass ) .getClass ( )
258258 }
259+
260+ override string getAPrimaryQlClass ( ) { result = "ClassDefinition" }
259261}
260262
261263/**
@@ -342,6 +344,8 @@ private class ClassInitializedMember extends MemberDeclaration {
342344 ClassInitializedMember ( ) { this instanceof MethodDefinition or this .isStatic ( ) }
343345
344346 int getIndex ( ) { properties ( this , _, result , _, _) }
347+
348+ override string getAPrimaryQlClass ( ) { result = "ClassInitializedMember" }
345349}
346350
347351/**
@@ -361,6 +365,8 @@ class SuperExpr extends @super_expr, Expr {
361365 * which is the nearest enclosing non-arrow function.
362366 */
363367 Function getBinder ( ) { result = getEnclosingFunction ( ) .getThisBinder ( ) }
368+
369+ override string getAPrimaryQlClass ( ) { result = "SuperExpr" }
364370}
365371
366372/**
@@ -412,6 +418,8 @@ class SuperPropAccess extends PropAccess {
412418 */
413419class NewTargetExpr extends @newtarget_expr, Expr {
414420 override predicate isImpure ( ) { none ( ) }
421+
422+ override string getAPrimaryQlClass ( ) { result = "NewTargetExpr" }
415423}
416424
417425/**
@@ -574,6 +582,8 @@ class MemberDeclaration extends @property, Documentable {
574582 * True if this is abstract, ambient, or an overload signature.
575583 */
576584 predicate isSignature ( ) { not isConcrete ( ) }
585+
586+ override string getAPrimaryQlClass ( ) { result = "MemberDeclaration" }
577587}
578588
579589/**
@@ -748,7 +758,9 @@ private predicate hasOverloadedConstructorCallSignature(ClassOrInterface type) {
748758 * }
749759 * ```
750760 */
751- class MethodDefinition extends MethodDeclaration , MemberDefinition { }
761+ class MethodDefinition extends MethodDeclaration , MemberDefinition {
762+ override string getAPrimaryQlClass ( ) { result = "MethodDefinition" }
763+ }
752764
753765/**
754766 * A method signature declared in a class or interface, that is, a method without a function body.
@@ -763,7 +775,9 @@ class MethodDefinition extends MethodDeclaration, MemberDefinition { }
763775 *
764776 * Note that TypeScript call signatures are not considered method signatures.
765777 */
766- class MethodSignature extends MethodDeclaration , MemberSignature { }
778+ class MethodSignature extends MethodDeclaration , MemberSignature {
779+ override string getAPrimaryQlClass ( ) { result = "MethodSignature" }
780+ }
767781
768782/**
769783 * A constructor declaration in a class, either a concrete definition or a signature without a body.
@@ -792,6 +806,8 @@ class ConstructorDeclaration extends MethodDeclaration {
792806
793807 /** Holds if this is a synthetic default constructor. */
794808 predicate isSynthetic ( ) { getLocation ( ) .isEmpty ( ) }
809+
810+ override string getAPrimaryQlClass ( ) { result = "ConstructorDeclaration" }
795811}
796812
797813/**
@@ -813,7 +829,9 @@ class ConstructorDeclaration extends MethodDeclaration {
813829 * }
814830 * ```
815831 */
816- class ConstructorDefinition extends ConstructorDeclaration , MethodDefinition { }
832+ class ConstructorDefinition extends ConstructorDeclaration , MethodDefinition {
833+ override string getAPrimaryQlClass ( ) { result = "ConstructorDefinition" }
834+ }
817835
818836/**
819837 * A constructor signature declared in a class, that is, a constructor without a function body.
@@ -824,7 +842,9 @@ class ConstructorDefinition extends ConstructorDeclaration, MethodDefinition { }
824842 * }
825843 * ```
826844 */
827- class ConstructorSignature extends ConstructorDeclaration , MethodSignature { }
845+ class ConstructorSignature extends ConstructorDeclaration , MethodSignature {
846+ override string getAPrimaryQlClass ( ) { result = "ConstructorSignature" }
847+ }
828848
829849/**
830850 * A function generated by the extractor to implement a synthetic default constructor.
@@ -925,7 +945,9 @@ abstract class AccessorMethodSignature extends MethodSignature, AccessorMethodDe
925945 * }
926946 * ```
927947 */
928- class GetterMethodDeclaration extends AccessorMethodDeclaration , @property_getter { }
948+ class GetterMethodDeclaration extends AccessorMethodDeclaration , @property_getter {
949+ override string getAPrimaryQlClass ( ) { result = "GetterMethodDeclaration" }
950+ }
929951
930952/**
931953 * A concrete getter method definition in a class, that is, a getter method with a function body.
@@ -945,7 +967,9 @@ class GetterMethodDeclaration extends AccessorMethodDeclaration, @property_gette
945967 * }
946968 * ```
947969 */
948- class GetterMethodDefinition extends GetterMethodDeclaration , AccessorMethodDefinition { }
970+ class GetterMethodDefinition extends GetterMethodDeclaration , AccessorMethodDefinition {
971+ override string getAPrimaryQlClass ( ) { result = "GetterMethodDefinition" }
972+ }
949973
950974/**
951975 * A getter method signature declared in a class or interface, that is, a getter method without a function body.
@@ -958,7 +982,9 @@ class GetterMethodDefinition extends GetterMethodDeclaration, AccessorMethodDefi
958982 * }
959983 * ```
960984 */
961- class GetterMethodSignature extends GetterMethodDeclaration , AccessorMethodSignature { }
985+ class GetterMethodSignature extends GetterMethodDeclaration , AccessorMethodSignature {
986+ override string getAPrimaryQlClass ( ) { result = "GetterMethodSignature" }
987+ }
962988
963989/**
964990 * A setter method declaration in a class or interface, either a concrete definition or a signature without a body.
@@ -981,7 +1007,9 @@ class GetterMethodSignature extends GetterMethodDeclaration, AccessorMethodSigna
9811007 * }
9821008 * ```
9831009 */
984- class SetterMethodDeclaration extends AccessorMethodDeclaration , @property_setter { }
1010+ class SetterMethodDeclaration extends AccessorMethodDeclaration , @property_setter {
1011+ override string getAPrimaryQlClass ( ) { result = "SetterMethodDeclaration" }
1012+ }
9851013
9861014/**
9871015 * A concrete setter method definition in a class, that is, a setter method with a function body
@@ -1000,7 +1028,9 @@ class SetterMethodDeclaration extends AccessorMethodDeclaration, @property_sette
10001028 * }
10011029 * ```
10021030 */
1003- class SetterMethodDefinition extends SetterMethodDeclaration , AccessorMethodDefinition { }
1031+ class SetterMethodDefinition extends SetterMethodDeclaration , AccessorMethodDefinition {
1032+ override string getAPrimaryQlClass ( ) { result = "SetterMethodDefinition" }
1033+ }
10041034
10051035/**
10061036 * A setter method signature declared in a class or interface, that is, a setter method without a function body.
@@ -1013,7 +1043,9 @@ class SetterMethodDefinition extends SetterMethodDeclaration, AccessorMethodDefi
10131043 * }
10141044 * ```
10151045 */
1016- class SetterMethodSignature extends SetterMethodDeclaration , AccessorMethodSignature { }
1046+ class SetterMethodSignature extends SetterMethodDeclaration , AccessorMethodSignature {
1047+ override string getAPrimaryQlClass ( ) { result = "SetterMethodSignature" }
1048+ }
10171049
10181050/**
10191051 * A field declaration in a class or interface, either a concrete definition or an abstract or ambient field signature.
@@ -1047,6 +1079,8 @@ class FieldDeclaration extends MemberDeclaration, @field {
10471079
10481080 /** Holds if this is a TypeScript field marked as definitely assigned with the `!` operator. */
10491081 predicate hasDefiniteAssignmentAssertion ( ) { has_definite_assignment_assertion ( this ) }
1082+
1083+ override string getAPrimaryQlClass ( ) { result = "FieldDeclaration" }
10501084}
10511085
10521086/**
@@ -1203,4 +1237,6 @@ class IndexSignature extends @index_signature, MemberSignature {
12031237 override InterfaceDefinition getDeclaringType ( ) {
12041238 result = MemberSignature .super .getDeclaringType ( )
12051239 }
1240+
1241+ override string getAPrimaryQlClass ( ) { result = "IndexSignature" }
12061242}
0 commit comments