bltjs
Version:
A BigchainDB Load Tester
22 lines (21 loc) • 804 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
/**
* ApiInfo is used to store information about the API of the connected node. It's what you get when you navigate to the api_url.
*/
class ApiInfo {
/**
* Create a new ApiInfo object from a JSON Object.
* @param {any} jsonObject - The JSON Object we will extract information from.
* @returns {ApiInfo} The constructed ApiInfo object.
*/
static copyConstructor(jsonObject) {
let newApiInfo = new ApiInfo();
newApiInfo.assets = jsonObject.assets;
newApiInfo.docs = jsonObject.docs;
newApiInfo.streams = jsonObject.streams;
newApiInfo.transactions = jsonObject.transactions;
return newApiInfo;
}
}
exports.ApiInfo = ApiInfo;