DeviceRegistrationState class

Represents the state of the device registration process.

Holds the list of organizations, product types, selected organization and product type, device details, submission status, error messages, and success state. Used by DeviceRegistrationCubit to manage the UI state for device registration.

Inheritance

Constructors

DeviceRegistrationState.new({List<Map<String, String>> organizationList = const [], List<String> productTypeList = const ["main", "mini"], String? selectedOrganizationId, String? selectedOrganizationName, String? selectedProductType, String deviceName = '', String kitId = '', String tabletSerialNumber = '', String tocoId = '', bool isSubmitting = false, String? errorMessage, bool isSuccess = false})
const

Properties

deviceName String
The entered device name.
final
errorMessage String?
Error message, if any, during registration.
final
hashCode int
The hash code for this object.
no setterinherited
isSubmitting bool
Whether the registration form is currently submitting.
final
isSuccess bool
Whether the registration was successful.
final
kitId String
The entered kit ID.
final
organizationList List<Map<String, String>>
List of available organizations for device registration.
final
productTypeList List<String>
List of available product types for device registration.
final
props List<Object?>
The list of properties that will be used to determine whether two instances are equal.
no setteroverride
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
selectedOrganizationId String?
The ID of the selected organization.
final
selectedOrganizationName String?
The name of the selected organization.
final
selectedProductType String?
The selected product type.
final
stringify bool?
If set to true, the toString method will be overridden to output this instance's props.
no setterinherited
tabletSerialNumber String
The entered tablet serial number.
final
tocoId String
The entered toco ID.
final

Methods

copyWith({List<Map<String, String>>? organizationList, List<String>? productTypeList, String? selectedOrganizationId, String? clearSelectedOrganizationId()?, String? selectedOrganizationName, String? clearSelectedOrganizationName()?, String? selectedProductType, String? clearSelectedProductType()?, String? deviceName, String? kitId, String? tabletSerialNumber, String? tocoId, bool? isSubmitting, String? errorMessage, String? clearErrorMessage()?, bool? isSuccess}) DeviceRegistrationState
Creates a copy of this state with the specified fields replaced.
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