chariot.js
Version:
An extremely lightweight and extensible Eris client framework
1 lines • 14.2 kB
JavaScript
(window.webpackJsonp=window.webpackJsonp||[]).push([[17],{204:function(t,e,r){"use strict";r.r(e);var s=r(0),a=Object(s.a)({},(function(){var t=this,e=t.$createElement,r=t._self._c||e;return r("div",{staticClass:"content"},[r("h1",{attrs:{id:"client-extends-eris-client"}},[r("a",{staticClass:"header-anchor",attrs:{href:"#client-extends-eris-client"}},[t._v("#")]),t._v(" Client "),r("span",{staticStyle:{"font-size":".5em"}},[t._v("extends "),r("a",{attrs:{href:"https://abal.moe/Eris/docs/Client",target:"_blank",rel:"noopener noreferrer"}},[t._v("Eris.Client"),r("OutboundLink")],1)]),t._v(" "),r("Badge",{attrs:{text:"Abstract",type:"chariot"}})],1),t._v(" "),t._m(0),t._v(" "),r("p",[t._v("An example project along with highly detailed explanations and tips can be found within the "),r("strong",[t._v("Examples")]),t._v(" section "),r("router-link",{attrs:{to:"./../examples/project.html"}},[t._v("here.")])],1),t._v(" "),t._m(1),t._v(" "),t._m(2),t._v(" "),r("div",{staticClass:"table"},[r("table",[t._m(3),t._v(" "),r("tbody",[r("tr",[t._m(4),t._v(" "),r("td",[r("router-link",{attrs:{to:"./config.html"}},[t._v("Config")])],1),t._v(" "),r("td",[r("Fa-Times")],1),t._v(" "),r("td",[t._v("N/A")]),t._v(" "),r("td",[t._v("A valid Chariot.js config class object")])])])])]),t._v(" "),t._m(5),t._v(" "),r("div",{attrs:{id:"properties"}},[r("h3",{attrs:{id:"prefix"}},[r("a",{staticClass:"header-anchor",attrs:{href:"#prefix"}},[t._v("#")]),t._v(" prefix "),r("Badge",{attrs:{text:"Read Only",type:"chariot"}})],1),t._v(" "),r("property",{attrs:{"property-description":"The prefixes Chariot.js was instantiated with","property-type":"Array<String>","property-type-url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String"}}),t._v(" "),r("h3",{attrs:{id:"guildprefixes"}},[r("a",{staticClass:"header-anchor",attrs:{href:"#guildprefixes"}},[t._v("#")]),t._v(" guildPrefixes "),r("Badge",{attrs:{text:"Read Only",type:"chariot"}})],1),t._v(" "),r("property",{attrs:{"property-description":"All per-guild specific prefixes Chariot.js was instantiated with","property-type":"Array<Object>","property-type-url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object"}}),t._v(" "),r("h3",{attrs:{id:"commands"}},[r("a",{staticClass:"header-anchor",attrs:{href:"#commands"}},[t._v("#")]),t._v(" commands "),r("Badge",{attrs:{text:"Read Only",type:"chariot"}})],1),t._v(" "),r("property",{attrs:{"property-description":"The internal collection of all validly registered Chariot.js commands mapped by their instantiation name.","property-type":"Collection<Chariot.Command>","property-type-url":"command.html"}}),t._v(" "),t._m(6),t._v(" "),r("property",{attrs:{"property-description":"Whether the bot user belongs to an OAuth2 application","property-type":"Boolean","property-type-url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Boolean"}}),t._v(" "),t._m(7),t._v(" "),r("property",{attrs:{"property-description":"Object mapping channel IDs to guild IDs","property-type":"Object","property-type-url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object"}}),t._v(" "),t._m(8),t._v(" "),r("property",{attrs:{"property-description":"Collection of group channels the bot is in (user accounts only)","property-type":"Collection<GroupChannel>","property-type-url":"https://abal.moe/Eris/docs/GroupChannel"}}),t._v(" "),t._m(9),t._v(" "),r("property",{attrs:{"property-description":"Collection of guilds the bot is in","property-type":"Collection<Guild>","property-type-url":"https://abal.moe/Eris/docs/Guild"}}),t._v(" "),t._m(10),t._v(" "),r("property",{attrs:{"property-description":"Object mapping guild IDs to shard IDs","property-type":"Object","property-type-url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object"}}),t._v(" "),t._m(11),t._v(" "),r("property",{attrs:{"property-description":"Object mapping user IDs to user notes (user accounts only)","property-type":"Object","property-type-url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object"}}),t._v(" "),t._m(12),t._v(" "),r("property",{attrs:{"property-description":"Eris options","property-type":"Object","property-type-url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object"}}),t._v(" "),t._m(13),t._v(" "),r("property",{attrs:{"property-description":"Object mapping user IDs to private channel IDs","property-type":"Object","property-type-url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object"}}),t._v(" "),t._m(14),t._v(" "),r("property",{attrs:{"property-description":"Collection of private channels the bot is in","property-type":"Collection<PrivateChannel>","property-type-url":"https://abal.moe/Eris/docs/PrivateChannel"}}),t._v(" "),t._m(15),t._v(" "),r("property",{attrs:{"property-description":"Collection of relationships the bot user has (user accounts only)","property-type":"Collection<Relationship>","property-type-url":"https://abal.moe/Eris/docs/Relationship"}}),t._v(" "),t._m(16),t._v(" "),r("property",{attrs:{"property-description":"Collection of shards Eris is using","property-type":"Collection<Shard>","property-type-url":"https://abal.moe/Eris/docs/Shard"}}),t._v(" "),t._m(17),t._v(" "),r("property",{attrs:{"property-description":"Timestamp of bot ready event","property-type":"Number","property-type-url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Number"}}),t._v(" "),t._m(18),t._v(" "),r("property",{attrs:{"property-description":"The bot user token","property-type":"String","property-type-url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String"}}),t._v(" "),t._m(19),t._v(" "),r("property",{attrs:{"property-description":"Collection of unavailable guilds the bot is in","property-type":"Collection<UnavailableGuilds>","property-type-url":"https://abal.moe/Eris/docs/UnavailableGuild"}}),t._v(" "),t._m(20),t._v(" "),r("property",{attrs:{"property-description":"How long in milliseconds the bot has been up for","property-type":"Number","property-type-url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Number"}}),t._v(" "),t._m(21),t._v(" "),r("property",{attrs:{"property-description":"The bot user","property-type":"ExtendedUser","property-type-url":"https://abal.moe/Eris/docs/ExtendedUser"}}),t._v(" "),t._m(22),t._v(" "),r("property",{attrs:{"property-description":"Object mapping guild IDs to individual guild settings for the bot user (user accounts only)","property-type":"Object","property-type-url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object"}}),t._v(" "),t._m(23),t._v(" "),r("property",{attrs:{"property-description":"Collection of users the bot sees","property-type":"Collection<User>","property-type-url":"https://abal.moe/Eris/docs/User"}}),t._v(" "),t._m(24),t._v(" "),r("property",{attrs:{"property-description":"Object containing the user account settings (user accounts only)","property-type":"Object","property-type-url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object"}}),t._v(" "),t._m(25),t._v(" "),r("property",{attrs:{"property-description":"Extended collection of active VoiceConnections the bot has","property-type":"Collection<VoiceConnection>","property-tail":"true","property-type-url":"https://abal.moe/Eris/docs/VoiceConnection"}})],1),t._v(" "),t._m(26),t._v(" "),r("p",[t._v("Please reference "),r("a",{attrs:{href:"https://abal.moe/Eris/docs/Client",target:"_blank",rel:"noopener noreferrer"}},[t._v("Eris.Client"),r("OutboundLink")],1),t._v(" for a full method reference. The Chariot.js client does "),r("strong",[t._v("not")]),t._v(" expose any usable "),r("strong",[t._v("public")]),t._v(" methods.")]),t._v(" "),t._m(27),t._v(" "),r("p",[t._v("Please reference "),r("a",{attrs:{href:"https://abal.moe/Eris/docs/Client",target:"_blank",rel:"noopener noreferrer"}},[t._v("Eris.Client"),r("OutboundLink")],1),t._v(" for a full event reference. The Chariot.js client does "),r("strong",[t._v("not")]),t._v(" expose any usable "),r("strong",[t._v("public")]),t._v(" events.")])])}),[function(){var t=this,e=t.$createElement,r=t._self._c||e;return r("p",[t._v("The main "),r("strong",[t._v("Chariot.js")]),t._v(" abstract base client class extending the Eris client. Every new bot created "),r("strong",[t._v("must")]),t._v(" extend this class. This class should "),r("strong",[t._v("never")]),t._v(" be instantiated "),r("em",[t._v("as-is")]),t._v(" without being extended as this might introduce unexpected behavior.")])},function(){var t=this.$createElement,e=this._self._c||t;return e("h2",{attrs:{id:"constructor"}},[e("a",{staticClass:"header-anchor",attrs:{href:"#constructor"}},[this._v("#")]),this._v(" Constructor")])},function(){var t=this.$createElement,e=this._self._c||t;return e("p",[this._v("Instantiation: "),e("span",{staticStyle:{"font-weight":"bold"}},[e("code",[this._v("new Client(chariotConfig);")])])])},function(){var t=this,e=t.$createElement,r=t._self._c||e;return r("thead",[r("tr",[r("th",[t._v("Parameter")]),t._v(" "),r("th",[t._v("Type")]),t._v(" "),r("th",[t._v("Optional")]),t._v(" "),r("th",[t._v("Default")]),t._v(" "),r("th",[t._v("Description")])])])},function(){var t=this.$createElement,e=this._self._c||t;return e("td",[e("code",[this._v("chariotConfig")])])},function(){var t=this.$createElement,e=this._self._c||t;return e("h2",{attrs:{id:"properties"}},[e("a",{staticClass:"header-anchor",attrs:{href:"#properties"}},[this._v("#")]),this._v(" Properties")])},function(){var t=this.$createElement,e=this._self._c||t;return e("h3",{attrs:{id:"bot"}},[e("a",{staticClass:"header-anchor",attrs:{href:"#bot"}},[this._v("#")]),this._v(" bot")])},function(){var t=this.$createElement,e=this._self._c||t;return e("h3",{attrs:{id:"channelguildmap"}},[e("a",{staticClass:"header-anchor",attrs:{href:"#channelguildmap"}},[this._v("#")]),this._v(" channelGuildMap")])},function(){var t=this.$createElement,e=this._self._c||t;return e("h3",{attrs:{id:"groupchannels"}},[e("a",{staticClass:"header-anchor",attrs:{href:"#groupchannels"}},[this._v("#")]),this._v(" groupChannels")])},function(){var t=this.$createElement,e=this._self._c||t;return e("h3",{attrs:{id:"guilds"}},[e("a",{staticClass:"header-anchor",attrs:{href:"#guilds"}},[this._v("#")]),this._v(" guilds")])},function(){var t=this.$createElement,e=this._self._c||t;return e("h3",{attrs:{id:"guildshardmap"}},[e("a",{staticClass:"header-anchor",attrs:{href:"#guildshardmap"}},[this._v("#")]),this._v(" guildShardMap")])},function(){var t=this.$createElement,e=this._self._c||t;return e("h3",{attrs:{id:"notes"}},[e("a",{staticClass:"header-anchor",attrs:{href:"#notes"}},[this._v("#")]),this._v(" notes")])},function(){var t=this.$createElement,e=this._self._c||t;return e("h3",{attrs:{id:"options"}},[e("a",{staticClass:"header-anchor",attrs:{href:"#options"}},[this._v("#")]),this._v(" options")])},function(){var t=this.$createElement,e=this._self._c||t;return e("h3",{attrs:{id:"privatechannelmap"}},[e("a",{staticClass:"header-anchor",attrs:{href:"#privatechannelmap"}},[this._v("#")]),this._v(" privateChannelMap")])},function(){var t=this.$createElement,e=this._self._c||t;return e("h3",{attrs:{id:"privatechannels"}},[e("a",{staticClass:"header-anchor",attrs:{href:"#privatechannels"}},[this._v("#")]),this._v(" privateChannels")])},function(){var t=this.$createElement,e=this._self._c||t;return e("h3",{attrs:{id:"relationships"}},[e("a",{staticClass:"header-anchor",attrs:{href:"#relationships"}},[this._v("#")]),this._v(" relationships")])},function(){var t=this.$createElement,e=this._self._c||t;return e("h3",{attrs:{id:"shards"}},[e("a",{staticClass:"header-anchor",attrs:{href:"#shards"}},[this._v("#")]),this._v(" shards")])},function(){var t=this.$createElement,e=this._self._c||t;return e("h3",{attrs:{id:"starttime"}},[e("a",{staticClass:"header-anchor",attrs:{href:"#starttime"}},[this._v("#")]),this._v(" startTime")])},function(){var t=this.$createElement,e=this._self._c||t;return e("h3",{attrs:{id:"token"}},[e("a",{staticClass:"header-anchor",attrs:{href:"#token"}},[this._v("#")]),this._v(" token")])},function(){var t=this.$createElement,e=this._self._c||t;return e("h3",{attrs:{id:"unavailableguilds"}},[e("a",{staticClass:"header-anchor",attrs:{href:"#unavailableguilds"}},[this._v("#")]),this._v(" unavailableGuilds")])},function(){var t=this.$createElement,e=this._self._c||t;return e("h3",{attrs:{id:"uptime"}},[e("a",{staticClass:"header-anchor",attrs:{href:"#uptime"}},[this._v("#")]),this._v(" uptime")])},function(){var t=this.$createElement,e=this._self._c||t;return e("h3",{attrs:{id:"user"}},[e("a",{staticClass:"header-anchor",attrs:{href:"#user"}},[this._v("#")]),this._v(" user")])},function(){var t=this.$createElement,e=this._self._c||t;return e("h3",{attrs:{id:"userguildsettings"}},[e("a",{staticClass:"header-anchor",attrs:{href:"#userguildsettings"}},[this._v("#")]),this._v(" userGuildSettings")])},function(){var t=this.$createElement,e=this._self._c||t;return e("h3",{attrs:{id:"users"}},[e("a",{staticClass:"header-anchor",attrs:{href:"#users"}},[this._v("#")]),this._v(" users")])},function(){var t=this.$createElement,e=this._self._c||t;return e("h3",{attrs:{id:"usersettings"}},[e("a",{staticClass:"header-anchor",attrs:{href:"#usersettings"}},[this._v("#")]),this._v(" userSettings")])},function(){var t=this.$createElement,e=this._self._c||t;return e("h3",{attrs:{id:"voiceconnections"}},[e("a",{staticClass:"header-anchor",attrs:{href:"#voiceconnections"}},[this._v("#")]),this._v(" voiceConnections")])},function(){var t=this.$createElement,e=this._self._c||t;return e("h2",{attrs:{id:"methods"}},[e("a",{staticClass:"header-anchor",attrs:{href:"#methods"}},[this._v("#")]),this._v(" Methods")])},function(){var t=this.$createElement,e=this._self._c||t;return e("h2",{attrs:{id:"events"}},[e("a",{staticClass:"header-anchor",attrs:{href:"#events"}},[this._v("#")]),this._v(" Events")])}],!1,null,null,null);e.default=a.exports}}]);