Class DataContractGameObject
A base class used to populate a DataContract with a generic game object.
Inherited Members
Namespace: Microsoft.XboxStudios.GameStateTracker.Generic
Assembly: GameStateTracker.Generic.DataContract.dll
Syntax
[DataContract]
public class DataContractGameObject : GenericGameObject, IGameObject, INotifyPropertyChanged
Constructors
View SourceDataContractGameObject(IGameObject)
Initializes a new instance of the DataContractGameObject class.
Declaration
public DataContractGameObject(IGameObject gameObject)
Parameters
| Type | Name | Description |
|---|---|---|
| IGameObject | gameObject | The game object to encapsulate. |
Methods
View SourceGetPropertyInfo(string)
Gets the property info for the given property.
Declaration
protected virtual PropertyInfo? GetPropertyInfo(string propertyName)
Parameters
| Type | Name | Description |
|---|---|---|
| string | propertyName | The property name. |
Returns
| Type | Description |
|---|---|
| PropertyInfo | The property info, if it exists. |
OnGameObjectPropertyChanged(object?, PropertyChangedEventArgs)
Called when a property changes on the underlying game object.
Declaration
protected override void OnGameObjectPropertyChanged(object? sender, PropertyChangedEventArgs e)
Parameters
| Type | Name | Description |
|---|---|---|
| object | sender | The sender. |
| PropertyChangedEventArgs | e | The property changed event args. |