зеркало из https://github.com/docker/node-sdk.git
Коммит
a7f38377a0
|
@ -1,3 +1,2 @@
|
|||
*.log
|
||||
node_modules
|
||||
dist
|
||||
|
|
|
@ -1,7 +0,0 @@
|
|||
module.exports = {
|
||||
presets: [
|
||||
'@babel/preset-typescript',
|
||||
['@babel/preset-env', { targets: { node: 'current' } }],
|
||||
],
|
||||
plugins: [],
|
||||
};
|
|
@ -0,0 +1 @@
|
|||
export { ExecRequest, ExecResponse, ListRequest, ListResponse, LogsRequest, LogsResponse, RunRequest, RunResponse, StopRequest, StopResponse, DeleteRequest, DeleteResponse, Container, Port, } from './protos/containers/v1/containers_pb';
|
|
@ -0,0 +1,18 @@
|
|||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
var containers_pb_1 = require("./protos/containers/v1/containers_pb");
|
||||
Object.defineProperty(exports, "ExecRequest", { enumerable: true, get: function () { return containers_pb_1.ExecRequest; } });
|
||||
Object.defineProperty(exports, "ExecResponse", { enumerable: true, get: function () { return containers_pb_1.ExecResponse; } });
|
||||
Object.defineProperty(exports, "ListRequest", { enumerable: true, get: function () { return containers_pb_1.ListRequest; } });
|
||||
Object.defineProperty(exports, "ListResponse", { enumerable: true, get: function () { return containers_pb_1.ListResponse; } });
|
||||
Object.defineProperty(exports, "LogsRequest", { enumerable: true, get: function () { return containers_pb_1.LogsRequest; } });
|
||||
Object.defineProperty(exports, "LogsResponse", { enumerable: true, get: function () { return containers_pb_1.LogsResponse; } });
|
||||
Object.defineProperty(exports, "RunRequest", { enumerable: true, get: function () { return containers_pb_1.RunRequest; } });
|
||||
Object.defineProperty(exports, "RunResponse", { enumerable: true, get: function () { return containers_pb_1.RunResponse; } });
|
||||
Object.defineProperty(exports, "StopRequest", { enumerable: true, get: function () { return containers_pb_1.StopRequest; } });
|
||||
Object.defineProperty(exports, "StopResponse", { enumerable: true, get: function () { return containers_pb_1.StopResponse; } });
|
||||
Object.defineProperty(exports, "DeleteRequest", { enumerable: true, get: function () { return containers_pb_1.DeleteRequest; } });
|
||||
Object.defineProperty(exports, "DeleteResponse", { enumerable: true, get: function () { return containers_pb_1.DeleteResponse; } });
|
||||
Object.defineProperty(exports, "Container", { enumerable: true, get: function () { return containers_pb_1.Container; } });
|
||||
Object.defineProperty(exports, "Port", { enumerable: true, get: function () { return containers_pb_1.Port; } });
|
||||
//# sourceMappingURL=containers.js.map
|
|
@ -0,0 +1 @@
|
|||
{"version":3,"file":"containers.js","sourceRoot":"","sources":["../src/containers.ts"],"names":[],"mappings":";;AAAA,sEAe8C;AAd5C,4GAAA,WAAW,OAAA;AACX,6GAAA,YAAY,OAAA;AACZ,4GAAA,WAAW,OAAA;AACX,6GAAA,YAAY,OAAA;AACZ,4GAAA,WAAW,OAAA;AACX,6GAAA,YAAY,OAAA;AACZ,2GAAA,UAAU,OAAA;AACV,4GAAA,WAAW,OAAA;AACX,4GAAA,WAAW,OAAA;AACX,6GAAA,YAAY,OAAA;AACZ,8GAAA,aAAa,OAAA;AACb,+GAAA,cAAc,OAAA;AACd,0GAAA,SAAS,OAAA;AACT,qGAAA,IAAI,OAAA"}
|
|
@ -0,0 +1 @@
|
|||
export { ListRequest, ListResponse, SetCurrentRequest, SetCurrentResponse, } from './protos/contexts/v1/contexts_pb';
|
|
@ -0,0 +1,8 @@
|
|||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
var contexts_pb_1 = require("./protos/contexts/v1/contexts_pb");
|
||||
Object.defineProperty(exports, "ListRequest", { enumerable: true, get: function () { return contexts_pb_1.ListRequest; } });
|
||||
Object.defineProperty(exports, "ListResponse", { enumerable: true, get: function () { return contexts_pb_1.ListResponse; } });
|
||||
Object.defineProperty(exports, "SetCurrentRequest", { enumerable: true, get: function () { return contexts_pb_1.SetCurrentRequest; } });
|
||||
Object.defineProperty(exports, "SetCurrentResponse", { enumerable: true, get: function () { return contexts_pb_1.SetCurrentResponse; } });
|
||||
//# sourceMappingURL=contexts.js.map
|
|
@ -0,0 +1 @@
|
|||
{"version":3,"file":"contexts.js","sourceRoot":"","sources":["../src/contexts.ts"],"names":[],"mappings":";;AAAA,gEAK0C;AAJxC,0GAAA,WAAW,OAAA;AACX,2GAAA,YAAY,OAAA;AACZ,gHAAA,iBAAiB,OAAA;AACjB,iHAAA,kBAAkB,OAAA"}
|
|
@ -0,0 +1,16 @@
|
|||
import { ContainersClient } from './protos/containers/v1/containers_grpc_pb';
|
||||
import { ContextsClient } from './protos/contexts/v1/contexts_grpc_pb';
|
||||
import { ComposeClient } from './protos/compose/v1/compose_grpc_pb';
|
||||
import { StreamingClient } from './protos/streams/v1/streams_grpc_pb';
|
||||
export declare class Containers extends ContainersClient {
|
||||
constructor();
|
||||
}
|
||||
export declare class Contexts extends ContextsClient {
|
||||
constructor();
|
||||
}
|
||||
export declare class Compose extends ComposeClient {
|
||||
constructor();
|
||||
}
|
||||
export declare class Streams extends StreamingClient {
|
||||
constructor();
|
||||
}
|
|
@ -0,0 +1,35 @@
|
|||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
exports.Streams = exports.Compose = exports.Contexts = exports.Containers = void 0;
|
||||
const grpc_js_1 = require("@grpc/grpc-js");
|
||||
const containers_grpc_pb_1 = require("./protos/containers/v1/containers_grpc_pb");
|
||||
const contexts_grpc_pb_1 = require("./protos/contexts/v1/contexts_grpc_pb");
|
||||
const compose_grpc_pb_1 = require("./protos/compose/v1/compose_grpc_pb");
|
||||
const streams_grpc_pb_1 = require("./protos/streams/v1/streams_grpc_pb");
|
||||
// ~/Library/Containers/com.docker.docker/Data/cli-api.sock
|
||||
const address = 'unix:///tmp/backend.sock';
|
||||
class Containers extends containers_grpc_pb_1.ContainersClient {
|
||||
constructor() {
|
||||
super(address, grpc_js_1.credentials.createInsecure());
|
||||
}
|
||||
}
|
||||
exports.Containers = Containers;
|
||||
class Contexts extends contexts_grpc_pb_1.ContextsClient {
|
||||
constructor() {
|
||||
super(address, grpc_js_1.credentials.createInsecure());
|
||||
}
|
||||
}
|
||||
exports.Contexts = Contexts;
|
||||
class Compose extends compose_grpc_pb_1.ComposeClient {
|
||||
constructor() {
|
||||
super(address, grpc_js_1.credentials.createInsecure());
|
||||
}
|
||||
}
|
||||
exports.Compose = Compose;
|
||||
class Streams extends streams_grpc_pb_1.StreamingClient {
|
||||
constructor() {
|
||||
super(address, grpc_js_1.credentials.createInsecure());
|
||||
}
|
||||
}
|
||||
exports.Streams = Streams;
|
||||
//# sourceMappingURL=index.js.map
|
|
@ -0,0 +1 @@
|
|||
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;AAAA,2CAA4C;AAC5C,kFAA6E;AAC7E,4EAAuE;AACvE,yEAAoE;AACpE,yEAAsE;AAEtE,2DAA2D;AAC3D,MAAM,OAAO,GAAG,0BAA0B,CAAC;AAE3C,MAAa,UAAW,SAAQ,qCAAgB;IAC9C;QACE,KAAK,CAAC,OAAO,EAAE,qBAAW,CAAC,cAAc,EAAE,CAAC,CAAC;IAC/C,CAAC;CACF;AAJD,gCAIC;AAED,MAAa,QAAS,SAAQ,iCAAc;IAC1C;QACE,KAAK,CAAC,OAAO,EAAE,qBAAW,CAAC,cAAc,EAAE,CAAC,CAAC;IAC/C,CAAC;CACF;AAJD,4BAIC;AAED,MAAa,OAAQ,SAAQ,+BAAa;IACxC;QACE,KAAK,CAAC,OAAO,EAAE,qBAAW,CAAC,cAAc,EAAE,CAAC,CAAC;IAC/C,CAAC;CACF;AAJD,0BAIC;AAED,MAAa,OAAQ,SAAQ,iCAAe;IAC1C;QACE,KAAK,CAAC,OAAO,EAAE,qBAAW,CAAC,cAAc,EAAE,CAAC,CAAC;IAC/C,CAAC;CACF;AAJD,0BAIC"}
|
|
@ -0,0 +1,52 @@
|
|||
/*
|
||||
Copyright (c) 2020 Docker Inc.
|
||||
|
||||
Permission is hereby granted, free of charge, to any person
|
||||
obtaining a copy of this software and associated documentation
|
||||
files (the "Software"), to deal in the Software without
|
||||
restriction, including without limitation the rights to use, copy,
|
||||
modify, merge, publish, distribute, sublicense, and/or sell copies
|
||||
of the Software, and to permit persons to whom the Software is
|
||||
furnished to do so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be
|
||||
included in all copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
EXPRESS OR IMPLIED,
|
||||
INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
||||
IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
|
||||
HOLDERS BE LIABLE FOR ANY CLAIM,
|
||||
DAMAGES OR OTHER LIABILITY,
|
||||
WHETHER IN AN ACTION OF CONTRACT,
|
||||
TORT OR OTHERWISE,
|
||||
ARISING FROM, OUT OF OR IN CONNECTION WITH
|
||||
THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
*/
|
||||
|
||||
syntax = "proto3";
|
||||
|
||||
package com.docker.api.protos.compose.v1;
|
||||
|
||||
option go_package = "github.com/docker/api/protos/compose/v1;v1";
|
||||
|
||||
service Compose {
|
||||
rpc Up(ComposeUpRequest) returns (ComposeUpResponse);
|
||||
rpc Down(ComposeDownRequest) returns (ComposeDownResponse);
|
||||
}
|
||||
|
||||
message ComposeUpRequest {
|
||||
string projectName = 1;
|
||||
string workDir = 2;
|
||||
repeated string files = 3;
|
||||
}
|
||||
|
||||
message ComposeUpResponse {
|
||||
}
|
||||
|
||||
message ComposeDownRequest {
|
||||
}
|
||||
|
||||
message ComposeDownResponse {
|
||||
}
|
|
@ -0,0 +1,59 @@
|
|||
// package: com.docker.api.protos.compose.v1
|
||||
// file: compose/v1/compose.proto
|
||||
|
||||
/* tslint:disable */
|
||||
/* eslint-disable */
|
||||
|
||||
import * as grpc from "@grpc/grpc-js";
|
||||
import {handleClientStreamingCall} from "@grpc/grpc-js/build/src/server-call";
|
||||
import * as compose_v1_compose_pb from "../../compose/v1/compose_pb";
|
||||
|
||||
interface IComposeService extends grpc.ServiceDefinition<grpc.UntypedServiceImplementation> {
|
||||
up: IComposeService_IUp;
|
||||
down: IComposeService_IDown;
|
||||
}
|
||||
|
||||
interface IComposeService_IUp extends grpc.MethodDefinition<compose_v1_compose_pb.ComposeUpRequest, compose_v1_compose_pb.ComposeUpResponse> {
|
||||
path: string; // "/com.docker.api.protos.compose.v1.Compose/Up"
|
||||
requestStream: boolean; // false
|
||||
responseStream: boolean; // false
|
||||
requestSerialize: grpc.serialize<compose_v1_compose_pb.ComposeUpRequest>;
|
||||
requestDeserialize: grpc.deserialize<compose_v1_compose_pb.ComposeUpRequest>;
|
||||
responseSerialize: grpc.serialize<compose_v1_compose_pb.ComposeUpResponse>;
|
||||
responseDeserialize: grpc.deserialize<compose_v1_compose_pb.ComposeUpResponse>;
|
||||
}
|
||||
interface IComposeService_IDown extends grpc.MethodDefinition<compose_v1_compose_pb.ComposeDownRequest, compose_v1_compose_pb.ComposeDownResponse> {
|
||||
path: string; // "/com.docker.api.protos.compose.v1.Compose/Down"
|
||||
requestStream: boolean; // false
|
||||
responseStream: boolean; // false
|
||||
requestSerialize: grpc.serialize<compose_v1_compose_pb.ComposeDownRequest>;
|
||||
requestDeserialize: grpc.deserialize<compose_v1_compose_pb.ComposeDownRequest>;
|
||||
responseSerialize: grpc.serialize<compose_v1_compose_pb.ComposeDownResponse>;
|
||||
responseDeserialize: grpc.deserialize<compose_v1_compose_pb.ComposeDownResponse>;
|
||||
}
|
||||
|
||||
export const ComposeService: IComposeService;
|
||||
|
||||
export interface IComposeServer {
|
||||
up: grpc.handleUnaryCall<compose_v1_compose_pb.ComposeUpRequest, compose_v1_compose_pb.ComposeUpResponse>;
|
||||
down: grpc.handleUnaryCall<compose_v1_compose_pb.ComposeDownRequest, compose_v1_compose_pb.ComposeDownResponse>;
|
||||
}
|
||||
|
||||
export interface IComposeClient {
|
||||
up(request: compose_v1_compose_pb.ComposeUpRequest, callback: (error: grpc.ServiceError | null, response: compose_v1_compose_pb.ComposeUpResponse) => void): grpc.ClientUnaryCall;
|
||||
up(request: compose_v1_compose_pb.ComposeUpRequest, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: compose_v1_compose_pb.ComposeUpResponse) => void): grpc.ClientUnaryCall;
|
||||
up(request: compose_v1_compose_pb.ComposeUpRequest, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: compose_v1_compose_pb.ComposeUpResponse) => void): grpc.ClientUnaryCall;
|
||||
down(request: compose_v1_compose_pb.ComposeDownRequest, callback: (error: grpc.ServiceError | null, response: compose_v1_compose_pb.ComposeDownResponse) => void): grpc.ClientUnaryCall;
|
||||
down(request: compose_v1_compose_pb.ComposeDownRequest, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: compose_v1_compose_pb.ComposeDownResponse) => void): grpc.ClientUnaryCall;
|
||||
down(request: compose_v1_compose_pb.ComposeDownRequest, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: compose_v1_compose_pb.ComposeDownResponse) => void): grpc.ClientUnaryCall;
|
||||
}
|
||||
|
||||
export class ComposeClient extends grpc.Client implements IComposeClient {
|
||||
constructor(address: string, credentials: grpc.ChannelCredentials, options?: object);
|
||||
public up(request: compose_v1_compose_pb.ComposeUpRequest, callback: (error: grpc.ServiceError | null, response: compose_v1_compose_pb.ComposeUpResponse) => void): grpc.ClientUnaryCall;
|
||||
public up(request: compose_v1_compose_pb.ComposeUpRequest, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: compose_v1_compose_pb.ComposeUpResponse) => void): grpc.ClientUnaryCall;
|
||||
public up(request: compose_v1_compose_pb.ComposeUpRequest, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: compose_v1_compose_pb.ComposeUpResponse) => void): grpc.ClientUnaryCall;
|
||||
public down(request: compose_v1_compose_pb.ComposeDownRequest, callback: (error: grpc.ServiceError | null, response: compose_v1_compose_pb.ComposeDownResponse) => void): grpc.ClientUnaryCall;
|
||||
public down(request: compose_v1_compose_pb.ComposeDownRequest, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: compose_v1_compose_pb.ComposeDownResponse) => void): grpc.ClientUnaryCall;
|
||||
public down(request: compose_v1_compose_pb.ComposeDownRequest, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: compose_v1_compose_pb.ComposeDownResponse) => void): grpc.ClientUnaryCall;
|
||||
}
|
|
@ -0,0 +1,104 @@
|
|||
// GENERATED CODE -- DO NOT EDIT!
|
||||
|
||||
// Original file comments:
|
||||
//
|
||||
// Copyright (c) 2020 Docker Inc.
|
||||
//
|
||||
// Permission is hereby granted, free of charge, to any person
|
||||
// obtaining a copy of this software and associated documentation
|
||||
// files (the "Software"), to deal in the Software without
|
||||
// restriction, including without limitation the rights to use, copy,
|
||||
// modify, merge, publish, distribute, sublicense, and/or sell copies
|
||||
// of the Software, and to permit persons to whom the Software is
|
||||
// furnished to do so, subject to the following conditions:
|
||||
//
|
||||
// The above copyright notice and this permission notice shall be
|
||||
// included in all copies or substantial portions of the Software.
|
||||
//
|
||||
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
// EXPRESS OR IMPLIED,
|
||||
// INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
||||
// IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
|
||||
// HOLDERS BE LIABLE FOR ANY CLAIM,
|
||||
// DAMAGES OR OTHER LIABILITY,
|
||||
// WHETHER IN AN ACTION OF CONTRACT,
|
||||
// TORT OR OTHERWISE,
|
||||
// ARISING FROM, OUT OF OR IN CONNECTION WITH
|
||||
// THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
//
|
||||
'use strict';
|
||||
var grpc = require('@grpc/grpc-js');
|
||||
var compose_v1_compose_pb = require('../../compose/v1/compose_pb.js');
|
||||
|
||||
function serialize_com_docker_api_protos_compose_v1_ComposeDownRequest(arg) {
|
||||
if (!(arg instanceof compose_v1_compose_pb.ComposeDownRequest)) {
|
||||
throw new Error('Expected argument of type com.docker.api.protos.compose.v1.ComposeDownRequest');
|
||||
}
|
||||
return Buffer.from(arg.serializeBinary());
|
||||
}
|
||||
|
||||
function deserialize_com_docker_api_protos_compose_v1_ComposeDownRequest(buffer_arg) {
|
||||
return compose_v1_compose_pb.ComposeDownRequest.deserializeBinary(new Uint8Array(buffer_arg));
|
||||
}
|
||||
|
||||
function serialize_com_docker_api_protos_compose_v1_ComposeDownResponse(arg) {
|
||||
if (!(arg instanceof compose_v1_compose_pb.ComposeDownResponse)) {
|
||||
throw new Error('Expected argument of type com.docker.api.protos.compose.v1.ComposeDownResponse');
|
||||
}
|
||||
return Buffer.from(arg.serializeBinary());
|
||||
}
|
||||
|
||||
function deserialize_com_docker_api_protos_compose_v1_ComposeDownResponse(buffer_arg) {
|
||||
return compose_v1_compose_pb.ComposeDownResponse.deserializeBinary(new Uint8Array(buffer_arg));
|
||||
}
|
||||
|
||||
function serialize_com_docker_api_protos_compose_v1_ComposeUpRequest(arg) {
|
||||
if (!(arg instanceof compose_v1_compose_pb.ComposeUpRequest)) {
|
||||
throw new Error('Expected argument of type com.docker.api.protos.compose.v1.ComposeUpRequest');
|
||||
}
|
||||
return Buffer.from(arg.serializeBinary());
|
||||
}
|
||||
|
||||
function deserialize_com_docker_api_protos_compose_v1_ComposeUpRequest(buffer_arg) {
|
||||
return compose_v1_compose_pb.ComposeUpRequest.deserializeBinary(new Uint8Array(buffer_arg));
|
||||
}
|
||||
|
||||
function serialize_com_docker_api_protos_compose_v1_ComposeUpResponse(arg) {
|
||||
if (!(arg instanceof compose_v1_compose_pb.ComposeUpResponse)) {
|
||||
throw new Error('Expected argument of type com.docker.api.protos.compose.v1.ComposeUpResponse');
|
||||
}
|
||||
return Buffer.from(arg.serializeBinary());
|
||||
}
|
||||
|
||||
function deserialize_com_docker_api_protos_compose_v1_ComposeUpResponse(buffer_arg) {
|
||||
return compose_v1_compose_pb.ComposeUpResponse.deserializeBinary(new Uint8Array(buffer_arg));
|
||||
}
|
||||
|
||||
|
||||
var ComposeService = exports.ComposeService = {
|
||||
up: {
|
||||
path: '/com.docker.api.protos.compose.v1.Compose/Up',
|
||||
requestStream: false,
|
||||
responseStream: false,
|
||||
requestType: compose_v1_compose_pb.ComposeUpRequest,
|
||||
responseType: compose_v1_compose_pb.ComposeUpResponse,
|
||||
requestSerialize: serialize_com_docker_api_protos_compose_v1_ComposeUpRequest,
|
||||
requestDeserialize: deserialize_com_docker_api_protos_compose_v1_ComposeUpRequest,
|
||||
responseSerialize: serialize_com_docker_api_protos_compose_v1_ComposeUpResponse,
|
||||
responseDeserialize: deserialize_com_docker_api_protos_compose_v1_ComposeUpResponse,
|
||||
},
|
||||
down: {
|
||||
path: '/com.docker.api.protos.compose.v1.Compose/Down',
|
||||
requestStream: false,
|
||||
responseStream: false,
|
||||
requestType: compose_v1_compose_pb.ComposeDownRequest,
|
||||
responseType: compose_v1_compose_pb.ComposeDownResponse,
|
||||
requestSerialize: serialize_com_docker_api_protos_compose_v1_ComposeDownRequest,
|
||||
requestDeserialize: deserialize_com_docker_api_protos_compose_v1_ComposeDownRequest,
|
||||
responseSerialize: serialize_com_docker_api_protos_compose_v1_ComposeDownResponse,
|
||||
responseDeserialize: deserialize_com_docker_api_protos_compose_v1_ComposeDownResponse,
|
||||
},
|
||||
};
|
||||
|
||||
exports.ComposeClient = grpc.makeGenericClientConstructor(ComposeService);
|
|
@ -0,0 +1 @@
|
|||
{"version":3,"file":"compose_grpc_pb.js","sourceRoot":"","sources":["../../../../src/protos/compose/v1/compose_grpc_pb.js"],"names":[],"mappings":"AAAA,iCAAiC;AAEjC,0BAA0B;AAC1B,EAAE;AACF,iCAAiC;AACjC,EAAE;AACF,8DAA8D;AAC9D,iEAAiE;AACjE,0DAA0D;AAC1D,qEAAqE;AACrE,qEAAqE;AACrE,iEAAiE;AACjE,2DAA2D;AAC3D,EAAE;AACF,iEAAiE;AACjE,kEAAkE;AAClE,EAAE;AACF,kEAAkE;AAClE,sBAAsB;AACtB,kEAAkE;AAClE,wDAAwD;AACxD,6CAA6C;AAC7C,mCAAmC;AACnC,8BAA8B;AAC9B,oCAAoC;AACpC,qBAAqB;AACrB,6CAA6C;AAC7C,6DAA6D;AAC7D,EAAE;AACF,YAAY,CAAC;AACb,IAAI,IAAI,GAAG,OAAO,CAAC,eAAe,CAAC,CAAC;AACpC,IAAI,qBAAqB,GAAG,OAAO,CAAC,gCAAgC,CAAC,CAAC;AAEtE,SAAS,6DAA6D,CAAC,GAAG;IACxE,IAAI,CAAC,CAAC,GAAG,YAAY,qBAAqB,CAAC,kBAAkB,CAAC,EAAE;QAC9D,MAAM,IAAI,KAAK,CAAC,+EAA+E,CAAC,CAAC;KAClG;IACD,OAAO,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,eAAe,EAAE,CAAC,CAAC;AAC5C,CAAC;AAED,SAAS,+DAA+D,CAAC,UAAU;IACjF,OAAO,qBAAqB,CAAC,kBAAkB,CAAC,iBAAiB,CAAC,IAAI,UAAU,CAAC,UAAU,CAAC,CAAC,CAAC;AAChG,CAAC;AAED,SAAS,8DAA8D,CAAC,GAAG;IACzE,IAAI,CAAC,CAAC,GAAG,YAAY,qBAAqB,CAAC,mBAAmB,CAAC,EAAE;QAC/D,MAAM,IAAI,KAAK,CAAC,gFAAgF,CAAC,CAAC;KACnG;IACD,OAAO,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,eAAe,EAAE,CAAC,CAAC;AAC5C,CAAC;AAED,SAAS,gEAAgE,CAAC,UAAU;IAClF,OAAO,qBAAqB,CAAC,mBAAmB,CAAC,iBAAiB,CAAC,IAAI,UAAU,CAAC,UAAU,CAAC,CAAC,CAAC;AACjG,CAAC;AAED,SAAS,2DAA2D,CAAC,GAAG;IACtE,IAAI,CAAC,CAAC,GAAG,YAAY,qBAAqB,CAAC,gBAAgB,CAAC,EAAE;QAC5D,MAAM,IAAI,KAAK,CAAC,6EAA6E,CAAC,CAAC;KAChG;IACD,OAAO,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,eAAe,EAAE,CAAC,CAAC;AAC5C,CAAC;AAED,SAAS,6DAA6D,CAAC,UAAU;IAC/E,OAAO,qBAAqB,CAAC,gBAAgB,CAAC,iBAAiB,CAAC,IAAI,UAAU,CAAC,UAAU,CAAC,CAAC,CAAC;AAC9F,CAAC;AAED,SAAS,4DAA4D,CAAC,GAAG;IACvE,IAAI,CAAC,CAAC,GAAG,YAAY,qBAAqB,CAAC,iBAAiB,CAAC,EAAE;QAC7D,MAAM,IAAI,KAAK,CAAC,8EAA8E,CAAC,CAAC;KACjG;IACD,OAAO,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,eAAe,EAAE,CAAC,CAAC;AAC5C,CAAC;AAED,SAAS,8DAA8D,CAAC,UAAU;IAChF,OAAO,qBAAqB,CAAC,iBAAiB,CAAC,iBAAiB,CAAC,IAAI,UAAU,CAAC,UAAU,CAAC,CAAC,CAAC;AAC/F,CAAC;AAGD,IAAI,cAAc,GAAG,OAAO,CAAC,cAAc,GAAG;IAC5C,EAAE,EAAE;QACF,IAAI,EAAE,8CAA8C;QACpD,aAAa,EAAE,KAAK;QACpB,cAAc,EAAE,KAAK;QACrB,WAAW,EAAE,qBAAqB,CAAC,gBAAgB;QACnD,YAAY,EAAE,qBAAqB,CAAC,iBAAiB;QACrD,gBAAgB,EAAE,2DAA2D;QAC7E,kBAAkB,EAAE,6DAA6D;QACjF,iBAAiB,EAAE,4DAA4D;QAC/E,mBAAmB,EAAE,8DAA8D;KACpF;IACD,IAAI,EAAE;QACJ,IAAI,EAAE,gDAAgD;QACtD,aAAa,EAAE,KAAK;QACpB,cAAc,EAAE,KAAK;QACrB,WAAW,EAAE,qBAAqB,CAAC,kBAAkB;QACrD,YAAY,EAAE,qBAAqB,CAAC,mBAAmB;QACvD,gBAAgB,EAAE,6DAA6D;QAC/E,kBAAkB,EAAE,+DAA+D;QACnF,iBAAiB,EAAE,8DAA8D;QACjF,mBAAmB,EAAE,gEAAgE;KACtF;CACF,CAAC;AAEF,OAAO,CAAC,aAAa,GAAG,IAAI,CAAC,4BAA4B,CAAC,cAAc,CAAC,CAAC"}
|
|
@ -0,0 +1,89 @@
|
|||
// package: com.docker.api.protos.compose.v1
|
||||
// file: compose/v1/compose.proto
|
||||
|
||||
/* tslint:disable */
|
||||
/* eslint-disable */
|
||||
|
||||
import * as jspb from "google-protobuf";
|
||||
|
||||
export class ComposeUpRequest extends jspb.Message {
|
||||
getProjectname(): string;
|
||||
setProjectname(value: string): ComposeUpRequest;
|
||||
|
||||
getWorkdir(): string;
|
||||
setWorkdir(value: string): ComposeUpRequest;
|
||||
|
||||
clearFilesList(): void;
|
||||
getFilesList(): Array<string>;
|
||||
setFilesList(value: Array<string>): ComposeUpRequest;
|
||||
addFiles(value: string, index?: number): string;
|
||||
|
||||
|
||||
serializeBinary(): Uint8Array;
|
||||
toObject(includeInstance?: boolean): ComposeUpRequest.AsObject;
|
||||
static toObject(includeInstance: boolean, msg: ComposeUpRequest): ComposeUpRequest.AsObject;
|
||||
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
|
||||
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
|
||||
static serializeBinaryToWriter(message: ComposeUpRequest, writer: jspb.BinaryWriter): void;
|
||||
static deserializeBinary(bytes: Uint8Array): ComposeUpRequest;
|
||||
static deserializeBinaryFromReader(message: ComposeUpRequest, reader: jspb.BinaryReader): ComposeUpRequest;
|
||||
}
|
||||
|
||||
export namespace ComposeUpRequest {
|
||||
export type AsObject = {
|
||||
projectname: string,
|
||||
workdir: string,
|
||||
filesList: Array<string>,
|
||||
}
|
||||
}
|
||||
|
||||
export class ComposeUpResponse extends jspb.Message {
|
||||
|
||||
serializeBinary(): Uint8Array;
|
||||
toObject(includeInstance?: boolean): ComposeUpResponse.AsObject;
|
||||
static toObject(includeInstance: boolean, msg: ComposeUpResponse): ComposeUpResponse.AsObject;
|
||||
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
|
||||
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
|
||||
static serializeBinaryToWriter(message: ComposeUpResponse, writer: jspb.BinaryWriter): void;
|
||||
static deserializeBinary(bytes: Uint8Array): ComposeUpResponse;
|
||||
static deserializeBinaryFromReader(message: ComposeUpResponse, reader: jspb.BinaryReader): ComposeUpResponse;
|
||||
}
|
||||
|
||||
export namespace ComposeUpResponse {
|
||||
export type AsObject = {
|
||||
}
|
||||
}
|
||||
|
||||
export class ComposeDownRequest extends jspb.Message {
|
||||
|
||||
serializeBinary(): Uint8Array;
|
||||
toObject(includeInstance?: boolean): ComposeDownRequest.AsObject;
|
||||
static toObject(includeInstance: boolean, msg: ComposeDownRequest): ComposeDownRequest.AsObject;
|
||||
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
|
||||
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
|
||||
static serializeBinaryToWriter(message: ComposeDownRequest, writer: jspb.BinaryWriter): void;
|
||||
static deserializeBinary(bytes: Uint8Array): ComposeDownRequest;
|
||||
static deserializeBinaryFromReader(message: ComposeDownRequest, reader: jspb.BinaryReader): ComposeDownRequest;
|
||||
}
|
||||
|
||||
export namespace ComposeDownRequest {
|
||||
export type AsObject = {
|
||||
}
|
||||
}
|
||||
|
||||
export class ComposeDownResponse extends jspb.Message {
|
||||
|
||||
serializeBinary(): Uint8Array;
|
||||
toObject(includeInstance?: boolean): ComposeDownResponse.AsObject;
|
||||
static toObject(includeInstance: boolean, msg: ComposeDownResponse): ComposeDownResponse.AsObject;
|
||||
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
|
||||
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
|
||||
static serializeBinaryToWriter(message: ComposeDownResponse, writer: jspb.BinaryWriter): void;
|
||||
static deserializeBinary(bytes: Uint8Array): ComposeDownResponse;
|
||||
static deserializeBinaryFromReader(message: ComposeDownResponse, reader: jspb.BinaryReader): ComposeDownResponse;
|
||||
}
|
||||
|
||||
export namespace ComposeDownResponse {
|
||||
export type AsObject = {
|
||||
}
|
||||
}
|
|
@ -0,0 +1,622 @@
|
|||
// source: compose/v1/compose.proto
|
||||
/**
|
||||
* @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')();
|
||||
|
||||
goog.exportSymbol('proto.com.docker.api.protos.compose.v1.ComposeDownRequest', null, global);
|
||||
goog.exportSymbol('proto.com.docker.api.protos.compose.v1.ComposeDownResponse', null, global);
|
||||
goog.exportSymbol('proto.com.docker.api.protos.compose.v1.ComposeUpRequest', null, global);
|
||||
goog.exportSymbol('proto.com.docker.api.protos.compose.v1.ComposeUpResponse', 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.com.docker.api.protos.compose.v1.ComposeUpRequest = function(opt_data) {
|
||||
jspb.Message.initialize(this, opt_data, 0, -1, proto.com.docker.api.protos.compose.v1.ComposeUpRequest.repeatedFields_, null);
|
||||
};
|
||||
goog.inherits(proto.com.docker.api.protos.compose.v1.ComposeUpRequest, jspb.Message);
|
||||
if (goog.DEBUG && !COMPILED) {
|
||||
/**
|
||||
* @public
|
||||
* @override
|
||||
*/
|
||||
proto.com.docker.api.protos.compose.v1.ComposeUpRequest.displayName = 'proto.com.docker.api.protos.compose.v1.ComposeUpRequest';
|
||||
}
|
||||
/**
|
||||
* 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.com.docker.api.protos.compose.v1.ComposeUpResponse = function(opt_data) {
|
||||
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
|
||||
};
|
||||
goog.inherits(proto.com.docker.api.protos.compose.v1.ComposeUpResponse, jspb.Message);
|
||||
if (goog.DEBUG && !COMPILED) {
|
||||
/**
|
||||
* @public
|
||||
* @override
|
||||
*/
|
||||
proto.com.docker.api.protos.compose.v1.ComposeUpResponse.displayName = 'proto.com.docker.api.protos.compose.v1.ComposeUpResponse';
|
||||
}
|
||||
/**
|
||||
* 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.com.docker.api.protos.compose.v1.ComposeDownRequest = function(opt_data) {
|
||||
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
|
||||
};
|
||||
goog.inherits(proto.com.docker.api.protos.compose.v1.ComposeDownRequest, jspb.Message);
|
||||
if (goog.DEBUG && !COMPILED) {
|
||||
/**
|
||||
* @public
|
||||
* @override
|
||||
*/
|
||||
proto.com.docker.api.protos.compose.v1.ComposeDownRequest.displayName = 'proto.com.docker.api.protos.compose.v1.ComposeDownRequest';
|
||||
}
|
||||
/**
|
||||
* 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.com.docker.api.protos.compose.v1.ComposeDownResponse = function(opt_data) {
|
||||
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
|
||||
};
|
||||
goog.inherits(proto.com.docker.api.protos.compose.v1.ComposeDownResponse, jspb.Message);
|
||||
if (goog.DEBUG && !COMPILED) {
|
||||
/**
|
||||
* @public
|
||||
* @override
|
||||
*/
|
||||
proto.com.docker.api.protos.compose.v1.ComposeDownResponse.displayName = 'proto.com.docker.api.protos.compose.v1.ComposeDownResponse';
|
||||
}
|
||||
|
||||
/**
|
||||
* List of repeated fields within this message type.
|
||||
* @private {!Array<number>}
|
||||
* @const
|
||||
*/
|
||||
proto.com.docker.api.protos.compose.v1.ComposeUpRequest.repeatedFields_ = [3];
|
||||
|
||||
|
||||
|
||||
if (jspb.Message.GENERATE_TO_OBJECT) {
|
||||
/**
|
||||
* Creates an object representation of this proto.
|
||||
* Field names that are reserved in JavaScript and will be renamed to pb_name.
|
||||
* Optional fields that are not set will be set to undefined.
|
||||
* To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
|
||||
* For the list of reserved names please see:
|
||||
* net/proto2/compiler/js/internal/generator.cc#kKeyword.
|
||||
* @param {boolean=} opt_includeInstance Deprecated. whether to include the
|
||||
* JSPB instance for transitional soy proto support:
|
||||
* http://goto/soy-param-migration
|
||||
* @return {!Object}
|
||||
*/
|
||||
proto.com.docker.api.protos.compose.v1.ComposeUpRequest.prototype.toObject = function(opt_includeInstance) {
|
||||
return proto.com.docker.api.protos.compose.v1.ComposeUpRequest.toObject(opt_includeInstance, this);
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Static version of the {@see toObject} method.
|
||||
* @param {boolean|undefined} includeInstance Deprecated. Whether to include
|
||||
* the JSPB instance for transitional soy proto support:
|
||||
* http://goto/soy-param-migration
|
||||
* @param {!proto.com.docker.api.protos.compose.v1.ComposeUpRequest} msg The msg instance to transform.
|
||||
* @return {!Object}
|
||||
* @suppress {unusedLocalVariables} f is only used for nested messages
|
||||
*/
|
||||
proto.com.docker.api.protos.compose.v1.ComposeUpRequest.toObject = function(includeInstance, msg) {
|
||||
var f, obj = {
|
||||
projectname: jspb.Message.getFieldWithDefault(msg, 1, ""),
|
||||
workdir: jspb.Message.getFieldWithDefault(msg, 2, ""),
|
||||
filesList: (f = jspb.Message.getRepeatedField(msg, 3)) == null ? undefined : 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.com.docker.api.protos.compose.v1.ComposeUpRequest}
|
||||
*/
|
||||
proto.com.docker.api.protos.compose.v1.ComposeUpRequest.deserializeBinary = function(bytes) {
|
||||
var reader = new jspb.BinaryReader(bytes);
|
||||
var msg = new proto.com.docker.api.protos.compose.v1.ComposeUpRequest;
|
||||
return proto.com.docker.api.protos.compose.v1.ComposeUpRequest.deserializeBinaryFromReader(msg, reader);
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Deserializes binary data (in protobuf wire format) from the
|
||||
* given reader into the given message object.
|
||||
* @param {!proto.com.docker.api.protos.compose.v1.ComposeUpRequest} msg The message object to deserialize into.
|
||||
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
|
||||
* @return {!proto.com.docker.api.protos.compose.v1.ComposeUpRequest}
|
||||
*/
|
||||
proto.com.docker.api.protos.compose.v1.ComposeUpRequest.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.setProjectname(value);
|
||||
break;
|
||||
case 2:
|
||||
var value = /** @type {string} */ (reader.readString());
|
||||
msg.setWorkdir(value);
|
||||
break;
|
||||
case 3:
|
||||
var value = /** @type {string} */ (reader.readString());
|
||||
msg.addFiles(value);
|
||||
break;
|
||||
default:
|
||||
reader.skipField();
|
||||
break;
|
||||
}
|
||||
}
|
||||
return msg;
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Serializes the message to binary data (in protobuf wire format).
|
||||
* @return {!Uint8Array}
|
||||
*/
|
||||
proto.com.docker.api.protos.compose.v1.ComposeUpRequest.prototype.serializeBinary = function() {
|
||||
var writer = new jspb.BinaryWriter();
|
||||
proto.com.docker.api.protos.compose.v1.ComposeUpRequest.serializeBinaryToWriter(this, writer);
|
||||
return writer.getResultBuffer();
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Serializes the given message to binary data (in protobuf wire
|
||||
* format), writing to the given BinaryWriter.
|
||||
* @param {!proto.com.docker.api.protos.compose.v1.ComposeUpRequest} message
|
||||
* @param {!jspb.BinaryWriter} writer
|
||||
* @suppress {unusedLocalVariables} f is only used for nested messages
|
||||
*/
|
||||
proto.com.docker.api.protos.compose.v1.ComposeUpRequest.serializeBinaryToWriter = function(message, writer) {
|
||||
var f = undefined;
|
||||
f = message.getProjectname();
|
||||
if (f.length > 0) {
|
||||
writer.writeString(
|
||||
1,
|
||||
f
|
||||
);
|
||||
}
|
||||
f = message.getWorkdir();
|
||||
if (f.length > 0) {
|
||||
writer.writeString(
|
||||
2,
|
||||
f
|
||||
);
|
||||
}
|
||||
f = message.getFilesList();
|
||||
if (f.length > 0) {
|
||||
writer.writeRepeatedString(
|
||||
3,
|
||||
f
|
||||
);
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* optional string projectName = 1;
|
||||
* @return {string}
|
||||
*/
|
||||
proto.com.docker.api.protos.compose.v1.ComposeUpRequest.prototype.getProjectname = function() {
|
||||
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* @param {string} value
|
||||
* @return {!proto.com.docker.api.protos.compose.v1.ComposeUpRequest} returns this
|
||||
*/
|
||||
proto.com.docker.api.protos.compose.v1.ComposeUpRequest.prototype.setProjectname = function(value) {
|
||||
return jspb.Message.setProto3StringField(this, 1, value);
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* optional string workDir = 2;
|
||||
* @return {string}
|
||||
*/
|
||||
proto.com.docker.api.protos.compose.v1.ComposeUpRequest.prototype.getWorkdir = function() {
|
||||
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* @param {string} value
|
||||
* @return {!proto.com.docker.api.protos.compose.v1.ComposeUpRequest} returns this
|
||||
*/
|
||||
proto.com.docker.api.protos.compose.v1.ComposeUpRequest.prototype.setWorkdir = function(value) {
|
||||
return jspb.Message.setProto3StringField(this, 2, value);
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* repeated string files = 3;
|
||||
* @return {!Array<string>}
|
||||
*/
|
||||
proto.com.docker.api.protos.compose.v1.ComposeUpRequest.prototype.getFilesList = function() {
|
||||
return /** @type {!Array<string>} */ (jspb.Message.getRepeatedField(this, 3));
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* @param {!Array<string>} value
|
||||
* @return {!proto.com.docker.api.protos.compose.v1.ComposeUpRequest} returns this
|
||||
*/
|
||||
proto.com.docker.api.protos.compose.v1.ComposeUpRequest.prototype.setFilesList = function(value) {
|
||||
return jspb.Message.setField(this, 3, value || []);
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* @param {string} value
|
||||
* @param {number=} opt_index
|
||||
* @return {!proto.com.docker.api.protos.compose.v1.ComposeUpRequest} returns this
|
||||
*/
|
||||
proto.com.docker.api.protos.compose.v1.ComposeUpRequest.prototype.addFiles = function(value, opt_index) {
|
||||
return jspb.Message.addToRepeatedField(this, 3, value, opt_index);
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Clears the list making it empty but non-null.
|
||||
* @return {!proto.com.docker.api.protos.compose.v1.ComposeUpRequest} returns this
|
||||
*/
|
||||
proto.com.docker.api.protos.compose.v1.ComposeUpRequest.prototype.clearFilesList = function() {
|
||||
return this.setFilesList([]);
|
||||
};
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
if (jspb.Message.GENERATE_TO_OBJECT) {
|
||||
/**
|
||||
* Creates an object representation of this proto.
|
||||
* Field names that are reserved in JavaScript and will be renamed to pb_name.
|
||||
* Optional fields that are not set will be set to undefined.
|
||||
* To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
|
||||
* For the list of reserved names please see:
|
||||
* net/proto2/compiler/js/internal/generator.cc#kKeyword.
|
||||
* @param {boolean=} opt_includeInstance Deprecated. whether to include the
|
||||
* JSPB instance for transitional soy proto support:
|
||||
* http://goto/soy-param-migration
|
||||
* @return {!Object}
|
||||
*/
|
||||
proto.com.docker.api.protos.compose.v1.ComposeUpResponse.prototype.toObject = function(opt_includeInstance) {
|
||||
return proto.com.docker.api.protos.compose.v1.ComposeUpResponse.toObject(opt_includeInstance, this);
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Static version of the {@see toObject} method.
|
||||
* @param {boolean|undefined} includeInstance Deprecated. Whether to include
|
||||
* the JSPB instance for transitional soy proto support:
|
||||
* http://goto/soy-param-migration
|
||||
* @param {!proto.com.docker.api.protos.compose.v1.ComposeUpResponse} msg The msg instance to transform.
|
||||
* @return {!Object}
|
||||
* @suppress {unusedLocalVariables} f is only used for nested messages
|
||||
*/
|
||||
proto.com.docker.api.protos.compose.v1.ComposeUpResponse.toObject = function(includeInstance, msg) {
|
||||
var f, obj = {
|
||||
|
||||
};
|
||||
|
||||
if (includeInstance) {
|
||||
obj.$jspbMessageInstance = msg;
|
||||
}
|
||||
return obj;
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Deserializes binary data (in protobuf wire format).
|
||||
* @param {jspb.ByteSource} bytes The bytes to deserialize.
|
||||
* @return {!proto.com.docker.api.protos.compose.v1.ComposeUpResponse}
|
||||
*/
|
||||
proto.com.docker.api.protos.compose.v1.ComposeUpResponse.deserializeBinary = function(bytes) {
|
||||
var reader = new jspb.BinaryReader(bytes);
|
||||
var msg = new proto.com.docker.api.protos.compose.v1.ComposeUpResponse;
|
||||
return proto.com.docker.api.protos.compose.v1.ComposeUpResponse.deserializeBinaryFromReader(msg, reader);
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Deserializes binary data (in protobuf wire format) from the
|
||||
* given reader into the given message object.
|
||||
* @param {!proto.com.docker.api.protos.compose.v1.ComposeUpResponse} msg The message object to deserialize into.
|
||||
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
|
||||
* @return {!proto.com.docker.api.protos.compose.v1.ComposeUpResponse}
|
||||
*/
|
||||
proto.com.docker.api.protos.compose.v1.ComposeUpResponse.deserializeBinaryFromReader = function(msg, reader) {
|
||||
while (reader.nextField()) {
|
||||
if (reader.isEndGroup()) {
|
||||
break;
|
||||
}
|
||||
var field = reader.getFieldNumber();
|
||||
switch (field) {
|
||||
default:
|
||||
reader.skipField();
|
||||
break;
|
||||
}
|
||||
}
|
||||
return msg;
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Serializes the message to binary data (in protobuf wire format).
|
||||
* @return {!Uint8Array}
|
||||
*/
|
||||
proto.com.docker.api.protos.compose.v1.ComposeUpResponse.prototype.serializeBinary = function() {
|
||||
var writer = new jspb.BinaryWriter();
|
||||
proto.com.docker.api.protos.compose.v1.ComposeUpResponse.serializeBinaryToWriter(this, writer);
|
||||
return writer.getResultBuffer();
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Serializes the given message to binary data (in protobuf wire
|
||||
* format), writing to the given BinaryWriter.
|
||||
* @param {!proto.com.docker.api.protos.compose.v1.ComposeUpResponse} message
|
||||
* @param {!jspb.BinaryWriter} writer
|
||||
* @suppress {unusedLocalVariables} f is only used for nested messages
|
||||
*/
|
||||
proto.com.docker.api.protos.compose.v1.ComposeUpResponse.serializeBinaryToWriter = function(message, writer) {
|
||||
var f = undefined;
|
||||
};
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
if (jspb.Message.GENERATE_TO_OBJECT) {
|
||||
/**
|
||||
* Creates an object representation of this proto.
|
||||
* Field names that are reserved in JavaScript and will be renamed to pb_name.
|
||||
* Optional fields that are not set will be set to undefined.
|
||||
* To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
|
||||
* For the list of reserved names please see:
|
||||
* net/proto2/compiler/js/internal/generator.cc#kKeyword.
|
||||
* @param {boolean=} opt_includeInstance Deprecated. whether to include the
|
||||
* JSPB instance for transitional soy proto support:
|
||||
* http://goto/soy-param-migration
|
||||
* @return {!Object}
|
||||
*/
|
||||
proto.com.docker.api.protos.compose.v1.ComposeDownRequest.prototype.toObject = function(opt_includeInstance) {
|
||||
return proto.com.docker.api.protos.compose.v1.ComposeDownRequest.toObject(opt_includeInstance, this);
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Static version of the {@see toObject} method.
|
||||
* @param {boolean|undefined} includeInstance Deprecated. Whether to include
|
||||
* the JSPB instance for transitional soy proto support:
|
||||
* http://goto/soy-param-migration
|
||||
* @param {!proto.com.docker.api.protos.compose.v1.ComposeDownRequest} msg The msg instance to transform.
|
||||
* @return {!Object}
|
||||
* @suppress {unusedLocalVariables} f is only used for nested messages
|
||||
*/
|
||||
proto.com.docker.api.protos.compose.v1.ComposeDownRequest.toObject = function(includeInstance, msg) {
|
||||
var f, obj = {
|
||||
|
||||
};
|
||||
|
||||
if (includeInstance) {
|
||||
obj.$jspbMessageInstance = msg;
|
||||
}
|
||||
return obj;
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Deserializes binary data (in protobuf wire format).
|
||||
* @param {jspb.ByteSource} bytes The bytes to deserialize.
|
||||
* @return {!proto.com.docker.api.protos.compose.v1.ComposeDownRequest}
|
||||
*/
|
||||
proto.com.docker.api.protos.compose.v1.ComposeDownRequest.deserializeBinary = function(bytes) {
|
||||
var reader = new jspb.BinaryReader(bytes);
|
||||
var msg = new proto.com.docker.api.protos.compose.v1.ComposeDownRequest;
|
||||
return proto.com.docker.api.protos.compose.v1.ComposeDownRequest.deserializeBinaryFromReader(msg, reader);
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Deserializes binary data (in protobuf wire format) from the
|
||||
* given reader into the given message object.
|
||||
* @param {!proto.com.docker.api.protos.compose.v1.ComposeDownRequest} msg The message object to deserialize into.
|
||||
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
|
||||
* @return {!proto.com.docker.api.protos.compose.v1.ComposeDownRequest}
|
||||
*/
|
||||
proto.com.docker.api.protos.compose.v1.ComposeDownRequest.deserializeBinaryFromReader = function(msg, reader) {
|
||||
while (reader.nextField()) {
|
||||
if (reader.isEndGroup()) {
|
||||
break;
|
||||
}
|
||||
var field = reader.getFieldNumber();
|
||||
switch (field) {
|
||||
default:
|
||||
reader.skipField();
|
||||
break;
|
||||
}
|
||||
}
|
||||
return msg;
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Serializes the message to binary data (in protobuf wire format).
|
||||
* @return {!Uint8Array}
|
||||
*/
|
||||
proto.com.docker.api.protos.compose.v1.ComposeDownRequest.prototype.serializeBinary = function() {
|
||||
var writer = new jspb.BinaryWriter();
|
||||
proto.com.docker.api.protos.compose.v1.ComposeDownRequest.serializeBinaryToWriter(this, writer);
|
||||
return writer.getResultBuffer();
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Serializes the given message to binary data (in protobuf wire
|
||||
* format), writing to the given BinaryWriter.
|
||||
* @param {!proto.com.docker.api.protos.compose.v1.ComposeDownRequest} message
|
||||
* @param {!jspb.BinaryWriter} writer
|
||||
* @suppress {unusedLocalVariables} f is only used for nested messages
|
||||
*/
|
||||
proto.com.docker.api.protos.compose.v1.ComposeDownRequest.serializeBinaryToWriter = function(message, writer) {
|
||||
var f = undefined;
|
||||
};
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
if (jspb.Message.GENERATE_TO_OBJECT) {
|
||||
/**
|
||||
* Creates an object representation of this proto.
|
||||
* Field names that are reserved in JavaScript and will be renamed to pb_name.
|
||||
* Optional fields that are not set will be set to undefined.
|
||||
* To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
|
||||
* For the list of reserved names please see:
|
||||
* net/proto2/compiler/js/internal/generator.cc#kKeyword.
|
||||
* @param {boolean=} opt_includeInstance Deprecated. whether to include the
|
||||
* JSPB instance for transitional soy proto support:
|
||||
* http://goto/soy-param-migration
|
||||
* @return {!Object}
|
||||
*/
|
||||
proto.com.docker.api.protos.compose.v1.ComposeDownResponse.prototype.toObject = function(opt_includeInstance) {
|
||||
return proto.com.docker.api.protos.compose.v1.ComposeDownResponse.toObject(opt_includeInstance, this);
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Static version of the {@see toObject} method.
|
||||
* @param {boolean|undefined} includeInstance Deprecated. Whether to include
|
||||
* the JSPB instance for transitional soy proto support:
|
||||
* http://goto/soy-param-migration
|
||||
* @param {!proto.com.docker.api.protos.compose.v1.ComposeDownResponse} msg The msg instance to transform.
|
||||
* @return {!Object}
|
||||
* @suppress {unusedLocalVariables} f is only used for nested messages
|
||||
*/
|
||||
proto.com.docker.api.protos.compose.v1.ComposeDownResponse.toObject = function(includeInstance, msg) {
|
||||
var f, obj = {
|
||||
|
||||
};
|
||||
|
||||
if (includeInstance) {
|
||||
obj.$jspbMessageInstance = msg;
|
||||
}
|
||||
return obj;
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Deserializes binary data (in protobuf wire format).
|
||||
* @param {jspb.ByteSource} bytes The bytes to deserialize.
|
||||
* @return {!proto.com.docker.api.protos.compose.v1.ComposeDownResponse}
|
||||
*/
|
||||
proto.com.docker.api.protos.compose.v1.ComposeDownResponse.deserializeBinary = function(bytes) {
|
||||
var reader = new jspb.BinaryReader(bytes);
|
||||
var msg = new proto.com.docker.api.protos.compose.v1.ComposeDownResponse;
|
||||
return proto.com.docker.api.protos.compose.v1.ComposeDownResponse.deserializeBinaryFromReader(msg, reader);
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Deserializes binary data (in protobuf wire format) from the
|
||||
* given reader into the given message object.
|
||||
* @param {!proto.com.docker.api.protos.compose.v1.ComposeDownResponse} msg The message object to deserialize into.
|
||||
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
|
||||
* @return {!proto.com.docker.api.protos.compose.v1.ComposeDownResponse}
|
||||
*/
|
||||
proto.com.docker.api.protos.compose.v1.ComposeDownResponse.deserializeBinaryFromReader = function(msg, reader) {
|
||||
while (reader.nextField()) {
|
||||
if (reader.isEndGroup()) {
|
||||
break;
|
||||
}
|
||||
var field = reader.getFieldNumber();
|
||||
switch (field) {
|
||||
default:
|
||||
reader.skipField();
|
||||
break;
|
||||
}
|
||||
}
|
||||
return msg;
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Serializes the message to binary data (in protobuf wire format).
|
||||
* @return {!Uint8Array}
|
||||
*/
|
||||
proto.com.docker.api.protos.compose.v1.ComposeDownResponse.prototype.serializeBinary = function() {
|
||||
var writer = new jspb.BinaryWriter();
|
||||
proto.com.docker.api.protos.compose.v1.ComposeDownResponse.serializeBinaryToWriter(this, writer);
|
||||
return writer.getResultBuffer();
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Serializes the given message to binary data (in protobuf wire
|
||||
* format), writing to the given BinaryWriter.
|
||||
* @param {!proto.com.docker.api.protos.compose.v1.ComposeDownResponse} message
|
||||
* @param {!jspb.BinaryWriter} writer
|
||||
* @suppress {unusedLocalVariables} f is only used for nested messages
|
||||
*/
|
||||
proto.com.docker.api.protos.compose.v1.ComposeDownResponse.serializeBinaryToWriter = function(message, writer) {
|
||||
var f = undefined;
|
||||
};
|
||||
|
||||
|
||||
goog.object.extend(exports, proto.com.docker.api.protos.compose.v1);
|
Различия файлов скрыты, потому что одна или несколько строк слишком длинны
|
@ -0,0 +1,119 @@
|
|||
/*
|
||||
Copyright (c) 2020 Docker Inc.
|
||||
|
||||
Permission is hereby granted, free of charge, to any person
|
||||
obtaining a copy of this software and associated documentation
|
||||
files (the "Software"), to deal in the Software without
|
||||
restriction, including without limitation the rights to use, copy,
|
||||
modify, merge, publish, distribute, sublicense, and/or sell copies
|
||||
of the Software, and to permit persons to whom the Software is
|
||||
furnished to do so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be
|
||||
included in all copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
EXPRESS OR IMPLIED,
|
||||
INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
||||
IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
|
||||
HOLDERS BE LIABLE FOR ANY CLAIM,
|
||||
DAMAGES OR OTHER LIABILITY,
|
||||
WHETHER IN AN ACTION OF CONTRACT,
|
||||
TORT OR OTHERWISE,
|
||||
ARISING FROM, OUT OF OR IN CONNECTION WITH
|
||||
THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
*/
|
||||
|
||||
syntax = "proto3";
|
||||
|
||||
package com.docker.api.protos.containers.v1;
|
||||
|
||||
option go_package = "github.com/docker/api/protos/containers/v1;v1";
|
||||
|
||||
service Containers {
|
||||
rpc List(ListRequest) returns (ListResponse);
|
||||
rpc Stop(StopRequest) returns (StopResponse);
|
||||
rpc Run(RunRequest) returns (RunResponse);
|
||||
rpc Exec(ExecRequest) returns (ExecResponse);
|
||||
rpc Logs(LogsRequest) returns (stream LogsResponse);
|
||||
rpc Delete(DeleteRequest) returns (DeleteResponse);
|
||||
}
|
||||
|
||||
message Port {
|
||||
uint32 host_port = 1;
|
||||
uint32 container_port = 2;
|
||||
string protocol = 3;
|
||||
string host_ip = 4;
|
||||
}
|
||||
|
||||
message Container {
|
||||
string id = 1;
|
||||
string image = 2;
|
||||
string status = 3;
|
||||
string command = 4;
|
||||
uint64 cpu_time = 5;
|
||||
uint64 memory_usage = 6;
|
||||
uint64 memory_limit = 7;
|
||||
uint64 pids_current = 8;
|
||||
uint64 pids_limit = 9;
|
||||
repeated string labels = 10;
|
||||
repeated Port ports = 11;
|
||||
}
|
||||
|
||||
message DeleteRequest {
|
||||
string id = 1;
|
||||
bool force = 2;
|
||||
}
|
||||
|
||||
message DeleteResponse {
|
||||
}
|
||||
|
||||
message StopRequest {
|
||||
string id = 1;
|
||||
uint32 timeout = 2;
|
||||
}
|
||||
|
||||
message StopResponse {
|
||||
}
|
||||
|
||||
message RunRequest {
|
||||
string id = 1;
|
||||
string image = 2;
|
||||
repeated Port ports = 3;
|
||||
map<string, string> labels = 4;
|
||||
repeated string volumes = 5;
|
||||
}
|
||||
|
||||
message RunResponse {
|
||||
}
|
||||
|
||||
message ExecRequest {
|
||||
string id = 1;
|
||||
string command = 2;
|
||||
string stream_id = 3;
|
||||
repeated string args = 4;
|
||||
repeated string env = 5;
|
||||
bool tty = 6;
|
||||
}
|
||||
|
||||
message ExecResponse {
|
||||
bytes output = 1;
|
||||
}
|
||||
|
||||
message ListRequest {
|
||||
bool all = 1;
|
||||
}
|
||||
|
||||
message ListResponse {
|
||||
repeated Container containers = 1;
|
||||
}
|
||||
|
||||
message LogsRequest {
|
||||
string container_id = 1;
|
||||
bool follow = 3;
|
||||
}
|
||||
|
||||
message LogsResponse {
|
||||
bytes value = 1;
|
||||
}
|
|
@ -0,0 +1,125 @@
|
|||
// package: com.docker.api.protos.containers.v1
|
||||
// file: containers/v1/containers.proto
|
||||
|
||||
/* tslint:disable */
|
||||
/* eslint-disable */
|
||||
|
||||
import * as grpc from "@grpc/grpc-js";
|
||||
import {handleClientStreamingCall} from "@grpc/grpc-js/build/src/server-call";
|
||||
import * as containers_v1_containers_pb from "../../containers/v1/containers_pb";
|
||||
|
||||
interface IContainersService extends grpc.ServiceDefinition<grpc.UntypedServiceImplementation> {
|
||||
list: IContainersService_IList;
|
||||
stop: IContainersService_IStop;
|
||||
run: IContainersService_IRun;
|
||||
exec: IContainersService_IExec;
|
||||
logs: IContainersService_ILogs;
|
||||
delete: IContainersService_IDelete;
|
||||
}
|
||||
|
||||
interface IContainersService_IList extends grpc.MethodDefinition<containers_v1_containers_pb.ListRequest, containers_v1_containers_pb.ListResponse> {
|
||||
path: string; // "/com.docker.api.protos.containers.v1.Containers/List"
|
||||
requestStream: boolean; // false
|
||||
responseStream: boolean; // false
|
||||
requestSerialize: grpc.serialize<containers_v1_containers_pb.ListRequest>;
|
||||
requestDeserialize: grpc.deserialize<containers_v1_containers_pb.ListRequest>;
|
||||
responseSerialize: grpc.serialize<containers_v1_containers_pb.ListResponse>;
|
||||
responseDeserialize: grpc.deserialize<containers_v1_containers_pb.ListResponse>;
|
||||
}
|
||||
interface IContainersService_IStop extends grpc.MethodDefinition<containers_v1_containers_pb.StopRequest, containers_v1_containers_pb.StopResponse> {
|
||||
path: string; // "/com.docker.api.protos.containers.v1.Containers/Stop"
|
||||
requestStream: boolean; // false
|
||||
responseStream: boolean; // false
|
||||
requestSerialize: grpc.serialize<containers_v1_containers_pb.StopRequest>;
|
||||
requestDeserialize: grpc.deserialize<containers_v1_containers_pb.StopRequest>;
|
||||
responseSerialize: grpc.serialize<containers_v1_containers_pb.StopResponse>;
|
||||
responseDeserialize: grpc.deserialize<containers_v1_containers_pb.StopResponse>;
|
||||
}
|
||||
interface IContainersService_IRun extends grpc.MethodDefinition<containers_v1_containers_pb.RunRequest, containers_v1_containers_pb.RunResponse> {
|
||||
path: string; // "/com.docker.api.protos.containers.v1.Containers/Run"
|
||||
requestStream: boolean; // false
|
||||
responseStream: boolean; // false
|
||||
requestSerialize: grpc.serialize<containers_v1_containers_pb.RunRequest>;
|
||||
requestDeserialize: grpc.deserialize<containers_v1_containers_pb.RunRequest>;
|
||||
responseSerialize: grpc.serialize<containers_v1_containers_pb.RunResponse>;
|
||||
responseDeserialize: grpc.deserialize<containers_v1_containers_pb.RunResponse>;
|
||||
}
|
||||
interface IContainersService_IExec extends grpc.MethodDefinition<containers_v1_containers_pb.ExecRequest, containers_v1_containers_pb.ExecResponse> {
|
||||
path: string; // "/com.docker.api.protos.containers.v1.Containers/Exec"
|
||||
requestStream: boolean; // false
|
||||
responseStream: boolean; // false
|
||||
requestSerialize: grpc.serialize<containers_v1_containers_pb.ExecRequest>;
|
||||
requestDeserialize: grpc.deserialize<containers_v1_containers_pb.ExecRequest>;
|
||||
responseSerialize: grpc.serialize<containers_v1_containers_pb.ExecResponse>;
|
||||
responseDeserialize: grpc.deserialize<containers_v1_containers_pb.ExecResponse>;
|
||||
}
|
||||
interface IContainersService_ILogs extends grpc.MethodDefinition<containers_v1_containers_pb.LogsRequest, containers_v1_containers_pb.LogsResponse> {
|
||||
path: string; // "/com.docker.api.protos.containers.v1.Containers/Logs"
|
||||
requestStream: boolean; // false
|
||||
responseStream: boolean; // true
|
||||
requestSerialize: grpc.serialize<containers_v1_containers_pb.LogsRequest>;
|
||||
requestDeserialize: grpc.deserialize<containers_v1_containers_pb.LogsRequest>;
|
||||
responseSerialize: grpc.serialize<containers_v1_containers_pb.LogsResponse>;
|
||||
responseDeserialize: grpc.deserialize<containers_v1_containers_pb.LogsResponse>;
|
||||
}
|
||||
interface IContainersService_IDelete extends grpc.MethodDefinition<containers_v1_containers_pb.DeleteRequest, containers_v1_containers_pb.DeleteResponse> {
|
||||
path: string; // "/com.docker.api.protos.containers.v1.Containers/Delete"
|
||||
requestStream: boolean; // false
|
||||
responseStream: boolean; // false
|
||||
requestSerialize: grpc.serialize<containers_v1_containers_pb.DeleteRequest>;
|
||||
requestDeserialize: grpc.deserialize<containers_v1_containers_pb.DeleteRequest>;
|
||||
responseSerialize: grpc.serialize<containers_v1_containers_pb.DeleteResponse>;
|
||||
responseDeserialize: grpc.deserialize<containers_v1_containers_pb.DeleteResponse>;
|
||||
}
|
||||
|
||||
export const ContainersService: IContainersService;
|
||||
|
||||
export interface IContainersServer {
|
||||
list: grpc.handleUnaryCall<containers_v1_containers_pb.ListRequest, containers_v1_containers_pb.ListResponse>;
|
||||
stop: grpc.handleUnaryCall<containers_v1_containers_pb.StopRequest, containers_v1_containers_pb.StopResponse>;
|
||||
run: grpc.handleUnaryCall<containers_v1_containers_pb.RunRequest, containers_v1_containers_pb.RunResponse>;
|
||||
exec: grpc.handleUnaryCall<containers_v1_containers_pb.ExecRequest, containers_v1_containers_pb.ExecResponse>;
|
||||
logs: grpc.handleServerStreamingCall<containers_v1_containers_pb.LogsRequest, containers_v1_containers_pb.LogsResponse>;
|
||||
delete: grpc.handleUnaryCall<containers_v1_containers_pb.DeleteRequest, containers_v1_containers_pb.DeleteResponse>;
|
||||
}
|
||||
|
||||
export interface IContainersClient {
|
||||
list(request: containers_v1_containers_pb.ListRequest, callback: (error: grpc.ServiceError | null, response: containers_v1_containers_pb.ListResponse) => void): grpc.ClientUnaryCall;
|
||||
list(request: containers_v1_containers_pb.ListRequest, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: containers_v1_containers_pb.ListResponse) => void): grpc.ClientUnaryCall;
|
||||
list(request: containers_v1_containers_pb.ListRequest, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: containers_v1_containers_pb.ListResponse) => void): grpc.ClientUnaryCall;
|
||||
stop(request: containers_v1_containers_pb.StopRequest, callback: (error: grpc.ServiceError | null, response: containers_v1_containers_pb.StopResponse) => void): grpc.ClientUnaryCall;
|
||||
stop(request: containers_v1_containers_pb.StopRequest, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: containers_v1_containers_pb.StopResponse) => void): grpc.ClientUnaryCall;
|
||||
stop(request: containers_v1_containers_pb.StopRequest, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: containers_v1_containers_pb.StopResponse) => void): grpc.ClientUnaryCall;
|
||||
run(request: containers_v1_containers_pb.RunRequest, callback: (error: grpc.ServiceError | null, response: containers_v1_containers_pb.RunResponse) => void): grpc.ClientUnaryCall;
|
||||
run(request: containers_v1_containers_pb.RunRequest, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: containers_v1_containers_pb.RunResponse) => void): grpc.ClientUnaryCall;
|
||||
run(request: containers_v1_containers_pb.RunRequest, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: containers_v1_containers_pb.RunResponse) => void): grpc.ClientUnaryCall;
|
||||
exec(request: containers_v1_containers_pb.ExecRequest, callback: (error: grpc.ServiceError | null, response: containers_v1_containers_pb.ExecResponse) => void): grpc.ClientUnaryCall;
|
||||
exec(request: containers_v1_containers_pb.ExecRequest, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: containers_v1_containers_pb.ExecResponse) => void): grpc.ClientUnaryCall;
|
||||
exec(request: containers_v1_containers_pb.ExecRequest, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: containers_v1_containers_pb.ExecResponse) => void): grpc.ClientUnaryCall;
|
||||
logs(request: containers_v1_containers_pb.LogsRequest, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<containers_v1_containers_pb.LogsResponse>;
|
||||
logs(request: containers_v1_containers_pb.LogsRequest, metadata?: grpc.Metadata, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<containers_v1_containers_pb.LogsResponse>;
|
||||
delete(request: containers_v1_containers_pb.DeleteRequest, callback: (error: grpc.ServiceError | null, response: containers_v1_containers_pb.DeleteResponse) => void): grpc.ClientUnaryCall;
|
||||
delete(request: containers_v1_containers_pb.DeleteRequest, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: containers_v1_containers_pb.DeleteResponse) => void): grpc.ClientUnaryCall;
|
||||
delete(request: containers_v1_containers_pb.DeleteRequest, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: containers_v1_containers_pb.DeleteResponse) => void): grpc.ClientUnaryCall;
|
||||
}
|
||||
|
||||
export class ContainersClient extends grpc.Client implements IContainersClient {
|
||||
constructor(address: string, credentials: grpc.ChannelCredentials, options?: object);
|
||||
public list(request: containers_v1_containers_pb.ListRequest, callback: (error: grpc.ServiceError | null, response: containers_v1_containers_pb.ListResponse) => void): grpc.ClientUnaryCall;
|
||||
public list(request: containers_v1_containers_pb.ListRequest, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: containers_v1_containers_pb.ListResponse) => void): grpc.ClientUnaryCall;
|
||||
public list(request: containers_v1_containers_pb.ListRequest, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: containers_v1_containers_pb.ListResponse) => void): grpc.ClientUnaryCall;
|
||||
public stop(request: containers_v1_containers_pb.StopRequest, callback: (error: grpc.ServiceError | null, response: containers_v1_containers_pb.StopResponse) => void): grpc.ClientUnaryCall;
|
||||
public stop(request: containers_v1_containers_pb.StopRequest, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: containers_v1_containers_pb.StopResponse) => void): grpc.ClientUnaryCall;
|
||||
public stop(request: containers_v1_containers_pb.StopRequest, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: containers_v1_containers_pb.StopResponse) => void): grpc.ClientUnaryCall;
|
||||
public run(request: containers_v1_containers_pb.RunRequest, callback: (error: grpc.ServiceError | null, response: containers_v1_containers_pb.RunResponse) => void): grpc.ClientUnaryCall;
|
||||
public run(request: containers_v1_containers_pb.RunRequest, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: containers_v1_containers_pb.RunResponse) => void): grpc.ClientUnaryCall;
|
||||
public run(request: containers_v1_containers_pb.RunRequest, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: containers_v1_containers_pb.RunResponse) => void): grpc.ClientUnaryCall;
|
||||
public exec(request: containers_v1_containers_pb.ExecRequest, callback: (error: grpc.ServiceError | null, response: containers_v1_containers_pb.ExecResponse) => void): grpc.ClientUnaryCall;
|
||||
public exec(request: containers_v1_containers_pb.ExecRequest, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: containers_v1_containers_pb.ExecResponse) => void): grpc.ClientUnaryCall;
|
||||
public exec(request: containers_v1_containers_pb.ExecRequest, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: containers_v1_containers_pb.ExecResponse) => void): grpc.ClientUnaryCall;
|
||||
public logs(request: containers_v1_containers_pb.LogsRequest, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<containers_v1_containers_pb.LogsResponse>;
|
||||
public logs(request: containers_v1_containers_pb.LogsRequest, metadata?: grpc.Metadata, options?: Partial<grpc.CallOptions>): grpc.ClientReadableStream<containers_v1_containers_pb.LogsResponse>;
|
||||
public delete(request: containers_v1_containers_pb.DeleteRequest, callback: (error: grpc.ServiceError | null, response: containers_v1_containers_pb.DeleteResponse) => void): grpc.ClientUnaryCall;
|
||||
public delete(request: containers_v1_containers_pb.DeleteRequest, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: containers_v1_containers_pb.DeleteResponse) => void): grpc.ClientUnaryCall;
|
||||
public delete(request: containers_v1_containers_pb.DeleteRequest, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: containers_v1_containers_pb.DeleteResponse) => void): grpc.ClientUnaryCall;
|
||||
}
|
|
@ -0,0 +1,236 @@
|
|||
// GENERATED CODE -- DO NOT EDIT!
|
||||
|
||||
// Original file comments:
|
||||
//
|
||||
// Copyright (c) 2020 Docker Inc.
|
||||
//
|
||||
// Permission is hereby granted, free of charge, to any person
|
||||
// obtaining a copy of this software and associated documentation
|
||||
// files (the "Software"), to deal in the Software without
|
||||
// restriction, including without limitation the rights to use, copy,
|
||||
// modify, merge, publish, distribute, sublicense, and/or sell copies
|
||||
// of the Software, and to permit persons to whom the Software is
|
||||
// furnished to do so, subject to the following conditions:
|
||||
//
|
||||
// The above copyright notice and this permission notice shall be
|
||||
// included in all copies or substantial portions of the Software.
|
||||
//
|
||||
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
// EXPRESS OR IMPLIED,
|
||||
// INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
||||
// IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
|
||||
// HOLDERS BE LIABLE FOR ANY CLAIM,
|
||||
// DAMAGES OR OTHER LIABILITY,
|
||||
// WHETHER IN AN ACTION OF CONTRACT,
|
||||
// TORT OR OTHERWISE,
|
||||
// ARISING FROM, OUT OF OR IN CONNECTION WITH
|
||||
// THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
//
|
||||
'use strict';
|
||||
var grpc = require('@grpc/grpc-js');
|
||||
var containers_v1_containers_pb = require('../../containers/v1/containers_pb.js');
|
||||
|
||||
function serialize_com_docker_api_protos_containers_v1_DeleteRequest(arg) {
|
||||
if (!(arg instanceof containers_v1_containers_pb.DeleteRequest)) {
|
||||
throw new Error('Expected argument of type com.docker.api.protos.containers.v1.DeleteRequest');
|
||||
}
|
||||
return Buffer.from(arg.serializeBinary());
|
||||
}
|
||||
|
||||
function deserialize_com_docker_api_protos_containers_v1_DeleteRequest(buffer_arg) {
|
||||
return containers_v1_containers_pb.DeleteRequest.deserializeBinary(new Uint8Array(buffer_arg));
|
||||
}
|
||||
|
||||
function serialize_com_docker_api_protos_containers_v1_DeleteResponse(arg) {
|
||||
if (!(arg instanceof containers_v1_containers_pb.DeleteResponse)) {
|
||||
throw new Error('Expected argument of type com.docker.api.protos.containers.v1.DeleteResponse');
|
||||
}
|
||||
return Buffer.from(arg.serializeBinary());
|
||||
}
|
||||
|
||||
function deserialize_com_docker_api_protos_containers_v1_DeleteResponse(buffer_arg) {
|
||||
return containers_v1_containers_pb.DeleteResponse.deserializeBinary(new Uint8Array(buffer_arg));
|
||||
}
|
||||
|
||||
function serialize_com_docker_api_protos_containers_v1_ExecRequest(arg) {
|
||||
if (!(arg instanceof containers_v1_containers_pb.ExecRequest)) {
|
||||
throw new Error('Expected argument of type com.docker.api.protos.containers.v1.ExecRequest');
|
||||
}
|
||||
return Buffer.from(arg.serializeBinary());
|
||||
}
|
||||
|
||||
function deserialize_com_docker_api_protos_containers_v1_ExecRequest(buffer_arg) {
|
||||
return containers_v1_containers_pb.ExecRequest.deserializeBinary(new Uint8Array(buffer_arg));
|
||||
}
|
||||
|
||||
function serialize_com_docker_api_protos_containers_v1_ExecResponse(arg) {
|
||||
if (!(arg instanceof containers_v1_containers_pb.ExecResponse)) {
|
||||
throw new Error('Expected argument of type com.docker.api.protos.containers.v1.ExecResponse');
|
||||
}
|
||||
return Buffer.from(arg.serializeBinary());
|
||||
}
|
||||
|
||||
function deserialize_com_docker_api_protos_containers_v1_ExecResponse(buffer_arg) {
|
||||
return containers_v1_containers_pb.ExecResponse.deserializeBinary(new Uint8Array(buffer_arg));
|
||||
}
|
||||
|
||||
function serialize_com_docker_api_protos_containers_v1_ListRequest(arg) {
|
||||
if (!(arg instanceof containers_v1_containers_pb.ListRequest)) {
|
||||
throw new Error('Expected argument of type com.docker.api.protos.containers.v1.ListRequest');
|
||||
}
|
||||
return Buffer.from(arg.serializeBinary());
|
||||
}
|
||||
|
||||
function deserialize_com_docker_api_protos_containers_v1_ListRequest(buffer_arg) {
|
||||
return containers_v1_containers_pb.ListRequest.deserializeBinary(new Uint8Array(buffer_arg));
|
||||
}
|
||||
|
||||
function serialize_com_docker_api_protos_containers_v1_ListResponse(arg) {
|
||||
if (!(arg instanceof containers_v1_containers_pb.ListResponse)) {
|
||||
throw new Error('Expected argument of type com.docker.api.protos.containers.v1.ListResponse');
|
||||
}
|
||||
return Buffer.from(arg.serializeBinary());
|
||||
}
|
||||
|
||||
function deserialize_com_docker_api_protos_containers_v1_ListResponse(buffer_arg) {
|
||||
return containers_v1_containers_pb.ListResponse.deserializeBinary(new Uint8Array(buffer_arg));
|
||||
}
|
||||
|
||||
function serialize_com_docker_api_protos_containers_v1_LogsRequest(arg) {
|
||||
if (!(arg instanceof containers_v1_containers_pb.LogsRequest)) {
|
||||
throw new Error('Expected argument of type com.docker.api.protos.containers.v1.LogsRequest');
|
||||
}
|
||||
return Buffer.from(arg.serializeBinary());
|
||||
}
|
||||
|
||||
function deserialize_com_docker_api_protos_containers_v1_LogsRequest(buffer_arg) {
|
||||
return containers_v1_containers_pb.LogsRequest.deserializeBinary(new Uint8Array(buffer_arg));
|
||||
}
|
||||
|
||||
function serialize_com_docker_api_protos_containers_v1_LogsResponse(arg) {
|
||||
if (!(arg instanceof containers_v1_containers_pb.LogsResponse)) {
|
||||
throw new Error('Expected argument of type com.docker.api.protos.containers.v1.LogsResponse');
|
||||
}
|
||||
return Buffer.from(arg.serializeBinary());
|
||||
}
|
||||
|
||||
function deserialize_com_docker_api_protos_containers_v1_LogsResponse(buffer_arg) {
|
||||
return containers_v1_containers_pb.LogsResponse.deserializeBinary(new Uint8Array(buffer_arg));
|
||||
}
|
||||
|
||||
function serialize_com_docker_api_protos_containers_v1_RunRequest(arg) {
|
||||
if (!(arg instanceof containers_v1_containers_pb.RunRequest)) {
|
||||
throw new Error('Expected argument of type com.docker.api.protos.containers.v1.RunRequest');
|
||||
}
|
||||
return Buffer.from(arg.serializeBinary());
|
||||
}
|
||||
|
||||
function deserialize_com_docker_api_protos_containers_v1_RunRequest(buffer_arg) {
|
||||
return containers_v1_containers_pb.RunRequest.deserializeBinary(new Uint8Array(buffer_arg));
|
||||
}
|
||||
|
||||
function serialize_com_docker_api_protos_containers_v1_RunResponse(arg) {
|
||||
if (!(arg instanceof containers_v1_containers_pb.RunResponse)) {
|
||||
throw new Error('Expected argument of type com.docker.api.protos.containers.v1.RunResponse');
|
||||
}
|
||||
return Buffer.from(arg.serializeBinary());
|
||||
}
|
||||
|
||||
function deserialize_com_docker_api_protos_containers_v1_RunResponse(buffer_arg) {
|
||||
return containers_v1_containers_pb.RunResponse.deserializeBinary(new Uint8Array(buffer_arg));
|
||||
}
|
||||
|
||||
function serialize_com_docker_api_protos_containers_v1_StopRequest(arg) {
|
||||
if (!(arg instanceof containers_v1_containers_pb.StopRequest)) {
|
||||
throw new Error('Expected argument of type com.docker.api.protos.containers.v1.StopRequest');
|
||||
}
|
||||
return Buffer.from(arg.serializeBinary());
|
||||
}
|
||||
|
||||
function deserialize_com_docker_api_protos_containers_v1_StopRequest(buffer_arg) {
|
||||
return containers_v1_containers_pb.StopRequest.deserializeBinary(new Uint8Array(buffer_arg));
|
||||
}
|
||||
|
||||
function serialize_com_docker_api_protos_containers_v1_StopResponse(arg) {
|
||||
if (!(arg instanceof containers_v1_containers_pb.StopResponse)) {
|
||||
throw new Error('Expected argument of type com.docker.api.protos.containers.v1.StopResponse');
|
||||
}
|
||||
return Buffer.from(arg.serializeBinary());
|
||||
}
|
||||
|
||||
function deserialize_com_docker_api_protos_containers_v1_StopResponse(buffer_arg) {
|
||||
return containers_v1_containers_pb.StopResponse.deserializeBinary(new Uint8Array(buffer_arg));
|
||||
}
|
||||
|
||||
|
||||
var ContainersService = exports.ContainersService = {
|
||||
list: {
|
||||
path: '/com.docker.api.protos.containers.v1.Containers/List',
|
||||
requestStream: false,
|
||||
responseStream: false,
|
||||
requestType: containers_v1_containers_pb.ListRequest,
|
||||
responseType: containers_v1_containers_pb.ListResponse,
|
||||
requestSerialize: serialize_com_docker_api_protos_containers_v1_ListRequest,
|
||||
requestDeserialize: deserialize_com_docker_api_protos_containers_v1_ListRequest,
|
||||
responseSerialize: serialize_com_docker_api_protos_containers_v1_ListResponse,
|
||||
responseDeserialize: deserialize_com_docker_api_protos_containers_v1_ListResponse,
|
||||
},
|
||||
stop: {
|
||||
path: '/com.docker.api.protos.containers.v1.Containers/Stop',
|
||||
requestStream: false,
|
||||
responseStream: false,
|
||||
requestType: containers_v1_containers_pb.StopRequest,
|
||||
responseType: containers_v1_containers_pb.StopResponse,
|
||||
requestSerialize: serialize_com_docker_api_protos_containers_v1_StopRequest,
|
||||
requestDeserialize: deserialize_com_docker_api_protos_containers_v1_StopRequest,
|
||||
responseSerialize: serialize_com_docker_api_protos_containers_v1_StopResponse,
|
||||
responseDeserialize: deserialize_com_docker_api_protos_containers_v1_StopResponse,
|
||||
},
|
||||
run: {
|
||||
path: '/com.docker.api.protos.containers.v1.Containers/Run',
|
||||
requestStream: false,
|
||||
responseStream: false,
|
||||
requestType: containers_v1_containers_pb.RunRequest,
|
||||
responseType: containers_v1_containers_pb.RunResponse,
|
||||
requestSerialize: serialize_com_docker_api_protos_containers_v1_RunRequest,
|
||||
requestDeserialize: deserialize_com_docker_api_protos_containers_v1_RunRequest,
|
||||
responseSerialize: serialize_com_docker_api_protos_containers_v1_RunResponse,
|
||||
responseDeserialize: deserialize_com_docker_api_protos_containers_v1_RunResponse,
|
||||
},
|
||||
exec: {
|
||||
path: '/com.docker.api.protos.containers.v1.Containers/Exec',
|
||||
requestStream: false,
|
||||
responseStream: false,
|
||||
requestType: containers_v1_containers_pb.ExecRequest,
|
||||
responseType: containers_v1_containers_pb.ExecResponse,
|
||||
requestSerialize: serialize_com_docker_api_protos_containers_v1_ExecRequest,
|
||||
requestDeserialize: deserialize_com_docker_api_protos_containers_v1_ExecRequest,
|
||||
responseSerialize: serialize_com_docker_api_protos_containers_v1_ExecResponse,
|
||||
responseDeserialize: deserialize_com_docker_api_protos_containers_v1_ExecResponse,
|
||||
},
|
||||
logs: {
|
||||
path: '/com.docker.api.protos.containers.v1.Containers/Logs',
|
||||
requestStream: false,
|
||||
responseStream: true,
|
||||
requestType: containers_v1_containers_pb.LogsRequest,
|
||||
responseType: containers_v1_containers_pb.LogsResponse,
|
||||
requestSerialize: serialize_com_docker_api_protos_containers_v1_LogsRequest,
|
||||
requestDeserialize: deserialize_com_docker_api_protos_containers_v1_LogsRequest,
|
||||
responseSerialize: serialize_com_docker_api_protos_containers_v1_LogsResponse,
|
||||
responseDeserialize: deserialize_com_docker_api_protos_containers_v1_LogsResponse,
|
||||
},
|
||||
delete: {
|
||||
path: '/com.docker.api.protos.containers.v1.Containers/Delete',
|
||||
requestStream: false,
|
||||
responseStream: false,
|
||||
requestType: containers_v1_containers_pb.DeleteRequest,
|
||||
responseType: containers_v1_containers_pb.DeleteResponse,
|
||||
requestSerialize: serialize_com_docker_api_protos_containers_v1_DeleteRequest,
|
||||
requestDeserialize: deserialize_com_docker_api_protos_containers_v1_DeleteRequest,
|
||||
responseSerialize: serialize_com_docker_api_protos_containers_v1_DeleteResponse,
|
||||
responseDeserialize: deserialize_com_docker_api_protos_containers_v1_DeleteResponse,
|
||||
},
|
||||
};
|
||||
|
||||
exports.ContainersClient = grpc.makeGenericClientConstructor(ContainersService);
|
Различия файлов скрыты, потому что одна или несколько строк слишком длинны
|
@ -0,0 +1,409 @@
|
|||
// package: com.docker.api.protos.containers.v1
|
||||
// file: containers/v1/containers.proto
|
||||
|
||||
/* tslint:disable */
|
||||
/* eslint-disable */
|
||||
|
||||
import * as jspb from "google-protobuf";
|
||||
|
||||
export class Port extends jspb.Message {
|
||||
getHostPort(): number;
|
||||
setHostPort(value: number): Port;
|
||||
|
||||
getContainerPort(): number;
|
||||
setContainerPort(value: number): Port;
|
||||
|
||||
getProtocol(): string;
|
||||
setProtocol(value: string): Port;
|
||||
|
||||
getHostIp(): string;
|
||||
setHostIp(value: string): Port;
|
||||
|
||||
|
||||
serializeBinary(): Uint8Array;
|
||||
toObject(includeInstance?: boolean): Port.AsObject;
|
||||
static toObject(includeInstance: boolean, msg: Port): Port.AsObject;
|
||||
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
|
||||
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
|
||||
static serializeBinaryToWriter(message: Port, writer: jspb.BinaryWriter): void;
|
||||
static deserializeBinary(bytes: Uint8Array): Port;
|
||||
static deserializeBinaryFromReader(message: Port, reader: jspb.BinaryReader): Port;
|
||||
}
|
||||
|
||||
export namespace Port {
|
||||
export type AsObject = {
|
||||
hostPort: number,
|
||||
containerPort: number,
|
||||
protocol: string,
|
||||
hostIp: string,
|
||||
}
|
||||
}
|
||||
|
||||
export class Container extends jspb.Message {
|
||||
getId(): string;
|
||||
setId(value: string): Container;
|
||||
|
||||
getImage(): string;
|
||||
setImage(value: string): Container;
|
||||
|
||||
getStatus(): string;
|
||||
setStatus(value: string): Container;
|
||||
|
||||
getCommand(): string;
|
||||
setCommand(value: string): Container;
|
||||
|
||||
getCpuTime(): number;
|
||||
setCpuTime(value: number): Container;
|
||||
|
||||
getMemoryUsage(): number;
|
||||
setMemoryUsage(value: number): Container;
|
||||
|
||||
getMemoryLimit(): number;
|
||||
setMemoryLimit(value: number): Container;
|
||||
|
||||
getPidsCurrent(): number;
|
||||
setPidsCurrent(value: number): Container;
|
||||
|
||||
getPidsLimit(): number;
|
||||
setPidsLimit(value: number): Container;
|
||||
|
||||
clearLabelsList(): void;
|
||||
getLabelsList(): Array<string>;
|
||||
setLabelsList(value: Array<string>): Container;
|
||||
addLabels(value: string, index?: number): string;
|
||||
|
||||
clearPortsList(): void;
|
||||
getPortsList(): Array<Port>;
|
||||
setPortsList(value: Array<Port>): Container;
|
||||
addPorts(value?: Port, index?: number): Port;
|
||||
|
||||
|
||||
serializeBinary(): Uint8Array;
|
||||
toObject(includeInstance?: boolean): Container.AsObject;
|
||||
static toObject(includeInstance: boolean, msg: Container): Container.AsObject;
|
||||
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
|
||||
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
|
||||
static serializeBinaryToWriter(message: Container, writer: jspb.BinaryWriter): void;
|
||||
static deserializeBinary(bytes: Uint8Array): Container;
|
||||
static deserializeBinaryFromReader(message: Container, reader: jspb.BinaryReader): Container;
|
||||
}
|
||||
|
||||
export namespace Container {
|
||||
export type AsObject = {
|
||||
id: string,
|
||||
image: string,
|
||||
status: string,
|
||||
command: string,
|
||||
cpuTime: number,
|
||||
memoryUsage: number,
|
||||
memoryLimit: number,
|
||||
pidsCurrent: number,
|
||||
pidsLimit: number,
|
||||
labelsList: Array<string>,
|
||||
portsList: Array<Port.AsObject>,
|
||||
}
|
||||
}
|
||||
|
||||
export class DeleteRequest extends jspb.Message {
|
||||
getId(): string;
|
||||
setId(value: string): DeleteRequest;
|
||||
|
||||
getForce(): boolean;
|
||||
setForce(value: boolean): DeleteRequest;
|
||||
|
||||
|
||||
serializeBinary(): Uint8Array;
|
||||
toObject(includeInstance?: boolean): DeleteRequest.AsObject;
|
||||
static toObject(includeInstance: boolean, msg: DeleteRequest): DeleteRequest.AsObject;
|
||||
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
|
||||
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
|
||||
static serializeBinaryToWriter(message: DeleteRequest, writer: jspb.BinaryWriter): void;
|
||||
static deserializeBinary(bytes: Uint8Array): DeleteRequest;
|
||||
static deserializeBinaryFromReader(message: DeleteRequest, reader: jspb.BinaryReader): DeleteRequest;
|
||||
}
|
||||
|
||||
export namespace DeleteRequest {
|
||||
export type AsObject = {
|
||||
id: string,
|
||||
force: boolean,
|
||||
}
|
||||
}
|
||||
|
||||
export class DeleteResponse extends jspb.Message {
|
||||
|
||||
serializeBinary(): Uint8Array;
|
||||
toObject(includeInstance?: boolean): DeleteResponse.AsObject;
|
||||
static toObject(includeInstance: boolean, msg: DeleteResponse): DeleteResponse.AsObject;
|
||||
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
|
||||
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
|
||||
static serializeBinaryToWriter(message: DeleteResponse, writer: jspb.BinaryWriter): void;
|
||||
static deserializeBinary(bytes: Uint8Array): DeleteResponse;
|
||||
static deserializeBinaryFromReader(message: DeleteResponse, reader: jspb.BinaryReader): DeleteResponse;
|
||||
}
|
||||
|
||||
export namespace DeleteResponse {
|
||||
export type AsObject = {
|
||||
}
|
||||
}
|
||||
|
||||
export class StopRequest extends jspb.Message {
|
||||
getId(): string;
|
||||
setId(value: string): StopRequest;
|
||||
|
||||
getTimeout(): number;
|
||||
setTimeout(value: number): StopRequest;
|
||||
|
||||
|
||||
serializeBinary(): Uint8Array;
|
||||
toObject(includeInstance?: boolean): StopRequest.AsObject;
|
||||
static toObject(includeInstance: boolean, msg: StopRequest): StopRequest.AsObject;
|
||||
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
|
||||
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
|
||||
static serializeBinaryToWriter(message: StopRequest, writer: jspb.BinaryWriter): void;
|
||||
static deserializeBinary(bytes: Uint8Array): StopRequest;
|
||||
static deserializeBinaryFromReader(message: StopRequest, reader: jspb.BinaryReader): StopRequest;
|
||||
}
|
||||
|
||||
export namespace StopRequest {
|
||||
export type AsObject = {
|
||||
id: string,
|
||||
timeout: number,
|
||||
}
|
||||
}
|
||||
|
||||
export class StopResponse extends jspb.Message {
|
||||
|
||||
serializeBinary(): Uint8Array;
|
||||
toObject(includeInstance?: boolean): StopResponse.AsObject;
|
||||
static toObject(includeInstance: boolean, msg: StopResponse): StopResponse.AsObject;
|
||||
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
|
||||
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
|
||||
static serializeBinaryToWriter(message: StopResponse, writer: jspb.BinaryWriter): void;
|
||||
static deserializeBinary(bytes: Uint8Array): StopResponse;
|
||||
static deserializeBinaryFromReader(message: StopResponse, reader: jspb.BinaryReader): StopResponse;
|
||||
}
|
||||
|
||||
export namespace StopResponse {
|
||||
export type AsObject = {
|
||||
}
|
||||
}
|
||||
|
||||
export class RunRequest extends jspb.Message {
|
||||
getId(): string;
|
||||
setId(value: string): RunRequest;
|
||||
|
||||
getImage(): string;
|
||||
setImage(value: string): RunRequest;
|
||||
|
||||
clearPortsList(): void;
|
||||
getPortsList(): Array<Port>;
|
||||
setPortsList(value: Array<Port>): RunRequest;
|
||||
addPorts(value?: Port, index?: number): Port;
|
||||
|
||||
|
||||
getLabelsMap(): jspb.Map<string, string>;
|
||||
clearLabelsMap(): void;
|
||||
|
||||
clearVolumesList(): void;
|
||||
getVolumesList(): Array<string>;
|
||||
setVolumesList(value: Array<string>): RunRequest;
|
||||
addVolumes(value: string, index?: number): string;
|
||||
|
||||
|
||||
serializeBinary(): Uint8Array;
|
||||
toObject(includeInstance?: boolean): RunRequest.AsObject;
|
||||
static toObject(includeInstance: boolean, msg: RunRequest): RunRequest.AsObject;
|
||||
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
|
||||
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
|
||||
static serializeBinaryToWriter(message: RunRequest, writer: jspb.BinaryWriter): void;
|
||||
static deserializeBinary(bytes: Uint8Array): RunRequest;
|
||||
static deserializeBinaryFromReader(message: RunRequest, reader: jspb.BinaryReader): RunRequest;
|
||||
}
|
||||
|
||||
export namespace RunRequest {
|
||||
export type AsObject = {
|
||||
id: string,
|
||||
image: string,
|
||||
portsList: Array<Port.AsObject>,
|
||||
|
||||
labelsMap: Array<[string, string]>,
|
||||
volumesList: Array<string>,
|
||||
}
|
||||
}
|
||||
|
||||
export class RunResponse extends jspb.Message {
|
||||
|
||||
serializeBinary(): Uint8Array;
|
||||
toObject(includeInstance?: boolean): RunResponse.AsObject;
|
||||
static toObject(includeInstance: boolean, msg: RunResponse): RunResponse.AsObject;
|
||||
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
|
||||
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
|
||||
static serializeBinaryToWriter(message: RunResponse, writer: jspb.BinaryWriter): void;
|
||||
static deserializeBinary(bytes: Uint8Array): RunResponse;
|
||||
static deserializeBinaryFromReader(message: RunResponse, reader: jspb.BinaryReader): RunResponse;
|
||||
}
|
||||
|
||||
export namespace RunResponse {
|
||||
export type AsObject = {
|
||||
}
|
||||
}
|
||||
|
||||
export class ExecRequest extends jspb.Message {
|
||||
getId(): string;
|
||||
setId(value: string): ExecRequest;
|
||||
|
||||
getCommand(): string;
|
||||
setCommand(value: string): ExecRequest;
|
||||
|
||||
getStreamId(): string;
|
||||
setStreamId(value: string): ExecRequest;
|
||||
|
||||
clearArgsList(): void;
|
||||
getArgsList(): Array<string>;
|
||||
setArgsList(value: Array<string>): ExecRequest;
|
||||
addArgs(value: string, index?: number): string;
|
||||
|
||||
clearEnvList(): void;
|
||||
getEnvList(): Array<string>;
|
||||
setEnvList(value: Array<string>): ExecRequest;
|
||||
addEnv(value: string, index?: number): string;
|
||||
|
||||
getTty(): boolean;
|
||||
setTty(value: boolean): ExecRequest;
|
||||
|
||||
|
||||
serializeBinary(): Uint8Array;
|
||||
toObject(includeInstance?: boolean): ExecRequest.AsObject;
|
||||
static toObject(includeInstance: boolean, msg: ExecRequest): ExecRequest.AsObject;
|
||||
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
|
||||
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
|
||||
static serializeBinaryToWriter(message: ExecRequest, writer: jspb.BinaryWriter): void;
|
||||
static deserializeBinary(bytes: Uint8Array): ExecRequest;
|
||||
static deserializeBinaryFromReader(message: ExecRequest, reader: jspb.BinaryReader): ExecRequest;
|
||||
}
|
||||
|
||||
export namespace ExecRequest {
|
||||
export type AsObject = {
|
||||
id: string,
|
||||
command: string,
|
||||
streamId: string,
|
||||
argsList: Array<string>,
|
||||
envList: Array<string>,
|
||||
tty: boolean,
|
||||
}
|
||||
}
|
||||
|
||||
export class ExecResponse extends jspb.Message {
|
||||
getOutput(): Uint8Array | string;
|
||||
getOutput_asU8(): Uint8Array;
|
||||
getOutput_asB64(): string;
|
||||
setOutput(value: Uint8Array | string): ExecResponse;
|
||||
|
||||
|
||||
serializeBinary(): Uint8Array;
|
||||
toObject(includeInstance?: boolean): ExecResponse.AsObject;
|
||||
static toObject(includeInstance: boolean, msg: ExecResponse): ExecResponse.AsObject;
|
||||
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
|
||||
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
|
||||
static serializeBinaryToWriter(message: ExecResponse, writer: jspb.BinaryWriter): void;
|
||||
static deserializeBinary(bytes: Uint8Array): ExecResponse;
|
||||
static deserializeBinaryFromReader(message: ExecResponse, reader: jspb.BinaryReader): ExecResponse;
|
||||
}
|
||||
|
||||
export namespace ExecResponse {
|
||||
export type AsObject = {
|
||||
output: Uint8Array | string,
|
||||
}
|
||||
}
|
||||
|
||||
export class ListRequest extends jspb.Message {
|
||||
getAll(): boolean;
|
||||
setAll(value: boolean): ListRequest;
|
||||
|
||||
|
||||
serializeBinary(): Uint8Array;
|
||||
toObject(includeInstance?: boolean): ListRequest.AsObject;
|
||||
static toObject(includeInstance: boolean, msg: ListRequest): ListRequest.AsObject;
|
||||
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
|
||||
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
|
||||
static serializeBinaryToWriter(message: ListRequest, writer: jspb.BinaryWriter): void;
|
||||
static deserializeBinary(bytes: Uint8Array): ListRequest;
|
||||
static deserializeBinaryFromReader(message: ListRequest, reader: jspb.BinaryReader): ListRequest;
|
||||
}
|
||||
|
||||
export namespace ListRequest {
|
||||
export type AsObject = {
|
||||
all: boolean,
|
||||
}
|
||||
}
|
||||
|
||||
export class ListResponse extends jspb.Message {
|
||||
clearContainersList(): void;
|
||||
getContainersList(): Array<Container>;
|
||||
setContainersList(value: Array<Container>): ListResponse;
|
||||
addContainers(value?: Container, index?: number): Container;
|
||||
|
||||
|
||||
serializeBinary(): Uint8Array;
|
||||
toObject(includeInstance?: boolean): ListResponse.AsObject;
|
||||
static toObject(includeInstance: boolean, msg: ListResponse): ListResponse.AsObject;
|
||||
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
|
||||
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
|
||||
static serializeBinaryToWriter(message: ListResponse, writer: jspb.BinaryWriter): void;
|
||||
static deserializeBinary(bytes: Uint8Array): ListResponse;
|
||||
static deserializeBinaryFromReader(message: ListResponse, reader: jspb.BinaryReader): ListResponse;
|
||||
}
|
||||
|
||||
export namespace ListResponse {
|
||||
export type AsObject = {
|
||||
containersList: Array<Container.AsObject>,
|
||||
}
|
||||
}
|
||||
|
||||
export class LogsRequest extends jspb.Message {
|
||||
getContainerId(): string;
|
||||
setContainerId(value: string): LogsRequest;
|
||||
|
||||
getFollow(): boolean;
|
||||
setFollow(value: boolean): LogsRequest;
|
||||
|
||||
|
||||
serializeBinary(): Uint8Array;
|
||||
toObject(includeInstance?: boolean): LogsRequest.AsObject;
|
||||
static toObject(includeInstance: boolean, msg: LogsRequest): LogsRequest.AsObject;
|
||||
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
|
||||
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
|
||||
static serializeBinaryToWriter(message: LogsRequest, writer: jspb.BinaryWriter): void;
|
||||
static deserializeBinary(bytes: Uint8Array): LogsRequest;
|
||||
static deserializeBinaryFromReader(message: LogsRequest, reader: jspb.BinaryReader): LogsRequest;
|
||||
}
|
||||
|
||||
export namespace LogsRequest {
|
||||
export type AsObject = {
|
||||
containerId: string,
|
||||
follow: boolean,
|
||||
}
|
||||
}
|
||||
|
||||
export class LogsResponse extends jspb.Message {
|
||||
getValue(): Uint8Array | string;
|
||||
getValue_asU8(): Uint8Array;
|
||||
getValue_asB64(): string;
|
||||
setValue(value: Uint8Array | string): LogsResponse;
|
||||
|
||||
|
||||
serializeBinary(): Uint8Array;
|
||||
toObject(includeInstance?: boolean): LogsResponse.AsObject;
|
||||
static toObject(includeInstance: boolean, msg: LogsResponse): LogsResponse.AsObject;
|
||||
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
|
||||
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
|
||||
static serializeBinaryToWriter(message: LogsResponse, writer: jspb.BinaryWriter): void;
|
||||
static deserializeBinary(bytes: Uint8Array): LogsResponse;
|
||||
static deserializeBinaryFromReader(message: LogsResponse, reader: jspb.BinaryReader): LogsResponse;
|
||||
}
|
||||
|
||||
export namespace LogsResponse {
|
||||
export type AsObject = {
|
||||
value: Uint8Array | string,
|
||||
}
|
||||
}
|
Разница между файлами не показана из-за своего большого размера
Загрузить разницу
Различия файлов скрыты, потому что одна или несколько строк слишком длинны
|
@ -0,0 +1,59 @@
|
|||
/*
|
||||
Copyright (c) 2020 Docker Inc.
|
||||
|
||||
Permission is hereby granted, free of charge, to any person
|
||||
obtaining a copy of this software and associated documentation
|
||||
files (the "Software"), to deal in the Software without
|
||||
restriction, including without limitation the rights to use, copy,
|
||||
modify, merge, publish, distribute, sublicense, and/or sell copies
|
||||
of the Software, and to permit persons to whom the Software is
|
||||
furnished to do so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be
|
||||
included in all copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
EXPRESS OR IMPLIED,
|
||||
INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
||||
IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
|
||||
HOLDERS BE LIABLE FOR ANY CLAIM,
|
||||
DAMAGES OR OTHER LIABILITY,
|
||||
WHETHER IN AN ACTION OF CONTRACT,
|
||||
TORT OR OTHERWISE,
|
||||
ARISING FROM, OUT OF OR IN CONNECTION WITH
|
||||
THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
*/
|
||||
|
||||
syntax = "proto3";
|
||||
|
||||
package com.docker.api.protos.context.v1;
|
||||
|
||||
option go_package = "github.com/docker/api/protos/context/v1;v1";
|
||||
|
||||
service Contexts {
|
||||
// Sets the current request for all calls
|
||||
rpc SetCurrent(SetCurrentRequest) returns (SetCurrentResponse);
|
||||
// Returns the list of existing contexts
|
||||
rpc List(ListRequest) returns (ListResponse);
|
||||
}
|
||||
|
||||
message Context {
|
||||
string name = 1;
|
||||
string contextType = 2;
|
||||
bool current = 3;
|
||||
}
|
||||
|
||||
message SetCurrentRequest {
|
||||
string name = 1;
|
||||
}
|
||||
|
||||
message SetCurrentResponse {
|
||||
}
|
||||
|
||||
message ListRequest {
|
||||
}
|
||||
|
||||
message ListResponse {
|
||||
repeated Context contexts = 1;
|
||||
}
|
|
@ -0,0 +1,59 @@
|
|||
// package: com.docker.api.protos.context.v1
|
||||
// file: contexts/v1/contexts.proto
|
||||
|
||||
/* tslint:disable */
|
||||
/* eslint-disable */
|
||||
|
||||
import * as grpc from "@grpc/grpc-js";
|
||||
import {handleClientStreamingCall} from "@grpc/grpc-js/build/src/server-call";
|
||||
import * as contexts_v1_contexts_pb from "../../contexts/v1/contexts_pb";
|
||||
|
||||
interface IContextsService extends grpc.ServiceDefinition<grpc.UntypedServiceImplementation> {
|
||||
setCurrent: IContextsService_ISetCurrent;
|
||||
list: IContextsService_IList;
|
||||
}
|
||||
|
||||
interface IContextsService_ISetCurrent extends grpc.MethodDefinition<contexts_v1_contexts_pb.SetCurrentRequest, contexts_v1_contexts_pb.SetCurrentResponse> {
|
||||
path: string; // "/com.docker.api.protos.context.v1.Contexts/SetCurrent"
|
||||
requestStream: boolean; // false
|
||||
responseStream: boolean; // false
|
||||
requestSerialize: grpc.serialize<contexts_v1_contexts_pb.SetCurrentRequest>;
|
||||
requestDeserialize: grpc.deserialize<contexts_v1_contexts_pb.SetCurrentRequest>;
|
||||
responseSerialize: grpc.serialize<contexts_v1_contexts_pb.SetCurrentResponse>;
|
||||
responseDeserialize: grpc.deserialize<contexts_v1_contexts_pb.SetCurrentResponse>;
|
||||
}
|
||||
interface IContextsService_IList extends grpc.MethodDefinition<contexts_v1_contexts_pb.ListRequest, contexts_v1_contexts_pb.ListResponse> {
|
||||
path: string; // "/com.docker.api.protos.context.v1.Contexts/List"
|
||||
requestStream: boolean; // false
|
||||
responseStream: boolean; // false
|
||||
requestSerialize: grpc.serialize<contexts_v1_contexts_pb.ListRequest>;
|
||||
requestDeserialize: grpc.deserialize<contexts_v1_contexts_pb.ListRequest>;
|
||||
responseSerialize: grpc.serialize<contexts_v1_contexts_pb.ListResponse>;
|
||||
responseDeserialize: grpc.deserialize<contexts_v1_contexts_pb.ListResponse>;
|
||||
}
|
||||
|
||||
export const ContextsService: IContextsService;
|
||||
|
||||
export interface IContextsServer {
|
||||
setCurrent: grpc.handleUnaryCall<contexts_v1_contexts_pb.SetCurrentRequest, contexts_v1_contexts_pb.SetCurrentResponse>;
|
||||
list: grpc.handleUnaryCall<contexts_v1_contexts_pb.ListRequest, contexts_v1_contexts_pb.ListResponse>;
|
||||
}
|
||||
|
||||
export interface IContextsClient {
|
||||
setCurrent(request: contexts_v1_contexts_pb.SetCurrentRequest, callback: (error: grpc.ServiceError | null, response: contexts_v1_contexts_pb.SetCurrentResponse) => void): grpc.ClientUnaryCall;
|
||||
setCurrent(request: contexts_v1_contexts_pb.SetCurrentRequest, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: contexts_v1_contexts_pb.SetCurrentResponse) => void): grpc.ClientUnaryCall;
|
||||
setCurrent(request: contexts_v1_contexts_pb.SetCurrentRequest, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: contexts_v1_contexts_pb.SetCurrentResponse) => void): grpc.ClientUnaryCall;
|
||||
list(request: contexts_v1_contexts_pb.ListRequest, callback: (error: grpc.ServiceError | null, response: contexts_v1_contexts_pb.ListResponse) => void): grpc.ClientUnaryCall;
|
||||
list(request: contexts_v1_contexts_pb.ListRequest, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: contexts_v1_contexts_pb.ListResponse) => void): grpc.ClientUnaryCall;
|
||||
list(request: contexts_v1_contexts_pb.ListRequest, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: contexts_v1_contexts_pb.ListResponse) => void): grpc.ClientUnaryCall;
|
||||
}
|
||||
|
||||
export class ContextsClient extends grpc.Client implements IContextsClient {
|
||||
constructor(address: string, credentials: grpc.ChannelCredentials, options?: object);
|
||||
public setCurrent(request: contexts_v1_contexts_pb.SetCurrentRequest, callback: (error: grpc.ServiceError | null, response: contexts_v1_contexts_pb.SetCurrentResponse) => void): grpc.ClientUnaryCall;
|
||||
public setCurrent(request: contexts_v1_contexts_pb.SetCurrentRequest, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: contexts_v1_contexts_pb.SetCurrentResponse) => void): grpc.ClientUnaryCall;
|
||||
public setCurrent(request: contexts_v1_contexts_pb.SetCurrentRequest, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: contexts_v1_contexts_pb.SetCurrentResponse) => void): grpc.ClientUnaryCall;
|
||||
public list(request: contexts_v1_contexts_pb.ListRequest, callback: (error: grpc.ServiceError | null, response: contexts_v1_contexts_pb.ListResponse) => void): grpc.ClientUnaryCall;
|
||||
public list(request: contexts_v1_contexts_pb.ListRequest, metadata: grpc.Metadata, callback: (error: grpc.ServiceError | null, response: contexts_v1_contexts_pb.ListResponse) => void): grpc.ClientUnaryCall;
|
||||
public list(request: contexts_v1_contexts_pb.ListRequest, metadata: grpc.Metadata, options: Partial<grpc.CallOptions>, callback: (error: grpc.ServiceError | null, response: contexts_v1_contexts_pb.ListResponse) => void): grpc.ClientUnaryCall;
|
||||
}
|
|
@ -0,0 +1,106 @@
|
|||
// GENERATED CODE -- DO NOT EDIT!
|
||||
|
||||
// Original file comments:
|
||||
//
|
||||
// Copyright (c) 2020 Docker Inc.
|
||||
//
|
||||
// Permission is hereby granted, free of charge, to any person
|
||||
// obtaining a copy of this software and associated documentation
|
||||
// files (the "Software"), to deal in the Software without
|
||||
// restriction, including without limitation the rights to use, copy,
|
||||
// modify, merge, publish, distribute, sublicense, and/or sell copies
|
||||
// of the Software, and to permit persons to whom the Software is
|
||||
// furnished to do so, subject to the following conditions:
|
||||
//
|
||||
// The above copyright notice and this permission notice shall be
|
||||
// included in all copies or substantial portions of the Software.
|
||||
//
|
||||
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
// EXPRESS OR IMPLIED,
|
||||
// INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
||||
// IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
|
||||
// HOLDERS BE LIABLE FOR ANY CLAIM,
|
||||
// DAMAGES OR OTHER LIABILITY,
|
||||
// WHETHER IN AN ACTION OF CONTRACT,
|
||||
// TORT OR OTHERWISE,
|
||||
// ARISING FROM, OUT OF OR IN CONNECTION WITH
|
||||
// THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
//
|
||||
'use strict';
|
||||
var grpc = require('@grpc/grpc-js');
|
||||
var contexts_v1_contexts_pb = require('../../contexts/v1/contexts_pb.js');
|
||||
|
||||
function serialize_com_docker_api_protos_context_v1_ListRequest(arg) {
|
||||
if (!(arg instanceof contexts_v1_contexts_pb.ListRequest)) {
|
||||
throw new Error('Expected argument of type com.docker.api.protos.context.v1.ListRequest');
|
||||
}
|
||||
return Buffer.from(arg.serializeBinary());
|
||||
}
|
||||
|
||||
function deserialize_com_docker_api_protos_context_v1_ListRequest(buffer_arg) {
|
||||
return contexts_v1_contexts_pb.ListRequest.deserializeBinary(new Uint8Array(buffer_arg));
|
||||
}
|
||||
|
||||
function serialize_com_docker_api_protos_context_v1_ListResponse(arg) {
|
||||
if (!(arg instanceof contexts_v1_contexts_pb.ListResponse)) {
|
||||
throw new Error('Expected argument of type com.docker.api.protos.context.v1.ListResponse');
|
||||
}
|
||||
return Buffer.from(arg.serializeBinary());
|
||||
}
|
||||
|
||||
function deserialize_com_docker_api_protos_context_v1_ListResponse(buffer_arg) {
|
||||
return contexts_v1_contexts_pb.ListResponse.deserializeBinary(new Uint8Array(buffer_arg));
|
||||
}
|
||||
|
||||
function serialize_com_docker_api_protos_context_v1_SetCurrentRequest(arg) {
|
||||
if (!(arg instanceof contexts_v1_contexts_pb.SetCurrentRequest)) {
|
||||
throw new Error('Expected argument of type com.docker.api.protos.context.v1.SetCurrentRequest');
|
||||
}
|
||||
return Buffer.from(arg.serializeBinary());
|
||||
}
|
||||
|
||||
function deserialize_com_docker_api_protos_context_v1_SetCurrentRequest(buffer_arg) {
|
||||
return contexts_v1_contexts_pb.SetCurrentRequest.deserializeBinary(new Uint8Array(buffer_arg));
|
||||
}
|
||||
|
||||
function serialize_com_docker_api_protos_context_v1_SetCurrentResponse(arg) {
|
||||
if (!(arg instanceof contexts_v1_contexts_pb.SetCurrentResponse)) {
|
||||
throw new Error('Expected argument of type com.docker.api.protos.context.v1.SetCurrentResponse');
|
||||
}
|
||||
return Buffer.from(arg.serializeBinary());
|
||||
}
|
||||
|
||||
function deserialize_com_docker_api_protos_context_v1_SetCurrentResponse(buffer_arg) {
|
||||
return contexts_v1_contexts_pb.SetCurrentResponse.deserializeBinary(new Uint8Array(buffer_arg));
|
||||
}
|
||||
|
||||
|
||||
var ContextsService = exports.ContextsService = {
|
||||
// Sets the current request for all calls
|
||||
setCurrent: {
|
||||
path: '/com.docker.api.protos.context.v1.Contexts/SetCurrent',
|
||||
requestStream: false,
|
||||
responseStream: false,
|
||||
requestType: contexts_v1_contexts_pb.SetCurrentRequest,
|
||||
responseType: contexts_v1_contexts_pb.SetCurrentResponse,
|
||||
requestSerialize: serialize_com_docker_api_protos_context_v1_SetCurrentRequest,
|
||||
requestDeserialize: deserialize_com_docker_api_protos_context_v1_SetCurrentRequest,
|
||||
responseSerialize: serialize_com_docker_api_protos_context_v1_SetCurrentResponse,
|
||||
responseDeserialize: deserialize_com_docker_api_protos_context_v1_SetCurrentResponse,
|
||||
},
|
||||
// Returns the list of existing contexts
|
||||
list: {
|
||||
path: '/com.docker.api.protos.context.v1.Contexts/List',
|
||||
requestStream: false,
|
||||
responseStream: false,
|
||||
requestType: contexts_v1_contexts_pb.ListRequest,
|
||||
responseType: contexts_v1_contexts_pb.ListResponse,
|
||||
requestSerialize: serialize_com_docker_api_protos_context_v1_ListRequest,
|
||||
requestDeserialize: deserialize_com_docker_api_protos_context_v1_ListRequest,
|
||||
responseSerialize: serialize_com_docker_api_protos_context_v1_ListResponse,
|
||||
responseDeserialize: deserialize_com_docker_api_protos_context_v1_ListResponse,
|
||||
},
|
||||
};
|
||||
|
||||
exports.ContextsClient = grpc.makeGenericClientConstructor(ContextsService);
|
|
@ -0,0 +1 @@
|
|||
{"version":3,"file":"contexts_grpc_pb.js","sourceRoot":"","sources":["../../../../src/protos/contexts/v1/contexts_grpc_pb.js"],"names":[],"mappings":"AAAA,iCAAiC;AAEjC,0BAA0B;AAC1B,EAAE;AACF,iCAAiC;AACjC,EAAE;AACF,8DAA8D;AAC9D,iEAAiE;AACjE,0DAA0D;AAC1D,qEAAqE;AACrE,qEAAqE;AACrE,iEAAiE;AACjE,2DAA2D;AAC3D,EAAE;AACF,iEAAiE;AACjE,kEAAkE;AAClE,EAAE;AACF,kEAAkE;AAClE,sBAAsB;AACtB,kEAAkE;AAClE,wDAAwD;AACxD,6CAA6C;AAC7C,mCAAmC;AACnC,8BAA8B;AAC9B,oCAAoC;AACpC,qBAAqB;AACrB,6CAA6C;AAC7C,6DAA6D;AAC7D,EAAE;AACF,YAAY,CAAC;AACb,IAAI,IAAI,GAAG,OAAO,CAAC,eAAe,CAAC,CAAC;AACpC,IAAI,uBAAuB,GAAG,OAAO,CAAC,kCAAkC,CAAC,CAAC;AAE1E,SAAS,sDAAsD,CAAC,GAAG;IACjE,IAAI,CAAC,CAAC,GAAG,YAAY,uBAAuB,CAAC,WAAW,CAAC,EAAE;QACzD,MAAM,IAAI,KAAK,CAAC,wEAAwE,CAAC,CAAC;KAC3F;IACD,OAAO,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,eAAe,EAAE,CAAC,CAAC;AAC5C,CAAC;AAED,SAAS,wDAAwD,CAAC,UAAU;IAC1E,OAAO,uBAAuB,CAAC,WAAW,CAAC,iBAAiB,CAAC,IAAI,UAAU,CAAC,UAAU,CAAC,CAAC,CAAC;AAC3F,CAAC;AAED,SAAS,uDAAuD,CAAC,GAAG;IAClE,IAAI,CAAC,CAAC,GAAG,YAAY,uBAAuB,CAAC,YAAY,CAAC,EAAE;QAC1D,MAAM,IAAI,KAAK,CAAC,yEAAyE,CAAC,CAAC;KAC5F;IACD,OAAO,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,eAAe,EAAE,CAAC,CAAC;AAC5C,CAAC;AAED,SAAS,yDAAyD,CAAC,UAAU;IAC3E,OAAO,uBAAuB,CAAC,YAAY,CAAC,iBAAiB,CAAC,IAAI,UAAU,CAAC,UAAU,CAAC,CAAC,CAAC;AAC5F,CAAC;AAED,SAAS,4DAA4D,CAAC,GAAG;IACvE,IAAI,CAAC,CAAC,GAAG,YAAY,uBAAuB,CAAC,iBAAiB,CAAC,EAAE;QAC/D,MAAM,IAAI,KAAK,CAAC,8EAA8E,CAAC,CAAC;KACjG;IACD,OAAO,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,eAAe,EAAE,CAAC,CAAC;AAC5C,CAAC;AAED,SAAS,8DAA8D,CAAC,UAAU;IAChF,OAAO,uBAAuB,CAAC,iBAAiB,CAAC,iBAAiB,CAAC,IAAI,UAAU,CAAC,UAAU,CAAC,CAAC,CAAC;AACjG,CAAC;AAED,SAAS,6DAA6D,CAAC,GAAG;IACxE,IAAI,CAAC,CAAC,GAAG,YAAY,uBAAuB,CAAC,kBAAkB,CAAC,EAAE;QAChE,MAAM,IAAI,KAAK,CAAC,+EAA+E,CAAC,CAAC;KAClG;IACD,OAAO,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,eAAe,EAAE,CAAC,CAAC;AAC5C,CAAC;AAED,SAAS,+DAA+D,CAAC,UAAU;IACjF,OAAO,uBAAuB,CAAC,kBAAkB,CAAC,iBAAiB,CAAC,IAAI,UAAU,CAAC,UAAU,CAAC,CAAC,CAAC;AAClG,CAAC;AAGD,IAAI,eAAe,GAAG,OAAO,CAAC,eAAe,GAAG;IAC9C,yCAAyC;IAC3C,UAAU,EAAE;QACR,IAAI,EAAE,uDAAuD;QAC7D,aAAa,EAAE,KAAK;QACpB,cAAc,EAAE,KAAK;QACrB,WAAW,EAAE,uBAAuB,CAAC,iBAAiB;QACtD,YAAY,EAAE,uBAAuB,CAAC,kBAAkB;QACxD,gBAAgB,EAAE,4DAA4D;QAC9E,kBAAkB,EAAE,8DAA8D;QAClF,iBAAiB,EAAE,6DAA6D;QAChF,mBAAmB,EAAE,+DAA+D;KACrF;IACD,wCAAwC;IAC1C,IAAI,EAAE;QACF,IAAI,EAAE,iDAAiD;QACvD,aAAa,EAAE,KAAK;QACpB,cAAc,EAAE,KAAK;QACrB,WAAW,EAAE,uBAAuB,CAAC,WAAW;QAChD,YAAY,EAAE,uBAAuB,CAAC,YAAY;QAClD,gBAAgB,EAAE,sDAAsD;QACxE,kBAAkB,EAAE,wDAAwD;QAC5E,iBAAiB,EAAE,uDAAuD;QAC1E,mBAAmB,EAAE,yDAAyD;KAC/E;CACF,CAAC;AAEF,OAAO,CAAC,cAAc,GAAG,IAAI,CAAC,4BAA4B,CAAC,eAAe,CAAC,CAAC"}
|
|
@ -0,0 +1,114 @@
|
|||
// package: com.docker.api.protos.context.v1
|
||||
// file: contexts/v1/contexts.proto
|
||||
|
||||
/* tslint:disable */
|
||||
/* eslint-disable */
|
||||
|
||||
import * as jspb from "google-protobuf";
|
||||
|
||||
export class Context extends jspb.Message {
|
||||
getName(): string;
|
||||
setName(value: string): Context;
|
||||
|
||||
getContexttype(): string;
|
||||
setContexttype(value: string): Context;
|
||||
|
||||
getCurrent(): boolean;
|
||||
setCurrent(value: boolean): Context;
|
||||
|
||||
|
||||
serializeBinary(): Uint8Array;
|
||||
toObject(includeInstance?: boolean): Context.AsObject;
|
||||
static toObject(includeInstance: boolean, msg: Context): Context.AsObject;
|
||||
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
|
||||
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
|
||||
static serializeBinaryToWriter(message: Context, writer: jspb.BinaryWriter): void;
|
||||
static deserializeBinary(bytes: Uint8Array): Context;
|
||||
static deserializeBinaryFromReader(message: Context, reader: jspb.BinaryReader): Context;
|
||||
}
|
||||
|
||||
export namespace Context {
|
||||
export type AsObject = {
|
||||
name: string,
|
||||
contexttype: string,
|
||||
current: boolean,
|
||||
}
|
||||
}
|
||||
|
||||
export class SetCurrentRequest extends jspb.Message {
|
||||
getName(): string;
|
||||
setName(value: string): SetCurrentRequest;
|
||||
|
||||
|
||||
serializeBinary(): Uint8Array;
|
||||
toObject(includeInstance?: boolean): SetCurrentRequest.AsObject;
|
||||
static toObject(includeInstance: boolean, msg: SetCurrentRequest): SetCurrentRequest.AsObject;
|
||||
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
|
||||
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
|
||||
static serializeBinaryToWriter(message: SetCurrentRequest, writer: jspb.BinaryWriter): void;
|
||||
static deserializeBinary(bytes: Uint8Array): SetCurrentRequest;
|
||||
static deserializeBinaryFromReader(message: SetCurrentRequest, reader: jspb.BinaryReader): SetCurrentRequest;
|
||||
}
|
||||
|
||||
export namespace SetCurrentRequest {
|
||||
export type AsObject = {
|
||||
name: string,
|
||||
}
|
||||
}
|
||||
|
||||
export class SetCurrentResponse extends jspb.Message {
|
||||
|
||||
serializeBinary(): Uint8Array;
|
||||
toObject(includeInstance?: boolean): SetCurrentResponse.AsObject;
|
||||
static toObject(includeInstance: boolean, msg: SetCurrentResponse): SetCurrentResponse.AsObject;
|
||||
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
|
||||
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
|
||||
static serializeBinaryToWriter(message: SetCurrentResponse, writer: jspb.BinaryWriter): void;
|
||||
static deserializeBinary(bytes: Uint8Array): SetCurrentResponse;
|
||||
static deserializeBinaryFromReader(message: SetCurrentResponse, reader: jspb.BinaryReader): SetCurrentResponse;
|
||||
}
|
||||
|
||||
export namespace SetCurrentResponse {
|
||||
export type AsObject = {
|
||||
}
|
||||
}
|
||||
|
||||
export class ListRequest extends jspb.Message {
|
||||
|
||||
serializeBinary(): Uint8Array;
|
||||
toObject(includeInstance?: boolean): ListRequest.AsObject;
|
||||
static toObject(includeInstance: boolean, msg: ListRequest): ListRequest.AsObject;
|
||||
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
|
||||
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
|
||||
static serializeBinaryToWriter(message: ListRequest, writer: jspb.BinaryWriter): void;
|
||||
static deserializeBinary(bytes: Uint8Array): ListRequest;
|
||||
static deserializeBinaryFromReader(message: ListRequest, reader: jspb.BinaryReader): ListRequest;
|
||||
}
|
||||
|
||||
export namespace ListRequest {
|
||||
export type AsObject = {
|
||||
}
|
||||
}
|
||||
|
||||
export class ListResponse extends jspb.Message {
|
||||
clearContextsList(): void;
|
||||
getContextsList(): Array<Context>;
|
||||
setContextsList(value: Array<Context>): ListResponse;
|
||||
addContexts(value?: Context, index?: number): Context;
|
||||
|
||||
|
||||
serializeBinary(): Uint8Array;
|
||||
toObject(includeInstance?: boolean): ListResponse.AsObject;
|
||||
static toObject(includeInstance: boolean, msg: ListResponse): ListResponse.AsObject;
|
||||
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
|
||||
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
|
||||
static serializeBinaryToWriter(message: ListResponse, writer: jspb.BinaryWriter): void;
|
||||
static deserializeBinary(bytes: Uint8Array): ListResponse;
|
||||
static deserializeBinaryFromReader(message: ListResponse, reader: jspb.BinaryReader): ListResponse;
|
||||
}
|
||||
|
||||
export namespace ListResponse {
|
||||
export type AsObject = {
|
||||
contextsList: Array<Context.AsObject>,
|
||||
}
|
||||
}
|
|
@ -0,0 +1,807 @@
|
|||
// source: contexts/v1/contexts.proto
|
||||
/**
|
||||
* @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')();
|
||||
|
||||
goog.exportSymbol('proto.com.docker.api.protos.context.v1.Context', null, global);
|
||||
goog.exportSymbol('proto.com.docker.api.protos.context.v1.ListRequest', null, global);
|
||||
goog.exportSymbol('proto.com.docker.api.protos.context.v1.ListResponse', null, global);
|
||||
goog.exportSymbol('proto.com.docker.api.protos.context.v1.SetCurrentRequest', null, global);
|
||||
goog.exportSymbol('proto.com.docker.api.protos.context.v1.SetCurrentResponse', 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.com.docker.api.protos.context.v1.Context = function(opt_data) {
|
||||
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
|
||||
};
|
||||
goog.inherits(proto.com.docker.api.protos.context.v1.Context, jspb.Message);
|
||||
if (goog.DEBUG && !COMPILED) {
|
||||
/**
|
||||
* @public
|
||||
* @override
|
||||
*/
|
||||
proto.com.docker.api.protos.context.v1.Context.displayName = 'proto.com.docker.api.protos.context.v1.Context';
|
||||
}
|
||||
/**
|
||||
* 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.com.docker.api.protos.context.v1.SetCurrentRequest = function(opt_data) {
|
||||
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
|
||||
};
|
||||
goog.inherits(proto.com.docker.api.protos.context.v1.SetCurrentRequest, jspb.Message);
|
||||
if (goog.DEBUG && !COMPILED) {
|
||||
/**
|
||||
* @public
|
||||
* @override
|
||||
*/
|
||||
proto.com.docker.api.protos.context.v1.SetCurrentRequest.displayName = 'proto.com.docker.api.protos.context.v1.SetCurrentRequest';
|
||||
}
|
||||
/**
|
||||
* 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.com.docker.api.protos.context.v1.SetCurrentResponse = function(opt_data) {
|
||||
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
|
||||
};
|
||||
goog.inherits(proto.com.docker.api.protos.context.v1.SetCurrentResponse, jspb.Message);
|
||||
if (goog.DEBUG && !COMPILED) {
|
||||
/**
|
||||
* @public
|
||||
* @override
|
||||
*/
|
||||
proto.com.docker.api.protos.context.v1.SetCurrentResponse.displayName = 'proto.com.docker.api.protos.context.v1.SetCurrentResponse';
|
||||
}
|
||||
/**
|
||||
* 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.com.docker.api.protos.context.v1.ListRequest = function(opt_data) {
|
||||
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
|
||||
};
|
||||
goog.inherits(proto.com.docker.api.protos.context.v1.ListRequest, jspb.Message);
|
||||
if (goog.DEBUG && !COMPILED) {
|
||||
/**
|
||||
* @public
|
||||
* @override
|
||||
*/
|
||||
proto.com.docker.api.protos.context.v1.ListRequest.displayName = 'proto.com.docker.api.protos.context.v1.ListRequest';
|
||||
}
|
||||
/**
|
||||
* 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.com.docker.api.protos.context.v1.ListResponse = function(opt_data) {
|
||||
jspb.Message.initialize(this, opt_data, 0, -1, proto.com.docker.api.protos.context.v1.ListResponse.repeatedFields_, null);
|
||||
};
|
||||
goog.inherits(proto.com.docker.api.protos.context.v1.ListResponse, jspb.Message);
|
||||
if (goog.DEBUG && !COMPILED) {
|
||||
/**
|
||||
* @public
|
||||
* @override
|
||||
*/
|
||||
proto.com.docker.api.protos.context.v1.ListResponse.displayName = 'proto.com.docker.api.protos.context.v1.ListResponse';
|
||||
}
|
||||
|
||||
|
||||
|
||||
if (jspb.Message.GENERATE_TO_OBJECT) {
|
||||
/**
|
||||
* Creates an object representation of this proto.
|
||||
* Field names that are reserved in JavaScript and will be renamed to pb_name.
|
||||
* Optional fields that are not set will be set to undefined.
|
||||
* To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
|
||||
* For the list of reserved names please see:
|
||||
* net/proto2/compiler/js/internal/generator.cc#kKeyword.
|
||||
* @param {boolean=} opt_includeInstance Deprecated. whether to include the
|
||||
* JSPB instance for transitional soy proto support:
|
||||
* http://goto/soy-param-migration
|
||||
* @return {!Object}
|
||||
*/
|
||||
proto.com.docker.api.protos.context.v1.Context.prototype.toObject = function(opt_includeInstance) {
|
||||
return proto.com.docker.api.protos.context.v1.Context.toObject(opt_includeInstance, this);
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Static version of the {@see toObject} method.
|
||||
* @param {boolean|undefined} includeInstance Deprecated. Whether to include
|
||||
* the JSPB instance for transitional soy proto support:
|
||||
* http://goto/soy-param-migration
|
||||
* @param {!proto.com.docker.api.protos.context.v1.Context} msg The msg instance to transform.
|
||||
* @return {!Object}
|
||||
* @suppress {unusedLocalVariables} f is only used for nested messages
|
||||
*/
|
||||
proto.com.docker.api.protos.context.v1.Context.toObject = function(includeInstance, msg) {
|
||||
var f, obj = {
|
||||
name: jspb.Message.getFieldWithDefault(msg, 1, ""),
|
||||
contexttype: jspb.Message.getFieldWithDefault(msg, 2, ""),
|
||||
current: jspb.Message.getBooleanFieldWithDefault(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.com.docker.api.protos.context.v1.Context}
|
||||
*/
|
||||
proto.com.docker.api.protos.context.v1.Context.deserializeBinary = function(bytes) {
|
||||
var reader = new jspb.BinaryReader(bytes);
|
||||
var msg = new proto.com.docker.api.protos.context.v1.Context;
|
||||
return proto.com.docker.api.protos.context.v1.Context.deserializeBinaryFromReader(msg, reader);
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Deserializes binary data (in protobuf wire format) from the
|
||||
* given reader into the given message object.
|
||||
* @param {!proto.com.docker.api.protos.context.v1.Context} msg The message object to deserialize into.
|
||||
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
|
||||
* @return {!proto.com.docker.api.protos.context.v1.Context}
|
||||
*/
|
||||
proto.com.docker.api.protos.context.v1.Context.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.setContexttype(value);
|
||||
break;
|
||||
case 3:
|
||||
var value = /** @type {boolean} */ (reader.readBool());
|
||||
msg.setCurrent(value);
|
||||
break;
|
||||
default:
|
||||
reader.skipField();
|
||||
break;
|
||||
}
|
||||
}
|
||||
return msg;
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Serializes the message to binary data (in protobuf wire format).
|
||||
* @return {!Uint8Array}
|
||||
*/
|
||||
proto.com.docker.api.protos.context.v1.Context.prototype.serializeBinary = function() {
|
||||
var writer = new jspb.BinaryWriter();
|
||||
proto.com.docker.api.protos.context.v1.Context.serializeBinaryToWriter(this, writer);
|
||||
return writer.getResultBuffer();
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Serializes the given message to binary data (in protobuf wire
|
||||
* format), writing to the given BinaryWriter.
|
||||
* @param {!proto.com.docker.api.protos.context.v1.Context} message
|
||||
* @param {!jspb.BinaryWriter} writer
|
||||
* @suppress {unusedLocalVariables} f is only used for nested messages
|
||||
*/
|
||||
proto.com.docker.api.protos.context.v1.Context.serializeBinaryToWriter = function(message, writer) {
|
||||
var f = undefined;
|
||||
f = message.getName();
|
||||
if (f.length > 0) {
|
||||
writer.writeString(
|
||||
1,
|
||||
f
|
||||
);
|
||||
}
|
||||
f = message.getContexttype();
|
||||
if (f.length > 0) {
|
||||
writer.writeString(
|
||||
2,
|
||||
f
|
||||
);
|
||||
}
|
||||
f = message.getCurrent();
|
||||
if (f) {
|
||||
writer.writeBool(
|
||||
3,
|
||||
f
|
||||
);
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* optional string name = 1;
|
||||
* @return {string}
|
||||
*/
|
||||
proto.com.docker.api.protos.context.v1.Context.prototype.getName = function() {
|
||||
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* @param {string} value
|
||||
* @return {!proto.com.docker.api.protos.context.v1.Context} returns this
|
||||
*/
|
||||
proto.com.docker.api.protos.context.v1.Context.prototype.setName = function(value) {
|
||||
return jspb.Message.setProto3StringField(this, 1, value);
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* optional string contextType = 2;
|
||||
* @return {string}
|
||||
*/
|
||||
proto.com.docker.api.protos.context.v1.Context.prototype.getContexttype = function() {
|
||||
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* @param {string} value
|
||||
* @return {!proto.com.docker.api.protos.context.v1.Context} returns this
|
||||
*/
|
||||
proto.com.docker.api.protos.context.v1.Context.prototype.setContexttype = function(value) {
|
||||
return jspb.Message.setProto3StringField(this, 2, value);
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* optional bool current = 3;
|
||||
* @return {boolean}
|
||||
*/
|
||||
proto.com.docker.api.protos.context.v1.Context.prototype.getCurrent = function() {
|
||||
return /** @type {boolean} */ (jspb.Message.getBooleanFieldWithDefault(this, 3, false));
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* @param {boolean} value
|
||||
* @return {!proto.com.docker.api.protos.context.v1.Context} returns this
|
||||
*/
|
||||
proto.com.docker.api.protos.context.v1.Context.prototype.setCurrent = function(value) {
|
||||
return jspb.Message.setProto3BooleanField(this, 3, value);
|
||||
};
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
if (jspb.Message.GENERATE_TO_OBJECT) {
|
||||
/**
|
||||
* Creates an object representation of this proto.
|
||||
* Field names that are reserved in JavaScript and will be renamed to pb_name.
|
||||
* Optional fields that are not set will be set to undefined.
|
||||
* To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
|
||||
* For the list of reserved names please see:
|
||||
* net/proto2/compiler/js/internal/generator.cc#kKeyword.
|
||||
* @param {boolean=} opt_includeInstance Deprecated. whether to include the
|
||||
* JSPB instance for transitional soy proto support:
|
||||
* http://goto/soy-param-migration
|
||||
* @return {!Object}
|
||||
*/
|
||||
proto.com.docker.api.protos.context.v1.SetCurrentRequest.prototype.toObject = function(opt_includeInstance) {
|
||||
return proto.com.docker.api.protos.context.v1.SetCurrentRequest.toObject(opt_includeInstance, this);
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Static version of the {@see toObject} method.
|
||||
* @param {boolean|undefined} includeInstance Deprecated. Whether to include
|
||||
* the JSPB instance for transitional soy proto support:
|
||||
* http://goto/soy-param-migration
|
||||
* @param {!proto.com.docker.api.protos.context.v1.SetCurrentRequest} msg The msg instance to transform.
|
||||
* @return {!Object}
|
||||
* @suppress {unusedLocalVariables} f is only used for nested messages
|
||||
*/
|
||||
proto.com.docker.api.protos.context.v1.SetCurrentRequest.toObject = function(includeInstance, msg) {
|
||||
var f, obj = {
|
||||
name: jspb.Message.getFieldWithDefault(msg, 1, "")
|
||||
};
|
||||
|
||||
if (includeInstance) {
|
||||
obj.$jspbMessageInstance = msg;
|
||||
}
|
||||
return obj;
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Deserializes binary data (in protobuf wire format).
|
||||
* @param {jspb.ByteSource} bytes The bytes to deserialize.
|
||||
* @return {!proto.com.docker.api.protos.context.v1.SetCurrentRequest}
|
||||
*/
|
||||
proto.com.docker.api.protos.context.v1.SetCurrentRequest.deserializeBinary = function(bytes) {
|
||||
var reader = new jspb.BinaryReader(bytes);
|
||||
var msg = new proto.com.docker.api.protos.context.v1.SetCurrentRequest;
|
||||
return proto.com.docker.api.protos.context.v1.SetCurrentRequest.deserializeBinaryFromReader(msg, reader);
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Deserializes binary data (in protobuf wire format) from the
|
||||
* given reader into the given message object.
|
||||
* @param {!proto.com.docker.api.protos.context.v1.SetCurrentRequest} msg The message object to deserialize into.
|
||||
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
|
||||
* @return {!proto.com.docker.api.protos.context.v1.SetCurrentRequest}
|
||||
*/
|
||||
proto.com.docker.api.protos.context.v1.SetCurrentRequest.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;
|
||||
default:
|
||||
reader.skipField();
|
||||
break;
|
||||
}
|
||||
}
|
||||
return msg;
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Serializes the message to binary data (in protobuf wire format).
|
||||
* @return {!Uint8Array}
|
||||
*/
|
||||
proto.com.docker.api.protos.context.v1.SetCurrentRequest.prototype.serializeBinary = function() {
|
||||
var writer = new jspb.BinaryWriter();
|
||||
proto.com.docker.api.protos.context.v1.SetCurrentRequest.serializeBinaryToWriter(this, writer);
|
||||
return writer.getResultBuffer();
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Serializes the given message to binary data (in protobuf wire
|
||||
* format), writing to the given BinaryWriter.
|
||||
* @param {!proto.com.docker.api.protos.context.v1.SetCurrentRequest} message
|
||||
* @param {!jspb.BinaryWriter} writer
|
||||
* @suppress {unusedLocalVariables} f is only used for nested messages
|
||||
*/
|
||||
proto.com.docker.api.protos.context.v1.SetCurrentRequest.serializeBinaryToWriter = function(message, writer) {
|
||||
var f = undefined;
|
||||
f = message.getName();
|
||||
if (f.length > 0) {
|
||||
writer.writeString(
|
||||
1,
|
||||
f
|
||||
);
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* optional string name = 1;
|
||||
* @return {string}
|
||||
*/
|
||||
proto.com.docker.api.protos.context.v1.SetCurrentRequest.prototype.getName = function() {
|
||||
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* @param {string} value
|
||||
* @return {!proto.com.docker.api.protos.context.v1.SetCurrentRequest} returns this
|
||||
*/
|
||||
proto.com.docker.api.protos.context.v1.SetCurrentRequest.prototype.setName = function(value) {
|
||||
return jspb.Message.setProto3StringField(this, 1, value);
|
||||
};
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
if (jspb.Message.GENERATE_TO_OBJECT) {
|
||||
/**
|
||||
* Creates an object representation of this proto.
|
||||
* Field names that are reserved in JavaScript and will be renamed to pb_name.
|
||||
* Optional fields that are not set will be set to undefined.
|
||||
* To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
|
||||
* For the list of reserved names please see:
|
||||
* net/proto2/compiler/js/internal/generator.cc#kKeyword.
|
||||
* @param {boolean=} opt_includeInstance Deprecated. whether to include the
|
||||
* JSPB instance for transitional soy proto support:
|
||||
* http://goto/soy-param-migration
|
||||
* @return {!Object}
|
||||
*/
|
||||
proto.com.docker.api.protos.context.v1.SetCurrentResponse.prototype.toObject = function(opt_includeInstance) {
|
||||
return proto.com.docker.api.protos.context.v1.SetCurrentResponse.toObject(opt_includeInstance, this);
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Static version of the {@see toObject} method.
|
||||
* @param {boolean|undefined} includeInstance Deprecated. Whether to include
|
||||
* the JSPB instance for transitional soy proto support:
|
||||
* http://goto/soy-param-migration
|
||||
* @param {!proto.com.docker.api.protos.context.v1.SetCurrentResponse} msg The msg instance to transform.
|
||||
* @return {!Object}
|
||||
* @suppress {unusedLocalVariables} f is only used for nested messages
|
||||
*/
|
||||
proto.com.docker.api.protos.context.v1.SetCurrentResponse.toObject = function(includeInstance, msg) {
|
||||
var f, obj = {
|
||||
|
||||
};
|
||||
|
||||
if (includeInstance) {
|
||||
obj.$jspbMessageInstance = msg;
|
||||
}
|
||||
return obj;
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Deserializes binary data (in protobuf wire format).
|
||||
* @param {jspb.ByteSource} bytes The bytes to deserialize.
|
||||
* @return {!proto.com.docker.api.protos.context.v1.SetCurrentResponse}
|
||||
*/
|
||||
proto.com.docker.api.protos.context.v1.SetCurrentResponse.deserializeBinary = function(bytes) {
|
||||
var reader = new jspb.BinaryReader(bytes);
|
||||
var msg = new proto.com.docker.api.protos.context.v1.SetCurrentResponse;
|
||||
return proto.com.docker.api.protos.context.v1.SetCurrentResponse.deserializeBinaryFromReader(msg, reader);
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Deserializes binary data (in protobuf wire format) from the
|
||||
* given reader into the given message object.
|
||||
* @param {!proto.com.docker.api.protos.context.v1.SetCurrentResponse} msg The message object to deserialize into.
|
||||
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
|
||||
* @return {!proto.com.docker.api.protos.context.v1.SetCurrentResponse}
|
||||
*/
|
||||
proto.com.docker.api.protos.context.v1.SetCurrentResponse.deserializeBinaryFromReader = function(msg, reader) {
|
||||
while (reader.nextField()) {
|
||||
if (reader.isEndGroup()) {
|
||||
break;
|
||||
}
|
||||
var field = reader.getFieldNumber();
|
||||
switch (field) {
|
||||
default:
|
||||
reader.skipField();
|
||||
break;
|
||||
}
|
||||
}
|
||||
return msg;
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Serializes the message to binary data (in protobuf wire format).
|
||||
* @return {!Uint8Array}
|
||||
*/
|
||||
proto.com.docker.api.protos.context.v1.SetCurrentResponse.prototype.serializeBinary = function() {
|
||||
var writer = new jspb.BinaryWriter();
|
||||
proto.com.docker.api.protos.context.v1.SetCurrentResponse.serializeBinaryToWriter(this, writer);
|
||||
return writer.getResultBuffer();
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Serializes the given message to binary data (in protobuf wire
|
||||
* format), writing to the given BinaryWriter.
|
||||
* @param {!proto.com.docker.api.protos.context.v1.SetCurrentResponse} message
|
||||
* @param {!jspb.BinaryWriter} writer
|
||||
* @suppress {unusedLocalVariables} f is only used for nested messages
|
||||
*/
|
||||
proto.com.docker.api.protos.context.v1.SetCurrentResponse.serializeBinaryToWriter = function(message, writer) {
|
||||
var f = undefined;
|
||||
};
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
if (jspb.Message.GENERATE_TO_OBJECT) {
|
||||
/**
|
||||
* Creates an object representation of this proto.
|
||||
* Field names that are reserved in JavaScript and will be renamed to pb_name.
|
||||
* Optional fields that are not set will be set to undefined.
|
||||
* To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
|
||||
* For the list of reserved names please see:
|
||||
* net/proto2/compiler/js/internal/generator.cc#kKeyword.
|
||||
* @param {boolean=} opt_includeInstance Deprecated. whether to include the
|
||||
* JSPB instance for transitional soy proto support:
|
||||
* http://goto/soy-param-migration
|
||||
* @return {!Object}
|
||||
*/
|
||||
proto.com.docker.api.protos.context.v1.ListRequest.prototype.toObject = function(opt_includeInstance) {
|
||||
return proto.com.docker.api.protos.context.v1.ListRequest.toObject(opt_includeInstance, this);
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Static version of the {@see toObject} method.
|
||||
* @param {boolean|undefined} includeInstance Deprecated. Whether to include
|
||||
* the JSPB instance for transitional soy proto support:
|
||||
* http://goto/soy-param-migration
|
||||
* @param {!proto.com.docker.api.protos.context.v1.ListRequest} msg The msg instance to transform.
|
||||
* @return {!Object}
|
||||
* @suppress {unusedLocalVariables} f is only used for nested messages
|
||||
*/
|
||||
proto.com.docker.api.protos.context.v1.ListRequest.toObject = function(includeInstance, msg) {
|
||||
var f, obj = {
|
||||
|
||||
};
|
||||
|
||||
if (includeInstance) {
|
||||
obj.$jspbMessageInstance = msg;
|
||||
}
|
||||
return obj;
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Deserializes binary data (in protobuf wire format).
|
||||
* @param {jspb.ByteSource} bytes The bytes to deserialize.
|
||||
* @return {!proto.com.docker.api.protos.context.v1.ListRequest}
|
||||
*/
|
||||
proto.com.docker.api.protos.context.v1.ListRequest.deserializeBinary = function(bytes) {
|
||||
var reader = new jspb.BinaryReader(bytes);
|
||||
var msg = new proto.com.docker.api.protos.context.v1.ListRequest;
|
||||
return proto.com.docker.api.protos.context.v1.ListRequest.deserializeBinaryFromReader(msg, reader);
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Deserializes binary data (in protobuf wire format) from the
|
||||
* given reader into the given message object.
|
||||
* @param {!proto.com.docker.api.protos.context.v1.ListRequest} msg The message object to deserialize into.
|
||||
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
|
||||
* @return {!proto.com.docker.api.protos.context.v1.ListRequest}
|
||||
*/
|
||||
proto.com.docker.api.protos.context.v1.ListRequest.deserializeBinaryFromReader = function(msg, reader) {
|
||||
while (reader.nextField()) {
|
||||
if (reader.isEndGroup()) {
|
||||
break;
|
||||
}
|
||||
var field = reader.getFieldNumber();
|
||||
switch (field) {
|
||||
default:
|
||||
reader.skipField();
|
||||
break;
|
||||
}
|
||||
}
|
||||
return msg;
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Serializes the message to binary data (in protobuf wire format).
|
||||
* @return {!Uint8Array}
|
||||
*/
|
||||
proto.com.docker.api.protos.context.v1.ListRequest.prototype.serializeBinary = function() {
|
||||
var writer = new jspb.BinaryWriter();
|
||||
proto.com.docker.api.protos.context.v1.ListRequest.serializeBinaryToWriter(this, writer);
|
||||
return writer.getResultBuffer();
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Serializes the given message to binary data (in protobuf wire
|
||||
* format), writing to the given BinaryWriter.
|
||||
* @param {!proto.com.docker.api.protos.context.v1.ListRequest} message
|
||||
* @param {!jspb.BinaryWriter} writer
|
||||
* @suppress {unusedLocalVariables} f is only used for nested messages
|
||||
*/
|
||||
proto.com.docker.api.protos.context.v1.ListRequest.serializeBinaryToWriter = function(message, writer) {
|
||||
var f = undefined;
|
||||
};
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* List of repeated fields within this message type.
|
||||
* @private {!Array<number>}
|
||||
* @const
|
||||
*/
|
||||
proto.com.docker.api.protos.context.v1.ListResponse.repeatedFields_ = [1];
|
||||
|
||||
|
||||
|
||||
if (jspb.Message.GENERATE_TO_OBJECT) {
|
||||
/**
|
||||
* Creates an object representation of this proto.
|
||||
* Field names that are reserved in JavaScript and will be renamed to pb_name.
|
||||
* Optional fields that are not set will be set to undefined.
|
||||
* To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
|
||||
* For the list of reserved names please see:
|
||||
* net/proto2/compiler/js/internal/generator.cc#kKeyword.
|
||||
* @param {boolean=} opt_includeInstance Deprecated. whether to include the
|
||||
* JSPB instance for transitional soy proto support:
|
||||
* http://goto/soy-param-migration
|
||||
* @return {!Object}
|
||||
*/
|
||||
proto.com.docker.api.protos.context.v1.ListResponse.prototype.toObject = function(opt_includeInstance) {
|
||||
return proto.com.docker.api.protos.context.v1.ListResponse.toObject(opt_includeInstance, this);
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Static version of the {@see toObject} method.
|
||||
* @param {boolean|undefined} includeInstance Deprecated. Whether to include
|
||||
* the JSPB instance for transitional soy proto support:
|
||||
* http://goto/soy-param-migration
|
||||
* @param {!proto.com.docker.api.protos.context.v1.ListResponse} msg The msg instance to transform.
|
||||
* @return {!Object}
|
||||
* @suppress {unusedLocalVariables} f is only used for nested messages
|
||||
*/
|
||||
proto.com.docker.api.protos.context.v1.ListResponse.toObject = function(includeInstance, msg) {
|
||||
var f, obj = {
|
||||
contextsList: jspb.Message.toObjectList(msg.getContextsList(),
|
||||
proto.com.docker.api.protos.context.v1.Context.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.com.docker.api.protos.context.v1.ListResponse}
|
||||
*/
|
||||
proto.com.docker.api.protos.context.v1.ListResponse.deserializeBinary = function(bytes) {
|
||||
var reader = new jspb.BinaryReader(bytes);
|
||||
var msg = new proto.com.docker.api.protos.context.v1.ListResponse;
|
||||
return proto.com.docker.api.protos.context.v1.ListResponse.deserializeBinaryFromReader(msg, reader);
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Deserializes binary data (in protobuf wire format) from the
|
||||
* given reader into the given message object.
|
||||
* @param {!proto.com.docker.api.protos.context.v1.ListResponse} msg The message object to deserialize into.
|
||||
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
|
||||
* @return {!proto.com.docker.api.protos.context.v1.ListResponse}
|
||||
*/
|
||||
proto.com.docker.api.protos.context.v1.ListResponse.deserializeBinaryFromReader = function(msg, reader) {
|
||||
while (reader.nextField()) {
|
||||
if (reader.isEndGroup()) {
|
||||
break;
|
||||
}
|
||||
var field = reader.getFieldNumber();
|
||||
switch (field) {
|
||||
case 1:
|
||||
var value = new proto.com.docker.api.protos.context.v1.Context;
|
||||
reader.readMessage(value,proto.com.docker.api.protos.context.v1.Context.deserializeBinaryFromReader);
|
||||
msg.addContexts(value);
|
||||
break;
|
||||
default:
|
||||
reader.skipField();
|
||||
break;
|
||||
}
|
||||
}
|
||||
return msg;
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Serializes the message to binary data (in protobuf wire format).
|
||||
* @return {!Uint8Array}
|
||||
*/
|
||||
proto.com.docker.api.protos.context.v1.ListResponse.prototype.serializeBinary = function() {
|
||||
var writer = new jspb.BinaryWriter();
|
||||
proto.com.docker.api.protos.context.v1.ListResponse.serializeBinaryToWriter(this, writer);
|
||||
return writer.getResultBuffer();
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Serializes the given message to binary data (in protobuf wire
|
||||
* format), writing to the given BinaryWriter.
|
||||
* @param {!proto.com.docker.api.protos.context.v1.ListResponse} message
|
||||
* @param {!jspb.BinaryWriter} writer
|
||||
* @suppress {unusedLocalVariables} f is only used for nested messages
|
||||
*/
|
||||
proto.com.docker.api.protos.context.v1.ListResponse.serializeBinaryToWriter = function(message, writer) {
|
||||
var f = undefined;
|
||||
f = message.getContextsList();
|
||||
if (f.length > 0) {
|
||||
writer.writeRepeatedMessage(
|
||||
1,
|
||||
f,
|
||||
proto.com.docker.api.protos.context.v1.Context.serializeBinaryToWriter
|
||||
);
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* repeated Context contexts = 1;
|
||||
* @return {!Array<!proto.com.docker.api.protos.context.v1.Context>}
|
||||
*/
|
||||
proto.com.docker.api.protos.context.v1.ListResponse.prototype.getContextsList = function() {
|
||||
return /** @type{!Array<!proto.com.docker.api.protos.context.v1.Context>} */ (
|
||||
jspb.Message.getRepeatedWrapperField(this, proto.com.docker.api.protos.context.v1.Context, 1));
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* @param {!Array<!proto.com.docker.api.protos.context.v1.Context>} value
|
||||
* @return {!proto.com.docker.api.protos.context.v1.ListResponse} returns this
|
||||
*/
|
||||
proto.com.docker.api.protos.context.v1.ListResponse.prototype.setContextsList = function(value) {
|
||||
return jspb.Message.setRepeatedWrapperField(this, 1, value);
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* @param {!proto.com.docker.api.protos.context.v1.Context=} opt_value
|
||||
* @param {number=} opt_index
|
||||
* @return {!proto.com.docker.api.protos.context.v1.Context}
|
||||
*/
|
||||
proto.com.docker.api.protos.context.v1.ListResponse.prototype.addContexts = function(opt_value, opt_index) {
|
||||
return jspb.Message.addToRepeatedWrapperField(this, 1, opt_value, proto.com.docker.api.protos.context.v1.Context, opt_index);
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Clears the list making it empty but non-null.
|
||||
* @return {!proto.com.docker.api.protos.context.v1.ListResponse} returns this
|
||||
*/
|
||||
proto.com.docker.api.protos.context.v1.ListResponse.prototype.clearContextsList = function() {
|
||||
return this.setContextsList([]);
|
||||
};
|
||||
|
||||
|
||||
goog.object.extend(exports, proto.com.docker.api.protos.context.v1);
|
Различия файлов скрыты, потому что одна или несколько строк слишком длинны
|
@ -0,0 +1,31 @@
|
|||
syntax = "proto3";
|
||||
|
||||
package com.docker.api.protos.streams.v1;
|
||||
|
||||
import "google/protobuf/any.proto";
|
||||
|
||||
option go_package = "github.com/docker/api/protos/streams/v1;v1";
|
||||
|
||||
service Streaming {
|
||||
rpc NewStream(stream google.protobuf.Any) returns (stream google.protobuf.Any);
|
||||
}
|
||||
|
||||
enum IOStream {
|
||||
STDIN = 0;
|
||||
STDOUT = 1;
|
||||
STDERR = 2;
|
||||
}
|
||||
|
||||
message BytesMessage {
|
||||
IOStream type = 1;
|
||||
bytes value = 2;
|
||||
}
|
||||
|
||||
message ResizeMessage {
|
||||
uint32 width = 1;
|
||||
uint32 height = 2;
|
||||
}
|
||||
|
||||
message ExitMessage {
|
||||
uint32 status = 1;
|
||||
}
|
|
@ -0,0 +1,42 @@
|
|||
// package: com.docker.api.protos.streams.v1
|
||||
// file: streams/v1/streams.proto
|
||||
|
||||
/* tslint:disable */
|
||||
/* eslint-disable */
|
||||
|
||||
import * as grpc from "@grpc/grpc-js";
|
||||
import {handleClientStreamingCall} from "@grpc/grpc-js/build/src/server-call";
|
||||
import * as streams_v1_streams_pb from "../../streams/v1/streams_pb";
|
||||
import * as google_protobuf_any_pb from "google-protobuf/google/protobuf/any_pb";
|
||||
|
||||
interface IStreamingService extends grpc.ServiceDefinition<grpc.UntypedServiceImplementation> {
|
||||
newStream: IStreamingService_INewStream;
|
||||
}
|
||||
|
||||
interface IStreamingService_INewStream extends grpc.MethodDefinition<google_protobuf_any_pb.Any, google_protobuf_any_pb.Any> {
|
||||
path: string; // "/com.docker.api.protos.streams.v1.Streaming/NewStream"
|
||||
requestStream: boolean; // true
|
||||
responseStream: boolean; // true
|
||||
requestSerialize: grpc.serialize<google_protobuf_any_pb.Any>;
|
||||
requestDeserialize: grpc.deserialize<google_protobuf_any_pb.Any>;
|
||||
responseSerialize: grpc.serialize<google_protobuf_any_pb.Any>;
|
||||
responseDeserialize: grpc.deserialize<google_protobuf_any_pb.Any>;
|
||||
}
|
||||
|
||||
export const StreamingService: IStreamingService;
|
||||
|
||||
export interface IStreamingServer {
|
||||
newStream: grpc.handleBidiStreamingCall<google_protobuf_any_pb.Any, google_protobuf_any_pb.Any>;
|
||||
}
|
||||
|
||||
export interface IStreamingClient {
|
||||
newStream(): grpc.ClientDuplexStream<google_protobuf_any_pb.Any, google_protobuf_any_pb.Any>;
|
||||
newStream(options: Partial<grpc.CallOptions>): grpc.ClientDuplexStream<google_protobuf_any_pb.Any, google_protobuf_any_pb.Any>;
|
||||
newStream(metadata: grpc.Metadata, options?: Partial<grpc.CallOptions>): grpc.ClientDuplexStream<google_protobuf_any_pb.Any, google_protobuf_any_pb.Any>;
|
||||
}
|
||||
|
||||
export class StreamingClient extends grpc.Client implements IStreamingClient {
|
||||
constructor(address: string, credentials: grpc.ChannelCredentials, options?: object);
|
||||
public newStream(options?: Partial<grpc.CallOptions>): grpc.ClientDuplexStream<google_protobuf_any_pb.Any, google_protobuf_any_pb.Any>;
|
||||
public newStream(metadata?: grpc.Metadata, options?: Partial<grpc.CallOptions>): grpc.ClientDuplexStream<google_protobuf_any_pb.Any, google_protobuf_any_pb.Any>;
|
||||
}
|
|
@ -0,0 +1,34 @@
|
|||
// GENERATED CODE -- DO NOT EDIT!
|
||||
|
||||
'use strict';
|
||||
var grpc = require('@grpc/grpc-js');
|
||||
var streams_v1_streams_pb = require('../../streams/v1/streams_pb.js');
|
||||
var google_protobuf_any_pb = require('google-protobuf/google/protobuf/any_pb.js');
|
||||
|
||||
function serialize_google_protobuf_Any(arg) {
|
||||
if (!(arg instanceof google_protobuf_any_pb.Any)) {
|
||||
throw new Error('Expected argument of type google.protobuf.Any');
|
||||
}
|
||||
return Buffer.from(arg.serializeBinary());
|
||||
}
|
||||
|
||||
function deserialize_google_protobuf_Any(buffer_arg) {
|
||||
return google_protobuf_any_pb.Any.deserializeBinary(new Uint8Array(buffer_arg));
|
||||
}
|
||||
|
||||
|
||||
var StreamingService = exports.StreamingService = {
|
||||
newStream: {
|
||||
path: '/com.docker.api.protos.streams.v1.Streaming/NewStream',
|
||||
requestStream: true,
|
||||
responseStream: true,
|
||||
requestType: google_protobuf_any_pb.Any,
|
||||
responseType: google_protobuf_any_pb.Any,
|
||||
requestSerialize: serialize_google_protobuf_Any,
|
||||
requestDeserialize: deserialize_google_protobuf_Any,
|
||||
responseSerialize: serialize_google_protobuf_Any,
|
||||
responseDeserialize: deserialize_google_protobuf_Any,
|
||||
},
|
||||
};
|
||||
|
||||
exports.StreamingClient = grpc.makeGenericClientConstructor(StreamingService);
|
|
@ -0,0 +1 @@
|
|||
{"version":3,"file":"streams_grpc_pb.js","sourceRoot":"","sources":["../../../../src/protos/streams/v1/streams_grpc_pb.js"],"names":[],"mappings":"AAAA,iCAAiC;AAEjC,YAAY,CAAC;AACb,IAAI,IAAI,GAAG,OAAO,CAAC,eAAe,CAAC,CAAC;AACpC,IAAI,qBAAqB,GAAG,OAAO,CAAC,gCAAgC,CAAC,CAAC;AACtE,IAAI,sBAAsB,GAAG,OAAO,CAAC,2CAA2C,CAAC,CAAC;AAElF,SAAS,6BAA6B,CAAC,GAAG;IACxC,IAAI,CAAC,CAAC,GAAG,YAAY,sBAAsB,CAAC,GAAG,CAAC,EAAE;QAChD,MAAM,IAAI,KAAK,CAAC,+CAA+C,CAAC,CAAC;KAClE;IACD,OAAO,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,eAAe,EAAE,CAAC,CAAC;AAC5C,CAAC;AAED,SAAS,+BAA+B,CAAC,UAAU;IACjD,OAAO,sBAAsB,CAAC,GAAG,CAAC,iBAAiB,CAAC,IAAI,UAAU,CAAC,UAAU,CAAC,CAAC,CAAC;AAClF,CAAC;AAGD,IAAI,gBAAgB,GAAG,OAAO,CAAC,gBAAgB,GAAG;IAChD,SAAS,EAAE;QACT,IAAI,EAAE,uDAAuD;QAC7D,aAAa,EAAE,IAAI;QACnB,cAAc,EAAE,IAAI;QACpB,WAAW,EAAE,sBAAsB,CAAC,GAAG;QACvC,YAAY,EAAE,sBAAsB,CAAC,GAAG;QACxC,gBAAgB,EAAE,6BAA6B;QAC/C,kBAAkB,EAAE,+BAA+B;QACnD,iBAAiB,EAAE,6BAA6B;QAChD,mBAAmB,EAAE,+BAA+B;KACrD;CACF,CAAC;AAEF,OAAO,CAAC,eAAe,GAAG,IAAI,CAAC,4BAA4B,CAAC,gBAAgB,CAAC,CAAC"}
|
|
@ -0,0 +1,87 @@
|
|||
// package: com.docker.api.protos.streams.v1
|
||||
// file: streams/v1/streams.proto
|
||||
|
||||
/* tslint:disable */
|
||||
/* eslint-disable */
|
||||
|
||||
import * as jspb from "google-protobuf";
|
||||
import * as google_protobuf_any_pb from "google-protobuf/google/protobuf/any_pb";
|
||||
|
||||
export class BytesMessage extends jspb.Message {
|
||||
getType(): IOStream;
|
||||
setType(value: IOStream): BytesMessage;
|
||||
|
||||
getValue(): Uint8Array | string;
|
||||
getValue_asU8(): Uint8Array;
|
||||
getValue_asB64(): string;
|
||||
setValue(value: Uint8Array | string): BytesMessage;
|
||||
|
||||
|
||||
serializeBinary(): Uint8Array;
|
||||
toObject(includeInstance?: boolean): BytesMessage.AsObject;
|
||||
static toObject(includeInstance: boolean, msg: BytesMessage): BytesMessage.AsObject;
|
||||
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
|
||||
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
|
||||
static serializeBinaryToWriter(message: BytesMessage, writer: jspb.BinaryWriter): void;
|
||||
static deserializeBinary(bytes: Uint8Array): BytesMessage;
|
||||
static deserializeBinaryFromReader(message: BytesMessage, reader: jspb.BinaryReader): BytesMessage;
|
||||
}
|
||||
|
||||
export namespace BytesMessage {
|
||||
export type AsObject = {
|
||||
type: IOStream,
|
||||
value: Uint8Array | string,
|
||||
}
|
||||
}
|
||||
|
||||
export class ResizeMessage extends jspb.Message {
|
||||
getWidth(): number;
|
||||
setWidth(value: number): ResizeMessage;
|
||||
|
||||
getHeight(): number;
|
||||
setHeight(value: number): ResizeMessage;
|
||||
|
||||
|
||||
serializeBinary(): Uint8Array;
|
||||
toObject(includeInstance?: boolean): ResizeMessage.AsObject;
|
||||
static toObject(includeInstance: boolean, msg: ResizeMessage): ResizeMessage.AsObject;
|
||||
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
|
||||
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
|
||||
static serializeBinaryToWriter(message: ResizeMessage, writer: jspb.BinaryWriter): void;
|
||||
static deserializeBinary(bytes: Uint8Array): ResizeMessage;
|
||||
static deserializeBinaryFromReader(message: ResizeMessage, reader: jspb.BinaryReader): ResizeMessage;
|
||||
}
|
||||
|
||||
export namespace ResizeMessage {
|
||||
export type AsObject = {
|
||||
width: number,
|
||||
height: number,
|
||||
}
|
||||
}
|
||||
|
||||
export class ExitMessage extends jspb.Message {
|
||||
getStatus(): number;
|
||||
setStatus(value: number): ExitMessage;
|
||||
|
||||
|
||||
serializeBinary(): Uint8Array;
|
||||
toObject(includeInstance?: boolean): ExitMessage.AsObject;
|
||||
static toObject(includeInstance: boolean, msg: ExitMessage): ExitMessage.AsObject;
|
||||
static extensions: {[key: number]: jspb.ExtensionFieldInfo<jspb.Message>};
|
||||
static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo<jspb.Message>};
|
||||
static serializeBinaryToWriter(message: ExitMessage, writer: jspb.BinaryWriter): void;
|
||||
static deserializeBinary(bytes: Uint8Array): ExitMessage;
|
||||
static deserializeBinaryFromReader(message: ExitMessage, reader: jspb.BinaryReader): ExitMessage;
|
||||
}
|
||||
|
||||
export namespace ExitMessage {
|
||||
export type AsObject = {
|
||||
status: number,
|
||||
}
|
||||
}
|
||||
|
||||
export enum IOStream {
|
||||
STDIN = 0,
|
||||
STDOUT = 1,
|
||||
STDERR = 2,
|
||||
}
|
|
@ -0,0 +1,567 @@
|
|||
// source: streams/v1/streams.proto
|
||||
/**
|
||||
* @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 google_protobuf_any_pb = require('google-protobuf/google/protobuf/any_pb.js');
|
||||
goog.object.extend(proto, google_protobuf_any_pb);
|
||||
goog.exportSymbol('proto.com.docker.api.protos.streams.v1.BytesMessage', null, global);
|
||||
goog.exportSymbol('proto.com.docker.api.protos.streams.v1.ExitMessage', null, global);
|
||||
goog.exportSymbol('proto.com.docker.api.protos.streams.v1.IOStream', null, global);
|
||||
goog.exportSymbol('proto.com.docker.api.protos.streams.v1.ResizeMessage', 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.com.docker.api.protos.streams.v1.BytesMessage = function(opt_data) {
|
||||
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
|
||||
};
|
||||
goog.inherits(proto.com.docker.api.protos.streams.v1.BytesMessage, jspb.Message);
|
||||
if (goog.DEBUG && !COMPILED) {
|
||||
/**
|
||||
* @public
|
||||
* @override
|
||||
*/
|
||||
proto.com.docker.api.protos.streams.v1.BytesMessage.displayName = 'proto.com.docker.api.protos.streams.v1.BytesMessage';
|
||||
}
|
||||
/**
|
||||
* 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.com.docker.api.protos.streams.v1.ResizeMessage = function(opt_data) {
|
||||
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
|
||||
};
|
||||
goog.inherits(proto.com.docker.api.protos.streams.v1.ResizeMessage, jspb.Message);
|
||||
if (goog.DEBUG && !COMPILED) {
|
||||
/**
|
||||
* @public
|
||||
* @override
|
||||
*/
|
||||
proto.com.docker.api.protos.streams.v1.ResizeMessage.displayName = 'proto.com.docker.api.protos.streams.v1.ResizeMessage';
|
||||
}
|
||||
/**
|
||||
* 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.com.docker.api.protos.streams.v1.ExitMessage = function(opt_data) {
|
||||
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
|
||||
};
|
||||
goog.inherits(proto.com.docker.api.protos.streams.v1.ExitMessage, jspb.Message);
|
||||
if (goog.DEBUG && !COMPILED) {
|
||||
/**
|
||||
* @public
|
||||
* @override
|
||||
*/
|
||||
proto.com.docker.api.protos.streams.v1.ExitMessage.displayName = 'proto.com.docker.api.protos.streams.v1.ExitMessage';
|
||||
}
|
||||
|
||||
|
||||
|
||||
if (jspb.Message.GENERATE_TO_OBJECT) {
|
||||
/**
|
||||
* Creates an object representation of this proto.
|
||||
* Field names that are reserved in JavaScript and will be renamed to pb_name.
|
||||
* Optional fields that are not set will be set to undefined.
|
||||
* To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
|
||||
* For the list of reserved names please see:
|
||||
* net/proto2/compiler/js/internal/generator.cc#kKeyword.
|
||||
* @param {boolean=} opt_includeInstance Deprecated. whether to include the
|
||||
* JSPB instance for transitional soy proto support:
|
||||
* http://goto/soy-param-migration
|
||||
* @return {!Object}
|
||||
*/
|
||||
proto.com.docker.api.protos.streams.v1.BytesMessage.prototype.toObject = function(opt_includeInstance) {
|
||||
return proto.com.docker.api.protos.streams.v1.BytesMessage.toObject(opt_includeInstance, this);
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Static version of the {@see toObject} method.
|
||||
* @param {boolean|undefined} includeInstance Deprecated. Whether to include
|
||||
* the JSPB instance for transitional soy proto support:
|
||||
* http://goto/soy-param-migration
|
||||
* @param {!proto.com.docker.api.protos.streams.v1.BytesMessage} msg The msg instance to transform.
|
||||
* @return {!Object}
|
||||
* @suppress {unusedLocalVariables} f is only used for nested messages
|
||||
*/
|
||||
proto.com.docker.api.protos.streams.v1.BytesMessage.toObject = function(includeInstance, msg) {
|
||||
var f, obj = {
|
||||
type: jspb.Message.getFieldWithDefault(msg, 1, 0),
|
||||
value: msg.getValue_asB64()
|
||||
};
|
||||
|
||||
if (includeInstance) {
|
||||
obj.$jspbMessageInstance = msg;
|
||||
}
|
||||
return obj;
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Deserializes binary data (in protobuf wire format).
|
||||
* @param {jspb.ByteSource} bytes The bytes to deserialize.
|
||||
* @return {!proto.com.docker.api.protos.streams.v1.BytesMessage}
|
||||
*/
|
||||
proto.com.docker.api.protos.streams.v1.BytesMessage.deserializeBinary = function(bytes) {
|
||||
var reader = new jspb.BinaryReader(bytes);
|
||||
var msg = new proto.com.docker.api.protos.streams.v1.BytesMessage;
|
||||
return proto.com.docker.api.protos.streams.v1.BytesMessage.deserializeBinaryFromReader(msg, reader);
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Deserializes binary data (in protobuf wire format) from the
|
||||
* given reader into the given message object.
|
||||
* @param {!proto.com.docker.api.protos.streams.v1.BytesMessage} msg The message object to deserialize into.
|
||||
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
|
||||
* @return {!proto.com.docker.api.protos.streams.v1.BytesMessage}
|
||||
*/
|
||||
proto.com.docker.api.protos.streams.v1.BytesMessage.deserializeBinaryFromReader = function(msg, reader) {
|
||||
while (reader.nextField()) {
|
||||
if (reader.isEndGroup()) {
|
||||
break;
|
||||
}
|
||||
var field = reader.getFieldNumber();
|
||||
switch (field) {
|
||||
case 1:
|
||||
var value = /** @type {!proto.com.docker.api.protos.streams.v1.IOStream} */ (reader.readEnum());
|
||||
msg.setType(value);
|
||||
break;
|
||||
case 2:
|
||||
var value = /** @type {!Uint8Array} */ (reader.readBytes());
|
||||
msg.setValue(value);
|
||||
break;
|
||||
default:
|
||||
reader.skipField();
|
||||
break;
|
||||
}
|
||||
}
|
||||
return msg;
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Serializes the message to binary data (in protobuf wire format).
|
||||
* @return {!Uint8Array}
|
||||
*/
|
||||
proto.com.docker.api.protos.streams.v1.BytesMessage.prototype.serializeBinary = function() {
|
||||
var writer = new jspb.BinaryWriter();
|
||||
proto.com.docker.api.protos.streams.v1.BytesMessage.serializeBinaryToWriter(this, writer);
|
||||
return writer.getResultBuffer();
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Serializes the given message to binary data (in protobuf wire
|
||||
* format), writing to the given BinaryWriter.
|
||||
* @param {!proto.com.docker.api.protos.streams.v1.BytesMessage} message
|
||||
* @param {!jspb.BinaryWriter} writer
|
||||
* @suppress {unusedLocalVariables} f is only used for nested messages
|
||||
*/
|
||||
proto.com.docker.api.protos.streams.v1.BytesMessage.serializeBinaryToWriter = function(message, writer) {
|
||||
var f = undefined;
|
||||
f = message.getType();
|
||||
if (f !== 0.0) {
|
||||
writer.writeEnum(
|
||||
1,
|
||||
f
|
||||
);
|
||||
}
|
||||
f = message.getValue_asU8();
|
||||
if (f.length > 0) {
|
||||
writer.writeBytes(
|
||||
2,
|
||||
f
|
||||
);
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* optional IOStream type = 1;
|
||||
* @return {!proto.com.docker.api.protos.streams.v1.IOStream}
|
||||
*/
|
||||
proto.com.docker.api.protos.streams.v1.BytesMessage.prototype.getType = function() {
|
||||
return /** @type {!proto.com.docker.api.protos.streams.v1.IOStream} */ (jspb.Message.getFieldWithDefault(this, 1, 0));
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* @param {!proto.com.docker.api.protos.streams.v1.IOStream} value
|
||||
* @return {!proto.com.docker.api.protos.streams.v1.BytesMessage} returns this
|
||||
*/
|
||||
proto.com.docker.api.protos.streams.v1.BytesMessage.prototype.setType = function(value) {
|
||||
return jspb.Message.setProto3EnumField(this, 1, value);
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* optional bytes value = 2;
|
||||
* @return {!(string|Uint8Array)}
|
||||
*/
|
||||
proto.com.docker.api.protos.streams.v1.BytesMessage.prototype.getValue = function() {
|
||||
return /** @type {!(string|Uint8Array)} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* optional bytes value = 2;
|
||||
* This is a type-conversion wrapper around `getValue()`
|
||||
* @return {string}
|
||||
*/
|
||||
proto.com.docker.api.protos.streams.v1.BytesMessage.prototype.getValue_asB64 = function() {
|
||||
return /** @type {string} */ (jspb.Message.bytesAsB64(
|
||||
this.getValue()));
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* optional bytes value = 2;
|
||||
* Note that Uint8Array is not supported on all browsers.
|
||||
* @see http://caniuse.com/Uint8Array
|
||||
* This is a type-conversion wrapper around `getValue()`
|
||||
* @return {!Uint8Array}
|
||||
*/
|
||||
proto.com.docker.api.protos.streams.v1.BytesMessage.prototype.getValue_asU8 = function() {
|
||||
return /** @type {!Uint8Array} */ (jspb.Message.bytesAsU8(
|
||||
this.getValue()));
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* @param {!(string|Uint8Array)} value
|
||||
* @return {!proto.com.docker.api.protos.streams.v1.BytesMessage} returns this
|
||||
*/
|
||||
proto.com.docker.api.protos.streams.v1.BytesMessage.prototype.setValue = function(value) {
|
||||
return jspb.Message.setProto3BytesField(this, 2, value);
|
||||
};
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
if (jspb.Message.GENERATE_TO_OBJECT) {
|
||||
/**
|
||||
* Creates an object representation of this proto.
|
||||
* Field names that are reserved in JavaScript and will be renamed to pb_name.
|
||||
* Optional fields that are not set will be set to undefined.
|
||||
* To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
|
||||
* For the list of reserved names please see:
|
||||
* net/proto2/compiler/js/internal/generator.cc#kKeyword.
|
||||
* @param {boolean=} opt_includeInstance Deprecated. whether to include the
|
||||
* JSPB instance for transitional soy proto support:
|
||||
* http://goto/soy-param-migration
|
||||
* @return {!Object}
|
||||
*/
|
||||
proto.com.docker.api.protos.streams.v1.ResizeMessage.prototype.toObject = function(opt_includeInstance) {
|
||||
return proto.com.docker.api.protos.streams.v1.ResizeMessage.toObject(opt_includeInstance, this);
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Static version of the {@see toObject} method.
|
||||
* @param {boolean|undefined} includeInstance Deprecated. Whether to include
|
||||
* the JSPB instance for transitional soy proto support:
|
||||
* http://goto/soy-param-migration
|
||||
* @param {!proto.com.docker.api.protos.streams.v1.ResizeMessage} msg The msg instance to transform.
|
||||
* @return {!Object}
|
||||
* @suppress {unusedLocalVariables} f is only used for nested messages
|
||||
*/
|
||||
proto.com.docker.api.protos.streams.v1.ResizeMessage.toObject = function(includeInstance, msg) {
|
||||
var f, obj = {
|
||||
width: jspb.Message.getFieldWithDefault(msg, 1, 0),
|
||||
height: jspb.Message.getFieldWithDefault(msg, 2, 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.com.docker.api.protos.streams.v1.ResizeMessage}
|
||||
*/
|
||||
proto.com.docker.api.protos.streams.v1.ResizeMessage.deserializeBinary = function(bytes) {
|
||||
var reader = new jspb.BinaryReader(bytes);
|
||||
var msg = new proto.com.docker.api.protos.streams.v1.ResizeMessage;
|
||||
return proto.com.docker.api.protos.streams.v1.ResizeMessage.deserializeBinaryFromReader(msg, reader);
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Deserializes binary data (in protobuf wire format) from the
|
||||
* given reader into the given message object.
|
||||
* @param {!proto.com.docker.api.protos.streams.v1.ResizeMessage} msg The message object to deserialize into.
|
||||
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
|
||||
* @return {!proto.com.docker.api.protos.streams.v1.ResizeMessage}
|
||||
*/
|
||||
proto.com.docker.api.protos.streams.v1.ResizeMessage.deserializeBinaryFromReader = function(msg, reader) {
|
||||
while (reader.nextField()) {
|
||||
if (reader.isEndGroup()) {
|
||||
break;
|
||||
}
|
||||
var field = reader.getFieldNumber();
|
||||
switch (field) {
|
||||
case 1:
|
||||
var value = /** @type {number} */ (reader.readUint32());
|
||||
msg.setWidth(value);
|
||||
break;
|
||||
case 2:
|
||||
var value = /** @type {number} */ (reader.readUint32());
|
||||
msg.setHeight(value);
|
||||
break;
|
||||
default:
|
||||
reader.skipField();
|
||||
break;
|
||||
}
|
||||
}
|
||||
return msg;
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Serializes the message to binary data (in protobuf wire format).
|
||||
* @return {!Uint8Array}
|
||||
*/
|
||||
proto.com.docker.api.protos.streams.v1.ResizeMessage.prototype.serializeBinary = function() {
|
||||
var writer = new jspb.BinaryWriter();
|
||||
proto.com.docker.api.protos.streams.v1.ResizeMessage.serializeBinaryToWriter(this, writer);
|
||||
return writer.getResultBuffer();
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Serializes the given message to binary data (in protobuf wire
|
||||
* format), writing to the given BinaryWriter.
|
||||
* @param {!proto.com.docker.api.protos.streams.v1.ResizeMessage} message
|
||||
* @param {!jspb.BinaryWriter} writer
|
||||
* @suppress {unusedLocalVariables} f is only used for nested messages
|
||||
*/
|
||||
proto.com.docker.api.protos.streams.v1.ResizeMessage.serializeBinaryToWriter = function(message, writer) {
|
||||
var f = undefined;
|
||||
f = message.getWidth();
|
||||
if (f !== 0) {
|
||||
writer.writeUint32(
|
||||
1,
|
||||
f
|
||||
);
|
||||
}
|
||||
f = message.getHeight();
|
||||
if (f !== 0) {
|
||||
writer.writeUint32(
|
||||
2,
|
||||
f
|
||||
);
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* optional uint32 width = 1;
|
||||
* @return {number}
|
||||
*/
|
||||
proto.com.docker.api.protos.streams.v1.ResizeMessage.prototype.getWidth = function() {
|
||||
return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 1, 0));
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* @param {number} value
|
||||
* @return {!proto.com.docker.api.protos.streams.v1.ResizeMessage} returns this
|
||||
*/
|
||||
proto.com.docker.api.protos.streams.v1.ResizeMessage.prototype.setWidth = function(value) {
|
||||
return jspb.Message.setProto3IntField(this, 1, value);
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* optional uint32 height = 2;
|
||||
* @return {number}
|
||||
*/
|
||||
proto.com.docker.api.protos.streams.v1.ResizeMessage.prototype.getHeight = function() {
|
||||
return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 2, 0));
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* @param {number} value
|
||||
* @return {!proto.com.docker.api.protos.streams.v1.ResizeMessage} returns this
|
||||
*/
|
||||
proto.com.docker.api.protos.streams.v1.ResizeMessage.prototype.setHeight = function(value) {
|
||||
return jspb.Message.setProto3IntField(this, 2, value);
|
||||
};
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
if (jspb.Message.GENERATE_TO_OBJECT) {
|
||||
/**
|
||||
* Creates an object representation of this proto.
|
||||
* Field names that are reserved in JavaScript and will be renamed to pb_name.
|
||||
* Optional fields that are not set will be set to undefined.
|
||||
* To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
|
||||
* For the list of reserved names please see:
|
||||
* net/proto2/compiler/js/internal/generator.cc#kKeyword.
|
||||
* @param {boolean=} opt_includeInstance Deprecated. whether to include the
|
||||
* JSPB instance for transitional soy proto support:
|
||||
* http://goto/soy-param-migration
|
||||
* @return {!Object}
|
||||
*/
|
||||
proto.com.docker.api.protos.streams.v1.ExitMessage.prototype.toObject = function(opt_includeInstance) {
|
||||
return proto.com.docker.api.protos.streams.v1.ExitMessage.toObject(opt_includeInstance, this);
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Static version of the {@see toObject} method.
|
||||
* @param {boolean|undefined} includeInstance Deprecated. Whether to include
|
||||
* the JSPB instance for transitional soy proto support:
|
||||
* http://goto/soy-param-migration
|
||||
* @param {!proto.com.docker.api.protos.streams.v1.ExitMessage} msg The msg instance to transform.
|
||||
* @return {!Object}
|
||||
* @suppress {unusedLocalVariables} f is only used for nested messages
|
||||
*/
|
||||
proto.com.docker.api.protos.streams.v1.ExitMessage.toObject = function(includeInstance, msg) {
|
||||
var f, obj = {
|
||||
status: jspb.Message.getFieldWithDefault(msg, 1, 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.com.docker.api.protos.streams.v1.ExitMessage}
|
||||
*/
|
||||
proto.com.docker.api.protos.streams.v1.ExitMessage.deserializeBinary = function(bytes) {
|
||||
var reader = new jspb.BinaryReader(bytes);
|
||||
var msg = new proto.com.docker.api.protos.streams.v1.ExitMessage;
|
||||
return proto.com.docker.api.protos.streams.v1.ExitMessage.deserializeBinaryFromReader(msg, reader);
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Deserializes binary data (in protobuf wire format) from the
|
||||
* given reader into the given message object.
|
||||
* @param {!proto.com.docker.api.protos.streams.v1.ExitMessage} msg The message object to deserialize into.
|
||||
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
|
||||
* @return {!proto.com.docker.api.protos.streams.v1.ExitMessage}
|
||||
*/
|
||||
proto.com.docker.api.protos.streams.v1.ExitMessage.deserializeBinaryFromReader = function(msg, reader) {
|
||||
while (reader.nextField()) {
|
||||
if (reader.isEndGroup()) {
|
||||
break;
|
||||
}
|
||||
var field = reader.getFieldNumber();
|
||||
switch (field) {
|
||||
case 1:
|
||||
var value = /** @type {number} */ (reader.readUint32());
|
||||
msg.setStatus(value);
|
||||
break;
|
||||
default:
|
||||
reader.skipField();
|
||||
break;
|
||||
}
|
||||
}
|
||||
return msg;
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Serializes the message to binary data (in protobuf wire format).
|
||||
* @return {!Uint8Array}
|
||||
*/
|
||||
proto.com.docker.api.protos.streams.v1.ExitMessage.prototype.serializeBinary = function() {
|
||||
var writer = new jspb.BinaryWriter();
|
||||
proto.com.docker.api.protos.streams.v1.ExitMessage.serializeBinaryToWriter(this, writer);
|
||||
return writer.getResultBuffer();
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Serializes the given message to binary data (in protobuf wire
|
||||
* format), writing to the given BinaryWriter.
|
||||
* @param {!proto.com.docker.api.protos.streams.v1.ExitMessage} message
|
||||
* @param {!jspb.BinaryWriter} writer
|
||||
* @suppress {unusedLocalVariables} f is only used for nested messages
|
||||
*/
|
||||
proto.com.docker.api.protos.streams.v1.ExitMessage.serializeBinaryToWriter = function(message, writer) {
|
||||
var f = undefined;
|
||||
f = message.getStatus();
|
||||
if (f !== 0) {
|
||||
writer.writeUint32(
|
||||
1,
|
||||
f
|
||||
);
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* optional uint32 status = 1;
|
||||
* @return {number}
|
||||
*/
|
||||
proto.com.docker.api.protos.streams.v1.ExitMessage.prototype.getStatus = function() {
|
||||
return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 1, 0));
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* @param {number} value
|
||||
* @return {!proto.com.docker.api.protos.streams.v1.ExitMessage} returns this
|
||||
*/
|
||||
proto.com.docker.api.protos.streams.v1.ExitMessage.prototype.setStatus = function(value) {
|
||||
return jspb.Message.setProto3IntField(this, 1, value);
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* @enum {number}
|
||||
*/
|
||||
proto.com.docker.api.protos.streams.v1.IOStream = {
|
||||
STDIN: 0,
|
||||
STDOUT: 1,
|
||||
STDERR: 2
|
||||
};
|
||||
|
||||
goog.object.extend(exports, proto.com.docker.api.protos.streams.v1);
|
Различия файлов скрыты, потому что одна или несколько строк слишком длинны
18
package.json
18
package.json
|
@ -12,7 +12,8 @@
|
|||
},
|
||||
"scripts": {
|
||||
"start": "rollup -w -c",
|
||||
"build": "rollup -c",
|
||||
"build": "tsc && yarn move-protos",
|
||||
"move-protos": "cp -r src/protos dist",
|
||||
"test": "jest",
|
||||
"test:watch": "jest --watch",
|
||||
"lint": "eslint src --ext .ts",
|
||||
|
@ -29,14 +30,10 @@
|
|||
"author": "Docker Inc.",
|
||||
"module": "dist/mylib.esm.js",
|
||||
"devDependencies": {
|
||||
"@babel/core": "^7.10.2",
|
||||
"@babel/preset-env": "^7.10.2",
|
||||
"@babel/preset-typescript": "^7.10.1",
|
||||
"@rollup/plugin-commonjs": "^13.0.0",
|
||||
"@rollup/plugin-typescript": "^4.1.2",
|
||||
"@types/node": "^14.0.11",
|
||||
"@typescript-eslint/eslint-plugin": "^3.2.0",
|
||||
"@typescript-eslint/parser": "^3.2.0",
|
||||
"@types/google-protobuf": "^3.7.2",
|
||||
"@types/node": "^14.0.13",
|
||||
"@typescript-eslint/eslint-plugin": "^3.1.0",
|
||||
"@typescript-eslint/parser": "^3.1.0",
|
||||
"eslint": "^7.2.0",
|
||||
"eslint-config-airbnb-base": "^14.1.0",
|
||||
"eslint-plugin-import": "^2.20.2",
|
||||
|
@ -44,10 +41,7 @@
|
|||
"grpc_tools_node_protoc_ts": "^4.0.0",
|
||||
"jest": "^26.0.1",
|
||||
"prettier": "^2.0.5",
|
||||
"rollup": "^2.13.1",
|
||||
"rollup-plugin-terser": "^6.1.0",
|
||||
"ts-node": "^8.10.2",
|
||||
"tslib": "^2.0.0",
|
||||
"typescript": "^3.9.5"
|
||||
},
|
||||
"dependencies": {
|
||||
|
|
|
@ -1,22 +0,0 @@
|
|||
import typescript from '@rollup/plugin-typescript';
|
||||
import commonjs from '@rollup/plugin-commonjs';
|
||||
import { terser } from 'rollup-plugin-terser';
|
||||
|
||||
export default {
|
||||
input: 'src/index.ts',
|
||||
external: ['@grpc/grpc-js', '@grpc/proto-loader', 'google-protobuf'],
|
||||
treeshake: false,
|
||||
output: {
|
||||
dir: 'dist',
|
||||
format: 'cjs',
|
||||
compact: true,
|
||||
sourcemap: true,
|
||||
},
|
||||
plugins: [
|
||||
typescript({
|
||||
outDir: 'dist',
|
||||
}),
|
||||
commonjs(),
|
||||
process.env.NODE_ENV === 'production' && terser(),
|
||||
],
|
||||
};
|
10
src/index.ts
10
src/index.ts
|
@ -1,4 +1,4 @@
|
|||
import * as grpc from '@grpc/grpc-js';
|
||||
import { credentials } from '@grpc/grpc-js';
|
||||
import { ContainersClient } from './protos/containers/v1/containers_grpc_pb';
|
||||
import { ContextsClient } from './protos/contexts/v1/contexts_grpc_pb';
|
||||
import { ComposeClient } from './protos/compose/v1/compose_grpc_pb';
|
||||
|
@ -9,24 +9,24 @@ const address = 'unix:///tmp/backend.sock';
|
|||
|
||||
export class Containers extends ContainersClient {
|
||||
constructor() {
|
||||
super(address, grpc.credentials.createInsecure());
|
||||
super(address, credentials.createInsecure());
|
||||
}
|
||||
}
|
||||
|
||||
export class Contexts extends ContextsClient {
|
||||
constructor() {
|
||||
super(address, grpc.credentials.createInsecure());
|
||||
super(address, credentials.createInsecure());
|
||||
}
|
||||
}
|
||||
|
||||
export class Compose extends ComposeClient {
|
||||
constructor() {
|
||||
super(address, grpc.credentials.createInsecure());
|
||||
super(address, credentials.createInsecure());
|
||||
}
|
||||
}
|
||||
|
||||
export class Streams extends StreamingClient {
|
||||
constructor() {
|
||||
super(address, grpc.credentials.createInsecure());
|
||||
super(address, credentials.createInsecure());
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,8 +1,8 @@
|
|||
{
|
||||
"include": ["src", "types"],
|
||||
"compilerOptions": {
|
||||
"module": "ESNext",
|
||||
"target": "ESNext",
|
||||
"module": "CommonJS",
|
||||
"target": "ES2015",
|
||||
"lib": ["esnext"],
|
||||
"importHelpers": true,
|
||||
"declaration": true,
|
||||
|
@ -10,7 +10,7 @@
|
|||
"allowJs": true,
|
||||
"rootDir": "./src",
|
||||
"strict": true,
|
||||
"outDir": "/dev/shm",
|
||||
"outDir": "dist",
|
||||
"noUnusedLocals": true,
|
||||
"noUnusedParameters": true,
|
||||
"noImplicitReturns": true,
|
||||
|
|
925
yarn.lock
925
yarn.lock
Разница между файлами не показана из-за своего большого размера
Загрузить разницу
Загрузка…
Ссылка в новой задаче