UNPKG

@canonical/jujulib

Version:
86 lines (85 loc) 2.39 kB
/** Juju Client version 5. This facade is available on: Controller-machine-agent Machine-agent Unit-agent Models NOTE: This file was generated using the Juju schema from Juju 3.0-beta4 at the git SHA a13ab81a. Do not manually edit this file. */ import { autoBind } from "../../utils.js"; /** Client serves client-specific API methods. */ class ClientV5 { constructor(transport, info) { this.NAME = "Client"; this.VERSION = 5; this._transport = transport; this._info = info; // Automatically bind all methods to instances. autoBind(this); } /** FindTools returns a List containing all tools matching the given parameters. */ findTools(params) { return new Promise((resolve, reject) => { const req = { type: "Client", request: "FindTools", version: 5, params: params, }; this._transport.write(req, resolve, reject); }); } /** FullStatus gives the information needed for juju status over the api */ fullStatus(params) { return new Promise((resolve, reject) => { const req = { type: "Client", request: "FullStatus", version: 5, params: params, }; this._transport.write(req, resolve, reject); }); } /** StatusHistory returns a slice of past statuses for several entities. */ statusHistory(params) { return new Promise((resolve, reject) => { const req = { type: "Client", request: "StatusHistory", version: 5, params: params, }; this._transport.write(req, resolve, reject); }); } /** WatchAll initiates a watcher for entities in the connected model. */ watchAll(params) { return new Promise((resolve, reject) => { const req = { type: "Client", request: "WatchAll", version: 5, params: params, }; this._transport.write(req, resolve, reject); }); } } ClientV5.NAME = "Client"; ClientV5.VERSION = 5; export default ClientV5; //# sourceMappingURL=ClientV5.js.map