Class CustomExpressionXmlConverter
Defined converter for XML element and expression.
Inheritance
CustomExpressionXmlConverter
Namespace: Sartorius.SAF.Serialization
Assembly: Sartorius.SAF.dll
Syntax
public abstract class CustomExpressionXmlConverter
Methods
View SourceTryDeserialize(XElement, out Expression)
Upon deserialization replace the Query (IQueryable) in the Expression tree with a new Query that has a different ConstantExpression. Re-create the Query, but with a different server-side IQueryProvider. For IQuery-Provider, we just create a Linq.EnumerableQuery`1. Need both a working IQueryProvider and a new Query with ConstantExpression equal to actual data.
Declaration
public abstract bool TryDeserialize(XElement expressionXml, out Expression e)
Parameters
| Type | Name | Description |
|---|---|---|
| XElement | expressionXml | An XML element. |
| Expression | e | An expression. |
Returns
| Type | Description |
|---|---|
| bool | True if deserialize was successful, otherwise false. |
TrySerialize(Expression, out XElement)
Try to serialize the given expression.
Declaration
public abstract bool TrySerialize(Expression expression, out XElement x)
Parameters
| Type | Name | Description |
|---|---|---|
| Expression | expression | An expression. |
| XElement | x | An XML element. |
Returns
| Type | Description |
|---|---|
| bool | True if deserialize was successful, otherwise false. |