Files

173 lines
6.3 KiB
TypeScript
Raw Permalink Normal View History

2024-06-11 17:42:10 -07:00
// Copyright 2024, Command Line Inc.
// SPDX-License-Identifier: Apache-2.0
2024-09-16 11:59:39 -07:00
// generated by cmd/generate/main-generatets.go
2024-06-11 17:42:10 -07:00
import * as WOS from "./wos";
// blockservice.BlockService (block)
class BlockServiceType {
2024-06-24 14:34:31 -07:00
GetControllerStatus(arg2: string): Promise<BlockControllerRuntimeStatus> {
return WOS.callBackendService("block", "GetControllerStatus", Array.from(arguments))
}
2024-06-17 22:38:48 -07:00
SaveTerminalState(arg2: string, arg3: string, arg4: string, arg5: number): Promise<void> {
return WOS.callBackendService("block", "SaveTerminalState", Array.from(arguments))
}
2024-07-29 22:35:21 -07:00
SaveWaveAiData(arg2: string, arg3: OpenAIPromptMessageType[]): Promise<void> {
return WOS.callBackendService("block", "SaveWaveAiData", Array.from(arguments))
}
2024-06-11 17:42:10 -07:00
}
2024-07-17 15:24:43 -07:00
export const BlockService = new BlockServiceType();
2024-06-11 17:42:10 -07:00
// clientservice.ClientService (client)
class ClientServiceType {
// @returns object updates
AgreeTos(): Promise<void> {
return WOS.callBackendService("client", "AgreeTos", Array.from(arguments))
}
2024-06-19 19:10:53 -07:00
FocusWindow(arg2: string): Promise<void> {
return WOS.callBackendService("client", "FocusWindow", Array.from(arguments))
}
2024-08-23 18:12:40 -07:00
GetAllConnStatus(): Promise<ConnStatus[]> {
return WOS.callBackendService("client", "GetAllConnStatus", Array.from(arguments))
}
2024-06-11 17:42:10 -07:00
GetClientData(): Promise<Client> {
return WOS.callBackendService("client", "GetClientData", Array.from(arguments))
}
GetTab(arg1: string): Promise<Tab> {
return WOS.callBackendService("client", "GetTab", Array.from(arguments))
}
2024-06-19 19:10:53 -07:00
GetWindow(arg1: string): Promise<WaveWindow> {
2024-06-11 17:42:10 -07:00
return WOS.callBackendService("client", "GetWindow", Array.from(arguments))
}
GetWorkspace(arg1: string): Promise<Workspace> {
return WOS.callBackendService("client", "GetWorkspace", Array.from(arguments))
}
2024-06-19 19:10:53 -07:00
MakeWindow(): Promise<WaveWindow> {
return WOS.callBackendService("client", "MakeWindow", Array.from(arguments))
}
2024-06-11 17:42:10 -07:00
}
2024-07-17 15:24:43 -07:00
export const ClientService = new ClientServiceType();
2024-06-11 17:42:10 -07:00
// fileservice.FileService (file)
class FileServiceType {
2024-08-19 11:02:40 -07:00
// delete file
DeleteFile(connection: string, path: string): Promise<void> {
2024-06-25 13:53:55 -07:00
return WOS.callBackendService("file", "DeleteFile", Array.from(arguments))
}
2024-08-27 18:49:49 -07:00
GetFullConfig(): Promise<FullConfigType> {
return WOS.callBackendService("file", "GetFullConfig", Array.from(arguments))
2024-06-19 23:59:41 -07:00
}
2024-06-11 17:42:10 -07:00
GetWaveFile(arg1: string, arg2: string): Promise<any> {
return WOS.callBackendService("file", "GetWaveFile", Array.from(arguments))
}
2024-08-19 11:02:40 -07:00
// read file
ReadFile(connection: string, path: string): Promise<FullFile> {
2024-06-11 17:42:10 -07:00
return WOS.callBackendService("file", "ReadFile", Array.from(arguments))
}
2024-08-19 11:02:40 -07:00
// save file
SaveFile(connection: string, path: string, data64: string): Promise<void> {
2024-07-18 14:41:33 +08:00
return WOS.callBackendService("file", "SaveFile", Array.from(arguments))
}
// get file info
StatFile(connection: string, path: string): Promise<FileInfo> {
2024-06-11 17:42:10 -07:00
return WOS.callBackendService("file", "StatFile", Array.from(arguments))
}
}
2024-07-17 15:24:43 -07:00
export const FileService = new FileServiceType();
2024-06-11 17:42:10 -07:00
// 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 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 12:50:33 +08:00
2024-06-22 01:23:04 +08:00
// @returns object updates
UpdateTabName(tabId: string, name: string): Promise<void> {
return WOS.callBackendService("object", "UpdateTabName", Array.from(arguments))
}
2024-06-18 12:50:33 +08:00
// @returns object updates
UpdateWorkspaceTabIds(workspaceId: string, tabIds: string[]): Promise<void> {
return WOS.callBackendService("object", "UpdateWorkspaceTabIds", Array.from(arguments))
}
2024-06-11 17:42:10 -07:00
}
2024-07-17 15:24:43 -07:00
export const ObjectService = new ObjectServiceType();
2024-06-11 17:42:10 -07:00
2024-07-18 15:21:33 -07:00
// userinputservice.UserInputService (userinput)
class UserInputServiceType {
SendUserInputResponse(arg1: UserInputResponse): Promise<void> {
return WOS.callBackendService("userinput", "SendUserInputResponse", Array.from(arguments))
}
}
export const UserInputService = new UserInputServiceType();
2024-06-17 09:58:28 -07:00
// windowservice.WindowService (window)
class WindowServiceType {
2024-06-19 19:10:53 -07:00
// @returns object updates
CloseTab(arg3: string): Promise<void> {
return WOS.callBackendService("window", "CloseTab", Array.from(arguments))
}
CloseWindow(arg2: string): Promise<void> {
return WOS.callBackendService("window", "CloseWindow", Array.from(arguments))
}
// move block to new window
// @returns object updates
MoveBlockToNewWindow(currentTabId: string, blockId: string): Promise<void> {
return WOS.callBackendService("window", "MoveBlockToNewWindow", Array.from(arguments))
}
2024-06-17 09:58:28 -07:00
// @returns object updates
SetWindowPosAndSize(arg2: string, arg3: Point, arg4: WinSize): Promise<void> {
return WOS.callBackendService("window", "SetWindowPosAndSize", Array.from(arguments))
}
}
2024-07-17 15:24:43 -07:00
export const WindowService = new WindowServiceType();
2024-06-17 09:58:28 -07:00