Template class Null safety

A representation of a template for a message.

A stripped down message without coordinates and scheduling information.

Constructors

Template({required String header, required String message, required String id, required String fontFamily, required double fontSize, required int backgrondColour, required int foregroundColour, required double width, required double height, required String textAlignment})
Constructs a Template instance with the specified customisations.
Template.fromJson(Map<String, Object?> json)
Named constructor to create Template from a Map.

Properties

backgrondColour → int
The background colour of the template.
final
fontFamily → String
The font family of the header and message.
final
fontSize → double
The font size of the header and message.
final
foregroundColour → int
The foreground colour of the template i.e., text colour.
final
hashCode → int
The hash code for this object. [...]
read-only, inherited
The content in header.
final
height → double
The height of this template.
final
id → String
The id of this template, retrieved from storage.
final
message → String
The content in the main body.
final
runtimeType → Type
A representation of the runtime type of the object.
read-only, inherited
textAlignment → String
The text alignment. [...]
final
width → double
The width of this template.
final

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed. [...]
inherited
toJson() → Map<String, Object?>
The current instance as a Map.
toString() → String
A string representation of this object. [...]
inherited

Operators

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