Merge pull request #40 from bcmi-labs/arduino-cli

Switched to the official `arduino-cli`.
This commit is contained in:
Akos Kitta 2019-07-25 09:57:13 +02:00 committed by GitHub
commit 83e966d208
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
46 changed files with 15428 additions and 10844 deletions

1
.gitignore vendored
View File

@ -3,6 +3,7 @@ node_modules/
.node_modules/
lib/
build/
downloads/
!electron/build/
src-gen/
arduino-ide-*/webpack.config.js

6
.vscode/launch.json vendored
View File

@ -4,6 +4,12 @@
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
"version": "0.2.0",
"configurations": [
{
"type": "node",
"request": "launch",
"name": "Launch Node.js Program",
"program": "${file}"
},
{
"type": "node",
"request": "launch",

View File

@ -40,5 +40,10 @@
}
}
}
},
"generator": {
"config": {
"preloadTemplate": "<div class='theia-preload' style='background-color: rgb(237, 241, 242);'></div>"
}
}
}

View File

@ -18,24 +18,34 @@
"@theia/workspace": "next",
"@theia/navigator": "next",
"@theia/terminal": "next",
"@types/which": "^1.3.1",
"css-element-queries": "^1.2.0",
"p-queue": "^5.0.0"
"p-queue": "^5.0.0",
"which": "^1.3.1"
},
"scripts": {
"generate-protoc": "./scripts/generate-protoc.sh && node ./scripts/patch-grpc-js.js",
"prepare": "yarn run clean && yarn run build",
"prepare": "yarn download-cli && yarn run clean && yarn run build",
"clean": "rimraf lib",
"download-cli": "node ./scripts/download-cli.js",
"generate-protocol": "node ./scripts/generate-protocol.js",
"lint": "tslint -c ./tslint.json --project ./tsconfig.json",
"build": "tsc && cp -rf src/node/cli-protocol lib/node && yarn lint",
"build": "tsc && ncp ./src/node/cli-protocol/ ./lib/node/cli-protocol/ && yarn lint",
"watch": "tsc -w"
},
"devDependencies": {
"@types/google-protobuf": "^3.2.7",
"decompress": "^4.2.0",
"decompress-tarbz2": "^4.1.1",
"decompress-unzip": "^4.0.1",
"download": "^7.1.0",
"grpc-tools": "^1.7.3",
"grpc_tools_node_protoc_ts": "^2.5.0",
"ncp": "^2.0.0",
"rimraf": "^2.6.1",
"shelljs": "^0.8.3",
"tslint": "^5.5.0",
"typescript": "2.9.1"
"typescript": "2.9.1",
"uuid": "^3.2.1",
"yargs": "^11.1.0"
},
"files": [
"lib",
@ -53,4 +63,4 @@
"frontendElectron": "lib/electron-browser/electron-arduino-menu-module"
}
]
}
}

View File

@ -0,0 +1,117 @@
// @ts-check
// The links to the downloads as of today (11.08.) are the followings:
// - https://downloads.arduino.cc/arduino-cli/nightly/arduino-cli-nightly-latest-${FILE_NAME}
// - https://downloads.arduino.cc/arduino-cli/arduino-cli-latest-${FILE_NAME}
(async () => {
const DEFAULT_VERSION = 'nightly';
const os = require('os');
const fs = require('fs');
const path = require('path');
const shell = require('shelljs');
const download = require('download');
const decompress = require('decompress');
const unzip = require('decompress-unzip');
const untarbz = require('decompress-tarbz2');
process.on('unhandledRejection', (reason, _) => {
shell.echo(String(reason));
shell.exit(1);
throw reason;
});
process.on('uncaughtException', error => {
shell.echo(String(error));
shell.exit(1);
throw error;
});
const yargs = require('yargs')
.option('cli-version', {
alias: 'cv',
default: DEFAULT_VERSION,
choices: [
// 'latest', // TODO: How do we get the source for `latest`. Currently, `latest` is the `0.3.7-alpha.preview`.
'nightly'
],
describe: `The version of the 'arduino-cli' to download. Defaults to ${DEFAULT_VERSION}.`
})
.option('force-download', {
alias: 'fd',
default: false,
describe: `If set, this script force downloads the 'arduino-cli' even if it already exists on the file system.`
})
.version(false).parse();
const version = yargs['cli-version'];
const force = yargs['force-download'];
const { platform, arch } = process;
const build = path.join(__dirname, '..', 'build');
const downloads = path.join(__dirname, '..', 'downloads');
const cli = path.join(build, `arduino-cli${os.platform() === 'win32' ? '.exe' : ''}`);
if (fs.existsSync(cli) && !force) {
shell.echo(`The 'arduino-cli' already exists at ${cli}. Skipping download.`);
shell.exit(0);
}
if (!fs.existsSync(build)) {
if (shell.mkdir('-p', build).code !== 0) {
shell.echo('Could not create new directory.');
shell.exit(1);
}
}
if (shell.rm('-rf', cli, downloads).code !== 0) {
shell.exit(1);
}
const suffix = (() => {
switch (platform) {
case 'darwin': return 'macosx.zip';
case 'win32': return 'windows.zip';
case 'linux': {
switch (arch) {
case 'arm64': return 'linuxarm.tar.bz2';
case 'x32': return 'linux32.tar.bz2';
case 'x64': return 'linux64.tar.bz2';
default: return undefined;
}
}
default: return undefined;
}
})();
if (!suffix) {
shell.echo(`The CLI is not available for ${platform} ${arch}.`);
shell.exit(1);
}
const url = `https://downloads.arduino.cc/arduino-cli/${version === 'nightly' ? 'nightly/' : ''}arduino-cli-${version}-latest-${suffix}`;
shell.echo(`>>> Downloading 'arduino-cli' from '${url}'...`);
const data = await download(url);
shell.echo(`<<< Download succeeded.`);
shell.echo('>>> Decompressing CLI...');
const files = await decompress(data, downloads, {
plugins: [
unzip(),
untarbz()
]
});
shell.echo('<<< Decompressing succeeded.');
if (files.length !== 1) {
shell.echo('Error ocurred when decompressing the CLI.');
shell.exit(1);
}
if (shell.mv('-f', path.join(downloads, files[0].path), cli).code !== 0) {
shell.echo(`Could not move file to ${cli}.`);
shell.exit(1);
}
if (!fs.existsSync(cli)) {
shell.echo(`Could not find CLI at ${cli}.`);
shell.exit(1);
} else {
shell.echo('Done.');
}
})();

View File

@ -1,43 +0,0 @@
#!/bin/bash
WORKDIR=/tmp/arduino-cli-protoc
echo "Working in $WORKDIR"
# this could be a Git submodule, but that feels to clunky for just building the protobuf stuff
mkdir -p $WORKDIR
pushd $WORKDIR
if [ ! -d arduino-cli ]; then
git clone https://github.com/typefox/arduino-cli
cd arduino-cli
git checkout daemon
cd -
mkdir -p go/src/github.com/arduino
ln -s $PWD/arduino-cli go/src/github.com/arduino
export GOPATH=$PWD/go
cd go/src/github.com/arduino/arduino-cli
GOOS=linux go build -o arduino-cli.linux
# GOOS=darwin go build -o arduino-cli.darwin
fi
popd
# make sure the output path exists
mkdir -p src/node/cli-protocol
export PATH=$PATH:$PWD/node_modules/.bin
# generate js codes via grpc-tools
grpc_tools_node_protoc \
--js_out=import_style=commonjs,binary:./src/node/cli-protocol \
--grpc_out=./src/node/cli-protocol \
--plugin=protoc-gen-grpc=`which grpc_tools_node_protoc_plugin` \
-I /usr/lib/protoc/include \
-I $WORKDIR/arduino-cli/rpc \
$WORKDIR/arduino-cli/rpc/*.proto
# generate d.ts codes
protoc \
--plugin=protoc-gen-ts=./node_modules/.bin/protoc-gen-ts \
--ts_out=./src/node/cli-protocol \
-I /usr/lib/protoc/include \
-I $WORKDIR/arduino-cli/rpc \
$WORKDIR/arduino-cli/rpc/*.proto

View File

@ -0,0 +1,81 @@
// @ts-check
(async () => {
const DEFAULT_VERSION = 'nightly'; // '0.3.7-alpha.preview';
const os = require('os');
const path = require('path');
const { v4 } = require('uuid');
const shell = require('shelljs');
shell.env.PATH = `${shell.env.PATH}${path.delimiter}${path.join(__dirname, '..', 'node_modules', '.bin')}`;
const yargs = require('yargs')
.option('cli-version', {
alias: 'cv',
default: DEFAULT_VERSION,
choices: [
// 'latest', // TODO: How do we get the source for `latest`. Currently, `latest` is the `0.3.7-alpha.preview`.
'nightly'
],
describe: `The version of the 'arduino-cli' to download. Specify either an existing version or use 'nightly'. Defaults to ${DEFAULT_VERSION}.`
})
.version(false).parse();
const version = yargs['cli-version'];
if (version !== 'nightly') {
shell.echo(`Only 'nightly' version is supported.`);
shell.exit(1);
}
const repository = path.join(os.tmpdir(), `${v4()}-arduino-cli`);
if (shell.mkdir('-p', repository).code !== 0) {
shell.exit(1);
}
if (shell.exec(`git clone https://github.com/arduino/arduino-cli.git ${repository}`).code !== 0) {
shell.exit(1);
}
if (version !== 'nightly') {
if (shell.exec(`git -C ${repository} checkout tags/${version} -b ${version}`).code !== 0) {
shell.exit(1);
}
}
shell.echo('Generating TS/JS API from:');
if (shell.exec(`git -C ${repository} rev-parse --abbrev-ref HEAD`).code !== 0) {
shell.exit(1);
}
if (shell.exec(`git -C ${repository} rev-parse --short HEAD`).code !== 0) {
shell.exit(1);
}
const pluginExec = shell.which('grpc_tools_node_protoc_plugin');
if (!pluginExec || pluginExec.code !== 0) {
shell.exit(1);
}
const plugin = pluginExec.stdout.trim();
const rpc = path.join(repository, 'rpc');
const out = path.join(__dirname, '..', 'src', 'node', 'cli-protocol');
// Generate JS code from the `.proto` files.
if (shell.exec(`grpc_tools_node_protoc \
--js_out=import_style=commonjs,binary:${out} \
--grpc_out=${out} \
--plugin=protoc-gen-grpc=${plugin} \
-I ${rpc} \
${path.join(rpc, '/**/*.proto')}`).code !== 0) {
shell.exit(1);
}
// Generate the `.d.ts` files for JS.
if (shell.exec(`protoc \
--plugin=protoc-gen-ts=${path.resolve(__dirname, '..', 'node_modules', '.bin', 'protoc-gen-ts')} \
--ts_out=${out} \
-I ${rpc} \
${path.join(rpc, '/**/*.proto')}`).code !== 0) {
shell.exit(1);
}
const { patch } = require('./patch-grpc-js');
patch([out])
shell.echo('Done.');
})();

View File

@ -1,25 +1,38 @@
// Use `@grpc/grpc-js` instead of `grpc` at runtime.
// https://github.com/grpc/grpc-node/issues/624
(() => {
const fs = require('fs');
const path = require('path');
const roots = ['src']; // XXX: patch the `lib` instead?
console.info("🔧 >>> Patching code. Switching from 'grpc' to '@grpc/grpc-js'...");
for (const root of roots) {
const cliProtocolPath = path.resolve(__dirname, '..', root, 'node', 'cli-protocol');
for (const fileName of fs.readdirSync(cliProtocolPath)) {
const filePath = path.resolve(cliProtocolPath, fileName);
let content = fs.readFileSync(filePath, { encoding: 'utf8' });
if (content.indexOf("require('grpc')") !== -1) {
console.info(`Updated require('grpc') to require('@grpc/grpc-js') in ${filePath}.`);
fs.writeFileSync(filePath, content.replace("require('grpc')", "require('@grpc/grpc-js')"));
}
content = fs.readFileSync(filePath, { encoding: 'utf8' });
if (content.indexOf('import * as grpc from "grpc"') !== -1) {
console.info(`Updated import * as grpc from "grpc" to import * as grpc from "@grpc/grpc-js" in ${filePath}.`);
fs.writeFileSync(filePath, content.replace('import * as grpc from "grpc"', 'import * as grpc from "@grpc/grpc-js"'));
// https://github.com/grpc/grpc-node/issues/931
const fs = require('fs');
const path = require('path');
module.exports.patch = function (roots = [path.join(__dirname, '..', 'src', 'node')]) {
console.info('🔧 <<< Patching code...');
patch(roots);
console.info('👌 <<< Done. The code has been patched.');
};
function patch(paths) {
for (const p of paths) {
const exist = fs.existsSync(p);
if (exist) {
const stat = fs.statSync(p);
if (stat.isDirectory()) {
console.info(`🔧 >>> Scanning code in ${p}...`);
patch(fs.readdirSync(p).map(name => path.join(p, name)));
} else {
let content = fs.readFileSync(p, { encoding: 'utf8' });
if (content.indexOf("require('grpc')") !== -1) {
console.info(`Updated require('grpc') to require('@grpc/grpc-js') in ${p}.`);
fs.writeFileSync(p, content.replace("require('grpc')", "require('@grpc/grpc-js')"));
}
content = fs.readFileSync(p, { encoding: 'utf8' });
if (content.indexOf('import * as grpc from "grpc"') !== -1) {
console.info(`Updated import * as grpc from "grpc" to import * as grpc from "@grpc/grpc-js" in ${p}.`);
fs.writeFileSync(p, content.replace('import * as grpc from "grpc"', 'import * as grpc from "@grpc/grpc-js"'));
}
}
} else {
console.warn(`${p} does not exist. Skipping.`);
}
}
console.info('👌 <<< Done. The code has been patched.');
})();
}

View File

@ -23,29 +23,21 @@ export interface Board {
export interface AttachedSerialBoard extends Board {
port: string;
type: 'serial';
serialNumber?: string;
productID?: string;
vendorID?: string;
}
export namespace AttachedSerialBoard {
export function is(b: Board): b is AttachedSerialBoard {
return 'type' in b && (b as Board & { type: any }).type === 'serial' &&
'port' in b && !!(b as Board & { port: any }).port && typeof (b as Board & { port: any }).port === 'string';
return 'port' in b;
}
}
export interface AttachedNetworkBoard extends Board {
info?: string;
address?: string;
port: number;
type: 'network';
address: string;
port: string;
}
export namespace AttachedNetworkBoard {
export function is(b: Board): b is AttachedNetworkBoard {
return 'type' in b && (b as Board & { type: any }).type === 'network' &&
'port' in b && !!(b as Board & { port: any }).port && typeof (b as Board & { port: any }).port === 'number';
return 'address' in b && 'port' in b;
}
}

View File

@ -1,6 +1,8 @@
import * as which from 'which';
import * as os from 'os';
import { exec, ChildProcess } from 'child_process';
import { join, resolve } from 'path';
import { join, delimiter } from 'path';
import { exec } from 'child_process';
import { ChildProcess } from 'child_process';
import { inject, injectable, named } from 'inversify';
import { ILogger } from '@theia/core/lib/common/logger';
import { BackendApplicationContribution } from '@theia/core/lib/node';
@ -8,11 +10,12 @@ import { Deferred } from '@theia/core/lib/common/promise-util';
import { DaemonLog } from './daemon-log';
import { ToolOutputServiceServer } from '../common/protocol/tool-output-service';
const EXECUTABLE_PATH = resolve(join(__dirname, '..', '..', 'build', `arduino-cli.${os.platform()}`))
@injectable()
export class ArduinoDaemon implements BackendApplicationContribution {
// Set this to `true` if you want to connect to a CLI running in debug mode.
static DEBUG_CLI = false;
@inject(ILogger)
@named('daemon')
protected readonly logger: ILogger
@ -26,32 +29,50 @@ export class ArduinoDaemon implements BackendApplicationContribution {
async onStart() {
try {
const daemon = exec(`${EXECUTABLE_PATH} --debug daemon`, (err, stdout, stderr) => {
if (err || stderr) {
console.log(err || new Error(stderr));
return;
if (!ArduinoDaemon.DEBUG_CLI) {
const build = join(__dirname, '..', '..', 'build');
const executable = await new Promise<string>((resolve, reject) => {
which(`arduino-cli${os.platform() === 'win32' ? '.exe' : ''}`, { path: `${process.env.PATH}${delimiter}${build}` }, (err, path) => {
if (err) {
reject(err);
return;
}
resolve(path);
});
});
this.logger.info(`>>> Starting 'arduino-cli' daemon... [${executable}]`);
const daemon = exec(`${executable} --debug daemon`, (err, stdout, stderr) => {
if (err || stderr) {
console.log(err || new Error(stderr));
return;
}
console.log(stdout);
});
if (daemon.stdout) {
daemon.stdout.on('data', data => {
this.toolOutputService.publishNewOutput('daemon', data.toString());
DaemonLog.log(this.logger, data.toString());
});
}
console.log(stdout);
});
if (daemon.stdout) {
daemon.stdout.on('data', data => {
this.toolOutputService.publishNewOutput('daemon', data.toString());
DaemonLog.log(this.logger, data.toString());
});
if (daemon.stderr) {
daemon.stderr.on('data', data => {
this.toolOutputService.publishNewOutput('daemon error', data.toString());
DaemonLog.log(this.logger, data.toString());
});
}
if (daemon.stderr) {
daemon.on('exit', (code, signal) => DaemonLog.log(this.logger, `Daemon exited with code: ${code}. Signal was: ${signal}.`));
}
this.process = daemon;
}
if (daemon.stderr) {
daemon.stderr.on('data', data => {
this.toolOutputService.publishNewOutput('daemon error', data.toString());
DaemonLog.log(this.logger, data.toString());
});
}
if (daemon.stderr) {
daemon.on('exit', (code, signal) => DaemonLog.log(this.logger, `Daemon exited with code: ${code}. Signal was: ${signal}.`));
}
this.process = daemon;
await new Promise((resolve, reject) => setTimeout(resolve, 2000));
await new Promise(resolve => setTimeout(resolve, 2000));
this.isReady.resolve();
if (!ArduinoDaemon.DEBUG_CLI) {
this.logger.info(`<<< The 'arduino-cli' daemon is up an running.`);
} else {
this.logger.info(`Assuming the 'arduino-cli' already runs in debug mode.`);
}
} catch (error) {
this.isReady.reject(error || new Error('failed to start arduino-cli'));
}

View File

@ -1,8 +1,9 @@
import * as PQueue from 'p-queue';
import { injectable, inject } from 'inversify';
import { BoardsService, AttachedSerialBoard, AttachedNetworkBoard, BoardPackage, Board } from '../common/protocol/boards-service';
import { PlatformSearchReq, PlatformSearchResp, PlatformInstallReq, PlatformInstallResp, PlatformListReq, PlatformListResp } from './cli-protocol/core_pb';
import { BoardsService, AttachedSerialBoard, BoardPackage, Board, AttachedNetworkBoard } from '../common/protocol/boards-service';
import { PlatformSearchReq, PlatformSearchResp, PlatformInstallReq, PlatformInstallResp, PlatformListReq, PlatformListResp } from './cli-protocol/commands/core_pb';
import { CoreClientProvider } from './core-client-provider';
import { BoardListReq, BoardListResp } from './cli-protocol/board_pb';
import { BoardListReq, BoardListResp } from './cli-protocol/commands/board_pb';
import { ToolOutputServiceServer } from '../common/protocol/tool-output-service';
@injectable()
@ -15,37 +16,48 @@ export class BoardsServiceImpl implements BoardsService {
protected readonly toolOutputService: ToolOutputServiceServer;
protected selectedBoard: Board | undefined;
protected readonly queue = new PQueue({ autoStart: true, concurrency: 1 });
public async getAttachedBoards(): Promise<{ boards: Board[] }> {
const coreClient = await this.coreClientProvider.getClient();
if (!coreClient) {
return { boards: [] };
}
const { client, instance } = coreClient;
return this.queue.add(() => {
return new Promise<{ boards: Board[] }>(async resolve => {
const coreClient = await this.coreClientProvider.getClient();
const boards: Board[] = [];
if (!coreClient) {
resolve({ boards });
return;
}
const req = new BoardListReq();
req.setInstance(instance);
const resp = await new Promise<BoardListResp>((resolve, reject) => client.boardList(req, (err, resp) => (!!err ? reject : resolve)(!!err ? err : resp)));
const serialBoards: Board[] = resp.getSerialList().map(b => <AttachedSerialBoard>{
name: b.getName() || "unknown",
fqbn: b.getFqbn(),
port: b.getPort(),
type: 'serial',
serialNumber: b.getSerialnumber(),
productID: b.getProductid(),
vendorID: b.getVendorid()
const { client, instance } = coreClient;
const req = new BoardListReq();
req.setInstance(instance);
const resp = await new Promise<BoardListResp>((resolve, reject) => client.boardList(req, (err, resp) => (!!err ? reject : resolve)(!!err ? err : resp)));
for (const portsList of resp.getPortsList()) {
const protocol = portsList.getProtocol();
const address = portsList.getAddress();
for (const board of portsList.getBoardsList()) {
const name = board.getName() || 'unknown';
const fqbn = board.getFqbn();
const port = address;
if (protocol === 'serial') {
boards.push(<AttachedSerialBoard>{
name,
fqbn,
port
});
} else { // We assume, it is a `network` board.
boards.push(<AttachedNetworkBoard>{
name,
fqbn,
address,
port
});
}
}
}
resolve({boards});
})
});
const networkBoards: Board[] = resp.getNetworkList().map(b => <AttachedNetworkBoard>{
name: b.getName(),
fqbn: b.getFqbn(),
address: b.getAddress(),
info: b.getInfo(),
port: b.getPort(),
type: 'network'
});
return { boards: serialBoards.concat(networkBoards) };
}
async selectBoard(board: Board): Promise<void> {
@ -77,7 +89,7 @@ export class BoardsServiceImpl implements BoardsService {
let items = resp.getSearchOutputList().map(item => {
let installedVersion: string | undefined;
const matchingPlatform = installedPlatforms.find(ip => ip.getId().startsWith(`${item.getId()}@`));
const matchingPlatform = installedPlatforms.find(ip => ip.getId().startsWith(`${item.getId()}`));
if (!!matchingPlatform) {
installedVersion = matchingPlatform.getInstalled();
}
@ -85,8 +97,8 @@ export class BoardsServiceImpl implements BoardsService {
const result: BoardPackage = {
id: item.getId(),
name: item.getName(),
author: item.getAuthor(),
availableVersions: [ item.getVersion() ],
author: item.getMaintainer(),
availableVersions: [item.getInstalled()],
description: item.getBoardsList().map(b => b.getName()).join(", "),
installable: true,
summary: "Boards included in this package:",
@ -106,7 +118,7 @@ export class BoardsServiceImpl implements BoardsService {
}
const { client, instance } = coreClient;
const [ platform, boardName ] = pkg.id.split(":");
const [platform, boardName] = pkg.id.split(":");
const req = new PlatformInstallReq();
req.setInstance(instance);

File diff suppressed because it is too large Load Diff

View File

@ -1,17 +1,17 @@
// package: arduino
// file: board.proto
// package: cc.arduino.cli.commands
// file: commands/board.proto
/* tslint:disable */
import * as jspb from "google-protobuf";
import * as common_pb from "./common_pb";
import * as commands_common_pb from "../commands/common_pb";
export class BoardDetailsReq extends jspb.Message {
hasInstance(): boolean;
clearInstance(): void;
getInstance(): common_pb.Instance | undefined;
setInstance(value?: common_pb.Instance): void;
getInstance(): commands_common_pb.Instance | undefined;
setInstance(value?: commands_common_pb.Instance): void;
getFqbn(): string;
setFqbn(value: string): void;
@ -29,7 +29,7 @@ export class BoardDetailsReq extends jspb.Message {
export namespace BoardDetailsReq {
export type AsObject = {
instance?: common_pb.Instance.AsObject,
instance?: commands_common_pb.Instance.AsObject,
fqbn: string,
}
}
@ -156,12 +156,72 @@ export namespace RequiredTool {
}
}
export class BoardAttachReq extends jspb.Message {
hasInstance(): boolean;
clearInstance(): void;
getInstance(): commands_common_pb.Instance | undefined;
setInstance(value?: commands_common_pb.Instance): void;
getBoardUri(): string;
setBoardUri(value: string): void;
getSketchPath(): string;
setSketchPath(value: string): void;
getSearchTimeout(): string;
setSearchTimeout(value: string): void;
serializeBinary(): Uint8Array;
toObject(includeInstance?: boolean): BoardAttachReq.AsObject;
static toObject(includeInstance: boolean, msg: BoardAttachReq): BoardAttachReq.AsObject;
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
static serializeBinaryToWriter(message: BoardAttachReq, writer: jspb.BinaryWriter): void;
static deserializeBinary(bytes: Uint8Array): BoardAttachReq;
static deserializeBinaryFromReader(message: BoardAttachReq, reader: jspb.BinaryReader): BoardAttachReq;
}
export namespace BoardAttachReq {
export type AsObject = {
instance?: commands_common_pb.Instance.AsObject,
boardUri: string,
sketchPath: string,
searchTimeout: string,
}
}
export class BoardAttachResp extends jspb.Message {
hasTaskProgress(): boolean;
clearTaskProgress(): void;
getTaskProgress(): commands_common_pb.TaskProgress | undefined;
setTaskProgress(value?: commands_common_pb.TaskProgress): void;
serializeBinary(): Uint8Array;
toObject(includeInstance?: boolean): BoardAttachResp.AsObject;
static toObject(includeInstance: boolean, msg: BoardAttachResp): BoardAttachResp.AsObject;
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
static serializeBinaryToWriter(message: BoardAttachResp, writer: jspb.BinaryWriter): void;
static deserializeBinary(bytes: Uint8Array): BoardAttachResp;
static deserializeBinaryFromReader(message: BoardAttachResp, reader: jspb.BinaryReader): BoardAttachResp;
}
export namespace BoardAttachResp {
export type AsObject = {
taskProgress?: commands_common_pb.TaskProgress.AsObject,
}
}
export class BoardListReq extends jspb.Message {
hasInstance(): boolean;
clearInstance(): void;
getInstance(): common_pb.Instance | undefined;
setInstance(value?: common_pb.Instance): void;
getInstance(): commands_common_pb.Instance | undefined;
setInstance(value?: commands_common_pb.Instance): void;
serializeBinary(): Uint8Array;
@ -176,20 +236,15 @@ export class BoardListReq extends jspb.Message {
export namespace BoardListReq {
export type AsObject = {
instance?: common_pb.Instance.AsObject,
instance?: commands_common_pb.Instance.AsObject,
}
}
export class BoardListResp extends jspb.Message {
clearSerialList(): void;
getSerialList(): Array<AttachedSerialBoard>;
setSerialList(value: Array<AttachedSerialBoard>): void;
addSerial(value?: AttachedSerialBoard, index?: number): AttachedSerialBoard;
clearNetworkList(): void;
getNetworkList(): Array<AttachedNetworkBoard>;
setNetworkList(value: Array<AttachedNetworkBoard>): void;
addNetwork(value?: AttachedNetworkBoard, index?: number): AttachedNetworkBoard;
clearPortsList(): void;
getPortsList(): Array<DetectedPort>;
setPortsList(value: Array<DetectedPort>): void;
addPorts(value?: DetectedPort, index?: number): DetectedPort;
serializeBinary(): Uint8Array;
@ -204,85 +259,119 @@ export class BoardListResp extends jspb.Message {
export namespace BoardListResp {
export type AsObject = {
serialList: Array<AttachedSerialBoard.AsObject>,
networkList: Array<AttachedNetworkBoard.AsObject>,
portsList: Array<DetectedPort.AsObject>,
}
}
export class AttachedNetworkBoard extends jspb.Message {
getName(): string;
setName(value: string): void;
getFqbn(): string;
setFqbn(value: string): void;
getInfo(): string;
setInfo(value: string): void;
export class DetectedPort extends jspb.Message {
getAddress(): string;
setAddress(value: string): void;
getPort(): number;
setPort(value: number): void;
getProtocol(): string;
setProtocol(value: string): void;
getProtocolLabel(): string;
setProtocolLabel(value: string): void;
clearBoardsList(): void;
getBoardsList(): Array<BoardListItem>;
setBoardsList(value: Array<BoardListItem>): void;
addBoards(value?: BoardListItem, index?: number): BoardListItem;
serializeBinary(): Uint8Array;
toObject(includeInstance?: boolean): AttachedNetworkBoard.AsObject;
static toObject(includeInstance: boolean, msg: AttachedNetworkBoard): AttachedNetworkBoard.AsObject;
toObject(includeInstance?: boolean): DetectedPort.AsObject;
static toObject(includeInstance: boolean, msg: DetectedPort): DetectedPort.AsObject;
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
static serializeBinaryToWriter(message: AttachedNetworkBoard, writer: jspb.BinaryWriter): void;
static deserializeBinary(bytes: Uint8Array): AttachedNetworkBoard;
static deserializeBinaryFromReader(message: AttachedNetworkBoard, reader: jspb.BinaryReader): AttachedNetworkBoard;
static serializeBinaryToWriter(message: DetectedPort, writer: jspb.BinaryWriter): void;
static deserializeBinary(bytes: Uint8Array): DetectedPort;
static deserializeBinaryFromReader(message: DetectedPort, reader: jspb.BinaryReader): DetectedPort;
}
export namespace AttachedNetworkBoard {
export namespace DetectedPort {
export type AsObject = {
name: string,
fqbn: string,
info: string,
address: string,
port: number,
protocol: string,
protocolLabel: string,
boardsList: Array<BoardListItem.AsObject>,
}
}
export class AttachedSerialBoard extends jspb.Message {
export class BoardListAllReq extends jspb.Message {
hasInstance(): boolean;
clearInstance(): void;
getInstance(): commands_common_pb.Instance | undefined;
setInstance(value?: commands_common_pb.Instance): void;
clearSearchArgsList(): void;
getSearchArgsList(): Array<string>;
setSearchArgsList(value: Array<string>): void;
addSearchArgs(value: string, index?: number): string;
serializeBinary(): Uint8Array;
toObject(includeInstance?: boolean): BoardListAllReq.AsObject;
static toObject(includeInstance: boolean, msg: BoardListAllReq): BoardListAllReq.AsObject;
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
static serializeBinaryToWriter(message: BoardListAllReq, writer: jspb.BinaryWriter): void;
static deserializeBinary(bytes: Uint8Array): BoardListAllReq;
static deserializeBinaryFromReader(message: BoardListAllReq, reader: jspb.BinaryReader): BoardListAllReq;
}
export namespace BoardListAllReq {
export type AsObject = {
instance?: commands_common_pb.Instance.AsObject,
searchArgsList: Array<string>,
}
}
export class BoardListAllResp extends jspb.Message {
clearBoardsList(): void;
getBoardsList(): Array<BoardListItem>;
setBoardsList(value: Array<BoardListItem>): void;
addBoards(value?: BoardListItem, index?: number): BoardListItem;
serializeBinary(): Uint8Array;
toObject(includeInstance?: boolean): BoardListAllResp.AsObject;
static toObject(includeInstance: boolean, msg: BoardListAllResp): BoardListAllResp.AsObject;
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
static serializeBinaryToWriter(message: BoardListAllResp, writer: jspb.BinaryWriter): void;
static deserializeBinary(bytes: Uint8Array): BoardListAllResp;
static deserializeBinaryFromReader(message: BoardListAllResp, reader: jspb.BinaryReader): BoardListAllResp;
}
export namespace BoardListAllResp {
export type AsObject = {
boardsList: Array<BoardListItem.AsObject>,
}
}
export class BoardListItem extends jspb.Message {
getName(): string;
setName(value: string): void;
getFqbn(): string;
setFqbn(value: string): void;
getPort(): string;
setPort(value: string): void;
getSerialnumber(): string;
setSerialnumber(value: string): void;
getProductid(): string;
setProductid(value: string): void;
getVendorid(): string;
setVendorid(value: string): void;
serializeBinary(): Uint8Array;
toObject(includeInstance?: boolean): AttachedSerialBoard.AsObject;
static toObject(includeInstance: boolean, msg: AttachedSerialBoard): AttachedSerialBoard.AsObject;
toObject(includeInstance?: boolean): BoardListItem.AsObject;
static toObject(includeInstance: boolean, msg: BoardListItem): BoardListItem.AsObject;
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
static serializeBinaryToWriter(message: AttachedSerialBoard, writer: jspb.BinaryWriter): void;
static deserializeBinary(bytes: Uint8Array): AttachedSerialBoard;
static deserializeBinaryFromReader(message: AttachedSerialBoard, reader: jspb.BinaryReader): AttachedSerialBoard;
static serializeBinaryToWriter(message: BoardListItem, writer: jspb.BinaryWriter): void;
static deserializeBinary(bytes: Uint8Array): BoardListItem;
static deserializeBinaryFromReader(message: BoardListItem, reader: jspb.BinaryReader): BoardListItem;
}
export namespace AttachedSerialBoard {
export namespace BoardListItem {
export type AsObject = {
name: string,
fqbn: string,
port: string,
serialnumber: string,
productid: string,
vendorid: string,
}
}

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,409 @@
// package: cc.arduino.cli.commands
// file: commands/commands.proto
/* tslint:disable */
import * as grpc from "@grpc/grpc-js";
import * as commands_commands_pb from "../commands/commands_pb";
import * as commands_common_pb from "../commands/common_pb";
import * as commands_board_pb from "../commands/board_pb";
import * as commands_compile_pb from "../commands/compile_pb";
import * as commands_core_pb from "../commands/core_pb";
import * as commands_upload_pb from "../commands/upload_pb";
import * as commands_lib_pb from "../commands/lib_pb";
interface IArduinoCoreService extends grpc.ServiceDefinition<grpc.UntypedServiceImplementation> {
init: IArduinoCoreService_IInit;
destroy: IArduinoCoreService_IDestroy;
rescan: IArduinoCoreService_IRescan;
updateIndex: IArduinoCoreService_IUpdateIndex;
updateLibrariesIndex: IArduinoCoreService_IUpdateLibrariesIndex;
version: IArduinoCoreService_IVersion;
boardDetails: IArduinoCoreService_IBoardDetails;
boardAttach: IArduinoCoreService_IBoardAttach;
boardList: IArduinoCoreService_IBoardList;
boardListAll: IArduinoCoreService_IBoardListAll;
compile: IArduinoCoreService_ICompile;
platformInstall: IArduinoCoreService_IPlatformInstall;
platformDownload: IArduinoCoreService_IPlatformDownload;
platformUninstall: IArduinoCoreService_IPlatformUninstall;
platformUpgrade: IArduinoCoreService_IPlatformUpgrade;
upload: IArduinoCoreService_IUpload;
platformSearch: IArduinoCoreService_IPlatformSearch;
platformList: IArduinoCoreService_IPlatformList;
libraryDownload: IArduinoCoreService_ILibraryDownload;
libraryInstall: IArduinoCoreService_ILibraryInstall;
libraryUninstall: IArduinoCoreService_ILibraryUninstall;
libraryUpgradeAll: IArduinoCoreService_ILibraryUpgradeAll;
librarySearch: IArduinoCoreService_ILibrarySearch;
libraryList: IArduinoCoreService_ILibraryList;
}
interface IArduinoCoreService_IInit extends grpc.MethodDefinition<commands_commands_pb.InitReq, commands_commands_pb.InitResp> {
path: string; // "/cc.arduino.cli.commands.ArduinoCore/Init"
requestStream: boolean; // false
responseStream: boolean; // true
requestSerialize: grpc.serialize<commands_commands_pb.InitReq>;
requestDeserialize: grpc.deserialize<commands_commands_pb.InitReq>;
responseSerialize: grpc.serialize<commands_commands_pb.InitResp>;
responseDeserialize: grpc.deserialize<commands_commands_pb.InitResp>;
}
interface IArduinoCoreService_IDestroy extends grpc.MethodDefinition<commands_commands_pb.DestroyReq, commands_commands_pb.DestroyResp> {
path: string; // "/cc.arduino.cli.commands.ArduinoCore/Destroy"
requestStream: boolean; // false
responseStream: boolean; // false
requestSerialize: grpc.serialize<commands_commands_pb.DestroyReq>;
requestDeserialize: grpc.deserialize<commands_commands_pb.DestroyReq>;
responseSerialize: grpc.serialize<commands_commands_pb.DestroyResp>;
responseDeserialize: grpc.deserialize<commands_commands_pb.DestroyResp>;
}
interface IArduinoCoreService_IRescan extends grpc.MethodDefinition<commands_commands_pb.RescanReq, commands_commands_pb.RescanResp> {
path: string; // "/cc.arduino.cli.commands.ArduinoCore/Rescan"
requestStream: boolean; // false
responseStream: boolean; // false
requestSerialize: grpc.serialize<commands_commands_pb.RescanReq>;
requestDeserialize: grpc.deserialize<commands_commands_pb.RescanReq>;
responseSerialize: grpc.serialize<commands_commands_pb.RescanResp>;
responseDeserialize: grpc.deserialize<commands_commands_pb.RescanResp>;
}
interface IArduinoCoreService_IUpdateIndex extends grpc.MethodDefinition<commands_commands_pb.UpdateIndexReq, commands_commands_pb.UpdateIndexResp> {
path: string; // "/cc.arduino.cli.commands.ArduinoCore/UpdateIndex"
requestStream: boolean; // false
responseStream: boolean; // true
requestSerialize: grpc.serialize<commands_commands_pb.UpdateIndexReq>;
requestDeserialize: grpc.deserialize<commands_commands_pb.UpdateIndexReq>;
responseSerialize: grpc.serialize<commands_commands_pb.UpdateIndexResp>;
responseDeserialize: grpc.deserialize<commands_commands_pb.UpdateIndexResp>;
}
interface IArduinoCoreService_IUpdateLibrariesIndex extends grpc.MethodDefinition<commands_commands_pb.UpdateLibrariesIndexReq, commands_commands_pb.UpdateLibrariesIndexResp> {
path: string; // "/cc.arduino.cli.commands.ArduinoCore/UpdateLibrariesIndex"
requestStream: boolean; // false
responseStream: boolean; // true
requestSerialize: grpc.serialize<commands_commands_pb.UpdateLibrariesIndexReq>;
requestDeserialize: grpc.deserialize<commands_commands_pb.UpdateLibrariesIndexReq>;
responseSerialize: grpc.serialize<commands_commands_pb.UpdateLibrariesIndexResp>;
responseDeserialize: grpc.deserialize<commands_commands_pb.UpdateLibrariesIndexResp>;
}
interface IArduinoCoreService_IVersion extends grpc.MethodDefinition<commands_commands_pb.VersionReq, commands_commands_pb.VersionResp> {
path: string; // "/cc.arduino.cli.commands.ArduinoCore/Version"
requestStream: boolean; // false
responseStream: boolean; // false
requestSerialize: grpc.serialize<commands_commands_pb.VersionReq>;
requestDeserialize: grpc.deserialize<commands_commands_pb.VersionReq>;
responseSerialize: grpc.serialize<commands_commands_pb.VersionResp>;
responseDeserialize: grpc.deserialize<commands_commands_pb.VersionResp>;
}
interface IArduinoCoreService_IBoardDetails extends grpc.MethodDefinition<commands_board_pb.BoardDetailsReq, commands_board_pb.BoardDetailsResp> {
path: string; // "/cc.arduino.cli.commands.ArduinoCore/BoardDetails"
requestStream: boolean; // false
responseStream: boolean; // false
requestSerialize: grpc.serialize<commands_board_pb.BoardDetailsReq>;
requestDeserialize: grpc.deserialize<commands_board_pb.BoardDetailsReq>;
responseSerialize: grpc.serialize<commands_board_pb.BoardDetailsResp>;
responseDeserialize: grpc.deserialize<commands_board_pb.BoardDetailsResp>;
}
interface IArduinoCoreService_IBoardAttach extends grpc.MethodDefinition<commands_board_pb.BoardAttachReq, commands_board_pb.BoardAttachResp> {
path: string; // "/cc.arduino.cli.commands.ArduinoCore/BoardAttach"
requestStream: boolean; // false
responseStream: boolean; // true
requestSerialize: grpc.serialize<commands_board_pb.BoardAttachReq>;
requestDeserialize: grpc.deserialize<commands_board_pb.BoardAttachReq>;
responseSerialize: grpc.serialize<commands_board_pb.BoardAttachResp>;
responseDeserialize: grpc.deserialize<commands_board_pb.BoardAttachResp>;
}
interface IArduinoCoreService_IBoardList extends grpc.MethodDefinition<commands_board_pb.BoardListReq, commands_board_pb.BoardListResp> {
path: string; // "/cc.arduino.cli.commands.ArduinoCore/BoardList"
requestStream: boolean; // false
responseStream: boolean; // false
requestSerialize: grpc.serialize<commands_board_pb.BoardListReq>;
requestDeserialize: grpc.deserialize<commands_board_pb.BoardListReq>;
responseSerialize: grpc.serialize<commands_board_pb.BoardListResp>;
responseDeserialize: grpc.deserialize<commands_board_pb.BoardListResp>;
}
interface IArduinoCoreService_IBoardListAll extends grpc.MethodDefinition<commands_board_pb.BoardListAllReq, commands_board_pb.BoardListAllResp> {
path: string; // "/cc.arduino.cli.commands.ArduinoCore/BoardListAll"
requestStream: boolean; // false
responseStream: boolean; // false
requestSerialize: grpc.serialize<commands_board_pb.BoardListAllReq>;
requestDeserialize: grpc.deserialize<commands_board_pb.BoardListAllReq>;
responseSerialize: grpc.serialize<commands_board_pb.BoardListAllResp>;
responseDeserialize: grpc.deserialize<commands_board_pb.BoardListAllResp>;
}
interface IArduinoCoreService_ICompile extends grpc.MethodDefinition<commands_compile_pb.CompileReq, commands_compile_pb.CompileResp> {
path: string; // "/cc.arduino.cli.commands.ArduinoCore/Compile"
requestStream: boolean; // false
responseStream: boolean; // true
requestSerialize: grpc.serialize<commands_compile_pb.CompileReq>;
requestDeserialize: grpc.deserialize<commands_compile_pb.CompileReq>;
responseSerialize: grpc.serialize<commands_compile_pb.CompileResp>;
responseDeserialize: grpc.deserialize<commands_compile_pb.CompileResp>;
}
interface IArduinoCoreService_IPlatformInstall extends grpc.MethodDefinition<commands_core_pb.PlatformInstallReq, commands_core_pb.PlatformInstallResp> {
path: string; // "/cc.arduino.cli.commands.ArduinoCore/PlatformInstall"
requestStream: boolean; // false
responseStream: boolean; // true
requestSerialize: grpc.serialize<commands_core_pb.PlatformInstallReq>;
requestDeserialize: grpc.deserialize<commands_core_pb.PlatformInstallReq>;
responseSerialize: grpc.serialize<commands_core_pb.PlatformInstallResp>;
responseDeserialize: grpc.deserialize<commands_core_pb.PlatformInstallResp>;
}
interface IArduinoCoreService_IPlatformDownload extends grpc.MethodDefinition<commands_core_pb.PlatformDownloadReq, commands_core_pb.PlatformDownloadResp> {
path: string; // "/cc.arduino.cli.commands.ArduinoCore/PlatformDownload"
requestStream: boolean; // false
responseStream: boolean; // true
requestSerialize: grpc.serialize<commands_core_pb.PlatformDownloadReq>;
requestDeserialize: grpc.deserialize<commands_core_pb.PlatformDownloadReq>;
responseSerialize: grpc.serialize<commands_core_pb.PlatformDownloadResp>;
responseDeserialize: grpc.deserialize<commands_core_pb.PlatformDownloadResp>;
}
interface IArduinoCoreService_IPlatformUninstall extends grpc.MethodDefinition<commands_core_pb.PlatformUninstallReq, commands_core_pb.PlatformUninstallResp> {
path: string; // "/cc.arduino.cli.commands.ArduinoCore/PlatformUninstall"
requestStream: boolean; // false
responseStream: boolean; // true
requestSerialize: grpc.serialize<commands_core_pb.PlatformUninstallReq>;
requestDeserialize: grpc.deserialize<commands_core_pb.PlatformUninstallReq>;
responseSerialize: grpc.serialize<commands_core_pb.PlatformUninstallResp>;
responseDeserialize: grpc.deserialize<commands_core_pb.PlatformUninstallResp>;
}
interface IArduinoCoreService_IPlatformUpgrade extends grpc.MethodDefinition<commands_core_pb.PlatformUpgradeReq, commands_core_pb.PlatformUpgradeResp> {
path: string; // "/cc.arduino.cli.commands.ArduinoCore/PlatformUpgrade"
requestStream: boolean; // false
responseStream: boolean; // true
requestSerialize: grpc.serialize<commands_core_pb.PlatformUpgradeReq>;
requestDeserialize: grpc.deserialize<commands_core_pb.PlatformUpgradeReq>;
responseSerialize: grpc.serialize<commands_core_pb.PlatformUpgradeResp>;
responseDeserialize: grpc.deserialize<commands_core_pb.PlatformUpgradeResp>;
}
interface IArduinoCoreService_IUpload extends grpc.MethodDefinition<commands_upload_pb.UploadReq, commands_upload_pb.UploadResp> {
path: string; // "/cc.arduino.cli.commands.ArduinoCore/Upload"
requestStream: boolean; // false
responseStream: boolean; // true
requestSerialize: grpc.serialize<commands_upload_pb.UploadReq>;
requestDeserialize: grpc.deserialize<commands_upload_pb.UploadReq>;
responseSerialize: grpc.serialize<commands_upload_pb.UploadResp>;
responseDeserialize: grpc.deserialize<commands_upload_pb.UploadResp>;
}
interface IArduinoCoreService_IPlatformSearch extends grpc.MethodDefinition<commands_core_pb.PlatformSearchReq, commands_core_pb.PlatformSearchResp> {
path: string; // "/cc.arduino.cli.commands.ArduinoCore/PlatformSearch"
requestStream: boolean; // false
responseStream: boolean; // false
requestSerialize: grpc.serialize<commands_core_pb.PlatformSearchReq>;
requestDeserialize: grpc.deserialize<commands_core_pb.PlatformSearchReq>;
responseSerialize: grpc.serialize<commands_core_pb.PlatformSearchResp>;
responseDeserialize: grpc.deserialize<commands_core_pb.PlatformSearchResp>;
}
interface IArduinoCoreService_IPlatformList extends grpc.MethodDefinition<commands_core_pb.PlatformListReq, commands_core_pb.PlatformListResp> {
path: string; // "/cc.arduino.cli.commands.ArduinoCore/PlatformList"
requestStream: boolean; // false
responseStream: boolean; // false
requestSerialize: grpc.serialize<commands_core_pb.PlatformListReq>;
requestDeserialize: grpc.deserialize<commands_core_pb.PlatformListReq>;
responseSerialize: grpc.serialize<commands_core_pb.PlatformListResp>;
responseDeserialize: grpc.deserialize<commands_core_pb.PlatformListResp>;
}
interface IArduinoCoreService_ILibraryDownload extends grpc.MethodDefinition<commands_lib_pb.LibraryDownloadReq, commands_lib_pb.LibraryDownloadResp> {
path: string; // "/cc.arduino.cli.commands.ArduinoCore/LibraryDownload"
requestStream: boolean; // false
responseStream: boolean; // true
requestSerialize: grpc.serialize<commands_lib_pb.LibraryDownloadReq>;
requestDeserialize: grpc.deserialize<commands_lib_pb.LibraryDownloadReq>;
responseSerialize: grpc.serialize<commands_lib_pb.LibraryDownloadResp>;
responseDeserialize: grpc.deserialize<commands_lib_pb.LibraryDownloadResp>;
}
interface IArduinoCoreService_ILibraryInstall extends grpc.MethodDefinition<commands_lib_pb.LibraryInstallReq, commands_lib_pb.LibraryInstallResp> {
path: string; // "/cc.arduino.cli.commands.ArduinoCore/LibraryInstall"
requestStream: boolean; // false
responseStream: boolean; // true
requestSerialize: grpc.serialize<commands_lib_pb.LibraryInstallReq>;
requestDeserialize: grpc.deserialize<commands_lib_pb.LibraryInstallReq>;
responseSerialize: grpc.serialize<commands_lib_pb.LibraryInstallResp>;
responseDeserialize: grpc.deserialize<commands_lib_pb.LibraryInstallResp>;
}
interface IArduinoCoreService_ILibraryUninstall extends grpc.MethodDefinition<commands_lib_pb.LibraryUninstallReq, commands_lib_pb.LibraryUninstallResp> {
path: string; // "/cc.arduino.cli.commands.ArduinoCore/LibraryUninstall"
requestStream: boolean; // false
responseStream: boolean; // true
requestSerialize: grpc.serialize<commands_lib_pb.LibraryUninstallReq>;
requestDeserialize: grpc.deserialize<commands_lib_pb.LibraryUninstallReq>;
responseSerialize: grpc.serialize<commands_lib_pb.LibraryUninstallResp>;
responseDeserialize: grpc.deserialize<commands_lib_pb.LibraryUninstallResp>;
}
interface IArduinoCoreService_ILibraryUpgradeAll extends grpc.MethodDefinition<commands_lib_pb.LibraryUpgradeAllReq, commands_lib_pb.LibraryUpgradeAllResp> {
path: string; // "/cc.arduino.cli.commands.ArduinoCore/LibraryUpgradeAll"
requestStream: boolean; // false
responseStream: boolean; // true
requestSerialize: grpc.serialize<commands_lib_pb.LibraryUpgradeAllReq>;
requestDeserialize: grpc.deserialize<commands_lib_pb.LibraryUpgradeAllReq>;
responseSerialize: grpc.serialize<commands_lib_pb.LibraryUpgradeAllResp>;
responseDeserialize: grpc.deserialize<commands_lib_pb.LibraryUpgradeAllResp>;
}
interface IArduinoCoreService_ILibrarySearch extends grpc.MethodDefinition<commands_lib_pb.LibrarySearchReq, commands_lib_pb.LibrarySearchResp> {
path: string; // "/cc.arduino.cli.commands.ArduinoCore/LibrarySearch"
requestStream: boolean; // false
responseStream: boolean; // false
requestSerialize: grpc.serialize<commands_lib_pb.LibrarySearchReq>;
requestDeserialize: grpc.deserialize<commands_lib_pb.LibrarySearchReq>;
responseSerialize: grpc.serialize<commands_lib_pb.LibrarySearchResp>;
responseDeserialize: grpc.deserialize<commands_lib_pb.LibrarySearchResp>;
}
interface IArduinoCoreService_ILibraryList extends grpc.MethodDefinition<commands_lib_pb.LibraryListReq, commands_lib_pb.LibraryListResp> {
path: string; // "/cc.arduino.cli.commands.ArduinoCore/LibraryList"
requestStream: boolean; // false
responseStream: boolean; // false
requestSerialize: grpc.serialize<commands_lib_pb.LibraryListReq>;
requestDeserialize: grpc.deserialize<commands_lib_pb.LibraryListReq>;
responseSerialize: grpc.serialize<commands_lib_pb.LibraryListResp>;
responseDeserialize: grpc.deserialize<commands_lib_pb.LibraryListResp>;
}
export const ArduinoCoreService: IArduinoCoreService;
export interface IArduinoCoreServer {
init: grpc.handleServerStreamingCall<commands_commands_pb.InitReq, commands_commands_pb.InitResp>;
destroy: grpc.handleUnaryCall<commands_commands_pb.DestroyReq, commands_commands_pb.DestroyResp>;
rescan: grpc.handleUnaryCall<commands_commands_pb.RescanReq, commands_commands_pb.RescanResp>;
updateIndex: grpc.handleServerStreamingCall<commands_commands_pb.UpdateIndexReq, commands_commands_pb.UpdateIndexResp>;
updateLibrariesIndex: grpc.handleServerStreamingCall<commands_commands_pb.UpdateLibrariesIndexReq, commands_commands_pb.UpdateLibrariesIndexResp>;
version: grpc.handleUnaryCall<commands_commands_pb.VersionReq, commands_commands_pb.VersionResp>;
boardDetails: grpc.handleUnaryCall<commands_board_pb.BoardDetailsReq, commands_board_pb.BoardDetailsResp>;
boardAttach: grpc.handleServerStreamingCall<commands_board_pb.BoardAttachReq, commands_board_pb.BoardAttachResp>;
boardList: grpc.handleUnaryCall<commands_board_pb.BoardListReq, commands_board_pb.BoardListResp>;
boardListAll: grpc.handleUnaryCall<commands_board_pb.BoardListAllReq, commands_board_pb.BoardListAllResp>;
compile: grpc.handleServerStreamingCall<commands_compile_pb.CompileReq, commands_compile_pb.CompileResp>;
platformInstall: grpc.handleServerStreamingCall<commands_core_pb.PlatformInstallReq, commands_core_pb.PlatformInstallResp>;
platformDownload: grpc.handleServerStreamingCall<commands_core_pb.PlatformDownloadReq, commands_core_pb.PlatformDownloadResp>;
platformUninstall: grpc.handleServerStreamingCall<commands_core_pb.PlatformUninstallReq, commands_core_pb.PlatformUninstallResp>;
platformUpgrade: grpc.handleServerStreamingCall<commands_core_pb.PlatformUpgradeReq, commands_core_pb.PlatformUpgradeResp>;
upload: grpc.handleServerStreamingCall<commands_upload_pb.UploadReq, commands_upload_pb.UploadResp>;
platformSearch: grpc.handleUnaryCall<commands_core_pb.PlatformSearchReq, commands_core_pb.PlatformSearchResp>;
platformList: grpc.handleUnaryCall<commands_core_pb.PlatformListReq, commands_core_pb.PlatformListResp>;
libraryDownload: grpc.handleServerStreamingCall<commands_lib_pb.LibraryDownloadReq, commands_lib_pb.LibraryDownloadResp>;
libraryInstall: grpc.handleServerStreamingCall<commands_lib_pb.LibraryInstallReq, commands_lib_pb.LibraryInstallResp>;
libraryUninstall: grpc.handleServerStreamingCall<commands_lib_pb.LibraryUninstallReq, commands_lib_pb.LibraryUninstallResp>;
libraryUpgradeAll: grpc.handleServerStreamingCall<commands_lib_pb.LibraryUpgradeAllReq, commands_lib_pb.LibraryUpgradeAllResp>;
librarySearch: grpc.handleUnaryCall<commands_lib_pb.LibrarySearchReq, commands_lib_pb.LibrarySearchResp>;
libraryList: grpc.handleUnaryCall<commands_lib_pb.LibraryListReq, commands_lib_pb.LibraryListResp>;
}
export interface IArduinoCoreClient {
init(request: commands_commands_pb.InitReq, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_commands_pb.InitResp>;
init(request: commands_commands_pb.InitReq, metadata?: grpc.Metadata, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_commands_pb.InitResp>;
destroy(request: commands_commands_pb.DestroyReq, callback: (error: grpc.ServiceError | null, response: commands_commands_pb.DestroyResp) => void): grpc.ClientUnaryCall;
destroy(request: commands_commands_pb.DestroyReq, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: commands_commands_pb.DestroyResp) => void): grpc.ClientUnaryCall;
destroy(request: commands_commands_pb.DestroyReq, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: commands_commands_pb.DestroyResp) => void): grpc.ClientUnaryCall;
rescan(request: commands_commands_pb.RescanReq, callback: (error: grpc.ServiceError | null, response: commands_commands_pb.RescanResp) => void): grpc.ClientUnaryCall;
rescan(request: commands_commands_pb.RescanReq, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: commands_commands_pb.RescanResp) => void): grpc.ClientUnaryCall;
rescan(request: commands_commands_pb.RescanReq, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: commands_commands_pb.RescanResp) => void): grpc.ClientUnaryCall;
updateIndex(request: commands_commands_pb.UpdateIndexReq, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_commands_pb.UpdateIndexResp>;
updateIndex(request: commands_commands_pb.UpdateIndexReq, metadata?: grpc.Metadata, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_commands_pb.UpdateIndexResp>;
updateLibrariesIndex(request: commands_commands_pb.UpdateLibrariesIndexReq, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_commands_pb.UpdateLibrariesIndexResp>;
updateLibrariesIndex(request: commands_commands_pb.UpdateLibrariesIndexReq, metadata?: grpc.Metadata, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_commands_pb.UpdateLibrariesIndexResp>;
version(request: commands_commands_pb.VersionReq, callback: (error: grpc.ServiceError | null, response: commands_commands_pb.VersionResp) => void): grpc.ClientUnaryCall;
version(request: commands_commands_pb.VersionReq, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: commands_commands_pb.VersionResp) => void): grpc.ClientUnaryCall;
version(request: commands_commands_pb.VersionReq, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: commands_commands_pb.VersionResp) => void): grpc.ClientUnaryCall;
boardDetails(request: commands_board_pb.BoardDetailsReq, callback: (error: grpc.ServiceError | null, response: commands_board_pb.BoardDetailsResp) => void): grpc.ClientUnaryCall;
boardDetails(request: commands_board_pb.BoardDetailsReq, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: commands_board_pb.BoardDetailsResp) => void): grpc.ClientUnaryCall;
boardDetails(request: commands_board_pb.BoardDetailsReq, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: commands_board_pb.BoardDetailsResp) => void): grpc.ClientUnaryCall;
boardAttach(request: commands_board_pb.BoardAttachReq, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_board_pb.BoardAttachResp>;
boardAttach(request: commands_board_pb.BoardAttachReq, metadata?: grpc.Metadata, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_board_pb.BoardAttachResp>;
boardList(request: commands_board_pb.BoardListReq, callback: (error: grpc.ServiceError | null, response: commands_board_pb.BoardListResp) => void): grpc.ClientUnaryCall;
boardList(request: commands_board_pb.BoardListReq, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: commands_board_pb.BoardListResp) => void): grpc.ClientUnaryCall;
boardList(request: commands_board_pb.BoardListReq, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: commands_board_pb.BoardListResp) => void): grpc.ClientUnaryCall;
boardListAll(request: commands_board_pb.BoardListAllReq, callback: (error: grpc.ServiceError | null, response: commands_board_pb.BoardListAllResp) => void): grpc.ClientUnaryCall;
boardListAll(request: commands_board_pb.BoardListAllReq, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: commands_board_pb.BoardListAllResp) => void): grpc.ClientUnaryCall;
boardListAll(request: commands_board_pb.BoardListAllReq, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: commands_board_pb.BoardListAllResp) => void): grpc.ClientUnaryCall;
compile(request: commands_compile_pb.CompileReq, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_compile_pb.CompileResp>;
compile(request: commands_compile_pb.CompileReq, metadata?: grpc.Metadata, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_compile_pb.CompileResp>;
platformInstall(request: commands_core_pb.PlatformInstallReq, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_core_pb.PlatformInstallResp>;
platformInstall(request: commands_core_pb.PlatformInstallReq, metadata?: grpc.Metadata, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_core_pb.PlatformInstallResp>;
platformDownload(request: commands_core_pb.PlatformDownloadReq, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_core_pb.PlatformDownloadResp>;
platformDownload(request: commands_core_pb.PlatformDownloadReq, metadata?: grpc.Metadata, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_core_pb.PlatformDownloadResp>;
platformUninstall(request: commands_core_pb.PlatformUninstallReq, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_core_pb.PlatformUninstallResp>;
platformUninstall(request: commands_core_pb.PlatformUninstallReq, metadata?: grpc.Metadata, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_core_pb.PlatformUninstallResp>;
platformUpgrade(request: commands_core_pb.PlatformUpgradeReq, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_core_pb.PlatformUpgradeResp>;
platformUpgrade(request: commands_core_pb.PlatformUpgradeReq, metadata?: grpc.Metadata, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_core_pb.PlatformUpgradeResp>;
upload(request: commands_upload_pb.UploadReq, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_upload_pb.UploadResp>;
upload(request: commands_upload_pb.UploadReq, metadata?: grpc.Metadata, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_upload_pb.UploadResp>;
platformSearch(request: commands_core_pb.PlatformSearchReq, callback: (error: grpc.ServiceError | null, response: commands_core_pb.PlatformSearchResp) => void): grpc.ClientUnaryCall;
platformSearch(request: commands_core_pb.PlatformSearchReq, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: commands_core_pb.PlatformSearchResp) => void): grpc.ClientUnaryCall;
platformSearch(request: commands_core_pb.PlatformSearchReq, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: commands_core_pb.PlatformSearchResp) => void): grpc.ClientUnaryCall;
platformList(request: commands_core_pb.PlatformListReq, callback: (error: grpc.ServiceError | null, response: commands_core_pb.PlatformListResp) => void): grpc.ClientUnaryCall;
platformList(request: commands_core_pb.PlatformListReq, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: commands_core_pb.PlatformListResp) => void): grpc.ClientUnaryCall;
platformList(request: commands_core_pb.PlatformListReq, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: commands_core_pb.PlatformListResp) => void): grpc.ClientUnaryCall;
libraryDownload(request: commands_lib_pb.LibraryDownloadReq, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_lib_pb.LibraryDownloadResp>;
libraryDownload(request: commands_lib_pb.LibraryDownloadReq, metadata?: grpc.Metadata, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_lib_pb.LibraryDownloadResp>;
libraryInstall(request: commands_lib_pb.LibraryInstallReq, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_lib_pb.LibraryInstallResp>;
libraryInstall(request: commands_lib_pb.LibraryInstallReq, metadata?: grpc.Metadata, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_lib_pb.LibraryInstallResp>;
libraryUninstall(request: commands_lib_pb.LibraryUninstallReq, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_lib_pb.LibraryUninstallResp>;
libraryUninstall(request: commands_lib_pb.LibraryUninstallReq, metadata?: grpc.Metadata, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_lib_pb.LibraryUninstallResp>;
libraryUpgradeAll(request: commands_lib_pb.LibraryUpgradeAllReq, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_lib_pb.LibraryUpgradeAllResp>;
libraryUpgradeAll(request: commands_lib_pb.LibraryUpgradeAllReq, metadata?: grpc.Metadata, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_lib_pb.LibraryUpgradeAllResp>;
librarySearch(request: commands_lib_pb.LibrarySearchReq, callback: (error: grpc.ServiceError | null, response: commands_lib_pb.LibrarySearchResp) => void): grpc.ClientUnaryCall;
librarySearch(request: commands_lib_pb.LibrarySearchReq, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: commands_lib_pb.LibrarySearchResp) => void): grpc.ClientUnaryCall;
librarySearch(request: commands_lib_pb.LibrarySearchReq, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: commands_lib_pb.LibrarySearchResp) => void): grpc.ClientUnaryCall;
libraryList(request: commands_lib_pb.LibraryListReq, callback: (error: grpc.ServiceError | null, response: commands_lib_pb.LibraryListResp) => void): grpc.ClientUnaryCall;
libraryList(request: commands_lib_pb.LibraryListReq, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: commands_lib_pb.LibraryListResp) => void): grpc.ClientUnaryCall;
libraryList(request: commands_lib_pb.LibraryListReq, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: commands_lib_pb.LibraryListResp) => void): grpc.ClientUnaryCall;
}
export class ArduinoCoreClient extends grpc.Client implements IArduinoCoreClient {
constructor(address: string, credentials: grpc.ChannelCredentials, options?: object);
public init(request: commands_commands_pb.InitReq, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_commands_pb.InitResp>;
public init(request: commands_commands_pb.InitReq, metadata?: grpc.Metadata, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_commands_pb.InitResp>;
public destroy(request: commands_commands_pb.DestroyReq, callback: (error: grpc.ServiceError | null, response: commands_commands_pb.DestroyResp) => void): grpc.ClientUnaryCall;
public destroy(request: commands_commands_pb.DestroyReq, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: commands_commands_pb.DestroyResp) => void): grpc.ClientUnaryCall;
public destroy(request: commands_commands_pb.DestroyReq, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: commands_commands_pb.DestroyResp) => void): grpc.ClientUnaryCall;
public rescan(request: commands_commands_pb.RescanReq, callback: (error: grpc.ServiceError | null, response: commands_commands_pb.RescanResp) => void): grpc.ClientUnaryCall;
public rescan(request: commands_commands_pb.RescanReq, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: commands_commands_pb.RescanResp) => void): grpc.ClientUnaryCall;
public rescan(request: commands_commands_pb.RescanReq, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: commands_commands_pb.RescanResp) => void): grpc.ClientUnaryCall;
public updateIndex(request: commands_commands_pb.UpdateIndexReq, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_commands_pb.UpdateIndexResp>;
public updateIndex(request: commands_commands_pb.UpdateIndexReq, metadata?: grpc.Metadata, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_commands_pb.UpdateIndexResp>;
public updateLibrariesIndex(request: commands_commands_pb.UpdateLibrariesIndexReq, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_commands_pb.UpdateLibrariesIndexResp>;
public updateLibrariesIndex(request: commands_commands_pb.UpdateLibrariesIndexReq, metadata?: grpc.Metadata, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_commands_pb.UpdateLibrariesIndexResp>;
public version(request: commands_commands_pb.VersionReq, callback: (error: grpc.ServiceError | null, response: commands_commands_pb.VersionResp) => void): grpc.ClientUnaryCall;
public version(request: commands_commands_pb.VersionReq, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: commands_commands_pb.VersionResp) => void): grpc.ClientUnaryCall;
public version(request: commands_commands_pb.VersionReq, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: commands_commands_pb.VersionResp) => void): grpc.ClientUnaryCall;
public boardDetails(request: commands_board_pb.BoardDetailsReq, callback: (error: grpc.ServiceError | null, response: commands_board_pb.BoardDetailsResp) => void): grpc.ClientUnaryCall;
public boardDetails(request: commands_board_pb.BoardDetailsReq, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: commands_board_pb.BoardDetailsResp) => void): grpc.ClientUnaryCall;
public boardDetails(request: commands_board_pb.BoardDetailsReq, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: commands_board_pb.BoardDetailsResp) => void): grpc.ClientUnaryCall;
public boardAttach(request: commands_board_pb.BoardAttachReq, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_board_pb.BoardAttachResp>;
public boardAttach(request: commands_board_pb.BoardAttachReq, metadata?: grpc.Metadata, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_board_pb.BoardAttachResp>;
public boardList(request: commands_board_pb.BoardListReq, callback: (error: grpc.ServiceError | null, response: commands_board_pb.BoardListResp) => void): grpc.ClientUnaryCall;
public boardList(request: commands_board_pb.BoardListReq, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: commands_board_pb.BoardListResp) => void): grpc.ClientUnaryCall;
public boardList(request: commands_board_pb.BoardListReq, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: commands_board_pb.BoardListResp) => void): grpc.ClientUnaryCall;
public boardListAll(request: commands_board_pb.BoardListAllReq, callback: (error: grpc.ServiceError | null, response: commands_board_pb.BoardListAllResp) => void): grpc.ClientUnaryCall;
public boardListAll(request: commands_board_pb.BoardListAllReq, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: commands_board_pb.BoardListAllResp) => void): grpc.ClientUnaryCall;
public boardListAll(request: commands_board_pb.BoardListAllReq, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: commands_board_pb.BoardListAllResp) => void): grpc.ClientUnaryCall;
public compile(request: commands_compile_pb.CompileReq, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_compile_pb.CompileResp>;
public compile(request: commands_compile_pb.CompileReq, metadata?: grpc.Metadata, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_compile_pb.CompileResp>;
public platformInstall(request: commands_core_pb.PlatformInstallReq, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_core_pb.PlatformInstallResp>;
public platformInstall(request: commands_core_pb.PlatformInstallReq, metadata?: grpc.Metadata, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_core_pb.PlatformInstallResp>;
public platformDownload(request: commands_core_pb.PlatformDownloadReq, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_core_pb.PlatformDownloadResp>;
public platformDownload(request: commands_core_pb.PlatformDownloadReq, metadata?: grpc.Metadata, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_core_pb.PlatformDownloadResp>;
public platformUninstall(request: commands_core_pb.PlatformUninstallReq, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_core_pb.PlatformUninstallResp>;
public platformUninstall(request: commands_core_pb.PlatformUninstallReq, metadata?: grpc.Metadata, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_core_pb.PlatformUninstallResp>;
public platformUpgrade(request: commands_core_pb.PlatformUpgradeReq, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_core_pb.PlatformUpgradeResp>;
public platformUpgrade(request: commands_core_pb.PlatformUpgradeReq, metadata?: grpc.Metadata, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_core_pb.PlatformUpgradeResp>;
public upload(request: commands_upload_pb.UploadReq, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_upload_pb.UploadResp>;
public upload(request: commands_upload_pb.UploadReq, metadata?: grpc.Metadata, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_upload_pb.UploadResp>;
public platformSearch(request: commands_core_pb.PlatformSearchReq, callback: (error: grpc.ServiceError | null, response: commands_core_pb.PlatformSearchResp) => void): grpc.ClientUnaryCall;
public platformSearch(request: commands_core_pb.PlatformSearchReq, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: commands_core_pb.PlatformSearchResp) => void): grpc.ClientUnaryCall;
public platformSearch(request: commands_core_pb.PlatformSearchReq, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: commands_core_pb.PlatformSearchResp) => void): grpc.ClientUnaryCall;
public platformList(request: commands_core_pb.PlatformListReq, callback: (error: grpc.ServiceError | null, response: commands_core_pb.PlatformListResp) => void): grpc.ClientUnaryCall;
public platformList(request: commands_core_pb.PlatformListReq, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: commands_core_pb.PlatformListResp) => void): grpc.ClientUnaryCall;
public platformList(request: commands_core_pb.PlatformListReq, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: commands_core_pb.PlatformListResp) => void): grpc.ClientUnaryCall;
public libraryDownload(request: commands_lib_pb.LibraryDownloadReq, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_lib_pb.LibraryDownloadResp>;
public libraryDownload(request: commands_lib_pb.LibraryDownloadReq, metadata?: grpc.Metadata, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_lib_pb.LibraryDownloadResp>;
public libraryInstall(request: commands_lib_pb.LibraryInstallReq, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_lib_pb.LibraryInstallResp>;
public libraryInstall(request: commands_lib_pb.LibraryInstallReq, metadata?: grpc.Metadata, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_lib_pb.LibraryInstallResp>;
public libraryUninstall(request: commands_lib_pb.LibraryUninstallReq, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_lib_pb.LibraryUninstallResp>;
public libraryUninstall(request: commands_lib_pb.LibraryUninstallReq, metadata?: grpc.Metadata, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_lib_pb.LibraryUninstallResp>;
public libraryUpgradeAll(request: commands_lib_pb.LibraryUpgradeAllReq, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_lib_pb.LibraryUpgradeAllResp>;
public libraryUpgradeAll(request: commands_lib_pb.LibraryUpgradeAllReq, metadata?: grpc.Metadata, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_lib_pb.LibraryUpgradeAllResp>;
public librarySearch(request: commands_lib_pb.LibrarySearchReq, callback: (error: grpc.ServiceError | null, response: commands_lib_pb.LibrarySearchResp) => void): grpc.ClientUnaryCall;
public librarySearch(request: commands_lib_pb.LibrarySearchReq, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: commands_lib_pb.LibrarySearchResp) => void): grpc.ClientUnaryCall;
public librarySearch(request: commands_lib_pb.LibrarySearchReq, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: commands_lib_pb.LibrarySearchResp) => void): grpc.ClientUnaryCall;
public libraryList(request: commands_lib_pb.LibraryListReq, callback: (error: grpc.ServiceError | null, response: commands_lib_pb.LibraryListResp) => void): grpc.ClientUnaryCall;
public libraryList(request: commands_lib_pb.LibraryListReq, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: commands_lib_pb.LibraryListResp) => void): grpc.ClientUnaryCall;
public libraryList(request: commands_lib_pb.LibraryListReq, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: commands_lib_pb.LibraryListResp) => void): grpc.ClientUnaryCall;
}

View File

@ -0,0 +1,839 @@
// GENERATED CODE -- DO NOT EDIT!
// Original file comments:
//
// This file is part of arduino-cli.
//
// Copyright 2018 ARDUINO SA (http://www.arduino.cc/)
//
// This software is released under the GNU General Public License version 3,
// which covers the main part of arduino-cli.
// The terms of this license can be found at:
// https://www.gnu.org/licenses/gpl-3.0.en.html
//
// You can be released from the requirements of the above licenses by purchasing
// a commercial license. Buying such a license is mandatory if you want to modify or
// otherwise use the software for commercial activities involving the Arduino
// software without disclosing the source code of your own applications. To purchase
// a commercial license, send an email to license@arduino.cc.
//
//
'use strict';
var grpc = require('@grpc/grpc-js');
var commands_commands_pb = require('../commands/commands_pb.js');
var commands_common_pb = require('../commands/common_pb.js');
var commands_board_pb = require('../commands/board_pb.js');
var commands_compile_pb = require('../commands/compile_pb.js');
var commands_core_pb = require('../commands/core_pb.js');
var commands_upload_pb = require('../commands/upload_pb.js');
var commands_lib_pb = require('../commands/lib_pb.js');
function serialize_cc_arduino_cli_commands_BoardAttachReq(arg) {
if (!(arg instanceof commands_board_pb.BoardAttachReq)) {
throw new Error('Expected argument of type cc.arduino.cli.commands.BoardAttachReq');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_cc_arduino_cli_commands_BoardAttachReq(buffer_arg) {
return commands_board_pb.BoardAttachReq.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_cc_arduino_cli_commands_BoardAttachResp(arg) {
if (!(arg instanceof commands_board_pb.BoardAttachResp)) {
throw new Error('Expected argument of type cc.arduino.cli.commands.BoardAttachResp');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_cc_arduino_cli_commands_BoardAttachResp(buffer_arg) {
return commands_board_pb.BoardAttachResp.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_cc_arduino_cli_commands_BoardDetailsReq(arg) {
if (!(arg instanceof commands_board_pb.BoardDetailsReq)) {
throw new Error('Expected argument of type cc.arduino.cli.commands.BoardDetailsReq');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_cc_arduino_cli_commands_BoardDetailsReq(buffer_arg) {
return commands_board_pb.BoardDetailsReq.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_cc_arduino_cli_commands_BoardDetailsResp(arg) {
if (!(arg instanceof commands_board_pb.BoardDetailsResp)) {
throw new Error('Expected argument of type cc.arduino.cli.commands.BoardDetailsResp');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_cc_arduino_cli_commands_BoardDetailsResp(buffer_arg) {
return commands_board_pb.BoardDetailsResp.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_cc_arduino_cli_commands_BoardListAllReq(arg) {
if (!(arg instanceof commands_board_pb.BoardListAllReq)) {
throw new Error('Expected argument of type cc.arduino.cli.commands.BoardListAllReq');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_cc_arduino_cli_commands_BoardListAllReq(buffer_arg) {
return commands_board_pb.BoardListAllReq.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_cc_arduino_cli_commands_BoardListAllResp(arg) {
if (!(arg instanceof commands_board_pb.BoardListAllResp)) {
throw new Error('Expected argument of type cc.arduino.cli.commands.BoardListAllResp');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_cc_arduino_cli_commands_BoardListAllResp(buffer_arg) {
return commands_board_pb.BoardListAllResp.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_cc_arduino_cli_commands_BoardListReq(arg) {
if (!(arg instanceof commands_board_pb.BoardListReq)) {
throw new Error('Expected argument of type cc.arduino.cli.commands.BoardListReq');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_cc_arduino_cli_commands_BoardListReq(buffer_arg) {
return commands_board_pb.BoardListReq.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_cc_arduino_cli_commands_BoardListResp(arg) {
if (!(arg instanceof commands_board_pb.BoardListResp)) {
throw new Error('Expected argument of type cc.arduino.cli.commands.BoardListResp');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_cc_arduino_cli_commands_BoardListResp(buffer_arg) {
return commands_board_pb.BoardListResp.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_cc_arduino_cli_commands_CompileReq(arg) {
if (!(arg instanceof commands_compile_pb.CompileReq)) {
throw new Error('Expected argument of type cc.arduino.cli.commands.CompileReq');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_cc_arduino_cli_commands_CompileReq(buffer_arg) {
return commands_compile_pb.CompileReq.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_cc_arduino_cli_commands_CompileResp(arg) {
if (!(arg instanceof commands_compile_pb.CompileResp)) {
throw new Error('Expected argument of type cc.arduino.cli.commands.CompileResp');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_cc_arduino_cli_commands_CompileResp(buffer_arg) {
return commands_compile_pb.CompileResp.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_cc_arduino_cli_commands_DestroyReq(arg) {
if (!(arg instanceof commands_commands_pb.DestroyReq)) {
throw new Error('Expected argument of type cc.arduino.cli.commands.DestroyReq');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_cc_arduino_cli_commands_DestroyReq(buffer_arg) {
return commands_commands_pb.DestroyReq.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_cc_arduino_cli_commands_DestroyResp(arg) {
if (!(arg instanceof commands_commands_pb.DestroyResp)) {
throw new Error('Expected argument of type cc.arduino.cli.commands.DestroyResp');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_cc_arduino_cli_commands_DestroyResp(buffer_arg) {
return commands_commands_pb.DestroyResp.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_cc_arduino_cli_commands_InitReq(arg) {
if (!(arg instanceof commands_commands_pb.InitReq)) {
throw new Error('Expected argument of type cc.arduino.cli.commands.InitReq');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_cc_arduino_cli_commands_InitReq(buffer_arg) {
return commands_commands_pb.InitReq.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_cc_arduino_cli_commands_InitResp(arg) {
if (!(arg instanceof commands_commands_pb.InitResp)) {
throw new Error('Expected argument of type cc.arduino.cli.commands.InitResp');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_cc_arduino_cli_commands_InitResp(buffer_arg) {
return commands_commands_pb.InitResp.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_cc_arduino_cli_commands_LibraryDownloadReq(arg) {
if (!(arg instanceof commands_lib_pb.LibraryDownloadReq)) {
throw new Error('Expected argument of type cc.arduino.cli.commands.LibraryDownloadReq');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_cc_arduino_cli_commands_LibraryDownloadReq(buffer_arg) {
return commands_lib_pb.LibraryDownloadReq.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_cc_arduino_cli_commands_LibraryDownloadResp(arg) {
if (!(arg instanceof commands_lib_pb.LibraryDownloadResp)) {
throw new Error('Expected argument of type cc.arduino.cli.commands.LibraryDownloadResp');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_cc_arduino_cli_commands_LibraryDownloadResp(buffer_arg) {
return commands_lib_pb.LibraryDownloadResp.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_cc_arduino_cli_commands_LibraryInstallReq(arg) {
if (!(arg instanceof commands_lib_pb.LibraryInstallReq)) {
throw new Error('Expected argument of type cc.arduino.cli.commands.LibraryInstallReq');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_cc_arduino_cli_commands_LibraryInstallReq(buffer_arg) {
return commands_lib_pb.LibraryInstallReq.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_cc_arduino_cli_commands_LibraryInstallResp(arg) {
if (!(arg instanceof commands_lib_pb.LibraryInstallResp)) {
throw new Error('Expected argument of type cc.arduino.cli.commands.LibraryInstallResp');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_cc_arduino_cli_commands_LibraryInstallResp(buffer_arg) {
return commands_lib_pb.LibraryInstallResp.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_cc_arduino_cli_commands_LibraryListReq(arg) {
if (!(arg instanceof commands_lib_pb.LibraryListReq)) {
throw new Error('Expected argument of type cc.arduino.cli.commands.LibraryListReq');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_cc_arduino_cli_commands_LibraryListReq(buffer_arg) {
return commands_lib_pb.LibraryListReq.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_cc_arduino_cli_commands_LibraryListResp(arg) {
if (!(arg instanceof commands_lib_pb.LibraryListResp)) {
throw new Error('Expected argument of type cc.arduino.cli.commands.LibraryListResp');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_cc_arduino_cli_commands_LibraryListResp(buffer_arg) {
return commands_lib_pb.LibraryListResp.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_cc_arduino_cli_commands_LibrarySearchReq(arg) {
if (!(arg instanceof commands_lib_pb.LibrarySearchReq)) {
throw new Error('Expected argument of type cc.arduino.cli.commands.LibrarySearchReq');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_cc_arduino_cli_commands_LibrarySearchReq(buffer_arg) {
return commands_lib_pb.LibrarySearchReq.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_cc_arduino_cli_commands_LibrarySearchResp(arg) {
if (!(arg instanceof commands_lib_pb.LibrarySearchResp)) {
throw new Error('Expected argument of type cc.arduino.cli.commands.LibrarySearchResp');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_cc_arduino_cli_commands_LibrarySearchResp(buffer_arg) {
return commands_lib_pb.LibrarySearchResp.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_cc_arduino_cli_commands_LibraryUninstallReq(arg) {
if (!(arg instanceof commands_lib_pb.LibraryUninstallReq)) {
throw new Error('Expected argument of type cc.arduino.cli.commands.LibraryUninstallReq');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_cc_arduino_cli_commands_LibraryUninstallReq(buffer_arg) {
return commands_lib_pb.LibraryUninstallReq.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_cc_arduino_cli_commands_LibraryUninstallResp(arg) {
if (!(arg instanceof commands_lib_pb.LibraryUninstallResp)) {
throw new Error('Expected argument of type cc.arduino.cli.commands.LibraryUninstallResp');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_cc_arduino_cli_commands_LibraryUninstallResp(buffer_arg) {
return commands_lib_pb.LibraryUninstallResp.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_cc_arduino_cli_commands_LibraryUpgradeAllReq(arg) {
if (!(arg instanceof commands_lib_pb.LibraryUpgradeAllReq)) {
throw new Error('Expected argument of type cc.arduino.cli.commands.LibraryUpgradeAllReq');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_cc_arduino_cli_commands_LibraryUpgradeAllReq(buffer_arg) {
return commands_lib_pb.LibraryUpgradeAllReq.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_cc_arduino_cli_commands_LibraryUpgradeAllResp(arg) {
if (!(arg instanceof commands_lib_pb.LibraryUpgradeAllResp)) {
throw new Error('Expected argument of type cc.arduino.cli.commands.LibraryUpgradeAllResp');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_cc_arduino_cli_commands_LibraryUpgradeAllResp(buffer_arg) {
return commands_lib_pb.LibraryUpgradeAllResp.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_cc_arduino_cli_commands_PlatformDownloadReq(arg) {
if (!(arg instanceof commands_core_pb.PlatformDownloadReq)) {
throw new Error('Expected argument of type cc.arduino.cli.commands.PlatformDownloadReq');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_cc_arduino_cli_commands_PlatformDownloadReq(buffer_arg) {
return commands_core_pb.PlatformDownloadReq.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_cc_arduino_cli_commands_PlatformDownloadResp(arg) {
if (!(arg instanceof commands_core_pb.PlatformDownloadResp)) {
throw new Error('Expected argument of type cc.arduino.cli.commands.PlatformDownloadResp');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_cc_arduino_cli_commands_PlatformDownloadResp(buffer_arg) {
return commands_core_pb.PlatformDownloadResp.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_cc_arduino_cli_commands_PlatformInstallReq(arg) {
if (!(arg instanceof commands_core_pb.PlatformInstallReq)) {
throw new Error('Expected argument of type cc.arduino.cli.commands.PlatformInstallReq');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_cc_arduino_cli_commands_PlatformInstallReq(buffer_arg) {
return commands_core_pb.PlatformInstallReq.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_cc_arduino_cli_commands_PlatformInstallResp(arg) {
if (!(arg instanceof commands_core_pb.PlatformInstallResp)) {
throw new Error('Expected argument of type cc.arduino.cli.commands.PlatformInstallResp');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_cc_arduino_cli_commands_PlatformInstallResp(buffer_arg) {
return commands_core_pb.PlatformInstallResp.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_cc_arduino_cli_commands_PlatformListReq(arg) {
if (!(arg instanceof commands_core_pb.PlatformListReq)) {
throw new Error('Expected argument of type cc.arduino.cli.commands.PlatformListReq');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_cc_arduino_cli_commands_PlatformListReq(buffer_arg) {
return commands_core_pb.PlatformListReq.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_cc_arduino_cli_commands_PlatformListResp(arg) {
if (!(arg instanceof commands_core_pb.PlatformListResp)) {
throw new Error('Expected argument of type cc.arduino.cli.commands.PlatformListResp');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_cc_arduino_cli_commands_PlatformListResp(buffer_arg) {
return commands_core_pb.PlatformListResp.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_cc_arduino_cli_commands_PlatformSearchReq(arg) {
if (!(arg instanceof commands_core_pb.PlatformSearchReq)) {
throw new Error('Expected argument of type cc.arduino.cli.commands.PlatformSearchReq');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_cc_arduino_cli_commands_PlatformSearchReq(buffer_arg) {
return commands_core_pb.PlatformSearchReq.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_cc_arduino_cli_commands_PlatformSearchResp(arg) {
if (!(arg instanceof commands_core_pb.PlatformSearchResp)) {
throw new Error('Expected argument of type cc.arduino.cli.commands.PlatformSearchResp');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_cc_arduino_cli_commands_PlatformSearchResp(buffer_arg) {
return commands_core_pb.PlatformSearchResp.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_cc_arduino_cli_commands_PlatformUninstallReq(arg) {
if (!(arg instanceof commands_core_pb.PlatformUninstallReq)) {
throw new Error('Expected argument of type cc.arduino.cli.commands.PlatformUninstallReq');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_cc_arduino_cli_commands_PlatformUninstallReq(buffer_arg) {
return commands_core_pb.PlatformUninstallReq.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_cc_arduino_cli_commands_PlatformUninstallResp(arg) {
if (!(arg instanceof commands_core_pb.PlatformUninstallResp)) {
throw new Error('Expected argument of type cc.arduino.cli.commands.PlatformUninstallResp');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_cc_arduino_cli_commands_PlatformUninstallResp(buffer_arg) {
return commands_core_pb.PlatformUninstallResp.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_cc_arduino_cli_commands_PlatformUpgradeReq(arg) {
if (!(arg instanceof commands_core_pb.PlatformUpgradeReq)) {
throw new Error('Expected argument of type cc.arduino.cli.commands.PlatformUpgradeReq');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_cc_arduino_cli_commands_PlatformUpgradeReq(buffer_arg) {
return commands_core_pb.PlatformUpgradeReq.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_cc_arduino_cli_commands_PlatformUpgradeResp(arg) {
if (!(arg instanceof commands_core_pb.PlatformUpgradeResp)) {
throw new Error('Expected argument of type cc.arduino.cli.commands.PlatformUpgradeResp');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_cc_arduino_cli_commands_PlatformUpgradeResp(buffer_arg) {
return commands_core_pb.PlatformUpgradeResp.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_cc_arduino_cli_commands_RescanReq(arg) {
if (!(arg instanceof commands_commands_pb.RescanReq)) {
throw new Error('Expected argument of type cc.arduino.cli.commands.RescanReq');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_cc_arduino_cli_commands_RescanReq(buffer_arg) {
return commands_commands_pb.RescanReq.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_cc_arduino_cli_commands_RescanResp(arg) {
if (!(arg instanceof commands_commands_pb.RescanResp)) {
throw new Error('Expected argument of type cc.arduino.cli.commands.RescanResp');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_cc_arduino_cli_commands_RescanResp(buffer_arg) {
return commands_commands_pb.RescanResp.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_cc_arduino_cli_commands_UpdateIndexReq(arg) {
if (!(arg instanceof commands_commands_pb.UpdateIndexReq)) {
throw new Error('Expected argument of type cc.arduino.cli.commands.UpdateIndexReq');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_cc_arduino_cli_commands_UpdateIndexReq(buffer_arg) {
return commands_commands_pb.UpdateIndexReq.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_cc_arduino_cli_commands_UpdateIndexResp(arg) {
if (!(arg instanceof commands_commands_pb.UpdateIndexResp)) {
throw new Error('Expected argument of type cc.arduino.cli.commands.UpdateIndexResp');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_cc_arduino_cli_commands_UpdateIndexResp(buffer_arg) {
return commands_commands_pb.UpdateIndexResp.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_cc_arduino_cli_commands_UpdateLibrariesIndexReq(arg) {
if (!(arg instanceof commands_commands_pb.UpdateLibrariesIndexReq)) {
throw new Error('Expected argument of type cc.arduino.cli.commands.UpdateLibrariesIndexReq');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_cc_arduino_cli_commands_UpdateLibrariesIndexReq(buffer_arg) {
return commands_commands_pb.UpdateLibrariesIndexReq.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_cc_arduino_cli_commands_UpdateLibrariesIndexResp(arg) {
if (!(arg instanceof commands_commands_pb.UpdateLibrariesIndexResp)) {
throw new Error('Expected argument of type cc.arduino.cli.commands.UpdateLibrariesIndexResp');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_cc_arduino_cli_commands_UpdateLibrariesIndexResp(buffer_arg) {
return commands_commands_pb.UpdateLibrariesIndexResp.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_cc_arduino_cli_commands_UploadReq(arg) {
if (!(arg instanceof commands_upload_pb.UploadReq)) {
throw new Error('Expected argument of type cc.arduino.cli.commands.UploadReq');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_cc_arduino_cli_commands_UploadReq(buffer_arg) {
return commands_upload_pb.UploadReq.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_cc_arduino_cli_commands_UploadResp(arg) {
if (!(arg instanceof commands_upload_pb.UploadResp)) {
throw new Error('Expected argument of type cc.arduino.cli.commands.UploadResp');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_cc_arduino_cli_commands_UploadResp(buffer_arg) {
return commands_upload_pb.UploadResp.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_cc_arduino_cli_commands_VersionReq(arg) {
if (!(arg instanceof commands_commands_pb.VersionReq)) {
throw new Error('Expected argument of type cc.arduino.cli.commands.VersionReq');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_cc_arduino_cli_commands_VersionReq(buffer_arg) {
return commands_commands_pb.VersionReq.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_cc_arduino_cli_commands_VersionResp(arg) {
if (!(arg instanceof commands_commands_pb.VersionResp)) {
throw new Error('Expected argument of type cc.arduino.cli.commands.VersionResp');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_cc_arduino_cli_commands_VersionResp(buffer_arg) {
return commands_commands_pb.VersionResp.deserializeBinary(new Uint8Array(buffer_arg));
}
// The main Arduino Platform Service
var ArduinoCoreService = exports.ArduinoCoreService = {
// Start a new instance of the Arduino Core Service
init: {
path: '/cc.arduino.cli.commands.ArduinoCore/Init',
requestStream: false,
responseStream: true,
requestType: commands_commands_pb.InitReq,
responseType: commands_commands_pb.InitResp,
requestSerialize: serialize_cc_arduino_cli_commands_InitReq,
requestDeserialize: deserialize_cc_arduino_cli_commands_InitReq,
responseSerialize: serialize_cc_arduino_cli_commands_InitResp,
responseDeserialize: deserialize_cc_arduino_cli_commands_InitResp,
},
// Destroy an instance of the Arduino Core Service
destroy: {
path: '/cc.arduino.cli.commands.ArduinoCore/Destroy',
requestStream: false,
responseStream: false,
requestType: commands_commands_pb.DestroyReq,
responseType: commands_commands_pb.DestroyResp,
requestSerialize: serialize_cc_arduino_cli_commands_DestroyReq,
requestDeserialize: deserialize_cc_arduino_cli_commands_DestroyReq,
responseSerialize: serialize_cc_arduino_cli_commands_DestroyResp,
responseDeserialize: deserialize_cc_arduino_cli_commands_DestroyResp,
},
// Rescan instance of the Arduino Core Service
rescan: {
path: '/cc.arduino.cli.commands.ArduinoCore/Rescan',
requestStream: false,
responseStream: false,
requestType: commands_commands_pb.RescanReq,
responseType: commands_commands_pb.RescanResp,
requestSerialize: serialize_cc_arduino_cli_commands_RescanReq,
requestDeserialize: deserialize_cc_arduino_cli_commands_RescanReq,
responseSerialize: serialize_cc_arduino_cli_commands_RescanResp,
responseDeserialize: deserialize_cc_arduino_cli_commands_RescanResp,
},
// Update package index of the Arduino Core Service
updateIndex: {
path: '/cc.arduino.cli.commands.ArduinoCore/UpdateIndex',
requestStream: false,
responseStream: true,
requestType: commands_commands_pb.UpdateIndexReq,
responseType: commands_commands_pb.UpdateIndexResp,
requestSerialize: serialize_cc_arduino_cli_commands_UpdateIndexReq,
requestDeserialize: deserialize_cc_arduino_cli_commands_UpdateIndexReq,
responseSerialize: serialize_cc_arduino_cli_commands_UpdateIndexResp,
responseDeserialize: deserialize_cc_arduino_cli_commands_UpdateIndexResp,
},
// Update libraries index
updateLibrariesIndex: {
path: '/cc.arduino.cli.commands.ArduinoCore/UpdateLibrariesIndex',
requestStream: false,
responseStream: true,
requestType: commands_commands_pb.UpdateLibrariesIndexReq,
responseType: commands_commands_pb.UpdateLibrariesIndexResp,
requestSerialize: serialize_cc_arduino_cli_commands_UpdateLibrariesIndexReq,
requestDeserialize: deserialize_cc_arduino_cli_commands_UpdateLibrariesIndexReq,
responseSerialize: serialize_cc_arduino_cli_commands_UpdateLibrariesIndexResp,
responseDeserialize: deserialize_cc_arduino_cli_commands_UpdateLibrariesIndexResp,
},
version: {
path: '/cc.arduino.cli.commands.ArduinoCore/Version',
requestStream: false,
responseStream: false,
requestType: commands_commands_pb.VersionReq,
responseType: commands_commands_pb.VersionResp,
requestSerialize: serialize_cc_arduino_cli_commands_VersionReq,
requestDeserialize: deserialize_cc_arduino_cli_commands_VersionReq,
responseSerialize: serialize_cc_arduino_cli_commands_VersionResp,
responseDeserialize: deserialize_cc_arduino_cli_commands_VersionResp,
},
// BOARD COMMANDS
// --------------
//
// Requests details about a board
boardDetails: {
path: '/cc.arduino.cli.commands.ArduinoCore/BoardDetails',
requestStream: false,
responseStream: false,
requestType: commands_board_pb.BoardDetailsReq,
responseType: commands_board_pb.BoardDetailsResp,
requestSerialize: serialize_cc_arduino_cli_commands_BoardDetailsReq,
requestDeserialize: deserialize_cc_arduino_cli_commands_BoardDetailsReq,
responseSerialize: serialize_cc_arduino_cli_commands_BoardDetailsResp,
responseDeserialize: deserialize_cc_arduino_cli_commands_BoardDetailsResp,
},
boardAttach: {
path: '/cc.arduino.cli.commands.ArduinoCore/BoardAttach',
requestStream: false,
responseStream: true,
requestType: commands_board_pb.BoardAttachReq,
responseType: commands_board_pb.BoardAttachResp,
requestSerialize: serialize_cc_arduino_cli_commands_BoardAttachReq,
requestDeserialize: deserialize_cc_arduino_cli_commands_BoardAttachReq,
responseSerialize: serialize_cc_arduino_cli_commands_BoardAttachResp,
responseDeserialize: deserialize_cc_arduino_cli_commands_BoardAttachResp,
},
boardList: {
path: '/cc.arduino.cli.commands.ArduinoCore/BoardList',
requestStream: false,
responseStream: false,
requestType: commands_board_pb.BoardListReq,
responseType: commands_board_pb.BoardListResp,
requestSerialize: serialize_cc_arduino_cli_commands_BoardListReq,
requestDeserialize: deserialize_cc_arduino_cli_commands_BoardListReq,
responseSerialize: serialize_cc_arduino_cli_commands_BoardListResp,
responseDeserialize: deserialize_cc_arduino_cli_commands_BoardListResp,
},
boardListAll: {
path: '/cc.arduino.cli.commands.ArduinoCore/BoardListAll',
requestStream: false,
responseStream: false,
requestType: commands_board_pb.BoardListAllReq,
responseType: commands_board_pb.BoardListAllResp,
requestSerialize: serialize_cc_arduino_cli_commands_BoardListAllReq,
requestDeserialize: deserialize_cc_arduino_cli_commands_BoardListAllReq,
responseSerialize: serialize_cc_arduino_cli_commands_BoardListAllResp,
responseDeserialize: deserialize_cc_arduino_cli_commands_BoardListAllResp,
},
compile: {
path: '/cc.arduino.cli.commands.ArduinoCore/Compile',
requestStream: false,
responseStream: true,
requestType: commands_compile_pb.CompileReq,
responseType: commands_compile_pb.CompileResp,
requestSerialize: serialize_cc_arduino_cli_commands_CompileReq,
requestDeserialize: deserialize_cc_arduino_cli_commands_CompileReq,
responseSerialize: serialize_cc_arduino_cli_commands_CompileResp,
responseDeserialize: deserialize_cc_arduino_cli_commands_CompileResp,
},
platformInstall: {
path: '/cc.arduino.cli.commands.ArduinoCore/PlatformInstall',
requestStream: false,
responseStream: true,
requestType: commands_core_pb.PlatformInstallReq,
responseType: commands_core_pb.PlatformInstallResp,
requestSerialize: serialize_cc_arduino_cli_commands_PlatformInstallReq,
requestDeserialize: deserialize_cc_arduino_cli_commands_PlatformInstallReq,
responseSerialize: serialize_cc_arduino_cli_commands_PlatformInstallResp,
responseDeserialize: deserialize_cc_arduino_cli_commands_PlatformInstallResp,
},
platformDownload: {
path: '/cc.arduino.cli.commands.ArduinoCore/PlatformDownload',
requestStream: false,
responseStream: true,
requestType: commands_core_pb.PlatformDownloadReq,
responseType: commands_core_pb.PlatformDownloadResp,
requestSerialize: serialize_cc_arduino_cli_commands_PlatformDownloadReq,
requestDeserialize: deserialize_cc_arduino_cli_commands_PlatformDownloadReq,
responseSerialize: serialize_cc_arduino_cli_commands_PlatformDownloadResp,
responseDeserialize: deserialize_cc_arduino_cli_commands_PlatformDownloadResp,
},
platformUninstall: {
path: '/cc.arduino.cli.commands.ArduinoCore/PlatformUninstall',
requestStream: false,
responseStream: true,
requestType: commands_core_pb.PlatformUninstallReq,
responseType: commands_core_pb.PlatformUninstallResp,
requestSerialize: serialize_cc_arduino_cli_commands_PlatformUninstallReq,
requestDeserialize: deserialize_cc_arduino_cli_commands_PlatformUninstallReq,
responseSerialize: serialize_cc_arduino_cli_commands_PlatformUninstallResp,
responseDeserialize: deserialize_cc_arduino_cli_commands_PlatformUninstallResp,
},
platformUpgrade: {
path: '/cc.arduino.cli.commands.ArduinoCore/PlatformUpgrade',
requestStream: false,
responseStream: true,
requestType: commands_core_pb.PlatformUpgradeReq,
responseType: commands_core_pb.PlatformUpgradeResp,
requestSerialize: serialize_cc_arduino_cli_commands_PlatformUpgradeReq,
requestDeserialize: deserialize_cc_arduino_cli_commands_PlatformUpgradeReq,
responseSerialize: serialize_cc_arduino_cli_commands_PlatformUpgradeResp,
responseDeserialize: deserialize_cc_arduino_cli_commands_PlatformUpgradeResp,
},
upload: {
path: '/cc.arduino.cli.commands.ArduinoCore/Upload',
requestStream: false,
responseStream: true,
requestType: commands_upload_pb.UploadReq,
responseType: commands_upload_pb.UploadResp,
requestSerialize: serialize_cc_arduino_cli_commands_UploadReq,
requestDeserialize: deserialize_cc_arduino_cli_commands_UploadReq,
responseSerialize: serialize_cc_arduino_cli_commands_UploadResp,
responseDeserialize: deserialize_cc_arduino_cli_commands_UploadResp,
},
platformSearch: {
path: '/cc.arduino.cli.commands.ArduinoCore/PlatformSearch',
requestStream: false,
responseStream: false,
requestType: commands_core_pb.PlatformSearchReq,
responseType: commands_core_pb.PlatformSearchResp,
requestSerialize: serialize_cc_arduino_cli_commands_PlatformSearchReq,
requestDeserialize: deserialize_cc_arduino_cli_commands_PlatformSearchReq,
responseSerialize: serialize_cc_arduino_cli_commands_PlatformSearchResp,
responseDeserialize: deserialize_cc_arduino_cli_commands_PlatformSearchResp,
},
platformList: {
path: '/cc.arduino.cli.commands.ArduinoCore/PlatformList',
requestStream: false,
responseStream: false,
requestType: commands_core_pb.PlatformListReq,
responseType: commands_core_pb.PlatformListResp,
requestSerialize: serialize_cc_arduino_cli_commands_PlatformListReq,
requestDeserialize: deserialize_cc_arduino_cli_commands_PlatformListReq,
responseSerialize: serialize_cc_arduino_cli_commands_PlatformListResp,
responseDeserialize: deserialize_cc_arduino_cli_commands_PlatformListResp,
},
libraryDownload: {
path: '/cc.arduino.cli.commands.ArduinoCore/LibraryDownload',
requestStream: false,
responseStream: true,
requestType: commands_lib_pb.LibraryDownloadReq,
responseType: commands_lib_pb.LibraryDownloadResp,
requestSerialize: serialize_cc_arduino_cli_commands_LibraryDownloadReq,
requestDeserialize: deserialize_cc_arduino_cli_commands_LibraryDownloadReq,
responseSerialize: serialize_cc_arduino_cli_commands_LibraryDownloadResp,
responseDeserialize: deserialize_cc_arduino_cli_commands_LibraryDownloadResp,
},
libraryInstall: {
path: '/cc.arduino.cli.commands.ArduinoCore/LibraryInstall',
requestStream: false,
responseStream: true,
requestType: commands_lib_pb.LibraryInstallReq,
responseType: commands_lib_pb.LibraryInstallResp,
requestSerialize: serialize_cc_arduino_cli_commands_LibraryInstallReq,
requestDeserialize: deserialize_cc_arduino_cli_commands_LibraryInstallReq,
responseSerialize: serialize_cc_arduino_cli_commands_LibraryInstallResp,
responseDeserialize: deserialize_cc_arduino_cli_commands_LibraryInstallResp,
},
libraryUninstall: {
path: '/cc.arduino.cli.commands.ArduinoCore/LibraryUninstall',
requestStream: false,
responseStream: true,
requestType: commands_lib_pb.LibraryUninstallReq,
responseType: commands_lib_pb.LibraryUninstallResp,
requestSerialize: serialize_cc_arduino_cli_commands_LibraryUninstallReq,
requestDeserialize: deserialize_cc_arduino_cli_commands_LibraryUninstallReq,
responseSerialize: serialize_cc_arduino_cli_commands_LibraryUninstallResp,
responseDeserialize: deserialize_cc_arduino_cli_commands_LibraryUninstallResp,
},
libraryUpgradeAll: {
path: '/cc.arduino.cli.commands.ArduinoCore/LibraryUpgradeAll',
requestStream: false,
responseStream: true,
requestType: commands_lib_pb.LibraryUpgradeAllReq,
responseType: commands_lib_pb.LibraryUpgradeAllResp,
requestSerialize: serialize_cc_arduino_cli_commands_LibraryUpgradeAllReq,
requestDeserialize: deserialize_cc_arduino_cli_commands_LibraryUpgradeAllReq,
responseSerialize: serialize_cc_arduino_cli_commands_LibraryUpgradeAllResp,
responseDeserialize: deserialize_cc_arduino_cli_commands_LibraryUpgradeAllResp,
},
librarySearch: {
path: '/cc.arduino.cli.commands.ArduinoCore/LibrarySearch',
requestStream: false,
responseStream: false,
requestType: commands_lib_pb.LibrarySearchReq,
responseType: commands_lib_pb.LibrarySearchResp,
requestSerialize: serialize_cc_arduino_cli_commands_LibrarySearchReq,
requestDeserialize: deserialize_cc_arduino_cli_commands_LibrarySearchReq,
responseSerialize: serialize_cc_arduino_cli_commands_LibrarySearchResp,
responseDeserialize: deserialize_cc_arduino_cli_commands_LibrarySearchResp,
},
libraryList: {
path: '/cc.arduino.cli.commands.ArduinoCore/LibraryList',
requestStream: false,
responseStream: false,
requestType: commands_lib_pb.LibraryListReq,
responseType: commands_lib_pb.LibraryListResp,
requestSerialize: serialize_cc_arduino_cli_commands_LibraryListReq,
requestDeserialize: deserialize_cc_arduino_cli_commands_LibraryListReq,
responseSerialize: serialize_cc_arduino_cli_commands_LibraryListResp,
responseDeserialize: deserialize_cc_arduino_cli_commands_LibraryListResp,
},
};
exports.ArduinoCoreClient = grpc.makeGenericClientConstructor(ArduinoCoreService);
// BOOTSTRAP COMMANDS
// -------------------

View File

@ -1,15 +1,15 @@
// package: arduino
// file: commands.proto
// package: cc.arduino.cli.commands
// file: commands/commands.proto
/* tslint:disable */
import * as jspb from "google-protobuf";
import * as common_pb from "./common_pb";
import * as board_pb from "./board_pb";
import * as compile_pb from "./compile_pb";
import * as core_pb from "./core_pb";
import * as upload_pb from "./upload_pb";
import * as lib_pb from "./lib_pb";
import * as commands_common_pb from "../commands/common_pb";
import * as commands_board_pb from "../commands/board_pb";
import * as commands_compile_pb from "../commands/compile_pb";
import * as commands_core_pb from "../commands/core_pb";
import * as commands_upload_pb from "../commands/upload_pb";
import * as commands_lib_pb from "../commands/lib_pb";
export class Configuration extends jspb.Message {
getDatadir(): string;
@ -78,8 +78,8 @@ export class InitResp extends jspb.Message {
hasInstance(): boolean;
clearInstance(): void;
getInstance(): common_pb.Instance | undefined;
setInstance(value?: common_pb.Instance): void;
getInstance(): commands_common_pb.Instance | undefined;
setInstance(value?: commands_common_pb.Instance): void;
clearPlatformsIndexErrorsList(): void;
getPlatformsIndexErrorsList(): Array<string>;
@ -90,6 +90,18 @@ export class InitResp extends jspb.Message {
setLibrariesIndexError(value: string): void;
hasDownloadProgress(): boolean;
clearDownloadProgress(): void;
getDownloadProgress(): commands_common_pb.DownloadProgress | undefined;
setDownloadProgress(value?: commands_common_pb.DownloadProgress): void;
hasTaskProgress(): boolean;
clearTaskProgress(): void;
getTaskProgress(): commands_common_pb.TaskProgress | undefined;
setTaskProgress(value?: commands_common_pb.TaskProgress): void;
serializeBinary(): Uint8Array;
toObject(includeInstance?: boolean): InitResp.AsObject;
static toObject(includeInstance: boolean, msg: InitResp): InitResp.AsObject;
@ -102,9 +114,11 @@ export class InitResp extends jspb.Message {
export namespace InitResp {
export type AsObject = {
instance?: common_pb.Instance.AsObject,
instance?: commands_common_pb.Instance.AsObject,
platformsIndexErrorsList: Array<string>,
librariesIndexError: string,
downloadProgress?: commands_common_pb.DownloadProgress.AsObject,
taskProgress?: commands_common_pb.TaskProgress.AsObject,
}
}
@ -112,8 +126,8 @@ export class DestroyReq extends jspb.Message {
hasInstance(): boolean;
clearInstance(): void;
getInstance(): common_pb.Instance | undefined;
setInstance(value?: common_pb.Instance): void;
getInstance(): commands_common_pb.Instance | undefined;
setInstance(value?: commands_common_pb.Instance): void;
serializeBinary(): Uint8Array;
@ -128,7 +142,7 @@ export class DestroyReq extends jspb.Message {
export namespace DestroyReq {
export type AsObject = {
instance?: common_pb.Instance.AsObject,
instance?: commands_common_pb.Instance.AsObject,
}
}
@ -153,8 +167,8 @@ export class RescanReq extends jspb.Message {
hasInstance(): boolean;
clearInstance(): void;
getInstance(): common_pb.Instance | undefined;
setInstance(value?: common_pb.Instance): void;
getInstance(): commands_common_pb.Instance | undefined;
setInstance(value?: commands_common_pb.Instance): void;
serializeBinary(): Uint8Array;
@ -169,7 +183,7 @@ export class RescanReq extends jspb.Message {
export namespace RescanReq {
export type AsObject = {
instance?: common_pb.Instance.AsObject,
instance?: commands_common_pb.Instance.AsObject,
}
}
@ -204,8 +218,8 @@ export class UpdateIndexReq extends jspb.Message {
hasInstance(): boolean;
clearInstance(): void;
getInstance(): common_pb.Instance | undefined;
setInstance(value?: common_pb.Instance): void;
getInstance(): commands_common_pb.Instance | undefined;
setInstance(value?: commands_common_pb.Instance): void;
serializeBinary(): Uint8Array;
@ -220,7 +234,7 @@ export class UpdateIndexReq extends jspb.Message {
export namespace UpdateIndexReq {
export type AsObject = {
instance?: common_pb.Instance.AsObject,
instance?: commands_common_pb.Instance.AsObject,
}
}
@ -228,8 +242,8 @@ export class UpdateIndexResp extends jspb.Message {
hasDownloadProgress(): boolean;
clearDownloadProgress(): void;
getDownloadProgress(): common_pb.DownloadProgress | undefined;
setDownloadProgress(value?: common_pb.DownloadProgress): void;
getDownloadProgress(): commands_common_pb.DownloadProgress | undefined;
setDownloadProgress(value?: commands_common_pb.DownloadProgress): void;
serializeBinary(): Uint8Array;
@ -244,6 +258,92 @@ export class UpdateIndexResp extends jspb.Message {
export namespace UpdateIndexResp {
export type AsObject = {
downloadProgress?: common_pb.DownloadProgress.AsObject,
downloadProgress?: commands_common_pb.DownloadProgress.AsObject,
}
}
export class UpdateLibrariesIndexReq extends jspb.Message {
hasInstance(): boolean;
clearInstance(): void;
getInstance(): commands_common_pb.Instance | undefined;
setInstance(value?: commands_common_pb.Instance): void;
serializeBinary(): Uint8Array;
toObject(includeInstance?: boolean): UpdateLibrariesIndexReq.AsObject;
static toObject(includeInstance: boolean, msg: UpdateLibrariesIndexReq): UpdateLibrariesIndexReq.AsObject;
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
static serializeBinaryToWriter(message: UpdateLibrariesIndexReq, writer: jspb.BinaryWriter): void;
static deserializeBinary(bytes: Uint8Array): UpdateLibrariesIndexReq;
static deserializeBinaryFromReader(message: UpdateLibrariesIndexReq, reader: jspb.BinaryReader): UpdateLibrariesIndexReq;
}
export namespace UpdateLibrariesIndexReq {
export type AsObject = {
instance?: commands_common_pb.Instance.AsObject,
}
}
export class UpdateLibrariesIndexResp extends jspb.Message {
hasDownloadProgress(): boolean;
clearDownloadProgress(): void;
getDownloadProgress(): commands_common_pb.DownloadProgress | undefined;
setDownloadProgress(value?: commands_common_pb.DownloadProgress): void;
serializeBinary(): Uint8Array;
toObject(includeInstance?: boolean): UpdateLibrariesIndexResp.AsObject;
static toObject(includeInstance: boolean, msg: UpdateLibrariesIndexResp): UpdateLibrariesIndexResp.AsObject;
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
static serializeBinaryToWriter(message: UpdateLibrariesIndexResp, writer: jspb.BinaryWriter): void;
static deserializeBinary(bytes: Uint8Array): UpdateLibrariesIndexResp;
static deserializeBinaryFromReader(message: UpdateLibrariesIndexResp, reader: jspb.BinaryReader): UpdateLibrariesIndexResp;
}
export namespace UpdateLibrariesIndexResp {
export type AsObject = {
downloadProgress?: commands_common_pb.DownloadProgress.AsObject,
}
}
export class VersionReq extends jspb.Message {
serializeBinary(): Uint8Array;
toObject(includeInstance?: boolean): VersionReq.AsObject;
static toObject(includeInstance: boolean, msg: VersionReq): VersionReq.AsObject;
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
static serializeBinaryToWriter(message: VersionReq, writer: jspb.BinaryWriter): void;
static deserializeBinary(bytes: Uint8Array): VersionReq;
static deserializeBinaryFromReader(message: VersionReq, reader: jspb.BinaryReader): VersionReq;
}
export namespace VersionReq {
export type AsObject = {
}
}
export class VersionResp extends jspb.Message {
getVersion(): string;
setVersion(value: string): void;
serializeBinary(): Uint8Array;
toObject(includeInstance?: boolean): VersionResp.AsObject;
static toObject(includeInstance: boolean, msg: VersionResp): VersionResp.AsObject;
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
static serializeBinaryToWriter(message: VersionResp, writer: jspb.BinaryWriter): void;
static deserializeBinary(bytes: Uint8Array): VersionResp;
static deserializeBinaryFromReader(message: VersionResp, reader: jspb.BinaryReader): VersionResp;
}
export namespace VersionResp {
export type AsObject = {
version: string,
}
}

File diff suppressed because it is too large Load Diff

View File

@ -1,5 +1,5 @@
// package: arduino
// file: common.proto
// package: cc.arduino.cli.commands
// file: commands/common.proto
/* tslint:disable */

View File

@ -11,9 +11,9 @@ var jspb = require('google-protobuf');
var goog = jspb;
var global = Function('return this')();
goog.exportSymbol('proto.arduino.DownloadProgress', null, global);
goog.exportSymbol('proto.arduino.Instance', null, global);
goog.exportSymbol('proto.arduino.TaskProgress', null, global);
goog.exportSymbol('proto.cc.arduino.cli.commands.DownloadProgress', null, global);
goog.exportSymbol('proto.cc.arduino.cli.commands.Instance', null, global);
goog.exportSymbol('proto.cc.arduino.cli.commands.TaskProgress', null, global);
/**
* Generated by JsPbCodeGenerator.
@ -25,12 +25,12 @@ goog.exportSymbol('proto.arduino.TaskProgress', null, global);
* @extends {jspb.Message}
* @constructor
*/
proto.arduino.Instance = function(opt_data) {
proto.cc.arduino.cli.commands.Instance = function(opt_data) {
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
};
goog.inherits(proto.arduino.Instance, jspb.Message);
goog.inherits(proto.cc.arduino.cli.commands.Instance, jspb.Message);
if (goog.DEBUG && !COMPILED) {
proto.arduino.Instance.displayName = 'proto.arduino.Instance';
proto.cc.arduino.cli.commands.Instance.displayName = 'proto.cc.arduino.cli.commands.Instance';
}
@ -45,8 +45,8 @@ if (jspb.Message.GENERATE_TO_OBJECT) {
* for transitional soy proto support: http://goto/soy-param-migration
* @return {!Object}
*/
proto.arduino.Instance.prototype.toObject = function(opt_includeInstance) {
return proto.arduino.Instance.toObject(opt_includeInstance, this);
proto.cc.arduino.cli.commands.Instance.prototype.toObject = function(opt_includeInstance) {
return proto.cc.arduino.cli.commands.Instance.toObject(opt_includeInstance, this);
};
@ -55,11 +55,11 @@ proto.arduino.Instance.prototype.toObject = function(opt_includeInstance) {
* @param {boolean|undefined} includeInstance Whether to include the JSPB
* instance for transitional soy proto support:
* http://goto/soy-param-migration
* @param {!proto.arduino.Instance} msg The msg instance to transform.
* @param {!proto.cc.arduino.cli.commands.Instance} msg The msg instance to transform.
* @return {!Object}
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.arduino.Instance.toObject = function(includeInstance, msg) {
proto.cc.arduino.cli.commands.Instance.toObject = function(includeInstance, msg) {
var f, obj = {
id: jspb.Message.getFieldWithDefault(msg, 1, 0)
};
@ -75,23 +75,23 @@ proto.arduino.Instance.toObject = function(includeInstance, msg) {
/**
* Deserializes binary data (in protobuf wire format).
* @param {jspb.ByteSource} bytes The bytes to deserialize.
* @return {!proto.arduino.Instance}
* @return {!proto.cc.arduino.cli.commands.Instance}
*/
proto.arduino.Instance.deserializeBinary = function(bytes) {
proto.cc.arduino.cli.commands.Instance.deserializeBinary = function(bytes) {
var reader = new jspb.BinaryReader(bytes);
var msg = new proto.arduino.Instance;
return proto.arduino.Instance.deserializeBinaryFromReader(msg, reader);
var msg = new proto.cc.arduino.cli.commands.Instance;
return proto.cc.arduino.cli.commands.Instance.deserializeBinaryFromReader(msg, reader);
};
/**
* Deserializes binary data (in protobuf wire format) from the
* given reader into the given message object.
* @param {!proto.arduino.Instance} msg The message object to deserialize into.
* @param {!proto.cc.arduino.cli.commands.Instance} msg The message object to deserialize into.
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
* @return {!proto.arduino.Instance}
* @return {!proto.cc.arduino.cli.commands.Instance}
*/
proto.arduino.Instance.deserializeBinaryFromReader = function(msg, reader) {
proto.cc.arduino.cli.commands.Instance.deserializeBinaryFromReader = function(msg, reader) {
while (reader.nextField()) {
if (reader.isEndGroup()) {
break;
@ -115,9 +115,9 @@ proto.arduino.Instance.deserializeBinaryFromReader = function(msg, reader) {
* Serializes the message to binary data (in protobuf wire format).
* @return {!Uint8Array}
*/
proto.arduino.Instance.prototype.serializeBinary = function() {
proto.cc.arduino.cli.commands.Instance.prototype.serializeBinary = function() {
var writer = new jspb.BinaryWriter();
proto.arduino.Instance.serializeBinaryToWriter(this, writer);
proto.cc.arduino.cli.commands.Instance.serializeBinaryToWriter(this, writer);
return writer.getResultBuffer();
};
@ -125,11 +125,11 @@ proto.arduino.Instance.prototype.serializeBinary = function() {
/**
* Serializes the given message to binary data (in protobuf wire
* format), writing to the given BinaryWriter.
* @param {!proto.arduino.Instance} message
* @param {!proto.cc.arduino.cli.commands.Instance} message
* @param {!jspb.BinaryWriter} writer
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.arduino.Instance.serializeBinaryToWriter = function(message, writer) {
proto.cc.arduino.cli.commands.Instance.serializeBinaryToWriter = function(message, writer) {
var f = undefined;
f = message.getId();
if (f !== 0) {
@ -145,13 +145,13 @@ proto.arduino.Instance.serializeBinaryToWriter = function(message, writer) {
* optional int32 id = 1;
* @return {number}
*/
proto.arduino.Instance.prototype.getId = function() {
proto.cc.arduino.cli.commands.Instance.prototype.getId = function() {
return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 1, 0));
};
/** @param {number} value */
proto.arduino.Instance.prototype.setId = function(value) {
proto.cc.arduino.cli.commands.Instance.prototype.setId = function(value) {
jspb.Message.setProto3IntField(this, 1, value);
};
@ -167,12 +167,12 @@ proto.arduino.Instance.prototype.setId = function(value) {
* @extends {jspb.Message}
* @constructor
*/
proto.arduino.DownloadProgress = function(opt_data) {
proto.cc.arduino.cli.commands.DownloadProgress = function(opt_data) {
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
};
goog.inherits(proto.arduino.DownloadProgress, jspb.Message);
goog.inherits(proto.cc.arduino.cli.commands.DownloadProgress, jspb.Message);
if (goog.DEBUG && !COMPILED) {
proto.arduino.DownloadProgress.displayName = 'proto.arduino.DownloadProgress';
proto.cc.arduino.cli.commands.DownloadProgress.displayName = 'proto.cc.arduino.cli.commands.DownloadProgress';
}
@ -187,8 +187,8 @@ if (jspb.Message.GENERATE_TO_OBJECT) {
* for transitional soy proto support: http://goto/soy-param-migration
* @return {!Object}
*/
proto.arduino.DownloadProgress.prototype.toObject = function(opt_includeInstance) {
return proto.arduino.DownloadProgress.toObject(opt_includeInstance, this);
proto.cc.arduino.cli.commands.DownloadProgress.prototype.toObject = function(opt_includeInstance) {
return proto.cc.arduino.cli.commands.DownloadProgress.toObject(opt_includeInstance, this);
};
@ -197,11 +197,11 @@ proto.arduino.DownloadProgress.prototype.toObject = function(opt_includeInstance
* @param {boolean|undefined} includeInstance Whether to include the JSPB
* instance for transitional soy proto support:
* http://goto/soy-param-migration
* @param {!proto.arduino.DownloadProgress} msg The msg instance to transform.
* @param {!proto.cc.arduino.cli.commands.DownloadProgress} msg The msg instance to transform.
* @return {!Object}
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.arduino.DownloadProgress.toObject = function(includeInstance, msg) {
proto.cc.arduino.cli.commands.DownloadProgress.toObject = function(includeInstance, msg) {
var f, obj = {
url: jspb.Message.getFieldWithDefault(msg, 1, ""),
file: jspb.Message.getFieldWithDefault(msg, 2, ""),
@ -221,23 +221,23 @@ proto.arduino.DownloadProgress.toObject = function(includeInstance, msg) {
/**
* Deserializes binary data (in protobuf wire format).
* @param {jspb.ByteSource} bytes The bytes to deserialize.
* @return {!proto.arduino.DownloadProgress}
* @return {!proto.cc.arduino.cli.commands.DownloadProgress}
*/
proto.arduino.DownloadProgress.deserializeBinary = function(bytes) {
proto.cc.arduino.cli.commands.DownloadProgress.deserializeBinary = function(bytes) {
var reader = new jspb.BinaryReader(bytes);
var msg = new proto.arduino.DownloadProgress;
return proto.arduino.DownloadProgress.deserializeBinaryFromReader(msg, reader);
var msg = new proto.cc.arduino.cli.commands.DownloadProgress;
return proto.cc.arduino.cli.commands.DownloadProgress.deserializeBinaryFromReader(msg, reader);
};
/**
* Deserializes binary data (in protobuf wire format) from the
* given reader into the given message object.
* @param {!proto.arduino.DownloadProgress} msg The message object to deserialize into.
* @param {!proto.cc.arduino.cli.commands.DownloadProgress} msg The message object to deserialize into.
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
* @return {!proto.arduino.DownloadProgress}
* @return {!proto.cc.arduino.cli.commands.DownloadProgress}
*/
proto.arduino.DownloadProgress.deserializeBinaryFromReader = function(msg, reader) {
proto.cc.arduino.cli.commands.DownloadProgress.deserializeBinaryFromReader = function(msg, reader) {
while (reader.nextField()) {
if (reader.isEndGroup()) {
break;
@ -277,9 +277,9 @@ proto.arduino.DownloadProgress.deserializeBinaryFromReader = function(msg, reade
* Serializes the message to binary data (in protobuf wire format).
* @return {!Uint8Array}
*/
proto.arduino.DownloadProgress.prototype.serializeBinary = function() {
proto.cc.arduino.cli.commands.DownloadProgress.prototype.serializeBinary = function() {
var writer = new jspb.BinaryWriter();
proto.arduino.DownloadProgress.serializeBinaryToWriter(this, writer);
proto.cc.arduino.cli.commands.DownloadProgress.serializeBinaryToWriter(this, writer);
return writer.getResultBuffer();
};
@ -287,11 +287,11 @@ proto.arduino.DownloadProgress.prototype.serializeBinary = function() {
/**
* Serializes the given message to binary data (in protobuf wire
* format), writing to the given BinaryWriter.
* @param {!proto.arduino.DownloadProgress} message
* @param {!proto.cc.arduino.cli.commands.DownloadProgress} message
* @param {!jspb.BinaryWriter} writer
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.arduino.DownloadProgress.serializeBinaryToWriter = function(message, writer) {
proto.cc.arduino.cli.commands.DownloadProgress.serializeBinaryToWriter = function(message, writer) {
var f = undefined;
f = message.getUrl();
if (f.length > 0) {
@ -335,13 +335,13 @@ proto.arduino.DownloadProgress.serializeBinaryToWriter = function(message, write
* optional string url = 1;
* @return {string}
*/
proto.arduino.DownloadProgress.prototype.getUrl = function() {
proto.cc.arduino.cli.commands.DownloadProgress.prototype.getUrl = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
};
/** @param {string} value */
proto.arduino.DownloadProgress.prototype.setUrl = function(value) {
proto.cc.arduino.cli.commands.DownloadProgress.prototype.setUrl = function(value) {
jspb.Message.setProto3StringField(this, 1, value);
};
@ -350,13 +350,13 @@ proto.arduino.DownloadProgress.prototype.setUrl = function(value) {
* optional string file = 2;
* @return {string}
*/
proto.arduino.DownloadProgress.prototype.getFile = function() {
proto.cc.arduino.cli.commands.DownloadProgress.prototype.getFile = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
};
/** @param {string} value */
proto.arduino.DownloadProgress.prototype.setFile = function(value) {
proto.cc.arduino.cli.commands.DownloadProgress.prototype.setFile = function(value) {
jspb.Message.setProto3StringField(this, 2, value);
};
@ -365,13 +365,13 @@ proto.arduino.DownloadProgress.prototype.setFile = function(value) {
* optional int64 total_size = 3;
* @return {number}
*/
proto.arduino.DownloadProgress.prototype.getTotalSize = function() {
proto.cc.arduino.cli.commands.DownloadProgress.prototype.getTotalSize = function() {
return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 3, 0));
};
/** @param {number} value */
proto.arduino.DownloadProgress.prototype.setTotalSize = function(value) {
proto.cc.arduino.cli.commands.DownloadProgress.prototype.setTotalSize = function(value) {
jspb.Message.setProto3IntField(this, 3, value);
};
@ -380,13 +380,13 @@ proto.arduino.DownloadProgress.prototype.setTotalSize = function(value) {
* optional int64 downloaded = 4;
* @return {number}
*/
proto.arduino.DownloadProgress.prototype.getDownloaded = function() {
proto.cc.arduino.cli.commands.DownloadProgress.prototype.getDownloaded = function() {
return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 4, 0));
};
/** @param {number} value */
proto.arduino.DownloadProgress.prototype.setDownloaded = function(value) {
proto.cc.arduino.cli.commands.DownloadProgress.prototype.setDownloaded = function(value) {
jspb.Message.setProto3IntField(this, 4, value);
};
@ -397,13 +397,13 @@ proto.arduino.DownloadProgress.prototype.setDownloaded = function(value) {
* You should avoid comparisons like {@code val === true/false} in those cases.
* @return {boolean}
*/
proto.arduino.DownloadProgress.prototype.getCompleted = function() {
proto.cc.arduino.cli.commands.DownloadProgress.prototype.getCompleted = function() {
return /** @type {boolean} */ (jspb.Message.getFieldWithDefault(this, 5, false));
};
/** @param {boolean} value */
proto.arduino.DownloadProgress.prototype.setCompleted = function(value) {
proto.cc.arduino.cli.commands.DownloadProgress.prototype.setCompleted = function(value) {
jspb.Message.setProto3BooleanField(this, 5, value);
};
@ -419,12 +419,12 @@ proto.arduino.DownloadProgress.prototype.setCompleted = function(value) {
* @extends {jspb.Message}
* @constructor
*/
proto.arduino.TaskProgress = function(opt_data) {
proto.cc.arduino.cli.commands.TaskProgress = function(opt_data) {
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
};
goog.inherits(proto.arduino.TaskProgress, jspb.Message);
goog.inherits(proto.cc.arduino.cli.commands.TaskProgress, jspb.Message);
if (goog.DEBUG && !COMPILED) {
proto.arduino.TaskProgress.displayName = 'proto.arduino.TaskProgress';
proto.cc.arduino.cli.commands.TaskProgress.displayName = 'proto.cc.arduino.cli.commands.TaskProgress';
}
@ -439,8 +439,8 @@ if (jspb.Message.GENERATE_TO_OBJECT) {
* for transitional soy proto support: http://goto/soy-param-migration
* @return {!Object}
*/
proto.arduino.TaskProgress.prototype.toObject = function(opt_includeInstance) {
return proto.arduino.TaskProgress.toObject(opt_includeInstance, this);
proto.cc.arduino.cli.commands.TaskProgress.prototype.toObject = function(opt_includeInstance) {
return proto.cc.arduino.cli.commands.TaskProgress.toObject(opt_includeInstance, this);
};
@ -449,11 +449,11 @@ proto.arduino.TaskProgress.prototype.toObject = function(opt_includeInstance) {
* @param {boolean|undefined} includeInstance Whether to include the JSPB
* instance for transitional soy proto support:
* http://goto/soy-param-migration
* @param {!proto.arduino.TaskProgress} msg The msg instance to transform.
* @param {!proto.cc.arduino.cli.commands.TaskProgress} msg The msg instance to transform.
* @return {!Object}
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.arduino.TaskProgress.toObject = function(includeInstance, msg) {
proto.cc.arduino.cli.commands.TaskProgress.toObject = function(includeInstance, msg) {
var f, obj = {
name: jspb.Message.getFieldWithDefault(msg, 1, ""),
message: jspb.Message.getFieldWithDefault(msg, 2, ""),
@ -471,23 +471,23 @@ proto.arduino.TaskProgress.toObject = function(includeInstance, msg) {
/**
* Deserializes binary data (in protobuf wire format).
* @param {jspb.ByteSource} bytes The bytes to deserialize.
* @return {!proto.arduino.TaskProgress}
* @return {!proto.cc.arduino.cli.commands.TaskProgress}
*/
proto.arduino.TaskProgress.deserializeBinary = function(bytes) {
proto.cc.arduino.cli.commands.TaskProgress.deserializeBinary = function(bytes) {
var reader = new jspb.BinaryReader(bytes);
var msg = new proto.arduino.TaskProgress;
return proto.arduino.TaskProgress.deserializeBinaryFromReader(msg, reader);
var msg = new proto.cc.arduino.cli.commands.TaskProgress;
return proto.cc.arduino.cli.commands.TaskProgress.deserializeBinaryFromReader(msg, reader);
};
/**
* Deserializes binary data (in protobuf wire format) from the
* given reader into the given message object.
* @param {!proto.arduino.TaskProgress} msg The message object to deserialize into.
* @param {!proto.cc.arduino.cli.commands.TaskProgress} msg The message object to deserialize into.
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
* @return {!proto.arduino.TaskProgress}
* @return {!proto.cc.arduino.cli.commands.TaskProgress}
*/
proto.arduino.TaskProgress.deserializeBinaryFromReader = function(msg, reader) {
proto.cc.arduino.cli.commands.TaskProgress.deserializeBinaryFromReader = function(msg, reader) {
while (reader.nextField()) {
if (reader.isEndGroup()) {
break;
@ -519,9 +519,9 @@ proto.arduino.TaskProgress.deserializeBinaryFromReader = function(msg, reader) {
* Serializes the message to binary data (in protobuf wire format).
* @return {!Uint8Array}
*/
proto.arduino.TaskProgress.prototype.serializeBinary = function() {
proto.cc.arduino.cli.commands.TaskProgress.prototype.serializeBinary = function() {
var writer = new jspb.BinaryWriter();
proto.arduino.TaskProgress.serializeBinaryToWriter(this, writer);
proto.cc.arduino.cli.commands.TaskProgress.serializeBinaryToWriter(this, writer);
return writer.getResultBuffer();
};
@ -529,11 +529,11 @@ proto.arduino.TaskProgress.prototype.serializeBinary = function() {
/**
* Serializes the given message to binary data (in protobuf wire
* format), writing to the given BinaryWriter.
* @param {!proto.arduino.TaskProgress} message
* @param {!proto.cc.arduino.cli.commands.TaskProgress} message
* @param {!jspb.BinaryWriter} writer
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.arduino.TaskProgress.serializeBinaryToWriter = function(message, writer) {
proto.cc.arduino.cli.commands.TaskProgress.serializeBinaryToWriter = function(message, writer) {
var f = undefined;
f = message.getName();
if (f.length > 0) {
@ -563,13 +563,13 @@ proto.arduino.TaskProgress.serializeBinaryToWriter = function(message, writer) {
* optional string name = 1;
* @return {string}
*/
proto.arduino.TaskProgress.prototype.getName = function() {
proto.cc.arduino.cli.commands.TaskProgress.prototype.getName = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
};
/** @param {string} value */
proto.arduino.TaskProgress.prototype.setName = function(value) {
proto.cc.arduino.cli.commands.TaskProgress.prototype.setName = function(value) {
jspb.Message.setProto3StringField(this, 1, value);
};
@ -578,13 +578,13 @@ proto.arduino.TaskProgress.prototype.setName = function(value) {
* optional string message = 2;
* @return {string}
*/
proto.arduino.TaskProgress.prototype.getMessage = function() {
proto.cc.arduino.cli.commands.TaskProgress.prototype.getMessage = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
};
/** @param {string} value */
proto.arduino.TaskProgress.prototype.setMessage = function(value) {
proto.cc.arduino.cli.commands.TaskProgress.prototype.setMessage = function(value) {
jspb.Message.setProto3StringField(this, 2, value);
};
@ -595,15 +595,15 @@ proto.arduino.TaskProgress.prototype.setMessage = function(value) {
* You should avoid comparisons like {@code val === true/false} in those cases.
* @return {boolean}
*/
proto.arduino.TaskProgress.prototype.getCompleted = function() {
proto.cc.arduino.cli.commands.TaskProgress.prototype.getCompleted = function() {
return /** @type {boolean} */ (jspb.Message.getFieldWithDefault(this, 3, false));
};
/** @param {boolean} value */
proto.arduino.TaskProgress.prototype.setCompleted = function(value) {
proto.cc.arduino.cli.commands.TaskProgress.prototype.setCompleted = function(value) {
jspb.Message.setProto3BooleanField(this, 3, value);
};
goog.object.extend(exports, proto.arduino);
goog.object.extend(exports, proto.cc.arduino.cli.commands);

View File

@ -1,17 +1,17 @@
// package: arduino
// file: compile.proto
// package: cc.arduino.cli.commands
// file: commands/compile.proto
/* tslint:disable */
import * as jspb from "google-protobuf";
import * as common_pb from "./common_pb";
import * as commands_common_pb from "../commands/common_pb";
export class CompileReq extends jspb.Message {
hasInstance(): boolean;
clearInstance(): void;
getInstance(): common_pb.Instance | undefined;
setInstance(value?: common_pb.Instance): void;
getInstance(): commands_common_pb.Instance | undefined;
setInstance(value?: commands_common_pb.Instance): void;
getFqbn(): string;
setFqbn(value: string): void;
@ -64,7 +64,7 @@ export class CompileReq extends jspb.Message {
export namespace CompileReq {
export type AsObject = {
instance?: common_pb.Instance.AsObject,
instance?: commands_common_pb.Instance.AsObject,
fqbn: string,
sketchpath: string,
showproperties: boolean,
@ -92,18 +92,6 @@ export class CompileResp extends jspb.Message {
setErrStream(value: Uint8Array | string): void;
hasDownloadProgress(): boolean;
clearDownloadProgress(): void;
getDownloadProgress(): common_pb.DownloadProgress | undefined;
setDownloadProgress(value?: common_pb.DownloadProgress): void;
hasTaskProgress(): boolean;
clearTaskProgress(): void;
getTaskProgress(): common_pb.TaskProgress | undefined;
setTaskProgress(value?: common_pb.TaskProgress): void;
serializeBinary(): Uint8Array;
toObject(includeInstance?: boolean): CompileResp.AsObject;
static toObject(includeInstance: boolean, msg: CompileResp): CompileResp.AsObject;
@ -118,7 +106,5 @@ export namespace CompileResp {
export type AsObject = {
outStream: Uint8Array | string,
errStream: Uint8Array | string,
downloadProgress?: common_pb.DownloadProgress.AsObject,
taskProgress?: common_pb.TaskProgress.AsObject,
}
}

View File

@ -11,10 +11,10 @@ var jspb = require('google-protobuf');
var goog = jspb;
var global = Function('return this')();
var common_pb = require('./common_pb.js');
goog.object.extend(proto, common_pb);
goog.exportSymbol('proto.arduino.CompileReq', null, global);
goog.exportSymbol('proto.arduino.CompileResp', null, global);
var commands_common_pb = require('../commands/common_pb.js');
goog.object.extend(proto, commands_common_pb);
goog.exportSymbol('proto.cc.arduino.cli.commands.CompileReq', null, global);
goog.exportSymbol('proto.cc.arduino.cli.commands.CompileResp', null, global);
/**
* Generated by JsPbCodeGenerator.
@ -26,19 +26,19 @@ goog.exportSymbol('proto.arduino.CompileResp', null, global);
* @extends {jspb.Message}
* @constructor
*/
proto.arduino.CompileReq = function(opt_data) {
jspb.Message.initialize(this, opt_data, 0, -1, proto.arduino.CompileReq.repeatedFields_, null);
proto.cc.arduino.cli.commands.CompileReq = function(opt_data) {
jspb.Message.initialize(this, opt_data, 0, -1, proto.cc.arduino.cli.commands.CompileReq.repeatedFields_, null);
};
goog.inherits(proto.arduino.CompileReq, jspb.Message);
goog.inherits(proto.cc.arduino.cli.commands.CompileReq, jspb.Message);
if (goog.DEBUG && !COMPILED) {
proto.arduino.CompileReq.displayName = 'proto.arduino.CompileReq';
proto.cc.arduino.cli.commands.CompileReq.displayName = 'proto.cc.arduino.cli.commands.CompileReq';
}
/**
* List of repeated fields within this message type.
* @private {!Array<number>}
* @const
*/
proto.arduino.CompileReq.repeatedFields_ = [8];
proto.cc.arduino.cli.commands.CompileReq.repeatedFields_ = [8];
@ -53,8 +53,8 @@ if (jspb.Message.GENERATE_TO_OBJECT) {
* for transitional soy proto support: http://goto/soy-param-migration
* @return {!Object}
*/
proto.arduino.CompileReq.prototype.toObject = function(opt_includeInstance) {
return proto.arduino.CompileReq.toObject(opt_includeInstance, this);
proto.cc.arduino.cli.commands.CompileReq.prototype.toObject = function(opt_includeInstance) {
return proto.cc.arduino.cli.commands.CompileReq.toObject(opt_includeInstance, this);
};
@ -63,13 +63,13 @@ proto.arduino.CompileReq.prototype.toObject = function(opt_includeInstance) {
* @param {boolean|undefined} includeInstance Whether to include the JSPB
* instance for transitional soy proto support:
* http://goto/soy-param-migration
* @param {!proto.arduino.CompileReq} msg The msg instance to transform.
* @param {!proto.cc.arduino.cli.commands.CompileReq} msg The msg instance to transform.
* @return {!Object}
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.arduino.CompileReq.toObject = function(includeInstance, msg) {
proto.cc.arduino.cli.commands.CompileReq.toObject = function(includeInstance, msg) {
var f, obj = {
instance: (f = msg.getInstance()) && common_pb.Instance.toObject(includeInstance, f),
instance: (f = msg.getInstance()) && commands_common_pb.Instance.toObject(includeInstance, f),
fqbn: jspb.Message.getFieldWithDefault(msg, 2, ""),
sketchpath: jspb.Message.getFieldWithDefault(msg, 3, ""),
showproperties: jspb.Message.getFieldWithDefault(msg, 4, false),
@ -95,23 +95,23 @@ proto.arduino.CompileReq.toObject = function(includeInstance, msg) {
/**
* Deserializes binary data (in protobuf wire format).
* @param {jspb.ByteSource} bytes The bytes to deserialize.
* @return {!proto.arduino.CompileReq}
* @return {!proto.cc.arduino.cli.commands.CompileReq}
*/
proto.arduino.CompileReq.deserializeBinary = function(bytes) {
proto.cc.arduino.cli.commands.CompileReq.deserializeBinary = function(bytes) {
var reader = new jspb.BinaryReader(bytes);
var msg = new proto.arduino.CompileReq;
return proto.arduino.CompileReq.deserializeBinaryFromReader(msg, reader);
var msg = new proto.cc.arduino.cli.commands.CompileReq;
return proto.cc.arduino.cli.commands.CompileReq.deserializeBinaryFromReader(msg, reader);
};
/**
* Deserializes binary data (in protobuf wire format) from the
* given reader into the given message object.
* @param {!proto.arduino.CompileReq} msg The message object to deserialize into.
* @param {!proto.cc.arduino.cli.commands.CompileReq} msg The message object to deserialize into.
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
* @return {!proto.arduino.CompileReq}
* @return {!proto.cc.arduino.cli.commands.CompileReq}
*/
proto.arduino.CompileReq.deserializeBinaryFromReader = function(msg, reader) {
proto.cc.arduino.cli.commands.CompileReq.deserializeBinaryFromReader = function(msg, reader) {
while (reader.nextField()) {
if (reader.isEndGroup()) {
break;
@ -119,8 +119,8 @@ proto.arduino.CompileReq.deserializeBinaryFromReader = function(msg, reader) {
var field = reader.getFieldNumber();
switch (field) {
case 1:
var value = new common_pb.Instance;
reader.readMessage(value,common_pb.Instance.deserializeBinaryFromReader);
var value = new commands_common_pb.Instance;
reader.readMessage(value,commands_common_pb.Instance.deserializeBinaryFromReader);
msg.setInstance(value);
break;
case 2:
@ -184,9 +184,9 @@ proto.arduino.CompileReq.deserializeBinaryFromReader = function(msg, reader) {
* Serializes the message to binary data (in protobuf wire format).
* @return {!Uint8Array}
*/
proto.arduino.CompileReq.prototype.serializeBinary = function() {
proto.cc.arduino.cli.commands.CompileReq.prototype.serializeBinary = function() {
var writer = new jspb.BinaryWriter();
proto.arduino.CompileReq.serializeBinaryToWriter(this, writer);
proto.cc.arduino.cli.commands.CompileReq.serializeBinaryToWriter(this, writer);
return writer.getResultBuffer();
};
@ -194,18 +194,18 @@ proto.arduino.CompileReq.prototype.serializeBinary = function() {
/**
* Serializes the given message to binary data (in protobuf wire
* format), writing to the given BinaryWriter.
* @param {!proto.arduino.CompileReq} message
* @param {!proto.cc.arduino.cli.commands.CompileReq} message
* @param {!jspb.BinaryWriter} writer
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.arduino.CompileReq.serializeBinaryToWriter = function(message, writer) {
proto.cc.arduino.cli.commands.CompileReq.serializeBinaryToWriter = function(message, writer) {
var f = undefined;
f = message.getInstance();
if (f != null) {
writer.writeMessage(
1,
f,
common_pb.Instance.serializeBinaryToWriter
commands_common_pb.Instance.serializeBinaryToWriter
);
}
f = message.getFqbn();
@ -297,21 +297,21 @@ proto.arduino.CompileReq.serializeBinaryToWriter = function(message, writer) {
/**
* optional Instance instance = 1;
* @return {?proto.arduino.Instance}
* @return {?proto.cc.arduino.cli.commands.Instance}
*/
proto.arduino.CompileReq.prototype.getInstance = function() {
return /** @type{?proto.arduino.Instance} */ (
jspb.Message.getWrapperField(this, common_pb.Instance, 1));
proto.cc.arduino.cli.commands.CompileReq.prototype.getInstance = function() {
return /** @type{?proto.cc.arduino.cli.commands.Instance} */ (
jspb.Message.getWrapperField(this, commands_common_pb.Instance, 1));
};
/** @param {?proto.arduino.Instance|undefined} value */
proto.arduino.CompileReq.prototype.setInstance = function(value) {
/** @param {?proto.cc.arduino.cli.commands.Instance|undefined} value */
proto.cc.arduino.cli.commands.CompileReq.prototype.setInstance = function(value) {
jspb.Message.setWrapperField(this, 1, value);
};
proto.arduino.CompileReq.prototype.clearInstance = function() {
proto.cc.arduino.cli.commands.CompileReq.prototype.clearInstance = function() {
this.setInstance(undefined);
};
@ -320,7 +320,7 @@ proto.arduino.CompileReq.prototype.clearInstance = function() {
* Returns whether this field is set.
* @return {boolean}
*/
proto.arduino.CompileReq.prototype.hasInstance = function() {
proto.cc.arduino.cli.commands.CompileReq.prototype.hasInstance = function() {
return jspb.Message.getField(this, 1) != null;
};
@ -329,13 +329,13 @@ proto.arduino.CompileReq.prototype.hasInstance = function() {
* optional string fqbn = 2;
* @return {string}
*/
proto.arduino.CompileReq.prototype.getFqbn = function() {
proto.cc.arduino.cli.commands.CompileReq.prototype.getFqbn = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
};
/** @param {string} value */
proto.arduino.CompileReq.prototype.setFqbn = function(value) {
proto.cc.arduino.cli.commands.CompileReq.prototype.setFqbn = function(value) {
jspb.Message.setProto3StringField(this, 2, value);
};
@ -344,13 +344,13 @@ proto.arduino.CompileReq.prototype.setFqbn = function(value) {
* optional string sketchPath = 3;
* @return {string}
*/
proto.arduino.CompileReq.prototype.getSketchpath = function() {
proto.cc.arduino.cli.commands.CompileReq.prototype.getSketchpath = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 3, ""));
};
/** @param {string} value */
proto.arduino.CompileReq.prototype.setSketchpath = function(value) {
proto.cc.arduino.cli.commands.CompileReq.prototype.setSketchpath = function(value) {
jspb.Message.setProto3StringField(this, 3, value);
};
@ -361,13 +361,13 @@ proto.arduino.CompileReq.prototype.setSketchpath = function(value) {
* You should avoid comparisons like {@code val === true/false} in those cases.
* @return {boolean}
*/
proto.arduino.CompileReq.prototype.getShowproperties = function() {
proto.cc.arduino.cli.commands.CompileReq.prototype.getShowproperties = function() {
return /** @type {boolean} */ (jspb.Message.getFieldWithDefault(this, 4, false));
};
/** @param {boolean} value */
proto.arduino.CompileReq.prototype.setShowproperties = function(value) {
proto.cc.arduino.cli.commands.CompileReq.prototype.setShowproperties = function(value) {
jspb.Message.setProto3BooleanField(this, 4, value);
};
@ -378,13 +378,13 @@ proto.arduino.CompileReq.prototype.setShowproperties = function(value) {
* You should avoid comparisons like {@code val === true/false} in those cases.
* @return {boolean}
*/
proto.arduino.CompileReq.prototype.getPreprocess = function() {
proto.cc.arduino.cli.commands.CompileReq.prototype.getPreprocess = function() {
return /** @type {boolean} */ (jspb.Message.getFieldWithDefault(this, 5, false));
};
/** @param {boolean} value */
proto.arduino.CompileReq.prototype.setPreprocess = function(value) {
proto.cc.arduino.cli.commands.CompileReq.prototype.setPreprocess = function(value) {
jspb.Message.setProto3BooleanField(this, 5, value);
};
@ -393,13 +393,13 @@ proto.arduino.CompileReq.prototype.setPreprocess = function(value) {
* optional string buildCachePath = 6;
* @return {string}
*/
proto.arduino.CompileReq.prototype.getBuildcachepath = function() {
proto.cc.arduino.cli.commands.CompileReq.prototype.getBuildcachepath = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 6, ""));
};
/** @param {string} value */
proto.arduino.CompileReq.prototype.setBuildcachepath = function(value) {
proto.cc.arduino.cli.commands.CompileReq.prototype.setBuildcachepath = function(value) {
jspb.Message.setProto3StringField(this, 6, value);
};
@ -408,13 +408,13 @@ proto.arduino.CompileReq.prototype.setBuildcachepath = function(value) {
* optional string buildPath = 7;
* @return {string}
*/
proto.arduino.CompileReq.prototype.getBuildpath = function() {
proto.cc.arduino.cli.commands.CompileReq.prototype.getBuildpath = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 7, ""));
};
/** @param {string} value */
proto.arduino.CompileReq.prototype.setBuildpath = function(value) {
proto.cc.arduino.cli.commands.CompileReq.prototype.setBuildpath = function(value) {
jspb.Message.setProto3StringField(this, 7, value);
};
@ -423,13 +423,13 @@ proto.arduino.CompileReq.prototype.setBuildpath = function(value) {
* repeated string buildProperties = 8;
* @return {!Array<string>}
*/
proto.arduino.CompileReq.prototype.getBuildpropertiesList = function() {
proto.cc.arduino.cli.commands.CompileReq.prototype.getBuildpropertiesList = function() {
return /** @type {!Array<string>} */ (jspb.Message.getRepeatedField(this, 8));
};
/** @param {!Array<string>} value */
proto.arduino.CompileReq.prototype.setBuildpropertiesList = function(value) {
proto.cc.arduino.cli.commands.CompileReq.prototype.setBuildpropertiesList = function(value) {
jspb.Message.setField(this, 8, value || []);
};
@ -438,12 +438,12 @@ proto.arduino.CompileReq.prototype.setBuildpropertiesList = function(value) {
* @param {string} value
* @param {number=} opt_index
*/
proto.arduino.CompileReq.prototype.addBuildproperties = function(value, opt_index) {
proto.cc.arduino.cli.commands.CompileReq.prototype.addBuildproperties = function(value, opt_index) {
jspb.Message.addToRepeatedField(this, 8, value, opt_index);
};
proto.arduino.CompileReq.prototype.clearBuildpropertiesList = function() {
proto.cc.arduino.cli.commands.CompileReq.prototype.clearBuildpropertiesList = function() {
this.setBuildpropertiesList([]);
};
@ -452,13 +452,13 @@ proto.arduino.CompileReq.prototype.clearBuildpropertiesList = function() {
* optional string warnings = 9;
* @return {string}
*/
proto.arduino.CompileReq.prototype.getWarnings = function() {
proto.cc.arduino.cli.commands.CompileReq.prototype.getWarnings = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 9, ""));
};
/** @param {string} value */
proto.arduino.CompileReq.prototype.setWarnings = function(value) {
proto.cc.arduino.cli.commands.CompileReq.prototype.setWarnings = function(value) {
jspb.Message.setProto3StringField(this, 9, value);
};
@ -469,13 +469,13 @@ proto.arduino.CompileReq.prototype.setWarnings = function(value) {
* You should avoid comparisons like {@code val === true/false} in those cases.
* @return {boolean}
*/
proto.arduino.CompileReq.prototype.getVerbose = function() {
proto.cc.arduino.cli.commands.CompileReq.prototype.getVerbose = function() {
return /** @type {boolean} */ (jspb.Message.getFieldWithDefault(this, 10, false));
};
/** @param {boolean} value */
proto.arduino.CompileReq.prototype.setVerbose = function(value) {
proto.cc.arduino.cli.commands.CompileReq.prototype.setVerbose = function(value) {
jspb.Message.setProto3BooleanField(this, 10, value);
};
@ -486,13 +486,13 @@ proto.arduino.CompileReq.prototype.setVerbose = function(value) {
* You should avoid comparisons like {@code val === true/false} in those cases.
* @return {boolean}
*/
proto.arduino.CompileReq.prototype.getQuiet = function() {
proto.cc.arduino.cli.commands.CompileReq.prototype.getQuiet = function() {
return /** @type {boolean} */ (jspb.Message.getFieldWithDefault(this, 11, false));
};
/** @param {boolean} value */
proto.arduino.CompileReq.prototype.setQuiet = function(value) {
proto.cc.arduino.cli.commands.CompileReq.prototype.setQuiet = function(value) {
jspb.Message.setProto3BooleanField(this, 11, value);
};
@ -501,13 +501,13 @@ proto.arduino.CompileReq.prototype.setQuiet = function(value) {
* optional string vidPid = 12;
* @return {string}
*/
proto.arduino.CompileReq.prototype.getVidpid = function() {
proto.cc.arduino.cli.commands.CompileReq.prototype.getVidpid = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 12, ""));
};
/** @param {string} value */
proto.arduino.CompileReq.prototype.setVidpid = function(value) {
proto.cc.arduino.cli.commands.CompileReq.prototype.setVidpid = function(value) {
jspb.Message.setProto3StringField(this, 12, value);
};
@ -516,13 +516,13 @@ proto.arduino.CompileReq.prototype.setVidpid = function(value) {
* optional string exportFile = 13;
* @return {string}
*/
proto.arduino.CompileReq.prototype.getExportfile = function() {
proto.cc.arduino.cli.commands.CompileReq.prototype.getExportfile = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 13, ""));
};
/** @param {string} value */
proto.arduino.CompileReq.prototype.setExportfile = function(value) {
proto.cc.arduino.cli.commands.CompileReq.prototype.setExportfile = function(value) {
jspb.Message.setProto3StringField(this, 13, value);
};
@ -538,12 +538,12 @@ proto.arduino.CompileReq.prototype.setExportfile = function(value) {
* @extends {jspb.Message}
* @constructor
*/
proto.arduino.CompileResp = function(opt_data) {
proto.cc.arduino.cli.commands.CompileResp = function(opt_data) {
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
};
goog.inherits(proto.arduino.CompileResp, jspb.Message);
goog.inherits(proto.cc.arduino.cli.commands.CompileResp, jspb.Message);
if (goog.DEBUG && !COMPILED) {
proto.arduino.CompileResp.displayName = 'proto.arduino.CompileResp';
proto.cc.arduino.cli.commands.CompileResp.displayName = 'proto.cc.arduino.cli.commands.CompileResp';
}
@ -558,8 +558,8 @@ if (jspb.Message.GENERATE_TO_OBJECT) {
* for transitional soy proto support: http://goto/soy-param-migration
* @return {!Object}
*/
proto.arduino.CompileResp.prototype.toObject = function(opt_includeInstance) {
return proto.arduino.CompileResp.toObject(opt_includeInstance, this);
proto.cc.arduino.cli.commands.CompileResp.prototype.toObject = function(opt_includeInstance) {
return proto.cc.arduino.cli.commands.CompileResp.toObject(opt_includeInstance, this);
};
@ -568,16 +568,14 @@ proto.arduino.CompileResp.prototype.toObject = function(opt_includeInstance) {
* @param {boolean|undefined} includeInstance Whether to include the JSPB
* instance for transitional soy proto support:
* http://goto/soy-param-migration
* @param {!proto.arduino.CompileResp} msg The msg instance to transform.
* @param {!proto.cc.arduino.cli.commands.CompileResp} msg The msg instance to transform.
* @return {!Object}
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.arduino.CompileResp.toObject = function(includeInstance, msg) {
proto.cc.arduino.cli.commands.CompileResp.toObject = function(includeInstance, msg) {
var f, obj = {
outStream: msg.getOutStream_asB64(),
errStream: msg.getErrStream_asB64(),
downloadProgress: (f = msg.getDownloadProgress()) && common_pb.DownloadProgress.toObject(includeInstance, f),
taskProgress: (f = msg.getTaskProgress()) && common_pb.TaskProgress.toObject(includeInstance, f)
errStream: msg.getErrStream_asB64()
};
if (includeInstance) {
@ -591,23 +589,23 @@ proto.arduino.CompileResp.toObject = function(includeInstance, msg) {
/**
* Deserializes binary data (in protobuf wire format).
* @param {jspb.ByteSource} bytes The bytes to deserialize.
* @return {!proto.arduino.CompileResp}
* @return {!proto.cc.arduino.cli.commands.CompileResp}
*/
proto.arduino.CompileResp.deserializeBinary = function(bytes) {
proto.cc.arduino.cli.commands.CompileResp.deserializeBinary = function(bytes) {
var reader = new jspb.BinaryReader(bytes);
var msg = new proto.arduino.CompileResp;
return proto.arduino.CompileResp.deserializeBinaryFromReader(msg, reader);
var msg = new proto.cc.arduino.cli.commands.CompileResp;
return proto.cc.arduino.cli.commands.CompileResp.deserializeBinaryFromReader(msg, reader);
};
/**
* Deserializes binary data (in protobuf wire format) from the
* given reader into the given message object.
* @param {!proto.arduino.CompileResp} msg The message object to deserialize into.
* @param {!proto.cc.arduino.cli.commands.CompileResp} msg The message object to deserialize into.
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
* @return {!proto.arduino.CompileResp}
* @return {!proto.cc.arduino.cli.commands.CompileResp}
*/
proto.arduino.CompileResp.deserializeBinaryFromReader = function(msg, reader) {
proto.cc.arduino.cli.commands.CompileResp.deserializeBinaryFromReader = function(msg, reader) {
while (reader.nextField()) {
if (reader.isEndGroup()) {
break;
@ -622,16 +620,6 @@ proto.arduino.CompileResp.deserializeBinaryFromReader = function(msg, reader) {
var value = /** @type {!Uint8Array} */ (reader.readBytes());
msg.setErrStream(value);
break;
case 3:
var value = new common_pb.DownloadProgress;
reader.readMessage(value,common_pb.DownloadProgress.deserializeBinaryFromReader);
msg.setDownloadProgress(value);
break;
case 4:
var value = new common_pb.TaskProgress;
reader.readMessage(value,common_pb.TaskProgress.deserializeBinaryFromReader);
msg.setTaskProgress(value);
break;
default:
reader.skipField();
break;
@ -645,9 +633,9 @@ proto.arduino.CompileResp.deserializeBinaryFromReader = function(msg, reader) {
* Serializes the message to binary data (in protobuf wire format).
* @return {!Uint8Array}
*/
proto.arduino.CompileResp.prototype.serializeBinary = function() {
proto.cc.arduino.cli.commands.CompileResp.prototype.serializeBinary = function() {
var writer = new jspb.BinaryWriter();
proto.arduino.CompileResp.serializeBinaryToWriter(this, writer);
proto.cc.arduino.cli.commands.CompileResp.serializeBinaryToWriter(this, writer);
return writer.getResultBuffer();
};
@ -655,11 +643,11 @@ proto.arduino.CompileResp.prototype.serializeBinary = function() {
/**
* Serializes the given message to binary data (in protobuf wire
* format), writing to the given BinaryWriter.
* @param {!proto.arduino.CompileResp} message
* @param {!proto.cc.arduino.cli.commands.CompileResp} message
* @param {!jspb.BinaryWriter} writer
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.arduino.CompileResp.serializeBinaryToWriter = function(message, writer) {
proto.cc.arduino.cli.commands.CompileResp.serializeBinaryToWriter = function(message, writer) {
var f = undefined;
f = message.getOutStream_asU8();
if (f.length > 0) {
@ -675,22 +663,6 @@ proto.arduino.CompileResp.serializeBinaryToWriter = function(message, writer) {
f
);
}
f = message.getDownloadProgress();
if (f != null) {
writer.writeMessage(
3,
f,
common_pb.DownloadProgress.serializeBinaryToWriter
);
}
f = message.getTaskProgress();
if (f != null) {
writer.writeMessage(
4,
f,
common_pb.TaskProgress.serializeBinaryToWriter
);
}
};
@ -698,7 +670,7 @@ proto.arduino.CompileResp.serializeBinaryToWriter = function(message, writer) {
* optional bytes out_stream = 1;
* @return {!(string|Uint8Array)}
*/
proto.arduino.CompileResp.prototype.getOutStream = function() {
proto.cc.arduino.cli.commands.CompileResp.prototype.getOutStream = function() {
return /** @type {!(string|Uint8Array)} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
};
@ -708,7 +680,7 @@ proto.arduino.CompileResp.prototype.getOutStream = function() {
* This is a type-conversion wrapper around `getOutStream()`
* @return {string}
*/
proto.arduino.CompileResp.prototype.getOutStream_asB64 = function() {
proto.cc.arduino.cli.commands.CompileResp.prototype.getOutStream_asB64 = function() {
return /** @type {string} */ (jspb.Message.bytesAsB64(
this.getOutStream()));
};
@ -721,14 +693,14 @@ proto.arduino.CompileResp.prototype.getOutStream_asB64 = function() {
* This is a type-conversion wrapper around `getOutStream()`
* @return {!Uint8Array}
*/
proto.arduino.CompileResp.prototype.getOutStream_asU8 = function() {
proto.cc.arduino.cli.commands.CompileResp.prototype.getOutStream_asU8 = function() {
return /** @type {!Uint8Array} */ (jspb.Message.bytesAsU8(
this.getOutStream()));
};
/** @param {!(string|Uint8Array)} value */
proto.arduino.CompileResp.prototype.setOutStream = function(value) {
proto.cc.arduino.cli.commands.CompileResp.prototype.setOutStream = function(value) {
jspb.Message.setProto3BytesField(this, 1, value);
};
@ -737,7 +709,7 @@ proto.arduino.CompileResp.prototype.setOutStream = function(value) {
* optional bytes err_stream = 2;
* @return {!(string|Uint8Array)}
*/
proto.arduino.CompileResp.prototype.getErrStream = function() {
proto.cc.arduino.cli.commands.CompileResp.prototype.getErrStream = function() {
return /** @type {!(string|Uint8Array)} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
};
@ -747,7 +719,7 @@ proto.arduino.CompileResp.prototype.getErrStream = function() {
* This is a type-conversion wrapper around `getErrStream()`
* @return {string}
*/
proto.arduino.CompileResp.prototype.getErrStream_asB64 = function() {
proto.cc.arduino.cli.commands.CompileResp.prototype.getErrStream_asB64 = function() {
return /** @type {string} */ (jspb.Message.bytesAsB64(
this.getErrStream()));
};
@ -760,76 +732,16 @@ proto.arduino.CompileResp.prototype.getErrStream_asB64 = function() {
* This is a type-conversion wrapper around `getErrStream()`
* @return {!Uint8Array}
*/
proto.arduino.CompileResp.prototype.getErrStream_asU8 = function() {
proto.cc.arduino.cli.commands.CompileResp.prototype.getErrStream_asU8 = function() {
return /** @type {!Uint8Array} */ (jspb.Message.bytesAsU8(
this.getErrStream()));
};
/** @param {!(string|Uint8Array)} value */
proto.arduino.CompileResp.prototype.setErrStream = function(value) {
proto.cc.arduino.cli.commands.CompileResp.prototype.setErrStream = function(value) {
jspb.Message.setProto3BytesField(this, 2, value);
};
/**
* optional DownloadProgress download_progress = 3;
* @return {?proto.arduino.DownloadProgress}
*/
proto.arduino.CompileResp.prototype.getDownloadProgress = function() {
return /** @type{?proto.arduino.DownloadProgress} */ (
jspb.Message.getWrapperField(this, common_pb.DownloadProgress, 3));
};
/** @param {?proto.arduino.DownloadProgress|undefined} value */
proto.arduino.CompileResp.prototype.setDownloadProgress = function(value) {
jspb.Message.setWrapperField(this, 3, value);
};
proto.arduino.CompileResp.prototype.clearDownloadProgress = function() {
this.setDownloadProgress(undefined);
};
/**
* Returns whether this field is set.
* @return {boolean}
*/
proto.arduino.CompileResp.prototype.hasDownloadProgress = function() {
return jspb.Message.getField(this, 3) != null;
};
/**
* optional TaskProgress task_progress = 4;
* @return {?proto.arduino.TaskProgress}
*/
proto.arduino.CompileResp.prototype.getTaskProgress = function() {
return /** @type{?proto.arduino.TaskProgress} */ (
jspb.Message.getWrapperField(this, common_pb.TaskProgress, 4));
};
/** @param {?proto.arduino.TaskProgress|undefined} value */
proto.arduino.CompileResp.prototype.setTaskProgress = function(value) {
jspb.Message.setWrapperField(this, 4, value);
};
proto.arduino.CompileResp.prototype.clearTaskProgress = function() {
this.setTaskProgress(undefined);
};
/**
* Returns whether this field is set.
* @return {boolean}
*/
proto.arduino.CompileResp.prototype.hasTaskProgress = function() {
return jspb.Message.getField(this, 4) != null;
};
goog.object.extend(exports, proto.arduino);
goog.object.extend(exports, proto.cc.arduino.cli.commands);

View File

@ -1,17 +1,17 @@
// package: arduino
// file: core.proto
// package: cc.arduino.cli.commands
// file: commands/core.proto
/* tslint:disable */
import * as jspb from "google-protobuf";
import * as common_pb from "./common_pb";
import * as commands_common_pb from "../commands/common_pb";
export class PlatformInstallReq extends jspb.Message {
hasInstance(): boolean;
clearInstance(): void;
getInstance(): common_pb.Instance | undefined;
setInstance(value?: common_pb.Instance): void;
getInstance(): commands_common_pb.Instance | undefined;
setInstance(value?: commands_common_pb.Instance): void;
getPlatformPackage(): string;
setPlatformPackage(value: string): void;
@ -35,7 +35,7 @@ export class PlatformInstallReq extends jspb.Message {
export namespace PlatformInstallReq {
export type AsObject = {
instance?: common_pb.Instance.AsObject,
instance?: commands_common_pb.Instance.AsObject,
platformPackage: string,
architecture: string,
version: string,
@ -46,14 +46,14 @@ export class PlatformInstallResp extends jspb.Message {
hasProgress(): boolean;
clearProgress(): void;
getProgress(): common_pb.DownloadProgress | undefined;
setProgress(value?: common_pb.DownloadProgress): void;
getProgress(): commands_common_pb.DownloadProgress | undefined;
setProgress(value?: commands_common_pb.DownloadProgress): void;
hasTaskProgress(): boolean;
clearTaskProgress(): void;
getTaskProgress(): common_pb.TaskProgress | undefined;
setTaskProgress(value?: common_pb.TaskProgress): void;
getTaskProgress(): commands_common_pb.TaskProgress | undefined;
setTaskProgress(value?: commands_common_pb.TaskProgress): void;
serializeBinary(): Uint8Array;
@ -68,8 +68,8 @@ export class PlatformInstallResp extends jspb.Message {
export namespace PlatformInstallResp {
export type AsObject = {
progress?: common_pb.DownloadProgress.AsObject,
taskProgress?: common_pb.TaskProgress.AsObject,
progress?: commands_common_pb.DownloadProgress.AsObject,
taskProgress?: commands_common_pb.TaskProgress.AsObject,
}
}
@ -77,8 +77,8 @@ export class PlatformDownloadReq extends jspb.Message {
hasInstance(): boolean;
clearInstance(): void;
getInstance(): common_pb.Instance | undefined;
setInstance(value?: common_pb.Instance): void;
getInstance(): commands_common_pb.Instance | undefined;
setInstance(value?: commands_common_pb.Instance): void;
getPlatformPackage(): string;
setPlatformPackage(value: string): void;
@ -102,7 +102,7 @@ export class PlatformDownloadReq extends jspb.Message {
export namespace PlatformDownloadReq {
export type AsObject = {
instance?: common_pb.Instance.AsObject,
instance?: commands_common_pb.Instance.AsObject,
platformPackage: string,
architecture: string,
version: string,
@ -113,8 +113,8 @@ export class PlatformDownloadResp extends jspb.Message {
hasProgress(): boolean;
clearProgress(): void;
getProgress(): common_pb.DownloadProgress | undefined;
setProgress(value?: common_pb.DownloadProgress): void;
getProgress(): commands_common_pb.DownloadProgress | undefined;
setProgress(value?: commands_common_pb.DownloadProgress): void;
serializeBinary(): Uint8Array;
@ -129,7 +129,7 @@ export class PlatformDownloadResp extends jspb.Message {
export namespace PlatformDownloadResp {
export type AsObject = {
progress?: common_pb.DownloadProgress.AsObject,
progress?: commands_common_pb.DownloadProgress.AsObject,
}
}
@ -137,8 +137,8 @@ export class PlatformUninstallReq extends jspb.Message {
hasInstance(): boolean;
clearInstance(): void;
getInstance(): common_pb.Instance | undefined;
setInstance(value?: common_pb.Instance): void;
getInstance(): commands_common_pb.Instance | undefined;
setInstance(value?: commands_common_pb.Instance): void;
getPlatformPackage(): string;
setPlatformPackage(value: string): void;
@ -146,9 +146,6 @@ export class PlatformUninstallReq extends jspb.Message {
getArchitecture(): string;
setArchitecture(value: string): void;
getVersion(): string;
setVersion(value: string): void;
serializeBinary(): Uint8Array;
toObject(includeInstance?: boolean): PlatformUninstallReq.AsObject;
@ -162,10 +159,9 @@ export class PlatformUninstallReq extends jspb.Message {
export namespace PlatformUninstallReq {
export type AsObject = {
instance?: common_pb.Instance.AsObject,
instance?: commands_common_pb.Instance.AsObject,
platformPackage: string,
architecture: string,
version: string,
}
}
@ -173,8 +169,8 @@ export class PlatformUninstallResp extends jspb.Message {
hasTaskProgress(): boolean;
clearTaskProgress(): void;
getTaskProgress(): common_pb.TaskProgress | undefined;
setTaskProgress(value?: common_pb.TaskProgress): void;
getTaskProgress(): commands_common_pb.TaskProgress | undefined;
setTaskProgress(value?: commands_common_pb.TaskProgress): void;
serializeBinary(): Uint8Array;
@ -189,7 +185,7 @@ export class PlatformUninstallResp extends jspb.Message {
export namespace PlatformUninstallResp {
export type AsObject = {
taskProgress?: common_pb.TaskProgress.AsObject,
taskProgress?: commands_common_pb.TaskProgress.AsObject,
}
}
@ -197,8 +193,8 @@ export class PlatformUpgradeReq extends jspb.Message {
hasInstance(): boolean;
clearInstance(): void;
getInstance(): common_pb.Instance | undefined;
setInstance(value?: common_pb.Instance): void;
getInstance(): commands_common_pb.Instance | undefined;
setInstance(value?: commands_common_pb.Instance): void;
getPlatformPackage(): string;
setPlatformPackage(value: string): void;
@ -219,7 +215,7 @@ export class PlatformUpgradeReq extends jspb.Message {
export namespace PlatformUpgradeReq {
export type AsObject = {
instance?: common_pb.Instance.AsObject,
instance?: commands_common_pb.Instance.AsObject,
platformPackage: string,
architecture: string,
}
@ -229,14 +225,14 @@ export class PlatformUpgradeResp extends jspb.Message {
hasProgress(): boolean;
clearProgress(): void;
getProgress(): common_pb.DownloadProgress | undefined;
setProgress(value?: common_pb.DownloadProgress): void;
getProgress(): commands_common_pb.DownloadProgress | undefined;
setProgress(value?: commands_common_pb.DownloadProgress): void;
hasTaskProgress(): boolean;
clearTaskProgress(): void;
getTaskProgress(): common_pb.TaskProgress | undefined;
setTaskProgress(value?: common_pb.TaskProgress): void;
getTaskProgress(): commands_common_pb.TaskProgress | undefined;
setTaskProgress(value?: commands_common_pb.TaskProgress): void;
serializeBinary(): Uint8Array;
@ -251,8 +247,8 @@ export class PlatformUpgradeResp extends jspb.Message {
export namespace PlatformUpgradeResp {
export type AsObject = {
progress?: common_pb.DownloadProgress.AsObject,
taskProgress?: common_pb.TaskProgress.AsObject,
progress?: commands_common_pb.DownloadProgress.AsObject,
taskProgress?: commands_common_pb.TaskProgress.AsObject,
}
}
@ -260,8 +256,8 @@ export class PlatformSearchReq extends jspb.Message {
hasInstance(): boolean;
clearInstance(): void;
getInstance(): common_pb.Instance | undefined;
setInstance(value?: common_pb.Instance): void;
getInstance(): commands_common_pb.Instance | undefined;
setInstance(value?: commands_common_pb.Instance): void;
getSearchArgs(): string;
setSearchArgs(value: string): void;
@ -279,16 +275,16 @@ export class PlatformSearchReq extends jspb.Message {
export namespace PlatformSearchReq {
export type AsObject = {
instance?: common_pb.Instance.AsObject,
instance?: commands_common_pb.Instance.AsObject,
searchArgs: string,
}
}
export class PlatformSearchResp extends jspb.Message {
clearSearchOutputList(): void;
getSearchOutputList(): Array<SearchOutput>;
setSearchOutputList(value: Array<SearchOutput>): void;
addSearchOutput(value?: SearchOutput, index?: number): SearchOutput;
getSearchOutputList(): Array<Platform>;
setSearchOutputList(value: Array<Platform>): void;
addSearchOutput(value?: Platform, index?: number): Platform;
serializeBinary(): Uint8Array;
@ -303,71 +299,7 @@ export class PlatformSearchResp extends jspb.Message {
export namespace PlatformSearchResp {
export type AsObject = {
searchOutputList: Array<SearchOutput.AsObject>,
}
}
export class SearchOutput extends jspb.Message {
getId(): string;
setId(value: string): void;
getVersion(): string;
setVersion(value: string): void;
getName(): string;
setName(value: string): void;
getAuthor(): string;
setAuthor(value: string): void;
clearBoardsList(): void;
getBoardsList(): Array<SearchOutputBoard>;
setBoardsList(value: Array<SearchOutputBoard>): void;
addBoards(value?: SearchOutputBoard, index?: number): SearchOutputBoard;
serializeBinary(): Uint8Array;
toObject(includeInstance?: boolean): SearchOutput.AsObject;
static toObject(includeInstance: boolean, msg: SearchOutput): SearchOutput.AsObject;
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
static serializeBinaryToWriter(message: SearchOutput, writer: jspb.BinaryWriter): void;
static deserializeBinary(bytes: Uint8Array): SearchOutput;
static deserializeBinaryFromReader(message: SearchOutput, reader: jspb.BinaryReader): SearchOutput;
}
export namespace SearchOutput {
export type AsObject = {
id: string,
version: string,
name: string,
author: string,
boardsList: Array<SearchOutputBoard.AsObject>,
}
}
export class SearchOutputBoard extends jspb.Message {
getName(): string;
setName(value: string): void;
getFqbn(): string;
setFqbn(value: string): void;
serializeBinary(): Uint8Array;
toObject(includeInstance?: boolean): SearchOutputBoard.AsObject;
static toObject(includeInstance: boolean, msg: SearchOutputBoard): SearchOutputBoard.AsObject;
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
static serializeBinaryToWriter(message: SearchOutputBoard, writer: jspb.BinaryWriter): void;
static deserializeBinary(bytes: Uint8Array): SearchOutputBoard;
static deserializeBinaryFromReader(message: SearchOutputBoard, reader: jspb.BinaryReader): SearchOutputBoard;
}
export namespace SearchOutputBoard {
export type AsObject = {
name: string,
fqbn: string,
searchOutputList: Array<Platform.AsObject>,
}
}
@ -375,8 +307,8 @@ export class PlatformListReq extends jspb.Message {
hasInstance(): boolean;
clearInstance(): void;
getInstance(): common_pb.Instance | undefined;
setInstance(value?: common_pb.Instance): void;
getInstance(): commands_common_pb.Instance | undefined;
setInstance(value?: commands_common_pb.Instance): void;
getUpdatableOnly(): boolean;
setUpdatableOnly(value: boolean): void;
@ -394,16 +326,16 @@ export class PlatformListReq extends jspb.Message {
export namespace PlatformListReq {
export type AsObject = {
instance?: common_pb.Instance.AsObject,
instance?: commands_common_pb.Instance.AsObject,
updatableOnly: boolean,
}
}
export class PlatformListResp extends jspb.Message {
clearInstalledPlatformList(): void;
getInstalledPlatformList(): Array<InstalledPlatform>;
setInstalledPlatformList(value: Array<InstalledPlatform>): void;
addInstalledPlatform(value?: InstalledPlatform, index?: number): InstalledPlatform;
getInstalledPlatformList(): Array<Platform>;
setInstalledPlatformList(value: Array<Platform>): void;
addInstalledPlatform(value?: Platform, index?: number): Platform;
serializeBinary(): Uint8Array;
@ -418,11 +350,11 @@ export class PlatformListResp extends jspb.Message {
export namespace PlatformListResp {
export type AsObject = {
installedPlatformList: Array<InstalledPlatform.AsObject>,
installedPlatformList: Array<Platform.AsObject>,
}
}
export class InstalledPlatform extends jspb.Message {
export class Platform extends jspb.Message {
getId(): string;
setId(value: string): void;
@ -435,22 +367,65 @@ export class InstalledPlatform extends jspb.Message {
getName(): string;
setName(value: string): void;
getMaintainer(): string;
setMaintainer(value: string): void;
getWebsite(): string;
setWebsite(value: string): void;
getEmail(): string;
setEmail(value: string): void;
clearBoardsList(): void;
getBoardsList(): Array<Board>;
setBoardsList(value: Array<Board>): void;
addBoards(value?: Board, index?: number): Board;
serializeBinary(): Uint8Array;
toObject(includeInstance?: boolean): InstalledPlatform.AsObject;
static toObject(includeInstance: boolean, msg: InstalledPlatform): InstalledPlatform.AsObject;
toObject(includeInstance?: boolean): Platform.AsObject;
static toObject(includeInstance: boolean, msg: Platform): Platform.AsObject;
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
static serializeBinaryToWriter(message: InstalledPlatform, writer: jspb.BinaryWriter): void;
static deserializeBinary(bytes: Uint8Array): InstalledPlatform;
static deserializeBinaryFromReader(message: InstalledPlatform, reader: jspb.BinaryReader): InstalledPlatform;
static serializeBinaryToWriter(message: Platform, writer: jspb.BinaryWriter): void;
static deserializeBinary(bytes: Uint8Array): Platform;
static deserializeBinaryFromReader(message: Platform, reader: jspb.BinaryReader): Platform;
}
export namespace InstalledPlatform {
export namespace Platform {
export type AsObject = {
id: string,
installed: string,
latest: string,
name: string,
maintainer: string,
website: string,
email: string,
boardsList: Array<Board.AsObject>,
}
}
export class Board extends jspb.Message {
getName(): string;
setName(value: string): void;
getFqbn(): string;
setFqbn(value: string): void;
serializeBinary(): Uint8Array;
toObject(includeInstance?: boolean): Board.AsObject;
static toObject(includeInstance: boolean, msg: Board): Board.AsObject;
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
static serializeBinaryToWriter(message: Board, writer: jspb.BinaryWriter): void;
static deserializeBinary(bytes: Uint8Array): Board;
static deserializeBinaryFromReader(message: Board, reader: jspb.BinaryReader): Board;
}
export namespace Board {
export type AsObject = {
name: string,
fqbn: string,
}
}

View File

@ -1,17 +1,17 @@
// package: arduino
// file: lib.proto
// package: cc.arduino.cli.commands
// file: commands/lib.proto
/* tslint:disable */
import * as jspb from "google-protobuf";
import * as common_pb from "./common_pb";
import * as commands_common_pb from "../commands/common_pb";
export class LibraryDownloadReq extends jspb.Message {
hasInstance(): boolean;
clearInstance(): void;
getInstance(): common_pb.Instance | undefined;
setInstance(value?: common_pb.Instance): void;
getInstance(): commands_common_pb.Instance | undefined;
setInstance(value?: commands_common_pb.Instance): void;
getName(): string;
setName(value: string): void;
@ -32,7 +32,7 @@ export class LibraryDownloadReq extends jspb.Message {
export namespace LibraryDownloadReq {
export type AsObject = {
instance?: common_pb.Instance.AsObject,
instance?: commands_common_pb.Instance.AsObject,
name: string,
version: string,
}
@ -42,8 +42,8 @@ export class LibraryDownloadResp extends jspb.Message {
hasProgress(): boolean;
clearProgress(): void;
getProgress(): common_pb.DownloadProgress | undefined;
setProgress(value?: common_pb.DownloadProgress): void;
getProgress(): commands_common_pb.DownloadProgress | undefined;
setProgress(value?: commands_common_pb.DownloadProgress): void;
serializeBinary(): Uint8Array;
@ -58,7 +58,7 @@ export class LibraryDownloadResp extends jspb.Message {
export namespace LibraryDownloadResp {
export type AsObject = {
progress?: common_pb.DownloadProgress.AsObject,
progress?: commands_common_pb.DownloadProgress.AsObject,
}
}
@ -66,8 +66,8 @@ export class LibraryInstallReq extends jspb.Message {
hasInstance(): boolean;
clearInstance(): void;
getInstance(): common_pb.Instance | undefined;
setInstance(value?: common_pb.Instance): void;
getInstance(): commands_common_pb.Instance | undefined;
setInstance(value?: commands_common_pb.Instance): void;
getName(): string;
setName(value: string): void;
@ -88,7 +88,7 @@ export class LibraryInstallReq extends jspb.Message {
export namespace LibraryInstallReq {
export type AsObject = {
instance?: common_pb.Instance.AsObject,
instance?: commands_common_pb.Instance.AsObject,
name: string,
version: string,
}
@ -98,14 +98,14 @@ export class LibraryInstallResp extends jspb.Message {
hasProgress(): boolean;
clearProgress(): void;
getProgress(): common_pb.DownloadProgress | undefined;
setProgress(value?: common_pb.DownloadProgress): void;
getProgress(): commands_common_pb.DownloadProgress | undefined;
setProgress(value?: commands_common_pb.DownloadProgress): void;
hasTaskProgress(): boolean;
clearTaskProgress(): void;
getTaskProgress(): common_pb.TaskProgress | undefined;
setTaskProgress(value?: common_pb.TaskProgress): void;
getTaskProgress(): commands_common_pb.TaskProgress | undefined;
setTaskProgress(value?: commands_common_pb.TaskProgress): void;
serializeBinary(): Uint8Array;
@ -120,8 +120,8 @@ export class LibraryInstallResp extends jspb.Message {
export namespace LibraryInstallResp {
export type AsObject = {
progress?: common_pb.DownloadProgress.AsObject,
taskProgress?: common_pb.TaskProgress.AsObject,
progress?: commands_common_pb.DownloadProgress.AsObject,
taskProgress?: commands_common_pb.TaskProgress.AsObject,
}
}
@ -129,8 +129,8 @@ export class LibraryUninstallReq extends jspb.Message {
hasInstance(): boolean;
clearInstance(): void;
getInstance(): common_pb.Instance | undefined;
setInstance(value?: common_pb.Instance): void;
getInstance(): commands_common_pb.Instance | undefined;
setInstance(value?: commands_common_pb.Instance): void;
getName(): string;
setName(value: string): void;
@ -151,7 +151,7 @@ export class LibraryUninstallReq extends jspb.Message {
export namespace LibraryUninstallReq {
export type AsObject = {
instance?: common_pb.Instance.AsObject,
instance?: commands_common_pb.Instance.AsObject,
name: string,
version: string,
}
@ -161,8 +161,8 @@ export class LibraryUninstallResp extends jspb.Message {
hasTaskProgress(): boolean;
clearTaskProgress(): void;
getTaskProgress(): common_pb.TaskProgress | undefined;
setTaskProgress(value?: common_pb.TaskProgress): void;
getTaskProgress(): commands_common_pb.TaskProgress | undefined;
setTaskProgress(value?: commands_common_pb.TaskProgress): void;
serializeBinary(): Uint8Array;
@ -177,7 +177,7 @@ export class LibraryUninstallResp extends jspb.Message {
export namespace LibraryUninstallResp {
export type AsObject = {
taskProgress?: common_pb.TaskProgress.AsObject,
taskProgress?: commands_common_pb.TaskProgress.AsObject,
}
}
@ -185,8 +185,8 @@ export class LibraryUpgradeAllReq extends jspb.Message {
hasInstance(): boolean;
clearInstance(): void;
getInstance(): common_pb.Instance | undefined;
setInstance(value?: common_pb.Instance): void;
getInstance(): commands_common_pb.Instance | undefined;
setInstance(value?: commands_common_pb.Instance): void;
serializeBinary(): Uint8Array;
@ -201,7 +201,7 @@ export class LibraryUpgradeAllReq extends jspb.Message {
export namespace LibraryUpgradeAllReq {
export type AsObject = {
instance?: common_pb.Instance.AsObject,
instance?: commands_common_pb.Instance.AsObject,
}
}
@ -209,14 +209,14 @@ export class LibraryUpgradeAllResp extends jspb.Message {
hasProgress(): boolean;
clearProgress(): void;
getProgress(): common_pb.DownloadProgress | undefined;
setProgress(value?: common_pb.DownloadProgress): void;
getProgress(): commands_common_pb.DownloadProgress | undefined;
setProgress(value?: commands_common_pb.DownloadProgress): void;
hasTaskProgress(): boolean;
clearTaskProgress(): void;
getTaskProgress(): common_pb.TaskProgress | undefined;
setTaskProgress(value?: common_pb.TaskProgress): void;
getTaskProgress(): commands_common_pb.TaskProgress | undefined;
setTaskProgress(value?: commands_common_pb.TaskProgress): void;
serializeBinary(): Uint8Array;
@ -231,8 +231,8 @@ export class LibraryUpgradeAllResp extends jspb.Message {
export namespace LibraryUpgradeAllResp {
export type AsObject = {
progress?: common_pb.DownloadProgress.AsObject,
taskProgress?: common_pb.TaskProgress.AsObject,
progress?: commands_common_pb.DownloadProgress.AsObject,
taskProgress?: commands_common_pb.TaskProgress.AsObject,
}
}
@ -240,11 +240,8 @@ export class LibrarySearchReq extends jspb.Message {
hasInstance(): boolean;
clearInstance(): void;
getInstance(): common_pb.Instance | undefined;
setInstance(value?: common_pb.Instance): void;
getNames(): boolean;
setNames(value: boolean): void;
getInstance(): commands_common_pb.Instance | undefined;
setInstance(value?: commands_common_pb.Instance): void;
getQuery(): string;
setQuery(value: string): void;
@ -262,17 +259,16 @@ export class LibrarySearchReq extends jspb.Message {
export namespace LibrarySearchReq {
export type AsObject = {
instance?: common_pb.Instance.AsObject,
names: boolean,
instance?: commands_common_pb.Instance.AsObject,
query: string,
}
}
export class LibrarySearchResp extends jspb.Message {
clearSearchOutputList(): void;
getSearchOutputList(): Array<SearchLibraryOutput>;
setSearchOutputList(value: Array<SearchLibraryOutput>): void;
addSearchOutput(value?: SearchLibraryOutput, index?: number): SearchLibraryOutput;
clearLibrariesList(): void;
getLibrariesList(): Array<SearchedLibrary>;
setLibrariesList(value: Array<SearchedLibrary>): void;
addLibraries(value?: SearchedLibrary, index?: number): SearchedLibrary;
serializeBinary(): Uint8Array;
@ -287,11 +283,11 @@ export class LibrarySearchResp extends jspb.Message {
export namespace LibrarySearchResp {
export type AsObject = {
searchOutputList: Array<SearchLibraryOutput.AsObject>,
librariesList: Array<SearchedLibrary.AsObject>,
}
}
export class SearchLibraryOutput extends jspb.Message {
export class SearchedLibrary extends jspb.Message {
getName(): string;
setName(value: string): void;
@ -307,16 +303,16 @@ export class SearchLibraryOutput extends jspb.Message {
serializeBinary(): Uint8Array;
toObject(includeInstance?: boolean): SearchLibraryOutput.AsObject;
static toObject(includeInstance: boolean, msg: SearchLibraryOutput): SearchLibraryOutput.AsObject;
toObject(includeInstance?: boolean): SearchedLibrary.AsObject;
static toObject(includeInstance: boolean, msg: SearchedLibrary): SearchedLibrary.AsObject;
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
static serializeBinaryToWriter(message: SearchLibraryOutput, writer: jspb.BinaryWriter): void;
static deserializeBinary(bytes: Uint8Array): SearchLibraryOutput;
static deserializeBinaryFromReader(message: SearchLibraryOutput, reader: jspb.BinaryReader): SearchLibraryOutput;
static serializeBinaryToWriter(message: SearchedLibrary, writer: jspb.BinaryWriter): void;
static deserializeBinary(bytes: Uint8Array): SearchedLibrary;
static deserializeBinaryFromReader(message: SearchedLibrary, reader: jspb.BinaryReader): SearchedLibrary;
}
export namespace SearchLibraryOutput {
export namespace SearchedLibrary {
export type AsObject = {
name: string,
@ -325,81 +321,6 @@ export namespace SearchLibraryOutput {
}
}
export class LibraryListReq extends jspb.Message {
hasInstance(): boolean;
clearInstance(): void;
getInstance(): common_pb.Instance | undefined;
setInstance(value?: common_pb.Instance): void;
serializeBinary(): Uint8Array;
toObject(includeInstance?: boolean): LibraryListReq.AsObject;
static toObject(includeInstance: boolean, msg: LibraryListReq): LibraryListReq.AsObject;
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
static serializeBinaryToWriter(message: LibraryListReq, writer: jspb.BinaryWriter): void;
static deserializeBinary(bytes: Uint8Array): LibraryListReq;
static deserializeBinaryFromReader(message: LibraryListReq, reader: jspb.BinaryReader): LibraryListReq;
}
export namespace LibraryListReq {
export type AsObject = {
instance?: common_pb.Instance.AsObject,
}
}
export class LibraryListResp extends jspb.Message {
clearLibrariesList(): void;
getLibrariesList(): Array<InstalledLibrary>;
setLibrariesList(value: Array<InstalledLibrary>): void;
addLibraries(value?: InstalledLibrary, index?: number): InstalledLibrary;
serializeBinary(): Uint8Array;
toObject(includeInstance?: boolean): LibraryListResp.AsObject;
static toObject(includeInstance: boolean, msg: LibraryListResp): LibraryListResp.AsObject;
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
static serializeBinaryToWriter(message: LibraryListResp, writer: jspb.BinaryWriter): void;
static deserializeBinary(bytes: Uint8Array): LibraryListResp;
static deserializeBinaryFromReader(message: LibraryListResp, reader: jspb.BinaryReader): LibraryListResp;
}
export namespace LibraryListResp {
export type AsObject = {
librariesList: Array<InstalledLibrary.AsObject>,
}
}
export class InstalledLibrary extends jspb.Message {
getName(): string;
setName(value: string): void;
hasInstalled(): boolean;
clearInstalled(): void;
getInstalled(): LibraryRelease | undefined;
setInstalled(value?: LibraryRelease): void;
serializeBinary(): Uint8Array;
toObject(includeInstance?: boolean): InstalledLibrary.AsObject;
static toObject(includeInstance: boolean, msg: InstalledLibrary): InstalledLibrary.AsObject;
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
static serializeBinaryToWriter(message: InstalledLibrary, writer: jspb.BinaryWriter): void;
static deserializeBinary(bytes: Uint8Array): InstalledLibrary;
static deserializeBinaryFromReader(message: InstalledLibrary, reader: jspb.BinaryReader): InstalledLibrary;
}
export namespace InstalledLibrary {
export type AsObject = {
name: string,
installed?: LibraryRelease.AsObject,
}
}
export class LibraryRelease extends jspb.Message {
getAuthor(): string;
setAuthor(value: string): void;
@ -500,3 +421,216 @@ export namespace DownloadResource {
cachepath: string,
}
}
export class LibraryListReq extends jspb.Message {
hasInstance(): boolean;
clearInstance(): void;
getInstance(): commands_common_pb.Instance | undefined;
setInstance(value?: commands_common_pb.Instance): void;
getAll(): boolean;
setAll(value: boolean): void;
getUpdatable(): boolean;
setUpdatable(value: boolean): void;
serializeBinary(): Uint8Array;
toObject(includeInstance?: boolean): LibraryListReq.AsObject;
static toObject(includeInstance: boolean, msg: LibraryListReq): LibraryListReq.AsObject;
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
static serializeBinaryToWriter(message: LibraryListReq, writer: jspb.BinaryWriter): void;
static deserializeBinary(bytes: Uint8Array): LibraryListReq;
static deserializeBinaryFromReader(message: LibraryListReq, reader: jspb.BinaryReader): LibraryListReq;
}
export namespace LibraryListReq {
export type AsObject = {
instance?: commands_common_pb.Instance.AsObject,
all: boolean,
updatable: boolean,
}
}
export class LibraryListResp extends jspb.Message {
clearInstalledLibraryList(): void;
getInstalledLibraryList(): Array<InstalledLibrary>;
setInstalledLibraryList(value: Array<InstalledLibrary>): void;
addInstalledLibrary(value?: InstalledLibrary, index?: number): InstalledLibrary;
serializeBinary(): Uint8Array;
toObject(includeInstance?: boolean): LibraryListResp.AsObject;
static toObject(includeInstance: boolean, msg: LibraryListResp): LibraryListResp.AsObject;
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
static serializeBinaryToWriter(message: LibraryListResp, writer: jspb.BinaryWriter): void;
static deserializeBinary(bytes: Uint8Array): LibraryListResp;
static deserializeBinaryFromReader(message: LibraryListResp, reader: jspb.BinaryReader): LibraryListResp;
}
export namespace LibraryListResp {
export type AsObject = {
installedLibraryList: Array<InstalledLibrary.AsObject>,
}
}
export class InstalledLibrary extends jspb.Message {
hasLibrary(): boolean;
clearLibrary(): void;
getLibrary(): Library | undefined;
setLibrary(value?: Library): void;
hasRelease(): boolean;
clearRelease(): void;
getRelease(): LibraryRelease | undefined;
setRelease(value?: LibraryRelease): void;
serializeBinary(): Uint8Array;
toObject(includeInstance?: boolean): InstalledLibrary.AsObject;
static toObject(includeInstance: boolean, msg: InstalledLibrary): InstalledLibrary.AsObject;
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
static serializeBinaryToWriter(message: InstalledLibrary, writer: jspb.BinaryWriter): void;
static deserializeBinary(bytes: Uint8Array): InstalledLibrary;
static deserializeBinaryFromReader(message: InstalledLibrary, reader: jspb.BinaryReader): InstalledLibrary;
}
export namespace InstalledLibrary {
export type AsObject = {
library?: Library.AsObject,
release?: LibraryRelease.AsObject,
}
}
export class Library extends jspb.Message {
getName(): string;
setName(value: string): void;
getAuthor(): string;
setAuthor(value: string): void;
getMaintainer(): string;
setMaintainer(value: string): void;
getSentence(): string;
setSentence(value: string): void;
getParagraph(): string;
setParagraph(value: string): void;
getWebsite(): string;
setWebsite(value: string): void;
getCategory(): string;
setCategory(value: string): void;
clearArchitecturesList(): void;
getArchitecturesList(): Array<string>;
setArchitecturesList(value: Array<string>): void;
addArchitectures(value: string, index?: number): string;
clearTypesList(): void;
getTypesList(): Array<string>;
setTypesList(value: Array<string>): void;
addTypes(value: string, index?: number): string;
getInstallDir(): string;
setInstallDir(value: string): void;
getSourceDir(): string;
setSourceDir(value: string): void;
getUtilityDir(): string;
setUtilityDir(value: string): void;
getLocation(): string;
setLocation(value: string): void;
getContainerPlatform(): string;
setContainerPlatform(value: string): void;
getLayout(): string;
setLayout(value: string): void;
getRealName(): string;
setRealName(value: string): void;
getDotALinkage(): boolean;
setDotALinkage(value: boolean): void;
getPrecompiled(): boolean;
setPrecompiled(value: boolean): void;
getLdFlags(): string;
setLdFlags(value: string): void;
getIsLegacy(): boolean;
setIsLegacy(value: boolean): void;
getVersion(): string;
setVersion(value: string): void;
getLicense(): string;
setLicense(value: string): void;
getPropertiesMap(): jspb.Map<string, string>;
clearPropertiesMap(): void;
serializeBinary(): Uint8Array;
toObject(includeInstance?: boolean): Library.AsObject;
static toObject(includeInstance: boolean, msg: Library): Library.AsObject;
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
static serializeBinaryToWriter(message: Library, writer: jspb.BinaryWriter): void;
static deserializeBinary(bytes: Uint8Array): Library;
static deserializeBinaryFromReader(message: Library, reader: jspb.BinaryReader): Library;
}
export namespace Library {
export type AsObject = {
name: string,
author: string,
maintainer: string,
sentence: string,
paragraph: string,
website: string,
category: string,
architecturesList: Array<string>,
typesList: Array<string>,
installDir: string,
sourceDir: string,
utilityDir: string,
location: string,
containerPlatform: string,
layout: string,
realName: string,
dotALinkage: boolean,
precompiled: boolean,
ldFlags: string,
isLegacy: boolean,
version: string,
license: string,
propertiesMap: Array<[string, string]>,
}
}
export enum LibraryLayout {
FLAT_LAYOUT = 0,
RECURSIVE_LAYOUT = 1,
}
export enum LibraryLocation {
IDE_BUILTIN = 0,
PLATFORM_BUILTIN = 1,
REFERENCED_PLATFORM_BUILTIN = 2,
SKETCHBOOK = 3,
}

File diff suppressed because it is too large Load Diff

View File

@ -1,17 +1,17 @@
// package: arduino
// file: upload.proto
// package: cc.arduino.cli.commands
// file: commands/upload.proto
/* tslint:disable */
import * as jspb from "google-protobuf";
import * as common_pb from "./common_pb";
import * as commands_common_pb from "../commands/common_pb";
export class UploadReq extends jspb.Message {
hasInstance(): boolean;
clearInstance(): void;
getInstance(): common_pb.Instance | undefined;
setInstance(value?: common_pb.Instance): void;
getInstance(): commands_common_pb.Instance | undefined;
setInstance(value?: commands_common_pb.Instance): void;
getFqbn(): string;
setFqbn(value: string): void;
@ -44,7 +44,7 @@ export class UploadReq extends jspb.Message {
export namespace UploadReq {
export type AsObject = {
instance?: common_pb.Instance.AsObject,
instance?: commands_common_pb.Instance.AsObject,
fqbn: string,
sketchPath: string,
port: string,

View File

@ -11,10 +11,10 @@ var jspb = require('google-protobuf');
var goog = jspb;
var global = Function('return this')();
var common_pb = require('./common_pb.js');
goog.object.extend(proto, common_pb);
goog.exportSymbol('proto.arduino.UploadReq', null, global);
goog.exportSymbol('proto.arduino.UploadResp', null, global);
var commands_common_pb = require('../commands/common_pb.js');
goog.object.extend(proto, commands_common_pb);
goog.exportSymbol('proto.cc.arduino.cli.commands.UploadReq', null, global);
goog.exportSymbol('proto.cc.arduino.cli.commands.UploadResp', null, global);
/**
* Generated by JsPbCodeGenerator.
@ -26,12 +26,12 @@ goog.exportSymbol('proto.arduino.UploadResp', null, global);
* @extends {jspb.Message}
* @constructor
*/
proto.arduino.UploadReq = function(opt_data) {
proto.cc.arduino.cli.commands.UploadReq = function(opt_data) {
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
};
goog.inherits(proto.arduino.UploadReq, jspb.Message);
goog.inherits(proto.cc.arduino.cli.commands.UploadReq, jspb.Message);
if (goog.DEBUG && !COMPILED) {
proto.arduino.UploadReq.displayName = 'proto.arduino.UploadReq';
proto.cc.arduino.cli.commands.UploadReq.displayName = 'proto.cc.arduino.cli.commands.UploadReq';
}
@ -46,8 +46,8 @@ if (jspb.Message.GENERATE_TO_OBJECT) {
* for transitional soy proto support: http://goto/soy-param-migration
* @return {!Object}
*/
proto.arduino.UploadReq.prototype.toObject = function(opt_includeInstance) {
return proto.arduino.UploadReq.toObject(opt_includeInstance, this);
proto.cc.arduino.cli.commands.UploadReq.prototype.toObject = function(opt_includeInstance) {
return proto.cc.arduino.cli.commands.UploadReq.toObject(opt_includeInstance, this);
};
@ -56,13 +56,13 @@ proto.arduino.UploadReq.prototype.toObject = function(opt_includeInstance) {
* @param {boolean|undefined} includeInstance Whether to include the JSPB
* instance for transitional soy proto support:
* http://goto/soy-param-migration
* @param {!proto.arduino.UploadReq} msg The msg instance to transform.
* @param {!proto.cc.arduino.cli.commands.UploadReq} msg The msg instance to transform.
* @return {!Object}
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.arduino.UploadReq.toObject = function(includeInstance, msg) {
proto.cc.arduino.cli.commands.UploadReq.toObject = function(includeInstance, msg) {
var f, obj = {
instance: (f = msg.getInstance()) && common_pb.Instance.toObject(includeInstance, f),
instance: (f = msg.getInstance()) && commands_common_pb.Instance.toObject(includeInstance, f),
fqbn: jspb.Message.getFieldWithDefault(msg, 2, ""),
sketchPath: jspb.Message.getFieldWithDefault(msg, 3, ""),
port: jspb.Message.getFieldWithDefault(msg, 4, ""),
@ -82,23 +82,23 @@ proto.arduino.UploadReq.toObject = function(includeInstance, msg) {
/**
* Deserializes binary data (in protobuf wire format).
* @param {jspb.ByteSource} bytes The bytes to deserialize.
* @return {!proto.arduino.UploadReq}
* @return {!proto.cc.arduino.cli.commands.UploadReq}
*/
proto.arduino.UploadReq.deserializeBinary = function(bytes) {
proto.cc.arduino.cli.commands.UploadReq.deserializeBinary = function(bytes) {
var reader = new jspb.BinaryReader(bytes);
var msg = new proto.arduino.UploadReq;
return proto.arduino.UploadReq.deserializeBinaryFromReader(msg, reader);
var msg = new proto.cc.arduino.cli.commands.UploadReq;
return proto.cc.arduino.cli.commands.UploadReq.deserializeBinaryFromReader(msg, reader);
};
/**
* Deserializes binary data (in protobuf wire format) from the
* given reader into the given message object.
* @param {!proto.arduino.UploadReq} msg The message object to deserialize into.
* @param {!proto.cc.arduino.cli.commands.UploadReq} msg The message object to deserialize into.
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
* @return {!proto.arduino.UploadReq}
* @return {!proto.cc.arduino.cli.commands.UploadReq}
*/
proto.arduino.UploadReq.deserializeBinaryFromReader = function(msg, reader) {
proto.cc.arduino.cli.commands.UploadReq.deserializeBinaryFromReader = function(msg, reader) {
while (reader.nextField()) {
if (reader.isEndGroup()) {
break;
@ -106,8 +106,8 @@ proto.arduino.UploadReq.deserializeBinaryFromReader = function(msg, reader) {
var field = reader.getFieldNumber();
switch (field) {
case 1:
var value = new common_pb.Instance;
reader.readMessage(value,common_pb.Instance.deserializeBinaryFromReader);
var value = new commands_common_pb.Instance;
reader.readMessage(value,commands_common_pb.Instance.deserializeBinaryFromReader);
msg.setInstance(value);
break;
case 2:
@ -147,9 +147,9 @@ proto.arduino.UploadReq.deserializeBinaryFromReader = function(msg, reader) {
* Serializes the message to binary data (in protobuf wire format).
* @return {!Uint8Array}
*/
proto.arduino.UploadReq.prototype.serializeBinary = function() {
proto.cc.arduino.cli.commands.UploadReq.prototype.serializeBinary = function() {
var writer = new jspb.BinaryWriter();
proto.arduino.UploadReq.serializeBinaryToWriter(this, writer);
proto.cc.arduino.cli.commands.UploadReq.serializeBinaryToWriter(this, writer);
return writer.getResultBuffer();
};
@ -157,18 +157,18 @@ proto.arduino.UploadReq.prototype.serializeBinary = function() {
/**
* Serializes the given message to binary data (in protobuf wire
* format), writing to the given BinaryWriter.
* @param {!proto.arduino.UploadReq} message
* @param {!proto.cc.arduino.cli.commands.UploadReq} message
* @param {!jspb.BinaryWriter} writer
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.arduino.UploadReq.serializeBinaryToWriter = function(message, writer) {
proto.cc.arduino.cli.commands.UploadReq.serializeBinaryToWriter = function(message, writer) {
var f = undefined;
f = message.getInstance();
if (f != null) {
writer.writeMessage(
1,
f,
common_pb.Instance.serializeBinaryToWriter
commands_common_pb.Instance.serializeBinaryToWriter
);
}
f = message.getFqbn();
@ -218,21 +218,21 @@ proto.arduino.UploadReq.serializeBinaryToWriter = function(message, writer) {
/**
* optional Instance instance = 1;
* @return {?proto.arduino.Instance}
* @return {?proto.cc.arduino.cli.commands.Instance}
*/
proto.arduino.UploadReq.prototype.getInstance = function() {
return /** @type{?proto.arduino.Instance} */ (
jspb.Message.getWrapperField(this, common_pb.Instance, 1));
proto.cc.arduino.cli.commands.UploadReq.prototype.getInstance = function() {
return /** @type{?proto.cc.arduino.cli.commands.Instance} */ (
jspb.Message.getWrapperField(this, commands_common_pb.Instance, 1));
};
/** @param {?proto.arduino.Instance|undefined} value */
proto.arduino.UploadReq.prototype.setInstance = function(value) {
/** @param {?proto.cc.arduino.cli.commands.Instance|undefined} value */
proto.cc.arduino.cli.commands.UploadReq.prototype.setInstance = function(value) {
jspb.Message.setWrapperField(this, 1, value);
};
proto.arduino.UploadReq.prototype.clearInstance = function() {
proto.cc.arduino.cli.commands.UploadReq.prototype.clearInstance = function() {
this.setInstance(undefined);
};
@ -241,7 +241,7 @@ proto.arduino.UploadReq.prototype.clearInstance = function() {
* Returns whether this field is set.
* @return {boolean}
*/
proto.arduino.UploadReq.prototype.hasInstance = function() {
proto.cc.arduino.cli.commands.UploadReq.prototype.hasInstance = function() {
return jspb.Message.getField(this, 1) != null;
};
@ -250,13 +250,13 @@ proto.arduino.UploadReq.prototype.hasInstance = function() {
* optional string fqbn = 2;
* @return {string}
*/
proto.arduino.UploadReq.prototype.getFqbn = function() {
proto.cc.arduino.cli.commands.UploadReq.prototype.getFqbn = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
};
/** @param {string} value */
proto.arduino.UploadReq.prototype.setFqbn = function(value) {
proto.cc.arduino.cli.commands.UploadReq.prototype.setFqbn = function(value) {
jspb.Message.setProto3StringField(this, 2, value);
};
@ -265,13 +265,13 @@ proto.arduino.UploadReq.prototype.setFqbn = function(value) {
* optional string sketch_path = 3;
* @return {string}
*/
proto.arduino.UploadReq.prototype.getSketchPath = function() {
proto.cc.arduino.cli.commands.UploadReq.prototype.getSketchPath = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 3, ""));
};
/** @param {string} value */
proto.arduino.UploadReq.prototype.setSketchPath = function(value) {
proto.cc.arduino.cli.commands.UploadReq.prototype.setSketchPath = function(value) {
jspb.Message.setProto3StringField(this, 3, value);
};
@ -280,13 +280,13 @@ proto.arduino.UploadReq.prototype.setSketchPath = function(value) {
* optional string port = 4;
* @return {string}
*/
proto.arduino.UploadReq.prototype.getPort = function() {
proto.cc.arduino.cli.commands.UploadReq.prototype.getPort = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 4, ""));
};
/** @param {string} value */
proto.arduino.UploadReq.prototype.setPort = function(value) {
proto.cc.arduino.cli.commands.UploadReq.prototype.setPort = function(value) {
jspb.Message.setProto3StringField(this, 4, value);
};
@ -297,13 +297,13 @@ proto.arduino.UploadReq.prototype.setPort = function(value) {
* You should avoid comparisons like {@code val === true/false} in those cases.
* @return {boolean}
*/
proto.arduino.UploadReq.prototype.getVerbose = function() {
proto.cc.arduino.cli.commands.UploadReq.prototype.getVerbose = function() {
return /** @type {boolean} */ (jspb.Message.getFieldWithDefault(this, 5, false));
};
/** @param {boolean} value */
proto.arduino.UploadReq.prototype.setVerbose = function(value) {
proto.cc.arduino.cli.commands.UploadReq.prototype.setVerbose = function(value) {
jspb.Message.setProto3BooleanField(this, 5, value);
};
@ -314,13 +314,13 @@ proto.arduino.UploadReq.prototype.setVerbose = function(value) {
* You should avoid comparisons like {@code val === true/false} in those cases.
* @return {boolean}
*/
proto.arduino.UploadReq.prototype.getVerify = function() {
proto.cc.arduino.cli.commands.UploadReq.prototype.getVerify = function() {
return /** @type {boolean} */ (jspb.Message.getFieldWithDefault(this, 6, false));
};
/** @param {boolean} value */
proto.arduino.UploadReq.prototype.setVerify = function(value) {
proto.cc.arduino.cli.commands.UploadReq.prototype.setVerify = function(value) {
jspb.Message.setProto3BooleanField(this, 6, value);
};
@ -329,13 +329,13 @@ proto.arduino.UploadReq.prototype.setVerify = function(value) {
* optional string import_file = 7;
* @return {string}
*/
proto.arduino.UploadReq.prototype.getImportFile = function() {
proto.cc.arduino.cli.commands.UploadReq.prototype.getImportFile = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 7, ""));
};
/** @param {string} value */
proto.arduino.UploadReq.prototype.setImportFile = function(value) {
proto.cc.arduino.cli.commands.UploadReq.prototype.setImportFile = function(value) {
jspb.Message.setProto3StringField(this, 7, value);
};
@ -351,12 +351,12 @@ proto.arduino.UploadReq.prototype.setImportFile = function(value) {
* @extends {jspb.Message}
* @constructor
*/
proto.arduino.UploadResp = function(opt_data) {
proto.cc.arduino.cli.commands.UploadResp = function(opt_data) {
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
};
goog.inherits(proto.arduino.UploadResp, jspb.Message);
goog.inherits(proto.cc.arduino.cli.commands.UploadResp, jspb.Message);
if (goog.DEBUG && !COMPILED) {
proto.arduino.UploadResp.displayName = 'proto.arduino.UploadResp';
proto.cc.arduino.cli.commands.UploadResp.displayName = 'proto.cc.arduino.cli.commands.UploadResp';
}
@ -371,8 +371,8 @@ if (jspb.Message.GENERATE_TO_OBJECT) {
* for transitional soy proto support: http://goto/soy-param-migration
* @return {!Object}
*/
proto.arduino.UploadResp.prototype.toObject = function(opt_includeInstance) {
return proto.arduino.UploadResp.toObject(opt_includeInstance, this);
proto.cc.arduino.cli.commands.UploadResp.prototype.toObject = function(opt_includeInstance) {
return proto.cc.arduino.cli.commands.UploadResp.toObject(opt_includeInstance, this);
};
@ -381,11 +381,11 @@ proto.arduino.UploadResp.prototype.toObject = function(opt_includeInstance) {
* @param {boolean|undefined} includeInstance Whether to include the JSPB
* instance for transitional soy proto support:
* http://goto/soy-param-migration
* @param {!proto.arduino.UploadResp} msg The msg instance to transform.
* @param {!proto.cc.arduino.cli.commands.UploadResp} msg The msg instance to transform.
* @return {!Object}
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.arduino.UploadResp.toObject = function(includeInstance, msg) {
proto.cc.arduino.cli.commands.UploadResp.toObject = function(includeInstance, msg) {
var f, obj = {
outStream: msg.getOutStream_asB64(),
errStream: msg.getErrStream_asB64()
@ -402,23 +402,23 @@ proto.arduino.UploadResp.toObject = function(includeInstance, msg) {
/**
* Deserializes binary data (in protobuf wire format).
* @param {jspb.ByteSource} bytes The bytes to deserialize.
* @return {!proto.arduino.UploadResp}
* @return {!proto.cc.arduino.cli.commands.UploadResp}
*/
proto.arduino.UploadResp.deserializeBinary = function(bytes) {
proto.cc.arduino.cli.commands.UploadResp.deserializeBinary = function(bytes) {
var reader = new jspb.BinaryReader(bytes);
var msg = new proto.arduino.UploadResp;
return proto.arduino.UploadResp.deserializeBinaryFromReader(msg, reader);
var msg = new proto.cc.arduino.cli.commands.UploadResp;
return proto.cc.arduino.cli.commands.UploadResp.deserializeBinaryFromReader(msg, reader);
};
/**
* Deserializes binary data (in protobuf wire format) from the
* given reader into the given message object.
* @param {!proto.arduino.UploadResp} msg The message object to deserialize into.
* @param {!proto.cc.arduino.cli.commands.UploadResp} msg The message object to deserialize into.
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
* @return {!proto.arduino.UploadResp}
* @return {!proto.cc.arduino.cli.commands.UploadResp}
*/
proto.arduino.UploadResp.deserializeBinaryFromReader = function(msg, reader) {
proto.cc.arduino.cli.commands.UploadResp.deserializeBinaryFromReader = function(msg, reader) {
while (reader.nextField()) {
if (reader.isEndGroup()) {
break;
@ -446,9 +446,9 @@ proto.arduino.UploadResp.deserializeBinaryFromReader = function(msg, reader) {
* Serializes the message to binary data (in protobuf wire format).
* @return {!Uint8Array}
*/
proto.arduino.UploadResp.prototype.serializeBinary = function() {
proto.cc.arduino.cli.commands.UploadResp.prototype.serializeBinary = function() {
var writer = new jspb.BinaryWriter();
proto.arduino.UploadResp.serializeBinaryToWriter(this, writer);
proto.cc.arduino.cli.commands.UploadResp.serializeBinaryToWriter(this, writer);
return writer.getResultBuffer();
};
@ -456,11 +456,11 @@ proto.arduino.UploadResp.prototype.serializeBinary = function() {
/**
* Serializes the given message to binary data (in protobuf wire
* format), writing to the given BinaryWriter.
* @param {!proto.arduino.UploadResp} message
* @param {!proto.cc.arduino.cli.commands.UploadResp} message
* @param {!jspb.BinaryWriter} writer
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.arduino.UploadResp.serializeBinaryToWriter = function(message, writer) {
proto.cc.arduino.cli.commands.UploadResp.serializeBinaryToWriter = function(message, writer) {
var f = undefined;
f = message.getOutStream_asU8();
if (f.length > 0) {
@ -483,7 +483,7 @@ proto.arduino.UploadResp.serializeBinaryToWriter = function(message, writer) {
* optional bytes out_stream = 1;
* @return {!(string|Uint8Array)}
*/
proto.arduino.UploadResp.prototype.getOutStream = function() {
proto.cc.arduino.cli.commands.UploadResp.prototype.getOutStream = function() {
return /** @type {!(string|Uint8Array)} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
};
@ -493,7 +493,7 @@ proto.arduino.UploadResp.prototype.getOutStream = function() {
* This is a type-conversion wrapper around `getOutStream()`
* @return {string}
*/
proto.arduino.UploadResp.prototype.getOutStream_asB64 = function() {
proto.cc.arduino.cli.commands.UploadResp.prototype.getOutStream_asB64 = function() {
return /** @type {string} */ (jspb.Message.bytesAsB64(
this.getOutStream()));
};
@ -506,14 +506,14 @@ proto.arduino.UploadResp.prototype.getOutStream_asB64 = function() {
* This is a type-conversion wrapper around `getOutStream()`
* @return {!Uint8Array}
*/
proto.arduino.UploadResp.prototype.getOutStream_asU8 = function() {
proto.cc.arduino.cli.commands.UploadResp.prototype.getOutStream_asU8 = function() {
return /** @type {!Uint8Array} */ (jspb.Message.bytesAsU8(
this.getOutStream()));
};
/** @param {!(string|Uint8Array)} value */
proto.arduino.UploadResp.prototype.setOutStream = function(value) {
proto.cc.arduino.cli.commands.UploadResp.prototype.setOutStream = function(value) {
jspb.Message.setProto3BytesField(this, 1, value);
};
@ -522,7 +522,7 @@ proto.arduino.UploadResp.prototype.setOutStream = function(value) {
* optional bytes err_stream = 2;
* @return {!(string|Uint8Array)}
*/
proto.arduino.UploadResp.prototype.getErrStream = function() {
proto.cc.arduino.cli.commands.UploadResp.prototype.getErrStream = function() {
return /** @type {!(string|Uint8Array)} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
};
@ -532,7 +532,7 @@ proto.arduino.UploadResp.prototype.getErrStream = function() {
* This is a type-conversion wrapper around `getErrStream()`
* @return {string}
*/
proto.arduino.UploadResp.prototype.getErrStream_asB64 = function() {
proto.cc.arduino.cli.commands.UploadResp.prototype.getErrStream_asB64 = function() {
return /** @type {string} */ (jspb.Message.bytesAsB64(
this.getErrStream()));
};
@ -545,16 +545,16 @@ proto.arduino.UploadResp.prototype.getErrStream_asB64 = function() {
* This is a type-conversion wrapper around `getErrStream()`
* @return {!Uint8Array}
*/
proto.arduino.UploadResp.prototype.getErrStream_asU8 = function() {
proto.cc.arduino.cli.commands.UploadResp.prototype.getErrStream_asU8 = function() {
return /** @type {!Uint8Array} */ (jspb.Message.bytesAsU8(
this.getErrStream()));
};
/** @param {!(string|Uint8Array)} value */
proto.arduino.UploadResp.prototype.setErrStream = function(value) {
proto.cc.arduino.cli.commands.UploadResp.prototype.setErrStream = function(value) {
jspb.Message.setProto3BytesField(this, 2, value);
};
goog.object.extend(exports, proto.arduino);
goog.object.extend(exports, proto.cc.arduino.cli.commands);

View File

@ -1,347 +0,0 @@
// package: arduino
// file: commands.proto
/* tslint:disable */
import * as grpc from "@grpc/grpc-js";
import * as commands_pb from "./commands_pb";
import * as common_pb from "./common_pb";
import * as board_pb from "./board_pb";
import * as compile_pb from "./compile_pb";
import * as core_pb from "./core_pb";
import * as upload_pb from "./upload_pb";
import * as lib_pb from "./lib_pb";
interface IArduinoCoreService extends grpc.ServiceDefinition<grpc.UntypedServiceImplementation> {
init: IArduinoCoreService_IInit;
destroy: IArduinoCoreService_IDestroy;
rescan: IArduinoCoreService_IRescan;
updateIndex: IArduinoCoreService_IUpdateIndex;
boardList: IArduinoCoreService_IBoardList;
boardDetails: IArduinoCoreService_IBoardDetails;
compile: IArduinoCoreService_ICompile;
platformInstall: IArduinoCoreService_IPlatformInstall;
platformDownload: IArduinoCoreService_IPlatformDownload;
platformUninstall: IArduinoCoreService_IPlatformUninstall;
platformUpgrade: IArduinoCoreService_IPlatformUpgrade;
upload: IArduinoCoreService_IUpload;
platformSearch: IArduinoCoreService_IPlatformSearch;
platformList: IArduinoCoreService_IPlatformList;
libraryDownload: IArduinoCoreService_ILibraryDownload;
libraryInstall: IArduinoCoreService_ILibraryInstall;
libraryUninstall: IArduinoCoreService_ILibraryUninstall;
libraryUpgradeAll: IArduinoCoreService_ILibraryUpgradeAll;
librarySearch: IArduinoCoreService_ILibrarySearch;
libraryList: IArduinoCoreService_ILibraryList;
}
interface IArduinoCoreService_IInit extends grpc.MethodDefinition<commands_pb.InitReq, commands_pb.InitResp> {
path: string; // "/arduino.ArduinoCore/Init"
requestStream: boolean; // false
responseStream: boolean; // false
requestSerialize: grpc.serialize<commands_pb.InitReq>;
requestDeserialize: grpc.deserialize<commands_pb.InitReq>;
responseSerialize: grpc.serialize<commands_pb.InitResp>;
responseDeserialize: grpc.deserialize<commands_pb.InitResp>;
}
interface IArduinoCoreService_IDestroy extends grpc.MethodDefinition<commands_pb.DestroyReq, commands_pb.DestroyResp> {
path: string; // "/arduino.ArduinoCore/Destroy"
requestStream: boolean; // false
responseStream: boolean; // false
requestSerialize: grpc.serialize<commands_pb.DestroyReq>;
requestDeserialize: grpc.deserialize<commands_pb.DestroyReq>;
responseSerialize: grpc.serialize<commands_pb.DestroyResp>;
responseDeserialize: grpc.deserialize<commands_pb.DestroyResp>;
}
interface IArduinoCoreService_IRescan extends grpc.MethodDefinition<commands_pb.RescanReq, commands_pb.RescanResp> {
path: string; // "/arduino.ArduinoCore/Rescan"
requestStream: boolean; // false
responseStream: boolean; // false
requestSerialize: grpc.serialize<commands_pb.RescanReq>;
requestDeserialize: grpc.deserialize<commands_pb.RescanReq>;
responseSerialize: grpc.serialize<commands_pb.RescanResp>;
responseDeserialize: grpc.deserialize<commands_pb.RescanResp>;
}
interface IArduinoCoreService_IUpdateIndex extends grpc.MethodDefinition<commands_pb.UpdateIndexReq, commands_pb.UpdateIndexResp> {
path: string; // "/arduino.ArduinoCore/UpdateIndex"
requestStream: boolean; // false
responseStream: boolean; // true
requestSerialize: grpc.serialize<commands_pb.UpdateIndexReq>;
requestDeserialize: grpc.deserialize<commands_pb.UpdateIndexReq>;
responseSerialize: grpc.serialize<commands_pb.UpdateIndexResp>;
responseDeserialize: grpc.deserialize<commands_pb.UpdateIndexResp>;
}
interface IArduinoCoreService_IBoardList extends grpc.MethodDefinition<board_pb.BoardListReq, board_pb.BoardListResp> {
path: string; // "/arduino.ArduinoCore/BoardList"
requestStream: boolean; // false
responseStream: boolean; // false
requestSerialize: grpc.serialize<board_pb.BoardListReq>;
requestDeserialize: grpc.deserialize<board_pb.BoardListReq>;
responseSerialize: grpc.serialize<board_pb.BoardListResp>;
responseDeserialize: grpc.deserialize<board_pb.BoardListResp>;
}
interface IArduinoCoreService_IBoardDetails extends grpc.MethodDefinition<board_pb.BoardDetailsReq, board_pb.BoardDetailsResp> {
path: string; // "/arduino.ArduinoCore/BoardDetails"
requestStream: boolean; // false
responseStream: boolean; // false
requestSerialize: grpc.serialize<board_pb.BoardDetailsReq>;
requestDeserialize: grpc.deserialize<board_pb.BoardDetailsReq>;
responseSerialize: grpc.serialize<board_pb.BoardDetailsResp>;
responseDeserialize: grpc.deserialize<board_pb.BoardDetailsResp>;
}
interface IArduinoCoreService_ICompile extends grpc.MethodDefinition<compile_pb.CompileReq, compile_pb.CompileResp> {
path: string; // "/arduino.ArduinoCore/Compile"
requestStream: boolean; // false
responseStream: boolean; // true
requestSerialize: grpc.serialize<compile_pb.CompileReq>;
requestDeserialize: grpc.deserialize<compile_pb.CompileReq>;
responseSerialize: grpc.serialize<compile_pb.CompileResp>;
responseDeserialize: grpc.deserialize<compile_pb.CompileResp>;
}
interface IArduinoCoreService_IPlatformInstall extends grpc.MethodDefinition<core_pb.PlatformInstallReq, core_pb.PlatformInstallResp> {
path: string; // "/arduino.ArduinoCore/PlatformInstall"
requestStream: boolean; // false
responseStream: boolean; // true
requestSerialize: grpc.serialize<core_pb.PlatformInstallReq>;
requestDeserialize: grpc.deserialize<core_pb.PlatformInstallReq>;
responseSerialize: grpc.serialize<core_pb.PlatformInstallResp>;
responseDeserialize: grpc.deserialize<core_pb.PlatformInstallResp>;
}
interface IArduinoCoreService_IPlatformDownload extends grpc.MethodDefinition<core_pb.PlatformDownloadReq, core_pb.PlatformDownloadResp> {
path: string; // "/arduino.ArduinoCore/PlatformDownload"
requestStream: boolean; // false
responseStream: boolean; // true
requestSerialize: grpc.serialize<core_pb.PlatformDownloadReq>;
requestDeserialize: grpc.deserialize<core_pb.PlatformDownloadReq>;
responseSerialize: grpc.serialize<core_pb.PlatformDownloadResp>;
responseDeserialize: grpc.deserialize<core_pb.PlatformDownloadResp>;
}
interface IArduinoCoreService_IPlatformUninstall extends grpc.MethodDefinition<core_pb.PlatformUninstallReq, core_pb.PlatformUninstallResp> {
path: string; // "/arduino.ArduinoCore/PlatformUninstall"
requestStream: boolean; // false
responseStream: boolean; // true
requestSerialize: grpc.serialize<core_pb.PlatformUninstallReq>;
requestDeserialize: grpc.deserialize<core_pb.PlatformUninstallReq>;
responseSerialize: grpc.serialize<core_pb.PlatformUninstallResp>;
responseDeserialize: grpc.deserialize<core_pb.PlatformUninstallResp>;
}
interface IArduinoCoreService_IPlatformUpgrade extends grpc.MethodDefinition<core_pb.PlatformUpgradeReq, core_pb.PlatformUpgradeResp> {
path: string; // "/arduino.ArduinoCore/PlatformUpgrade"
requestStream: boolean; // false
responseStream: boolean; // true
requestSerialize: grpc.serialize<core_pb.PlatformUpgradeReq>;
requestDeserialize: grpc.deserialize<core_pb.PlatformUpgradeReq>;
responseSerialize: grpc.serialize<core_pb.PlatformUpgradeResp>;
responseDeserialize: grpc.deserialize<core_pb.PlatformUpgradeResp>;
}
interface IArduinoCoreService_IUpload extends grpc.MethodDefinition<upload_pb.UploadReq, upload_pb.UploadResp> {
path: string; // "/arduino.ArduinoCore/Upload"
requestStream: boolean; // false
responseStream: boolean; // true
requestSerialize: grpc.serialize<upload_pb.UploadReq>;
requestDeserialize: grpc.deserialize<upload_pb.UploadReq>;
responseSerialize: grpc.serialize<upload_pb.UploadResp>;
responseDeserialize: grpc.deserialize<upload_pb.UploadResp>;
}
interface IArduinoCoreService_IPlatformSearch extends grpc.MethodDefinition<core_pb.PlatformSearchReq, core_pb.PlatformSearchResp> {
path: string; // "/arduino.ArduinoCore/PlatformSearch"
requestStream: boolean; // false
responseStream: boolean; // false
requestSerialize: grpc.serialize<core_pb.PlatformSearchReq>;
requestDeserialize: grpc.deserialize<core_pb.PlatformSearchReq>;
responseSerialize: grpc.serialize<core_pb.PlatformSearchResp>;
responseDeserialize: grpc.deserialize<core_pb.PlatformSearchResp>;
}
interface IArduinoCoreService_IPlatformList extends grpc.MethodDefinition<core_pb.PlatformListReq, core_pb.PlatformListResp> {
path: string; // "/arduino.ArduinoCore/PlatformList"
requestStream: boolean; // false
responseStream: boolean; // false
requestSerialize: grpc.serialize<core_pb.PlatformListReq>;
requestDeserialize: grpc.deserialize<core_pb.PlatformListReq>;
responseSerialize: grpc.serialize<core_pb.PlatformListResp>;
responseDeserialize: grpc.deserialize<core_pb.PlatformListResp>;
}
interface IArduinoCoreService_ILibraryDownload extends grpc.MethodDefinition<lib_pb.LibraryDownloadReq, lib_pb.LibraryDownloadResp> {
path: string; // "/arduino.ArduinoCore/LibraryDownload"
requestStream: boolean; // false
responseStream: boolean; // true
requestSerialize: grpc.serialize<lib_pb.LibraryDownloadReq>;
requestDeserialize: grpc.deserialize<lib_pb.LibraryDownloadReq>;
responseSerialize: grpc.serialize<lib_pb.LibraryDownloadResp>;
responseDeserialize: grpc.deserialize<lib_pb.LibraryDownloadResp>;
}
interface IArduinoCoreService_ILibraryInstall extends grpc.MethodDefinition<lib_pb.LibraryInstallReq, lib_pb.LibraryInstallResp> {
path: string; // "/arduino.ArduinoCore/LibraryInstall"
requestStream: boolean; // false
responseStream: boolean; // true
requestSerialize: grpc.serialize<lib_pb.LibraryInstallReq>;
requestDeserialize: grpc.deserialize<lib_pb.LibraryInstallReq>;
responseSerialize: grpc.serialize<lib_pb.LibraryInstallResp>;
responseDeserialize: grpc.deserialize<lib_pb.LibraryInstallResp>;
}
interface IArduinoCoreService_ILibraryUninstall extends grpc.MethodDefinition<lib_pb.LibraryUninstallReq, lib_pb.LibraryUninstallResp> {
path: string; // "/arduino.ArduinoCore/LibraryUninstall"
requestStream: boolean; // false
responseStream: boolean; // true
requestSerialize: grpc.serialize<lib_pb.LibraryUninstallReq>;
requestDeserialize: grpc.deserialize<lib_pb.LibraryUninstallReq>;
responseSerialize: grpc.serialize<lib_pb.LibraryUninstallResp>;
responseDeserialize: grpc.deserialize<lib_pb.LibraryUninstallResp>;
}
interface IArduinoCoreService_ILibraryUpgradeAll extends grpc.MethodDefinition<lib_pb.LibraryUpgradeAllReq, lib_pb.LibraryUpgradeAllResp> {
path: string; // "/arduino.ArduinoCore/LibraryUpgradeAll"
requestStream: boolean; // false
responseStream: boolean; // true
requestSerialize: grpc.serialize<lib_pb.LibraryUpgradeAllReq>;
requestDeserialize: grpc.deserialize<lib_pb.LibraryUpgradeAllReq>;
responseSerialize: grpc.serialize<lib_pb.LibraryUpgradeAllResp>;
responseDeserialize: grpc.deserialize<lib_pb.LibraryUpgradeAllResp>;
}
interface IArduinoCoreService_ILibrarySearch extends grpc.MethodDefinition<lib_pb.LibrarySearchReq, lib_pb.LibrarySearchResp> {
path: string; // "/arduino.ArduinoCore/LibrarySearch"
requestStream: boolean; // false
responseStream: boolean; // false
requestSerialize: grpc.serialize<lib_pb.LibrarySearchReq>;
requestDeserialize: grpc.deserialize<lib_pb.LibrarySearchReq>;
responseSerialize: grpc.serialize<lib_pb.LibrarySearchResp>;
responseDeserialize: grpc.deserialize<lib_pb.LibrarySearchResp>;
}
interface IArduinoCoreService_ILibraryList extends grpc.MethodDefinition<lib_pb.LibraryListReq, lib_pb.LibraryListResp> {
path: string; // "/arduino.ArduinoCore/LibraryList"
requestStream: boolean; // false
responseStream: boolean; // false
requestSerialize: grpc.serialize<lib_pb.LibraryListReq>;
requestDeserialize: grpc.deserialize<lib_pb.LibraryListReq>;
responseSerialize: grpc.serialize<lib_pb.LibraryListResp>;
responseDeserialize: grpc.deserialize<lib_pb.LibraryListResp>;
}
export const ArduinoCoreService: IArduinoCoreService;
export interface IArduinoCoreServer {
init: grpc.handleUnaryCall<commands_pb.InitReq, commands_pb.InitResp>;
destroy: grpc.handleUnaryCall<commands_pb.DestroyReq, commands_pb.DestroyResp>;
rescan: grpc.handleUnaryCall<commands_pb.RescanReq, commands_pb.RescanResp>;
updateIndex: grpc.handleServerStreamingCall<commands_pb.UpdateIndexReq, commands_pb.UpdateIndexResp>;
boardList: grpc.handleUnaryCall<board_pb.BoardListReq, board_pb.BoardListResp>;
boardDetails: grpc.handleUnaryCall<board_pb.BoardDetailsReq, board_pb.BoardDetailsResp>;
compile: grpc.handleServerStreamingCall<compile_pb.CompileReq, compile_pb.CompileResp>;
platformInstall: grpc.handleServerStreamingCall<core_pb.PlatformInstallReq, core_pb.PlatformInstallResp>;
platformDownload: grpc.handleServerStreamingCall<core_pb.PlatformDownloadReq, core_pb.PlatformDownloadResp>;
platformUninstall: grpc.handleServerStreamingCall<core_pb.PlatformUninstallReq, core_pb.PlatformUninstallResp>;
platformUpgrade: grpc.handleServerStreamingCall<core_pb.PlatformUpgradeReq, core_pb.PlatformUpgradeResp>;
upload: grpc.handleServerStreamingCall<upload_pb.UploadReq, upload_pb.UploadResp>;
platformSearch: grpc.handleUnaryCall<core_pb.PlatformSearchReq, core_pb.PlatformSearchResp>;
platformList: grpc.handleUnaryCall<core_pb.PlatformListReq, core_pb.PlatformListResp>;
libraryDownload: grpc.handleServerStreamingCall<lib_pb.LibraryDownloadReq, lib_pb.LibraryDownloadResp>;
libraryInstall: grpc.handleServerStreamingCall<lib_pb.LibraryInstallReq, lib_pb.LibraryInstallResp>;
libraryUninstall: grpc.handleServerStreamingCall<lib_pb.LibraryUninstallReq, lib_pb.LibraryUninstallResp>;
libraryUpgradeAll: grpc.handleServerStreamingCall<lib_pb.LibraryUpgradeAllReq, lib_pb.LibraryUpgradeAllResp>;
librarySearch: grpc.handleUnaryCall<lib_pb.LibrarySearchReq, lib_pb.LibrarySearchResp>;
libraryList: grpc.handleUnaryCall<lib_pb.LibraryListReq, lib_pb.LibraryListResp>;
}
export interface IArduinoCoreClient {
init(request: commands_pb.InitReq, callback: (error: grpc.ServiceError | null, response: commands_pb.InitResp) => void): grpc.ClientUnaryCall;
init(request: commands_pb.InitReq, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: commands_pb.InitResp) => void): grpc.ClientUnaryCall;
init(request: commands_pb.InitReq, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: commands_pb.InitResp) => void): grpc.ClientUnaryCall;
destroy(request: commands_pb.DestroyReq, callback: (error: grpc.ServiceError | null, response: commands_pb.DestroyResp) => void): grpc.ClientUnaryCall;
destroy(request: commands_pb.DestroyReq, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: commands_pb.DestroyResp) => void): grpc.ClientUnaryCall;
destroy(request: commands_pb.DestroyReq, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: commands_pb.DestroyResp) => void): grpc.ClientUnaryCall;
rescan(request: commands_pb.RescanReq, callback: (error: grpc.ServiceError | null, response: commands_pb.RescanResp) => void): grpc.ClientUnaryCall;
rescan(request: commands_pb.RescanReq, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: commands_pb.RescanResp) => void): grpc.ClientUnaryCall;
rescan(request: commands_pb.RescanReq, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: commands_pb.RescanResp) => void): grpc.ClientUnaryCall;
updateIndex(request: commands_pb.UpdateIndexReq, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_pb.UpdateIndexResp>;
updateIndex(request: commands_pb.UpdateIndexReq, metadata?: grpc.Metadata, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_pb.UpdateIndexResp>;
boardList(request: board_pb.BoardListReq, callback: (error: grpc.ServiceError | null, response: board_pb.BoardListResp) => void): grpc.ClientUnaryCall;
boardList(request: board_pb.BoardListReq, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: board_pb.BoardListResp) => void): grpc.ClientUnaryCall;
boardList(request: board_pb.BoardListReq, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: board_pb.BoardListResp) => void): grpc.ClientUnaryCall;
boardDetails(request: board_pb.BoardDetailsReq, callback: (error: grpc.ServiceError | null, response: board_pb.BoardDetailsResp) => void): grpc.ClientUnaryCall;
boardDetails(request: board_pb.BoardDetailsReq, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: board_pb.BoardDetailsResp) => void): grpc.ClientUnaryCall;
boardDetails(request: board_pb.BoardDetailsReq, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: board_pb.BoardDetailsResp) => void): grpc.ClientUnaryCall;
compile(request: compile_pb.CompileReq, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<compile_pb.CompileResp>;
compile(request: compile_pb.CompileReq, metadata?: grpc.Metadata, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<compile_pb.CompileResp>;
platformInstall(request: core_pb.PlatformInstallReq, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<core_pb.PlatformInstallResp>;
platformInstall(request: core_pb.PlatformInstallReq, metadata?: grpc.Metadata, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<core_pb.PlatformInstallResp>;
platformDownload(request: core_pb.PlatformDownloadReq, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<core_pb.PlatformDownloadResp>;
platformDownload(request: core_pb.PlatformDownloadReq, metadata?: grpc.Metadata, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<core_pb.PlatformDownloadResp>;
platformUninstall(request: core_pb.PlatformUninstallReq, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<core_pb.PlatformUninstallResp>;
platformUninstall(request: core_pb.PlatformUninstallReq, metadata?: grpc.Metadata, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<core_pb.PlatformUninstallResp>;
platformUpgrade(request: core_pb.PlatformUpgradeReq, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<core_pb.PlatformUpgradeResp>;
platformUpgrade(request: core_pb.PlatformUpgradeReq, metadata?: grpc.Metadata, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<core_pb.PlatformUpgradeResp>;
upload(request: upload_pb.UploadReq, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<upload_pb.UploadResp>;
upload(request: upload_pb.UploadReq, metadata?: grpc.Metadata, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<upload_pb.UploadResp>;
platformSearch(request: core_pb.PlatformSearchReq, callback: (error: grpc.ServiceError | null, response: core_pb.PlatformSearchResp) => void): grpc.ClientUnaryCall;
platformSearch(request: core_pb.PlatformSearchReq, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: core_pb.PlatformSearchResp) => void): grpc.ClientUnaryCall;
platformSearch(request: core_pb.PlatformSearchReq, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: core_pb.PlatformSearchResp) => void): grpc.ClientUnaryCall;
platformList(request: core_pb.PlatformListReq, callback: (error: grpc.ServiceError | null, response: core_pb.PlatformListResp) => void): grpc.ClientUnaryCall;
platformList(request: core_pb.PlatformListReq, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: core_pb.PlatformListResp) => void): grpc.ClientUnaryCall;
platformList(request: core_pb.PlatformListReq, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: core_pb.PlatformListResp) => void): grpc.ClientUnaryCall;
libraryDownload(request: lib_pb.LibraryDownloadReq, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<lib_pb.LibraryDownloadResp>;
libraryDownload(request: lib_pb.LibraryDownloadReq, metadata?: grpc.Metadata, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<lib_pb.LibraryDownloadResp>;
libraryInstall(request: lib_pb.LibraryInstallReq, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<lib_pb.LibraryInstallResp>;
libraryInstall(request: lib_pb.LibraryInstallReq, metadata?: grpc.Metadata, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<lib_pb.LibraryInstallResp>;
libraryUninstall(request: lib_pb.LibraryUninstallReq, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<lib_pb.LibraryUninstallResp>;
libraryUninstall(request: lib_pb.LibraryUninstallReq, metadata?: grpc.Metadata, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<lib_pb.LibraryUninstallResp>;
libraryUpgradeAll(request: lib_pb.LibraryUpgradeAllReq, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<lib_pb.LibraryUpgradeAllResp>;
libraryUpgradeAll(request: lib_pb.LibraryUpgradeAllReq, metadata?: grpc.Metadata, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<lib_pb.LibraryUpgradeAllResp>;
librarySearch(request: lib_pb.LibrarySearchReq, callback: (error: grpc.ServiceError | null, response: lib_pb.LibrarySearchResp) => void): grpc.ClientUnaryCall;
librarySearch(request: lib_pb.LibrarySearchReq, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: lib_pb.LibrarySearchResp) => void): grpc.ClientUnaryCall;
librarySearch(request: lib_pb.LibrarySearchReq, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: lib_pb.LibrarySearchResp) => void): grpc.ClientUnaryCall;
libraryList(request: lib_pb.LibraryListReq, callback: (error: grpc.ServiceError | null, response: lib_pb.LibraryListResp) => void): grpc.ClientUnaryCall;
libraryList(request: lib_pb.LibraryListReq, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: lib_pb.LibraryListResp) => void): grpc.ClientUnaryCall;
libraryList(request: lib_pb.LibraryListReq, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: lib_pb.LibraryListResp) => void): grpc.ClientUnaryCall;
}
export class ArduinoCoreClient extends grpc.Client implements IArduinoCoreClient {
constructor(address: string, credentials: grpc.ChannelCredentials, options?: object);
public init(request: commands_pb.InitReq, callback: (error: grpc.ServiceError | null, response: commands_pb.InitResp) => void): grpc.ClientUnaryCall;
public init(request: commands_pb.InitReq, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: commands_pb.InitResp) => void): grpc.ClientUnaryCall;
public init(request: commands_pb.InitReq, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: commands_pb.InitResp) => void): grpc.ClientUnaryCall;
public destroy(request: commands_pb.DestroyReq, callback: (error: grpc.ServiceError | null, response: commands_pb.DestroyResp) => void): grpc.ClientUnaryCall;
public destroy(request: commands_pb.DestroyReq, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: commands_pb.DestroyResp) => void): grpc.ClientUnaryCall;
public destroy(request: commands_pb.DestroyReq, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: commands_pb.DestroyResp) => void): grpc.ClientUnaryCall;
public rescan(request: commands_pb.RescanReq, callback: (error: grpc.ServiceError | null, response: commands_pb.RescanResp) => void): grpc.ClientUnaryCall;
public rescan(request: commands_pb.RescanReq, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: commands_pb.RescanResp) => void): grpc.ClientUnaryCall;
public rescan(request: commands_pb.RescanReq, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: commands_pb.RescanResp) => void): grpc.ClientUnaryCall;
public updateIndex(request: commands_pb.UpdateIndexReq, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_pb.UpdateIndexResp>;
public updateIndex(request: commands_pb.UpdateIndexReq, metadata?: grpc.Metadata, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<commands_pb.UpdateIndexResp>;
public boardList(request: board_pb.BoardListReq, callback: (error: grpc.ServiceError | null, response: board_pb.BoardListResp) => void): grpc.ClientUnaryCall;
public boardList(request: board_pb.BoardListReq, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: board_pb.BoardListResp) => void): grpc.ClientUnaryCall;
public boardList(request: board_pb.BoardListReq, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: board_pb.BoardListResp) => void): grpc.ClientUnaryCall;
public boardDetails(request: board_pb.BoardDetailsReq, callback: (error: grpc.ServiceError | null, response: board_pb.BoardDetailsResp) => void): grpc.ClientUnaryCall;
public boardDetails(request: board_pb.BoardDetailsReq, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: board_pb.BoardDetailsResp) => void): grpc.ClientUnaryCall;
public boardDetails(request: board_pb.BoardDetailsReq, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: board_pb.BoardDetailsResp) => void): grpc.ClientUnaryCall;
public compile(request: compile_pb.CompileReq, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<compile_pb.CompileResp>;
public compile(request: compile_pb.CompileReq, metadata?: grpc.Metadata, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<compile_pb.CompileResp>;
public platformInstall(request: core_pb.PlatformInstallReq, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<core_pb.PlatformInstallResp>;
public platformInstall(request: core_pb.PlatformInstallReq, metadata?: grpc.Metadata, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<core_pb.PlatformInstallResp>;
public platformDownload(request: core_pb.PlatformDownloadReq, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<core_pb.PlatformDownloadResp>;
public platformDownload(request: core_pb.PlatformDownloadReq, metadata?: grpc.Metadata, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<core_pb.PlatformDownloadResp>;
public platformUninstall(request: core_pb.PlatformUninstallReq, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<core_pb.PlatformUninstallResp>;
public platformUninstall(request: core_pb.PlatformUninstallReq, metadata?: grpc.Metadata, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<core_pb.PlatformUninstallResp>;
public platformUpgrade(request: core_pb.PlatformUpgradeReq, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<core_pb.PlatformUpgradeResp>;
public platformUpgrade(request: core_pb.PlatformUpgradeReq, metadata?: grpc.Metadata, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<core_pb.PlatformUpgradeResp>;
public upload(request: upload_pb.UploadReq, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<upload_pb.UploadResp>;
public upload(request: upload_pb.UploadReq, metadata?: grpc.Metadata, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<upload_pb.UploadResp>;
public platformSearch(request: core_pb.PlatformSearchReq, callback: (error: grpc.ServiceError | null, response: core_pb.PlatformSearchResp) => void): grpc.ClientUnaryCall;
public platformSearch(request: core_pb.PlatformSearchReq, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: core_pb.PlatformSearchResp) => void): grpc.ClientUnaryCall;
public platformSearch(request: core_pb.PlatformSearchReq, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: core_pb.PlatformSearchResp) => void): grpc.ClientUnaryCall;
public platformList(request: core_pb.PlatformListReq, callback: (error: grpc.ServiceError | null, response: core_pb.PlatformListResp) => void): grpc.ClientUnaryCall;
public platformList(request: core_pb.PlatformListReq, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: core_pb.PlatformListResp) => void): grpc.ClientUnaryCall;
public platformList(request: core_pb.PlatformListReq, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: core_pb.PlatformListResp) => void): grpc.ClientUnaryCall;
public libraryDownload(request: lib_pb.LibraryDownloadReq, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<lib_pb.LibraryDownloadResp>;
public libraryDownload(request: lib_pb.LibraryDownloadReq, metadata?: grpc.Metadata, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<lib_pb.LibraryDownloadResp>;
public libraryInstall(request: lib_pb.LibraryInstallReq, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<lib_pb.LibraryInstallResp>;
public libraryInstall(request: lib_pb.LibraryInstallReq, metadata?: grpc.Metadata, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<lib_pb.LibraryInstallResp>;
public libraryUninstall(request: lib_pb.LibraryUninstallReq, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<lib_pb.LibraryUninstallResp>;
public libraryUninstall(request: lib_pb.LibraryUninstallReq, metadata?: grpc.Metadata, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<lib_pb.LibraryUninstallResp>;
public libraryUpgradeAll(request: lib_pb.LibraryUpgradeAllReq, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<lib_pb.LibraryUpgradeAllResp>;
public libraryUpgradeAll(request: lib_pb.LibraryUpgradeAllReq, metadata?: grpc.Metadata, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<lib_pb.LibraryUpgradeAllResp>;
public librarySearch(request: lib_pb.LibrarySearchReq, callback: (error: grpc.ServiceError | null, response: lib_pb.LibrarySearchResp) => void): grpc.ClientUnaryCall;
public librarySearch(request: lib_pb.LibrarySearchReq, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: lib_pb.LibrarySearchResp) => void): grpc.ClientUnaryCall;
public librarySearch(request: lib_pb.LibrarySearchReq, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: lib_pb.LibrarySearchResp) => void): grpc.ClientUnaryCall;
public libraryList(request: lib_pb.LibraryListReq, callback: (error: grpc.ServiceError | null, response: lib_pb.LibraryListResp) => void): grpc.ClientUnaryCall;
public libraryList(request: lib_pb.LibraryListReq, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: lib_pb.LibraryListResp) => void): grpc.ClientUnaryCall;
public libraryList(request: lib_pb.LibraryListReq, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: lib_pb.LibraryListResp) => void): grpc.ClientUnaryCall;
}

View File

@ -1,706 +0,0 @@
// GENERATED CODE -- DO NOT EDIT!
// Original file comments:
//
// This file is part of arduino-cli.
//
// Copyright 2018 ARDUINO SA (http://www.arduino.cc/)
//
// This software is released under the GNU General Public License version 3,
// which covers the main part of arduino-cli.
// The terms of this license can be found at:
// https://www.gnu.org/licenses/gpl-3.0.en.html
//
// You can be released from the requirements of the above licenses by purchasing
// a commercial license. Buying such a license is mandatory if you want to modify or
// otherwise use the software for commercial activities involving the Arduino
// software without disclosing the source code of your own applications. To purchase
// a commercial license, send an email to license@arduino.cc.
//
//
'use strict';
var grpc = require('@grpc/grpc-js');
var commands_pb = require('./commands_pb.js');
var common_pb = require('./common_pb.js');
var board_pb = require('./board_pb.js');
var compile_pb = require('./compile_pb.js');
var core_pb = require('./core_pb.js');
var upload_pb = require('./upload_pb.js');
var lib_pb = require('./lib_pb.js');
function serialize_arduino_BoardDetailsReq(arg) {
if (!(arg instanceof board_pb.BoardDetailsReq)) {
throw new Error('Expected argument of type arduino.BoardDetailsReq');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_arduino_BoardDetailsReq(buffer_arg) {
return board_pb.BoardDetailsReq.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_arduino_BoardDetailsResp(arg) {
if (!(arg instanceof board_pb.BoardDetailsResp)) {
throw new Error('Expected argument of type arduino.BoardDetailsResp');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_arduino_BoardDetailsResp(buffer_arg) {
return board_pb.BoardDetailsResp.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_arduino_BoardListReq(arg) {
if (!(arg instanceof board_pb.BoardListReq)) {
throw new Error('Expected argument of type arduino.BoardListReq');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_arduino_BoardListReq(buffer_arg) {
return board_pb.BoardListReq.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_arduino_BoardListResp(arg) {
if (!(arg instanceof board_pb.BoardListResp)) {
throw new Error('Expected argument of type arduino.BoardListResp');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_arduino_BoardListResp(buffer_arg) {
return board_pb.BoardListResp.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_arduino_CompileReq(arg) {
if (!(arg instanceof compile_pb.CompileReq)) {
throw new Error('Expected argument of type arduino.CompileReq');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_arduino_CompileReq(buffer_arg) {
return compile_pb.CompileReq.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_arduino_CompileResp(arg) {
if (!(arg instanceof compile_pb.CompileResp)) {
throw new Error('Expected argument of type arduino.CompileResp');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_arduino_CompileResp(buffer_arg) {
return compile_pb.CompileResp.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_arduino_DestroyReq(arg) {
if (!(arg instanceof commands_pb.DestroyReq)) {
throw new Error('Expected argument of type arduino.DestroyReq');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_arduino_DestroyReq(buffer_arg) {
return commands_pb.DestroyReq.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_arduino_DestroyResp(arg) {
if (!(arg instanceof commands_pb.DestroyResp)) {
throw new Error('Expected argument of type arduino.DestroyResp');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_arduino_DestroyResp(buffer_arg) {
return commands_pb.DestroyResp.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_arduino_InitReq(arg) {
if (!(arg instanceof commands_pb.InitReq)) {
throw new Error('Expected argument of type arduino.InitReq');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_arduino_InitReq(buffer_arg) {
return commands_pb.InitReq.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_arduino_InitResp(arg) {
if (!(arg instanceof commands_pb.InitResp)) {
throw new Error('Expected argument of type arduino.InitResp');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_arduino_InitResp(buffer_arg) {
return commands_pb.InitResp.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_arduino_LibraryDownloadReq(arg) {
if (!(arg instanceof lib_pb.LibraryDownloadReq)) {
throw new Error('Expected argument of type arduino.LibraryDownloadReq');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_arduino_LibraryDownloadReq(buffer_arg) {
return lib_pb.LibraryDownloadReq.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_arduino_LibraryDownloadResp(arg) {
if (!(arg instanceof lib_pb.LibraryDownloadResp)) {
throw new Error('Expected argument of type arduino.LibraryDownloadResp');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_arduino_LibraryDownloadResp(buffer_arg) {
return lib_pb.LibraryDownloadResp.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_arduino_LibraryInstallReq(arg) {
if (!(arg instanceof lib_pb.LibraryInstallReq)) {
throw new Error('Expected argument of type arduino.LibraryInstallReq');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_arduino_LibraryInstallReq(buffer_arg) {
return lib_pb.LibraryInstallReq.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_arduino_LibraryInstallResp(arg) {
if (!(arg instanceof lib_pb.LibraryInstallResp)) {
throw new Error('Expected argument of type arduino.LibraryInstallResp');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_arduino_LibraryInstallResp(buffer_arg) {
return lib_pb.LibraryInstallResp.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_arduino_LibraryListReq(arg) {
if (!(arg instanceof lib_pb.LibraryListReq)) {
throw new Error('Expected argument of type arduino.LibraryListReq');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_arduino_LibraryListReq(buffer_arg) {
return lib_pb.LibraryListReq.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_arduino_LibraryListResp(arg) {
if (!(arg instanceof lib_pb.LibraryListResp)) {
throw new Error('Expected argument of type arduino.LibraryListResp');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_arduino_LibraryListResp(buffer_arg) {
return lib_pb.LibraryListResp.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_arduino_LibrarySearchReq(arg) {
if (!(arg instanceof lib_pb.LibrarySearchReq)) {
throw new Error('Expected argument of type arduino.LibrarySearchReq');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_arduino_LibrarySearchReq(buffer_arg) {
return lib_pb.LibrarySearchReq.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_arduino_LibrarySearchResp(arg) {
if (!(arg instanceof lib_pb.LibrarySearchResp)) {
throw new Error('Expected argument of type arduino.LibrarySearchResp');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_arduino_LibrarySearchResp(buffer_arg) {
return lib_pb.LibrarySearchResp.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_arduino_LibraryUninstallReq(arg) {
if (!(arg instanceof lib_pb.LibraryUninstallReq)) {
throw new Error('Expected argument of type arduino.LibraryUninstallReq');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_arduino_LibraryUninstallReq(buffer_arg) {
return lib_pb.LibraryUninstallReq.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_arduino_LibraryUninstallResp(arg) {
if (!(arg instanceof lib_pb.LibraryUninstallResp)) {
throw new Error('Expected argument of type arduino.LibraryUninstallResp');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_arduino_LibraryUninstallResp(buffer_arg) {
return lib_pb.LibraryUninstallResp.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_arduino_LibraryUpgradeAllReq(arg) {
if (!(arg instanceof lib_pb.LibraryUpgradeAllReq)) {
throw new Error('Expected argument of type arduino.LibraryUpgradeAllReq');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_arduino_LibraryUpgradeAllReq(buffer_arg) {
return lib_pb.LibraryUpgradeAllReq.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_arduino_LibraryUpgradeAllResp(arg) {
if (!(arg instanceof lib_pb.LibraryUpgradeAllResp)) {
throw new Error('Expected argument of type arduino.LibraryUpgradeAllResp');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_arduino_LibraryUpgradeAllResp(buffer_arg) {
return lib_pb.LibraryUpgradeAllResp.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_arduino_PlatformDownloadReq(arg) {
if (!(arg instanceof core_pb.PlatformDownloadReq)) {
throw new Error('Expected argument of type arduino.PlatformDownloadReq');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_arduino_PlatformDownloadReq(buffer_arg) {
return core_pb.PlatformDownloadReq.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_arduino_PlatformDownloadResp(arg) {
if (!(arg instanceof core_pb.PlatformDownloadResp)) {
throw new Error('Expected argument of type arduino.PlatformDownloadResp');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_arduino_PlatformDownloadResp(buffer_arg) {
return core_pb.PlatformDownloadResp.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_arduino_PlatformInstallReq(arg) {
if (!(arg instanceof core_pb.PlatformInstallReq)) {
throw new Error('Expected argument of type arduino.PlatformInstallReq');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_arduino_PlatformInstallReq(buffer_arg) {
return core_pb.PlatformInstallReq.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_arduino_PlatformInstallResp(arg) {
if (!(arg instanceof core_pb.PlatformInstallResp)) {
throw new Error('Expected argument of type arduino.PlatformInstallResp');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_arduino_PlatformInstallResp(buffer_arg) {
return core_pb.PlatformInstallResp.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_arduino_PlatformListReq(arg) {
if (!(arg instanceof core_pb.PlatformListReq)) {
throw new Error('Expected argument of type arduino.PlatformListReq');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_arduino_PlatformListReq(buffer_arg) {
return core_pb.PlatformListReq.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_arduino_PlatformListResp(arg) {
if (!(arg instanceof core_pb.PlatformListResp)) {
throw new Error('Expected argument of type arduino.PlatformListResp');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_arduino_PlatformListResp(buffer_arg) {
return core_pb.PlatformListResp.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_arduino_PlatformSearchReq(arg) {
if (!(arg instanceof core_pb.PlatformSearchReq)) {
throw new Error('Expected argument of type arduino.PlatformSearchReq');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_arduino_PlatformSearchReq(buffer_arg) {
return core_pb.PlatformSearchReq.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_arduino_PlatformSearchResp(arg) {
if (!(arg instanceof core_pb.PlatformSearchResp)) {
throw new Error('Expected argument of type arduino.PlatformSearchResp');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_arduino_PlatformSearchResp(buffer_arg) {
return core_pb.PlatformSearchResp.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_arduino_PlatformUninstallReq(arg) {
if (!(arg instanceof core_pb.PlatformUninstallReq)) {
throw new Error('Expected argument of type arduino.PlatformUninstallReq');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_arduino_PlatformUninstallReq(buffer_arg) {
return core_pb.PlatformUninstallReq.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_arduino_PlatformUninstallResp(arg) {
if (!(arg instanceof core_pb.PlatformUninstallResp)) {
throw new Error('Expected argument of type arduino.PlatformUninstallResp');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_arduino_PlatformUninstallResp(buffer_arg) {
return core_pb.PlatformUninstallResp.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_arduino_PlatformUpgradeReq(arg) {
if (!(arg instanceof core_pb.PlatformUpgradeReq)) {
throw new Error('Expected argument of type arduino.PlatformUpgradeReq');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_arduino_PlatformUpgradeReq(buffer_arg) {
return core_pb.PlatformUpgradeReq.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_arduino_PlatformUpgradeResp(arg) {
if (!(arg instanceof core_pb.PlatformUpgradeResp)) {
throw new Error('Expected argument of type arduino.PlatformUpgradeResp');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_arduino_PlatformUpgradeResp(buffer_arg) {
return core_pb.PlatformUpgradeResp.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_arduino_RescanReq(arg) {
if (!(arg instanceof commands_pb.RescanReq)) {
throw new Error('Expected argument of type arduino.RescanReq');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_arduino_RescanReq(buffer_arg) {
return commands_pb.RescanReq.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_arduino_RescanResp(arg) {
if (!(arg instanceof commands_pb.RescanResp)) {
throw new Error('Expected argument of type arduino.RescanResp');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_arduino_RescanResp(buffer_arg) {
return commands_pb.RescanResp.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_arduino_UpdateIndexReq(arg) {
if (!(arg instanceof commands_pb.UpdateIndexReq)) {
throw new Error('Expected argument of type arduino.UpdateIndexReq');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_arduino_UpdateIndexReq(buffer_arg) {
return commands_pb.UpdateIndexReq.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_arduino_UpdateIndexResp(arg) {
if (!(arg instanceof commands_pb.UpdateIndexResp)) {
throw new Error('Expected argument of type arduino.UpdateIndexResp');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_arduino_UpdateIndexResp(buffer_arg) {
return commands_pb.UpdateIndexResp.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_arduino_UploadReq(arg) {
if (!(arg instanceof upload_pb.UploadReq)) {
throw new Error('Expected argument of type arduino.UploadReq');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_arduino_UploadReq(buffer_arg) {
return upload_pb.UploadReq.deserializeBinary(new Uint8Array(buffer_arg));
}
function serialize_arduino_UploadResp(arg) {
if (!(arg instanceof upload_pb.UploadResp)) {
throw new Error('Expected argument of type arduino.UploadResp');
}
return Buffer.from(arg.serializeBinary());
}
function deserialize_arduino_UploadResp(buffer_arg) {
return upload_pb.UploadResp.deserializeBinary(new Uint8Array(buffer_arg));
}
// The main Arduino Platform Service
var ArduinoCoreService = exports.ArduinoCoreService = {
// Start a new instance of the Arduino Core Service
init: {
path: '/arduino.ArduinoCore/Init',
requestStream: false,
responseStream: false,
requestType: commands_pb.InitReq,
responseType: commands_pb.InitResp,
requestSerialize: serialize_arduino_InitReq,
requestDeserialize: deserialize_arduino_InitReq,
responseSerialize: serialize_arduino_InitResp,
responseDeserialize: deserialize_arduino_InitResp,
},
// Destroy an instance of the Arduino Core Service
destroy: {
path: '/arduino.ArduinoCore/Destroy',
requestStream: false,
responseStream: false,
requestType: commands_pb.DestroyReq,
responseType: commands_pb.DestroyResp,
requestSerialize: serialize_arduino_DestroyReq,
requestDeserialize: deserialize_arduino_DestroyReq,
responseSerialize: serialize_arduino_DestroyResp,
responseDeserialize: deserialize_arduino_DestroyResp,
},
// Rescan instance of the Arduino Core Service
rescan: {
path: '/arduino.ArduinoCore/Rescan',
requestStream: false,
responseStream: false,
requestType: commands_pb.RescanReq,
responseType: commands_pb.RescanResp,
requestSerialize: serialize_arduino_RescanReq,
requestDeserialize: deserialize_arduino_RescanReq,
responseSerialize: serialize_arduino_RescanResp,
responseDeserialize: deserialize_arduino_RescanResp,
},
// Update package index of the Arduino Core Service
updateIndex: {
path: '/arduino.ArduinoCore/UpdateIndex',
requestStream: false,
responseStream: true,
requestType: commands_pb.UpdateIndexReq,
responseType: commands_pb.UpdateIndexResp,
requestSerialize: serialize_arduino_UpdateIndexReq,
requestDeserialize: deserialize_arduino_UpdateIndexReq,
responseSerialize: serialize_arduino_UpdateIndexResp,
responseDeserialize: deserialize_arduino_UpdateIndexResp,
},
// BOARD COMMANDS
// --------------
//
boardList: {
path: '/arduino.ArduinoCore/BoardList',
requestStream: false,
responseStream: false,
requestType: board_pb.BoardListReq,
responseType: board_pb.BoardListResp,
requestSerialize: serialize_arduino_BoardListReq,
requestDeserialize: deserialize_arduino_BoardListReq,
responseSerialize: serialize_arduino_BoardListResp,
responseDeserialize: deserialize_arduino_BoardListResp,
},
// Requests details about a board
boardDetails: {
path: '/arduino.ArduinoCore/BoardDetails',
requestStream: false,
responseStream: false,
requestType: board_pb.BoardDetailsReq,
responseType: board_pb.BoardDetailsResp,
requestSerialize: serialize_arduino_BoardDetailsReq,
requestDeserialize: deserialize_arduino_BoardDetailsReq,
responseSerialize: serialize_arduino_BoardDetailsResp,
responseDeserialize: deserialize_arduino_BoardDetailsResp,
},
compile: {
path: '/arduino.ArduinoCore/Compile',
requestStream: false,
responseStream: true,
requestType: compile_pb.CompileReq,
responseType: compile_pb.CompileResp,
requestSerialize: serialize_arduino_CompileReq,
requestDeserialize: deserialize_arduino_CompileReq,
responseSerialize: serialize_arduino_CompileResp,
responseDeserialize: deserialize_arduino_CompileResp,
},
platformInstall: {
path: '/arduino.ArduinoCore/PlatformInstall',
requestStream: false,
responseStream: true,
requestType: core_pb.PlatformInstallReq,
responseType: core_pb.PlatformInstallResp,
requestSerialize: serialize_arduino_PlatformInstallReq,
requestDeserialize: deserialize_arduino_PlatformInstallReq,
responseSerialize: serialize_arduino_PlatformInstallResp,
responseDeserialize: deserialize_arduino_PlatformInstallResp,
},
platformDownload: {
path: '/arduino.ArduinoCore/PlatformDownload',
requestStream: false,
responseStream: true,
requestType: core_pb.PlatformDownloadReq,
responseType: core_pb.PlatformDownloadResp,
requestSerialize: serialize_arduino_PlatformDownloadReq,
requestDeserialize: deserialize_arduino_PlatformDownloadReq,
responseSerialize: serialize_arduino_PlatformDownloadResp,
responseDeserialize: deserialize_arduino_PlatformDownloadResp,
},
platformUninstall: {
path: '/arduino.ArduinoCore/PlatformUninstall',
requestStream: false,
responseStream: true,
requestType: core_pb.PlatformUninstallReq,
responseType: core_pb.PlatformUninstallResp,
requestSerialize: serialize_arduino_PlatformUninstallReq,
requestDeserialize: deserialize_arduino_PlatformUninstallReq,
responseSerialize: serialize_arduino_PlatformUninstallResp,
responseDeserialize: deserialize_arduino_PlatformUninstallResp,
},
platformUpgrade: {
path: '/arduino.ArduinoCore/PlatformUpgrade',
requestStream: false,
responseStream: true,
requestType: core_pb.PlatformUpgradeReq,
responseType: core_pb.PlatformUpgradeResp,
requestSerialize: serialize_arduino_PlatformUpgradeReq,
requestDeserialize: deserialize_arduino_PlatformUpgradeReq,
responseSerialize: serialize_arduino_PlatformUpgradeResp,
responseDeserialize: deserialize_arduino_PlatformUpgradeResp,
},
upload: {
path: '/arduino.ArduinoCore/Upload',
requestStream: false,
responseStream: true,
requestType: upload_pb.UploadReq,
responseType: upload_pb.UploadResp,
requestSerialize: serialize_arduino_UploadReq,
requestDeserialize: deserialize_arduino_UploadReq,
responseSerialize: serialize_arduino_UploadResp,
responseDeserialize: deserialize_arduino_UploadResp,
},
platformSearch: {
path: '/arduino.ArduinoCore/PlatformSearch',
requestStream: false,
responseStream: false,
requestType: core_pb.PlatformSearchReq,
responseType: core_pb.PlatformSearchResp,
requestSerialize: serialize_arduino_PlatformSearchReq,
requestDeserialize: deserialize_arduino_PlatformSearchReq,
responseSerialize: serialize_arduino_PlatformSearchResp,
responseDeserialize: deserialize_arduino_PlatformSearchResp,
},
platformList: {
path: '/arduino.ArduinoCore/PlatformList',
requestStream: false,
responseStream: false,
requestType: core_pb.PlatformListReq,
responseType: core_pb.PlatformListResp,
requestSerialize: serialize_arduino_PlatformListReq,
requestDeserialize: deserialize_arduino_PlatformListReq,
responseSerialize: serialize_arduino_PlatformListResp,
responseDeserialize: deserialize_arduino_PlatformListResp,
},
libraryDownload: {
path: '/arduino.ArduinoCore/LibraryDownload',
requestStream: false,
responseStream: true,
requestType: lib_pb.LibraryDownloadReq,
responseType: lib_pb.LibraryDownloadResp,
requestSerialize: serialize_arduino_LibraryDownloadReq,
requestDeserialize: deserialize_arduino_LibraryDownloadReq,
responseSerialize: serialize_arduino_LibraryDownloadResp,
responseDeserialize: deserialize_arduino_LibraryDownloadResp,
},
libraryInstall: {
path: '/arduino.ArduinoCore/LibraryInstall',
requestStream: false,
responseStream: true,
requestType: lib_pb.LibraryInstallReq,
responseType: lib_pb.LibraryInstallResp,
requestSerialize: serialize_arduino_LibraryInstallReq,
requestDeserialize: deserialize_arduino_LibraryInstallReq,
responseSerialize: serialize_arduino_LibraryInstallResp,
responseDeserialize: deserialize_arduino_LibraryInstallResp,
},
libraryUninstall: {
path: '/arduino.ArduinoCore/LibraryUninstall',
requestStream: false,
responseStream: true,
requestType: lib_pb.LibraryUninstallReq,
responseType: lib_pb.LibraryUninstallResp,
requestSerialize: serialize_arduino_LibraryUninstallReq,
requestDeserialize: deserialize_arduino_LibraryUninstallReq,
responseSerialize: serialize_arduino_LibraryUninstallResp,
responseDeserialize: deserialize_arduino_LibraryUninstallResp,
},
libraryUpgradeAll: {
path: '/arduino.ArduinoCore/LibraryUpgradeAll',
requestStream: false,
responseStream: true,
requestType: lib_pb.LibraryUpgradeAllReq,
responseType: lib_pb.LibraryUpgradeAllResp,
requestSerialize: serialize_arduino_LibraryUpgradeAllReq,
requestDeserialize: deserialize_arduino_LibraryUpgradeAllReq,
responseSerialize: serialize_arduino_LibraryUpgradeAllResp,
responseDeserialize: deserialize_arduino_LibraryUpgradeAllResp,
},
librarySearch: {
path: '/arduino.ArduinoCore/LibrarySearch',
requestStream: false,
responseStream: false,
requestType: lib_pb.LibrarySearchReq,
responseType: lib_pb.LibrarySearchResp,
requestSerialize: serialize_arduino_LibrarySearchReq,
requestDeserialize: deserialize_arduino_LibrarySearchReq,
responseSerialize: serialize_arduino_LibrarySearchResp,
responseDeserialize: deserialize_arduino_LibrarySearchResp,
},
libraryList: {
path: '/arduino.ArduinoCore/LibraryList',
requestStream: false,
responseStream: false,
requestType: lib_pb.LibraryListReq,
responseType: lib_pb.LibraryListResp,
requestSerialize: serialize_arduino_LibraryListReq,
requestDeserialize: deserialize_arduino_LibraryListReq,
responseSerialize: serialize_arduino_LibraryListResp,
responseDeserialize: deserialize_arduino_LibraryListResp,
},
};
exports.ArduinoCoreClient = grpc.makeGenericClientConstructor(ArduinoCoreService);
// BOOTSTRAP COMMANDS
// -------------------

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -1,14 +1,20 @@
import { inject, injectable } from 'inversify';
import * as grpc from '@grpc/grpc-js';
import { ArduinoCoreClient } from './cli-protocol/commands_grpc_pb';
import { InitResp, InitReq, Configuration, UpdateIndexReq, UpdateIndexResp } from './cli-protocol/commands_pb';
import { ArduinoCoreClient } from './cli-protocol/commands/commands_grpc_pb';
import {
InitResp,
InitReq,
Configuration,
UpdateIndexReq,
UpdateIndexResp
} from './cli-protocol/commands/commands_pb';
import { WorkspaceServiceExt } from '../browser/workspace-service-ext';
import { FileSystem } from '@theia/filesystem/lib/common';
import URI from '@theia/core/lib/common/uri';
import { CoreClientProvider, Client } from './core-client-provider';
import * as PQueue from 'p-queue';
import { ToolOutputServiceServer } from '../common/protocol/tool-output-service';
import { Instance } from './cli-protocol/common_pb';
import { Instance } from './cli-protocol/commands/common_pb';
import * as fs from 'fs-extra';
import * as path from 'path';
import * as os from 'os';
@ -81,10 +87,24 @@ export class CoreClientProviderImpl implements CoreClientProvider {
config.setSketchbookdir(rootPath);
config.setDatadir(defaultDataDirPath);
config.setDownloadsdir(defaultDownloadsDirPath);
config.setBoardmanageradditionalurlsList(['https://downloads.arduino.cc/packages/package_index.json']);
const initReq = new InitReq();
initReq.setConfiguration(config);
const initResp = await new Promise<InitResp>((resolve, reject) => client.init(initReq, (err, resp) => (!!err ? reject : resolve)(!!err ? err : resp)));
initReq.setLibraryManagerOnly(false);
const initResp = await new Promise<InitResp>(resolve => {
let resp: InitResp | undefined = undefined;
const stream = client.init(initReq);
stream.on('data', (data: InitResp) => {
if (!resp) {
resp = data;
}
})
stream.on('end', () => {
resolve(resp);
})
});
const instance = initResp.getInstance();
if (!instance) {
throw new Error(`Could not retrieve instance from the initialize response.`);

View File

@ -1,5 +1,5 @@
import { Instance } from './cli-protocol/common_pb';
import { ArduinoCoreClient } from './cli-protocol/commands_grpc_pb';
import { Instance } from './cli-protocol/commands/common_pb';
import { ArduinoCoreClient } from './cli-protocol/commands/commands_grpc_pb';
export const CoreClientProviderPath = '/services/core-client-provider';
export const CoreClientProvider = Symbol('CoreClientProvider');

View File

@ -1,12 +1,12 @@
import { inject, injectable } from 'inversify';
import { FileSystem } from '@theia/filesystem/lib/common/filesystem';
import { CoreService } from '../common/protocol/core-service';
import { CompileReq, CompileResp } from './cli-protocol/compile_pb';
import { CompileReq, CompileResp } from './cli-protocol/commands/compile_pb';
import { BoardsService, AttachedSerialBoard, AttachedNetworkBoard } from '../common/protocol/boards-service';
import { CoreClientProvider } from './core-client-provider';
import * as path from 'path';
import { ToolOutputServiceServer } from '../common/protocol/tool-output-service';
import { UploadReq, UploadResp } from './cli-protocol/upload_pb';
import { UploadReq, UploadResp } from './cli-protocol/commands/upload_pb';
@injectable()
export class CoreServiceImpl implements CoreService {

View File

@ -2,7 +2,7 @@ import { injectable, inject } from 'inversify';
import { Library, LibraryService } from '../common/protocol/library-service';
import { CoreClientProvider } from './core-client-provider';
import { LibrarySearchReq, LibrarySearchResp, LibraryListReq, LibraryListResp, LibraryRelease,
InstalledLibrary, LibraryInstallReq, LibraryInstallResp } from './cli-protocol/lib_pb';
InstalledLibrary, LibraryInstallReq, LibraryInstallResp } from './cli-protocol/commands/lib_pb';
import { ToolOutputServiceServer } from '../common/protocol/tool-output-service';
@injectable()
@ -24,22 +24,29 @@ export class LibraryServiceImpl implements LibraryService {
const listReq = new LibraryListReq();
listReq.setInstance(instance);
const installedLibsResp = await new Promise<LibraryListResp>((resolve, reject) => client.libraryList(listReq, (err, resp) => !!err ? reject(err) : resolve(resp)));
const installedLibs = installedLibsResp.getLibrariesList();
const installedLibs = installedLibsResp.getInstalledLibraryList();
const installedLibsIdx = new Map<string, InstalledLibrary>();
installedLibs.forEach(l => installedLibsIdx.set(l.getName(), l));
for (const installedLib of installedLibs) {
if (installedLib.hasLibrary()) {
const lib = installedLib.getLibrary();
if (lib) {
installedLibsIdx.set(lib.getRealName(), installedLib);
}
}
}
const req = new LibrarySearchReq();
req.setQuery(options.query || '');
req.setInstance(instance);
const resp = await new Promise<LibrarySearchResp>((resolve, reject) => client.librarySearch(req, (err, resp) => !!err ? reject(err) : resolve(resp)));
const items = resp.getSearchOutputList()
const items = resp.getLibrariesList()
.filter(item => !!item.getLatest())
.slice(0, 50)
.map(item => {
let installedVersion: string | undefined;
const installed = installedLibsIdx.get(item.getName());
if (installed) {
installedVersion = installed.getInstalled()!.getVersion();
installedVersion = installed.getLibrary()!.getVersion();
}
return toLibrary({
name: item.getName(),

3386
yarn.lock

File diff suppressed because it is too large Load Diff