2024-06-12 02:42:10 +02:00
|
|
|
// Copyright 2024, Command Line Inc.
|
|
|
|
// SPDX-License-Identifier: Apache-2.0
|
|
|
|
|
|
|
|
// generated by cmd/generate/main-generate.go
|
|
|
|
|
|
|
|
import * as WOS from "./wos";
|
|
|
|
|
|
|
|
// blockservice.BlockService (block)
|
|
|
|
class BlockServiceType {
|
2024-06-18 07:38:48 +02:00
|
|
|
SaveTerminalState(arg2: string, arg3: string, arg4: string, arg5: number): Promise<void> {
|
|
|
|
return WOS.callBackendService("block", "SaveTerminalState", Array.from(arguments))
|
|
|
|
}
|
|
|
|
|
2024-06-12 02:42:10 +02:00
|
|
|
// send command to block
|
2024-06-12 22:47:13 +02:00
|
|
|
SendCommand(blockid: string, cmd: BlockCommand): Promise<void> {
|
2024-06-12 02:42:10 +02:00
|
|
|
return WOS.callBackendService("block", "SendCommand", Array.from(arguments))
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
export const BlockService = new BlockServiceType()
|
|
|
|
|
|
|
|
// clientservice.ClientService (client)
|
|
|
|
class ClientServiceType {
|
|
|
|
GetClientData(): Promise<Client> {
|
|
|
|
return WOS.callBackendService("client", "GetClientData", Array.from(arguments))
|
|
|
|
}
|
|
|
|
GetTab(arg1: string): Promise<Tab> {
|
|
|
|
return WOS.callBackendService("client", "GetTab", Array.from(arguments))
|
|
|
|
}
|
|
|
|
GetWindow(arg1: string): Promise<Window> {
|
|
|
|
return WOS.callBackendService("client", "GetWindow", Array.from(arguments))
|
|
|
|
}
|
|
|
|
GetWorkspace(arg1: string): Promise<Workspace> {
|
|
|
|
return WOS.callBackendService("client", "GetWorkspace", Array.from(arguments))
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
export const ClientService = new ClientServiceType()
|
|
|
|
|
|
|
|
// fileservice.FileService (file)
|
|
|
|
class FileServiceType {
|
|
|
|
GetWaveFile(arg1: string, arg2: string): Promise<any> {
|
|
|
|
return WOS.callBackendService("file", "GetWaveFile", Array.from(arguments))
|
|
|
|
}
|
|
|
|
ReadFile(arg1: string): Promise<FullFile> {
|
|
|
|
return WOS.callBackendService("file", "ReadFile", Array.from(arguments))
|
|
|
|
}
|
|
|
|
StatFile(arg1: string): Promise<FileInfo> {
|
|
|
|
return WOS.callBackendService("file", "StatFile", Array.from(arguments))
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
export const FileService = new FileServiceType()
|
|
|
|
|
|
|
|
// objectservice.ObjectService (object)
|
|
|
|
class ObjectServiceType {
|
|
|
|
// @returns tabId (and object updates)
|
|
|
|
AddTabToWorkspace(tabName: string, activateTab: boolean): Promise<string> {
|
|
|
|
return WOS.callBackendService("object", "AddTabToWorkspace", Array.from(arguments))
|
|
|
|
}
|
|
|
|
|
|
|
|
// @returns object updates
|
|
|
|
CloseTab(tabId: string): Promise<void> {
|
|
|
|
return WOS.callBackendService("object", "CloseTab", Array.from(arguments))
|
|
|
|
}
|
|
|
|
|
|
|
|
// @returns blockId (and object updates)
|
|
|
|
CreateBlock(blockDef: BlockDef, rtOpts: RuntimeOpts): Promise<string> {
|
|
|
|
return WOS.callBackendService("object", "CreateBlock", Array.from(arguments))
|
|
|
|
}
|
|
|
|
|
|
|
|
// @returns object updates
|
|
|
|
DeleteBlock(blockId: string): Promise<void> {
|
|
|
|
return WOS.callBackendService("object", "DeleteBlock", Array.from(arguments))
|
|
|
|
}
|
|
|
|
|
|
|
|
// get wave object by oref
|
|
|
|
GetObject(oref: string): Promise<WaveObj> {
|
|
|
|
return WOS.callBackendService("object", "GetObject", Array.from(arguments))
|
|
|
|
}
|
|
|
|
|
|
|
|
// @returns objects
|
|
|
|
GetObjects(orefs: string[]): Promise<WaveObj[]> {
|
|
|
|
return WOS.callBackendService("object", "GetObjects", Array.from(arguments))
|
|
|
|
}
|
|
|
|
|
|
|
|
// @returns object updates
|
|
|
|
SetActiveTab(tabId: string): Promise<void> {
|
|
|
|
return WOS.callBackendService("object", "SetActiveTab", Array.from(arguments))
|
|
|
|
}
|
|
|
|
|
|
|
|
// @returns object updates
|
|
|
|
UpdateObject(waveObj: WaveObj, returnUpdates: boolean): Promise<void> {
|
|
|
|
return WOS.callBackendService("object", "UpdateObject", Array.from(arguments))
|
|
|
|
}
|
|
|
|
|
|
|
|
// @returns object updates
|
|
|
|
UpdateObjectMeta(oref: string, meta: MetaType): Promise<void> {
|
|
|
|
return WOS.callBackendService("object", "UpdateObjectMeta", Array.from(arguments))
|
|
|
|
}
|
2024-06-18 06:50:33 +02:00
|
|
|
|
|
|
|
// @returns object updates
|
|
|
|
UpdateWorkspaceTabIds(workspaceId: string, tabIds: string[]): Promise<void> {
|
|
|
|
return WOS.callBackendService("object", "UpdateWorkspaceTabIds", Array.from(arguments))
|
|
|
|
}
|
2024-06-12 02:42:10 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
export const ObjectService = new ObjectServiceType()
|
|
|
|
|
2024-06-17 18:58:28 +02:00
|
|
|
// windowservice.WindowService (window)
|
|
|
|
class WindowServiceType {
|
|
|
|
// @returns object updates
|
|
|
|
SetWindowPosAndSize(arg2: string, arg3: Point, arg4: WinSize): Promise<void> {
|
|
|
|
return WOS.callBackendService("window", "SetWindowPosAndSize", Array.from(arguments))
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
export const WindowService = new WindowServiceType()
|
|
|
|
|