diff options
author | Robert Jaros <rjaros@finn.pl> | 2019-10-26 00:17:24 +0200 |
---|---|---|
committer | Robert Jaros <rjaros@finn.pl> | 2019-10-26 00:17:24 +0200 |
commit | fb7ff5b8bf2073a8d7b78011b9edffc830dc63cb (patch) | |
tree | 911c8e9b208b9ba77f00531668d1d99b40fcb8e3 /api1/pl.treksoft.kvision.utils/-cache | |
parent | 4f5db77ec2db6c87cb93ceb9f7ea9ab311247f17 (diff) | |
download | kvision-fb7ff5b8bf2073a8d7b78011b9edffc830dc63cb.tar.gz kvision-fb7ff5b8bf2073a8d7b78011b9edffc830dc63cb.tar.bz2 kvision-fb7ff5b8bf2073a8d7b78011b9edffc830dc63cb.zip |
API documentation for KVision 2.0.0
Diffstat (limited to 'api1/pl.treksoft.kvision.utils/-cache')
-rw-r--r-- | api1/pl.treksoft.kvision.utils/-cache/-init-.html | 17 | ||||
-rw-r--r-- | api1/pl.treksoft.kvision.utils/-cache/get.html | 16 | ||||
-rw-r--r-- | api1/pl.treksoft.kvision.utils/-cache/index.html | 78 | ||||
-rw-r--r-- | api1/pl.treksoft.kvision.utils/-cache/set.html | 16 | ||||
-rw-r--r-- | api1/pl.treksoft.kvision.utils/-cache/to-string.html | 14 |
5 files changed, 141 insertions, 0 deletions
diff --git a/api1/pl.treksoft.kvision.utils/-cache/-init-.html b/api1/pl.treksoft.kvision.utils/-cache/-init-.html new file mode 100644 index 00000000..05af599a --- /dev/null +++ b/api1/pl.treksoft.kvision.utils/-cache/-init-.html @@ -0,0 +1,17 @@ +<HTML> +<HEAD> +<meta charset="UTF-8"> +<title>Cache.<init> - kvision</title> +<link rel="stylesheet" href="../../../style.css"> +</HEAD> +<BODY> +<a href="../../index.html">kvision</a> / <a href="../index.html">pl.treksoft.kvision.utils</a> / <a href="index.html">Cache</a> / <a href="./-init-.html"><init></a><br/> +<br/> +<h1><init></h1> +<a name="pl.treksoft.kvision.utils.Cache$<init>(kotlin.Int)"></a> +<code><span class="identifier">Cache</span><span class="symbol">(</span><span class="identifier" id="pl.treksoft.kvision.utils.Cache$<init>(kotlin.Int)/capacity">capacity</span><span class="symbol">:</span> <a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html"><span class="identifier">Int</span></a> <span class="symbol">=</span> 50<span class="symbol">)</span></code> +<p>This is a LRU cache that has no performance impact for cache insertions +once the capacity of the cache has been reached. For cache hit, +performance is O(1) and for cache eviction, it is O(1).</p> +</BODY> +</HTML> diff --git a/api1/pl.treksoft.kvision.utils/-cache/get.html b/api1/pl.treksoft.kvision.utils/-cache/get.html new file mode 100644 index 00000000..c6cb9816 --- /dev/null +++ b/api1/pl.treksoft.kvision.utils/-cache/get.html @@ -0,0 +1,16 @@ +<HTML> +<HEAD> +<meta charset="UTF-8"> +<title>Cache.get - kvision</title> +<link rel="stylesheet" href="../../../style.css"> +</HEAD> +<BODY> +<a href="../../index.html">kvision</a> / <a href="../index.html">pl.treksoft.kvision.utils</a> / <a href="index.html">Cache</a> / <a href="./get.html">get</a><br/> +<br/> +<h1>get</h1> +<a name="pl.treksoft.kvision.utils.Cache$get(pl.treksoft.kvision.utils.Cache.K)"></a> +<code><span class="keyword">operator</span> <span class="keyword">fun </span><span class="identifier">get</span><span class="symbol">(</span><span class="identifier" id="pl.treksoft.kvision.utils.Cache$get(pl.treksoft.kvision.utils.Cache.K)/key">key</span><span class="symbol">:</span> <a href="index.html#K"><span class="identifier">K</span></a><span class="symbol">)</span><span class="symbol">: </span><a href="index.html#V"><span class="identifier">V</span></a><span class="symbol">?</span></code> +<p><a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.collections/-hash-map/index.html">HashMap</a> get is O(1). +More info: https://stackoverflow.com/a/4578039/2085356</p> +</BODY> +</HTML> diff --git a/api1/pl.treksoft.kvision.utils/-cache/index.html b/api1/pl.treksoft.kvision.utils/-cache/index.html new file mode 100644 index 00000000..15c207b0 --- /dev/null +++ b/api1/pl.treksoft.kvision.utils/-cache/index.html @@ -0,0 +1,78 @@ +<HTML> +<HEAD> +<meta charset="UTF-8"> +<title>Cache - kvision</title> +<link rel="stylesheet" href="../../../style.css"> +</HEAD> +<BODY> +<a href="../../index.html">kvision</a> / <a href="../index.html">pl.treksoft.kvision.utils</a> / <a href="./index.html">Cache</a><br/> +<br/> +<h1>Cache</h1> +<code><span class="keyword">class </span><span class="identifier">Cache</span><span class="symbol"><</span><span class="identifier">K</span><span class="symbol">, </span><span class="identifier">V</span><span class="symbol">></span></code> +<p>This is a LRU cache that has no performance impact for cache insertions +once the capacity of the cache has been reached. For cache hit, +performance is O(1) and for cache eviction, it is O(1).</p> +<h3>Constructors</h3> +<table> +<tbody> +<tr> +<td> +<p><a href="-init-.html"><init></a></p> +</td> +<td> +<code><span class="identifier">Cache</span><span class="symbol">(</span><span class="identifier" id="pl.treksoft.kvision.utils.Cache$<init>(kotlin.Int)/capacity">capacity</span><span class="symbol">:</span> <a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-int/index.html"><span class="identifier">Int</span></a> <span class="symbol">=</span> 50<span class="symbol">)</span></code> +<p>This is a LRU cache that has no performance impact for cache insertions +once the capacity of the cache has been reached. For cache hit, +performance is O(1) and for cache eviction, it is O(1).</p> +</td> +</tr> +</tbody> +</table> +<h3>Functions</h3> +<table> +<tbody> +<tr> +<td> +<p><a href="get.html">get</a></p> +</td> +<td> +<code><span class="keyword">operator</span> <span class="keyword">fun </span><span class="identifier">get</span><span class="symbol">(</span><span class="identifier" id="pl.treksoft.kvision.utils.Cache$get(pl.treksoft.kvision.utils.Cache.K)/key">key</span><span class="symbol">:</span> <a href="index.html#K"><span class="identifier">K</span></a><span class="symbol">)</span><span class="symbol">: </span><a href="index.html#V"><span class="identifier">V</span></a><span class="symbol">?</span></code> +<p><a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.collections/-hash-map/index.html">HashMap</a> get is O(1). +More info: https://stackoverflow.com/a/4578039/2085356</p> +</td> +</tr> +<tr> +<td> +<p><a href="set.html">set</a></p> +</td> +<td> +<code><span class="keyword">operator</span> <span class="keyword">fun </span><span class="identifier">set</span><span class="symbol">(</span><span class="identifier" id="pl.treksoft.kvision.utils.Cache$set(pl.treksoft.kvision.utils.Cache.K, pl.treksoft.kvision.utils.Cache.V)/key">key</span><span class="symbol">:</span> <a href="index.html#K"><span class="identifier">K</span></a><span class="symbol">, </span><span class="identifier" id="pl.treksoft.kvision.utils.Cache$set(pl.treksoft.kvision.utils.Cache.K, pl.treksoft.kvision.utils.Cache.V)/value">value</span><span class="symbol">:</span> <a href="index.html#V"><span class="identifier">V</span></a><span class="symbol">)</span><span class="symbol">: </span><a href="index.html#K"><span class="identifier">K</span></a><span class="symbol">?</span></code> +<p><a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.collections/-hash-map/index.html">HashMap</a> put and remove is O(1). +More info: https://stackoverflow.com/a/4578039/2085356</p> +</td> +</tr> +<tr> +<td> +<p><a href="to-string.html">toString</a></p> +</td> +<td> +<code><span class="keyword">fun </span><span class="identifier">toString</span><span class="symbol">(</span><span class="symbol">)</span><span class="symbol">: </span><a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html"><span class="identifier">String</span></a></code></td> +</tr> +</tbody> +</table> +<h3>Extension Functions</h3> +<table> +<tbody> +<tr> +<td> +<p><a href="../kotlin.-any/create-instance.html">createInstance</a></p> +</td> +<td> +<code><span class="keyword">fun </span><span class="symbol"><</span><span class="identifier">T</span><span class="symbol">></span> <a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-any/index.html"><span class="identifier">Any</span></a><span class="symbol">?</span><span class="symbol">.</span><span class="identifier">createInstance</span><span class="symbol">(</span><span class="keyword">vararg</span> <span class="identifier" id="pl.treksoft.kvision.utils$createInstance(kotlin.Any, kotlin.Array((kotlin.Any)))/args">args</span><span class="symbol">:</span> <span class="keyword">dynamic</span><span class="symbol">)</span><span class="symbol">: </span><a href="../kotlin.-any/create-instance.html#T"><span class="identifier">T</span></a></code> +<p>Helper function for creating JavaScript objects from dynamic constructors.</p> +</td> +</tr> +</tbody> +</table> +</BODY> +</HTML> diff --git a/api1/pl.treksoft.kvision.utils/-cache/set.html b/api1/pl.treksoft.kvision.utils/-cache/set.html new file mode 100644 index 00000000..1d3c6baa --- /dev/null +++ b/api1/pl.treksoft.kvision.utils/-cache/set.html @@ -0,0 +1,16 @@ +<HTML> +<HEAD> +<meta charset="UTF-8"> +<title>Cache.set - kvision</title> +<link rel="stylesheet" href="../../../style.css"> +</HEAD> +<BODY> +<a href="../../index.html">kvision</a> / <a href="../index.html">pl.treksoft.kvision.utils</a> / <a href="index.html">Cache</a> / <a href="./set.html">set</a><br/> +<br/> +<h1>set</h1> +<a name="pl.treksoft.kvision.utils.Cache$set(pl.treksoft.kvision.utils.Cache.K, pl.treksoft.kvision.utils.Cache.V)"></a> +<code><span class="keyword">operator</span> <span class="keyword">fun </span><span class="identifier">set</span><span class="symbol">(</span><span class="identifier" id="pl.treksoft.kvision.utils.Cache$set(pl.treksoft.kvision.utils.Cache.K, pl.treksoft.kvision.utils.Cache.V)/key">key</span><span class="symbol">:</span> <a href="index.html#K"><span class="identifier">K</span></a><span class="symbol">, </span><span class="identifier" id="pl.treksoft.kvision.utils.Cache$set(pl.treksoft.kvision.utils.Cache.K, pl.treksoft.kvision.utils.Cache.V)/value">value</span><span class="symbol">:</span> <a href="index.html#V"><span class="identifier">V</span></a><span class="symbol">)</span><span class="symbol">: </span><a href="index.html#K"><span class="identifier">K</span></a><span class="symbol">?</span></code> +<p><a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.collections/-hash-map/index.html">HashMap</a> put and remove is O(1). +More info: https://stackoverflow.com/a/4578039/2085356</p> +</BODY> +</HTML> diff --git a/api1/pl.treksoft.kvision.utils/-cache/to-string.html b/api1/pl.treksoft.kvision.utils/-cache/to-string.html new file mode 100644 index 00000000..cd476dfd --- /dev/null +++ b/api1/pl.treksoft.kvision.utils/-cache/to-string.html @@ -0,0 +1,14 @@ +<HTML> +<HEAD> +<meta charset="UTF-8"> +<title>Cache.toString - kvision</title> +<link rel="stylesheet" href="../../../style.css"> +</HEAD> +<BODY> +<a href="../../index.html">kvision</a> / <a href="../index.html">pl.treksoft.kvision.utils</a> / <a href="index.html">Cache</a> / <a href="./to-string.html">toString</a><br/> +<br/> +<h1>toString</h1> +<a name="pl.treksoft.kvision.utils.Cache$toString()"></a> +<code><span class="keyword">fun </span><span class="identifier">toString</span><span class="symbol">(</span><span class="symbol">)</span><span class="symbol">: </span><a href="https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html"><span class="identifier">String</span></a></code> +</BODY> +</HTML> |