Class ParsingConfig
Configuration class for System.Linq.Dynamic.Core.
Inherited Members
Namespace: System.Linq.Dynamic.Core
Assembly: System.Linq.Dynamic.Core.dll
Syntax
public class ParsingConfig
Properties
| Improve this Doc View SourceAllowNewToEvaluateAnyType
Allows the New() keyword to evaluate any available Type.
Default value is false.
Declaration
public bool AllowNewToEvaluateAnyType { get; set; }
Property Value
| Type | Description |
|---|---|
| Boolean |
AreContextKeywordsEnabled
Determines if the context keywords (it, parent, and root) are valid and usable inside a Dynamic Linq string expression.
Does not affect the usability of the equivalent context symbols ($, ^ and ~).
Default value is true.
Declaration
public bool AreContextKeywordsEnabled { get; set; }
Property Value
| Type | Description |
|---|---|
| Boolean |
CustomTypeProvider
Gets or sets the IDynamicLinkCustomTypeProvider.
Declaration
public IDynamicLinkCustomTypeProvider CustomTypeProvider { get; set; }
Property Value
| Type | Description |
|---|---|
| IDynamicLinkCustomTypeProvider |
DateTimeIsParsedAsUTC
By default DateTime (like 'Fri, 10 May 2019 11:03:17 GMT') is parsed as local time. Use this flag to parse all DateTime strings as UTC.
Default value is false.
Declaration
public bool DateTimeIsParsedAsUTC { get; set; }
Property Value
| Type | Description |
|---|---|
| Boolean |
Default
Default ParsingConfig
Declaration
public static ParsingConfig Default { get; }
Property Value
| Type | Description |
|---|---|
| ParsingConfig |
DefaultEFCore21
Default ParsingConfig for EntityFramework Core 2.1 and higher
Declaration
public static ParsingConfig DefaultEFCore21 { get; }
Property Value
| Type | Description |
|---|---|
| ParsingConfig |
DisableMemberAccessToIndexAccessorFallback
By default when a member is not found in a type and the type has a string based index accessor it will be parsed as an index accessor. Use this flag to disable this behaviour and have parsing fail when parsing an expression where a member access on a non existing member happens.
Default value is false.
Declaration
public bool DisableMemberAccessToIndexAccessorFallback { get; set; }
Property Value
| Type | Description |
|---|---|
| Boolean |
EvaluateGroupByAtDatabase
Gets or sets a value indicating whether the EntityFramework version supports evaluating GroupBy at database level. See https://docs.microsoft.com/en-us/ef/core/what-is-new/ef-core-2.1#linq-groupby-translation
Remark: when this setting is set to 'true', make sure to supply this ParsingConfig as first parameter on the extension methods.
Default value is false.
Declaration
public bool EvaluateGroupByAtDatabase { get; set; }
Property Value
| Type | Description |
|---|---|
| Boolean |
ExpressionPromoter
Gets or sets the IExpressionPromoter.
Declaration
public IExpressionPromoter ExpressionPromoter { get; set; }
Property Value
| Type | Description |
|---|---|
| IExpressionPromoter |
NumberParseCulture
The number parsing culture.
Default value is CultureInfo.InvariantCulture
Declaration
public CultureInfo NumberParseCulture { get; set; }
Property Value
| Type | Description |
|---|---|
| CultureInfo |
QueryableAnalyzer
Gets or sets the IQueryableAnalyzer.
Declaration
public IQueryableAnalyzer QueryableAnalyzer { get; set; }
Property Value
| Type | Description |
|---|---|
| IQueryableAnalyzer |
RenameParameterExpression
Renames the (Typed)ParameterExpression empty Name to a the correct supplied name from it.
Default value is false.
Declaration
public bool RenameParameterExpression { get; set; }
Property Value
| Type | Description |
|---|---|
| Boolean |
ResolveTypesBySimpleName
By default finding types by a simple name is not supported. Use this flag to use the CustomTypeProvider to resolve types by a simple name like "Employee" instead of "MyDatabase.Entities.Employee". Note that a first matching type is returned and this functionality needs to scan all types from all assemblies, so use with caution.
Default value is false.
Declaration
public bool ResolveTypesBySimpleName { get; set; }
Property Value
| Type | Description |
|---|---|
| Boolean |
SupportEnumerationsFromSystemNamespace
Support enumeration-types from the System namespace in mscorlib. An example could be "StringComparison".
Default value is true.
Declaration
public bool SupportEnumerationsFromSystemNamespace { get; set; }
Property Value
| Type | Description |
|---|---|
| Boolean |
UseDynamicObjectClassForAnonymousTypes
Gets or sets a value indicating whether to use dynamic object class for anonymous types.
Default value is false.
Declaration
public bool UseDynamicObjectClassForAnonymousTypes { get; set; }
Property Value
| Type | Description |
|---|---|
| Boolean |
UseParameterizedNamesInDynamicQuery
Use Parameterized Names in generated dynamic SQL query. See https://github.com/graeme-hill/gblog/blob/master/source_content/articles/2014.139_entity-framework-dynamic-queries-and-parameterization.mkd
Default value is false.
Declaration
public bool UseParameterizedNamesInDynamicQuery { get; set; }
Property Value
| Type | Description |
|---|---|
| Boolean |