Interface INumericInfo
Defines a contract for providing metadata about a numeric type.
Namespace: Primitively
Assembly: Primitively.Abstractions.dll
Syntax
public interface INumericInfo
Properties
CreateFrom
Gets a function that creates an instance of the numeric type from a string representation.
Declaration
Func<string?, IPrimitive> CreateFrom { get; init; }
Property Value
Type | Description |
---|---|
Func<string, IPrimitive> |
DataType
Gets the data type of the numeric type.
Declaration
DataType DataType { get; init; }
Property Value
Type | Description |
---|---|
DataType |
Example
Gets an example value of the numeric type in string format.
Declaration
string? Example { get; init; }
Property Value
Type | Description |
---|---|
string |
Type
Gets the .NET type of the numeric type.
Declaration
Type Type { get; init; }
Property Value
Type | Description |
---|---|
Type |
ValueType
Gets the .NET value type that the numeric type encapsulates.
Declaration
Type ValueType { get; init; }
Property Value
Type | Description |
---|---|
Type |