X hits on this document





212 / 396

Chapter ‎18   Unsafe code Interface implementations

A class-base specification may include a list of interface types, in which case the class is said to implement the given interface types. Interface implementations are discussed further in §‎13.4.

10.1.3 Class body

The class-body of a class defines the members of that class.

class-body: {   class-member-declarationsopt   }

10.2 Class members

The members of a class consist of the members introduced by its class-member-declarations and the members inherited from the direct base class.

class-member-declarations: class-member-declaration class-member-declarations   class-member-declaration

class-member-declaration: constant-declaration field-declaration method-declaration property-declaration event-declaration indexer-declaration operator-declaration constructor-declaration destructor-declaration static-constructor-declaration type-declaration

The members of a class are divided into the following categories:

Constants, which represent constant values associated with the class (§‎10.3).

Fields, which are the variables of the class (§‎10.4).

Methods, which implement the computations and actions that can be performed by the class (§‎10.5).

Properties, which define named characteristics and the actions associated with reading and writing those characteristics (§‎10.6).

Events, which define notifications that can be generated by the class (§‎10.7).

Indexers, which permit instances of the class to be indexed in the same way (syntactically) as arrays (§‎10.8).

Operators, which define the expression operators that can be applied to instances of the class (§‎10.9).

Instance constructors, which implement the actions required to initialize instances of the class (§‎10.10)

Destructors, which implement the actions to be performed before instances of the class are permanently discarded (§‎10.12).

Static constructors, which implement the actions required to initialize the class itself (§‎10.11).

Types, which represent the types that are local to the class (§‎9.5).

Copyright Microsoft Corporation 1999-2003. All Rights Reserved.199

Document info
Document views1112
Page views1112
Page last viewedMon Jan 16 22:57:35 UTC 2017