Show / Hide Table of Contents

Class FuncFactory<TTuple, TResult>

Provides an easy way of invoking an Func<TResult> function delegate regardless of the amount of parameters provided.

Inheritance
Object
TemplateFactory<TTuple>
FuncFactory<TTuple, TResult>
Inherited Members
TemplateFactory<TTuple>.GenericArguments
TemplateFactory<TTuple>.HasDelegate
TemplateFactory<TTuple>.DelegateInfo
TemplateFactory<TTuple>.ToString()
TemplateFactory<TTuple>.ThrowIfNoValidDelegate(Boolean)
Namespace: Cuemon
Assembly: Cuemon.Core.dll
Syntax
public sealed class FuncFactory<TTuple, TResult> : TemplateFactory<TTuple> where TTuple : Template
Type Parameters
Name Description
TTuple

The type of the n-tuple representation of a Template.

TResult

The type of the return value of the function delegate Cuemon.FuncFactory`2.Method.

Constructors

| Improve this Doc View Source

FuncFactory(Func<TTuple, TResult>, TTuple)

Initializes a new instance of the FuncFactory<TTuple, TResult> class.

Declaration
public FuncFactory(Func<TTuple, TResult> method, TTuple tuple)
Parameters
Type Name Description
Func<TTuple, TResult> method

The function delegate to invoke.

TTuple tuple

The n-tuple argument of method.

Methods

| Improve this Doc View Source

Clone()

Creates a shallow copy of the current FuncFactory<TTuple, TResult> object.

Declaration
public override TemplateFactory<TTuple> Clone()
Returns
Type Description
TemplateFactory<TTuple>

A new FuncFactory<TTuple, TResult> that is a copy of this instance.

Overrides
Cuemon.TemplateFactory<TTuple>.Clone()
Remarks

When thread safety is required this is the method to invoke.

| Improve this Doc View Source

ExecuteMethod()

Executes the function delegate associated with this instance.

Declaration
public TResult ExecuteMethod()
Returns
Type Description
TResult

The result of the the function delegate associated with this instance.

  • Improve this Doc
  • View Source
In This Article
Back to top Copyright 2008-2022 Geekle. All rights reserved. Code with passion and love; deploy with confidence. 👨‍💻️🔥❤️🚀😎
Generated by DocFX