CodeQL library for C#
codeql/csharp-all 2.0.1-dev (changelog, source)
Search

Module Property

Provides classes for properties, indexers, and accessors.

Import path

import semmle.code.csharp.Property

Imports

Member

Provides classes relating to declarations and type members.

Stmt

Provides all statement classes.

Type

Provides classes for types.

Classes

Accessor

An accessor. Either a getter (Getter), a setter (Setter), or event accessor (EventAccessor).

DeclarationWithAccessors

A declaration that may have accessors. Either an event (Event), a property (Property), or an indexer (Indexer).

DeclarationWithGetSetAccessors

A declaration that may have a get accessor and a set accessor. Either a property (Property) or an indexer (Indexer).

Getter

A get accessor, for example get { return p; } in

Indexer

An indexer, for example string this[int i] on line 2 in

IndexerProperty

A Property which holds a type with an indexer.

Property

A property, for example P on line 2 in

Setter

A set accessor, for example set { p = value; } in

TrivialProperty

A property with a trivial getter and setter. For example, properties P1 and P2 are trivial, while P3 is not, in