Event class

An event.

Events are way to associated a collection of methods defined on a given class. There are two required methods (add_ and remove_), plus an optional one (raise_). Events are described in §II.22.13 of the ECMA-335 spec.

Inheritance
Mixed in types

Constructors

Event(Scope scope, int token, int _parentToken, String name, int _attributes, int eventType, int _addOnToken, int _removeOnToken, int _fireToken, List<int> otherMethodTokens)
Event.fromToken(Scope scope, int token)
Creates an event object from a provided token.
factory

Properties

addMethod Method?
Returns the add method for the event.
no setter
customAttributes Iterable<CustomAttribute>
latefinalinherited
eventType int
final
hashCode int
The hash code for this object.
no setterinherited
isGlobal bool
Returns true if the token is marked as global.
no setterinherited
isResolvedToken bool
Returns true if the token maps to an entry in the WinMD database.
no setterinherited
isRTSpecialName bool
Returns true if the common language runtime should check the encoding of the event name.
no setter
isSpecialName bool
Returns true if the event is special; its name describes how.
no setter
name String
final
otherMethodTokens List<int>
final
parent TypeDef
Returns the TypeDef representing the class that declares the event.
no setter
raiseMethod Method?
Returns the raise method for the event.
no setter
reader → IMetaDataImport2
no setterinherited
removeMethod Method?
Returns the remove method for the event.
no setter
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
scope Scope
The Scope that contains this token.
finalinherited
token int
A unique identifier for this token in the metadata file.
finalinherited
tokenType TokenType
no setterinherited

Methods

attributeAsString(String attrName) String
Retrieve the string associated with a specific attribute name.
inherited
existsAttribute(String attrName) bool
Whether this object has an attribute matching the given name.
inherited
findAttribute(String attrName) CustomAttribute?
Returns the first attribute matching the given name.
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
override

Operators

operator ==(Object other) bool
The equality operator.
inherited