OryksaTvConfig class

Everything the TV pieces read from the server: GET /v1/client/agent?locale=..., block tv.

Annotations

Constructors

OryksaTvConfig({required String locale, required String presenterName, required String presenterAvatar, String? voiceRev, OryksaTvTexts texts = const OryksaTvTexts({}), List<String> suggestions = const [], List<OryksaTvAction> actions = const [], OryksaTvRules rules = const OryksaTvRules(), bool fromServer = true})
Creates a configuration.
const
OryksaTvConfig.fromAgentJson(Map<String, dynamic> j, {required String requestedLocale})
Reads the answer of GET /v1/client/agent?locale=.... Without a tv block (older servers) fromServer is false and the texts are the English fallback.
factory

Properties

actions → List<OryksaTvAction>
Buttons of the assistant panel.
final
fromServer → bool
False when the server sent no tv block (older servers).
final
hashCode → int
The hash code for this object.
no setterinherited
locale → String
The locale the server chose (one of the supported ones), for example pt-BR.
final
presenterAvatar → String
Photo of the presenter.
final
presenterName → String
Name of the presenter (the AI), for example ORYKSA.
final
rules → OryksaTvRules
Rules.
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
suggestions → List<String>
Suggested questions for the assistant panel.
final
texts → OryksaTvTexts
Texts of the TV pieces.
final
voiceRev → String?
Changes when the business changes the voice of this locale (keys the voice cache).
final

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() → String
A string representation of this object.
inherited

Operators

operator ==(Object other) → bool
The equality operator.
inherited

Constants

defaultAvatar → const String
Default photo of the AI when the server sends none.