NDepend.API Documentation
TargetCodeElements Property
NDepend.CodeQuery Namespace > IQueryExecutionSuccessResult Interface : TargetCodeElements Property
Gets code elements referenced in the query itself, like the code element named "XYZ" in "from t in Types where t.IsUsing("XYZ") select t".
Syntax
IReadOnlyList<ICodeElement> TargetCodeElements {get;}
Remarks
If a wildcard match expression is used, like "X*YZ" instead of "XYZ", the returned collection contains all matched code elements.
Targets code elements can be matched by following extension methods declared in NDepend.Reserved.CQLinq.NDepend.Reserved.CQLinq.ExtensionMethodsCQLinqDependency:
NDepend.Reserved.CQLinq.ExtensionMethodsCQLinqDependency.IsUsedBy(NDepend.CodeModel.IUsed,System.String), NDepend.Reserved.CQLinq.ExtensionMethodsCQLinqDependency.IsUsedByAssembly(NDepend.CodeModel.IUsed,System.String), NDepend.Reserved.CQLinq.ExtensionMethodsCQLinqDependency.IsUsedByNamespace(NDepend.CodeModel.IUsed,System.String), NDepend.Reserved.CQLinq.ExtensionMethodsCQLinqDependency.IsUsedByType(NDepend.CodeModel.IUsed,System.String), NDepend.Reserved.CQLinq.ExtensionMethodsCQLinqDependency.IsUsedByMethod(NDepend.CodeModel.IUsed,System.String), NDepend.Reserved.CQLinq.ExtensionMethodsCQLinqDependency.DepthOfIsUsedBy, NDepend.Reserved.CQLinq.ExtensionMethodsCQLinqDependency.IsIndirectlyUsedBy,
NDepend.Reserved.CQLinq.ExtensionMethodsCQLinqDependency.IsUsing(NDepend.CodeModel.IUser,System.String), NDepend.Reserved.CQLinq.ExtensionMethodsCQLinqDependency.IsUsingAssembly(NDepend.CodeModel.IUser,System.String), NDepend.Reserved.CQLinq.ExtensionMethodsCQLinqDependency.IsUsingNamespace(NDepend.CodeModel.IUser,System.String), NDepend.Reserved.CQLinq.ExtensionMethodsCQLinqDependency.IsUsingType(NDepend.CodeModel.IUser,System.String), NDepend.Reserved.CQLinq.ExtensionMethodsCQLinqDependency.IsUsingMethod(NDepend.CodeModel.IUser,System.String), NDepend.Reserved.CQLinq.ExtensionMethodsCQLinqDependency.IsUsingField(NDepend.CodeModel.IUser,System.String), NDepend.Reserved.CQLinq.ExtensionMethodsCQLinqDependency.DepthOfIsUsing, NDepend.Reserved.CQLinq.ExtensionMethodsCQLinqDependency.IsIndirectlyUsing,
NDepend.Reserved.CQLinq.ExtensionMethodsCQLinqDependency.ReturnTypeIs, NDepend.Reserved.CQLinq.ExtensionMethodsCQLinqDependency.FieldTypeIs, NDepend.Reserved.CQLinq.ExtensionMethodsCQLinqDependency.AssignField(NDepend.CodeModel.IMethod,System.String), NDepend.Reserved.CQLinq.ExtensionMethodsCQLinqDependency.DepthOfAssignField, NDepend.Reserved.CQLinq.ExtensionMethodsCQLinqDependency.CreateA(NDepend.CodeModel.IMethod,System.String), NDepend.Reserved.CQLinq.ExtensionMethodsCQLinqDependency.DepthOfCreateA, NDepend.Reserved.CQLinq.ExtensionMethodsCQLinqDependency.HasAttribute,
NDepend.Reserved.CQLinq.ExtensionMethodsCQLinqDependency.DeriveFrom(NDepend.CodeModel.IType,System.String), NDepend.Reserved.CQLinq.ExtensionMethodsCQLinqDependency.DepthOfDeriveFrom(NDepend.CodeModel.IType,System.String), NDepend.Reserved.CQLinq.ExtensionMethodsCQLinqDependency.Implement(NDepend.CodeModel.IType,System.String)
Requirements

Target Platforms: Windows 11, 10, 8, 7 and Linux, MacOS with net8.0, net7.0 or net6.0 installed

See Also

Reference

IQueryExecutionSuccessResult Interface
IQueryExecutionSuccessResult Members