Class Presentation
How a profile presents itself on the dashboard: its custom elements, an optional theme, and the words for any state or event code it introduces.
public sealed record Presentation : IEquatable<Presentation>
- Inheritance
-
Presentation
- Implements
- Inherited Members
Constructors
Presentation(IReadOnlyList<ElementSpec>)
How a profile presents itself on the dashboard: its custom elements, an optional theme, and the words for any state or event code it introduces.
public Presentation(IReadOnlyList<ElementSpec> Elements)
Parameters
ElementsIReadOnlyList<ElementSpec>The custom sensors and node stats this profile contributes.
Properties
Elements
The custom sensors and node stats this profile contributes.
public IReadOnlyList<ElementSpec> Elements { get; init; }
Property Value
Messages
Gets the text for the codes this profile introduces, keyed by the page's message
key (state.flushing, event.filter_clog).
public IReadOnlyDictionary<string, LocalizedText>? Messages { get; init; }
Property Value
Theme
Gets an optional theme that tints the dashboard.
public Theme? Theme { get; init; }
Property Value
Methods
FromJson(string)
Reads a presentation from the JSON object a manifest carries under presentation.
public static Presentation FromJson(string json)
Parameters
jsonstringThe JSON object.
Returns
- Presentation
The presentation.
Exceptions
- JsonException
The text is not a presentation.
ToJson()
Writes this presentation as the JSON object a manifest carries.
public string ToJson()
Returns
- string
The JSON text.