Open sandboxFocus

Method Literal

Literal(object?, bool)

Returns an expression that represents a literal.

Declaration
public static IExpression Literal(object? value, bool stronglyTyped = false)
Parameters
Type Name Description
object value

A literal value, or null to represent a null string.

bool stronglyTyped

A value indicating if the literal should be qualified to remove any type ambiguity, for instance if the value parameter contains a long that can also represent an int.

Returns
Type Description
IExpression

Literal(int)

Returns an expression that represents a literal of type int.

Declaration
public static IExpression Literal(int value)
Parameters
Type Name Description
int value
Returns
Type Description
IExpression

Literal(uint, bool)

Returns an expression that represents a literal of type uint.

Declaration
public static IExpression Literal(uint value, bool stronglyTyped = false)
Parameters
Type Name Description
uint value

The literal value.

bool stronglyTyped

A value indicating if the literal should be qualified to remove any type ambiguity, for instance if the literal can also represent an int.

Returns
Type Description
IExpression

Literal(short, bool)

Returns an expression that represents a literal of type short.

Declaration
public static IExpression Literal(short value, bool stronglyTyped = false)
Parameters
Type Name Description
short value

The literal value.

bool stronglyTyped

A value indicating if the literal should be qualified to remove any type ambiguity, for instance if the literal can also represent an int.

Returns
Type Description
IExpression

Literal(ushort, bool)

Returns an expression that represents a literal of type ushort.

Declaration
public static IExpression Literal(ushort value, bool stronglyTyped = false)
Parameters
Type Name Description
ushort value

The literal value.

bool stronglyTyped

A value indicating if the literal should be qualified to remove any type ambiguity, for instance if the literal can also represent an int.

Returns
Type Description
IExpression

Literal(long, bool)

Returns an expression that represents a literal of type long.

Declaration
public static IExpression Literal(long value, bool stronglyTyped = false)
Parameters
Type Name Description
long value

The literal value.

bool stronglyTyped

A value indicating if the literal should be qualified to remove any type ambiguity, for instance if the literal can also represent an int.

Returns
Type Description
IExpression

Literal(ulong, bool)

Returns an expression that represents a literal of type ulong.

Declaration
public static IExpression Literal(ulong value, bool stronglyTyped = false)
Parameters
Type Name Description
ulong value

The literal value.

bool stronglyTyped

A value indicating if the literal should be qualified to remove any type ambiguity, for instance if the literal can also represent an int.

Returns
Type Description
IExpression

Literal(byte, bool)

Returns an expression that represents a literal of type byte.

Declaration
public static IExpression Literal(byte value, bool stronglyTyped = false)
Parameters
Type Name Description
byte value

The literal value.

bool stronglyTyped

A value indicating if the literal should be qualified to remove any type ambiguity, for instance if the literal can also represent an int.

Returns
Type Description
IExpression

Literal(sbyte, bool)

Returns an expression that represents a literal of type sbyte.

Declaration
public static IExpression Literal(sbyte value, bool stronglyTyped = false)
Parameters
Type Name Description
sbyte value

The literal value.

bool stronglyTyped

A value indicating if the literal should be qualified to remove any type ambiguity, for instance if the literal can also represent an int.

Returns
Type Description
IExpression

Literal(double, bool)

Returns an expression that represents a literal of type double.

Declaration
public static IExpression Literal(double value, bool stronglyTyped = false)
Parameters
Type Name Description
double value

The literal value.

bool stronglyTyped

A value indicating if the literal should be qualified to remove any type ambiguity, for instance if the literal can also represent an int.

Returns
Type Description
IExpression

Literal(float, bool)

Returns an expression that represents a literal of type float.

Declaration
public static IExpression Literal(float value, bool stronglyTyped = false)
Parameters
Type Name Description
float value

The literal value.

bool stronglyTyped

A value indicating if the literal should be qualified to remove any type ambiguity, for instance if the literal can also represent an int.

Returns
Type Description
IExpression

Literal(decimal, bool)

Returns an expression that represents a literal of type decimal.

Declaration
public static IExpression Literal(decimal value, bool stronglyTyped = false)
Parameters
Type Name Description
decimal value

The literal value.

bool stronglyTyped

A value indicating if the literal should be qualified to remove any type ambiguity, for instance if the literal can also represent an int.

Returns
Type Description
IExpression

Literal(string?, bool)

Returns an expression that represents a literal of type string.

Declaration
public static IExpression Literal(string? value, bool stronglyTyped = false)
Parameters
Type Name Description
string value

The literal value.

bool stronglyTyped

A value indicating if the null value should be qualified as (string?) null.

Returns
Type Description
IExpression