upload method
Starts uploading a log file to the server.
Initiates an upload operation; progress and final status are reported via
the onLogStatusChanged callback supplied when the LogUploader was
created.
Parameters
logPath: Path to the log file to upload.userName: User name to associate with the upload.userMail: User email to associate with the upload.details: Optional additional details describing the upload.externalFiles: Optional list of additional file paths to include in the upload. Can be used to attach screenshots, logs, or other relevant files.
Returns
- A GemError indicating the immediate outcome of the start request (for example, GemError.success when the operation was accepted).
See also:
- cancel — cancels an ongoing upload.
Implementation
GemError upload({
required final String logPath,
required final String userName,
required final String userMail,
final String details = '',
final List<String> externalFiles = const <String>[],
}) {
final OperationResult resultString = objectMethod(
pointerId,
'LogUploader',
'upload',
args: <String, Object>{
'logPath': logPath,
'userName': userName,
'userMail': userMail,
'details': details,
'externalFiles': externalFiles,
},
);
return GemErrorExtension.fromCode(resultString['result']);
}