Skip to content

OperationController

OperationController exposes the persistent operation list to the frontend. It stays limited to DTO conversion and feature invocation.

  • Methods: 4
  • Referenced types: 1

Methods

CancelOperation

CancelOperation requests cancellation of a running background operation.

Go

go
CancelOperation(id string) error

TypeScript

ts
CancelOperation(id: string): Promise<void>

Parameters

NameType
idstring

Example

ts
await CancelOperation("id")

Source

internal/transport/wails/operation_controller.go:29

ClearOperationHistory

ClearOperationHistory removes completed operation records and returns the count removed.

Go

go
ClearOperationHistory() (int64, error)

TypeScript

ts
ClearOperationHistory(): Promise<number>

Returns

Go typeTypeScript type
int64number

Example

ts
const clearOperationHistory = await ClearOperationHistory()

Source

internal/transport/wails/operation_controller.go:39

DeleteOperation

DeleteOperation removes a completed operation from history.

Go

go
DeleteOperation(id string) error

TypeScript

ts
DeleteOperation(id: string): Promise<void>

Parameters

NameType
idstring

Example

ts
await DeleteOperation("id")

Source

internal/transport/wails/operation_controller.go:34

ListOperations

ListOperations returns tracked background operations for progress and history views.

Go

go
ListOperations() ([]OperationDTO, error)

TypeScript

ts
ListOperations(): Promise<OperationDTO[]>

Returns

Go typeTypeScript type
[]OperationDTOOperationDTO[]

Example

ts
const listOperations = await ListOperations()

Source

internal/transport/wails/operation_controller.go:19