PostSharp6.4/API Reference/Post­Sharp.​Patterns.​Collections.​Advices Namespace/Collection­Dynamic­Advice(T) Class

CollectionDynamicAdvice<T> Class

Base implementation of the ICollectionDynamicAdvice<T> interface.
Inheritance Hierarchy
System.Object
  PostSharp.Patterns.DynamicAdvising.DynamicAdvice
    PostSharp.Patterns.Collections.Advices.CollectionDynamicAdvice<T>

Namespace:  PostSharp.Patterns.Collections.Advices
Assembly:  PostSharp.Patterns.Common (in PostSharp.Patterns.Common.dll) Version: 6.4.3.0 (6.4.3.0)
Syntax
C#
public abstract class CollectionDynamicAdvice<T> : DynamicAdvice, 
	ICollectionDynamicAdvice<T>, ICollectionDynamicAdviceBase, IDynamicAdvice, IDynamicInterfaceImplementation

Type Parameters

T
Type of collection items.

The CollectionDynamicAdvice<T> type exposes the following members.

Constructors
  NameDescription
Protected methodCollectionDynamicAdvice<T>
Initializes a new CollectionDynamicAdvice<T>.
Properties
  NameDescription
Protected propertyAdvisedObject
Gets the advised object.
(Inherited from DynamicAdvice.)
Protected propertyCollection
Gets the target AdvisableCollection<T>.
Public propertyIdentity
Gets the type identity of the advice, which should correspond to the first parameter of the Advise(Type, Func<IQueryInterface, IDynamicAdvice>) method. This is typically the generic type definition of the advice
(Inherited from DynamicAdvice.)
Public propertyOrder
Gets the execution order of the dynamic advice. See DynamicAdviceOrder.
(Inherited from DynamicAdvice.)
Methods
  NameDescription
Public methodClearItems
Empties the advised collection.
Public methodDispose
Disposes the current advice. // We don't use IDisposable so that advises are not be cast to IDisposable by default.
(Inherited from DynamicAdvice.)
Public methodInitialize
Initializes the current advice.
(Inherited from DynamicAdvice.)
Public methodInsertItem
Inserts an item into the advised collection.
Public methodInsertMany
Inserts several items to the advised collection.
Public methodIsReadOnly
Determines whether the advised collection is read-only.
Public methodIsSynchronized
Determines whether the advised collection is synchronized (i.e. thread-safe).
Public methodMoveItem
Moves an item of the advised collection from an old index to a new index.
Public methodQueryInterface<TInterface> (Inherited from DynamicAdvice.)
Public methodRemoveItem
Removes an item from the advised collection.
Public methodRemoveMany
Removes several items from the advised collection.
Public methodSetItem
Replaces an item in the advised collection.
Public methodToArray
Copies the advised collection into a new array.
See Also