Share via


ExpressionBuilder Class [IIS 7 and higher]

Maps an expression prefix to an expression builder type.

Syntax

class ExpressionBuilder : CollectionElement

Methods

This class contains no methods.

Properties

The following table lists the properties exposed by the ExpressionBuilder class.

Name

Description

ExpressionPrefix

A read-only string value that contains the prefix for the current expression builder object. The key property.

Type

A read/write string value that contains a type associated with the prefix specified in the ExpressionPrefix property.

Subclasses

This class contains no subclasses.

Remarks

Instances of this class are contained in the ExpressionBuilders array property of the ExpressionBuilderSettings class.

Expression builders allow property values to be set and retrieved in a control during page parsing. When the page parser encounters an expression in the format <%$ prefix:value %>, it creates an expression builder based on prefix and passes the value to the expression builder for evaluation. The expression builder then returns the requested value to the page.

ExpressionPrefix values are associated with expression builders in the <expressionBuilders> section of a Web.config file, as the following example shows:

<configuration>

<system.web>

<compilation>

<expressionBuilders>

<add expressionPrefix="TCO"

type="Contoso.Finance.TCOExpressionBuilder"/>

</expressionBuilders>

</compilation>

</system.web>

</configuration>

Inheritance Hierarchy

CollectionElement

   ExpressionBuilder

Requirements

Type

Description

Client

Requires IIS 7 on Windows Vista.

Server

Requires IIS 7 on Windows Server 2008.

Product

IIS 7

MOF file

WebAdministration.mof

See Also

Reference

CollectionElement Class [IIS 7 and higher]

CompilationSection Class [IIS 7 and higher]

ExpressionBuilderSettings Class [IIS 7 and higher]

ExpressionPrefixAttribute

CompilationSectionExpressionBuilders()()()()