A generic factory method delegate that creates instances of a given type and takes a context object of a given type.

Namespace: yWorks.Support
Assembly: yWorks.yFilesSilverlight.Viewer (in yWorks.yFilesSilverlight.Viewer.dll) Version: 2.4.0.0

Syntax

C#
public delegate TResult FactoryDelegate<TResult, TContext>( TContext context )
Visual Basic
Public Delegate Function FactoryDelegate(Of TResult, TContext) ( _ context As TContext _ ) As TResult

Parameters

context
Type: TContext
The context to pass to the factory. The semantic of this value depends on the implementation and use.

Type Parameters

TResult
The type of the object to create.
TContext
The type of the context to provide to the factory method.

Return Value

A newly created instance, or a shared instance, or null, depending on the implementation and use case.

See Also