BindablePropertyKey Klasse
Definition
Wichtig
Einige Informationen beziehen sich auf Vorabversionen, die vor dem Release ggf. grundlegend überarbeitet werden. Microsoft übernimmt hinsichtlich der hier bereitgestellten Informationen keine Gewährleistungen, seien sie ausdrücklich oder konkludent.
Der geheime Schlüssel zu einer BindableProperty-Klasse, der zum Implementieren einer BindableProperty-Klasse mit eingeschränktem Schreibzugriff verwendet wird.
public ref class BindablePropertyKey sealed
public sealed class BindablePropertyKey
type BindablePropertyKey = class
Public NotInheritable Class BindablePropertyKey
- Vererbung
-
BindablePropertyKey
Hinweise
Das folgende Beispiel zeigt die Erstellung eines BindablePropertyKeys. Schreibzugriff wird internal während des Lesezugriffs ausgeführt public.
class Bindable : BindableObject
{
internal static readonly BindablePropertyKey FooPropertyKey =
BindableProperty.CreateReadOnly<Bindable, string> (w => w.Foo, default(string));
public static readonly BindableProperty FooProperty = FooPropertyKey.BindableProperty;
public string Foo {
get { return (string)GetValue (FooProperty); }
internal set { SetValue (FooPropertyKey, value); }
}
}
Eigenschaften
| BindableProperty |
Ruft die BindableProperty-Klasse ab. |