Class DetailsViewModel<T>
A base view model for displaying item details.
Inheritance
DetailsViewModel<T>
Inherited Members
Namespace: Phoenix.BotBrain
Assembly: Phoenix.Plugin.BotBrain.Parameters.dll
Syntax
public class DetailsViewModel<T> : DetailsViewModel, INotifyPropertyChanged, IOnSelected
Type Parameters
Name | Description |
---|---|
T | The item type name. |
Remarks
Initializes a new instance of the DetailsViewModel<T> class.
Constructors
View SourceDetailsViewModel(IParameterFactory, IServiceProvider, T)
A base view model for displaying item details.
Declaration
public DetailsViewModel(IParameterFactory parameterFactory, IServiceProvider serviceProvider, T item = default)
Parameters
Type | Name | Description |
---|---|---|
IParameterFactory | parameterFactory | The parameter factory. |
IServiceProvider | serviceProvider | The service provider. |
T | item | The initial item. |
Remarks
Initializes a new instance of the DetailsViewModel<T> class.
Properties
View SourceItem
Gets or sets the item.
Declaration
protected T Item { get; set; }
Property Value
Type | Description |
---|---|
T |
ParameterNames
Gets the parameter names for the item.
Declaration
public override IEnumerable<string> ParameterNames { get; }
Property Value
Type | Description |
---|---|
IEnumerable<string> |
Overrides
View SourceTelemetryClient
Gets the telemetry client.
Declaration
protected override ITelemetryClient? TelemetryClient { get; }
Property Value
Type | Description |
---|---|
ITelemetryClient |
Overrides
Methods
View SourceCreateParameters()
Creates the parameters for editing.
Declaration
protected virtual IEnumerable<IParameter> CreateParameters()
Returns
Type | Description |
---|---|
IEnumerable<IParameter> | An enumeration of parameters. |
OnParameterChanged(string)
Called when a parameter value changes.
Declaration
protected virtual void OnParameterChanged(string parameterName)
Parameters
Type | Name | Description |
---|---|---|
string | parameterName | The parameter name. |
ResetParameters()
Re-creates the parameter editor.
Declaration
protected virtual void ResetParameters()
ToString()
Returns a string that represents the current object.
Declaration
public override string ToString()
Returns
Type | Description |
---|---|
string | A string that represents the current object. |