dyo-tools 0.1.0-rc1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.c8rc.json +4 -0
- package/.eslintignore +2 -0
- package/.eslintrc.json +41 -0
- package/Makefile +34 -0
- package/README.md +0 -0
- package/TODO.md +18 -0
- package/babel.config.js +1 -0
- package/dist/core/DTBunch.d.ts +32 -0
- package/dist/core/DTBunch.js +283 -0
- package/dist/core/DTBunch.js.map +1 -0
- package/dist/core/DTComponent.d.ts +20 -0
- package/dist/core/DTComponent.js +41 -0
- package/dist/core/DTComponent.js.map +1 -0
- package/dist/core/DTComponentWithMeta.d.ts +9 -0
- package/dist/core/DTComponentWithMeta.js +32 -0
- package/dist/core/DTComponentWithMeta.js.map +1 -0
- package/dist/core/DTElement.d.ts +13 -0
- package/dist/core/DTElement.js +46 -0
- package/dist/core/DTElement.js.map +1 -0
- package/dist/core/DTError.d.ts +13 -0
- package/dist/core/DTError.js +28 -0
- package/dist/core/DTError.js.map +1 -0
- package/dist/core/DTPlayer.d.ts +8 -0
- package/dist/core/DTPlayer.js +30 -0
- package/dist/core/DTPlayer.js.map +1 -0
- package/dist/index.d.ts +6 -0
- package/dist/index.js +16 -0
- package/dist/index.js.map +1 -0
- package/dist/tsconfig.tsbuildinfo +1321 -0
- package/dist/types/index.d.ts +58 -0
- package/dist/types/index.js +15 -0
- package/dist/types/index.js.map +1 -0
- package/dist/utils/filters.d.ts +6 -0
- package/dist/utils/filters.js +39 -0
- package/dist/utils/filters.js.map +1 -0
- package/docs/.nojekyll +1 -0
- package/docs/assets/highlight.css +22 -0
- package/docs/assets/icons.css +1043 -0
- package/docs/assets/icons.png +0 -0
- package/docs/assets/icons@2x.png +0 -0
- package/docs/assets/main.js +52 -0
- package/docs/assets/search.js +1 -0
- package/docs/assets/style.css +1388 -0
- package/docs/assets/widgets.png +0 -0
- package/docs/assets/widgets@2x.png +0 -0
- package/docs/classes/DTBunch.html +265 -0
- package/docs/classes/DTComponent.html +49 -0
- package/docs/classes/DTComponentWithMeta.html +73 -0
- package/docs/classes/DTElement.html +95 -0
- package/docs/classes/DTError.html +32 -0
- package/docs/classes/DTPlayer.html +86 -0
- package/docs/index.html +1 -0
- package/docs/modules.html +1 -0
- package/jest.config.js +6 -0
- package/package.json +41 -0
- package/src/core/DTBunch.ts +600 -0
- package/src/core/DTComponent.ts +135 -0
- package/src/core/DTComponentWithMeta.ts +62 -0
- package/src/core/DTElement.ts +96 -0
- package/src/core/DTError.ts +78 -0
- package/src/core/DTPlayer.ts +57 -0
- package/src/index.ts +7 -0
- package/src/types/index.ts +76 -0
- package/src/utils/filters.ts +64 -0
- package/test/core/DTBunch.double.ts +150 -0
- package/test/core/DTBunch.spec.ts +1374 -0
- package/test/core/DTComponent.double.ts +69 -0
- package/test/core/DTComponent.spec.ts +182 -0
- package/test/core/DTComponentWithMeta.double.ts +88 -0
- package/test/core/DTComponentWithMeta.spec.ts +112 -0
- package/test/core/DTElement.double.ts +27 -0
- package/test/core/DTElement.spec.ts +181 -0
- package/test/core/DTError.double.ts +43 -0
- package/test/core/DTError.spec.ts +106 -0
- package/test/core/DTPlayer.double.ts +49 -0
- package/test/core/DTPlayer.spec.ts +102 -0
- package/test/utils/filters.spec.ts +109 -0
- package/tsconfig.json +21 -0
|
@@ -0,0 +1,86 @@
|
|
|
1
|
+
<!DOCTYPE html><html class="default"><head><meta charSet="utf-8"/><meta http-equiv="x-ua-compatible" content="IE=edge"/><title>DTPlayer | dyo-tools</title><meta name="description" content="Documentation for dyo-tools"/><meta name="viewport" content="width=device-width, initial-scale=1"/><link rel="stylesheet" href="../assets/style.css"/><link rel="stylesheet" href="../assets/highlight.css"/><script async src="../assets/search.js" id="search-script"></script></head><body><script>document.body.classList.add(localStorage.getItem("tsd-theme") || "os")</script><header><div class="tsd-page-toolbar"><div class="container"><div class="table-wrap"><div class="table-cell" id="tsd-search" data-base=".."><div class="field"><label for="tsd-search-field" class="tsd-widget search no-caption">Search</label><input type="text" id="tsd-search-field"/></div><ul class="results"><li class="state loading">Preparing search index...</li><li class="state failure">The search index is not available</li></ul><a href="../index.html" class="title">dyo-tools</a></div><div class="table-cell" id="tsd-widgets"><div id="tsd-filter"><a href="#" class="tsd-widget options no-caption" data-toggle="options">Options</a><div class="tsd-filter-group"><div class="tsd-select" id="tsd-filter-visibility"><span class="tsd-select-label">All</span><ul class="tsd-select-list"><li data-value="public">Public</li><li data-value="protected">Public/Protected</li><li data-value="private" class="selected">All</li></ul></div> <input type="checkbox" id="tsd-filter-inherited" checked/><label class="tsd-widget" for="tsd-filter-inherited">Inherited</label><input type="checkbox" id="tsd-filter-externals" checked/><label class="tsd-widget" for="tsd-filter-externals">Externals</label></div></div><a href="#" class="tsd-widget menu no-caption" data-toggle="menu">Menu</a></div></div></div></div><div class="tsd-page-title"><div class="container"><ul class="tsd-breadcrumb"><li><a href="../modules.html">dyo-tools</a></li><li><a href="DTPlayer.html">DTPlayer</a></li></ul><h1>Class DTPlayer<IComponentMeta></h1></div></div></header><div class="container container-main"><div class="row"><div class="col-8 col-content"><section class="tsd-panel tsd-type-parameters"><h3>Type parameters</h3><ul class="tsd-type-parameters"><li><h4>IComponentMeta<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">DTAcceptedMetaData</span></h4></li></ul></section><section class="tsd-panel tsd-hierarchy"><h3>Hierarchy</h3><ul class="tsd-hierarchy"><li><a href="DTComponentWithMeta.html" class="tsd-signature-type" data-tsd-kind="Class">DTComponentWithMeta</a><span class="tsd-signature-symbol"><</span><span class="tsd-signature-type" data-tsd-kind="Type parameter">IComponentMeta</span><span class="tsd-signature-symbol">></span><ul class="tsd-hierarchy"><li><span class="target">DTPlayer</span></li></ul></li></ul></section><section class="tsd-panel-group tsd-index-group"><h2>Index</h2><section class="tsd-panel tsd-index-panel"><div class="tsd-index-content"><section class="tsd-index-section tsd-is-inherited"><h3>Constructors</h3><ul class="tsd-index-list"><li class="tsd-kind-constructor tsd-parent-kind-class tsd-has-type-parameter tsd-is-inherited"><a href="DTPlayer.html#constructor" class="tsd-kind-icon">constructor</a></li></ul></section><section class="tsd-index-section tsd-is-private-protected"><h3>Properties</h3><ul class="tsd-index-list"><li class="tsd-kind-property tsd-parent-kind-class tsd-is-overwrite tsd-is-protected"><a href="DTPlayer.html#_componentType" class="tsd-kind-icon">_component<wbr/>Type</a></li><li class="tsd-kind-property tsd-parent-kind-class tsd-is-inherited tsd-is-protected"><a href="DTPlayer.html#_context" class="tsd-kind-icon">_context</a></li><li class="tsd-kind-property tsd-parent-kind-class tsd-is-inherited tsd-is-protected"><a href="DTPlayer.html#_domain" class="tsd-kind-icon">_domain</a></li><li class="tsd-kind-property tsd-parent-kind-class tsd-is-inherited tsd-is-protected"><a href="DTPlayer.html#_id" class="tsd-kind-icon">_id</a></li><li class="tsd-kind-property tsd-parent-kind-class tsd-is-inherited tsd-is-protected"><a href="DTPlayer.html#_key" class="tsd-kind-icon">_key</a></li><li class="tsd-kind-property tsd-parent-kind-class tsd-is-inherited tsd-is-protected"><a href="DTPlayer.html#_meta" class="tsd-kind-icon">_meta</a></li><li class="tsd-kind-property tsd-parent-kind-class tsd-is-inherited tsd-is-protected"><a href="DTPlayer.html#_subKind" class="tsd-kind-icon">_sub<wbr/>Kind</a></li></ul></section><section class="tsd-index-section "><h3>Methods</h3><ul class="tsd-index-list"><li class="tsd-kind-method tsd-parent-kind-class tsd-is-overwrite"><a href="DTPlayer.html#copy" class="tsd-kind-icon">copy</a></li><li class="tsd-kind-method tsd-parent-kind-class tsd-is-inherited"><a href="DTPlayer.html#getComponentType" class="tsd-kind-icon">get<wbr/>Component<wbr/>Type</a></li><li class="tsd-kind-method tsd-parent-kind-class tsd-is-inherited"><a href="DTPlayer.html#getContext" class="tsd-kind-icon">get<wbr/>Context</a></li><li class="tsd-kind-method tsd-parent-kind-class tsd-is-inherited"><a href="DTPlayer.html#getDomain" class="tsd-kind-icon">get<wbr/>Domain</a></li><li class="tsd-kind-method tsd-parent-kind-class tsd-is-inherited"><a href="DTPlayer.html#getId" class="tsd-kind-icon">get<wbr/>Id</a></li><li class="tsd-kind-method tsd-parent-kind-class tsd-is-inherited"><a href="DTPlayer.html#getKey" class="tsd-kind-icon">get<wbr/>Key</a></li><li class="tsd-kind-method tsd-parent-kind-class tsd-is-inherited"><a href="DTPlayer.html#getManyMeta" class="tsd-kind-icon">get<wbr/>Many<wbr/>Meta</a></li><li class="tsd-kind-method tsd-parent-kind-class tsd-has-type-parameter tsd-is-inherited"><a href="DTPlayer.html#getMeta" class="tsd-kind-icon">get<wbr/>Meta</a></li><li class="tsd-kind-method tsd-parent-kind-class tsd-is-inherited"><a href="DTPlayer.html#getSubKind" class="tsd-kind-icon">get<wbr/>Sub<wbr/>Kind</a></li><li class="tsd-kind-method tsd-parent-kind-class tsd-is-inherited"><a href="DTPlayer.html#removeContext" class="tsd-kind-icon">remove<wbr/>Context</a></li><li class="tsd-kind-method tsd-parent-kind-class tsd-is-inherited"><a href="DTPlayer.html#setContext" class="tsd-kind-icon">set<wbr/>Context</a></li><li class="tsd-kind-method tsd-parent-kind-class tsd-is-inherited"><a href="DTPlayer.html#setManyMeta" class="tsd-kind-icon">set<wbr/>Many<wbr/>Meta</a></li><li class="tsd-kind-method tsd-parent-kind-class tsd-has-type-parameter tsd-is-inherited"><a href="DTPlayer.html#setMeta" class="tsd-kind-icon">set<wbr/>Meta</a></li><li class="tsd-kind-method tsd-parent-kind-class tsd-is-overwrite"><a href="DTPlayer.html#toObject" class="tsd-kind-icon">to<wbr/>Object</a></li><li class="tsd-kind-method tsd-parent-kind-class tsd-is-overwrite"><a href="DTPlayer.html#toString" class="tsd-kind-icon">to<wbr/>String</a></li></ul></section></div></section></section><section class="tsd-panel-group tsd-member-group tsd-is-inherited"><h2>Constructors</h2><section class="tsd-panel tsd-member tsd-kind-constructor tsd-parent-kind-class tsd-has-type-parameter tsd-is-inherited"><a id="constructor" class="tsd-anchor"></a><h3>constructor</h3><ul class="tsd-signatures tsd-kind-constructor tsd-parent-kind-class tsd-has-type-parameter tsd-is-inherited"><li class="tsd-signature tsd-kind-icon">new DTPlayer<span class="tsd-signature-symbol"><</span><span class="tsd-signature-type" data-tsd-kind="Type parameter">IComponentMeta</span><span class="tsd-signature-symbol">></span><span class="tsd-signature-symbol">(</span>key<span class="tsd-signature-symbol">?: </span><span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><a href="DTPlayer.html" class="tsd-signature-type" data-tsd-kind="Class">DTPlayer</a><span class="tsd-signature-symbol"><</span><span class="tsd-signature-type" data-tsd-kind="Type parameter">IComponentMeta</span><span class="tsd-signature-symbol">></span></li></ul><ul class="tsd-descriptions"><li class="tsd-description"><aside class="tsd-sources"><p>Inherited from <a href="DTComponentWithMeta.html">DTComponentWithMeta</a>.<a href="DTComponentWithMeta.html#constructor">constructor</a></p><ul><li>Defined in <a href="https://gitlab.com/flaya-dyo/dyo-tools/core/-/blob/9b29d44/src/core/DTComponent.ts#L48">src/core/DTComponent.ts:48</a></li></ul></aside><div class="tsd-comment tsd-typography"><div class="lead">
|
|
2
|
+
<p>Set automatic unique _id and _key.</p>
|
|
3
|
+
</div></div><h4 class="tsd-type-parameters-title">Type parameters</h4><ul class="tsd-type-parameters"><li><h4>IComponentMeta<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">DTAcceptedMetaData</span></h4></li></ul><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameters"><li><h5><span class="tsd-flag ts-flagOptional">Optional</span> key: <span class="tsd-signature-type">string</span></h5><div class="tsd-comment tsd-typography"><div class="lead">
|
|
4
|
+
<p>Optional Key to set. If not provided, set the _key with the _id value.</p>
|
|
5
|
+
</div></div></li></ul><h4 class="tsd-returns-title">Returns <a href="DTPlayer.html" class="tsd-signature-type" data-tsd-kind="Class">DTPlayer</a><span class="tsd-signature-symbol"><</span><span class="tsd-signature-type" data-tsd-kind="Type parameter">IComponentMeta</span><span class="tsd-signature-symbol">></span></h4></li></ul></section></section><section class="tsd-panel-group tsd-member-group tsd-is-private-protected"><h2>Properties</h2><section class="tsd-panel tsd-member tsd-kind-property tsd-parent-kind-class tsd-is-overwrite tsd-is-protected"><a id="_componentType" class="tsd-anchor"></a><h3><span class="tsd-flag ts-flagProtected">Protected</span> _component<wbr/>Type</h3><div class="tsd-signature tsd-kind-icon">_component<wbr/>Type<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol"> = 'player'</span></div><aside class="tsd-sources"><p>Overrides <a href="DTComponentWithMeta.html">DTComponentWithMeta</a>.<a href="DTComponentWithMeta.html#_componentType">_componentType</a></p><ul><li>Defined in <a href="https://gitlab.com/flaya-dyo/dyo-tools/core/-/blob/9b29d44/src/core/DTPlayer.ts#L8">src/core/DTPlayer.ts:8</a></li></ul></aside><div class="tsd-comment tsd-typography"><div class="lead">
|
|
6
|
+
<p>Defining component type to "player".</p>
|
|
7
|
+
</div></div></section><section class="tsd-panel tsd-member tsd-kind-property tsd-parent-kind-class tsd-is-inherited tsd-is-protected"><a id="_context" class="tsd-anchor"></a><h3><span class="tsd-flag ts-flagProtected">Protected</span> <span class="tsd-flag ts-flagOptional">Optional</span> _context</h3><div class="tsd-signature tsd-kind-icon">_context<span class="tsd-signature-symbol">?:</span> <a href="DTComponent.html" class="tsd-signature-type" data-tsd-kind="Class">DTComponent</a></div><aside class="tsd-sources"><p>Inherited from <a href="DTComponentWithMeta.html">DTComponentWithMeta</a>.<a href="DTComponentWithMeta.html#_context">_context</a></p><ul><li>Defined in <a href="https://gitlab.com/flaya-dyo/dyo-tools/core/-/blob/9b29d44/src/core/DTComponent.ts#L20">src/core/DTComponent.ts:20</a></li></ul></aside><div class="tsd-comment tsd-typography"><div class="lead">
|
|
8
|
+
<p>Component Parent Context.</p>
|
|
9
|
+
</div><div><p>A component can have only one <em>physical context</em>, and be managed by a parent Component.</p>
|
|
10
|
+
</div></div></section><section class="tsd-panel tsd-member tsd-kind-property tsd-parent-kind-class tsd-is-inherited tsd-is-protected"><a id="_domain" class="tsd-anchor"></a><h3><span class="tsd-flag ts-flagProtected">Protected</span> <span class="tsd-flag ts-flagOptional">Optional</span> _domain</h3><div class="tsd-signature tsd-kind-icon">_domain<span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span></div><aside class="tsd-sources"><p>Inherited from <a href="DTComponentWithMeta.html">DTComponentWithMeta</a>.<a href="DTComponentWithMeta.html#_domain">_domain</a></p><ul><li>Defined in <a href="https://gitlab.com/flaya-dyo/dyo-tools/core/-/blob/9b29d44/src/core/DTComponent.ts#L34">src/core/DTComponent.ts:34</a></li></ul></aside><div class="tsd-comment tsd-typography"><div class="lead">
|
|
11
|
+
<p>Second Level Component category.</p>
|
|
12
|
+
</div><div><p>Describing component Domain, like Card, Dice, Token...</p>
|
|
13
|
+
</div></div></section><section class="tsd-panel tsd-member tsd-kind-property tsd-parent-kind-class tsd-is-inherited tsd-is-protected"><a id="_id" class="tsd-anchor"></a><h3><span class="tsd-flag ts-flagProtected">Protected</span> _id</h3><div class="tsd-signature tsd-kind-icon">_id<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span></div><aside class="tsd-sources"><p>Inherited from <a href="DTComponentWithMeta.html">DTComponentWithMeta</a>.<a href="DTComponentWithMeta.html#_id">_id</a></p><ul><li>Defined in <a href="https://gitlab.com/flaya-dyo/dyo-tools/core/-/blob/9b29d44/src/core/DTComponent.ts#L7">src/core/DTComponent.ts:7</a></li></ul></aside><div class="tsd-comment tsd-typography"><div class="lead">
|
|
14
|
+
<p>Component unique ID. Use uuid v4 generator.</p>
|
|
15
|
+
</div></div></section><section class="tsd-panel tsd-member tsd-kind-property tsd-parent-kind-class tsd-is-inherited tsd-is-protected"><a id="_key" class="tsd-anchor"></a><h3><span class="tsd-flag ts-flagProtected">Protected</span> _key</h3><div class="tsd-signature tsd-kind-icon">_key<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span></div><aside class="tsd-sources"><p>Inherited from <a href="DTComponentWithMeta.html">DTComponentWithMeta</a>.<a href="DTComponentWithMeta.html#_key">_key</a></p><ul><li>Defined in <a href="https://gitlab.com/flaya-dyo/dyo-tools/core/-/blob/9b29d44/src/core/DTComponent.ts#L13">src/core/DTComponent.ts:13</a></li></ul></aside><div class="tsd-comment tsd-typography"><div class="lead">
|
|
16
|
+
<p>Component specific and accessible label.
|
|
17
|
+
If not provided, the key is set with ID by default.</p>
|
|
18
|
+
</div></div></section><section class="tsd-panel tsd-member tsd-kind-property tsd-parent-kind-class tsd-is-inherited tsd-is-protected"><a id="_meta" class="tsd-anchor"></a><h3><span class="tsd-flag ts-flagProtected">Protected</span> _meta</h3><div class="tsd-signature tsd-kind-icon">_meta<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">Partial</span><span class="tsd-signature-symbol"><</span><span class="tsd-signature-type" data-tsd-kind="Type parameter">IComponentMeta</span><span class="tsd-signature-symbol">></span><span class="tsd-signature-symbol"> = ...</span></div><aside class="tsd-sources"><p>Inherited from <a href="DTComponentWithMeta.html">DTComponentWithMeta</a>.<a href="DTComponentWithMeta.html#_meta">_meta</a></p><ul><li>Defined in <a href="https://gitlab.com/flaya-dyo/dyo-tools/core/-/blob/9b29d44/src/core/DTComponentWithMeta.ts#L10">src/core/DTComponentWithMeta.ts:10</a></li></ul></aside><div class="tsd-comment tsd-typography"><div class="lead">
|
|
19
|
+
<p>Component meta data.
|
|
20
|
+
Defined by generic type IComponentMeta.</p>
|
|
21
|
+
</div><dl class="tsd-comment-tags"><dt>default</dt><dd><p>{}</p>
|
|
22
|
+
</dd></dl></div></section><section class="tsd-panel tsd-member tsd-kind-property tsd-parent-kind-class tsd-is-inherited tsd-is-protected"><a id="_subKind" class="tsd-anchor"></a><h3><span class="tsd-flag ts-flagProtected">Protected</span> <span class="tsd-flag ts-flagOptional">Optional</span> _sub<wbr/>Kind</h3><div class="tsd-signature tsd-kind-icon">_sub<wbr/>Kind<span class="tsd-signature-symbol">?:</span> <span class="tsd-signature-type">string</span></div><aside class="tsd-sources"><p>Inherited from <a href="DTComponentWithMeta.html">DTComponentWithMeta</a>.<a href="DTComponentWithMeta.html#_subKind">_subKind</a></p><ul><li>Defined in <a href="https://gitlab.com/flaya-dyo/dyo-tools/core/-/blob/9b29d44/src/core/DTComponent.ts#L41">src/core/DTComponent.ts:41</a></li></ul></aside><div class="tsd-comment tsd-typography"><div class="lead">
|
|
23
|
+
<p>Third Level Component category.</p>
|
|
24
|
+
</div><div><p>Describing component extra type, like Hand, Deck, Trick...</p>
|
|
25
|
+
</div></div></section></section><section class="tsd-panel-group tsd-member-group "><h2>Methods</h2><section class="tsd-panel tsd-member tsd-kind-method tsd-parent-kind-class tsd-is-overwrite"><a id="copy" class="tsd-anchor"></a><h3>copy</h3><ul class="tsd-signatures tsd-kind-method tsd-parent-kind-class tsd-is-overwrite"><li class="tsd-signature tsd-kind-icon">copy<span class="tsd-signature-symbol">(</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><a href="DTPlayer.html" class="tsd-signature-type" data-tsd-kind="Class">DTPlayer</a><span class="tsd-signature-symbol"><</span><span class="tsd-signature-type" data-tsd-kind="Type parameter">IComponentMeta</span><span class="tsd-signature-symbol">></span></li></ul><ul class="tsd-descriptions"><li class="tsd-description"><aside class="tsd-sources"><p>Overrides <a href="DTComponentWithMeta.html">DTComponentWithMeta</a>.<a href="DTComponentWithMeta.html#copy">copy</a></p><ul><li>Defined in <a href="https://gitlab.com/flaya-dyo/dyo-tools/core/-/blob/9b29d44/src/core/DTPlayer.ts#L17">src/core/DTPlayer.ts:17</a></li></ul></aside><div class="tsd-comment tsd-typography"><div class="lead">
|
|
26
|
+
<p>Create and return a new DTPlayer instance by applying from current instance :</p>
|
|
27
|
+
<ul>
|
|
28
|
+
<li>Copy _key property</li>
|
|
29
|
+
<li>Copy _meta property</li>
|
|
30
|
+
</ul>
|
|
31
|
+
</div></div><h4 class="tsd-returns-title">Returns <a href="DTPlayer.html" class="tsd-signature-type" data-tsd-kind="Class">DTPlayer</a><span class="tsd-signature-symbol"><</span><span class="tsd-signature-type" data-tsd-kind="Type parameter">IComponentMeta</span><span class="tsd-signature-symbol">></span></h4><div><p>New DTPlayer instance copied.</p>
|
|
32
|
+
</div></li></ul></section><section class="tsd-panel tsd-member tsd-kind-method tsd-parent-kind-class tsd-is-inherited"><a id="getComponentType" class="tsd-anchor"></a><h3>get<wbr/>Component<wbr/>Type</h3><ul class="tsd-signatures tsd-kind-method tsd-parent-kind-class tsd-is-inherited"><li class="tsd-signature tsd-kind-icon">get<wbr/>Component<wbr/>Type<span class="tsd-signature-symbol">(</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">string</span></li></ul><ul class="tsd-descriptions"><li class="tsd-description"><aside class="tsd-sources"><p>Inherited from <a href="DTComponentWithMeta.html">DTComponentWithMeta</a>.<a href="DTComponentWithMeta.html#getComponentType">getComponentType</a></p><ul><li>Defined in <a href="https://gitlab.com/flaya-dyo/dyo-tools/core/-/blob/9b29d44/src/core/DTComponent.ts#L103">src/core/DTComponent.ts:103</a></li></ul></aside><div class="tsd-comment tsd-typography"><div class="lead">
|
|
33
|
+
<p>Getter for _componentType property.</p>
|
|
34
|
+
</div></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">string</span></h4></li></ul></section><section class="tsd-panel tsd-member tsd-kind-method tsd-parent-kind-class tsd-is-inherited"><a id="getContext" class="tsd-anchor"></a><h3>get<wbr/>Context</h3><ul class="tsd-signatures tsd-kind-method tsd-parent-kind-class tsd-is-inherited"><li class="tsd-signature tsd-kind-icon">get<wbr/>Context<span class="tsd-signature-symbol">(</span>contextType<span class="tsd-signature-symbol">?: </span><span class="tsd-signature-type">string</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><a href="DTComponent.html" class="tsd-signature-type" data-tsd-kind="Class">DTComponent</a></li></ul><ul class="tsd-descriptions"><li class="tsd-description"><aside class="tsd-sources"><p>Inherited from <a href="DTComponentWithMeta.html">DTComponentWithMeta</a>.<a href="DTComponentWithMeta.html#getContext">getContext</a></p><ul><li>Defined in <a href="https://gitlab.com/flaya-dyo/dyo-tools/core/-/blob/9b29d44/src/core/DTComponent.ts#L76">src/core/DTComponent.ts:76</a></li></ul></aside><div class="tsd-comment tsd-typography"><div class="lead">
|
|
35
|
+
<p>Getter for _context property.</p>
|
|
36
|
+
</div></div><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameters"><li><h5><span class="tsd-flag ts-flagOptional">Optional</span> contextType: <span class="tsd-signature-type">string</span></h5><div class="tsd-comment tsd-typography"><div class="lead">
|
|
37
|
+
<p>If provided, the getter parse all component level hierarchy to find the corresponding component
|
|
38
|
+
with <strong>contextType</strong> as _componentType value, and returns it. Return undefined if not found.</p>
|
|
39
|
+
</div></div></li></ul><h4 class="tsd-returns-title">Returns <a href="DTComponent.html" class="tsd-signature-type" data-tsd-kind="Class">DTComponent</a></h4><div><p>Direct parent Component or higher level Component if filtered with <strong>contextType</strong>.
|
|
40
|
+
Returns undefined if context doesn't exist.</p>
|
|
41
|
+
</div></li></ul></section><section class="tsd-panel tsd-member tsd-kind-method tsd-parent-kind-class tsd-is-inherited"><a id="getDomain" class="tsd-anchor"></a><h3>get<wbr/>Domain</h3><ul class="tsd-signatures tsd-kind-method tsd-parent-kind-class tsd-is-inherited"><li class="tsd-signature tsd-kind-icon">get<wbr/>Domain<span class="tsd-signature-symbol">(</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">string</span></li></ul><ul class="tsd-descriptions"><li class="tsd-description"><aside class="tsd-sources"><p>Inherited from <a href="DTComponentWithMeta.html">DTComponentWithMeta</a>.<a href="DTComponentWithMeta.html#getDomain">getDomain</a></p><ul><li>Defined in <a href="https://gitlab.com/flaya-dyo/dyo-tools/core/-/blob/9b29d44/src/core/DTComponent.ts#L110">src/core/DTComponent.ts:110</a></li></ul></aside><div class="tsd-comment tsd-typography"><div class="lead">
|
|
42
|
+
<p>Getter for _domain property.</p>
|
|
43
|
+
</div></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">string</span></h4></li></ul></section><section class="tsd-panel tsd-member tsd-kind-method tsd-parent-kind-class tsd-is-inherited"><a id="getId" class="tsd-anchor"></a><h3>get<wbr/>Id</h3><ul class="tsd-signatures tsd-kind-method tsd-parent-kind-class tsd-is-inherited"><li class="tsd-signature tsd-kind-icon">get<wbr/>Id<span class="tsd-signature-symbol">(</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">string</span></li></ul><ul class="tsd-descriptions"><li class="tsd-description"><aside class="tsd-sources"><p>Inherited from <a href="DTComponentWithMeta.html">DTComponentWithMeta</a>.<a href="DTComponentWithMeta.html#getId">getId</a></p><ul><li>Defined in <a href="https://gitlab.com/flaya-dyo/dyo-tools/core/-/blob/9b29d44/src/core/DTComponent.ts#L56">src/core/DTComponent.ts:56</a></li></ul></aside><div class="tsd-comment tsd-typography"><div class="lead">
|
|
44
|
+
<p>Getter for _id property.</p>
|
|
45
|
+
</div></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">string</span></h4></li></ul></section><section class="tsd-panel tsd-member tsd-kind-method tsd-parent-kind-class tsd-is-inherited"><a id="getKey" class="tsd-anchor"></a><h3>get<wbr/>Key</h3><ul class="tsd-signatures tsd-kind-method tsd-parent-kind-class tsd-is-inherited"><li class="tsd-signature tsd-kind-icon">get<wbr/>Key<span class="tsd-signature-symbol">(</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">string</span></li></ul><ul class="tsd-descriptions"><li class="tsd-description"><aside class="tsd-sources"><p>Inherited from <a href="DTComponentWithMeta.html">DTComponentWithMeta</a>.<a href="DTComponentWithMeta.html#getKey">getKey</a></p><ul><li>Defined in <a href="https://gitlab.com/flaya-dyo/dyo-tools/core/-/blob/9b29d44/src/core/DTComponent.ts#L63">src/core/DTComponent.ts:63</a></li></ul></aside><div class="tsd-comment tsd-typography"><div class="lead">
|
|
46
|
+
<p>Getter for _key property.</p>
|
|
47
|
+
</div></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">string</span></h4></li></ul></section><section class="tsd-panel tsd-member tsd-kind-method tsd-parent-kind-class tsd-is-inherited"><a id="getManyMeta" class="tsd-anchor"></a><h3>get<wbr/>Many<wbr/>Meta</h3><ul class="tsd-signatures tsd-kind-method tsd-parent-kind-class tsd-is-inherited"><li class="tsd-signature tsd-kind-icon">get<wbr/>Many<wbr/>Meta<span class="tsd-signature-symbol">(</span>metaKeys<span class="tsd-signature-symbol">?: </span><span class="tsd-signature-symbol">keyof </span><span class="tsd-signature-type" data-tsd-kind="Type parameter">IComponentMeta</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">Partial</span><span class="tsd-signature-symbol"><</span><span class="tsd-signature-type" data-tsd-kind="Type parameter">IComponentMeta</span><span class="tsd-signature-symbol">></span></li></ul><ul class="tsd-descriptions"><li class="tsd-description"><aside class="tsd-sources"><p>Inherited from <a href="DTComponentWithMeta.html">DTComponentWithMeta</a>.<a href="DTComponentWithMeta.html#getManyMeta">getManyMeta</a></p><ul><li>Defined in <a href="https://gitlab.com/flaya-dyo/dyo-tools/core/-/blob/9b29d44/src/core/DTComponentWithMeta.ts#L40">src/core/DTComponentWithMeta.ts:40</a></li></ul></aside><div class="tsd-comment tsd-typography"><div class="lead">
|
|
48
|
+
<p>Returns multiple defined keys values of meta data.</p>
|
|
49
|
+
</div></div><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameters"><li><h5>metaKeys: <span class="tsd-signature-symbol">keyof </span><span class="tsd-signature-type" data-tsd-kind="Type parameter">IComponentMeta</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol"> = []</span></h5><div class="tsd-comment tsd-typography"><div class="lead">
|
|
50
|
+
<p>Array of keys to filter for meta data. If not provided or empty, returns all keys.</p>
|
|
51
|
+
</div></div></li></ul><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Partial</span><span class="tsd-signature-symbol"><</span><span class="tsd-signature-type" data-tsd-kind="Type parameter">IComponentMeta</span><span class="tsd-signature-symbol">></span></h4><div><p>Meta data object with <strong>metaKeys</strong> provided keys only.</p>
|
|
52
|
+
</div></li></ul></section><section class="tsd-panel tsd-member tsd-kind-method tsd-parent-kind-class tsd-has-type-parameter tsd-is-inherited"><a id="getMeta" class="tsd-anchor"></a><h3>get<wbr/>Meta</h3><ul class="tsd-signatures tsd-kind-method tsd-parent-kind-class tsd-has-type-parameter tsd-is-inherited"><li class="tsd-signature tsd-kind-icon">get<wbr/>Meta<span class="tsd-signature-symbol"><</span><span class="tsd-signature-type" data-tsd-kind="Type parameter">K</span><span class="tsd-signature-symbol">></span><span class="tsd-signature-symbol">(</span>metaKey<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type" data-tsd-kind="Type parameter">K</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type" data-tsd-kind="Type parameter">IComponentMeta</span><span class="tsd-signature-symbol">[</span><span class="tsd-signature-type" data-tsd-kind="Type parameter">K</span><span class="tsd-signature-symbol">]</span></li></ul><ul class="tsd-descriptions"><li class="tsd-description"><aside class="tsd-sources"><p>Inherited from <a href="DTComponentWithMeta.html">DTComponentWithMeta</a>.<a href="DTComponentWithMeta.html#getMeta">getMeta</a></p><ul><li>Defined in <a href="https://gitlab.com/flaya-dyo/dyo-tools/core/-/blob/9b29d44/src/core/DTComponentWithMeta.ts#L19">src/core/DTComponentWithMeta.ts:19</a></li></ul></aside><div class="tsd-comment tsd-typography"><div class="lead">
|
|
53
|
+
<p>Getter for one meta by key.</p>
|
|
54
|
+
</div></div><h4 class="tsd-type-parameters-title">Type parameters</h4><ul class="tsd-type-parameters"><li><h4>K<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">string</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type">symbol</span></h4></li></ul><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameters"><li><h5>metaKey: <span class="tsd-signature-type" data-tsd-kind="Type parameter">K</span></h5><div class="tsd-comment tsd-typography"><div class="lead">
|
|
55
|
+
<p>Key name of one meta data.</p>
|
|
56
|
+
</div></div></li></ul><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type" data-tsd-kind="Type parameter">IComponentMeta</span><span class="tsd-signature-symbol">[</span><span class="tsd-signature-type" data-tsd-kind="Type parameter">K</span><span class="tsd-signature-symbol">]</span></h4><div><p>Associated meta <strong>metaKey</strong> value or undefined if not found.</p>
|
|
57
|
+
</div></li></ul></section><section class="tsd-panel tsd-member tsd-kind-method tsd-parent-kind-class tsd-is-inherited"><a id="getSubKind" class="tsd-anchor"></a><h3>get<wbr/>Sub<wbr/>Kind</h3><ul class="tsd-signatures tsd-kind-method tsd-parent-kind-class tsd-is-inherited"><li class="tsd-signature tsd-kind-icon">get<wbr/>Sub<wbr/>Kind<span class="tsd-signature-symbol">(</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">string</span></li></ul><ul class="tsd-descriptions"><li class="tsd-description"><aside class="tsd-sources"><p>Inherited from <a href="DTComponentWithMeta.html">DTComponentWithMeta</a>.<a href="DTComponentWithMeta.html#getSubKind">getSubKind</a></p><ul><li>Defined in <a href="https://gitlab.com/flaya-dyo/dyo-tools/core/-/blob/9b29d44/src/core/DTComponent.ts#L117">src/core/DTComponent.ts:117</a></li></ul></aside><div class="tsd-comment tsd-typography"><div class="lead">
|
|
58
|
+
<p>Getter for _subKind property.</p>
|
|
59
|
+
</div></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">string</span></h4></li></ul></section><section class="tsd-panel tsd-member tsd-kind-method tsd-parent-kind-class tsd-is-inherited"><a id="removeContext" class="tsd-anchor"></a><h3>remove<wbr/>Context</h3><ul class="tsd-signatures tsd-kind-method tsd-parent-kind-class tsd-is-inherited"><li class="tsd-signature tsd-kind-icon">remove<wbr/>Context<span class="tsd-signature-symbol">(</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">void</span></li></ul><ul class="tsd-descriptions"><li class="tsd-description"><aside class="tsd-sources"><p>Inherited from <a href="DTComponentWithMeta.html">DTComponentWithMeta</a>.<a href="DTComponentWithMeta.html#removeContext">removeContext</a></p><ul><li>Defined in <a href="https://gitlab.com/flaya-dyo/dyo-tools/core/-/blob/9b29d44/src/core/DTComponent.ts#L96">src/core/DTComponent.ts:96</a></li></ul></aside><div class="tsd-comment tsd-typography"><div class="lead">
|
|
60
|
+
<p>Remove the current context of component</p>
|
|
61
|
+
</div></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4></li></ul></section><section class="tsd-panel tsd-member tsd-kind-method tsd-parent-kind-class tsd-is-inherited"><a id="setContext" class="tsd-anchor"></a><h3>set<wbr/>Context</h3><ul class="tsd-signatures tsd-kind-method tsd-parent-kind-class tsd-is-inherited"><li class="tsd-signature tsd-kind-icon">set<wbr/>Context<span class="tsd-signature-symbol">(</span>value<span class="tsd-signature-symbol">: </span><a href="DTComponent.html" class="tsd-signature-type" data-tsd-kind="Class">DTComponent</a><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">void</span></li></ul><ul class="tsd-descriptions"><li class="tsd-description"><aside class="tsd-sources"><p>Inherited from <a href="DTComponentWithMeta.html">DTComponentWithMeta</a>.<a href="DTComponentWithMeta.html#setContext">setContext</a></p><ul><li>Defined in <a href="https://gitlab.com/flaya-dyo/dyo-tools/core/-/blob/9b29d44/src/core/DTComponent.ts#L89">src/core/DTComponent.ts:89</a></li></ul></aside><div class="tsd-comment tsd-typography"><div class="lead">
|
|
62
|
+
<p>Setter for _context property.</p>
|
|
63
|
+
</div></div><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameters"><li><h5>value: <a href="DTComponent.html" class="tsd-signature-type" data-tsd-kind="Class">DTComponent</a></h5></li></ul><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4></li></ul></section><section class="tsd-panel tsd-member tsd-kind-method tsd-parent-kind-class tsd-is-inherited"><a id="setManyMeta" class="tsd-anchor"></a><h3>set<wbr/>Many<wbr/>Meta</h3><ul class="tsd-signatures tsd-kind-method tsd-parent-kind-class tsd-is-inherited"><li class="tsd-signature tsd-kind-icon">set<wbr/>Many<wbr/>Meta<span class="tsd-signature-symbol">(</span>metaValues<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">Partial</span><span class="tsd-signature-symbol"><</span><span class="tsd-signature-type" data-tsd-kind="Type parameter">IComponentMeta</span><span class="tsd-signature-symbol">></span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">void</span></li></ul><ul class="tsd-descriptions"><li class="tsd-description"><aside class="tsd-sources"><p>Inherited from <a href="DTComponentWithMeta.html">DTComponentWithMeta</a>.<a href="DTComponentWithMeta.html#setManyMeta">setManyMeta</a></p><ul><li>Defined in <a href="https://gitlab.com/flaya-dyo/dyo-tools/core/-/blob/9b29d44/src/core/DTComponentWithMeta.ts#L59">src/core/DTComponentWithMeta.ts:59</a></li></ul></aside><div class="tsd-comment tsd-typography"><div class="lead">
|
|
64
|
+
<p>Set multiple meta data.</p>
|
|
65
|
+
</div></div><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameters"><li><h5>metaValues: <span class="tsd-signature-type">Partial</span><span class="tsd-signature-symbol"><</span><span class="tsd-signature-type" data-tsd-kind="Type parameter">IComponentMeta</span><span class="tsd-signature-symbol">></span></h5><div class="tsd-comment tsd-typography"><div class="lead">
|
|
66
|
+
<p>Object of meta data to set, according to the meta data property type.</p>
|
|
67
|
+
</div></div></li></ul><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4></li></ul></section><section class="tsd-panel tsd-member tsd-kind-method tsd-parent-kind-class tsd-has-type-parameter tsd-is-inherited"><a id="setMeta" class="tsd-anchor"></a><h3>set<wbr/>Meta</h3><ul class="tsd-signatures tsd-kind-method tsd-parent-kind-class tsd-has-type-parameter tsd-is-inherited"><li class="tsd-signature tsd-kind-icon">set<wbr/>Meta<span class="tsd-signature-symbol"><</span><span class="tsd-signature-type" data-tsd-kind="Type parameter">K</span><span class="tsd-signature-symbol">></span><span class="tsd-signature-symbol">(</span>metaKey<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type" data-tsd-kind="Type parameter">K</span>, metaValue<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type" data-tsd-kind="Type parameter">IComponentMeta</span><span class="tsd-signature-symbol">[</span><span class="tsd-signature-type" data-tsd-kind="Type parameter">K</span><span class="tsd-signature-symbol">]</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">void</span></li></ul><ul class="tsd-descriptions"><li class="tsd-description"><aside class="tsd-sources"><p>Inherited from <a href="DTComponentWithMeta.html">DTComponentWithMeta</a>.<a href="DTComponentWithMeta.html#setMeta">setMeta</a></p><ul><li>Defined in <a href="https://gitlab.com/flaya-dyo/dyo-tools/core/-/blob/9b29d44/src/core/DTComponentWithMeta.ts#L29">src/core/DTComponentWithMeta.ts:29</a></li></ul></aside><div class="tsd-comment tsd-typography"><div class="lead">
|
|
68
|
+
<p>Setter for one meta by key.</p>
|
|
69
|
+
</div></div><h4 class="tsd-type-parameters-title">Type parameters</h4><ul class="tsd-type-parameters"><li><h4>K<span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">string</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type">symbol</span></h4></li></ul><h4 class="tsd-parameters-title">Parameters</h4><ul class="tsd-parameters"><li><h5>metaKey: <span class="tsd-signature-type" data-tsd-kind="Type parameter">K</span></h5><div class="tsd-comment tsd-typography"><div class="lead">
|
|
70
|
+
<p>Key name of the meta data to update.</p>
|
|
71
|
+
</div></div></li><li><h5>metaValue: <span class="tsd-signature-type" data-tsd-kind="Type parameter">IComponentMeta</span><span class="tsd-signature-symbol">[</span><span class="tsd-signature-type" data-tsd-kind="Type parameter">K</span><span class="tsd-signature-symbol">]</span></h5><div class="tsd-comment tsd-typography"><div class="lead">
|
|
72
|
+
<p>New value to set into the meta data.</p>
|
|
73
|
+
</div></div></li></ul><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">void</span></h4></li></ul></section><section class="tsd-panel tsd-member tsd-kind-method tsd-parent-kind-class tsd-is-overwrite"><a id="toObject" class="tsd-anchor"></a><h3>to<wbr/>Object</h3><ul class="tsd-signatures tsd-kind-method tsd-parent-kind-class tsd-is-overwrite"><li class="tsd-signature tsd-kind-icon">to<wbr/>Object<span class="tsd-signature-symbol">(</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">DTPlayerToObject</span><span class="tsd-signature-symbol"><</span><span class="tsd-signature-type" data-tsd-kind="Type parameter">IComponentMeta</span><span class="tsd-signature-symbol">></span></li></ul><ul class="tsd-descriptions"><li class="tsd-description"><aside class="tsd-sources"><p>Overrides <a href="DTComponentWithMeta.html">DTComponentWithMeta</a>.<a href="DTComponentWithMeta.html#toObject">toObject</a></p><ul><li>Defined in <a href="https://gitlab.com/flaya-dyo/dyo-tools/core/-/blob/9b29d44/src/core/DTPlayer.ts#L35">src/core/DTPlayer.ts:35</a></li></ul></aside><div class="tsd-comment tsd-typography"><div class="lead">
|
|
74
|
+
<p>Return JSON Object representation of the Player instance.</p>
|
|
75
|
+
</div><div><p>JSON Object returned has the following structure :</p>
|
|
76
|
+
<ul>
|
|
77
|
+
<li><strong>id</strong> : _id property of the Player.</li>
|
|
78
|
+
<li><strong>key</strong> : _key property of the Player.</li>
|
|
79
|
+
<li><strong>type</strong> : _componentType property of the Player.</li>
|
|
80
|
+
<li><strong>meta</strong> : JSON Object of all current metadata in _meta property of the Player (only if not empty).</li>
|
|
81
|
+
</ul>
|
|
82
|
+
</div></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">DTPlayerToObject</span><span class="tsd-signature-symbol"><</span><span class="tsd-signature-type" data-tsd-kind="Type parameter">IComponentMeta</span><span class="tsd-signature-symbol">></span></h4><div><p>JSON Object representation of the Player.</p>
|
|
83
|
+
</div></li></ul></section><section class="tsd-panel tsd-member tsd-kind-method tsd-parent-kind-class tsd-is-overwrite"><a id="toString" class="tsd-anchor"></a><h3>to<wbr/>String</h3><ul class="tsd-signatures tsd-kind-method tsd-parent-kind-class tsd-is-overwrite"><li class="tsd-signature tsd-kind-icon">to<wbr/>String<span class="tsd-signature-symbol">(</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">string</span></li></ul><ul class="tsd-descriptions"><li class="tsd-description"><aside class="tsd-sources"><p>Overrides <a href="DTComponentWithMeta.html">DTComponentWithMeta</a>.<a href="DTComponentWithMeta.html#toString">toString</a></p><ul><li>Defined in <a href="https://gitlab.com/flaya-dyo/dyo-tools/core/-/blob/9b29d44/src/core/DTPlayer.ts#L54">src/core/DTPlayer.ts:54</a></li></ul></aside><div class="tsd-comment tsd-typography"><div class="lead">
|
|
84
|
+
<p>Return String representation of the Player instance.</p>
|
|
85
|
+
</div></div><h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">string</span></h4><div><p>String representation of the Player.</p>
|
|
86
|
+
</div></li></ul></section></section></div><div class="col-4 col-menu menu-sticky-wrap menu-highlight"><nav class="tsd-navigation primary"><ul><li class=""><a href="../modules.html">Exports</a></li></ul></nav><nav class="tsd-navigation secondary menu-sticky"><ul><li class="current tsd-kind-class tsd-has-type-parameter"><a href="DTPlayer.html" class="tsd-kind-icon">DTPlayer</a><ul><li class="tsd-kind-constructor tsd-parent-kind-class tsd-has-type-parameter tsd-is-inherited"><a href="DTPlayer.html#constructor" class="tsd-kind-icon">constructor</a></li><li class="tsd-kind-property tsd-parent-kind-class tsd-is-overwrite tsd-is-protected"><a href="DTPlayer.html#_componentType" class="tsd-kind-icon">_component<wbr/>Type</a></li><li class="tsd-kind-property tsd-parent-kind-class tsd-is-inherited tsd-is-protected"><a href="DTPlayer.html#_context" class="tsd-kind-icon">_context</a></li><li class="tsd-kind-property tsd-parent-kind-class tsd-is-inherited tsd-is-protected"><a href="DTPlayer.html#_domain" class="tsd-kind-icon">_domain</a></li><li class="tsd-kind-property tsd-parent-kind-class tsd-is-inherited tsd-is-protected"><a href="DTPlayer.html#_id" class="tsd-kind-icon">_id</a></li><li class="tsd-kind-property tsd-parent-kind-class tsd-is-inherited tsd-is-protected"><a href="DTPlayer.html#_key" class="tsd-kind-icon">_key</a></li><li class="tsd-kind-property tsd-parent-kind-class tsd-is-inherited tsd-is-protected"><a href="DTPlayer.html#_meta" class="tsd-kind-icon">_meta</a></li><li class="tsd-kind-property tsd-parent-kind-class tsd-is-inherited tsd-is-protected"><a href="DTPlayer.html#_subKind" class="tsd-kind-icon">_sub<wbr/>Kind</a></li><li class="tsd-kind-method tsd-parent-kind-class tsd-is-overwrite"><a href="DTPlayer.html#copy" class="tsd-kind-icon">copy</a></li><li class="tsd-kind-method tsd-parent-kind-class tsd-is-inherited"><a href="DTPlayer.html#getComponentType" class="tsd-kind-icon">get<wbr/>Component<wbr/>Type</a></li><li class="tsd-kind-method tsd-parent-kind-class tsd-is-inherited"><a href="DTPlayer.html#getContext" class="tsd-kind-icon">get<wbr/>Context</a></li><li class="tsd-kind-method tsd-parent-kind-class tsd-is-inherited"><a href="DTPlayer.html#getDomain" class="tsd-kind-icon">get<wbr/>Domain</a></li><li class="tsd-kind-method tsd-parent-kind-class tsd-is-inherited"><a href="DTPlayer.html#getId" class="tsd-kind-icon">get<wbr/>Id</a></li><li class="tsd-kind-method tsd-parent-kind-class tsd-is-inherited"><a href="DTPlayer.html#getKey" class="tsd-kind-icon">get<wbr/>Key</a></li><li class="tsd-kind-method tsd-parent-kind-class tsd-is-inherited"><a href="DTPlayer.html#getManyMeta" class="tsd-kind-icon">get<wbr/>Many<wbr/>Meta</a></li><li class="tsd-kind-method tsd-parent-kind-class tsd-has-type-parameter tsd-is-inherited"><a href="DTPlayer.html#getMeta" class="tsd-kind-icon">get<wbr/>Meta</a></li><li class="tsd-kind-method tsd-parent-kind-class tsd-is-inherited"><a href="DTPlayer.html#getSubKind" class="tsd-kind-icon">get<wbr/>Sub<wbr/>Kind</a></li><li class="tsd-kind-method tsd-parent-kind-class tsd-is-inherited"><a href="DTPlayer.html#removeContext" class="tsd-kind-icon">remove<wbr/>Context</a></li><li class="tsd-kind-method tsd-parent-kind-class tsd-is-inherited"><a href="DTPlayer.html#setContext" class="tsd-kind-icon">set<wbr/>Context</a></li><li class="tsd-kind-method tsd-parent-kind-class tsd-is-inherited"><a href="DTPlayer.html#setManyMeta" class="tsd-kind-icon">set<wbr/>Many<wbr/>Meta</a></li><li class="tsd-kind-method tsd-parent-kind-class tsd-has-type-parameter tsd-is-inherited"><a href="DTPlayer.html#setMeta" class="tsd-kind-icon">set<wbr/>Meta</a></li><li class="tsd-kind-method tsd-parent-kind-class tsd-is-overwrite"><a href="DTPlayer.html#toObject" class="tsd-kind-icon">to<wbr/>Object</a></li><li class="tsd-kind-method tsd-parent-kind-class tsd-is-overwrite"><a href="DTPlayer.html#toString" class="tsd-kind-icon">to<wbr/>String</a></li></ul></li></ul></nav></div></div></div><footer class="with-border-bottom"><div class="container"><h2>Legend</h2><div class="tsd-legend-group"><ul class="tsd-legend"><li class="tsd-kind-constructor tsd-parent-kind-class"><span class="tsd-kind-icon">Constructor</span></li><li class="tsd-kind-method tsd-parent-kind-class"><span class="tsd-kind-icon">Method</span></li></ul><ul class="tsd-legend"><li class="tsd-kind-method tsd-parent-kind-class tsd-is-inherited"><span class="tsd-kind-icon">Inherited method</span></li></ul><ul class="tsd-legend"><li class="tsd-kind-property tsd-parent-kind-class tsd-is-protected"><span class="tsd-kind-icon">Protected property</span></li></ul><ul class="tsd-legend"><li class="tsd-kind-property tsd-parent-kind-class tsd-is-private"><span class="tsd-kind-icon">Private property</span></li></ul></div><h2>Settings</h2><p>Theme <select id="theme"><option value="os">OS</option><option value="light">Light</option><option value="dark">Dark</option></select></p></div></footer><div class="container tsd-generator"><p>Generated using <a href="https://typedoc.org/" target="_blank">TypeDoc</a></p></div><div class="overlay"></div><script src="../assets/main.js"></script></body></html>
|
package/docs/index.html
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
<!DOCTYPE html><html class="default"><head><meta charSet="utf-8"/><meta http-equiv="x-ua-compatible" content="IE=edge"/><title>dyo-tools</title><meta name="description" content="Documentation for dyo-tools"/><meta name="viewport" content="width=device-width, initial-scale=1"/><link rel="stylesheet" href="assets/style.css"/><link rel="stylesheet" href="assets/highlight.css"/><script async src="assets/search.js" id="search-script"></script></head><body><script>document.body.classList.add(localStorage.getItem("tsd-theme") || "os")</script><header><div class="tsd-page-toolbar"><div class="container"><div class="table-wrap"><div class="table-cell" id="tsd-search" data-base="."><div class="field"><label for="tsd-search-field" class="tsd-widget search no-caption">Search</label><input type="text" id="tsd-search-field"/></div><ul class="results"><li class="state loading">Preparing search index...</li><li class="state failure">The search index is not available</li></ul><a href="index.html" class="title">dyo-tools</a></div><div class="table-cell" id="tsd-widgets"><div id="tsd-filter"><a href="#" class="tsd-widget options no-caption" data-toggle="options">Options</a><div class="tsd-filter-group"><div class="tsd-select" id="tsd-filter-visibility"><span class="tsd-select-label">All</span><ul class="tsd-select-list"><li data-value="public">Public</li><li data-value="protected">Public/Protected</li><li data-value="private" class="selected">All</li></ul></div> <input type="checkbox" id="tsd-filter-inherited" checked/><label class="tsd-widget" for="tsd-filter-inherited">Inherited</label><input type="checkbox" id="tsd-filter-externals" checked/><label class="tsd-widget" for="tsd-filter-externals">Externals</label></div></div><a href="#" class="tsd-widget menu no-caption" data-toggle="menu">Menu</a></div></div></div></div><div class="tsd-page-title"><div class="container"><h1>dyo-tools</h1></div></div></header><div class="container container-main"><div class="row"><div class="col-8 col-content"><div class="tsd-panel tsd-typography"></div></div><div class="col-4 col-menu menu-sticky-wrap menu-highlight"><nav class="tsd-navigation primary"><ul><li class="current"><a href="modules.html">Exports</a></li></ul></nav><nav class="tsd-navigation secondary menu-sticky"><ul><li class="tsd-kind-class tsd-has-type-parameter"><a href="classes/DTBunch.html" class="tsd-kind-icon">DTBunch</a></li><li class="tsd-kind-class"><a href="classes/DTComponent.html" class="tsd-kind-icon">DTComponent</a></li><li class="tsd-kind-class tsd-has-type-parameter"><a href="classes/DTComponentWithMeta.html" class="tsd-kind-icon">DTComponent<wbr/>With<wbr/>Meta</a></li><li class="tsd-kind-class tsd-has-type-parameter"><a href="classes/DTElement.html" class="tsd-kind-icon">DTElement</a></li><li class="tsd-kind-class"><a href="classes/DTError.html" class="tsd-kind-icon">DTError</a></li><li class="tsd-kind-class tsd-has-type-parameter"><a href="classes/DTPlayer.html" class="tsd-kind-icon">DTPlayer</a></li></ul></nav></div></div></div><footer class="with-border-bottom"><div class="container"><h2>Legend</h2><div class="tsd-legend-group"><ul class="tsd-legend"><li class="tsd-kind-constructor tsd-parent-kind-class"><span class="tsd-kind-icon">Constructor</span></li><li class="tsd-kind-method tsd-parent-kind-class"><span class="tsd-kind-icon">Method</span></li></ul><ul class="tsd-legend"><li class="tsd-kind-method tsd-parent-kind-class tsd-is-inherited"><span class="tsd-kind-icon">Inherited method</span></li></ul><ul class="tsd-legend"><li class="tsd-kind-property tsd-parent-kind-class tsd-is-protected"><span class="tsd-kind-icon">Protected property</span></li></ul><ul class="tsd-legend"><li class="tsd-kind-property tsd-parent-kind-class tsd-is-private"><span class="tsd-kind-icon">Private property</span></li></ul></div><h2>Settings</h2><p>Theme <select id="theme"><option value="os">OS</option><option value="light">Light</option><option value="dark">Dark</option></select></p></div></footer><div class="container tsd-generator"><p>Generated using <a href="https://typedoc.org/" target="_blank">TypeDoc</a></p></div><div class="overlay"></div><script src="assets/main.js"></script></body></html>
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
<!DOCTYPE html><html class="default"><head><meta charSet="utf-8"/><meta http-equiv="x-ua-compatible" content="IE=edge"/><title>dyo-tools</title><meta name="description" content="Documentation for dyo-tools"/><meta name="viewport" content="width=device-width, initial-scale=1"/><link rel="stylesheet" href="assets/style.css"/><link rel="stylesheet" href="assets/highlight.css"/><script async src="assets/search.js" id="search-script"></script></head><body><script>document.body.classList.add(localStorage.getItem("tsd-theme") || "os")</script><header><div class="tsd-page-toolbar"><div class="container"><div class="table-wrap"><div class="table-cell" id="tsd-search" data-base="."><div class="field"><label for="tsd-search-field" class="tsd-widget search no-caption">Search</label><input type="text" id="tsd-search-field"/></div><ul class="results"><li class="state loading">Preparing search index...</li><li class="state failure">The search index is not available</li></ul><a href="index.html" class="title">dyo-tools</a></div><div class="table-cell" id="tsd-widgets"><div id="tsd-filter"><a href="#" class="tsd-widget options no-caption" data-toggle="options">Options</a><div class="tsd-filter-group"><div class="tsd-select" id="tsd-filter-visibility"><span class="tsd-select-label">All</span><ul class="tsd-select-list"><li data-value="public">Public</li><li data-value="protected">Public/Protected</li><li data-value="private" class="selected">All</li></ul></div> <input type="checkbox" id="tsd-filter-inherited" checked/><label class="tsd-widget" for="tsd-filter-inherited">Inherited</label><input type="checkbox" id="tsd-filter-externals" checked/><label class="tsd-widget" for="tsd-filter-externals">Externals</label></div></div><a href="#" class="tsd-widget menu no-caption" data-toggle="menu">Menu</a></div></div></div></div><div class="tsd-page-title"><div class="container"><h1>dyo-tools</h1></div></div></header><div class="container container-main"><div class="row"><div class="col-8 col-content"><section class="tsd-panel-group tsd-index-group"><h2>Index</h2><section class="tsd-panel tsd-index-panel"><div class="tsd-index-content"><section class="tsd-index-section "><h3>Classes</h3><ul class="tsd-index-list"><li class="tsd-kind-class tsd-has-type-parameter"><a href="classes/DTBunch.html" class="tsd-kind-icon">DTBunch</a></li><li class="tsd-kind-class"><a href="classes/DTComponent.html" class="tsd-kind-icon">DTComponent</a></li><li class="tsd-kind-class tsd-has-type-parameter"><a href="classes/DTComponentWithMeta.html" class="tsd-kind-icon">DTComponent<wbr/>With<wbr/>Meta</a></li><li class="tsd-kind-class tsd-has-type-parameter"><a href="classes/DTElement.html" class="tsd-kind-icon">DTElement</a></li><li class="tsd-kind-class"><a href="classes/DTError.html" class="tsd-kind-icon">DTError</a></li><li class="tsd-kind-class tsd-has-type-parameter"><a href="classes/DTPlayer.html" class="tsd-kind-icon">DTPlayer</a></li></ul></section></div></section></section></div><div class="col-4 col-menu menu-sticky-wrap menu-highlight"><nav class="tsd-navigation primary"><ul><li class="current"><a href="modules.html">Exports</a></li></ul></nav><nav class="tsd-navigation secondary menu-sticky"><ul><li class="tsd-kind-class tsd-has-type-parameter"><a href="classes/DTBunch.html" class="tsd-kind-icon">DTBunch</a></li><li class="tsd-kind-class"><a href="classes/DTComponent.html" class="tsd-kind-icon">DTComponent</a></li><li class="tsd-kind-class tsd-has-type-parameter"><a href="classes/DTComponentWithMeta.html" class="tsd-kind-icon">DTComponent<wbr/>With<wbr/>Meta</a></li><li class="tsd-kind-class tsd-has-type-parameter"><a href="classes/DTElement.html" class="tsd-kind-icon">DTElement</a></li><li class="tsd-kind-class"><a href="classes/DTError.html" class="tsd-kind-icon">DTError</a></li><li class="tsd-kind-class tsd-has-type-parameter"><a href="classes/DTPlayer.html" class="tsd-kind-icon">DTPlayer</a></li></ul></nav></div></div></div><footer class="with-border-bottom"><div class="container"><h2>Legend</h2><div class="tsd-legend-group"><ul class="tsd-legend"><li class="tsd-kind-constructor tsd-parent-kind-class"><span class="tsd-kind-icon">Constructor</span></li><li class="tsd-kind-method tsd-parent-kind-class"><span class="tsd-kind-icon">Method</span></li></ul><ul class="tsd-legend"><li class="tsd-kind-method tsd-parent-kind-class tsd-is-inherited"><span class="tsd-kind-icon">Inherited method</span></li></ul><ul class="tsd-legend"><li class="tsd-kind-property tsd-parent-kind-class tsd-is-protected"><span class="tsd-kind-icon">Protected property</span></li></ul><ul class="tsd-legend"><li class="tsd-kind-property tsd-parent-kind-class tsd-is-private"><span class="tsd-kind-icon">Private property</span></li></ul></div><h2>Settings</h2><p>Theme <select id="theme"><option value="os">OS</option><option value="light">Light</option><option value="dark">Dark</option></select></p></div></footer><div class="container tsd-generator"><p>Generated using <a href="https://typedoc.org/" target="_blank">TypeDoc</a></p></div><div class="overlay"></div><script src="assets/main.js"></script></body></html>
|
package/jest.config.js
ADDED
package/package.json
ADDED
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "dyo-tools",
|
|
3
|
+
"version": "0.1.0-rc1",
|
|
4
|
+
"description": "Provide component classes to manage any board game instance.",
|
|
5
|
+
"main": "dist/index.js",
|
|
6
|
+
"scripts": {
|
|
7
|
+
"build": "tsc",
|
|
8
|
+
"start": "node dist/index.js",
|
|
9
|
+
"lint": "eslint src/ --ext .ts",
|
|
10
|
+
"lint:fix": "eslint src/ --ext .ts --fix",
|
|
11
|
+
"test": "jest",
|
|
12
|
+
"test:coverage": "c8 --check-coverage npm test",
|
|
13
|
+
"test:coverage:verify": "c8 --check-coverage --100 npm test"
|
|
14
|
+
},
|
|
15
|
+
"repository": {
|
|
16
|
+
"type": "git",
|
|
17
|
+
"url": "https://github.com/Flaya24/dyo-tools.git"
|
|
18
|
+
},
|
|
19
|
+
"author": "Flaya for DYO System",
|
|
20
|
+
"license": "MIT",
|
|
21
|
+
"keywords": ["game", "DYO", "board game"],
|
|
22
|
+
"devDependencies": {
|
|
23
|
+
"@babel/preset-env": "^7.14.7",
|
|
24
|
+
"@types/jest": "^27.4.0",
|
|
25
|
+
"@types/uuid": "^8.3.3",
|
|
26
|
+
"@typescript-eslint/eslint-plugin": "^5.9.0",
|
|
27
|
+
"@typescript-eslint/parser": "^5.9.0",
|
|
28
|
+
"c8": "^7.11.0",
|
|
29
|
+
"eslint": "^8.6.0",
|
|
30
|
+
"eslint-config-airbnb-base": "^15.0.0",
|
|
31
|
+
"eslint-config-airbnb-typescript": "^16.1.0",
|
|
32
|
+
"eslint-plugin-import": "^2.25.4",
|
|
33
|
+
"jest": "^27.0.6",
|
|
34
|
+
"ts-jest": "^27.1.3",
|
|
35
|
+
"typedoc": "^0.22.10",
|
|
36
|
+
"typescript": "^4.2.4"
|
|
37
|
+
},
|
|
38
|
+
"dependencies": {
|
|
39
|
+
"uuid": "^8.3.2"
|
|
40
|
+
}
|
|
41
|
+
}
|