Transfer
Overview
This class contains a collection of classes to represent the results of various transfer operations, including firmware, template, database, and raw binary file transfers.
Types
Result
The Result
class provides the result of a transfer operation. This includes the overall success or failure status, detailed error codes for each operation, and logs.
Properties
Name | Type | Description |
---|---|---|
errorCodeDetails | Map< T, ErrorCode > |
Detailed error codes for each transfer operation, where T represents the value of the transfer operation's argument. |
errorCode | SummaryErrorCode |
The summary error code indicating the overall result of the transfer operation. |
allLogs | List<Log > |
Logs related to the transfer operation. |
SummaryErrorCode
Declaration
enum class SummaryErrorCode(val id: Int) {
AllSuccess(0 + SummaryErrorCodeBaseID),
PartialSuccess(1 + SummaryErrorCodeBaseID),
AllFailed(2 + SummaryErrorCodeBaseID),
InitializationFailed(3 + SummaryErrorCodeBaseID),
InvalidArgument(4 + SummaryErrorCodeBaseID),
UnknownError(99 + SummaryErrorCodeBaseID),
}
Description
Constant | Description |
---|---|
AllSuccess | All operations were successful. |
PartialSuccess | Some operations were successful, while others failed. |
AllFailed | All operations failed. |
InitializationFailed | The initialization of the operation failed. |
InvalidArgument | An invalid argument was provided. |
UnknownError | An unknown error occurred. |
ErrorCode
Declaration
enum class ErrorCode(val id: Int) {
NoError(0 + ErrorCodeBaseID),
UnsupportedFunction(1 + ErrorCodeBaseID),
UnsupportedFunctionByCurrentConnectionInterface(2 + ErrorCodeBaseID),
FileNotFound(3 + ErrorCodeBaseID),
UnsupportedFile(4 + ErrorCodeBaseID),
FileNotForSelectedPrinter(5 + ErrorCodeBaseID),
PrinterStatusError(6 + ErrorCodeBaseID),
ConnectionFailed(7 + ErrorCodeBaseID),
Aborted(8 + ErrorCodeBaseID),
UnknownError(9 + ErrorCodeBaseID),
}
Description
Constant | Description |
---|---|
NoError | The operation was successful. |
UnsupportedFunction | The function is not supported by the printer. |
UnsupportedFunctionByCurrentConnectionInterface | The function is not supported by the current connection interface, but may be supported by other interfaces. |
FileNotFound | The specified file was not found. |
UnsupportedFile | The file format is not supported, or the file is corrupted. |
FileNotForSelectedPrinter | The file is not compatible with the selected printer. |
PrinterStatusError | The printer is in an unresponsive state. |
ConnectionFailed | The connection to the printer failed. |
Aborted | The operation was aborted due to cancellation or an error. |
UnknownError | An unknown error occurred. |
Constants
Constant | Value | Description |
---|---|---|
SummaryErrorCodeBaseID | 10000 | Base ID for SummaryErrorCode values. |
ErrorCodeBaseID | 10100 | Base ID for ErrorCode values. |