CodeDomSerializerBase.SetExpression Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Associates an object with an expression.
Overloads
SetExpression(IDesignerSerializationManager, Object, CodeExpression) |
Associates an object with an expression. |
SetExpression(IDesignerSerializationManager, Object, CodeExpression, Boolean) |
Associates an object with an expression, optionally specifying a preset expression. |
SetExpression(IDesignerSerializationManager, Object, CodeExpression)
- Source:
- CodeDomSerializerBase.cs
- Source:
- CodeDomSerializerBase.cs
- Source:
- CodeDomSerializerBase.cs
Associates an object with an expression.
protected:
void SetExpression(System::ComponentModel::Design::Serialization::IDesignerSerializationManager ^ manager, System::Object ^ value, System::CodeDom::CodeExpression ^ expression);
protected void SetExpression (System.ComponentModel.Design.Serialization.IDesignerSerializationManager manager, object value, System.CodeDom.CodeExpression expression);
member this.SetExpression : System.ComponentModel.Design.Serialization.IDesignerSerializationManager * obj * System.CodeDom.CodeExpression -> unit
Protected Sub SetExpression (manager As IDesignerSerializationManager, value As Object, expression As CodeExpression)
Parameters
- manager
- IDesignerSerializationManager
The IDesignerSerializationManager to use for serialization.
- value
- Object
The object to serialize.
- expression
- CodeExpression
The CodeExpression with which to associate value
.
Exceptions
manager
, value
, or expression
is null
.
Remarks
The SetExpression method is a helper method that associates a CodeExpression with an object. Objects that have been associated with expressions in this way are accessible through the GetExpression method. SetExpression stores its expression table as an appended object on the context stack so it is accessible by any serializer's GetExpression method.
See also
Applies to
SetExpression(IDesignerSerializationManager, Object, CodeExpression, Boolean)
- Source:
- CodeDomSerializerBase.cs
- Source:
- CodeDomSerializerBase.cs
- Source:
- CodeDomSerializerBase.cs
Associates an object with an expression, optionally specifying a preset expression.
protected:
void SetExpression(System::ComponentModel::Design::Serialization::IDesignerSerializationManager ^ manager, System::Object ^ value, System::CodeDom::CodeExpression ^ expression, bool isPreset);
protected void SetExpression (System.ComponentModel.Design.Serialization.IDesignerSerializationManager manager, object value, System.CodeDom.CodeExpression expression, bool isPreset);
member this.SetExpression : System.ComponentModel.Design.Serialization.IDesignerSerializationManager * obj * System.CodeDom.CodeExpression * bool -> unit
Protected Sub SetExpression (manager As IDesignerSerializationManager, value As Object, expression As CodeExpression, isPreset As Boolean)
Parameters
- manager
- IDesignerSerializationManager
The IDesignerSerializationManager to use for serialization.
- value
- Object
The object to serialize.
- expression
- CodeExpression
The CodeExpression with which to associate value
.
- isPreset
- Boolean
true
to specify a preset expression; otherwise, false
.
Remarks
The SetExpression method is a helper method that associates a CodeExpression with an object. Objects that have been associated with expressions in this way are accessible through the GetExpression method. The SetExpression stores its expression table as an appended object on the context stack so it is accessible by any serializer's GetExpression method.