Files
api/docs/assets/js/242.e6043b4e.js
T
2019-02-27 15:39:51 +00:00

1 line
13 KiB
JavaScript

(window.webpackJsonp=window.webpackJsonp||[]).push([[242],{551:function(t,e,r){"use strict";r.r(e);var s=r(46),a=Object(s.a)({},function(){var t=this,e=t.$createElement,r=t._self._c||e;return r("ContentSlotsDistributor",{attrs:{"slot-key":t.$parent.slotKey}},[r("p",[r("em",[r("strong",[t._v("name")])]),t._v(": ChainProperties")]),t._v(" "),r("p",[r("em",[r("strong",[t._v("description")])]),t._v(": Wraps the properties retrieved from the chain via the "),r("code",[t._v("system.properties")]),t._v(" RPC call. It extends the standard JS Map with de-facto values exposed as getters. While it implements a Codec, it is limited in that it can only be used with input objects via RPC, i.e. no hex decoding. Unlike a struct, this wrasp a JSON object with unknown keys and any values for those")]),t._v(" "),r("h1",{attrs:{id:"hierarchy"}},[r("a",{staticClass:"header-anchor",attrs:{href:"#hierarchy","aria-hidden":"true"}},[t._v("#")]),t._v(" Hierarchy")]),t._v(" "),r("p",[r("code",[t._v("Map")]),t._v("<"),r("code",[t._v("string")]),t._v(", "),r("code",[t._v("any")]),t._v(">")]),t._v(" "),r("p",[r("strong",[t._v("↳ ChainProperties")])]),t._v(" "),r("h1",{attrs:{id:"implements"}},[r("a",{staticClass:"header-anchor",attrs:{href:"#implements","aria-hidden":"true"}},[t._v("#")]),t._v(" Implements")]),t._v(" "),r("ul",[r("li",[r("router-link",{attrs:{to:"/types/interfaces/_types_.codec.html"}},[t._v("Codec")])],1)]),t._v(" "),r("h1",{attrs:{id:"constructors"}},[r("a",{staticClass:"header-anchor",attrs:{href:"#constructors","aria-hidden":"true"}},[t._v("#")]),t._v(" Constructors")]),t._v(" "),r("p",[r("a",{attrs:{id:"constructor"}})]),t._v(" "),r("h2",{attrs:{id:"constructor"}},[r("a",{staticClass:"header-anchor",attrs:{href:"#constructor","aria-hidden":"true"}},[t._v("#")]),t._v(" constructor")]),t._v(" "),r("p",[t._v("⊕ "),r("strong",[t._v("new ChainProperties")]),t._v("(value?: "),r("em",[r("code",[t._v("object")]),t._v(" | "),r("code",[t._v("null")])]),t._v("): "),r("router-link",{attrs:{to:"/types/classes/_type_chainproperties_.chainproperties.html"}},[t._v("ChainProperties")])],1),t._v(" "),r("p",[r("em",[t._v("Defined in "),r("a",{attrs:{href:"https://github.com/polkadot-js/api/blob/255b495/packages/types/src/type/ChainProperties.ts#L17",target:"_blank",rel:"noopener noreferrer"}},[t._v("type/ChainProperties.ts:17"),r("OutboundLink")],1)])]),t._v(" "),r("p",[r("strong",[t._v("Parameters:")])]),t._v(" "),r("table",[r("thead",[r("tr",[r("th",[t._v("Name")]),t._v(" "),r("th",[t._v("Type")])])]),t._v(" "),r("tbody",[r("tr",[r("td",[r("code",[t._v("Optional")]),t._v(" value")]),t._v(" "),r("td",[r("code",[t._v("object")]),t._v(" | "),r("code",[t._v("null")])])])])]),t._v(" "),r("p",[r("strong",[t._v("Returns:")]),t._v(" "),r("router-link",{attrs:{to:"/types/classes/_type_chainproperties_.chainproperties.html"}},[t._v("ChainProperties")])],1),t._v(" "),r("hr"),t._v(" "),r("h1",{attrs:{id:"properties"}},[r("a",{staticClass:"header-anchor",attrs:{href:"#properties","aria-hidden":"true"}},[t._v("#")]),t._v(" Properties")]),t._v(" "),r("p",[r("a",{attrs:{id:"map"}})]),t._v(" "),r("h2",{attrs:{id:"static-map"}},[r("a",{staticClass:"header-anchor",attrs:{href:"#static-map","aria-hidden":"true"}},[t._v("#")]),t._v(" "),r("code",[t._v("<Static>")]),t._v(" Map")]),t._v(" "),r("p",[r("strong",[t._v("● Map")]),t._v(": "),r("em",[r("code",[t._v("MapConstructor")])])]),t._v(" "),r("p",[r("em",[t._v("Defined in /home/travis/build/polkadot-js/api/node_modules/typescript/lib/lib.es2015.collection.d.ts:36")])]),t._v(" "),r("hr"),t._v(" "),r("h1",{attrs:{id:"accessors"}},[r("a",{staticClass:"header-anchor",attrs:{href:"#accessors","aria-hidden":"true"}},[t._v("#")]),t._v(" Accessors")]),t._v(" "),r("p",[r("a",{attrs:{id:"encodedlength"}})]),t._v(" "),r("h2",{attrs:{id:"encodedlength"}},[r("a",{staticClass:"header-anchor",attrs:{href:"#encodedlength","aria-hidden":"true"}},[t._v("#")]),t._v(" encodedLength")]),t._v(" "),r("p",[r("strong",[t._v("get encodedLength")]),t._v("(): "),r("code",[t._v("number")])]),t._v(" "),r("p",[r("em",[t._v("Defined in "),r("a",{attrs:{href:"https://github.com/polkadot-js/api/blob/255b495/packages/types/src/type/ChainProperties.ts#L29",target:"_blank",rel:"noopener noreferrer"}},[t._v("type/ChainProperties.ts:29"),r("OutboundLink")],1)])]),t._v(" "),r("p",[r("em",[r("strong",[t._v("description")])]),t._v(": Always 0, never encodes as a Uint8Array")]),t._v(" "),r("p",[r("strong",[t._v("Returns:")]),t._v(" "),r("code",[t._v("number")])]),t._v(" "),r("hr"),t._v(" "),r("p",[r("a",{attrs:{id:"isempty"}})]),t._v(" "),r("h2",{attrs:{id:"isempty"}},[r("a",{staticClass:"header-anchor",attrs:{href:"#isempty","aria-hidden":"true"}},[t._v("#")]),t._v(" isEmpty")]),t._v(" "),r("p",[r("strong",[t._v("get isEmpty")]),t._v("(): "),r("code",[t._v("boolean")])]),t._v(" "),r("p",[r("em",[t._v("Defined in "),r("a",{attrs:{href:"https://github.com/polkadot-js/api/blob/255b495/packages/types/src/type/ChainProperties.ts#L36",target:"_blank",rel:"noopener noreferrer"}},[t._v("type/ChainProperties.ts:36"),r("OutboundLink")],1)])]),t._v(" "),r("p",[r("em",[r("strong",[t._v("description")])]),t._v(": Checks if the value is an empty value")]),t._v(" "),r("p",[r("strong",[t._v("Returns:")]),t._v(" "),r("code",[t._v("boolean")])]),t._v(" "),r("hr"),t._v(" "),r("p",[r("a",{attrs:{id:"tokendecimals"}})]),t._v(" "),r("h2",{attrs:{id:"tokendecimals"}},[r("a",{staticClass:"header-anchor",attrs:{href:"#tokendecimals","aria-hidden":"true"}},[t._v("#")]),t._v(" tokenDecimals")]),t._v(" "),r("p",[r("strong",[t._v("get tokenDecimals")]),t._v("(): "),r("code",[t._v("number")]),t._v(" | "),r("code",[t._v("undefined")])]),t._v(" "),r("p",[r("em",[t._v("Defined in "),r("a",{attrs:{href:"https://github.com/polkadot-js/api/blob/255b495/packages/types/src/type/ChainProperties.ts#L43",target:"_blank",rel:"noopener noreferrer"}},[t._v("type/ChainProperties.ts:43"),r("OutboundLink")],1)])]),t._v(" "),r("p",[r("em",[r("strong",[t._v("description")])]),t._v(": The token decimals, if defined (de-facto standard only)")]),t._v(" "),r("p",[r("strong",[t._v("Returns:")]),t._v(" "),r("code",[t._v("number")]),t._v(" | "),r("code",[t._v("undefined")])]),t._v(" "),r("hr"),t._v(" "),r("p",[r("a",{attrs:{id:"tokensymbol"}})]),t._v(" "),r("h2",{attrs:{id:"tokensymbol"}},[r("a",{staticClass:"header-anchor",attrs:{href:"#tokensymbol","aria-hidden":"true"}},[t._v("#")]),t._v(" tokenSymbol")]),t._v(" "),r("p",[r("strong",[t._v("get tokenSymbol")]),t._v("(): "),r("code",[t._v("string")]),t._v(" | "),r("code",[t._v("undefined")])]),t._v(" "),r("p",[r("em",[t._v("Defined in "),r("a",{attrs:{href:"https://github.com/polkadot-js/api/blob/255b495/packages/types/src/type/ChainProperties.ts#L50",target:"_blank",rel:"noopener noreferrer"}},[t._v("type/ChainProperties.ts:50"),r("OutboundLink")],1)])]),t._v(" "),r("p",[r("em",[r("strong",[t._v("description")])]),t._v(": The token system, if defined (de-facto standard only)")]),t._v(" "),r("p",[r("strong",[t._v("Returns:")]),t._v(" "),r("code",[t._v("string")]),t._v(" | "),r("code",[t._v("undefined")])]),t._v(" "),r("hr"),t._v(" "),r("h1",{attrs:{id:"methods"}},[r("a",{staticClass:"header-anchor",attrs:{href:"#methods","aria-hidden":"true"}},[t._v("#")]),t._v(" Methods")]),t._v(" "),r("p",[r("a",{attrs:{id:"eq"}})]),t._v(" "),r("h2",{attrs:{id:"eq"}},[r("a",{staticClass:"header-anchor",attrs:{href:"#eq","aria-hidden":"true"}},[t._v("#")]),t._v(" eq")]),t._v(" "),r("p",[t._v("▸ "),r("strong",[t._v("eq")]),t._v("(other?: "),r("em",[r("code",[t._v("any")])]),t._v("): "),r("code",[t._v("boolean")])]),t._v(" "),r("p",[r("em",[t._v("Implementation of "),r("router-link",{attrs:{to:"/types/interfaces/_types_.codec.html"}},[t._v("Codec")]),t._v("."),r("router-link",{attrs:{to:"/types/interfaces/_types_.codec.html#eq"}},[t._v("eq")])],1)]),t._v(" "),r("p",[r("em",[t._v("Defined in "),r("a",{attrs:{href:"https://github.com/polkadot-js/api/blob/255b495/packages/types/src/type/ChainProperties.ts#L57",target:"_blank",rel:"noopener noreferrer"}},[t._v("type/ChainProperties.ts:57"),r("OutboundLink")],1)])]),t._v(" "),r("p",[r("em",[r("strong",[t._v("description")])]),t._v(": Compares the value of the input to see if there is a match")]),t._v(" "),r("p",[r("strong",[t._v("Parameters:")])]),t._v(" "),r("table",[r("thead",[r("tr",[r("th",[t._v("Name")]),t._v(" "),r("th",[t._v("Type")])])]),t._v(" "),r("tbody",[r("tr",[r("td",[r("code",[t._v("Optional")]),t._v(" other")]),t._v(" "),r("td",[r("code",[t._v("any")])])])])]),t._v(" "),r("p",[r("strong",[t._v("Returns:")]),t._v(" "),r("code",[t._v("boolean")])]),t._v(" "),r("hr"),t._v(" "),r("p",[r("a",{attrs:{id:"tohex"}})]),t._v(" "),r("h2",{attrs:{id:"tohex"}},[r("a",{staticClass:"header-anchor",attrs:{href:"#tohex","aria-hidden":"true"}},[t._v("#")]),t._v(" toHex")]),t._v(" "),r("p",[t._v("▸ "),r("strong",[t._v("toHex")]),t._v("(): "),r("code",[t._v("string")])]),t._v(" "),r("p",[r("em",[t._v("Implementation of "),r("router-link",{attrs:{to:"/types/interfaces/_types_.codec.html"}},[t._v("Codec")]),t._v("."),r("router-link",{attrs:{to:"/types/interfaces/_types_.codec.html#tohex"}},[t._v("toHex")])],1)]),t._v(" "),r("p",[r("em",[t._v("Defined in "),r("a",{attrs:{href:"https://github.com/polkadot-js/api/blob/255b495/packages/types/src/type/ChainProperties.ts#L64",target:"_blank",rel:"noopener noreferrer"}},[t._v("type/ChainProperties.ts:64"),r("OutboundLink")],1)])]),t._v(" "),r("p",[r("em",[r("strong",[t._v("description")])]),t._v(": Unimplemented, will throw")]),t._v(" "),r("p",[r("strong",[t._v("Returns:")]),t._v(" "),r("code",[t._v("string")])]),t._v(" "),r("hr"),t._v(" "),r("p",[r("a",{attrs:{id:"tojson"}})]),t._v(" "),r("h2",{attrs:{id:"tojson"}},[r("a",{staticClass:"header-anchor",attrs:{href:"#tojson","aria-hidden":"true"}},[t._v("#")]),t._v(" toJSON")]),t._v(" "),r("p",[t._v("▸ "),r("strong",[t._v("toJSON")]),t._v("(): "),r("code",[t._v("any")])]),t._v(" "),r("p",[r("em",[t._v("Implementation of "),r("router-link",{attrs:{to:"/types/interfaces/_types_.codec.html"}},[t._v("Codec")]),t._v("."),r("router-link",{attrs:{to:"/types/interfaces/_types_.codec.html#tojson"}},[t._v("toJSON")])],1)]),t._v(" "),r("p",[r("em",[t._v("Defined in "),r("a",{attrs:{href:"https://github.com/polkadot-js/api/blob/255b495/packages/types/src/type/ChainProperties.ts#L71",target:"_blank",rel:"noopener noreferrer"}},[t._v("type/ChainProperties.ts:71"),r("OutboundLink")],1)])]),t._v(" "),r("p",[r("em",[r("strong",[t._v("description")])]),t._v(": Converts the Object to JSON, typically used for RPC transfers")]),t._v(" "),r("p",[r("strong",[t._v("Returns:")]),t._v(" "),r("code",[t._v("any")])]),t._v(" "),r("hr"),t._v(" "),r("p",[r("a",{attrs:{id:"tostring"}})]),t._v(" "),r("h2",{attrs:{id:"tostring"}},[r("a",{staticClass:"header-anchor",attrs:{href:"#tostring","aria-hidden":"true"}},[t._v("#")]),t._v(" toString")]),t._v(" "),r("p",[t._v("▸ "),r("strong",[t._v("toString")]),t._v("(): "),r("code",[t._v("string")])]),t._v(" "),r("p",[r("em",[t._v("Implementation of "),r("router-link",{attrs:{to:"/types/interfaces/_types_.codec.html"}},[t._v("Codec")]),t._v("."),r("router-link",{attrs:{to:"/types/interfaces/_types_.codec.html#tostring"}},[t._v("toString")])],1)]),t._v(" "),r("p",[r("em",[t._v("Defined in "),r("a",{attrs:{href:"https://github.com/polkadot-js/api/blob/255b495/packages/types/src/type/ChainProperties.ts#L82",target:"_blank",rel:"noopener noreferrer"}},[t._v("type/ChainProperties.ts:82"),r("OutboundLink")],1)])]),t._v(" "),r("p",[r("em",[r("strong",[t._v("description")])]),t._v(": Returns the string representation of the value")]),t._v(" "),r("p",[r("strong",[t._v("Returns:")]),t._v(" "),r("code",[t._v("string")])]),t._v(" "),r("hr"),t._v(" "),r("p",[r("a",{attrs:{id:"tou8a"}})]),t._v(" "),r("h2",{attrs:{id:"tou8a"}},[r("a",{staticClass:"header-anchor",attrs:{href:"#tou8a","aria-hidden":"true"}},[t._v("#")]),t._v(" toU8a")]),t._v(" "),r("p",[t._v("▸ "),r("strong",[t._v("toU8a")]),t._v("(isBare?: "),r("em",[r("code",[t._v("undefined")]),t._v(" | "),r("code",[t._v("false")]),t._v(" | "),r("code",[t._v("true")])]),t._v("): "),r("code",[t._v("Uint8Array")])]),t._v(" "),r("p",[r("em",[t._v("Implementation of "),r("router-link",{attrs:{to:"/types/interfaces/_types_.codec.html"}},[t._v("Codec")]),t._v("."),r("router-link",{attrs:{to:"/types/interfaces/_types_.codec.html#tou8a"}},[t._v("toU8a")])],1)]),t._v(" "),r("p",[r("em",[t._v("Defined in "),r("a",{attrs:{href:"https://github.com/polkadot-js/api/blob/255b495/packages/types/src/type/ChainProperties.ts#L89",target:"_blank",rel:"noopener noreferrer"}},[t._v("type/ChainProperties.ts:89"),r("OutboundLink")],1)])]),t._v(" "),r("p",[r("em",[r("strong",[t._v("description")])]),t._v(": Unimplemented, will throw")]),t._v(" "),r("p",[r("strong",[t._v("Parameters:")])]),t._v(" "),r("table",[r("thead",[r("tr",[r("th",[t._v("Name")]),t._v(" "),r("th",[t._v("Type")])])]),t._v(" "),r("tbody",[r("tr",[r("td",[r("code",[t._v("Optional")]),t._v(" isBare")]),t._v(" "),r("td",[r("code",[t._v("undefined")]),t._v(" | "),r("code",[t._v("false")]),t._v(" | "),r("code",[t._v("true")])])])])]),t._v(" "),r("p",[r("strong",[t._v("Returns:")]),t._v(" "),r("code",[t._v("Uint8Array")])]),t._v(" "),r("hr")])},[],!1,null,null,null);e.default=a.exports}}]);