IReadOnlyPropertyCollection.Item property
Stores, alters, or accesses properties.
Namespace: Microsoft.Office.Server.Search.Query
Assembly: Microsoft.Office.Server.Search (in Microsoft.Office.Server.Search.dll)
Syntax
'Declaration
ReadOnly Default Property Item ( _
key As String _
) As Object
Get
'Usage
Dim instance As IReadOnlyPropertyCollection
Dim key As String
Dim value As Object
value = instance(key)
Object this[
string key
] { get; }
Parameters
key
Type: System.StringThe key of the property to access. It is case insensitive.
Property value
Type: System.Object
The value for the requested property as an object reference. It will have the same underlying type of the value that was stored in the property in the first place.
Exceptions
Exception | Condition |
---|---|
[!:ArgumentException] | If key is null or empty. |
KeyNotFoundException | If a property with the specified key is not found on IReadOnlyPropertyCollection. |
[!:FieldAccessException] | If the property being set has an internal/private setter. |
Remarks
Every property available on the class via property syntax, such as Properties.QueryText, also will be available via this accessor (for example, Properties["QueryTest"].
See also
Reference
IReadOnlyPropertyCollection interface