PropertyPath クラス

定義

別のプロパティの下、または所有している型の下のパスとして、プロパティを記述するためのデータ構造を実装します。 プロパティ パスは、オブジェクトへのデータ バインディングで使用されます。

public ref class PropertyPath sealed : DependencyObject
/// [Windows.Foundation.Metadata.Activatable(Microsoft.UI.Xaml.IPropertyPathFactory, 65536, "Microsoft.UI.Xaml.WinUIContract")]
/// [Windows.Foundation.Metadata.ContractVersion(Microsoft.UI.Xaml.WinUIContract, 65536)]
/// [Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
/// [Windows.Foundation.Metadata.Threading(Windows.Foundation.Metadata.ThreadingModel.Both)]
class PropertyPath final : DependencyObject
[Windows.Foundation.Metadata.Activatable(typeof(Microsoft.UI.Xaml.IPropertyPathFactory), 65536, "Microsoft.UI.Xaml.WinUIContract")]
[Windows.Foundation.Metadata.ContractVersion(typeof(Microsoft.UI.Xaml.WinUIContract), 65536)]
[Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
[Windows.Foundation.Metadata.Threading(Windows.Foundation.Metadata.ThreadingModel.Both)]
public sealed class PropertyPath : DependencyObject
Public NotInheritable Class PropertyPath
Inherits DependencyObject
継承
Object Platform::Object IInspectable DependencyObject PropertyPath
属性

注釈

オブジェクトを操作PropertyPathするメイン理由は、既存のバインディング プロパティを複製し、別の場所で使用することです。

  • 既存のバインド (Binding.Path) からパスを取得します。
  • その文字列値を使用して、新しい PropertyPathを構築します。
  • 新しいバインドを作成 しますBinding.Path に新しい PropertyPath を使用します (また、他のプロパティも調整する可能性があります)。
  • SetBinding を使用して、新しい Binding を別のオブジェクトとプロパティの組み合わせに適用します。

アニメーションのターゲット設定では、プロパティ パスの構文に関するトピックで説明されているように、 プロパティ パス の概念も使用されます。 ただし、アニメーション ターゲットは基になる型としてを使用 PropertyPath せず、パスを文字列として表し、関連するすべての API 呼び出しに文字列を使用します。

コンストラクター

PropertyPath(String)

パス文字列に基づいて PropertyPath クラスの新しいインスタンスを初期化します。

プロパティ

Dispatcher

常に Windows アプリ SDK アプリで を返しますnull。 代わりに DispatcherQueue を使用してください。

(継承元 DependencyObject)
DispatcherQueue

このオブジェクトが DispatcherQueue 関連付けられている を取得します。 は DispatcherQueue 、コードが UI 以外のスレッドによって開始された場合でも、UI スレッド上の にアクセス DependencyObject できる機能を表します。

(継承元 DependencyObject)
Path

この PropertyPath によって保持されるパス値を取得します。

メソッド

ClearValue(DependencyProperty)

依存関係プロパティのローカル値をクリアします。

(継承元 DependencyObject)
GetAnimationBaseValue(DependencyProperty)

依存関係プロパティに対して確立された基本値を返します。これは、アニメーションがアクティブでない場合に適用されます。

(継承元 DependencyObject)
GetValue(DependencyProperty)

DependencyObject から依存関係プロパティの現在の有効な値を返します。

(継承元 DependencyObject)
ReadLocalValue(DependencyProperty)

ローカル値が設定されている場合は、依存関係プロパティのローカル値を返します。

(継承元 DependencyObject)
RegisterPropertyChangedCallback(DependencyProperty, DependencyPropertyChangedCallback)

この DependencyObject インスタンスの特定の DependencyProperty に対する変更をリッスンするための通知関数を登録します。

(継承元 DependencyObject)
SetValue(DependencyProperty, Object)

DependencyObject の依存関係プロパティのローカル値を設定します。

(継承元 DependencyObject)
UnregisterPropertyChangedCallback(DependencyProperty, Int64)

RegisterPropertyChangedCallback を呼び出して以前に登録した変更通知を取り消します。

(継承元 DependencyObject)

適用対象

こちらもご覧ください