diff --git a/.gitignore b/.gitignore
index 019a0cd4..ddaa0df3 100644
--- a/.gitignore
+++ b/.gitignore
@@ -3,6 +3,7 @@ node_modules/
.node_modules/
lib/
build/
+downloads/
!electron/build/
src-gen/
arduino-ide-*/webpack.config.js
diff --git a/.vscode/launch.json b/.vscode/launch.json
index 48a072b3..da9bf2ac 100644
--- a/.vscode/launch.json
+++ b/.vscode/launch.json
@@ -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",
diff --git a/arduino-ide-electron/package.json b/arduino-ide-electron/package.json
index 4aca3f9c..dac2592d 100644
--- a/arduino-ide-electron/package.json
+++ b/arduino-ide-electron/package.json
@@ -40,5 +40,10 @@
}
}
}
+ },
+ "generator": {
+ "config": {
+ "preloadTemplate": "
"
+ }
}
}
\ No newline at end of file
diff --git a/arduino-ide-extension/build/arduino-cli.darwin b/arduino-ide-extension/build/arduino-cli.darwin
deleted file mode 100755
index 26722c7a..00000000
Binary files a/arduino-ide-extension/build/arduino-cli.darwin and /dev/null differ
diff --git a/arduino-ide-extension/build/arduino-cli.linux b/arduino-ide-extension/build/arduino-cli.linux
deleted file mode 100755
index 0c1426af..00000000
Binary files a/arduino-ide-extension/build/arduino-cli.linux and /dev/null differ
diff --git a/arduino-ide-extension/build/arduino-cli.win32 b/arduino-ide-extension/build/arduino-cli.win32
deleted file mode 100755
index e3577c75..00000000
Binary files a/arduino-ide-extension/build/arduino-cli.win32 and /dev/null differ
diff --git a/arduino-ide-extension/package.json b/arduino-ide-extension/package.json
index 32922ccb..b448930f 100644
--- a/arduino-ide-extension/package.json
+++ b/arduino-ide-extension/package.json
@@ -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"
}
]
-}
+}
\ No newline at end of file
diff --git a/arduino-ide-extension/scripts/download-cli.js b/arduino-ide-extension/scripts/download-cli.js
new file mode 100755
index 00000000..27bd76e5
--- /dev/null
+++ b/arduino-ide-extension/scripts/download-cli.js
@@ -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.');
+ }
+
+})();
\ No newline at end of file
diff --git a/arduino-ide-extension/scripts/generate-protoc.sh b/arduino-ide-extension/scripts/generate-protoc.sh
deleted file mode 100755
index 386f4422..00000000
--- a/arduino-ide-extension/scripts/generate-protoc.sh
+++ /dev/null
@@ -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
diff --git a/arduino-ide-extension/scripts/generate-protocol.js b/arduino-ide-extension/scripts/generate-protocol.js
new file mode 100644
index 00000000..82aa0415
--- /dev/null
+++ b/arduino-ide-extension/scripts/generate-protocol.js
@@ -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.');
+
+})();
\ No newline at end of file
diff --git a/arduino-ide-extension/scripts/patch-grpc-js.js b/arduino-ide-extension/scripts/patch-grpc-js.js
index d51dd863..999003ac 100644
--- a/arduino-ide-extension/scripts/patch-grpc-js.js
+++ b/arduino-ide-extension/scripts/patch-grpc-js.js
@@ -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.');
-})();
+}
\ No newline at end of file
diff --git a/arduino-ide-extension/src/common/protocol/boards-service.ts b/arduino-ide-extension/src/common/protocol/boards-service.ts
index b35861c2..ff77a0d3 100644
--- a/arduino-ide-extension/src/common/protocol/boards-service.ts
+++ b/arduino-ide-extension/src/common/protocol/boards-service.ts
@@ -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;
}
}
diff --git a/arduino-ide-extension/src/node/arduino-daemon.ts b/arduino-ide-extension/src/node/arduino-daemon.ts
index c30de779..a214fe90 100644
--- a/arduino-ide-extension/src/node/arduino-daemon.ts
+++ b/arduino-ide-extension/src/node/arduino-daemon.ts
@@ -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((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'));
}
diff --git a/arduino-ide-extension/src/node/boards-service-impl.ts b/arduino-ide-extension/src/node/boards-service-impl.ts
index 50df0265..079eb6c9 100644
--- a/arduino-ide-extension/src/node/boards-service-impl.ts
+++ b/arduino-ide-extension/src/node/boards-service-impl.ts
@@ -1,8 +1,8 @@
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()
@@ -18,34 +18,39 @@ export class BoardsServiceImpl implements BoardsService {
public async getAttachedBoards(): Promise<{ boards: Board[] }> {
const coreClient = await this.coreClientProvider.getClient();
+ const boards: Board[] = [];
if (!coreClient) {
- return { boards: [] };
+ return { boards };
}
const { client, instance } = coreClient;
const req = new BoardListReq();
req.setInstance(instance);
const resp = await new Promise((resolve, reject) => client.boardList(req, (err, resp) => (!!err ? reject : resolve)(!!err ? err : resp)));
-
- const serialBoards: Board[] = resp.getSerialList().map(b => {
- name: b.getName() || "unknown",
- fqbn: b.getFqbn(),
- port: b.getPort(),
- type: 'serial',
- serialNumber: b.getSerialnumber(),
- productID: b.getProductid(),
- vendorID: b.getVendorid()
- });
- const networkBoards: Board[] = resp.getNetworkList().map(b => {
- name: b.getName(),
- fqbn: b.getFqbn(),
- address: b.getAddress(),
- info: b.getInfo(),
- port: b.getPort(),
- type: 'network'
- });
-
- return { boards: serialBoards.concat(networkBoards) };
+ 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({
+ name,
+ fqbn,
+ port
+ });
+ } else { // We assume, it is a `network` board.
+ boards.push({
+ name,
+ fqbn,
+ address,
+ port
+ });
+ }
+ }
+ }
+ return { boards };
}
async selectBoard(board: Board): Promise {
@@ -77,7 +82,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 +90,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 +111,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);
diff --git a/arduino-ide-extension/src/node/cli-protocol/board_pb.js b/arduino-ide-extension/src/node/cli-protocol/board_pb.js
deleted file mode 100644
index e69931f3..00000000
--- a/arduino-ide-extension/src/node/cli-protocol/board_pb.js
+++ /dev/null
@@ -1,1968 +0,0 @@
-/**
- * @fileoverview
- * @enhanceable
- * @suppress {messageConventions} JS Compiler reports an error if a variable or
- * field starts with 'MSG_' and isn't a translatable message.
- * @public
- */
-// GENERATED CODE -- DO NOT EDIT!
-
-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.AttachedNetworkBoard', null, global);
-goog.exportSymbol('proto.arduino.AttachedSerialBoard', null, global);
-goog.exportSymbol('proto.arduino.BoardDetailsReq', null, global);
-goog.exportSymbol('proto.arduino.BoardDetailsResp', null, global);
-goog.exportSymbol('proto.arduino.BoardListReq', null, global);
-goog.exportSymbol('proto.arduino.BoardListResp', null, global);
-goog.exportSymbol('proto.arduino.ConfigOption', null, global);
-goog.exportSymbol('proto.arduino.ConfigValue', null, global);
-goog.exportSymbol('proto.arduino.RequiredTool', null, global);
-
-/**
- * Generated by JsPbCodeGenerator.
- * @param {Array=} opt_data Optional initial data array, typically from a
- * server response, or constructed directly in Javascript. The array is used
- * in place and becomes part of the constructed object. It is not cloned.
- * If no data is provided, the constructed object will be empty, but still
- * valid.
- * @extends {jspb.Message}
- * @constructor
- */
-proto.arduino.BoardDetailsReq = function(opt_data) {
- jspb.Message.initialize(this, opt_data, 0, -1, null, null);
-};
-goog.inherits(proto.arduino.BoardDetailsReq, jspb.Message);
-if (goog.DEBUG && !COMPILED) {
- proto.arduino.BoardDetailsReq.displayName = 'proto.arduino.BoardDetailsReq';
-}
-
-
-if (jspb.Message.GENERATE_TO_OBJECT) {
-/**
- * Creates an object representation of this proto suitable for use in Soy templates.
- * Field names that are reserved in JavaScript and will be renamed to pb_name.
- * To access a reserved field use, foo.pb_, eg, foo.pb_default.
- * For the list of reserved names please see:
- * com.google.apps.jspb.JsClassTemplate.JS_RESERVED_WORDS.
- * @param {boolean=} opt_includeInstance Whether to include the JSPB instance
- * for transitional soy proto support: http://goto/soy-param-migration
- * @return {!Object}
- */
-proto.arduino.BoardDetailsReq.prototype.toObject = function(opt_includeInstance) {
- return proto.arduino.BoardDetailsReq.toObject(opt_includeInstance, this);
-};
-
-
-/**
- * Static version of the {@see toObject} method.
- * @param {boolean|undefined} includeInstance Whether to include the JSPB
- * instance for transitional soy proto support:
- * http://goto/soy-param-migration
- * @param {!proto.arduino.BoardDetailsReq} msg The msg instance to transform.
- * @return {!Object}
- * @suppress {unusedLocalVariables} f is only used for nested messages
- */
-proto.arduino.BoardDetailsReq.toObject = function(includeInstance, msg) {
- var f, obj = {
- instance: (f = msg.getInstance()) && common_pb.Instance.toObject(includeInstance, f),
- fqbn: jspb.Message.getFieldWithDefault(msg, 2, "")
- };
-
- if (includeInstance) {
- obj.$jspbMessageInstance = msg;
- }
- return obj;
-};
-}
-
-
-/**
- * Deserializes binary data (in protobuf wire format).
- * @param {jspb.ByteSource} bytes The bytes to deserialize.
- * @return {!proto.arduino.BoardDetailsReq}
- */
-proto.arduino.BoardDetailsReq.deserializeBinary = function(bytes) {
- var reader = new jspb.BinaryReader(bytes);
- var msg = new proto.arduino.BoardDetailsReq;
- return proto.arduino.BoardDetailsReq.deserializeBinaryFromReader(msg, reader);
-};
-
-
-/**
- * Deserializes binary data (in protobuf wire format) from the
- * given reader into the given message object.
- * @param {!proto.arduino.BoardDetailsReq} msg The message object to deserialize into.
- * @param {!jspb.BinaryReader} reader The BinaryReader to use.
- * @return {!proto.arduino.BoardDetailsReq}
- */
-proto.arduino.BoardDetailsReq.deserializeBinaryFromReader = function(msg, reader) {
- while (reader.nextField()) {
- if (reader.isEndGroup()) {
- break;
- }
- var field = reader.getFieldNumber();
- switch (field) {
- case 1:
- var value = new common_pb.Instance;
- reader.readMessage(value,common_pb.Instance.deserializeBinaryFromReader);
- msg.setInstance(value);
- break;
- case 2:
- var value = /** @type {string} */ (reader.readString());
- msg.setFqbn(value);
- break;
- default:
- reader.skipField();
- break;
- }
- }
- return msg;
-};
-
-
-/**
- * Serializes the message to binary data (in protobuf wire format).
- * @return {!Uint8Array}
- */
-proto.arduino.BoardDetailsReq.prototype.serializeBinary = function() {
- var writer = new jspb.BinaryWriter();
- proto.arduino.BoardDetailsReq.serializeBinaryToWriter(this, writer);
- return writer.getResultBuffer();
-};
-
-
-/**
- * Serializes the given message to binary data (in protobuf wire
- * format), writing to the given BinaryWriter.
- * @param {!proto.arduino.BoardDetailsReq} message
- * @param {!jspb.BinaryWriter} writer
- * @suppress {unusedLocalVariables} f is only used for nested messages
- */
-proto.arduino.BoardDetailsReq.serializeBinaryToWriter = function(message, writer) {
- var f = undefined;
- f = message.getInstance();
- if (f != null) {
- writer.writeMessage(
- 1,
- f,
- common_pb.Instance.serializeBinaryToWriter
- );
- }
- f = message.getFqbn();
- if (f.length > 0) {
- writer.writeString(
- 2,
- f
- );
- }
-};
-
-
-/**
- * optional Instance instance = 1;
- * @return {?proto.arduino.Instance}
- */
-proto.arduino.BoardDetailsReq.prototype.getInstance = function() {
- return /** @type{?proto.arduino.Instance} */ (
- jspb.Message.getWrapperField(this, common_pb.Instance, 1));
-};
-
-
-/** @param {?proto.arduino.Instance|undefined} value */
-proto.arduino.BoardDetailsReq.prototype.setInstance = function(value) {
- jspb.Message.setWrapperField(this, 1, value);
-};
-
-
-proto.arduino.BoardDetailsReq.prototype.clearInstance = function() {
- this.setInstance(undefined);
-};
-
-
-/**
- * Returns whether this field is set.
- * @return {boolean}
- */
-proto.arduino.BoardDetailsReq.prototype.hasInstance = function() {
- return jspb.Message.getField(this, 1) != null;
-};
-
-
-/**
- * optional string fqbn = 2;
- * @return {string}
- */
-proto.arduino.BoardDetailsReq.prototype.getFqbn = function() {
- return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
-};
-
-
-/** @param {string} value */
-proto.arduino.BoardDetailsReq.prototype.setFqbn = function(value) {
- jspb.Message.setProto3StringField(this, 2, value);
-};
-
-
-
-/**
- * Generated by JsPbCodeGenerator.
- * @param {Array=} opt_data Optional initial data array, typically from a
- * server response, or constructed directly in Javascript. The array is used
- * in place and becomes part of the constructed object. It is not cloned.
- * If no data is provided, the constructed object will be empty, but still
- * valid.
- * @extends {jspb.Message}
- * @constructor
- */
-proto.arduino.BoardDetailsResp = function(opt_data) {
- jspb.Message.initialize(this, opt_data, 0, -1, proto.arduino.BoardDetailsResp.repeatedFields_, null);
-};
-goog.inherits(proto.arduino.BoardDetailsResp, jspb.Message);
-if (goog.DEBUG && !COMPILED) {
- proto.arduino.BoardDetailsResp.displayName = 'proto.arduino.BoardDetailsResp';
-}
-/**
- * List of repeated fields within this message type.
- * @private {!Array}
- * @const
- */
-proto.arduino.BoardDetailsResp.repeatedFields_ = [3,4];
-
-
-
-if (jspb.Message.GENERATE_TO_OBJECT) {
-/**
- * Creates an object representation of this proto suitable for use in Soy templates.
- * Field names that are reserved in JavaScript and will be renamed to pb_name.
- * To access a reserved field use, foo.pb_, eg, foo.pb_default.
- * For the list of reserved names please see:
- * com.google.apps.jspb.JsClassTemplate.JS_RESERVED_WORDS.
- * @param {boolean=} opt_includeInstance Whether to include the JSPB instance
- * for transitional soy proto support: http://goto/soy-param-migration
- * @return {!Object}
- */
-proto.arduino.BoardDetailsResp.prototype.toObject = function(opt_includeInstance) {
- return proto.arduino.BoardDetailsResp.toObject(opt_includeInstance, this);
-};
-
-
-/**
- * Static version of the {@see toObject} method.
- * @param {boolean|undefined} includeInstance Whether to include the JSPB
- * instance for transitional soy proto support:
- * http://goto/soy-param-migration
- * @param {!proto.arduino.BoardDetailsResp} msg The msg instance to transform.
- * @return {!Object}
- * @suppress {unusedLocalVariables} f is only used for nested messages
- */
-proto.arduino.BoardDetailsResp.toObject = function(includeInstance, msg) {
- var f, obj = {
- name: jspb.Message.getFieldWithDefault(msg, 2, ""),
- configOptionsList: jspb.Message.toObjectList(msg.getConfigOptionsList(),
- proto.arduino.ConfigOption.toObject, includeInstance),
- requiredToolsList: jspb.Message.toObjectList(msg.getRequiredToolsList(),
- proto.arduino.RequiredTool.toObject, includeInstance)
- };
-
- if (includeInstance) {
- obj.$jspbMessageInstance = msg;
- }
- return obj;
-};
-}
-
-
-/**
- * Deserializes binary data (in protobuf wire format).
- * @param {jspb.ByteSource} bytes The bytes to deserialize.
- * @return {!proto.arduino.BoardDetailsResp}
- */
-proto.arduino.BoardDetailsResp.deserializeBinary = function(bytes) {
- var reader = new jspb.BinaryReader(bytes);
- var msg = new proto.arduino.BoardDetailsResp;
- return proto.arduino.BoardDetailsResp.deserializeBinaryFromReader(msg, reader);
-};
-
-
-/**
- * Deserializes binary data (in protobuf wire format) from the
- * given reader into the given message object.
- * @param {!proto.arduino.BoardDetailsResp} msg The message object to deserialize into.
- * @param {!jspb.BinaryReader} reader The BinaryReader to use.
- * @return {!proto.arduino.BoardDetailsResp}
- */
-proto.arduino.BoardDetailsResp.deserializeBinaryFromReader = function(msg, reader) {
- while (reader.nextField()) {
- if (reader.isEndGroup()) {
- break;
- }
- var field = reader.getFieldNumber();
- switch (field) {
- case 2:
- var value = /** @type {string} */ (reader.readString());
- msg.setName(value);
- break;
- case 3:
- var value = new proto.arduino.ConfigOption;
- reader.readMessage(value,proto.arduino.ConfigOption.deserializeBinaryFromReader);
- msg.addConfigOptions(value);
- break;
- case 4:
- var value = new proto.arduino.RequiredTool;
- reader.readMessage(value,proto.arduino.RequiredTool.deserializeBinaryFromReader);
- msg.addRequiredTools(value);
- break;
- default:
- reader.skipField();
- break;
- }
- }
- return msg;
-};
-
-
-/**
- * Serializes the message to binary data (in protobuf wire format).
- * @return {!Uint8Array}
- */
-proto.arduino.BoardDetailsResp.prototype.serializeBinary = function() {
- var writer = new jspb.BinaryWriter();
- proto.arduino.BoardDetailsResp.serializeBinaryToWriter(this, writer);
- return writer.getResultBuffer();
-};
-
-
-/**
- * Serializes the given message to binary data (in protobuf wire
- * format), writing to the given BinaryWriter.
- * @param {!proto.arduino.BoardDetailsResp} message
- * @param {!jspb.BinaryWriter} writer
- * @suppress {unusedLocalVariables} f is only used for nested messages
- */
-proto.arduino.BoardDetailsResp.serializeBinaryToWriter = function(message, writer) {
- var f = undefined;
- f = message.getName();
- if (f.length > 0) {
- writer.writeString(
- 2,
- f
- );
- }
- f = message.getConfigOptionsList();
- if (f.length > 0) {
- writer.writeRepeatedMessage(
- 3,
- f,
- proto.arduino.ConfigOption.serializeBinaryToWriter
- );
- }
- f = message.getRequiredToolsList();
- if (f.length > 0) {
- writer.writeRepeatedMessage(
- 4,
- f,
- proto.arduino.RequiredTool.serializeBinaryToWriter
- );
- }
-};
-
-
-/**
- * optional string name = 2;
- * @return {string}
- */
-proto.arduino.BoardDetailsResp.prototype.getName = function() {
- return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
-};
-
-
-/** @param {string} value */
-proto.arduino.BoardDetailsResp.prototype.setName = function(value) {
- jspb.Message.setProto3StringField(this, 2, value);
-};
-
-
-/**
- * repeated ConfigOption config_options = 3;
- * @return {!Array}
- */
-proto.arduino.BoardDetailsResp.prototype.getConfigOptionsList = function() {
- return /** @type{!Array} */ (
- jspb.Message.getRepeatedWrapperField(this, proto.arduino.ConfigOption, 3));
-};
-
-
-/** @param {!Array} value */
-proto.arduino.BoardDetailsResp.prototype.setConfigOptionsList = function(value) {
- jspb.Message.setRepeatedWrapperField(this, 3, value);
-};
-
-
-/**
- * @param {!proto.arduino.ConfigOption=} opt_value
- * @param {number=} opt_index
- * @return {!proto.arduino.ConfigOption}
- */
-proto.arduino.BoardDetailsResp.prototype.addConfigOptions = function(opt_value, opt_index) {
- return jspb.Message.addToRepeatedWrapperField(this, 3, opt_value, proto.arduino.ConfigOption, opt_index);
-};
-
-
-proto.arduino.BoardDetailsResp.prototype.clearConfigOptionsList = function() {
- this.setConfigOptionsList([]);
-};
-
-
-/**
- * repeated RequiredTool required_tools = 4;
- * @return {!Array}
- */
-proto.arduino.BoardDetailsResp.prototype.getRequiredToolsList = function() {
- return /** @type{!Array} */ (
- jspb.Message.getRepeatedWrapperField(this, proto.arduino.RequiredTool, 4));
-};
-
-
-/** @param {!Array} value */
-proto.arduino.BoardDetailsResp.prototype.setRequiredToolsList = function(value) {
- jspb.Message.setRepeatedWrapperField(this, 4, value);
-};
-
-
-/**
- * @param {!proto.arduino.RequiredTool=} opt_value
- * @param {number=} opt_index
- * @return {!proto.arduino.RequiredTool}
- */
-proto.arduino.BoardDetailsResp.prototype.addRequiredTools = function(opt_value, opt_index) {
- return jspb.Message.addToRepeatedWrapperField(this, 4, opt_value, proto.arduino.RequiredTool, opt_index);
-};
-
-
-proto.arduino.BoardDetailsResp.prototype.clearRequiredToolsList = function() {
- this.setRequiredToolsList([]);
-};
-
-
-
-/**
- * Generated by JsPbCodeGenerator.
- * @param {Array=} opt_data Optional initial data array, typically from a
- * server response, or constructed directly in Javascript. The array is used
- * in place and becomes part of the constructed object. It is not cloned.
- * If no data is provided, the constructed object will be empty, but still
- * valid.
- * @extends {jspb.Message}
- * @constructor
- */
-proto.arduino.ConfigOption = function(opt_data) {
- jspb.Message.initialize(this, opt_data, 0, -1, proto.arduino.ConfigOption.repeatedFields_, null);
-};
-goog.inherits(proto.arduino.ConfigOption, jspb.Message);
-if (goog.DEBUG && !COMPILED) {
- proto.arduino.ConfigOption.displayName = 'proto.arduino.ConfigOption';
-}
-/**
- * List of repeated fields within this message type.
- * @private {!Array}
- * @const
- */
-proto.arduino.ConfigOption.repeatedFields_ = [3];
-
-
-
-if (jspb.Message.GENERATE_TO_OBJECT) {
-/**
- * Creates an object representation of this proto suitable for use in Soy templates.
- * Field names that are reserved in JavaScript and will be renamed to pb_name.
- * To access a reserved field use, foo.pb_, eg, foo.pb_default.
- * For the list of reserved names please see:
- * com.google.apps.jspb.JsClassTemplate.JS_RESERVED_WORDS.
- * @param {boolean=} opt_includeInstance Whether to include the JSPB instance
- * for transitional soy proto support: http://goto/soy-param-migration
- * @return {!Object}
- */
-proto.arduino.ConfigOption.prototype.toObject = function(opt_includeInstance) {
- return proto.arduino.ConfigOption.toObject(opt_includeInstance, this);
-};
-
-
-/**
- * Static version of the {@see toObject} method.
- * @param {boolean|undefined} includeInstance Whether to include the JSPB
- * instance for transitional soy proto support:
- * http://goto/soy-param-migration
- * @param {!proto.arduino.ConfigOption} msg The msg instance to transform.
- * @return {!Object}
- * @suppress {unusedLocalVariables} f is only used for nested messages
- */
-proto.arduino.ConfigOption.toObject = function(includeInstance, msg) {
- var f, obj = {
- option: jspb.Message.getFieldWithDefault(msg, 1, ""),
- optionLabel: jspb.Message.getFieldWithDefault(msg, 2, ""),
- valuesList: jspb.Message.toObjectList(msg.getValuesList(),
- proto.arduino.ConfigValue.toObject, includeInstance)
- };
-
- if (includeInstance) {
- obj.$jspbMessageInstance = msg;
- }
- return obj;
-};
-}
-
-
-/**
- * Deserializes binary data (in protobuf wire format).
- * @param {jspb.ByteSource} bytes The bytes to deserialize.
- * @return {!proto.arduino.ConfigOption}
- */
-proto.arduino.ConfigOption.deserializeBinary = function(bytes) {
- var reader = new jspb.BinaryReader(bytes);
- var msg = new proto.arduino.ConfigOption;
- return proto.arduino.ConfigOption.deserializeBinaryFromReader(msg, reader);
-};
-
-
-/**
- * Deserializes binary data (in protobuf wire format) from the
- * given reader into the given message object.
- * @param {!proto.arduino.ConfigOption} msg The message object to deserialize into.
- * @param {!jspb.BinaryReader} reader The BinaryReader to use.
- * @return {!proto.arduino.ConfigOption}
- */
-proto.arduino.ConfigOption.deserializeBinaryFromReader = function(msg, reader) {
- while (reader.nextField()) {
- if (reader.isEndGroup()) {
- break;
- }
- var field = reader.getFieldNumber();
- switch (field) {
- case 1:
- var value = /** @type {string} */ (reader.readString());
- msg.setOption(value);
- break;
- case 2:
- var value = /** @type {string} */ (reader.readString());
- msg.setOptionLabel(value);
- break;
- case 3:
- var value = new proto.arduino.ConfigValue;
- reader.readMessage(value,proto.arduino.ConfigValue.deserializeBinaryFromReader);
- msg.addValues(value);
- break;
- default:
- reader.skipField();
- break;
- }
- }
- return msg;
-};
-
-
-/**
- * Serializes the message to binary data (in protobuf wire format).
- * @return {!Uint8Array}
- */
-proto.arduino.ConfigOption.prototype.serializeBinary = function() {
- var writer = new jspb.BinaryWriter();
- proto.arduino.ConfigOption.serializeBinaryToWriter(this, writer);
- return writer.getResultBuffer();
-};
-
-
-/**
- * Serializes the given message to binary data (in protobuf wire
- * format), writing to the given BinaryWriter.
- * @param {!proto.arduino.ConfigOption} message
- * @param {!jspb.BinaryWriter} writer
- * @suppress {unusedLocalVariables} f is only used for nested messages
- */
-proto.arduino.ConfigOption.serializeBinaryToWriter = function(message, writer) {
- var f = undefined;
- f = message.getOption();
- if (f.length > 0) {
- writer.writeString(
- 1,
- f
- );
- }
- f = message.getOptionLabel();
- if (f.length > 0) {
- writer.writeString(
- 2,
- f
- );
- }
- f = message.getValuesList();
- if (f.length > 0) {
- writer.writeRepeatedMessage(
- 3,
- f,
- proto.arduino.ConfigValue.serializeBinaryToWriter
- );
- }
-};
-
-
-/**
- * optional string option = 1;
- * @return {string}
- */
-proto.arduino.ConfigOption.prototype.getOption = function() {
- return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
-};
-
-
-/** @param {string} value */
-proto.arduino.ConfigOption.prototype.setOption = function(value) {
- jspb.Message.setProto3StringField(this, 1, value);
-};
-
-
-/**
- * optional string option_label = 2;
- * @return {string}
- */
-proto.arduino.ConfigOption.prototype.getOptionLabel = function() {
- return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
-};
-
-
-/** @param {string} value */
-proto.arduino.ConfigOption.prototype.setOptionLabel = function(value) {
- jspb.Message.setProto3StringField(this, 2, value);
-};
-
-
-/**
- * repeated ConfigValue values = 3;
- * @return {!Array}
- */
-proto.arduino.ConfigOption.prototype.getValuesList = function() {
- return /** @type{!Array} */ (
- jspb.Message.getRepeatedWrapperField(this, proto.arduino.ConfigValue, 3));
-};
-
-
-/** @param {!Array} value */
-proto.arduino.ConfigOption.prototype.setValuesList = function(value) {
- jspb.Message.setRepeatedWrapperField(this, 3, value);
-};
-
-
-/**
- * @param {!proto.arduino.ConfigValue=} opt_value
- * @param {number=} opt_index
- * @return {!proto.arduino.ConfigValue}
- */
-proto.arduino.ConfigOption.prototype.addValues = function(opt_value, opt_index) {
- return jspb.Message.addToRepeatedWrapperField(this, 3, opt_value, proto.arduino.ConfigValue, opt_index);
-};
-
-
-proto.arduino.ConfigOption.prototype.clearValuesList = function() {
- this.setValuesList([]);
-};
-
-
-
-/**
- * Generated by JsPbCodeGenerator.
- * @param {Array=} opt_data Optional initial data array, typically from a
- * server response, or constructed directly in Javascript. The array is used
- * in place and becomes part of the constructed object. It is not cloned.
- * If no data is provided, the constructed object will be empty, but still
- * valid.
- * @extends {jspb.Message}
- * @constructor
- */
-proto.arduino.ConfigValue = function(opt_data) {
- jspb.Message.initialize(this, opt_data, 0, -1, null, null);
-};
-goog.inherits(proto.arduino.ConfigValue, jspb.Message);
-if (goog.DEBUG && !COMPILED) {
- proto.arduino.ConfigValue.displayName = 'proto.arduino.ConfigValue';
-}
-
-
-if (jspb.Message.GENERATE_TO_OBJECT) {
-/**
- * Creates an object representation of this proto suitable for use in Soy templates.
- * Field names that are reserved in JavaScript and will be renamed to pb_name.
- * To access a reserved field use, foo.pb_, eg, foo.pb_default.
- * For the list of reserved names please see:
- * com.google.apps.jspb.JsClassTemplate.JS_RESERVED_WORDS.
- * @param {boolean=} opt_includeInstance Whether to include the JSPB instance
- * for transitional soy proto support: http://goto/soy-param-migration
- * @return {!Object}
- */
-proto.arduino.ConfigValue.prototype.toObject = function(opt_includeInstance) {
- return proto.arduino.ConfigValue.toObject(opt_includeInstance, this);
-};
-
-
-/**
- * Static version of the {@see toObject} method.
- * @param {boolean|undefined} includeInstance Whether to include the JSPB
- * instance for transitional soy proto support:
- * http://goto/soy-param-migration
- * @param {!proto.arduino.ConfigValue} msg The msg instance to transform.
- * @return {!Object}
- * @suppress {unusedLocalVariables} f is only used for nested messages
- */
-proto.arduino.ConfigValue.toObject = function(includeInstance, msg) {
- var f, obj = {
- value: jspb.Message.getFieldWithDefault(msg, 1, ""),
- valueLabel: jspb.Message.getFieldWithDefault(msg, 2, ""),
- selected: jspb.Message.getFieldWithDefault(msg, 3, false)
- };
-
- if (includeInstance) {
- obj.$jspbMessageInstance = msg;
- }
- return obj;
-};
-}
-
-
-/**
- * Deserializes binary data (in protobuf wire format).
- * @param {jspb.ByteSource} bytes The bytes to deserialize.
- * @return {!proto.arduino.ConfigValue}
- */
-proto.arduino.ConfigValue.deserializeBinary = function(bytes) {
- var reader = new jspb.BinaryReader(bytes);
- var msg = new proto.arduino.ConfigValue;
- return proto.arduino.ConfigValue.deserializeBinaryFromReader(msg, reader);
-};
-
-
-/**
- * Deserializes binary data (in protobuf wire format) from the
- * given reader into the given message object.
- * @param {!proto.arduino.ConfigValue} msg The message object to deserialize into.
- * @param {!jspb.BinaryReader} reader The BinaryReader to use.
- * @return {!proto.arduino.ConfigValue}
- */
-proto.arduino.ConfigValue.deserializeBinaryFromReader = function(msg, reader) {
- while (reader.nextField()) {
- if (reader.isEndGroup()) {
- break;
- }
- var field = reader.getFieldNumber();
- switch (field) {
- case 1:
- var value = /** @type {string} */ (reader.readString());
- msg.setValue(value);
- break;
- case 2:
- var value = /** @type {string} */ (reader.readString());
- msg.setValueLabel(value);
- break;
- case 3:
- var value = /** @type {boolean} */ (reader.readBool());
- msg.setSelected(value);
- break;
- default:
- reader.skipField();
- break;
- }
- }
- return msg;
-};
-
-
-/**
- * Serializes the message to binary data (in protobuf wire format).
- * @return {!Uint8Array}
- */
-proto.arduino.ConfigValue.prototype.serializeBinary = function() {
- var writer = new jspb.BinaryWriter();
- proto.arduino.ConfigValue.serializeBinaryToWriter(this, writer);
- return writer.getResultBuffer();
-};
-
-
-/**
- * Serializes the given message to binary data (in protobuf wire
- * format), writing to the given BinaryWriter.
- * @param {!proto.arduino.ConfigValue} message
- * @param {!jspb.BinaryWriter} writer
- * @suppress {unusedLocalVariables} f is only used for nested messages
- */
-proto.arduino.ConfigValue.serializeBinaryToWriter = function(message, writer) {
- var f = undefined;
- f = message.getValue();
- if (f.length > 0) {
- writer.writeString(
- 1,
- f
- );
- }
- f = message.getValueLabel();
- if (f.length > 0) {
- writer.writeString(
- 2,
- f
- );
- }
- f = message.getSelected();
- if (f) {
- writer.writeBool(
- 3,
- f
- );
- }
-};
-
-
-/**
- * optional string value = 1;
- * @return {string}
- */
-proto.arduino.ConfigValue.prototype.getValue = function() {
- return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
-};
-
-
-/** @param {string} value */
-proto.arduino.ConfigValue.prototype.setValue = function(value) {
- jspb.Message.setProto3StringField(this, 1, value);
-};
-
-
-/**
- * optional string value_label = 2;
- * @return {string}
- */
-proto.arduino.ConfigValue.prototype.getValueLabel = function() {
- return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
-};
-
-
-/** @param {string} value */
-proto.arduino.ConfigValue.prototype.setValueLabel = function(value) {
- jspb.Message.setProto3StringField(this, 2, value);
-};
-
-
-/**
- * optional bool selected = 3;
- * Note that Boolean fields may be set to 0/1 when serialized from a Java server.
- * You should avoid comparisons like {@code val === true/false} in those cases.
- * @return {boolean}
- */
-proto.arduino.ConfigValue.prototype.getSelected = function() {
- return /** @type {boolean} */ (jspb.Message.getFieldWithDefault(this, 3, false));
-};
-
-
-/** @param {boolean} value */
-proto.arduino.ConfigValue.prototype.setSelected = function(value) {
- jspb.Message.setProto3BooleanField(this, 3, value);
-};
-
-
-
-/**
- * Generated by JsPbCodeGenerator.
- * @param {Array=} opt_data Optional initial data array, typically from a
- * server response, or constructed directly in Javascript. The array is used
- * in place and becomes part of the constructed object. It is not cloned.
- * If no data is provided, the constructed object will be empty, but still
- * valid.
- * @extends {jspb.Message}
- * @constructor
- */
-proto.arduino.RequiredTool = function(opt_data) {
- jspb.Message.initialize(this, opt_data, 0, -1, null, null);
-};
-goog.inherits(proto.arduino.RequiredTool, jspb.Message);
-if (goog.DEBUG && !COMPILED) {
- proto.arduino.RequiredTool.displayName = 'proto.arduino.RequiredTool';
-}
-
-
-if (jspb.Message.GENERATE_TO_OBJECT) {
-/**
- * Creates an object representation of this proto suitable for use in Soy templates.
- * Field names that are reserved in JavaScript and will be renamed to pb_name.
- * To access a reserved field use, foo.pb_, eg, foo.pb_default.
- * For the list of reserved names please see:
- * com.google.apps.jspb.JsClassTemplate.JS_RESERVED_WORDS.
- * @param {boolean=} opt_includeInstance Whether to include the JSPB instance
- * for transitional soy proto support: http://goto/soy-param-migration
- * @return {!Object}
- */
-proto.arduino.RequiredTool.prototype.toObject = function(opt_includeInstance) {
- return proto.arduino.RequiredTool.toObject(opt_includeInstance, this);
-};
-
-
-/**
- * Static version of the {@see toObject} method.
- * @param {boolean|undefined} includeInstance Whether to include the JSPB
- * instance for transitional soy proto support:
- * http://goto/soy-param-migration
- * @param {!proto.arduino.RequiredTool} msg The msg instance to transform.
- * @return {!Object}
- * @suppress {unusedLocalVariables} f is only used for nested messages
- */
-proto.arduino.RequiredTool.toObject = function(includeInstance, msg) {
- var f, obj = {
- name: jspb.Message.getFieldWithDefault(msg, 1, ""),
- version: jspb.Message.getFieldWithDefault(msg, 2, ""),
- packager: jspb.Message.getFieldWithDefault(msg, 3, "")
- };
-
- if (includeInstance) {
- obj.$jspbMessageInstance = msg;
- }
- return obj;
-};
-}
-
-
-/**
- * Deserializes binary data (in protobuf wire format).
- * @param {jspb.ByteSource} bytes The bytes to deserialize.
- * @return {!proto.arduino.RequiredTool}
- */
-proto.arduino.RequiredTool.deserializeBinary = function(bytes) {
- var reader = new jspb.BinaryReader(bytes);
- var msg = new proto.arduino.RequiredTool;
- return proto.arduino.RequiredTool.deserializeBinaryFromReader(msg, reader);
-};
-
-
-/**
- * Deserializes binary data (in protobuf wire format) from the
- * given reader into the given message object.
- * @param {!proto.arduino.RequiredTool} msg The message object to deserialize into.
- * @param {!jspb.BinaryReader} reader The BinaryReader to use.
- * @return {!proto.arduino.RequiredTool}
- */
-proto.arduino.RequiredTool.deserializeBinaryFromReader = function(msg, reader) {
- while (reader.nextField()) {
- if (reader.isEndGroup()) {
- break;
- }
- var field = reader.getFieldNumber();
- switch (field) {
- case 1:
- var value = /** @type {string} */ (reader.readString());
- msg.setName(value);
- break;
- case 2:
- var value = /** @type {string} */ (reader.readString());
- msg.setVersion(value);
- break;
- case 3:
- var value = /** @type {string} */ (reader.readString());
- msg.setPackager(value);
- break;
- default:
- reader.skipField();
- break;
- }
- }
- return msg;
-};
-
-
-/**
- * Serializes the message to binary data (in protobuf wire format).
- * @return {!Uint8Array}
- */
-proto.arduino.RequiredTool.prototype.serializeBinary = function() {
- var writer = new jspb.BinaryWriter();
- proto.arduino.RequiredTool.serializeBinaryToWriter(this, writer);
- return writer.getResultBuffer();
-};
-
-
-/**
- * Serializes the given message to binary data (in protobuf wire
- * format), writing to the given BinaryWriter.
- * @param {!proto.arduino.RequiredTool} message
- * @param {!jspb.BinaryWriter} writer
- * @suppress {unusedLocalVariables} f is only used for nested messages
- */
-proto.arduino.RequiredTool.serializeBinaryToWriter = function(message, writer) {
- var f = undefined;
- f = message.getName();
- if (f.length > 0) {
- writer.writeString(
- 1,
- f
- );
- }
- f = message.getVersion();
- if (f.length > 0) {
- writer.writeString(
- 2,
- f
- );
- }
- f = message.getPackager();
- if (f.length > 0) {
- writer.writeString(
- 3,
- f
- );
- }
-};
-
-
-/**
- * optional string name = 1;
- * @return {string}
- */
-proto.arduino.RequiredTool.prototype.getName = function() {
- return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
-};
-
-
-/** @param {string} value */
-proto.arduino.RequiredTool.prototype.setName = function(value) {
- jspb.Message.setProto3StringField(this, 1, value);
-};
-
-
-/**
- * optional string version = 2;
- * @return {string}
- */
-proto.arduino.RequiredTool.prototype.getVersion = function() {
- return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
-};
-
-
-/** @param {string} value */
-proto.arduino.RequiredTool.prototype.setVersion = function(value) {
- jspb.Message.setProto3StringField(this, 2, value);
-};
-
-
-/**
- * optional string packager = 3;
- * @return {string}
- */
-proto.arduino.RequiredTool.prototype.getPackager = function() {
- return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 3, ""));
-};
-
-
-/** @param {string} value */
-proto.arduino.RequiredTool.prototype.setPackager = function(value) {
- jspb.Message.setProto3StringField(this, 3, value);
-};
-
-
-
-/**
- * Generated by JsPbCodeGenerator.
- * @param {Array=} opt_data Optional initial data array, typically from a
- * server response, or constructed directly in Javascript. The array is used
- * in place and becomes part of the constructed object. It is not cloned.
- * If no data is provided, the constructed object will be empty, but still
- * valid.
- * @extends {jspb.Message}
- * @constructor
- */
-proto.arduino.BoardListReq = function(opt_data) {
- jspb.Message.initialize(this, opt_data, 0, -1, null, null);
-};
-goog.inherits(proto.arduino.BoardListReq, jspb.Message);
-if (goog.DEBUG && !COMPILED) {
- proto.arduino.BoardListReq.displayName = 'proto.arduino.BoardListReq';
-}
-
-
-if (jspb.Message.GENERATE_TO_OBJECT) {
-/**
- * Creates an object representation of this proto suitable for use in Soy templates.
- * Field names that are reserved in JavaScript and will be renamed to pb_name.
- * To access a reserved field use, foo.pb_, eg, foo.pb_default.
- * For the list of reserved names please see:
- * com.google.apps.jspb.JsClassTemplate.JS_RESERVED_WORDS.
- * @param {boolean=} opt_includeInstance Whether to include the JSPB instance
- * for transitional soy proto support: http://goto/soy-param-migration
- * @return {!Object}
- */
-proto.arduino.BoardListReq.prototype.toObject = function(opt_includeInstance) {
- return proto.arduino.BoardListReq.toObject(opt_includeInstance, this);
-};
-
-
-/**
- * Static version of the {@see toObject} method.
- * @param {boolean|undefined} includeInstance Whether to include the JSPB
- * instance for transitional soy proto support:
- * http://goto/soy-param-migration
- * @param {!proto.arduino.BoardListReq} msg The msg instance to transform.
- * @return {!Object}
- * @suppress {unusedLocalVariables} f is only used for nested messages
- */
-proto.arduino.BoardListReq.toObject = function(includeInstance, msg) {
- var f, obj = {
- instance: (f = msg.getInstance()) && common_pb.Instance.toObject(includeInstance, f)
- };
-
- if (includeInstance) {
- obj.$jspbMessageInstance = msg;
- }
- return obj;
-};
-}
-
-
-/**
- * Deserializes binary data (in protobuf wire format).
- * @param {jspb.ByteSource} bytes The bytes to deserialize.
- * @return {!proto.arduino.BoardListReq}
- */
-proto.arduino.BoardListReq.deserializeBinary = function(bytes) {
- var reader = new jspb.BinaryReader(bytes);
- var msg = new proto.arduino.BoardListReq;
- return proto.arduino.BoardListReq.deserializeBinaryFromReader(msg, reader);
-};
-
-
-/**
- * Deserializes binary data (in protobuf wire format) from the
- * given reader into the given message object.
- * @param {!proto.arduino.BoardListReq} msg The message object to deserialize into.
- * @param {!jspb.BinaryReader} reader The BinaryReader to use.
- * @return {!proto.arduino.BoardListReq}
- */
-proto.arduino.BoardListReq.deserializeBinaryFromReader = function(msg, reader) {
- while (reader.nextField()) {
- if (reader.isEndGroup()) {
- break;
- }
- var field = reader.getFieldNumber();
- switch (field) {
- case 1:
- var value = new common_pb.Instance;
- reader.readMessage(value,common_pb.Instance.deserializeBinaryFromReader);
- msg.setInstance(value);
- break;
- default:
- reader.skipField();
- break;
- }
- }
- return msg;
-};
-
-
-/**
- * Serializes the message to binary data (in protobuf wire format).
- * @return {!Uint8Array}
- */
-proto.arduino.BoardListReq.prototype.serializeBinary = function() {
- var writer = new jspb.BinaryWriter();
- proto.arduino.BoardListReq.serializeBinaryToWriter(this, writer);
- return writer.getResultBuffer();
-};
-
-
-/**
- * Serializes the given message to binary data (in protobuf wire
- * format), writing to the given BinaryWriter.
- * @param {!proto.arduino.BoardListReq} message
- * @param {!jspb.BinaryWriter} writer
- * @suppress {unusedLocalVariables} f is only used for nested messages
- */
-proto.arduino.BoardListReq.serializeBinaryToWriter = function(message, writer) {
- var f = undefined;
- f = message.getInstance();
- if (f != null) {
- writer.writeMessage(
- 1,
- f,
- common_pb.Instance.serializeBinaryToWriter
- );
- }
-};
-
-
-/**
- * optional Instance instance = 1;
- * @return {?proto.arduino.Instance}
- */
-proto.arduino.BoardListReq.prototype.getInstance = function() {
- return /** @type{?proto.arduino.Instance} */ (
- jspb.Message.getWrapperField(this, common_pb.Instance, 1));
-};
-
-
-/** @param {?proto.arduino.Instance|undefined} value */
-proto.arduino.BoardListReq.prototype.setInstance = function(value) {
- jspb.Message.setWrapperField(this, 1, value);
-};
-
-
-proto.arduino.BoardListReq.prototype.clearInstance = function() {
- this.setInstance(undefined);
-};
-
-
-/**
- * Returns whether this field is set.
- * @return {boolean}
- */
-proto.arduino.BoardListReq.prototype.hasInstance = function() {
- return jspb.Message.getField(this, 1) != null;
-};
-
-
-
-/**
- * Generated by JsPbCodeGenerator.
- * @param {Array=} opt_data Optional initial data array, typically from a
- * server response, or constructed directly in Javascript. The array is used
- * in place and becomes part of the constructed object. It is not cloned.
- * If no data is provided, the constructed object will be empty, but still
- * valid.
- * @extends {jspb.Message}
- * @constructor
- */
-proto.arduino.BoardListResp = function(opt_data) {
- jspb.Message.initialize(this, opt_data, 0, -1, proto.arduino.BoardListResp.repeatedFields_, null);
-};
-goog.inherits(proto.arduino.BoardListResp, jspb.Message);
-if (goog.DEBUG && !COMPILED) {
- proto.arduino.BoardListResp.displayName = 'proto.arduino.BoardListResp';
-}
-/**
- * List of repeated fields within this message type.
- * @private {!Array}
- * @const
- */
-proto.arduino.BoardListResp.repeatedFields_ = [1,2];
-
-
-
-if (jspb.Message.GENERATE_TO_OBJECT) {
-/**
- * Creates an object representation of this proto suitable for use in Soy templates.
- * Field names that are reserved in JavaScript and will be renamed to pb_name.
- * To access a reserved field use, foo.pb_, eg, foo.pb_default.
- * For the list of reserved names please see:
- * com.google.apps.jspb.JsClassTemplate.JS_RESERVED_WORDS.
- * @param {boolean=} opt_includeInstance Whether to include the JSPB instance
- * for transitional soy proto support: http://goto/soy-param-migration
- * @return {!Object}
- */
-proto.arduino.BoardListResp.prototype.toObject = function(opt_includeInstance) {
- return proto.arduino.BoardListResp.toObject(opt_includeInstance, this);
-};
-
-
-/**
- * Static version of the {@see toObject} method.
- * @param {boolean|undefined} includeInstance Whether to include the JSPB
- * instance for transitional soy proto support:
- * http://goto/soy-param-migration
- * @param {!proto.arduino.BoardListResp} msg The msg instance to transform.
- * @return {!Object}
- * @suppress {unusedLocalVariables} f is only used for nested messages
- */
-proto.arduino.BoardListResp.toObject = function(includeInstance, msg) {
- var f, obj = {
- serialList: jspb.Message.toObjectList(msg.getSerialList(),
- proto.arduino.AttachedSerialBoard.toObject, includeInstance),
- networkList: jspb.Message.toObjectList(msg.getNetworkList(),
- proto.arduino.AttachedNetworkBoard.toObject, includeInstance)
- };
-
- if (includeInstance) {
- obj.$jspbMessageInstance = msg;
- }
- return obj;
-};
-}
-
-
-/**
- * Deserializes binary data (in protobuf wire format).
- * @param {jspb.ByteSource} bytes The bytes to deserialize.
- * @return {!proto.arduino.BoardListResp}
- */
-proto.arduino.BoardListResp.deserializeBinary = function(bytes) {
- var reader = new jspb.BinaryReader(bytes);
- var msg = new proto.arduino.BoardListResp;
- return proto.arduino.BoardListResp.deserializeBinaryFromReader(msg, reader);
-};
-
-
-/**
- * Deserializes binary data (in protobuf wire format) from the
- * given reader into the given message object.
- * @param {!proto.arduino.BoardListResp} msg The message object to deserialize into.
- * @param {!jspb.BinaryReader} reader The BinaryReader to use.
- * @return {!proto.arduino.BoardListResp}
- */
-proto.arduino.BoardListResp.deserializeBinaryFromReader = function(msg, reader) {
- while (reader.nextField()) {
- if (reader.isEndGroup()) {
- break;
- }
- var field = reader.getFieldNumber();
- switch (field) {
- case 1:
- var value = new proto.arduino.AttachedSerialBoard;
- reader.readMessage(value,proto.arduino.AttachedSerialBoard.deserializeBinaryFromReader);
- msg.addSerial(value);
- break;
- case 2:
- var value = new proto.arduino.AttachedNetworkBoard;
- reader.readMessage(value,proto.arduino.AttachedNetworkBoard.deserializeBinaryFromReader);
- msg.addNetwork(value);
- break;
- default:
- reader.skipField();
- break;
- }
- }
- return msg;
-};
-
-
-/**
- * Serializes the message to binary data (in protobuf wire format).
- * @return {!Uint8Array}
- */
-proto.arduino.BoardListResp.prototype.serializeBinary = function() {
- var writer = new jspb.BinaryWriter();
- proto.arduino.BoardListResp.serializeBinaryToWriter(this, writer);
- return writer.getResultBuffer();
-};
-
-
-/**
- * Serializes the given message to binary data (in protobuf wire
- * format), writing to the given BinaryWriter.
- * @param {!proto.arduino.BoardListResp} message
- * @param {!jspb.BinaryWriter} writer
- * @suppress {unusedLocalVariables} f is only used for nested messages
- */
-proto.arduino.BoardListResp.serializeBinaryToWriter = function(message, writer) {
- var f = undefined;
- f = message.getSerialList();
- if (f.length > 0) {
- writer.writeRepeatedMessage(
- 1,
- f,
- proto.arduino.AttachedSerialBoard.serializeBinaryToWriter
- );
- }
- f = message.getNetworkList();
- if (f.length > 0) {
- writer.writeRepeatedMessage(
- 2,
- f,
- proto.arduino.AttachedNetworkBoard.serializeBinaryToWriter
- );
- }
-};
-
-
-/**
- * repeated AttachedSerialBoard serial = 1;
- * @return {!Array}
- */
-proto.arduino.BoardListResp.prototype.getSerialList = function() {
- return /** @type{!Array} */ (
- jspb.Message.getRepeatedWrapperField(this, proto.arduino.AttachedSerialBoard, 1));
-};
-
-
-/** @param {!Array} value */
-proto.arduino.BoardListResp.prototype.setSerialList = function(value) {
- jspb.Message.setRepeatedWrapperField(this, 1, value);
-};
-
-
-/**
- * @param {!proto.arduino.AttachedSerialBoard=} opt_value
- * @param {number=} opt_index
- * @return {!proto.arduino.AttachedSerialBoard}
- */
-proto.arduino.BoardListResp.prototype.addSerial = function(opt_value, opt_index) {
- return jspb.Message.addToRepeatedWrapperField(this, 1, opt_value, proto.arduino.AttachedSerialBoard, opt_index);
-};
-
-
-proto.arduino.BoardListResp.prototype.clearSerialList = function() {
- this.setSerialList([]);
-};
-
-
-/**
- * repeated AttachedNetworkBoard network = 2;
- * @return {!Array}
- */
-proto.arduino.BoardListResp.prototype.getNetworkList = function() {
- return /** @type{!Array} */ (
- jspb.Message.getRepeatedWrapperField(this, proto.arduino.AttachedNetworkBoard, 2));
-};
-
-
-/** @param {!Array} value */
-proto.arduino.BoardListResp.prototype.setNetworkList = function(value) {
- jspb.Message.setRepeatedWrapperField(this, 2, value);
-};
-
-
-/**
- * @param {!proto.arduino.AttachedNetworkBoard=} opt_value
- * @param {number=} opt_index
- * @return {!proto.arduino.AttachedNetworkBoard}
- */
-proto.arduino.BoardListResp.prototype.addNetwork = function(opt_value, opt_index) {
- return jspb.Message.addToRepeatedWrapperField(this, 2, opt_value, proto.arduino.AttachedNetworkBoard, opt_index);
-};
-
-
-proto.arduino.BoardListResp.prototype.clearNetworkList = function() {
- this.setNetworkList([]);
-};
-
-
-
-/**
- * Generated by JsPbCodeGenerator.
- * @param {Array=} opt_data Optional initial data array, typically from a
- * server response, or constructed directly in Javascript. The array is used
- * in place and becomes part of the constructed object. It is not cloned.
- * If no data is provided, the constructed object will be empty, but still
- * valid.
- * @extends {jspb.Message}
- * @constructor
- */
-proto.arduino.AttachedNetworkBoard = function(opt_data) {
- jspb.Message.initialize(this, opt_data, 0, -1, null, null);
-};
-goog.inherits(proto.arduino.AttachedNetworkBoard, jspb.Message);
-if (goog.DEBUG && !COMPILED) {
- proto.arduino.AttachedNetworkBoard.displayName = 'proto.arduino.AttachedNetworkBoard';
-}
-
-
-if (jspb.Message.GENERATE_TO_OBJECT) {
-/**
- * Creates an object representation of this proto suitable for use in Soy templates.
- * Field names that are reserved in JavaScript and will be renamed to pb_name.
- * To access a reserved field use, foo.pb_, eg, foo.pb_default.
- * For the list of reserved names please see:
- * com.google.apps.jspb.JsClassTemplate.JS_RESERVED_WORDS.
- * @param {boolean=} opt_includeInstance Whether to include the JSPB instance
- * for transitional soy proto support: http://goto/soy-param-migration
- * @return {!Object}
- */
-proto.arduino.AttachedNetworkBoard.prototype.toObject = function(opt_includeInstance) {
- return proto.arduino.AttachedNetworkBoard.toObject(opt_includeInstance, this);
-};
-
-
-/**
- * Static version of the {@see toObject} method.
- * @param {boolean|undefined} includeInstance Whether to include the JSPB
- * instance for transitional soy proto support:
- * http://goto/soy-param-migration
- * @param {!proto.arduino.AttachedNetworkBoard} msg The msg instance to transform.
- * @return {!Object}
- * @suppress {unusedLocalVariables} f is only used for nested messages
- */
-proto.arduino.AttachedNetworkBoard.toObject = function(includeInstance, msg) {
- var f, obj = {
- name: jspb.Message.getFieldWithDefault(msg, 1, ""),
- fqbn: jspb.Message.getFieldWithDefault(msg, 2, ""),
- info: jspb.Message.getFieldWithDefault(msg, 3, ""),
- address: jspb.Message.getFieldWithDefault(msg, 4, ""),
- port: jspb.Message.getFieldWithDefault(msg, 5, 0)
- };
-
- if (includeInstance) {
- obj.$jspbMessageInstance = msg;
- }
- return obj;
-};
-}
-
-
-/**
- * Deserializes binary data (in protobuf wire format).
- * @param {jspb.ByteSource} bytes The bytes to deserialize.
- * @return {!proto.arduino.AttachedNetworkBoard}
- */
-proto.arduino.AttachedNetworkBoard.deserializeBinary = function(bytes) {
- var reader = new jspb.BinaryReader(bytes);
- var msg = new proto.arduino.AttachedNetworkBoard;
- return proto.arduino.AttachedNetworkBoard.deserializeBinaryFromReader(msg, reader);
-};
-
-
-/**
- * Deserializes binary data (in protobuf wire format) from the
- * given reader into the given message object.
- * @param {!proto.arduino.AttachedNetworkBoard} msg The message object to deserialize into.
- * @param {!jspb.BinaryReader} reader The BinaryReader to use.
- * @return {!proto.arduino.AttachedNetworkBoard}
- */
-proto.arduino.AttachedNetworkBoard.deserializeBinaryFromReader = function(msg, reader) {
- while (reader.nextField()) {
- if (reader.isEndGroup()) {
- break;
- }
- var field = reader.getFieldNumber();
- switch (field) {
- case 1:
- var value = /** @type {string} */ (reader.readString());
- msg.setName(value);
- break;
- case 2:
- var value = /** @type {string} */ (reader.readString());
- msg.setFqbn(value);
- break;
- case 3:
- var value = /** @type {string} */ (reader.readString());
- msg.setInfo(value);
- break;
- case 4:
- var value = /** @type {string} */ (reader.readString());
- msg.setAddress(value);
- break;
- case 5:
- var value = /** @type {number} */ (reader.readUint64());
- msg.setPort(value);
- break;
- default:
- reader.skipField();
- break;
- }
- }
- return msg;
-};
-
-
-/**
- * Serializes the message to binary data (in protobuf wire format).
- * @return {!Uint8Array}
- */
-proto.arduino.AttachedNetworkBoard.prototype.serializeBinary = function() {
- var writer = new jspb.BinaryWriter();
- proto.arduino.AttachedNetworkBoard.serializeBinaryToWriter(this, writer);
- return writer.getResultBuffer();
-};
-
-
-/**
- * Serializes the given message to binary data (in protobuf wire
- * format), writing to the given BinaryWriter.
- * @param {!proto.arduino.AttachedNetworkBoard} message
- * @param {!jspb.BinaryWriter} writer
- * @suppress {unusedLocalVariables} f is only used for nested messages
- */
-proto.arduino.AttachedNetworkBoard.serializeBinaryToWriter = function(message, writer) {
- var f = undefined;
- f = message.getName();
- if (f.length > 0) {
- writer.writeString(
- 1,
- f
- );
- }
- f = message.getFqbn();
- if (f.length > 0) {
- writer.writeString(
- 2,
- f
- );
- }
- f = message.getInfo();
- if (f.length > 0) {
- writer.writeString(
- 3,
- f
- );
- }
- f = message.getAddress();
- if (f.length > 0) {
- writer.writeString(
- 4,
- f
- );
- }
- f = message.getPort();
- if (f !== 0) {
- writer.writeUint64(
- 5,
- f
- );
- }
-};
-
-
-/**
- * optional string name = 1;
- * @return {string}
- */
-proto.arduino.AttachedNetworkBoard.prototype.getName = function() {
- return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
-};
-
-
-/** @param {string} value */
-proto.arduino.AttachedNetworkBoard.prototype.setName = function(value) {
- jspb.Message.setProto3StringField(this, 1, value);
-};
-
-
-/**
- * optional string fqbn = 2;
- * @return {string}
- */
-proto.arduino.AttachedNetworkBoard.prototype.getFqbn = function() {
- return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
-};
-
-
-/** @param {string} value */
-proto.arduino.AttachedNetworkBoard.prototype.setFqbn = function(value) {
- jspb.Message.setProto3StringField(this, 2, value);
-};
-
-
-/**
- * optional string info = 3;
- * @return {string}
- */
-proto.arduino.AttachedNetworkBoard.prototype.getInfo = function() {
- return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 3, ""));
-};
-
-
-/** @param {string} value */
-proto.arduino.AttachedNetworkBoard.prototype.setInfo = function(value) {
- jspb.Message.setProto3StringField(this, 3, value);
-};
-
-
-/**
- * optional string address = 4;
- * @return {string}
- */
-proto.arduino.AttachedNetworkBoard.prototype.getAddress = function() {
- return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 4, ""));
-};
-
-
-/** @param {string} value */
-proto.arduino.AttachedNetworkBoard.prototype.setAddress = function(value) {
- jspb.Message.setProto3StringField(this, 4, value);
-};
-
-
-/**
- * optional uint64 port = 5;
- * @return {number}
- */
-proto.arduino.AttachedNetworkBoard.prototype.getPort = function() {
- return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 5, 0));
-};
-
-
-/** @param {number} value */
-proto.arduino.AttachedNetworkBoard.prototype.setPort = function(value) {
- jspb.Message.setProto3IntField(this, 5, value);
-};
-
-
-
-/**
- * Generated by JsPbCodeGenerator.
- * @param {Array=} opt_data Optional initial data array, typically from a
- * server response, or constructed directly in Javascript. The array is used
- * in place and becomes part of the constructed object. It is not cloned.
- * If no data is provided, the constructed object will be empty, but still
- * valid.
- * @extends {jspb.Message}
- * @constructor
- */
-proto.arduino.AttachedSerialBoard = function(opt_data) {
- jspb.Message.initialize(this, opt_data, 0, -1, null, null);
-};
-goog.inherits(proto.arduino.AttachedSerialBoard, jspb.Message);
-if (goog.DEBUG && !COMPILED) {
- proto.arduino.AttachedSerialBoard.displayName = 'proto.arduino.AttachedSerialBoard';
-}
-
-
-if (jspb.Message.GENERATE_TO_OBJECT) {
-/**
- * Creates an object representation of this proto suitable for use in Soy templates.
- * Field names that are reserved in JavaScript and will be renamed to pb_name.
- * To access a reserved field use, foo.pb_, eg, foo.pb_default.
- * For the list of reserved names please see:
- * com.google.apps.jspb.JsClassTemplate.JS_RESERVED_WORDS.
- * @param {boolean=} opt_includeInstance Whether to include the JSPB instance
- * for transitional soy proto support: http://goto/soy-param-migration
- * @return {!Object}
- */
-proto.arduino.AttachedSerialBoard.prototype.toObject = function(opt_includeInstance) {
- return proto.arduino.AttachedSerialBoard.toObject(opt_includeInstance, this);
-};
-
-
-/**
- * Static version of the {@see toObject} method.
- * @param {boolean|undefined} includeInstance Whether to include the JSPB
- * instance for transitional soy proto support:
- * http://goto/soy-param-migration
- * @param {!proto.arduino.AttachedSerialBoard} msg The msg instance to transform.
- * @return {!Object}
- * @suppress {unusedLocalVariables} f is only used for nested messages
- */
-proto.arduino.AttachedSerialBoard.toObject = function(includeInstance, msg) {
- var f, obj = {
- name: jspb.Message.getFieldWithDefault(msg, 1, ""),
- fqbn: jspb.Message.getFieldWithDefault(msg, 2, ""),
- port: jspb.Message.getFieldWithDefault(msg, 3, ""),
- serialnumber: jspb.Message.getFieldWithDefault(msg, 4, ""),
- productid: jspb.Message.getFieldWithDefault(msg, 5, ""),
- vendorid: jspb.Message.getFieldWithDefault(msg, 6, "")
- };
-
- if (includeInstance) {
- obj.$jspbMessageInstance = msg;
- }
- return obj;
-};
-}
-
-
-/**
- * Deserializes binary data (in protobuf wire format).
- * @param {jspb.ByteSource} bytes The bytes to deserialize.
- * @return {!proto.arduino.AttachedSerialBoard}
- */
-proto.arduino.AttachedSerialBoard.deserializeBinary = function(bytes) {
- var reader = new jspb.BinaryReader(bytes);
- var msg = new proto.arduino.AttachedSerialBoard;
- return proto.arduino.AttachedSerialBoard.deserializeBinaryFromReader(msg, reader);
-};
-
-
-/**
- * Deserializes binary data (in protobuf wire format) from the
- * given reader into the given message object.
- * @param {!proto.arduino.AttachedSerialBoard} msg The message object to deserialize into.
- * @param {!jspb.BinaryReader} reader The BinaryReader to use.
- * @return {!proto.arduino.AttachedSerialBoard}
- */
-proto.arduino.AttachedSerialBoard.deserializeBinaryFromReader = function(msg, reader) {
- while (reader.nextField()) {
- if (reader.isEndGroup()) {
- break;
- }
- var field = reader.getFieldNumber();
- switch (field) {
- case 1:
- var value = /** @type {string} */ (reader.readString());
- msg.setName(value);
- break;
- case 2:
- var value = /** @type {string} */ (reader.readString());
- msg.setFqbn(value);
- break;
- case 3:
- var value = /** @type {string} */ (reader.readString());
- msg.setPort(value);
- break;
- case 4:
- var value = /** @type {string} */ (reader.readString());
- msg.setSerialnumber(value);
- break;
- case 5:
- var value = /** @type {string} */ (reader.readString());
- msg.setProductid(value);
- break;
- case 6:
- var value = /** @type {string} */ (reader.readString());
- msg.setVendorid(value);
- break;
- default:
- reader.skipField();
- break;
- }
- }
- return msg;
-};
-
-
-/**
- * Serializes the message to binary data (in protobuf wire format).
- * @return {!Uint8Array}
- */
-proto.arduino.AttachedSerialBoard.prototype.serializeBinary = function() {
- var writer = new jspb.BinaryWriter();
- proto.arduino.AttachedSerialBoard.serializeBinaryToWriter(this, writer);
- return writer.getResultBuffer();
-};
-
-
-/**
- * Serializes the given message to binary data (in protobuf wire
- * format), writing to the given BinaryWriter.
- * @param {!proto.arduino.AttachedSerialBoard} message
- * @param {!jspb.BinaryWriter} writer
- * @suppress {unusedLocalVariables} f is only used for nested messages
- */
-proto.arduino.AttachedSerialBoard.serializeBinaryToWriter = function(message, writer) {
- var f = undefined;
- f = message.getName();
- if (f.length > 0) {
- writer.writeString(
- 1,
- f
- );
- }
- f = message.getFqbn();
- if (f.length > 0) {
- writer.writeString(
- 2,
- f
- );
- }
- f = message.getPort();
- if (f.length > 0) {
- writer.writeString(
- 3,
- f
- );
- }
- f = message.getSerialnumber();
- if (f.length > 0) {
- writer.writeString(
- 4,
- f
- );
- }
- f = message.getProductid();
- if (f.length > 0) {
- writer.writeString(
- 5,
- f
- );
- }
- f = message.getVendorid();
- if (f.length > 0) {
- writer.writeString(
- 6,
- f
- );
- }
-};
-
-
-/**
- * optional string name = 1;
- * @return {string}
- */
-proto.arduino.AttachedSerialBoard.prototype.getName = function() {
- return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
-};
-
-
-/** @param {string} value */
-proto.arduino.AttachedSerialBoard.prototype.setName = function(value) {
- jspb.Message.setProto3StringField(this, 1, value);
-};
-
-
-/**
- * optional string fqbn = 2;
- * @return {string}
- */
-proto.arduino.AttachedSerialBoard.prototype.getFqbn = function() {
- return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
-};
-
-
-/** @param {string} value */
-proto.arduino.AttachedSerialBoard.prototype.setFqbn = function(value) {
- jspb.Message.setProto3StringField(this, 2, value);
-};
-
-
-/**
- * optional string port = 3;
- * @return {string}
- */
-proto.arduino.AttachedSerialBoard.prototype.getPort = function() {
- return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 3, ""));
-};
-
-
-/** @param {string} value */
-proto.arduino.AttachedSerialBoard.prototype.setPort = function(value) {
- jspb.Message.setProto3StringField(this, 3, value);
-};
-
-
-/**
- * optional string serialNumber = 4;
- * @return {string}
- */
-proto.arduino.AttachedSerialBoard.prototype.getSerialnumber = function() {
- return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 4, ""));
-};
-
-
-/** @param {string} value */
-proto.arduino.AttachedSerialBoard.prototype.setSerialnumber = function(value) {
- jspb.Message.setProto3StringField(this, 4, value);
-};
-
-
-/**
- * optional string productID = 5;
- * @return {string}
- */
-proto.arduino.AttachedSerialBoard.prototype.getProductid = function() {
- return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 5, ""));
-};
-
-
-/** @param {string} value */
-proto.arduino.AttachedSerialBoard.prototype.setProductid = function(value) {
- jspb.Message.setProto3StringField(this, 5, value);
-};
-
-
-/**
- * optional string vendorID = 6;
- * @return {string}
- */
-proto.arduino.AttachedSerialBoard.prototype.getVendorid = function() {
- return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 6, ""));
-};
-
-
-/** @param {string} value */
-proto.arduino.AttachedSerialBoard.prototype.setVendorid = function(value) {
- jspb.Message.setProto3StringField(this, 6, value);
-};
-
-
-goog.object.extend(exports, proto.arduino);
diff --git a/arduino-ide-extension/src/node/cli-protocol/board_grpc_pb.js b/arduino-ide-extension/src/node/cli-protocol/commands/board_grpc_pb.js
similarity index 100%
rename from arduino-ide-extension/src/node/cli-protocol/board_grpc_pb.js
rename to arduino-ide-extension/src/node/cli-protocol/commands/board_grpc_pb.js
diff --git a/arduino-ide-extension/src/node/cli-protocol/board_pb.d.ts b/arduino-ide-extension/src/node/cli-protocol/commands/board_pb.d.ts
similarity index 53%
rename from arduino-ide-extension/src/node/cli-protocol/board_pb.d.ts
rename to arduino-ide-extension/src/node/cli-protocol/commands/board_pb.d.ts
index 303a355a..e78525fe 100644
--- a/arduino-ide-extension/src/node/cli-protocol/board_pb.d.ts
+++ b/arduino-ide-extension/src/node/cli-protocol/commands/board_pb.d.ts
@@ -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};
+ static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo};
+ 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};
+ static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo};
+ 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;
- setSerialList(value: Array): void;
- addSerial(value?: AttachedSerialBoard, index?: number): AttachedSerialBoard;
-
- clearNetworkList(): void;
- getNetworkList(): Array;
- setNetworkList(value: Array): void;
- addNetwork(value?: AttachedNetworkBoard, index?: number): AttachedNetworkBoard;
+ clearPortsList(): void;
+ getPortsList(): Array;
+ setPortsList(value: Array): 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,
- networkList: Array,
+ portsList: Array,
}
}
-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;
+ setBoardsList(value: Array): 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};
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo};
- 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,
}
}
-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;
+ setSearchArgsList(value: Array): 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};
+ static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo};
+ 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,
+ }
+}
+
+export class BoardListAllResp extends jspb.Message {
+ clearBoardsList(): void;
+ getBoardsList(): Array;
+ setBoardsList(value: Array): 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};
+ static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo};
+ 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,
+ }
+}
+
+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};
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo};
- 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,
}
}
diff --git a/arduino-ide-extension/src/node/cli-protocol/commands/board_pb.js b/arduino-ide-extension/src/node/cli-protocol/commands/board_pb.js
new file mode 100644
index 00000000..c88f9431
--- /dev/null
+++ b/arduino-ide-extension/src/node/cli-protocol/commands/board_pb.js
@@ -0,0 +1,2591 @@
+/**
+ * @fileoverview
+ * @enhanceable
+ * @suppress {messageConventions} JS Compiler reports an error if a variable or
+ * field starts with 'MSG_' and isn't a translatable message.
+ * @public
+ */
+// GENERATED CODE -- DO NOT EDIT!
+
+var jspb = require('google-protobuf');
+var goog = jspb;
+var global = Function('return this')();
+
+var commands_common_pb = require('../commands/common_pb.js');
+goog.object.extend(proto, commands_common_pb);
+goog.exportSymbol('proto.cc.arduino.cli.commands.BoardAttachReq', null, global);
+goog.exportSymbol('proto.cc.arduino.cli.commands.BoardAttachResp', null, global);
+goog.exportSymbol('proto.cc.arduino.cli.commands.BoardDetailsReq', null, global);
+goog.exportSymbol('proto.cc.arduino.cli.commands.BoardDetailsResp', null, global);
+goog.exportSymbol('proto.cc.arduino.cli.commands.BoardListAllReq', null, global);
+goog.exportSymbol('proto.cc.arduino.cli.commands.BoardListAllResp', null, global);
+goog.exportSymbol('proto.cc.arduino.cli.commands.BoardListItem', null, global);
+goog.exportSymbol('proto.cc.arduino.cli.commands.BoardListReq', null, global);
+goog.exportSymbol('proto.cc.arduino.cli.commands.BoardListResp', null, global);
+goog.exportSymbol('proto.cc.arduino.cli.commands.ConfigOption', null, global);
+goog.exportSymbol('proto.cc.arduino.cli.commands.ConfigValue', null, global);
+goog.exportSymbol('proto.cc.arduino.cli.commands.DetectedPort', null, global);
+goog.exportSymbol('proto.cc.arduino.cli.commands.RequiredTool', null, global);
+
+/**
+ * Generated by JsPbCodeGenerator.
+ * @param {Array=} opt_data Optional initial data array, typically from a
+ * server response, or constructed directly in Javascript. The array is used
+ * in place and becomes part of the constructed object. It is not cloned.
+ * If no data is provided, the constructed object will be empty, but still
+ * valid.
+ * @extends {jspb.Message}
+ * @constructor
+ */
+proto.cc.arduino.cli.commands.BoardDetailsReq = function(opt_data) {
+ jspb.Message.initialize(this, opt_data, 0, -1, null, null);
+};
+goog.inherits(proto.cc.arduino.cli.commands.BoardDetailsReq, jspb.Message);
+if (goog.DEBUG && !COMPILED) {
+ proto.cc.arduino.cli.commands.BoardDetailsReq.displayName = 'proto.cc.arduino.cli.commands.BoardDetailsReq';
+}
+
+
+if (jspb.Message.GENERATE_TO_OBJECT) {
+/**
+ * Creates an object representation of this proto suitable for use in Soy templates.
+ * Field names that are reserved in JavaScript and will be renamed to pb_name.
+ * To access a reserved field use, foo.pb_, eg, foo.pb_default.
+ * For the list of reserved names please see:
+ * com.google.apps.jspb.JsClassTemplate.JS_RESERVED_WORDS.
+ * @param {boolean=} opt_includeInstance Whether to include the JSPB instance
+ * for transitional soy proto support: http://goto/soy-param-migration
+ * @return {!Object}
+ */
+proto.cc.arduino.cli.commands.BoardDetailsReq.prototype.toObject = function(opt_includeInstance) {
+ return proto.cc.arduino.cli.commands.BoardDetailsReq.toObject(opt_includeInstance, this);
+};
+
+
+/**
+ * Static version of the {@see toObject} method.
+ * @param {boolean|undefined} includeInstance Whether to include the JSPB
+ * instance for transitional soy proto support:
+ * http://goto/soy-param-migration
+ * @param {!proto.cc.arduino.cli.commands.BoardDetailsReq} msg The msg instance to transform.
+ * @return {!Object}
+ * @suppress {unusedLocalVariables} f is only used for nested messages
+ */
+proto.cc.arduino.cli.commands.BoardDetailsReq.toObject = function(includeInstance, msg) {
+ var f, obj = {
+ instance: (f = msg.getInstance()) && commands_common_pb.Instance.toObject(includeInstance, f),
+ fqbn: jspb.Message.getFieldWithDefault(msg, 2, "")
+ };
+
+ if (includeInstance) {
+ obj.$jspbMessageInstance = msg;
+ }
+ return obj;
+};
+}
+
+
+/**
+ * Deserializes binary data (in protobuf wire format).
+ * @param {jspb.ByteSource} bytes The bytes to deserialize.
+ * @return {!proto.cc.arduino.cli.commands.BoardDetailsReq}
+ */
+proto.cc.arduino.cli.commands.BoardDetailsReq.deserializeBinary = function(bytes) {
+ var reader = new jspb.BinaryReader(bytes);
+ var msg = new proto.cc.arduino.cli.commands.BoardDetailsReq;
+ return proto.cc.arduino.cli.commands.BoardDetailsReq.deserializeBinaryFromReader(msg, reader);
+};
+
+
+/**
+ * Deserializes binary data (in protobuf wire format) from the
+ * given reader into the given message object.
+ * @param {!proto.cc.arduino.cli.commands.BoardDetailsReq} msg The message object to deserialize into.
+ * @param {!jspb.BinaryReader} reader The BinaryReader to use.
+ * @return {!proto.cc.arduino.cli.commands.BoardDetailsReq}
+ */
+proto.cc.arduino.cli.commands.BoardDetailsReq.deserializeBinaryFromReader = function(msg, reader) {
+ while (reader.nextField()) {
+ if (reader.isEndGroup()) {
+ break;
+ }
+ var field = reader.getFieldNumber();
+ switch (field) {
+ case 1:
+ var value = new commands_common_pb.Instance;
+ reader.readMessage(value,commands_common_pb.Instance.deserializeBinaryFromReader);
+ msg.setInstance(value);
+ break;
+ case 2:
+ var value = /** @type {string} */ (reader.readString());
+ msg.setFqbn(value);
+ break;
+ default:
+ reader.skipField();
+ break;
+ }
+ }
+ return msg;
+};
+
+
+/**
+ * Serializes the message to binary data (in protobuf wire format).
+ * @return {!Uint8Array}
+ */
+proto.cc.arduino.cli.commands.BoardDetailsReq.prototype.serializeBinary = function() {
+ var writer = new jspb.BinaryWriter();
+ proto.cc.arduino.cli.commands.BoardDetailsReq.serializeBinaryToWriter(this, writer);
+ return writer.getResultBuffer();
+};
+
+
+/**
+ * Serializes the given message to binary data (in protobuf wire
+ * format), writing to the given BinaryWriter.
+ * @param {!proto.cc.arduino.cli.commands.BoardDetailsReq} message
+ * @param {!jspb.BinaryWriter} writer
+ * @suppress {unusedLocalVariables} f is only used for nested messages
+ */
+proto.cc.arduino.cli.commands.BoardDetailsReq.serializeBinaryToWriter = function(message, writer) {
+ var f = undefined;
+ f = message.getInstance();
+ if (f != null) {
+ writer.writeMessage(
+ 1,
+ f,
+ commands_common_pb.Instance.serializeBinaryToWriter
+ );
+ }
+ f = message.getFqbn();
+ if (f.length > 0) {
+ writer.writeString(
+ 2,
+ f
+ );
+ }
+};
+
+
+/**
+ * optional Instance instance = 1;
+ * @return {?proto.cc.arduino.cli.commands.Instance}
+ */
+proto.cc.arduino.cli.commands.BoardDetailsReq.prototype.getInstance = function() {
+ return /** @type{?proto.cc.arduino.cli.commands.Instance} */ (
+ jspb.Message.getWrapperField(this, commands_common_pb.Instance, 1));
+};
+
+
+/** @param {?proto.cc.arduino.cli.commands.Instance|undefined} value */
+proto.cc.arduino.cli.commands.BoardDetailsReq.prototype.setInstance = function(value) {
+ jspb.Message.setWrapperField(this, 1, value);
+};
+
+
+proto.cc.arduino.cli.commands.BoardDetailsReq.prototype.clearInstance = function() {
+ this.setInstance(undefined);
+};
+
+
+/**
+ * Returns whether this field is set.
+ * @return {boolean}
+ */
+proto.cc.arduino.cli.commands.BoardDetailsReq.prototype.hasInstance = function() {
+ return jspb.Message.getField(this, 1) != null;
+};
+
+
+/**
+ * optional string fqbn = 2;
+ * @return {string}
+ */
+proto.cc.arduino.cli.commands.BoardDetailsReq.prototype.getFqbn = function() {
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
+};
+
+
+/** @param {string} value */
+proto.cc.arduino.cli.commands.BoardDetailsReq.prototype.setFqbn = function(value) {
+ jspb.Message.setProto3StringField(this, 2, value);
+};
+
+
+
+/**
+ * Generated by JsPbCodeGenerator.
+ * @param {Array=} opt_data Optional initial data array, typically from a
+ * server response, or constructed directly in Javascript. The array is used
+ * in place and becomes part of the constructed object. It is not cloned.
+ * If no data is provided, the constructed object will be empty, but still
+ * valid.
+ * @extends {jspb.Message}
+ * @constructor
+ */
+proto.cc.arduino.cli.commands.BoardDetailsResp = function(opt_data) {
+ jspb.Message.initialize(this, opt_data, 0, -1, proto.cc.arduino.cli.commands.BoardDetailsResp.repeatedFields_, null);
+};
+goog.inherits(proto.cc.arduino.cli.commands.BoardDetailsResp, jspb.Message);
+if (goog.DEBUG && !COMPILED) {
+ proto.cc.arduino.cli.commands.BoardDetailsResp.displayName = 'proto.cc.arduino.cli.commands.BoardDetailsResp';
+}
+/**
+ * List of repeated fields within this message type.
+ * @private {!Array}
+ * @const
+ */
+proto.cc.arduino.cli.commands.BoardDetailsResp.repeatedFields_ = [3,4];
+
+
+
+if (jspb.Message.GENERATE_TO_OBJECT) {
+/**
+ * Creates an object representation of this proto suitable for use in Soy templates.
+ * Field names that are reserved in JavaScript and will be renamed to pb_name.
+ * To access a reserved field use, foo.pb_, eg, foo.pb_default.
+ * For the list of reserved names please see:
+ * com.google.apps.jspb.JsClassTemplate.JS_RESERVED_WORDS.
+ * @param {boolean=} opt_includeInstance Whether to include the JSPB instance
+ * for transitional soy proto support: http://goto/soy-param-migration
+ * @return {!Object}
+ */
+proto.cc.arduino.cli.commands.BoardDetailsResp.prototype.toObject = function(opt_includeInstance) {
+ return proto.cc.arduino.cli.commands.BoardDetailsResp.toObject(opt_includeInstance, this);
+};
+
+
+/**
+ * Static version of the {@see toObject} method.
+ * @param {boolean|undefined} includeInstance Whether to include the JSPB
+ * instance for transitional soy proto support:
+ * http://goto/soy-param-migration
+ * @param {!proto.cc.arduino.cli.commands.BoardDetailsResp} msg The msg instance to transform.
+ * @return {!Object}
+ * @suppress {unusedLocalVariables} f is only used for nested messages
+ */
+proto.cc.arduino.cli.commands.BoardDetailsResp.toObject = function(includeInstance, msg) {
+ var f, obj = {
+ name: jspb.Message.getFieldWithDefault(msg, 2, ""),
+ configOptionsList: jspb.Message.toObjectList(msg.getConfigOptionsList(),
+ proto.cc.arduino.cli.commands.ConfigOption.toObject, includeInstance),
+ requiredToolsList: jspb.Message.toObjectList(msg.getRequiredToolsList(),
+ proto.cc.arduino.cli.commands.RequiredTool.toObject, includeInstance)
+ };
+
+ if (includeInstance) {
+ obj.$jspbMessageInstance = msg;
+ }
+ return obj;
+};
+}
+
+
+/**
+ * Deserializes binary data (in protobuf wire format).
+ * @param {jspb.ByteSource} bytes The bytes to deserialize.
+ * @return {!proto.cc.arduino.cli.commands.BoardDetailsResp}
+ */
+proto.cc.arduino.cli.commands.BoardDetailsResp.deserializeBinary = function(bytes) {
+ var reader = new jspb.BinaryReader(bytes);
+ var msg = new proto.cc.arduino.cli.commands.BoardDetailsResp;
+ return proto.cc.arduino.cli.commands.BoardDetailsResp.deserializeBinaryFromReader(msg, reader);
+};
+
+
+/**
+ * Deserializes binary data (in protobuf wire format) from the
+ * given reader into the given message object.
+ * @param {!proto.cc.arduino.cli.commands.BoardDetailsResp} msg The message object to deserialize into.
+ * @param {!jspb.BinaryReader} reader The BinaryReader to use.
+ * @return {!proto.cc.arduino.cli.commands.BoardDetailsResp}
+ */
+proto.cc.arduino.cli.commands.BoardDetailsResp.deserializeBinaryFromReader = function(msg, reader) {
+ while (reader.nextField()) {
+ if (reader.isEndGroup()) {
+ break;
+ }
+ var field = reader.getFieldNumber();
+ switch (field) {
+ case 2:
+ var value = /** @type {string} */ (reader.readString());
+ msg.setName(value);
+ break;
+ case 3:
+ var value = new proto.cc.arduino.cli.commands.ConfigOption;
+ reader.readMessage(value,proto.cc.arduino.cli.commands.ConfigOption.deserializeBinaryFromReader);
+ msg.addConfigOptions(value);
+ break;
+ case 4:
+ var value = new proto.cc.arduino.cli.commands.RequiredTool;
+ reader.readMessage(value,proto.cc.arduino.cli.commands.RequiredTool.deserializeBinaryFromReader);
+ msg.addRequiredTools(value);
+ break;
+ default:
+ reader.skipField();
+ break;
+ }
+ }
+ return msg;
+};
+
+
+/**
+ * Serializes the message to binary data (in protobuf wire format).
+ * @return {!Uint8Array}
+ */
+proto.cc.arduino.cli.commands.BoardDetailsResp.prototype.serializeBinary = function() {
+ var writer = new jspb.BinaryWriter();
+ proto.cc.arduino.cli.commands.BoardDetailsResp.serializeBinaryToWriter(this, writer);
+ return writer.getResultBuffer();
+};
+
+
+/**
+ * Serializes the given message to binary data (in protobuf wire
+ * format), writing to the given BinaryWriter.
+ * @param {!proto.cc.arduino.cli.commands.BoardDetailsResp} message
+ * @param {!jspb.BinaryWriter} writer
+ * @suppress {unusedLocalVariables} f is only used for nested messages
+ */
+proto.cc.arduino.cli.commands.BoardDetailsResp.serializeBinaryToWriter = function(message, writer) {
+ var f = undefined;
+ f = message.getName();
+ if (f.length > 0) {
+ writer.writeString(
+ 2,
+ f
+ );
+ }
+ f = message.getConfigOptionsList();
+ if (f.length > 0) {
+ writer.writeRepeatedMessage(
+ 3,
+ f,
+ proto.cc.arduino.cli.commands.ConfigOption.serializeBinaryToWriter
+ );
+ }
+ f = message.getRequiredToolsList();
+ if (f.length > 0) {
+ writer.writeRepeatedMessage(
+ 4,
+ f,
+ proto.cc.arduino.cli.commands.RequiredTool.serializeBinaryToWriter
+ );
+ }
+};
+
+
+/**
+ * optional string name = 2;
+ * @return {string}
+ */
+proto.cc.arduino.cli.commands.BoardDetailsResp.prototype.getName = function() {
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
+};
+
+
+/** @param {string} value */
+proto.cc.arduino.cli.commands.BoardDetailsResp.prototype.setName = function(value) {
+ jspb.Message.setProto3StringField(this, 2, value);
+};
+
+
+/**
+ * repeated ConfigOption config_options = 3;
+ * @return {!Array}
+ */
+proto.cc.arduino.cli.commands.BoardDetailsResp.prototype.getConfigOptionsList = function() {
+ return /** @type{!Array} */ (
+ jspb.Message.getRepeatedWrapperField(this, proto.cc.arduino.cli.commands.ConfigOption, 3));
+};
+
+
+/** @param {!Array} value */
+proto.cc.arduino.cli.commands.BoardDetailsResp.prototype.setConfigOptionsList = function(value) {
+ jspb.Message.setRepeatedWrapperField(this, 3, value);
+};
+
+
+/**
+ * @param {!proto.cc.arduino.cli.commands.ConfigOption=} opt_value
+ * @param {number=} opt_index
+ * @return {!proto.cc.arduino.cli.commands.ConfigOption}
+ */
+proto.cc.arduino.cli.commands.BoardDetailsResp.prototype.addConfigOptions = function(opt_value, opt_index) {
+ return jspb.Message.addToRepeatedWrapperField(this, 3, opt_value, proto.cc.arduino.cli.commands.ConfigOption, opt_index);
+};
+
+
+proto.cc.arduino.cli.commands.BoardDetailsResp.prototype.clearConfigOptionsList = function() {
+ this.setConfigOptionsList([]);
+};
+
+
+/**
+ * repeated RequiredTool required_tools = 4;
+ * @return {!Array}
+ */
+proto.cc.arduino.cli.commands.BoardDetailsResp.prototype.getRequiredToolsList = function() {
+ return /** @type{!Array} */ (
+ jspb.Message.getRepeatedWrapperField(this, proto.cc.arduino.cli.commands.RequiredTool, 4));
+};
+
+
+/** @param {!Array} value */
+proto.cc.arduino.cli.commands.BoardDetailsResp.prototype.setRequiredToolsList = function(value) {
+ jspb.Message.setRepeatedWrapperField(this, 4, value);
+};
+
+
+/**
+ * @param {!proto.cc.arduino.cli.commands.RequiredTool=} opt_value
+ * @param {number=} opt_index
+ * @return {!proto.cc.arduino.cli.commands.RequiredTool}
+ */
+proto.cc.arduino.cli.commands.BoardDetailsResp.prototype.addRequiredTools = function(opt_value, opt_index) {
+ return jspb.Message.addToRepeatedWrapperField(this, 4, opt_value, proto.cc.arduino.cli.commands.RequiredTool, opt_index);
+};
+
+
+proto.cc.arduino.cli.commands.BoardDetailsResp.prototype.clearRequiredToolsList = function() {
+ this.setRequiredToolsList([]);
+};
+
+
+
+/**
+ * Generated by JsPbCodeGenerator.
+ * @param {Array=} opt_data Optional initial data array, typically from a
+ * server response, or constructed directly in Javascript. The array is used
+ * in place and becomes part of the constructed object. It is not cloned.
+ * If no data is provided, the constructed object will be empty, but still
+ * valid.
+ * @extends {jspb.Message}
+ * @constructor
+ */
+proto.cc.arduino.cli.commands.ConfigOption = function(opt_data) {
+ jspb.Message.initialize(this, opt_data, 0, -1, proto.cc.arduino.cli.commands.ConfigOption.repeatedFields_, null);
+};
+goog.inherits(proto.cc.arduino.cli.commands.ConfigOption, jspb.Message);
+if (goog.DEBUG && !COMPILED) {
+ proto.cc.arduino.cli.commands.ConfigOption.displayName = 'proto.cc.arduino.cli.commands.ConfigOption';
+}
+/**
+ * List of repeated fields within this message type.
+ * @private {!Array}
+ * @const
+ */
+proto.cc.arduino.cli.commands.ConfigOption.repeatedFields_ = [3];
+
+
+
+if (jspb.Message.GENERATE_TO_OBJECT) {
+/**
+ * Creates an object representation of this proto suitable for use in Soy templates.
+ * Field names that are reserved in JavaScript and will be renamed to pb_name.
+ * To access a reserved field use, foo.pb_, eg, foo.pb_default.
+ * For the list of reserved names please see:
+ * com.google.apps.jspb.JsClassTemplate.JS_RESERVED_WORDS.
+ * @param {boolean=} opt_includeInstance Whether to include the JSPB instance
+ * for transitional soy proto support: http://goto/soy-param-migration
+ * @return {!Object}
+ */
+proto.cc.arduino.cli.commands.ConfigOption.prototype.toObject = function(opt_includeInstance) {
+ return proto.cc.arduino.cli.commands.ConfigOption.toObject(opt_includeInstance, this);
+};
+
+
+/**
+ * Static version of the {@see toObject} method.
+ * @param {boolean|undefined} includeInstance Whether to include the JSPB
+ * instance for transitional soy proto support:
+ * http://goto/soy-param-migration
+ * @param {!proto.cc.arduino.cli.commands.ConfigOption} msg The msg instance to transform.
+ * @return {!Object}
+ * @suppress {unusedLocalVariables} f is only used for nested messages
+ */
+proto.cc.arduino.cli.commands.ConfigOption.toObject = function(includeInstance, msg) {
+ var f, obj = {
+ option: jspb.Message.getFieldWithDefault(msg, 1, ""),
+ optionLabel: jspb.Message.getFieldWithDefault(msg, 2, ""),
+ valuesList: jspb.Message.toObjectList(msg.getValuesList(),
+ proto.cc.arduino.cli.commands.ConfigValue.toObject, includeInstance)
+ };
+
+ if (includeInstance) {
+ obj.$jspbMessageInstance = msg;
+ }
+ return obj;
+};
+}
+
+
+/**
+ * Deserializes binary data (in protobuf wire format).
+ * @param {jspb.ByteSource} bytes The bytes to deserialize.
+ * @return {!proto.cc.arduino.cli.commands.ConfigOption}
+ */
+proto.cc.arduino.cli.commands.ConfigOption.deserializeBinary = function(bytes) {
+ var reader = new jspb.BinaryReader(bytes);
+ var msg = new proto.cc.arduino.cli.commands.ConfigOption;
+ return proto.cc.arduino.cli.commands.ConfigOption.deserializeBinaryFromReader(msg, reader);
+};
+
+
+/**
+ * Deserializes binary data (in protobuf wire format) from the
+ * given reader into the given message object.
+ * @param {!proto.cc.arduino.cli.commands.ConfigOption} msg The message object to deserialize into.
+ * @param {!jspb.BinaryReader} reader The BinaryReader to use.
+ * @return {!proto.cc.arduino.cli.commands.ConfigOption}
+ */
+proto.cc.arduino.cli.commands.ConfigOption.deserializeBinaryFromReader = function(msg, reader) {
+ while (reader.nextField()) {
+ if (reader.isEndGroup()) {
+ break;
+ }
+ var field = reader.getFieldNumber();
+ switch (field) {
+ case 1:
+ var value = /** @type {string} */ (reader.readString());
+ msg.setOption(value);
+ break;
+ case 2:
+ var value = /** @type {string} */ (reader.readString());
+ msg.setOptionLabel(value);
+ break;
+ case 3:
+ var value = new proto.cc.arduino.cli.commands.ConfigValue;
+ reader.readMessage(value,proto.cc.arduino.cli.commands.ConfigValue.deserializeBinaryFromReader);
+ msg.addValues(value);
+ break;
+ default:
+ reader.skipField();
+ break;
+ }
+ }
+ return msg;
+};
+
+
+/**
+ * Serializes the message to binary data (in protobuf wire format).
+ * @return {!Uint8Array}
+ */
+proto.cc.arduino.cli.commands.ConfigOption.prototype.serializeBinary = function() {
+ var writer = new jspb.BinaryWriter();
+ proto.cc.arduino.cli.commands.ConfigOption.serializeBinaryToWriter(this, writer);
+ return writer.getResultBuffer();
+};
+
+
+/**
+ * Serializes the given message to binary data (in protobuf wire
+ * format), writing to the given BinaryWriter.
+ * @param {!proto.cc.arduino.cli.commands.ConfigOption} message
+ * @param {!jspb.BinaryWriter} writer
+ * @suppress {unusedLocalVariables} f is only used for nested messages
+ */
+proto.cc.arduino.cli.commands.ConfigOption.serializeBinaryToWriter = function(message, writer) {
+ var f = undefined;
+ f = message.getOption();
+ if (f.length > 0) {
+ writer.writeString(
+ 1,
+ f
+ );
+ }
+ f = message.getOptionLabel();
+ if (f.length > 0) {
+ writer.writeString(
+ 2,
+ f
+ );
+ }
+ f = message.getValuesList();
+ if (f.length > 0) {
+ writer.writeRepeatedMessage(
+ 3,
+ f,
+ proto.cc.arduino.cli.commands.ConfigValue.serializeBinaryToWriter
+ );
+ }
+};
+
+
+/**
+ * optional string option = 1;
+ * @return {string}
+ */
+proto.cc.arduino.cli.commands.ConfigOption.prototype.getOption = function() {
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
+};
+
+
+/** @param {string} value */
+proto.cc.arduino.cli.commands.ConfigOption.prototype.setOption = function(value) {
+ jspb.Message.setProto3StringField(this, 1, value);
+};
+
+
+/**
+ * optional string option_label = 2;
+ * @return {string}
+ */
+proto.cc.arduino.cli.commands.ConfigOption.prototype.getOptionLabel = function() {
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
+};
+
+
+/** @param {string} value */
+proto.cc.arduino.cli.commands.ConfigOption.prototype.setOptionLabel = function(value) {
+ jspb.Message.setProto3StringField(this, 2, value);
+};
+
+
+/**
+ * repeated ConfigValue values = 3;
+ * @return {!Array}
+ */
+proto.cc.arduino.cli.commands.ConfigOption.prototype.getValuesList = function() {
+ return /** @type{!Array} */ (
+ jspb.Message.getRepeatedWrapperField(this, proto.cc.arduino.cli.commands.ConfigValue, 3));
+};
+
+
+/** @param {!Array} value */
+proto.cc.arduino.cli.commands.ConfigOption.prototype.setValuesList = function(value) {
+ jspb.Message.setRepeatedWrapperField(this, 3, value);
+};
+
+
+/**
+ * @param {!proto.cc.arduino.cli.commands.ConfigValue=} opt_value
+ * @param {number=} opt_index
+ * @return {!proto.cc.arduino.cli.commands.ConfigValue}
+ */
+proto.cc.arduino.cli.commands.ConfigOption.prototype.addValues = function(opt_value, opt_index) {
+ return jspb.Message.addToRepeatedWrapperField(this, 3, opt_value, proto.cc.arduino.cli.commands.ConfigValue, opt_index);
+};
+
+
+proto.cc.arduino.cli.commands.ConfigOption.prototype.clearValuesList = function() {
+ this.setValuesList([]);
+};
+
+
+
+/**
+ * Generated by JsPbCodeGenerator.
+ * @param {Array=} opt_data Optional initial data array, typically from a
+ * server response, or constructed directly in Javascript. The array is used
+ * in place and becomes part of the constructed object. It is not cloned.
+ * If no data is provided, the constructed object will be empty, but still
+ * valid.
+ * @extends {jspb.Message}
+ * @constructor
+ */
+proto.cc.arduino.cli.commands.ConfigValue = function(opt_data) {
+ jspb.Message.initialize(this, opt_data, 0, -1, null, null);
+};
+goog.inherits(proto.cc.arduino.cli.commands.ConfigValue, jspb.Message);
+if (goog.DEBUG && !COMPILED) {
+ proto.cc.arduino.cli.commands.ConfigValue.displayName = 'proto.cc.arduino.cli.commands.ConfigValue';
+}
+
+
+if (jspb.Message.GENERATE_TO_OBJECT) {
+/**
+ * Creates an object representation of this proto suitable for use in Soy templates.
+ * Field names that are reserved in JavaScript and will be renamed to pb_name.
+ * To access a reserved field use, foo.pb_, eg, foo.pb_default.
+ * For the list of reserved names please see:
+ * com.google.apps.jspb.JsClassTemplate.JS_RESERVED_WORDS.
+ * @param {boolean=} opt_includeInstance Whether to include the JSPB instance
+ * for transitional soy proto support: http://goto/soy-param-migration
+ * @return {!Object}
+ */
+proto.cc.arduino.cli.commands.ConfigValue.prototype.toObject = function(opt_includeInstance) {
+ return proto.cc.arduino.cli.commands.ConfigValue.toObject(opt_includeInstance, this);
+};
+
+
+/**
+ * Static version of the {@see toObject} method.
+ * @param {boolean|undefined} includeInstance Whether to include the JSPB
+ * instance for transitional soy proto support:
+ * http://goto/soy-param-migration
+ * @param {!proto.cc.arduino.cli.commands.ConfigValue} msg The msg instance to transform.
+ * @return {!Object}
+ * @suppress {unusedLocalVariables} f is only used for nested messages
+ */
+proto.cc.arduino.cli.commands.ConfigValue.toObject = function(includeInstance, msg) {
+ var f, obj = {
+ value: jspb.Message.getFieldWithDefault(msg, 1, ""),
+ valueLabel: jspb.Message.getFieldWithDefault(msg, 2, ""),
+ selected: jspb.Message.getFieldWithDefault(msg, 3, false)
+ };
+
+ if (includeInstance) {
+ obj.$jspbMessageInstance = msg;
+ }
+ return obj;
+};
+}
+
+
+/**
+ * Deserializes binary data (in protobuf wire format).
+ * @param {jspb.ByteSource} bytes The bytes to deserialize.
+ * @return {!proto.cc.arduino.cli.commands.ConfigValue}
+ */
+proto.cc.arduino.cli.commands.ConfigValue.deserializeBinary = function(bytes) {
+ var reader = new jspb.BinaryReader(bytes);
+ var msg = new proto.cc.arduino.cli.commands.ConfigValue;
+ return proto.cc.arduino.cli.commands.ConfigValue.deserializeBinaryFromReader(msg, reader);
+};
+
+
+/**
+ * Deserializes binary data (in protobuf wire format) from the
+ * given reader into the given message object.
+ * @param {!proto.cc.arduino.cli.commands.ConfigValue} msg The message object to deserialize into.
+ * @param {!jspb.BinaryReader} reader The BinaryReader to use.
+ * @return {!proto.cc.arduino.cli.commands.ConfigValue}
+ */
+proto.cc.arduino.cli.commands.ConfigValue.deserializeBinaryFromReader = function(msg, reader) {
+ while (reader.nextField()) {
+ if (reader.isEndGroup()) {
+ break;
+ }
+ var field = reader.getFieldNumber();
+ switch (field) {
+ case 1:
+ var value = /** @type {string} */ (reader.readString());
+ msg.setValue(value);
+ break;
+ case 2:
+ var value = /** @type {string} */ (reader.readString());
+ msg.setValueLabel(value);
+ break;
+ case 3:
+ var value = /** @type {boolean} */ (reader.readBool());
+ msg.setSelected(value);
+ break;
+ default:
+ reader.skipField();
+ break;
+ }
+ }
+ return msg;
+};
+
+
+/**
+ * Serializes the message to binary data (in protobuf wire format).
+ * @return {!Uint8Array}
+ */
+proto.cc.arduino.cli.commands.ConfigValue.prototype.serializeBinary = function() {
+ var writer = new jspb.BinaryWriter();
+ proto.cc.arduino.cli.commands.ConfigValue.serializeBinaryToWriter(this, writer);
+ return writer.getResultBuffer();
+};
+
+
+/**
+ * Serializes the given message to binary data (in protobuf wire
+ * format), writing to the given BinaryWriter.
+ * @param {!proto.cc.arduino.cli.commands.ConfigValue} message
+ * @param {!jspb.BinaryWriter} writer
+ * @suppress {unusedLocalVariables} f is only used for nested messages
+ */
+proto.cc.arduino.cli.commands.ConfigValue.serializeBinaryToWriter = function(message, writer) {
+ var f = undefined;
+ f = message.getValue();
+ if (f.length > 0) {
+ writer.writeString(
+ 1,
+ f
+ );
+ }
+ f = message.getValueLabel();
+ if (f.length > 0) {
+ writer.writeString(
+ 2,
+ f
+ );
+ }
+ f = message.getSelected();
+ if (f) {
+ writer.writeBool(
+ 3,
+ f
+ );
+ }
+};
+
+
+/**
+ * optional string value = 1;
+ * @return {string}
+ */
+proto.cc.arduino.cli.commands.ConfigValue.prototype.getValue = function() {
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
+};
+
+
+/** @param {string} value */
+proto.cc.arduino.cli.commands.ConfigValue.prototype.setValue = function(value) {
+ jspb.Message.setProto3StringField(this, 1, value);
+};
+
+
+/**
+ * optional string value_label = 2;
+ * @return {string}
+ */
+proto.cc.arduino.cli.commands.ConfigValue.prototype.getValueLabel = function() {
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
+};
+
+
+/** @param {string} value */
+proto.cc.arduino.cli.commands.ConfigValue.prototype.setValueLabel = function(value) {
+ jspb.Message.setProto3StringField(this, 2, value);
+};
+
+
+/**
+ * optional bool selected = 3;
+ * Note that Boolean fields may be set to 0/1 when serialized from a Java server.
+ * You should avoid comparisons like {@code val === true/false} in those cases.
+ * @return {boolean}
+ */
+proto.cc.arduino.cli.commands.ConfigValue.prototype.getSelected = function() {
+ return /** @type {boolean} */ (jspb.Message.getFieldWithDefault(this, 3, false));
+};
+
+
+/** @param {boolean} value */
+proto.cc.arduino.cli.commands.ConfigValue.prototype.setSelected = function(value) {
+ jspb.Message.setProto3BooleanField(this, 3, value);
+};
+
+
+
+/**
+ * Generated by JsPbCodeGenerator.
+ * @param {Array=} opt_data Optional initial data array, typically from a
+ * server response, or constructed directly in Javascript. The array is used
+ * in place and becomes part of the constructed object. It is not cloned.
+ * If no data is provided, the constructed object will be empty, but still
+ * valid.
+ * @extends {jspb.Message}
+ * @constructor
+ */
+proto.cc.arduino.cli.commands.RequiredTool = function(opt_data) {
+ jspb.Message.initialize(this, opt_data, 0, -1, null, null);
+};
+goog.inherits(proto.cc.arduino.cli.commands.RequiredTool, jspb.Message);
+if (goog.DEBUG && !COMPILED) {
+ proto.cc.arduino.cli.commands.RequiredTool.displayName = 'proto.cc.arduino.cli.commands.RequiredTool';
+}
+
+
+if (jspb.Message.GENERATE_TO_OBJECT) {
+/**
+ * Creates an object representation of this proto suitable for use in Soy templates.
+ * Field names that are reserved in JavaScript and will be renamed to pb_name.
+ * To access a reserved field use, foo.pb_, eg, foo.pb_default.
+ * For the list of reserved names please see:
+ * com.google.apps.jspb.JsClassTemplate.JS_RESERVED_WORDS.
+ * @param {boolean=} opt_includeInstance Whether to include the JSPB instance
+ * for transitional soy proto support: http://goto/soy-param-migration
+ * @return {!Object}
+ */
+proto.cc.arduino.cli.commands.RequiredTool.prototype.toObject = function(opt_includeInstance) {
+ return proto.cc.arduino.cli.commands.RequiredTool.toObject(opt_includeInstance, this);
+};
+
+
+/**
+ * Static version of the {@see toObject} method.
+ * @param {boolean|undefined} includeInstance Whether to include the JSPB
+ * instance for transitional soy proto support:
+ * http://goto/soy-param-migration
+ * @param {!proto.cc.arduino.cli.commands.RequiredTool} msg The msg instance to transform.
+ * @return {!Object}
+ * @suppress {unusedLocalVariables} f is only used for nested messages
+ */
+proto.cc.arduino.cli.commands.RequiredTool.toObject = function(includeInstance, msg) {
+ var f, obj = {
+ name: jspb.Message.getFieldWithDefault(msg, 1, ""),
+ version: jspb.Message.getFieldWithDefault(msg, 2, ""),
+ packager: jspb.Message.getFieldWithDefault(msg, 3, "")
+ };
+
+ if (includeInstance) {
+ obj.$jspbMessageInstance = msg;
+ }
+ return obj;
+};
+}
+
+
+/**
+ * Deserializes binary data (in protobuf wire format).
+ * @param {jspb.ByteSource} bytes The bytes to deserialize.
+ * @return {!proto.cc.arduino.cli.commands.RequiredTool}
+ */
+proto.cc.arduino.cli.commands.RequiredTool.deserializeBinary = function(bytes) {
+ var reader = new jspb.BinaryReader(bytes);
+ var msg = new proto.cc.arduino.cli.commands.RequiredTool;
+ return proto.cc.arduino.cli.commands.RequiredTool.deserializeBinaryFromReader(msg, reader);
+};
+
+
+/**
+ * Deserializes binary data (in protobuf wire format) from the
+ * given reader into the given message object.
+ * @param {!proto.cc.arduino.cli.commands.RequiredTool} msg The message object to deserialize into.
+ * @param {!jspb.BinaryReader} reader The BinaryReader to use.
+ * @return {!proto.cc.arduino.cli.commands.RequiredTool}
+ */
+proto.cc.arduino.cli.commands.RequiredTool.deserializeBinaryFromReader = function(msg, reader) {
+ while (reader.nextField()) {
+ if (reader.isEndGroup()) {
+ break;
+ }
+ var field = reader.getFieldNumber();
+ switch (field) {
+ case 1:
+ var value = /** @type {string} */ (reader.readString());
+ msg.setName(value);
+ break;
+ case 2:
+ var value = /** @type {string} */ (reader.readString());
+ msg.setVersion(value);
+ break;
+ case 3:
+ var value = /** @type {string} */ (reader.readString());
+ msg.setPackager(value);
+ break;
+ default:
+ reader.skipField();
+ break;
+ }
+ }
+ return msg;
+};
+
+
+/**
+ * Serializes the message to binary data (in protobuf wire format).
+ * @return {!Uint8Array}
+ */
+proto.cc.arduino.cli.commands.RequiredTool.prototype.serializeBinary = function() {
+ var writer = new jspb.BinaryWriter();
+ proto.cc.arduino.cli.commands.RequiredTool.serializeBinaryToWriter(this, writer);
+ return writer.getResultBuffer();
+};
+
+
+/**
+ * Serializes the given message to binary data (in protobuf wire
+ * format), writing to the given BinaryWriter.
+ * @param {!proto.cc.arduino.cli.commands.RequiredTool} message
+ * @param {!jspb.BinaryWriter} writer
+ * @suppress {unusedLocalVariables} f is only used for nested messages
+ */
+proto.cc.arduino.cli.commands.RequiredTool.serializeBinaryToWriter = function(message, writer) {
+ var f = undefined;
+ f = message.getName();
+ if (f.length > 0) {
+ writer.writeString(
+ 1,
+ f
+ );
+ }
+ f = message.getVersion();
+ if (f.length > 0) {
+ writer.writeString(
+ 2,
+ f
+ );
+ }
+ f = message.getPackager();
+ if (f.length > 0) {
+ writer.writeString(
+ 3,
+ f
+ );
+ }
+};
+
+
+/**
+ * optional string name = 1;
+ * @return {string}
+ */
+proto.cc.arduino.cli.commands.RequiredTool.prototype.getName = function() {
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
+};
+
+
+/** @param {string} value */
+proto.cc.arduino.cli.commands.RequiredTool.prototype.setName = function(value) {
+ jspb.Message.setProto3StringField(this, 1, value);
+};
+
+
+/**
+ * optional string version = 2;
+ * @return {string}
+ */
+proto.cc.arduino.cli.commands.RequiredTool.prototype.getVersion = function() {
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
+};
+
+
+/** @param {string} value */
+proto.cc.arduino.cli.commands.RequiredTool.prototype.setVersion = function(value) {
+ jspb.Message.setProto3StringField(this, 2, value);
+};
+
+
+/**
+ * optional string packager = 3;
+ * @return {string}
+ */
+proto.cc.arduino.cli.commands.RequiredTool.prototype.getPackager = function() {
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 3, ""));
+};
+
+
+/** @param {string} value */
+proto.cc.arduino.cli.commands.RequiredTool.prototype.setPackager = function(value) {
+ jspb.Message.setProto3StringField(this, 3, value);
+};
+
+
+
+/**
+ * Generated by JsPbCodeGenerator.
+ * @param {Array=} opt_data Optional initial data array, typically from a
+ * server response, or constructed directly in Javascript. The array is used
+ * in place and becomes part of the constructed object. It is not cloned.
+ * If no data is provided, the constructed object will be empty, but still
+ * valid.
+ * @extends {jspb.Message}
+ * @constructor
+ */
+proto.cc.arduino.cli.commands.BoardAttachReq = function(opt_data) {
+ jspb.Message.initialize(this, opt_data, 0, -1, null, null);
+};
+goog.inherits(proto.cc.arduino.cli.commands.BoardAttachReq, jspb.Message);
+if (goog.DEBUG && !COMPILED) {
+ proto.cc.arduino.cli.commands.BoardAttachReq.displayName = 'proto.cc.arduino.cli.commands.BoardAttachReq';
+}
+
+
+if (jspb.Message.GENERATE_TO_OBJECT) {
+/**
+ * Creates an object representation of this proto suitable for use in Soy templates.
+ * Field names that are reserved in JavaScript and will be renamed to pb_name.
+ * To access a reserved field use, foo.pb_, eg, foo.pb_default.
+ * For the list of reserved names please see:
+ * com.google.apps.jspb.JsClassTemplate.JS_RESERVED_WORDS.
+ * @param {boolean=} opt_includeInstance Whether to include the JSPB instance
+ * for transitional soy proto support: http://goto/soy-param-migration
+ * @return {!Object}
+ */
+proto.cc.arduino.cli.commands.BoardAttachReq.prototype.toObject = function(opt_includeInstance) {
+ return proto.cc.arduino.cli.commands.BoardAttachReq.toObject(opt_includeInstance, this);
+};
+
+
+/**
+ * Static version of the {@see toObject} method.
+ * @param {boolean|undefined} includeInstance Whether to include the JSPB
+ * instance for transitional soy proto support:
+ * http://goto/soy-param-migration
+ * @param {!proto.cc.arduino.cli.commands.BoardAttachReq} msg The msg instance to transform.
+ * @return {!Object}
+ * @suppress {unusedLocalVariables} f is only used for nested messages
+ */
+proto.cc.arduino.cli.commands.BoardAttachReq.toObject = function(includeInstance, msg) {
+ var f, obj = {
+ instance: (f = msg.getInstance()) && commands_common_pb.Instance.toObject(includeInstance, f),
+ boardUri: jspb.Message.getFieldWithDefault(msg, 2, ""),
+ sketchPath: jspb.Message.getFieldWithDefault(msg, 3, ""),
+ searchTimeout: jspb.Message.getFieldWithDefault(msg, 4, "")
+ };
+
+ if (includeInstance) {
+ obj.$jspbMessageInstance = msg;
+ }
+ return obj;
+};
+}
+
+
+/**
+ * Deserializes binary data (in protobuf wire format).
+ * @param {jspb.ByteSource} bytes The bytes to deserialize.
+ * @return {!proto.cc.arduino.cli.commands.BoardAttachReq}
+ */
+proto.cc.arduino.cli.commands.BoardAttachReq.deserializeBinary = function(bytes) {
+ var reader = new jspb.BinaryReader(bytes);
+ var msg = new proto.cc.arduino.cli.commands.BoardAttachReq;
+ return proto.cc.arduino.cli.commands.BoardAttachReq.deserializeBinaryFromReader(msg, reader);
+};
+
+
+/**
+ * Deserializes binary data (in protobuf wire format) from the
+ * given reader into the given message object.
+ * @param {!proto.cc.arduino.cli.commands.BoardAttachReq} msg The message object to deserialize into.
+ * @param {!jspb.BinaryReader} reader The BinaryReader to use.
+ * @return {!proto.cc.arduino.cli.commands.BoardAttachReq}
+ */
+proto.cc.arduino.cli.commands.BoardAttachReq.deserializeBinaryFromReader = function(msg, reader) {
+ while (reader.nextField()) {
+ if (reader.isEndGroup()) {
+ break;
+ }
+ var field = reader.getFieldNumber();
+ switch (field) {
+ case 1:
+ var value = new commands_common_pb.Instance;
+ reader.readMessage(value,commands_common_pb.Instance.deserializeBinaryFromReader);
+ msg.setInstance(value);
+ break;
+ case 2:
+ var value = /** @type {string} */ (reader.readString());
+ msg.setBoardUri(value);
+ break;
+ case 3:
+ var value = /** @type {string} */ (reader.readString());
+ msg.setSketchPath(value);
+ break;
+ case 4:
+ var value = /** @type {string} */ (reader.readString());
+ msg.setSearchTimeout(value);
+ break;
+ default:
+ reader.skipField();
+ break;
+ }
+ }
+ return msg;
+};
+
+
+/**
+ * Serializes the message to binary data (in protobuf wire format).
+ * @return {!Uint8Array}
+ */
+proto.cc.arduino.cli.commands.BoardAttachReq.prototype.serializeBinary = function() {
+ var writer = new jspb.BinaryWriter();
+ proto.cc.arduino.cli.commands.BoardAttachReq.serializeBinaryToWriter(this, writer);
+ return writer.getResultBuffer();
+};
+
+
+/**
+ * Serializes the given message to binary data (in protobuf wire
+ * format), writing to the given BinaryWriter.
+ * @param {!proto.cc.arduino.cli.commands.BoardAttachReq} message
+ * @param {!jspb.BinaryWriter} writer
+ * @suppress {unusedLocalVariables} f is only used for nested messages
+ */
+proto.cc.arduino.cli.commands.BoardAttachReq.serializeBinaryToWriter = function(message, writer) {
+ var f = undefined;
+ f = message.getInstance();
+ if (f != null) {
+ writer.writeMessage(
+ 1,
+ f,
+ commands_common_pb.Instance.serializeBinaryToWriter
+ );
+ }
+ f = message.getBoardUri();
+ if (f.length > 0) {
+ writer.writeString(
+ 2,
+ f
+ );
+ }
+ f = message.getSketchPath();
+ if (f.length > 0) {
+ writer.writeString(
+ 3,
+ f
+ );
+ }
+ f = message.getSearchTimeout();
+ if (f.length > 0) {
+ writer.writeString(
+ 4,
+ f
+ );
+ }
+};
+
+
+/**
+ * optional Instance instance = 1;
+ * @return {?proto.cc.arduino.cli.commands.Instance}
+ */
+proto.cc.arduino.cli.commands.BoardAttachReq.prototype.getInstance = function() {
+ return /** @type{?proto.cc.arduino.cli.commands.Instance} */ (
+ jspb.Message.getWrapperField(this, commands_common_pb.Instance, 1));
+};
+
+
+/** @param {?proto.cc.arduino.cli.commands.Instance|undefined} value */
+proto.cc.arduino.cli.commands.BoardAttachReq.prototype.setInstance = function(value) {
+ jspb.Message.setWrapperField(this, 1, value);
+};
+
+
+proto.cc.arduino.cli.commands.BoardAttachReq.prototype.clearInstance = function() {
+ this.setInstance(undefined);
+};
+
+
+/**
+ * Returns whether this field is set.
+ * @return {boolean}
+ */
+proto.cc.arduino.cli.commands.BoardAttachReq.prototype.hasInstance = function() {
+ return jspb.Message.getField(this, 1) != null;
+};
+
+
+/**
+ * optional string board_uri = 2;
+ * @return {string}
+ */
+proto.cc.arduino.cli.commands.BoardAttachReq.prototype.getBoardUri = function() {
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
+};
+
+
+/** @param {string} value */
+proto.cc.arduino.cli.commands.BoardAttachReq.prototype.setBoardUri = function(value) {
+ jspb.Message.setProto3StringField(this, 2, value);
+};
+
+
+/**
+ * optional string sketch_path = 3;
+ * @return {string}
+ */
+proto.cc.arduino.cli.commands.BoardAttachReq.prototype.getSketchPath = function() {
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 3, ""));
+};
+
+
+/** @param {string} value */
+proto.cc.arduino.cli.commands.BoardAttachReq.prototype.setSketchPath = function(value) {
+ jspb.Message.setProto3StringField(this, 3, value);
+};
+
+
+/**
+ * optional string search_timeout = 4;
+ * @return {string}
+ */
+proto.cc.arduino.cli.commands.BoardAttachReq.prototype.getSearchTimeout = function() {
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 4, ""));
+};
+
+
+/** @param {string} value */
+proto.cc.arduino.cli.commands.BoardAttachReq.prototype.setSearchTimeout = function(value) {
+ jspb.Message.setProto3StringField(this, 4, value);
+};
+
+
+
+/**
+ * Generated by JsPbCodeGenerator.
+ * @param {Array=} opt_data Optional initial data array, typically from a
+ * server response, or constructed directly in Javascript. The array is used
+ * in place and becomes part of the constructed object. It is not cloned.
+ * If no data is provided, the constructed object will be empty, but still
+ * valid.
+ * @extends {jspb.Message}
+ * @constructor
+ */
+proto.cc.arduino.cli.commands.BoardAttachResp = function(opt_data) {
+ jspb.Message.initialize(this, opt_data, 0, -1, null, null);
+};
+goog.inherits(proto.cc.arduino.cli.commands.BoardAttachResp, jspb.Message);
+if (goog.DEBUG && !COMPILED) {
+ proto.cc.arduino.cli.commands.BoardAttachResp.displayName = 'proto.cc.arduino.cli.commands.BoardAttachResp';
+}
+
+
+if (jspb.Message.GENERATE_TO_OBJECT) {
+/**
+ * Creates an object representation of this proto suitable for use in Soy templates.
+ * Field names that are reserved in JavaScript and will be renamed to pb_name.
+ * To access a reserved field use, foo.pb_, eg, foo.pb_default.
+ * For the list of reserved names please see:
+ * com.google.apps.jspb.JsClassTemplate.JS_RESERVED_WORDS.
+ * @param {boolean=} opt_includeInstance Whether to include the JSPB instance
+ * for transitional soy proto support: http://goto/soy-param-migration
+ * @return {!Object}
+ */
+proto.cc.arduino.cli.commands.BoardAttachResp.prototype.toObject = function(opt_includeInstance) {
+ return proto.cc.arduino.cli.commands.BoardAttachResp.toObject(opt_includeInstance, this);
+};
+
+
+/**
+ * Static version of the {@see toObject} method.
+ * @param {boolean|undefined} includeInstance Whether to include the JSPB
+ * instance for transitional soy proto support:
+ * http://goto/soy-param-migration
+ * @param {!proto.cc.arduino.cli.commands.BoardAttachResp} msg The msg instance to transform.
+ * @return {!Object}
+ * @suppress {unusedLocalVariables} f is only used for nested messages
+ */
+proto.cc.arduino.cli.commands.BoardAttachResp.toObject = function(includeInstance, msg) {
+ var f, obj = {
+ taskProgress: (f = msg.getTaskProgress()) && commands_common_pb.TaskProgress.toObject(includeInstance, f)
+ };
+
+ if (includeInstance) {
+ obj.$jspbMessageInstance = msg;
+ }
+ return obj;
+};
+}
+
+
+/**
+ * Deserializes binary data (in protobuf wire format).
+ * @param {jspb.ByteSource} bytes The bytes to deserialize.
+ * @return {!proto.cc.arduino.cli.commands.BoardAttachResp}
+ */
+proto.cc.arduino.cli.commands.BoardAttachResp.deserializeBinary = function(bytes) {
+ var reader = new jspb.BinaryReader(bytes);
+ var msg = new proto.cc.arduino.cli.commands.BoardAttachResp;
+ return proto.cc.arduino.cli.commands.BoardAttachResp.deserializeBinaryFromReader(msg, reader);
+};
+
+
+/**
+ * Deserializes binary data (in protobuf wire format) from the
+ * given reader into the given message object.
+ * @param {!proto.cc.arduino.cli.commands.BoardAttachResp} msg The message object to deserialize into.
+ * @param {!jspb.BinaryReader} reader The BinaryReader to use.
+ * @return {!proto.cc.arduino.cli.commands.BoardAttachResp}
+ */
+proto.cc.arduino.cli.commands.BoardAttachResp.deserializeBinaryFromReader = function(msg, reader) {
+ while (reader.nextField()) {
+ if (reader.isEndGroup()) {
+ break;
+ }
+ var field = reader.getFieldNumber();
+ switch (field) {
+ case 1:
+ var value = new commands_common_pb.TaskProgress;
+ reader.readMessage(value,commands_common_pb.TaskProgress.deserializeBinaryFromReader);
+ msg.setTaskProgress(value);
+ break;
+ default:
+ reader.skipField();
+ break;
+ }
+ }
+ return msg;
+};
+
+
+/**
+ * Serializes the message to binary data (in protobuf wire format).
+ * @return {!Uint8Array}
+ */
+proto.cc.arduino.cli.commands.BoardAttachResp.prototype.serializeBinary = function() {
+ var writer = new jspb.BinaryWriter();
+ proto.cc.arduino.cli.commands.BoardAttachResp.serializeBinaryToWriter(this, writer);
+ return writer.getResultBuffer();
+};
+
+
+/**
+ * Serializes the given message to binary data (in protobuf wire
+ * format), writing to the given BinaryWriter.
+ * @param {!proto.cc.arduino.cli.commands.BoardAttachResp} message
+ * @param {!jspb.BinaryWriter} writer
+ * @suppress {unusedLocalVariables} f is only used for nested messages
+ */
+proto.cc.arduino.cli.commands.BoardAttachResp.serializeBinaryToWriter = function(message, writer) {
+ var f = undefined;
+ f = message.getTaskProgress();
+ if (f != null) {
+ writer.writeMessage(
+ 1,
+ f,
+ commands_common_pb.TaskProgress.serializeBinaryToWriter
+ );
+ }
+};
+
+
+/**
+ * optional TaskProgress task_progress = 1;
+ * @return {?proto.cc.arduino.cli.commands.TaskProgress}
+ */
+proto.cc.arduino.cli.commands.BoardAttachResp.prototype.getTaskProgress = function() {
+ return /** @type{?proto.cc.arduino.cli.commands.TaskProgress} */ (
+ jspb.Message.getWrapperField(this, commands_common_pb.TaskProgress, 1));
+};
+
+
+/** @param {?proto.cc.arduino.cli.commands.TaskProgress|undefined} value */
+proto.cc.arduino.cli.commands.BoardAttachResp.prototype.setTaskProgress = function(value) {
+ jspb.Message.setWrapperField(this, 1, value);
+};
+
+
+proto.cc.arduino.cli.commands.BoardAttachResp.prototype.clearTaskProgress = function() {
+ this.setTaskProgress(undefined);
+};
+
+
+/**
+ * Returns whether this field is set.
+ * @return {boolean}
+ */
+proto.cc.arduino.cli.commands.BoardAttachResp.prototype.hasTaskProgress = function() {
+ return jspb.Message.getField(this, 1) != null;
+};
+
+
+
+/**
+ * Generated by JsPbCodeGenerator.
+ * @param {Array=} opt_data Optional initial data array, typically from a
+ * server response, or constructed directly in Javascript. The array is used
+ * in place and becomes part of the constructed object. It is not cloned.
+ * If no data is provided, the constructed object will be empty, but still
+ * valid.
+ * @extends {jspb.Message}
+ * @constructor
+ */
+proto.cc.arduino.cli.commands.BoardListReq = function(opt_data) {
+ jspb.Message.initialize(this, opt_data, 0, -1, null, null);
+};
+goog.inherits(proto.cc.arduino.cli.commands.BoardListReq, jspb.Message);
+if (goog.DEBUG && !COMPILED) {
+ proto.cc.arduino.cli.commands.BoardListReq.displayName = 'proto.cc.arduino.cli.commands.BoardListReq';
+}
+
+
+if (jspb.Message.GENERATE_TO_OBJECT) {
+/**
+ * Creates an object representation of this proto suitable for use in Soy templates.
+ * Field names that are reserved in JavaScript and will be renamed to pb_name.
+ * To access a reserved field use, foo.pb_, eg, foo.pb_default.
+ * For the list of reserved names please see:
+ * com.google.apps.jspb.JsClassTemplate.JS_RESERVED_WORDS.
+ * @param {boolean=} opt_includeInstance Whether to include the JSPB instance
+ * for transitional soy proto support: http://goto/soy-param-migration
+ * @return {!Object}
+ */
+proto.cc.arduino.cli.commands.BoardListReq.prototype.toObject = function(opt_includeInstance) {
+ return proto.cc.arduino.cli.commands.BoardListReq.toObject(opt_includeInstance, this);
+};
+
+
+/**
+ * Static version of the {@see toObject} method.
+ * @param {boolean|undefined} includeInstance Whether to include the JSPB
+ * instance for transitional soy proto support:
+ * http://goto/soy-param-migration
+ * @param {!proto.cc.arduino.cli.commands.BoardListReq} msg The msg instance to transform.
+ * @return {!Object}
+ * @suppress {unusedLocalVariables} f is only used for nested messages
+ */
+proto.cc.arduino.cli.commands.BoardListReq.toObject = function(includeInstance, msg) {
+ var f, obj = {
+ instance: (f = msg.getInstance()) && commands_common_pb.Instance.toObject(includeInstance, f)
+ };
+
+ if (includeInstance) {
+ obj.$jspbMessageInstance = msg;
+ }
+ return obj;
+};
+}
+
+
+/**
+ * Deserializes binary data (in protobuf wire format).
+ * @param {jspb.ByteSource} bytes The bytes to deserialize.
+ * @return {!proto.cc.arduino.cli.commands.BoardListReq}
+ */
+proto.cc.arduino.cli.commands.BoardListReq.deserializeBinary = function(bytes) {
+ var reader = new jspb.BinaryReader(bytes);
+ var msg = new proto.cc.arduino.cli.commands.BoardListReq;
+ return proto.cc.arduino.cli.commands.BoardListReq.deserializeBinaryFromReader(msg, reader);
+};
+
+
+/**
+ * Deserializes binary data (in protobuf wire format) from the
+ * given reader into the given message object.
+ * @param {!proto.cc.arduino.cli.commands.BoardListReq} msg The message object to deserialize into.
+ * @param {!jspb.BinaryReader} reader The BinaryReader to use.
+ * @return {!proto.cc.arduino.cli.commands.BoardListReq}
+ */
+proto.cc.arduino.cli.commands.BoardListReq.deserializeBinaryFromReader = function(msg, reader) {
+ while (reader.nextField()) {
+ if (reader.isEndGroup()) {
+ break;
+ }
+ var field = reader.getFieldNumber();
+ switch (field) {
+ case 1:
+ var value = new commands_common_pb.Instance;
+ reader.readMessage(value,commands_common_pb.Instance.deserializeBinaryFromReader);
+ msg.setInstance(value);
+ break;
+ default:
+ reader.skipField();
+ break;
+ }
+ }
+ return msg;
+};
+
+
+/**
+ * Serializes the message to binary data (in protobuf wire format).
+ * @return {!Uint8Array}
+ */
+proto.cc.arduino.cli.commands.BoardListReq.prototype.serializeBinary = function() {
+ var writer = new jspb.BinaryWriter();
+ proto.cc.arduino.cli.commands.BoardListReq.serializeBinaryToWriter(this, writer);
+ return writer.getResultBuffer();
+};
+
+
+/**
+ * Serializes the given message to binary data (in protobuf wire
+ * format), writing to the given BinaryWriter.
+ * @param {!proto.cc.arduino.cli.commands.BoardListReq} message
+ * @param {!jspb.BinaryWriter} writer
+ * @suppress {unusedLocalVariables} f is only used for nested messages
+ */
+proto.cc.arduino.cli.commands.BoardListReq.serializeBinaryToWriter = function(message, writer) {
+ var f = undefined;
+ f = message.getInstance();
+ if (f != null) {
+ writer.writeMessage(
+ 1,
+ f,
+ commands_common_pb.Instance.serializeBinaryToWriter
+ );
+ }
+};
+
+
+/**
+ * optional Instance instance = 1;
+ * @return {?proto.cc.arduino.cli.commands.Instance}
+ */
+proto.cc.arduino.cli.commands.BoardListReq.prototype.getInstance = function() {
+ return /** @type{?proto.cc.arduino.cli.commands.Instance} */ (
+ jspb.Message.getWrapperField(this, commands_common_pb.Instance, 1));
+};
+
+
+/** @param {?proto.cc.arduino.cli.commands.Instance|undefined} value */
+proto.cc.arduino.cli.commands.BoardListReq.prototype.setInstance = function(value) {
+ jspb.Message.setWrapperField(this, 1, value);
+};
+
+
+proto.cc.arduino.cli.commands.BoardListReq.prototype.clearInstance = function() {
+ this.setInstance(undefined);
+};
+
+
+/**
+ * Returns whether this field is set.
+ * @return {boolean}
+ */
+proto.cc.arduino.cli.commands.BoardListReq.prototype.hasInstance = function() {
+ return jspb.Message.getField(this, 1) != null;
+};
+
+
+
+/**
+ * Generated by JsPbCodeGenerator.
+ * @param {Array=} opt_data Optional initial data array, typically from a
+ * server response, or constructed directly in Javascript. The array is used
+ * in place and becomes part of the constructed object. It is not cloned.
+ * If no data is provided, the constructed object will be empty, but still
+ * valid.
+ * @extends {jspb.Message}
+ * @constructor
+ */
+proto.cc.arduino.cli.commands.BoardListResp = function(opt_data) {
+ jspb.Message.initialize(this, opt_data, 0, -1, proto.cc.arduino.cli.commands.BoardListResp.repeatedFields_, null);
+};
+goog.inherits(proto.cc.arduino.cli.commands.BoardListResp, jspb.Message);
+if (goog.DEBUG && !COMPILED) {
+ proto.cc.arduino.cli.commands.BoardListResp.displayName = 'proto.cc.arduino.cli.commands.BoardListResp';
+}
+/**
+ * List of repeated fields within this message type.
+ * @private {!Array}
+ * @const
+ */
+proto.cc.arduino.cli.commands.BoardListResp.repeatedFields_ = [1];
+
+
+
+if (jspb.Message.GENERATE_TO_OBJECT) {
+/**
+ * Creates an object representation of this proto suitable for use in Soy templates.
+ * Field names that are reserved in JavaScript and will be renamed to pb_name.
+ * To access a reserved field use, foo.pb_, eg, foo.pb_default.
+ * For the list of reserved names please see:
+ * com.google.apps.jspb.JsClassTemplate.JS_RESERVED_WORDS.
+ * @param {boolean=} opt_includeInstance Whether to include the JSPB instance
+ * for transitional soy proto support: http://goto/soy-param-migration
+ * @return {!Object}
+ */
+proto.cc.arduino.cli.commands.BoardListResp.prototype.toObject = function(opt_includeInstance) {
+ return proto.cc.arduino.cli.commands.BoardListResp.toObject(opt_includeInstance, this);
+};
+
+
+/**
+ * Static version of the {@see toObject} method.
+ * @param {boolean|undefined} includeInstance Whether to include the JSPB
+ * instance for transitional soy proto support:
+ * http://goto/soy-param-migration
+ * @param {!proto.cc.arduino.cli.commands.BoardListResp} msg The msg instance to transform.
+ * @return {!Object}
+ * @suppress {unusedLocalVariables} f is only used for nested messages
+ */
+proto.cc.arduino.cli.commands.BoardListResp.toObject = function(includeInstance, msg) {
+ var f, obj = {
+ portsList: jspb.Message.toObjectList(msg.getPortsList(),
+ proto.cc.arduino.cli.commands.DetectedPort.toObject, includeInstance)
+ };
+
+ if (includeInstance) {
+ obj.$jspbMessageInstance = msg;
+ }
+ return obj;
+};
+}
+
+
+/**
+ * Deserializes binary data (in protobuf wire format).
+ * @param {jspb.ByteSource} bytes The bytes to deserialize.
+ * @return {!proto.cc.arduino.cli.commands.BoardListResp}
+ */
+proto.cc.arduino.cli.commands.BoardListResp.deserializeBinary = function(bytes) {
+ var reader = new jspb.BinaryReader(bytes);
+ var msg = new proto.cc.arduino.cli.commands.BoardListResp;
+ return proto.cc.arduino.cli.commands.BoardListResp.deserializeBinaryFromReader(msg, reader);
+};
+
+
+/**
+ * Deserializes binary data (in protobuf wire format) from the
+ * given reader into the given message object.
+ * @param {!proto.cc.arduino.cli.commands.BoardListResp} msg The message object to deserialize into.
+ * @param {!jspb.BinaryReader} reader The BinaryReader to use.
+ * @return {!proto.cc.arduino.cli.commands.BoardListResp}
+ */
+proto.cc.arduino.cli.commands.BoardListResp.deserializeBinaryFromReader = function(msg, reader) {
+ while (reader.nextField()) {
+ if (reader.isEndGroup()) {
+ break;
+ }
+ var field = reader.getFieldNumber();
+ switch (field) {
+ case 1:
+ var value = new proto.cc.arduino.cli.commands.DetectedPort;
+ reader.readMessage(value,proto.cc.arduino.cli.commands.DetectedPort.deserializeBinaryFromReader);
+ msg.addPorts(value);
+ break;
+ default:
+ reader.skipField();
+ break;
+ }
+ }
+ return msg;
+};
+
+
+/**
+ * Serializes the message to binary data (in protobuf wire format).
+ * @return {!Uint8Array}
+ */
+proto.cc.arduino.cli.commands.BoardListResp.prototype.serializeBinary = function() {
+ var writer = new jspb.BinaryWriter();
+ proto.cc.arduino.cli.commands.BoardListResp.serializeBinaryToWriter(this, writer);
+ return writer.getResultBuffer();
+};
+
+
+/**
+ * Serializes the given message to binary data (in protobuf wire
+ * format), writing to the given BinaryWriter.
+ * @param {!proto.cc.arduino.cli.commands.BoardListResp} message
+ * @param {!jspb.BinaryWriter} writer
+ * @suppress {unusedLocalVariables} f is only used for nested messages
+ */
+proto.cc.arduino.cli.commands.BoardListResp.serializeBinaryToWriter = function(message, writer) {
+ var f = undefined;
+ f = message.getPortsList();
+ if (f.length > 0) {
+ writer.writeRepeatedMessage(
+ 1,
+ f,
+ proto.cc.arduino.cli.commands.DetectedPort.serializeBinaryToWriter
+ );
+ }
+};
+
+
+/**
+ * repeated DetectedPort ports = 1;
+ * @return {!Array}
+ */
+proto.cc.arduino.cli.commands.BoardListResp.prototype.getPortsList = function() {
+ return /** @type{!Array} */ (
+ jspb.Message.getRepeatedWrapperField(this, proto.cc.arduino.cli.commands.DetectedPort, 1));
+};
+
+
+/** @param {!Array} value */
+proto.cc.arduino.cli.commands.BoardListResp.prototype.setPortsList = function(value) {
+ jspb.Message.setRepeatedWrapperField(this, 1, value);
+};
+
+
+/**
+ * @param {!proto.cc.arduino.cli.commands.DetectedPort=} opt_value
+ * @param {number=} opt_index
+ * @return {!proto.cc.arduino.cli.commands.DetectedPort}
+ */
+proto.cc.arduino.cli.commands.BoardListResp.prototype.addPorts = function(opt_value, opt_index) {
+ return jspb.Message.addToRepeatedWrapperField(this, 1, opt_value, proto.cc.arduino.cli.commands.DetectedPort, opt_index);
+};
+
+
+proto.cc.arduino.cli.commands.BoardListResp.prototype.clearPortsList = function() {
+ this.setPortsList([]);
+};
+
+
+
+/**
+ * Generated by JsPbCodeGenerator.
+ * @param {Array=} opt_data Optional initial data array, typically from a
+ * server response, or constructed directly in Javascript. The array is used
+ * in place and becomes part of the constructed object. It is not cloned.
+ * If no data is provided, the constructed object will be empty, but still
+ * valid.
+ * @extends {jspb.Message}
+ * @constructor
+ */
+proto.cc.arduino.cli.commands.DetectedPort = function(opt_data) {
+ jspb.Message.initialize(this, opt_data, 0, -1, proto.cc.arduino.cli.commands.DetectedPort.repeatedFields_, null);
+};
+goog.inherits(proto.cc.arduino.cli.commands.DetectedPort, jspb.Message);
+if (goog.DEBUG && !COMPILED) {
+ proto.cc.arduino.cli.commands.DetectedPort.displayName = 'proto.cc.arduino.cli.commands.DetectedPort';
+}
+/**
+ * List of repeated fields within this message type.
+ * @private {!Array}
+ * @const
+ */
+proto.cc.arduino.cli.commands.DetectedPort.repeatedFields_ = [4];
+
+
+
+if (jspb.Message.GENERATE_TO_OBJECT) {
+/**
+ * Creates an object representation of this proto suitable for use in Soy templates.
+ * Field names that are reserved in JavaScript and will be renamed to pb_name.
+ * To access a reserved field use, foo.pb_, eg, foo.pb_default.
+ * For the list of reserved names please see:
+ * com.google.apps.jspb.JsClassTemplate.JS_RESERVED_WORDS.
+ * @param {boolean=} opt_includeInstance Whether to include the JSPB instance
+ * for transitional soy proto support: http://goto/soy-param-migration
+ * @return {!Object}
+ */
+proto.cc.arduino.cli.commands.DetectedPort.prototype.toObject = function(opt_includeInstance) {
+ return proto.cc.arduino.cli.commands.DetectedPort.toObject(opt_includeInstance, this);
+};
+
+
+/**
+ * Static version of the {@see toObject} method.
+ * @param {boolean|undefined} includeInstance Whether to include the JSPB
+ * instance for transitional soy proto support:
+ * http://goto/soy-param-migration
+ * @param {!proto.cc.arduino.cli.commands.DetectedPort} msg The msg instance to transform.
+ * @return {!Object}
+ * @suppress {unusedLocalVariables} f is only used for nested messages
+ */
+proto.cc.arduino.cli.commands.DetectedPort.toObject = function(includeInstance, msg) {
+ var f, obj = {
+ address: jspb.Message.getFieldWithDefault(msg, 1, ""),
+ protocol: jspb.Message.getFieldWithDefault(msg, 2, ""),
+ protocolLabel: jspb.Message.getFieldWithDefault(msg, 3, ""),
+ boardsList: jspb.Message.toObjectList(msg.getBoardsList(),
+ proto.cc.arduino.cli.commands.BoardListItem.toObject, includeInstance)
+ };
+
+ if (includeInstance) {
+ obj.$jspbMessageInstance = msg;
+ }
+ return obj;
+};
+}
+
+
+/**
+ * Deserializes binary data (in protobuf wire format).
+ * @param {jspb.ByteSource} bytes The bytes to deserialize.
+ * @return {!proto.cc.arduino.cli.commands.DetectedPort}
+ */
+proto.cc.arduino.cli.commands.DetectedPort.deserializeBinary = function(bytes) {
+ var reader = new jspb.BinaryReader(bytes);
+ var msg = new proto.cc.arduino.cli.commands.DetectedPort;
+ return proto.cc.arduino.cli.commands.DetectedPort.deserializeBinaryFromReader(msg, reader);
+};
+
+
+/**
+ * Deserializes binary data (in protobuf wire format) from the
+ * given reader into the given message object.
+ * @param {!proto.cc.arduino.cli.commands.DetectedPort} msg The message object to deserialize into.
+ * @param {!jspb.BinaryReader} reader The BinaryReader to use.
+ * @return {!proto.cc.arduino.cli.commands.DetectedPort}
+ */
+proto.cc.arduino.cli.commands.DetectedPort.deserializeBinaryFromReader = function(msg, reader) {
+ while (reader.nextField()) {
+ if (reader.isEndGroup()) {
+ break;
+ }
+ var field = reader.getFieldNumber();
+ switch (field) {
+ case 1:
+ var value = /** @type {string} */ (reader.readString());
+ msg.setAddress(value);
+ break;
+ case 2:
+ var value = /** @type {string} */ (reader.readString());
+ msg.setProtocol(value);
+ break;
+ case 3:
+ var value = /** @type {string} */ (reader.readString());
+ msg.setProtocolLabel(value);
+ break;
+ case 4:
+ var value = new proto.cc.arduino.cli.commands.BoardListItem;
+ reader.readMessage(value,proto.cc.arduino.cli.commands.BoardListItem.deserializeBinaryFromReader);
+ msg.addBoards(value);
+ break;
+ default:
+ reader.skipField();
+ break;
+ }
+ }
+ return msg;
+};
+
+
+/**
+ * Serializes the message to binary data (in protobuf wire format).
+ * @return {!Uint8Array}
+ */
+proto.cc.arduino.cli.commands.DetectedPort.prototype.serializeBinary = function() {
+ var writer = new jspb.BinaryWriter();
+ proto.cc.arduino.cli.commands.DetectedPort.serializeBinaryToWriter(this, writer);
+ return writer.getResultBuffer();
+};
+
+
+/**
+ * Serializes the given message to binary data (in protobuf wire
+ * format), writing to the given BinaryWriter.
+ * @param {!proto.cc.arduino.cli.commands.DetectedPort} message
+ * @param {!jspb.BinaryWriter} writer
+ * @suppress {unusedLocalVariables} f is only used for nested messages
+ */
+proto.cc.arduino.cli.commands.DetectedPort.serializeBinaryToWriter = function(message, writer) {
+ var f = undefined;
+ f = message.getAddress();
+ if (f.length > 0) {
+ writer.writeString(
+ 1,
+ f
+ );
+ }
+ f = message.getProtocol();
+ if (f.length > 0) {
+ writer.writeString(
+ 2,
+ f
+ );
+ }
+ f = message.getProtocolLabel();
+ if (f.length > 0) {
+ writer.writeString(
+ 3,
+ f
+ );
+ }
+ f = message.getBoardsList();
+ if (f.length > 0) {
+ writer.writeRepeatedMessage(
+ 4,
+ f,
+ proto.cc.arduino.cli.commands.BoardListItem.serializeBinaryToWriter
+ );
+ }
+};
+
+
+/**
+ * optional string address = 1;
+ * @return {string}
+ */
+proto.cc.arduino.cli.commands.DetectedPort.prototype.getAddress = function() {
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
+};
+
+
+/** @param {string} value */
+proto.cc.arduino.cli.commands.DetectedPort.prototype.setAddress = function(value) {
+ jspb.Message.setProto3StringField(this, 1, value);
+};
+
+
+/**
+ * optional string protocol = 2;
+ * @return {string}
+ */
+proto.cc.arduino.cli.commands.DetectedPort.prototype.getProtocol = function() {
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
+};
+
+
+/** @param {string} value */
+proto.cc.arduino.cli.commands.DetectedPort.prototype.setProtocol = function(value) {
+ jspb.Message.setProto3StringField(this, 2, value);
+};
+
+
+/**
+ * optional string protocol_label = 3;
+ * @return {string}
+ */
+proto.cc.arduino.cli.commands.DetectedPort.prototype.getProtocolLabel = function() {
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 3, ""));
+};
+
+
+/** @param {string} value */
+proto.cc.arduino.cli.commands.DetectedPort.prototype.setProtocolLabel = function(value) {
+ jspb.Message.setProto3StringField(this, 3, value);
+};
+
+
+/**
+ * repeated BoardListItem boards = 4;
+ * @return {!Array}
+ */
+proto.cc.arduino.cli.commands.DetectedPort.prototype.getBoardsList = function() {
+ return /** @type{!Array} */ (
+ jspb.Message.getRepeatedWrapperField(this, proto.cc.arduino.cli.commands.BoardListItem, 4));
+};
+
+
+/** @param {!Array} value */
+proto.cc.arduino.cli.commands.DetectedPort.prototype.setBoardsList = function(value) {
+ jspb.Message.setRepeatedWrapperField(this, 4, value);
+};
+
+
+/**
+ * @param {!proto.cc.arduino.cli.commands.BoardListItem=} opt_value
+ * @param {number=} opt_index
+ * @return {!proto.cc.arduino.cli.commands.BoardListItem}
+ */
+proto.cc.arduino.cli.commands.DetectedPort.prototype.addBoards = function(opt_value, opt_index) {
+ return jspb.Message.addToRepeatedWrapperField(this, 4, opt_value, proto.cc.arduino.cli.commands.BoardListItem, opt_index);
+};
+
+
+proto.cc.arduino.cli.commands.DetectedPort.prototype.clearBoardsList = function() {
+ this.setBoardsList([]);
+};
+
+
+
+/**
+ * Generated by JsPbCodeGenerator.
+ * @param {Array=} opt_data Optional initial data array, typically from a
+ * server response, or constructed directly in Javascript. The array is used
+ * in place and becomes part of the constructed object. It is not cloned.
+ * If no data is provided, the constructed object will be empty, but still
+ * valid.
+ * @extends {jspb.Message}
+ * @constructor
+ */
+proto.cc.arduino.cli.commands.BoardListAllReq = function(opt_data) {
+ jspb.Message.initialize(this, opt_data, 0, -1, proto.cc.arduino.cli.commands.BoardListAllReq.repeatedFields_, null);
+};
+goog.inherits(proto.cc.arduino.cli.commands.BoardListAllReq, jspb.Message);
+if (goog.DEBUG && !COMPILED) {
+ proto.cc.arduino.cli.commands.BoardListAllReq.displayName = 'proto.cc.arduino.cli.commands.BoardListAllReq';
+}
+/**
+ * List of repeated fields within this message type.
+ * @private {!Array}
+ * @const
+ */
+proto.cc.arduino.cli.commands.BoardListAllReq.repeatedFields_ = [2];
+
+
+
+if (jspb.Message.GENERATE_TO_OBJECT) {
+/**
+ * Creates an object representation of this proto suitable for use in Soy templates.
+ * Field names that are reserved in JavaScript and will be renamed to pb_name.
+ * To access a reserved field use, foo.pb_, eg, foo.pb_default.
+ * For the list of reserved names please see:
+ * com.google.apps.jspb.JsClassTemplate.JS_RESERVED_WORDS.
+ * @param {boolean=} opt_includeInstance Whether to include the JSPB instance
+ * for transitional soy proto support: http://goto/soy-param-migration
+ * @return {!Object}
+ */
+proto.cc.arduino.cli.commands.BoardListAllReq.prototype.toObject = function(opt_includeInstance) {
+ return proto.cc.arduino.cli.commands.BoardListAllReq.toObject(opt_includeInstance, this);
+};
+
+
+/**
+ * Static version of the {@see toObject} method.
+ * @param {boolean|undefined} includeInstance Whether to include the JSPB
+ * instance for transitional soy proto support:
+ * http://goto/soy-param-migration
+ * @param {!proto.cc.arduino.cli.commands.BoardListAllReq} msg The msg instance to transform.
+ * @return {!Object}
+ * @suppress {unusedLocalVariables} f is only used for nested messages
+ */
+proto.cc.arduino.cli.commands.BoardListAllReq.toObject = function(includeInstance, msg) {
+ var f, obj = {
+ instance: (f = msg.getInstance()) && commands_common_pb.Instance.toObject(includeInstance, f),
+ searchArgsList: jspb.Message.getRepeatedField(msg, 2)
+ };
+
+ if (includeInstance) {
+ obj.$jspbMessageInstance = msg;
+ }
+ return obj;
+};
+}
+
+
+/**
+ * Deserializes binary data (in protobuf wire format).
+ * @param {jspb.ByteSource} bytes The bytes to deserialize.
+ * @return {!proto.cc.arduino.cli.commands.BoardListAllReq}
+ */
+proto.cc.arduino.cli.commands.BoardListAllReq.deserializeBinary = function(bytes) {
+ var reader = new jspb.BinaryReader(bytes);
+ var msg = new proto.cc.arduino.cli.commands.BoardListAllReq;
+ return proto.cc.arduino.cli.commands.BoardListAllReq.deserializeBinaryFromReader(msg, reader);
+};
+
+
+/**
+ * Deserializes binary data (in protobuf wire format) from the
+ * given reader into the given message object.
+ * @param {!proto.cc.arduino.cli.commands.BoardListAllReq} msg The message object to deserialize into.
+ * @param {!jspb.BinaryReader} reader The BinaryReader to use.
+ * @return {!proto.cc.arduino.cli.commands.BoardListAllReq}
+ */
+proto.cc.arduino.cli.commands.BoardListAllReq.deserializeBinaryFromReader = function(msg, reader) {
+ while (reader.nextField()) {
+ if (reader.isEndGroup()) {
+ break;
+ }
+ var field = reader.getFieldNumber();
+ switch (field) {
+ case 1:
+ var value = new commands_common_pb.Instance;
+ reader.readMessage(value,commands_common_pb.Instance.deserializeBinaryFromReader);
+ msg.setInstance(value);
+ break;
+ case 2:
+ var value = /** @type {string} */ (reader.readString());
+ msg.addSearchArgs(value);
+ break;
+ default:
+ reader.skipField();
+ break;
+ }
+ }
+ return msg;
+};
+
+
+/**
+ * Serializes the message to binary data (in protobuf wire format).
+ * @return {!Uint8Array}
+ */
+proto.cc.arduino.cli.commands.BoardListAllReq.prototype.serializeBinary = function() {
+ var writer = new jspb.BinaryWriter();
+ proto.cc.arduino.cli.commands.BoardListAllReq.serializeBinaryToWriter(this, writer);
+ return writer.getResultBuffer();
+};
+
+
+/**
+ * Serializes the given message to binary data (in protobuf wire
+ * format), writing to the given BinaryWriter.
+ * @param {!proto.cc.arduino.cli.commands.BoardListAllReq} message
+ * @param {!jspb.BinaryWriter} writer
+ * @suppress {unusedLocalVariables} f is only used for nested messages
+ */
+proto.cc.arduino.cli.commands.BoardListAllReq.serializeBinaryToWriter = function(message, writer) {
+ var f = undefined;
+ f = message.getInstance();
+ if (f != null) {
+ writer.writeMessage(
+ 1,
+ f,
+ commands_common_pb.Instance.serializeBinaryToWriter
+ );
+ }
+ f = message.getSearchArgsList();
+ if (f.length > 0) {
+ writer.writeRepeatedString(
+ 2,
+ f
+ );
+ }
+};
+
+
+/**
+ * optional Instance instance = 1;
+ * @return {?proto.cc.arduino.cli.commands.Instance}
+ */
+proto.cc.arduino.cli.commands.BoardListAllReq.prototype.getInstance = function() {
+ return /** @type{?proto.cc.arduino.cli.commands.Instance} */ (
+ jspb.Message.getWrapperField(this, commands_common_pb.Instance, 1));
+};
+
+
+/** @param {?proto.cc.arduino.cli.commands.Instance|undefined} value */
+proto.cc.arduino.cli.commands.BoardListAllReq.prototype.setInstance = function(value) {
+ jspb.Message.setWrapperField(this, 1, value);
+};
+
+
+proto.cc.arduino.cli.commands.BoardListAllReq.prototype.clearInstance = function() {
+ this.setInstance(undefined);
+};
+
+
+/**
+ * Returns whether this field is set.
+ * @return {boolean}
+ */
+proto.cc.arduino.cli.commands.BoardListAllReq.prototype.hasInstance = function() {
+ return jspb.Message.getField(this, 1) != null;
+};
+
+
+/**
+ * repeated string search_args = 2;
+ * @return {!Array}
+ */
+proto.cc.arduino.cli.commands.BoardListAllReq.prototype.getSearchArgsList = function() {
+ return /** @type {!Array} */ (jspb.Message.getRepeatedField(this, 2));
+};
+
+
+/** @param {!Array} value */
+proto.cc.arduino.cli.commands.BoardListAllReq.prototype.setSearchArgsList = function(value) {
+ jspb.Message.setField(this, 2, value || []);
+};
+
+
+/**
+ * @param {string} value
+ * @param {number=} opt_index
+ */
+proto.cc.arduino.cli.commands.BoardListAllReq.prototype.addSearchArgs = function(value, opt_index) {
+ jspb.Message.addToRepeatedField(this, 2, value, opt_index);
+};
+
+
+proto.cc.arduino.cli.commands.BoardListAllReq.prototype.clearSearchArgsList = function() {
+ this.setSearchArgsList([]);
+};
+
+
+
+/**
+ * Generated by JsPbCodeGenerator.
+ * @param {Array=} opt_data Optional initial data array, typically from a
+ * server response, or constructed directly in Javascript. The array is used
+ * in place and becomes part of the constructed object. It is not cloned.
+ * If no data is provided, the constructed object will be empty, but still
+ * valid.
+ * @extends {jspb.Message}
+ * @constructor
+ */
+proto.cc.arduino.cli.commands.BoardListAllResp = function(opt_data) {
+ jspb.Message.initialize(this, opt_data, 0, -1, proto.cc.arduino.cli.commands.BoardListAllResp.repeatedFields_, null);
+};
+goog.inherits(proto.cc.arduino.cli.commands.BoardListAllResp, jspb.Message);
+if (goog.DEBUG && !COMPILED) {
+ proto.cc.arduino.cli.commands.BoardListAllResp.displayName = 'proto.cc.arduino.cli.commands.BoardListAllResp';
+}
+/**
+ * List of repeated fields within this message type.
+ * @private {!Array}
+ * @const
+ */
+proto.cc.arduino.cli.commands.BoardListAllResp.repeatedFields_ = [1];
+
+
+
+if (jspb.Message.GENERATE_TO_OBJECT) {
+/**
+ * Creates an object representation of this proto suitable for use in Soy templates.
+ * Field names that are reserved in JavaScript and will be renamed to pb_name.
+ * To access a reserved field use, foo.pb_, eg, foo.pb_default.
+ * For the list of reserved names please see:
+ * com.google.apps.jspb.JsClassTemplate.JS_RESERVED_WORDS.
+ * @param {boolean=} opt_includeInstance Whether to include the JSPB instance
+ * for transitional soy proto support: http://goto/soy-param-migration
+ * @return {!Object}
+ */
+proto.cc.arduino.cli.commands.BoardListAllResp.prototype.toObject = function(opt_includeInstance) {
+ return proto.cc.arduino.cli.commands.BoardListAllResp.toObject(opt_includeInstance, this);
+};
+
+
+/**
+ * Static version of the {@see toObject} method.
+ * @param {boolean|undefined} includeInstance Whether to include the JSPB
+ * instance for transitional soy proto support:
+ * http://goto/soy-param-migration
+ * @param {!proto.cc.arduino.cli.commands.BoardListAllResp} msg The msg instance to transform.
+ * @return {!Object}
+ * @suppress {unusedLocalVariables} f is only used for nested messages
+ */
+proto.cc.arduino.cli.commands.BoardListAllResp.toObject = function(includeInstance, msg) {
+ var f, obj = {
+ boardsList: jspb.Message.toObjectList(msg.getBoardsList(),
+ proto.cc.arduino.cli.commands.BoardListItem.toObject, includeInstance)
+ };
+
+ if (includeInstance) {
+ obj.$jspbMessageInstance = msg;
+ }
+ return obj;
+};
+}
+
+
+/**
+ * Deserializes binary data (in protobuf wire format).
+ * @param {jspb.ByteSource} bytes The bytes to deserialize.
+ * @return {!proto.cc.arduino.cli.commands.BoardListAllResp}
+ */
+proto.cc.arduino.cli.commands.BoardListAllResp.deserializeBinary = function(bytes) {
+ var reader = new jspb.BinaryReader(bytes);
+ var msg = new proto.cc.arduino.cli.commands.BoardListAllResp;
+ return proto.cc.arduino.cli.commands.BoardListAllResp.deserializeBinaryFromReader(msg, reader);
+};
+
+
+/**
+ * Deserializes binary data (in protobuf wire format) from the
+ * given reader into the given message object.
+ * @param {!proto.cc.arduino.cli.commands.BoardListAllResp} msg The message object to deserialize into.
+ * @param {!jspb.BinaryReader} reader The BinaryReader to use.
+ * @return {!proto.cc.arduino.cli.commands.BoardListAllResp}
+ */
+proto.cc.arduino.cli.commands.BoardListAllResp.deserializeBinaryFromReader = function(msg, reader) {
+ while (reader.nextField()) {
+ if (reader.isEndGroup()) {
+ break;
+ }
+ var field = reader.getFieldNumber();
+ switch (field) {
+ case 1:
+ var value = new proto.cc.arduino.cli.commands.BoardListItem;
+ reader.readMessage(value,proto.cc.arduino.cli.commands.BoardListItem.deserializeBinaryFromReader);
+ msg.addBoards(value);
+ break;
+ default:
+ reader.skipField();
+ break;
+ }
+ }
+ return msg;
+};
+
+
+/**
+ * Serializes the message to binary data (in protobuf wire format).
+ * @return {!Uint8Array}
+ */
+proto.cc.arduino.cli.commands.BoardListAllResp.prototype.serializeBinary = function() {
+ var writer = new jspb.BinaryWriter();
+ proto.cc.arduino.cli.commands.BoardListAllResp.serializeBinaryToWriter(this, writer);
+ return writer.getResultBuffer();
+};
+
+
+/**
+ * Serializes the given message to binary data (in protobuf wire
+ * format), writing to the given BinaryWriter.
+ * @param {!proto.cc.arduino.cli.commands.BoardListAllResp} message
+ * @param {!jspb.BinaryWriter} writer
+ * @suppress {unusedLocalVariables} f is only used for nested messages
+ */
+proto.cc.arduino.cli.commands.BoardListAllResp.serializeBinaryToWriter = function(message, writer) {
+ var f = undefined;
+ f = message.getBoardsList();
+ if (f.length > 0) {
+ writer.writeRepeatedMessage(
+ 1,
+ f,
+ proto.cc.arduino.cli.commands.BoardListItem.serializeBinaryToWriter
+ );
+ }
+};
+
+
+/**
+ * repeated BoardListItem boards = 1;
+ * @return {!Array}
+ */
+proto.cc.arduino.cli.commands.BoardListAllResp.prototype.getBoardsList = function() {
+ return /** @type{!Array} */ (
+ jspb.Message.getRepeatedWrapperField(this, proto.cc.arduino.cli.commands.BoardListItem, 1));
+};
+
+
+/** @param {!Array} value */
+proto.cc.arduino.cli.commands.BoardListAllResp.prototype.setBoardsList = function(value) {
+ jspb.Message.setRepeatedWrapperField(this, 1, value);
+};
+
+
+/**
+ * @param {!proto.cc.arduino.cli.commands.BoardListItem=} opt_value
+ * @param {number=} opt_index
+ * @return {!proto.cc.arduino.cli.commands.BoardListItem}
+ */
+proto.cc.arduino.cli.commands.BoardListAllResp.prototype.addBoards = function(opt_value, opt_index) {
+ return jspb.Message.addToRepeatedWrapperField(this, 1, opt_value, proto.cc.arduino.cli.commands.BoardListItem, opt_index);
+};
+
+
+proto.cc.arduino.cli.commands.BoardListAllResp.prototype.clearBoardsList = function() {
+ this.setBoardsList([]);
+};
+
+
+
+/**
+ * Generated by JsPbCodeGenerator.
+ * @param {Array=} opt_data Optional initial data array, typically from a
+ * server response, or constructed directly in Javascript. The array is used
+ * in place and becomes part of the constructed object. It is not cloned.
+ * If no data is provided, the constructed object will be empty, but still
+ * valid.
+ * @extends {jspb.Message}
+ * @constructor
+ */
+proto.cc.arduino.cli.commands.BoardListItem = function(opt_data) {
+ jspb.Message.initialize(this, opt_data, 0, -1, null, null);
+};
+goog.inherits(proto.cc.arduino.cli.commands.BoardListItem, jspb.Message);
+if (goog.DEBUG && !COMPILED) {
+ proto.cc.arduino.cli.commands.BoardListItem.displayName = 'proto.cc.arduino.cli.commands.BoardListItem';
+}
+
+
+if (jspb.Message.GENERATE_TO_OBJECT) {
+/**
+ * Creates an object representation of this proto suitable for use in Soy templates.
+ * Field names that are reserved in JavaScript and will be renamed to pb_name.
+ * To access a reserved field use, foo.pb_, eg, foo.pb_default.
+ * For the list of reserved names please see:
+ * com.google.apps.jspb.JsClassTemplate.JS_RESERVED_WORDS.
+ * @param {boolean=} opt_includeInstance Whether to include the JSPB instance
+ * for transitional soy proto support: http://goto/soy-param-migration
+ * @return {!Object}
+ */
+proto.cc.arduino.cli.commands.BoardListItem.prototype.toObject = function(opt_includeInstance) {
+ return proto.cc.arduino.cli.commands.BoardListItem.toObject(opt_includeInstance, this);
+};
+
+
+/**
+ * Static version of the {@see toObject} method.
+ * @param {boolean|undefined} includeInstance Whether to include the JSPB
+ * instance for transitional soy proto support:
+ * http://goto/soy-param-migration
+ * @param {!proto.cc.arduino.cli.commands.BoardListItem} msg The msg instance to transform.
+ * @return {!Object}
+ * @suppress {unusedLocalVariables} f is only used for nested messages
+ */
+proto.cc.arduino.cli.commands.BoardListItem.toObject = function(includeInstance, msg) {
+ var f, obj = {
+ name: jspb.Message.getFieldWithDefault(msg, 1, ""),
+ fqbn: jspb.Message.getFieldWithDefault(msg, 2, "")
+ };
+
+ if (includeInstance) {
+ obj.$jspbMessageInstance = msg;
+ }
+ return obj;
+};
+}
+
+
+/**
+ * Deserializes binary data (in protobuf wire format).
+ * @param {jspb.ByteSource} bytes The bytes to deserialize.
+ * @return {!proto.cc.arduino.cli.commands.BoardListItem}
+ */
+proto.cc.arduino.cli.commands.BoardListItem.deserializeBinary = function(bytes) {
+ var reader = new jspb.BinaryReader(bytes);
+ var msg = new proto.cc.arduino.cli.commands.BoardListItem;
+ return proto.cc.arduino.cli.commands.BoardListItem.deserializeBinaryFromReader(msg, reader);
+};
+
+
+/**
+ * Deserializes binary data (in protobuf wire format) from the
+ * given reader into the given message object.
+ * @param {!proto.cc.arduino.cli.commands.BoardListItem} msg The message object to deserialize into.
+ * @param {!jspb.BinaryReader} reader The BinaryReader to use.
+ * @return {!proto.cc.arduino.cli.commands.BoardListItem}
+ */
+proto.cc.arduino.cli.commands.BoardListItem.deserializeBinaryFromReader = function(msg, reader) {
+ while (reader.nextField()) {
+ if (reader.isEndGroup()) {
+ break;
+ }
+ var field = reader.getFieldNumber();
+ switch (field) {
+ case 1:
+ var value = /** @type {string} */ (reader.readString());
+ msg.setName(value);
+ break;
+ case 2:
+ var value = /** @type {string} */ (reader.readString());
+ msg.setFqbn(value);
+ break;
+ default:
+ reader.skipField();
+ break;
+ }
+ }
+ return msg;
+};
+
+
+/**
+ * Serializes the message to binary data (in protobuf wire format).
+ * @return {!Uint8Array}
+ */
+proto.cc.arduino.cli.commands.BoardListItem.prototype.serializeBinary = function() {
+ var writer = new jspb.BinaryWriter();
+ proto.cc.arduino.cli.commands.BoardListItem.serializeBinaryToWriter(this, writer);
+ return writer.getResultBuffer();
+};
+
+
+/**
+ * Serializes the given message to binary data (in protobuf wire
+ * format), writing to the given BinaryWriter.
+ * @param {!proto.cc.arduino.cli.commands.BoardListItem} message
+ * @param {!jspb.BinaryWriter} writer
+ * @suppress {unusedLocalVariables} f is only used for nested messages
+ */
+proto.cc.arduino.cli.commands.BoardListItem.serializeBinaryToWriter = function(message, writer) {
+ var f = undefined;
+ f = message.getName();
+ if (f.length > 0) {
+ writer.writeString(
+ 1,
+ f
+ );
+ }
+ f = message.getFqbn();
+ if (f.length > 0) {
+ writer.writeString(
+ 2,
+ f
+ );
+ }
+};
+
+
+/**
+ * optional string name = 1;
+ * @return {string}
+ */
+proto.cc.arduino.cli.commands.BoardListItem.prototype.getName = function() {
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
+};
+
+
+/** @param {string} value */
+proto.cc.arduino.cli.commands.BoardListItem.prototype.setName = function(value) {
+ jspb.Message.setProto3StringField(this, 1, value);
+};
+
+
+/**
+ * optional string FQBN = 2;
+ * @return {string}
+ */
+proto.cc.arduino.cli.commands.BoardListItem.prototype.getFqbn = function() {
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
+};
+
+
+/** @param {string} value */
+proto.cc.arduino.cli.commands.BoardListItem.prototype.setFqbn = function(value) {
+ jspb.Message.setProto3StringField(this, 2, value);
+};
+
+
+goog.object.extend(exports, proto.cc.arduino.cli.commands);
diff --git a/arduino-ide-extension/src/node/cli-protocol/commands/commands_grpc_pb.d.ts b/arduino-ide-extension/src/node/cli-protocol/commands/commands_grpc_pb.d.ts
new file mode 100644
index 00000000..678aed9c
--- /dev/null
+++ b/arduino-ide-extension/src/node/cli-protocol/commands/commands_grpc_pb.d.ts
@@ -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 {
+ 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 {
+ path: string; // "/cc.arduino.cli.commands.ArduinoCore/Init"
+ requestStream: boolean; // false
+ responseStream: boolean; // true
+ requestSerialize: grpc.serialize;
+ requestDeserialize: grpc.deserialize;
+ responseSerialize: grpc.serialize;
+ responseDeserialize: grpc.deserialize;
+}
+interface IArduinoCoreService_IDestroy extends grpc.MethodDefinition {
+ path: string; // "/cc.arduino.cli.commands.ArduinoCore/Destroy"
+ requestStream: boolean; // false
+ responseStream: boolean; // false
+ requestSerialize: grpc.serialize;
+ requestDeserialize: grpc.deserialize;
+ responseSerialize: grpc.serialize;
+ responseDeserialize: grpc.deserialize;
+}
+interface IArduinoCoreService_IRescan extends grpc.MethodDefinition {
+ path: string; // "/cc.arduino.cli.commands.ArduinoCore/Rescan"
+ requestStream: boolean; // false
+ responseStream: boolean; // false
+ requestSerialize: grpc.serialize;
+ requestDeserialize: grpc.deserialize;
+ responseSerialize: grpc.serialize;
+ responseDeserialize: grpc.deserialize;
+}
+interface IArduinoCoreService_IUpdateIndex extends grpc.MethodDefinition {
+ path: string; // "/cc.arduino.cli.commands.ArduinoCore/UpdateIndex"
+ requestStream: boolean; // false
+ responseStream: boolean; // true
+ requestSerialize: grpc.serialize;
+ requestDeserialize: grpc.deserialize;
+ responseSerialize: grpc.serialize;
+ responseDeserialize: grpc.deserialize;
+}
+interface IArduinoCoreService_IUpdateLibrariesIndex extends grpc.MethodDefinition {
+ path: string; // "/cc.arduino.cli.commands.ArduinoCore/UpdateLibrariesIndex"
+ requestStream: boolean; // false
+ responseStream: boolean; // true
+ requestSerialize: grpc.serialize;
+ requestDeserialize: grpc.deserialize;
+ responseSerialize: grpc.serialize;
+ responseDeserialize: grpc.deserialize;
+}
+interface IArduinoCoreService_IVersion extends grpc.MethodDefinition {
+ path: string; // "/cc.arduino.cli.commands.ArduinoCore/Version"
+ requestStream: boolean; // false
+ responseStream: boolean; // false
+ requestSerialize: grpc.serialize;
+ requestDeserialize: grpc.deserialize;
+ responseSerialize: grpc.serialize;
+ responseDeserialize: grpc.deserialize;
+}
+interface IArduinoCoreService_IBoardDetails extends grpc.MethodDefinition {
+ path: string; // "/cc.arduino.cli.commands.ArduinoCore/BoardDetails"
+ requestStream: boolean; // false
+ responseStream: boolean; // false
+ requestSerialize: grpc.serialize;
+ requestDeserialize: grpc.deserialize;
+ responseSerialize: grpc.serialize;
+ responseDeserialize: grpc.deserialize;
+}
+interface IArduinoCoreService_IBoardAttach extends grpc.MethodDefinition {
+ path: string; // "/cc.arduino.cli.commands.ArduinoCore/BoardAttach"
+ requestStream: boolean; // false
+ responseStream: boolean; // true
+ requestSerialize: grpc.serialize;
+ requestDeserialize: grpc.deserialize;
+ responseSerialize: grpc.serialize;
+ responseDeserialize: grpc.deserialize;
+}
+interface IArduinoCoreService_IBoardList extends grpc.MethodDefinition {
+ path: string; // "/cc.arduino.cli.commands.ArduinoCore/BoardList"
+ requestStream: boolean; // false
+ responseStream: boolean; // false
+ requestSerialize: grpc.serialize;
+ requestDeserialize: grpc.deserialize;
+ responseSerialize: grpc.serialize;
+ responseDeserialize: grpc.deserialize;
+}
+interface IArduinoCoreService_IBoardListAll extends grpc.MethodDefinition {
+ path: string; // "/cc.arduino.cli.commands.ArduinoCore/BoardListAll"
+ requestStream: boolean; // false
+ responseStream: boolean; // false
+ requestSerialize: grpc.serialize;
+ requestDeserialize: grpc.deserialize;
+ responseSerialize: grpc.serialize;
+ responseDeserialize: grpc.deserialize;
+}
+interface IArduinoCoreService_ICompile extends grpc.MethodDefinition {
+ path: string; // "/cc.arduino.cli.commands.ArduinoCore/Compile"
+ requestStream: boolean; // false
+ responseStream: boolean; // true
+ requestSerialize: grpc.serialize;
+ requestDeserialize: grpc.deserialize;
+ responseSerialize: grpc.serialize;
+ responseDeserialize: grpc.deserialize;
+}
+interface IArduinoCoreService_IPlatformInstall extends grpc.MethodDefinition {
+ path: string; // "/cc.arduino.cli.commands.ArduinoCore/PlatformInstall"
+ requestStream: boolean; // false
+ responseStream: boolean; // true
+ requestSerialize: grpc.serialize;
+ requestDeserialize: grpc.deserialize;
+ responseSerialize: grpc.serialize;
+ responseDeserialize: grpc.deserialize;
+}
+interface IArduinoCoreService_IPlatformDownload extends grpc.MethodDefinition {
+ path: string; // "/cc.arduino.cli.commands.ArduinoCore/PlatformDownload"
+ requestStream: boolean; // false
+ responseStream: boolean; // true
+ requestSerialize: grpc.serialize;
+ requestDeserialize: grpc.deserialize;
+ responseSerialize: grpc.serialize;
+ responseDeserialize: grpc.deserialize;
+}
+interface IArduinoCoreService_IPlatformUninstall extends grpc.MethodDefinition {
+ path: string; // "/cc.arduino.cli.commands.ArduinoCore/PlatformUninstall"
+ requestStream: boolean; // false
+ responseStream: boolean; // true
+ requestSerialize: grpc.serialize;
+ requestDeserialize: grpc.deserialize;
+ responseSerialize: grpc.serialize;
+ responseDeserialize: grpc.deserialize;
+}
+interface IArduinoCoreService_IPlatformUpgrade extends grpc.MethodDefinition {
+ path: string; // "/cc.arduino.cli.commands.ArduinoCore/PlatformUpgrade"
+ requestStream: boolean; // false
+ responseStream: boolean; // true
+ requestSerialize: grpc.serialize;
+ requestDeserialize: grpc.deserialize;
+ responseSerialize: grpc.serialize;
+ responseDeserialize: grpc.deserialize;
+}
+interface IArduinoCoreService_IUpload extends grpc.MethodDefinition {
+ path: string; // "/cc.arduino.cli.commands.ArduinoCore/Upload"
+ requestStream: boolean; // false
+ responseStream: boolean; // true
+ requestSerialize: grpc.serialize;
+ requestDeserialize: grpc.deserialize;
+ responseSerialize: grpc.serialize;
+ responseDeserialize: grpc.deserialize;
+}
+interface IArduinoCoreService_IPlatformSearch extends grpc.MethodDefinition {
+ path: string; // "/cc.arduino.cli.commands.ArduinoCore/PlatformSearch"
+ requestStream: boolean; // false
+ responseStream: boolean; // false
+ requestSerialize: grpc.serialize;
+ requestDeserialize: grpc.deserialize;
+ responseSerialize: grpc.serialize;
+ responseDeserialize: grpc.deserialize;
+}
+interface IArduinoCoreService_IPlatformList extends grpc.MethodDefinition {
+ path: string; // "/cc.arduino.cli.commands.ArduinoCore/PlatformList"
+ requestStream: boolean; // false
+ responseStream: boolean; // false
+ requestSerialize: grpc.serialize;
+ requestDeserialize: grpc.deserialize;
+ responseSerialize: grpc.serialize;
+ responseDeserialize: grpc.deserialize;
+}
+interface IArduinoCoreService_ILibraryDownload extends grpc.MethodDefinition {
+ path: string; // "/cc.arduino.cli.commands.ArduinoCore/LibraryDownload"
+ requestStream: boolean; // false
+ responseStream: boolean; // true
+ requestSerialize: grpc.serialize;
+ requestDeserialize: grpc.deserialize;
+ responseSerialize: grpc.serialize;
+ responseDeserialize: grpc.deserialize;
+}
+interface IArduinoCoreService_ILibraryInstall extends grpc.MethodDefinition {
+ path: string; // "/cc.arduino.cli.commands.ArduinoCore/LibraryInstall"
+ requestStream: boolean; // false
+ responseStream: boolean; // true
+ requestSerialize: grpc.serialize;
+ requestDeserialize: grpc.deserialize;
+ responseSerialize: grpc.serialize;
+ responseDeserialize: grpc.deserialize;
+}
+interface IArduinoCoreService_ILibraryUninstall extends grpc.MethodDefinition {
+ path: string; // "/cc.arduino.cli.commands.ArduinoCore/LibraryUninstall"
+ requestStream: boolean; // false
+ responseStream: boolean; // true
+ requestSerialize: grpc.serialize;
+ requestDeserialize: grpc.deserialize;
+ responseSerialize: grpc.serialize;
+ responseDeserialize: grpc.deserialize;
+}
+interface IArduinoCoreService_ILibraryUpgradeAll extends grpc.MethodDefinition {
+ path: string; // "/cc.arduino.cli.commands.ArduinoCore/LibraryUpgradeAll"
+ requestStream: boolean; // false
+ responseStream: boolean; // true
+ requestSerialize: grpc.serialize;
+ requestDeserialize: grpc.deserialize;
+ responseSerialize: grpc.serialize;
+ responseDeserialize: grpc.deserialize;
+}
+interface IArduinoCoreService_ILibrarySearch extends grpc.MethodDefinition {
+ path: string; // "/cc.arduino.cli.commands.ArduinoCore/LibrarySearch"
+ requestStream: boolean; // false
+ responseStream: boolean; // false
+ requestSerialize: grpc.serialize;
+ requestDeserialize: grpc.deserialize;
+ responseSerialize: grpc.serialize;
+ responseDeserialize: grpc.deserialize;
+}
+interface IArduinoCoreService_ILibraryList extends grpc.MethodDefinition {
+ path: string; // "/cc.arduino.cli.commands.ArduinoCore/LibraryList"
+ requestStream: boolean; // false
+ responseStream: boolean; // false
+ requestSerialize: grpc.serialize;
+ requestDeserialize: grpc.deserialize;
+ responseSerialize: grpc.serialize;
+ responseDeserialize: grpc.deserialize;
+}
+
+export const ArduinoCoreService: IArduinoCoreService;
+
+export interface IArduinoCoreServer {
+ init: grpc.handleServerStreamingCall;
+ destroy: grpc.handleUnaryCall;
+ rescan: grpc.handleUnaryCall;
+ updateIndex: grpc.handleServerStreamingCall;
+ updateLibrariesIndex: grpc.handleServerStreamingCall;
+ version: grpc.handleUnaryCall;
+ boardDetails: grpc.handleUnaryCall;
+ boardAttach: grpc.handleServerStreamingCall;
+ boardList: grpc.handleUnaryCall;
+ boardListAll: grpc.handleUnaryCall;
+ compile: grpc.handleServerStreamingCall;
+ platformInstall: grpc.handleServerStreamingCall;
+ platformDownload: grpc.handleServerStreamingCall;
+ platformUninstall: grpc.handleServerStreamingCall;
+ platformUpgrade: grpc.handleServerStreamingCall;
+ upload: grpc.handleServerStreamingCall;
+ platformSearch: grpc.handleUnaryCall;
+ platformList: grpc.handleUnaryCall;
+ libraryDownload: grpc.handleServerStreamingCall;
+ libraryInstall: grpc.handleServerStreamingCall;
+ libraryUninstall: grpc.handleServerStreamingCall;
+ libraryUpgradeAll: grpc.handleServerStreamingCall;
+ librarySearch: grpc.handleUnaryCall;
+ libraryList: grpc.handleUnaryCall;
+}
+
+export interface IArduinoCoreClient {
+ init(request: commands_commands_pb.InitReq, options?: Partial): grpc.ClientReadableStream;
+ init(request: commands_commands_pb.InitReq, metadata?: grpc.Metadata, options?: Partial): grpc.ClientReadableStream;
+ 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, 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, callback: (error: grpc.ServiceError | null, response: commands_commands_pb.RescanResp) => void): grpc.ClientUnaryCall;
+ updateIndex(request: commands_commands_pb.UpdateIndexReq, options?: Partial): grpc.ClientReadableStream;
+ updateIndex(request: commands_commands_pb.UpdateIndexReq, metadata?: grpc.Metadata, options?: Partial): grpc.ClientReadableStream;
+ updateLibrariesIndex(request: commands_commands_pb.UpdateLibrariesIndexReq, options?: Partial): grpc.ClientReadableStream;
+ updateLibrariesIndex(request: commands_commands_pb.UpdateLibrariesIndexReq, metadata?: grpc.Metadata, options?: Partial): grpc.ClientReadableStream;
+ 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, 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, callback: (error: grpc.ServiceError | null, response: commands_board_pb.BoardDetailsResp) => void): grpc.ClientUnaryCall;
+ boardAttach(request: commands_board_pb.BoardAttachReq, options?: Partial): grpc.ClientReadableStream;
+ boardAttach(request: commands_board_pb.BoardAttachReq, metadata?: grpc.Metadata, options?: Partial): grpc.ClientReadableStream;
+ 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, 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, callback: (error: grpc.ServiceError | null, response: commands_board_pb.BoardListAllResp) => void): grpc.ClientUnaryCall;
+ compile(request: commands_compile_pb.CompileReq, options?: Partial): grpc.ClientReadableStream;
+ compile(request: commands_compile_pb.CompileReq, metadata?: grpc.Metadata, options?: Partial): grpc.ClientReadableStream;
+ platformInstall(request: commands_core_pb.PlatformInstallReq, options?: Partial): grpc.ClientReadableStream;
+ platformInstall(request: commands_core_pb.PlatformInstallReq, metadata?: grpc.Metadata, options?: Partial): grpc.ClientReadableStream;
+ platformDownload(request: commands_core_pb.PlatformDownloadReq, options?: Partial): grpc.ClientReadableStream;
+ platformDownload(request: commands_core_pb.PlatformDownloadReq, metadata?: grpc.Metadata, options?: Partial): grpc.ClientReadableStream;
+ platformUninstall(request: commands_core_pb.PlatformUninstallReq, options?: Partial): grpc.ClientReadableStream;
+ platformUninstall(request: commands_core_pb.PlatformUninstallReq, metadata?: grpc.Metadata, options?: Partial): grpc.ClientReadableStream