MessageFilterTable<TFilterData>.Item[MessageFilter] Property
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.
Gets or sets the filter data associated with the specified filter
.
public:
property TFilterData default[System::ServiceModel::Dispatcher::MessageFilter ^] { TFilterData get(System::ServiceModel::Dispatcher::MessageFilter ^ filter); void set(System::ServiceModel::Dispatcher::MessageFilter ^ filter, TFilterData value); };
public TFilterData this[System.ServiceModel.Dispatcher.MessageFilter filter] { get; set; }
member this.Item(System.ServiceModel.Dispatcher.MessageFilter) : 'FilterData with get, set
Default Public Property Item(filter As MessageFilter) As TFilterData
- filter
- MessageFilter
The MessageFilter associated with the filter data to get or set.
The filter data associated with the filter
. If the specified filter
is not found, a get operation throws a KeyNotFoundException, and a set operation creates a new filter data element with the specified filter
as the key.
filter
is null
.
The property is retrieved, and the filter
is not in the table.
The Item
property (the indexer in C#) provides the ability to access the filter data associated with a filter
in the table's filter collection by using the following syntax.
myFilters[filter]
myFilters(filter)
You can also use the Item
property to add new elements by setting the values of a filter
/filter data pair that does not exist in the action filter table. However if filter
is already in the table, setting the Item
property overwrites the old value. In contrast, the Add method does not modify the filter data of an existing filter
.
The dictionary item
is a filter/FilterData
pair in the case of MessageFilterTable<TFilterData>.
Producto | Versiones |
---|---|
.NET Framework | 3.0, 3.5, 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8, 4.8.1 |
Comentarios de .NET
.NET es un proyecto de código abierto. Seleccione un vínculo para proporcionar comentarios: