CompositionPropertySet クラス

定義

値をキーと値のペアとして格納します。

public ref class CompositionPropertySet sealed : CompositionObject
/// [Windows.Foundation.Metadata.ContractVersion(Windows.Foundation.UniversalApiContract, 65536)]
/// [Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
/// [Windows.Foundation.Metadata.Threading(Windows.Foundation.Metadata.ThreadingModel.Both)]
class CompositionPropertySet final : CompositionObject
/// [Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
/// [Windows.Foundation.Metadata.Threading(Windows.Foundation.Metadata.ThreadingModel.Both)]
/// [Windows.Foundation.Metadata.ContractVersion(Windows.Foundation.UniversalApiContract, 131072)]
class CompositionPropertySet final : CompositionObject
[Windows.Foundation.Metadata.ContractVersion(typeof(Windows.Foundation.UniversalApiContract), 65536)]
[Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
[Windows.Foundation.Metadata.Threading(Windows.Foundation.Metadata.ThreadingModel.Both)]
public sealed class CompositionPropertySet : CompositionObject
[Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
[Windows.Foundation.Metadata.Threading(Windows.Foundation.Metadata.ThreadingModel.Both)]
[Windows.Foundation.Metadata.ContractVersion(typeof(Windows.Foundation.UniversalApiContract), 131072)]
public sealed class CompositionPropertySet : CompositionObject
Public NotInheritable Class CompositionPropertySet
Inherits CompositionObject
継承
Object Platform::Object IInspectable CompositionObject CompositionPropertySet
属性

Windows の要件

デバイス ファミリ
Windows 10 (10.0.10240.0 で導入)
API contract
Windows.Foundation.UniversalApiContract (v1.0 で導入)

void CreatePropertySet()
{
  // Create the CompositionPropertySet and insert a scalar value
  CompositionPropertySet sharedPropSet = _compositor.CreatePropertySet();
  sharedPropSet.InsertScalar("offsetChange", 50f);

  // Reference value in CompositionPropertySet in an Expression
  ExpressionAnimation expression =
  _compositor.CreateExpressionAnimation("this.Target.Offset.X + shared.offsetChange");
  expression.SetReferenceParameter("shared", sharedPropSet);
}

void PropertySetRetrieve(CompositionPropertySet propertySet)
{
  // Retrieve the value of key in a CompositionPropertySet
  float tempOffset;
  propertySet.TryGetScalar("offsetChange", out tempOffset);
}

注釈

CompositionPropertySets は CompositionObjects であり、アプリケーション全体で共有でき、別のコンポジション オブジェクトの有効期間に関連付けられていないキー値のペアを格納できます。 CompositionPropertySetは、最も一般的にアニメーションで使用され、コンポジション アニメーションのドライブ部分に参照されるキーと値のペアを保持します。 CompositionPropertySetは、キーと値のペアを挿入したり、特定のキーの値を取得したりする機能を提供します。 アニメーションで CompositionPropertySet を 使用する方法の詳細については、「 アニメーションの概要 」ページを参照してください。

CompositionPropertySet は削除関数をサポートしていません。CompositionPropertySet を使用して、アプリケーション全体で共有される値を格納してください。

Note

既に存在するキーの CompositionPropertySet に新しい値を挿入すると、古い値が新しい値で上書きされます。

バージョン履歴

Windows のバージョン SDK バージョン 追加された値
1607 14393 InsertBoolean
1607 14393 TryGetBoolean

プロパティ

Comment

CompositionObject に関連付ける文字列。

(継承元 CompositionObject)
Compositor

この CompositionObject の作成に使用するコンポジター

(継承元 CompositionObject)
Dispatcher

CompositionObject のディスパッチャー。

(継承元 CompositionObject)
DispatcherQueue

CompostionObject の DispatcherQueue を取得します。

(継承元 CompositionObject)
ImplicitAnimations

このオブジェクトにアタッチされている暗黙的なアニメーションのコレクション。

(継承元 CompositionObject)
Properties

CompositionObject に関連付けられているプロパティのコレクション。

(継承元 CompositionObject)

メソッド

Close()

CompositionObject を閉じ、システム リソースを解放します。

(継承元 CompositionObject)
ConnectAnimation(String, CompositionAnimation)

接続とアニメーション。

(継承元 CompositionObject)
DisconnectAnimation(String)

アニメーションを切断します。

(継承元 CompositionObject)
Dispose()

アンマネージ リソースの解放またはリセットに関連付けられているアプリケーション定義のタスクを実行します。

(継承元 CompositionObject)
InsertBoolean(String, Boolean)

ブール型のキーと値のペアを挿入します。

InsertColor(String, Color)

Color キーと値のペアを挿入します。

InsertMatrix3x2(String, Matrix3x2)

Matrix3x2 キーと値のペアを挿入します。

InsertMatrix4x4(String, Matrix4x4)

Matrix4x4 キーと値のペアを挿入します。

InsertQuaternion(String, Quaternion)

四元数キーと値のペアを挿入します。

InsertScalar(String, Single)

単一キーと値のペアを挿入します。

InsertVector2(String, Vector2)

Vector2 キーと値のペアを挿入します。

InsertVector3(String, Vector3)

Vector3 キーと値のペアを挿入します。

InsertVector4(String, Vector4)

Vector4 キーと値のペアを挿入します。

PopulatePropertyInfo(String, AnimationPropertyInfo)

アニメーション化できるプロパティを定義します。

(継承元 CompositionObject)
StartAnimation(String, CompositionAnimation)

アニメーションをオブジェクトの指定したプロパティに接続し、アニメーションを開始します。

(継承元 CompositionObject)
StartAnimation(String, CompositionAnimation, AnimationController)

アニメーションをオブジェクトの指定したプロパティに接続し、アニメーションを開始します。

(継承元 CompositionObject)
StartAnimationGroup(ICompositionAnimationBase)

アニメーション グループを開始します。

CompositionObject の StartAnimationGroup メソッドを使用すると、CompositionAnimationGroup を開始できます。 グループ内のすべてのアニメーションは、オブジェクトで同時に開始されます。

(継承元 CompositionObject)
StopAnimation(String)

指定したプロパティからアニメーションを切断し、アニメーションを停止します。

(継承元 CompositionObject)
StopAnimationGroup(ICompositionAnimationBase)

アニメーション グループを停止します。

(継承元 CompositionObject)
TryGetAnimationController(String)

指定したプロパティで実行されているアニメーションの AnimationController を返します。

(継承元 CompositionObject)
TryGetBoolean(String, Boolean)

指定したブール値プロパティ値を取得します。

TryGetColor(String, Color)

指定した Color プロパティ値を取得します。

TryGetMatrix3x2(String, Matrix3x2)

指定した Matrix3x2 プロパティ値を取得します。

TryGetMatrix4x4(String, Matrix4x4)

指定した Matrix4x4 プロパティ値を取得します。

TryGetQuaternion(String, Quaternion)

指定した四元数プロパティ値を取得します。

TryGetScalar(String, Single)

指定した Single プロパティ値 取得します。

TryGetVector2(String, Vector2)

指定した Vector2 プロパティ値を取得します。

TryGetVector3(String, Vector3)

指定した Vector3 プロパティ値を取得します。

TryGetVector4(String, Vector4)

指定した Vector4 プロパティ値を取得します。

適用対象

こちらもご覧ください