Class FunctionDataType
Represents a function data type, i.e. akin to a delegate type.
Inherited Members
Namespace: Nuqleon.DataModel.TypeSystem
Assembly: Nuqleon.DataModel.CompilerServices.dll
Syntax
public class FunctionDataType : DataType
Properties
Kind
Gets the kind of the data type.
Declaration
public override DataTypeKinds Kind { get; }
Property Value
Type | Description |
---|---|
DataTypeKinds |
Overrides
ParameterTypes
Gets the parameter types of the function.
Declaration
public ReadOnlyCollection<DataType> ParameterTypes { get; }
Property Value
Type | Description |
---|---|
System.Collections.ObjectModel.ReadOnlyCollection<DataType> |
ReturnType
Gets the return type of the function.
Declaration
public DataType ReturnType { get; }
Property Value
Type | Description |
---|---|
DataType |
Methods
CreateInstance(Object[])
Creates a new instance of the function data type.
Declaration
public override object CreateInstance(params object[] arguments)
Parameters
Type | Name | Description |
---|---|---|
System.Object[] | arguments | Only one parameter can be specified, containing the function object. |
Returns
Type | Description |
---|---|
System.Object | Instance of the function data type. |
Overrides
GetFunction(Object)
Gets a strongly typed function over a value to conforms to the data type.
Declaration
public Delegate GetFunction(object value)
Parameters
Type | Name | Description |
---|---|---|
System.Object | value | Object to get a strongly typed function for. |
Returns
Type | Description |
---|---|
System.Delegate | Strongly typed function over the given value. |