BindingContext.GetInnerProperty<T> Metod

Definition

Returnerar ett typat objekt som begärs, om det finns, från lämpligt lager i bindningsstacken.

public:
generic <typename T>
 where T : class T GetInnerProperty();
public T GetInnerProperty<T>() where T : class;
member this.GetInnerProperty : unit -> 'T (requires 'T : null)
Public Function GetInnerProperty(Of T As Class) () As T

Typparametrar

T

Det typerade objekt som metoden frågar efter.

Returer

T

Det typerade objektet T begärdes om det finns eller null om det inte finns.

Exempel

CustomBinding binding = new CustomBinding();
BindingParameterCollection bpCol = new BindingParameterCollection();
BindingContext context = new BindingContext(binding, bpCol);
XmlDictionaryReaderQuotas quotas = context.GetInnerProperty<XmlDictionaryReaderQuotas>();
Dim binding As New CustomBinding()
Dim bpCol As New BindingParameterCollection()
Dim context As New BindingContext(binding, bpCol)
Dim quotas As XmlDictionaryReaderQuotas = context.GetInnerProperty(Of XmlDictionaryReaderQuotas)()

Kommentarer

Klonar bindningskontexten och anropar GetProperty<T>(BindingContext) nästa bindningselement som lagras i bindningskontexten.

Gäller för