Show / Hide Table of Contents

Class ExpressionCompiler

Implementation of ICreatesCSharpExpressions which uses the Roslyn Scripting API to create instances of CSharpExpression.

Inheritance
System.Object
ExpressionCompiler
Implements
ICreatesCSharpExpressions
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: ZptSharp.Expressions.CSharpExpressions
Assembly: ZptSharp.CSharpExpressions.dll
Syntax
public class ExpressionCompiler : ICreatesCSharpExpressions

Constructors

| Improve this Doc View Source

ExpressionCompiler(ILogger<ExpressionCompiler>, IGetsScriptBody)

Initializes a new instance of ExpressionCompiler.

Declaration
public ExpressionCompiler(ILogger<ExpressionCompiler> logger, IGetsScriptBody scriptBodyFactory)
Parameters
Type Name Description
Microsoft.Extensions.Logging.ILogger<ExpressionCompiler> logger

A logger.

IGetsScriptBody scriptBodyFactory

The script body factory.

Methods

| Improve this Doc View Source

GetExpressionAsync(ExpressionDescription, CancellationToken)

Gets the compiled expression.

Declaration
public Task<CSharpExpression> GetExpressionAsync(ExpressionDescription description, CancellationToken token = default(CancellationToken))
Parameters
Type Name Description
ExpressionDescription description

The expression identifier.

System.Threading.CancellationToken token

An optional cancellation token.

Returns
Type Description
System.Threading.Tasks.Task<CSharpExpression>

The compiled expression.

Implements

ICreatesCSharpExpressions
  • Improve this Doc
  • View Source
In This Article
Back to top Generated by DocFX