aboutsummaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorShulhan <m.shulhan@gmail.com>2019-08-28 23:59:56 +0700
committerShulhan <m.shulhan@gmail.com>2019-08-28 23:59:56 +0700
commit292bbb29aa44ff3a1632b27715596b2b00b77589 (patch)
treef1ca497d5635d5f85835e46fdd816378c6f38780 /lib
parentc4468122196b768c71c0abe4edc57265905decdf (diff)
downloadpakakeh.go-292bbb29aa44ff3a1632b27715596b2b00b77589.tar.xz
all: replace document generator from asciidoctor to ciigo
Previously, generating HTML files from asciidoc files require installing ruby, asciidoctor, and its dependency through Gemfile. To simplify this, we replace it with ciigo. Ciigo not only can convert the asciidoc files but it also support serving the file inside HTTP server and watching changes on asciidoc files during development for local previewing.
Diffstat (limited to 'lib')
-rw-r--r--lib/contact/README.html55
-rw-r--r--lib/dsv/README.html365
-rw-r--r--lib/mining/README.html63
-rw-r--r--lib/numbers/README.html55
-rw-r--r--lib/tabula/README.html177
-rw-r--r--lib/websocket/AUTOBAHN.html110
-rw-r--r--lib/websocket/BENCHMARK.html175
7 files changed, 953 insertions, 47 deletions
diff --git a/lib/contact/README.html b/lib/contact/README.html
new file mode 100644
index 00000000..458931a0
--- /dev/null
+++ b/lib/contact/README.html
@@ -0,0 +1,55 @@
+<!DOCTYPE html>
+<html>
+ <head>
+ <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
+ <meta name="viewport" content="width=device-width, initial-scale=1" />
+ <meta name="theme-color" content="#375EAB" />
+
+ <title></title>
+ </head>
+ <body>
+ <div class="topbar">
+ <div class="container">
+ <div class="top-heading">
+ <a href="/">github.com/shuLhan/share</a>
+ </div>
+ <div class="menu">
+ <a href="https://godoc.org/github.com/shuLhan/share">GoDoc</a>
+ </div>
+ <div class="menu">
+ <a href="/CHANGELOG.html">Changelog</a>
+ </div>
+ </div>
+ </div>
+
+ <div class="page">
+ <div class="container">
+ <h1></h1>
+ <p><a href="https://godoc.org/github.com/shuLhan/share/lib/contact"><img src="https://godoc.org/github.com/shuLhan/share/lib/contact?status.svg" alt="GoDoc"></a>
+<a href="https://goreportcard.com/report/github.com/shuLhan/share/lib/contact"><img src="https://goreportcard.com/badge/github.com/shuLhan/share/lib/contact" alt="Go Report Card"></a></p>
+<h1>contact</h1>
+<p>The Go library to manage contacts.</p>
+<h2>Features</h2>
+<ul>
+<li>Import Google's contacts v3 with OAuth2</li>
+<li>Import Yahoo's contacts with OAuth2</li>
+<li>Import Microsoft's Live/Outlook contacts with OAuth2</li>
+</ul>
+<h2>TODO</h2>
+<ul>
+<li>VCard 4.0 Encode and Decode</li>
+</ul>
+
+ </div>
+
+ </div>
+
+
+ <div class="footer">
+ Copyright 2019, Shulhan &lt;ms@kilabit.info&gt;. All rights reserved.
+ <br />
+ Use of this source code is governed by a BSD-style license that can be
+ found in the <a href="/LICENSE">LICENSE</a> file.
+ </div>
+ </body>
+</html>
diff --git a/lib/dsv/README.html b/lib/dsv/README.html
new file mode 100644
index 00000000..cf1c2e8b
--- /dev/null
+++ b/lib/dsv/README.html
@@ -0,0 +1,365 @@
+<!DOCTYPE html>
+<html>
+ <head>
+ <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
+ <meta name="viewport" content="width=device-width, initial-scale=1" />
+ <meta name="theme-color" content="#375EAB" />
+
+ <title></title>
+ </head>
+ <body>
+ <div class="topbar">
+ <div class="container">
+ <div class="top-heading">
+ <a href="/">github.com/shuLhan/share</a>
+ </div>
+ <div class="menu">
+ <a href="https://godoc.org/github.com/shuLhan/share">GoDoc</a>
+ </div>
+ <div class="menu">
+ <a href="/CHANGELOG.html">Changelog</a>
+ </div>
+ </div>
+ </div>
+
+ <div class="page">
+ <div class="container">
+ <h1></h1>
+ <p><a href="https://godoc.org/github.com/shuLhan/share/lib/dsv"><img src="https://godoc.org/github.com/shuLhan/share/lib/dsv?status.svg" alt="GoDoc"></a>
+<a href="https://goreportcard.com/report/github.com/shuLhan/share/lib/dsv"><img src="https://goreportcard.com/badge/github.com/shuLhan/share/lib/dsv" alt="Go Report Card"></a></p>
+<p>Package <code>dsv</code> is a Go library for working with delimited separated value (DSV).</p>
+<p>DSV is a free-style form of CSV format of text data, where each record is
+separated by newline, and each column can be separated by any string, not just
+comma.</p>
+<ul>
+<li><a href="#example">Example</a></li>
+<li><a href="#terminology">Terminology</a></li>
+<li><a href="#configuration">Configuration</a>
+<ul>
+<li><a href="#metadata">Metadata</a></li>
+<li><a href="#input">Input</a>
+<ul>
+<li><a href="#datasetmode-explained">DatasetMode Explained</a></li>
+</ul>
+</li>
+<li><a href="#output">Output</a></li>
+</ul>
+</li>
+<li><a href="#working-with-dsv">Working with DSV</a>
+<ul>
+<li><a href="#processing-each-rowscolumns">Processing each Rows/Columns</a></li>
+<li><a href="#using-different-dataset">Using different Dataset</a></li>
+<li><a href="#builtin-functions-for-dataset">Builtin Functions for Dataset</a></li>
+</ul>
+</li>
+<li><a href="#limitations">Limitations</a></li>
+</ul>
+<hr>
+<h2>Example</h2>
+<p>Lets process this input file <code>input.dat</code>,</p>
+<pre><code>Mon Dt HH MM SS Process
+Nov 29 23:14:36 process-1
+Nov 29 23:14:37 process-2
+Nov 29 23:14:38 process-3
+</code></pre>
+<p>and generate output file <code>output.dat</code> which format like this,</p>
+<pre><code>&quot;process_1&quot;,&quot;29-Nov&quot;
+&quot;process_2&quot;,&quot;29-Nov&quot;
+&quot;process_3&quot;,&quot;29-Nov&quot;
+</code></pre>
+<p>How do we do it?</p>
+<p>First, create file metadata for input and output, name it <code>config.dsv</code>,</p>
+<pre><code>{
+ &quot;Input&quot; :&quot;input.dat&quot;
+, &quot;Skip&quot; :1
+, &quot;InputMetadata&quot; :
+ [{
+ &quot;Name&quot; :&quot;month&quot;
+ , &quot;Separator&quot; :&quot; &quot;
+ },{
+ &quot;Name&quot; :&quot;date&quot;
+ , &quot;Separator&quot; :&quot; &quot;
+ , &quot;Type&quot; :&quot;integer&quot;
+ },{
+ &quot;Name&quot; :&quot;hour&quot;
+ , &quot;Separator&quot; :&quot;:&quot;
+ , &quot;Type&quot; :&quot;integer&quot;
+ },{
+ &quot;Name&quot; :&quot;minute&quot;
+ , &quot;Separator&quot; :&quot;:&quot;
+ , &quot;Type&quot; :&quot;integer&quot;
+ },{
+ &quot;Name&quot; :&quot;second&quot;
+ , &quot;Separator&quot; :&quot; &quot;
+ , &quot;Type&quot; :&quot;integer&quot;
+ },{
+ &quot;Name&quot; :&quot;process_name&quot;
+ , &quot;Separator&quot; :&quot;-&quot;
+ },{
+ &quot;Name&quot; :&quot;process_id&quot;
+ }]
+, &quot;Output&quot; :&quot;output.dat&quot;
+, &quot;OutputMetadata&quot;:
+ [{
+ &quot;Name&quot; :&quot;process_name&quot;
+ , &quot;LeftQuote&quot; :&quot;\&quot;&quot;
+ , &quot;Separator&quot; :&quot;_&quot;
+ },{
+ &quot;Name&quot; :&quot;process_id&quot;
+ , &quot;RightQuote&quot;:&quot;\&quot;&quot;
+ , &quot;Separator&quot; :&quot;,&quot;
+ },{
+ &quot;Name&quot; :&quot;date&quot;
+ , &quot;LeftQuote&quot; :&quot;\&quot;&quot;
+ , &quot;Separator&quot; :&quot;-&quot;
+ },{
+ &quot;Name&quot; :&quot;month&quot;
+ , &quot;RightQuote&quot;:&quot;\&quot;&quot;
+ }]
+}
+</code></pre>
+<p>The metadata is using JSON format. For more information see <code>metadata.go</code>
+and <code>reader.go</code>.</p>
+<p>Second, we create a reader to read the input file.</p>
+<pre><code>dsvReader, e := dsv.NewReader(&quot;config.dsv&quot;, nil)
+
+if nil != e {
+ t.Fatal(e)
+}
+</code></pre>
+<p>Third, we create a writer to write our output data,</p>
+<pre><code>dsvWriter, e := dsv.NewWriter(&quot;config.dsv&quot;)
+
+if nil != e {
+ t.Error(e)
+}
+</code></pre>
+<p>Last action, we process them: read input records and pass them to writer.</p>
+<pre><code>for {
+ n, e := dsv.Read(dsvReader)
+
+ if n &gt; 0 {
+ dsvWriter.Write(dsvReader)
+
+ // EOF, no more record.
+ } else if e == io.EOF {
+ break
+ }
+}
+
+// we will make sure all open descriptor is closed.
+_ = dsvReader.Close()
+</code></pre>
+<p>Easy enough? We can combine the reader and writer using <code>dsv.New()</code>, which will
+create reader and writer,</p>
+<pre><code>rw, e := dsv.New(&quot;config.dsv&quot;, nil)
+
+if nil != e {
+ t.Error(e)
+}
+
+// do usual process like in the last step.
+</code></pre>
+<p>Thats it!</p>
+<h2>Terminology</h2>
+<p>Here are some terminology that we used in developing this library, which may
+help reader understanding the configuration and API.</p>
+<ul>
+<li>Dataset: is a content of file</li>
+<li>Record: a single cell in row or column, or the smallest building block of
+dataset</li>
+<li>Row: is a horizontal representation of records in dataset</li>
+<li>Column: is a vertical representation of records in dataset</li>
+</ul>
+<pre><code> COL-0 COL-1 ... COL-x
+ROW-0: record record ... record
+ROW-1: record record ... record
+...
+ROW-y: record record ... record
+</code></pre>
+<h2>Configuration</h2>
+<p>We choose and use JSON for configuration because,</p>
+<ol>
+<li>No additional source to test.</li>
+<li>Easy to extended. User can embed the current metadata, add additional
+configuration, and create another reader to work with it.</li>
+</ol>
+<h3>Metadata</h3>
+<p>Metadata contain information about each column when reading input file and
+writing to output file,</p>
+<ul>
+<li><code>Name</code>: mandatory, the name of column</li>
+<li><code>Type</code>: optional, type of record when reading input file. Valid value are
+&quot;integer&quot;, &quot;real&quot;, or &quot;string&quot; (default)</li>
+<li><code>Separator</code>: optional, default to <code>&quot;\n&quot;</code>. Separator is a string that
+separate the current record with the next record.</li>
+<li><code>LeftQuote</code>: optional, default is empty <code>&quot;&quot;</code>. LeftQuote is a string that
+start at the beginning of record.</li>
+<li><code>RightQuote</code>: optional, default is empty <code>&quot;&quot;</code>. RightQuote is a string at the
+end of record.</li>
+<li><code>Skip</code>: optional, boolean, default is <code>false</code>. If true the column will be
+saved in dataset when reading input file, otherwise it will be ignored.</li>
+<li><code>ValueSpace</code>: optional, slice of string, default is empty. This contain the
+string representation of all possible value in column.</li>
+</ul>
+<h3>Input</h3>
+<p>Input configuration contain information about input file.</p>
+<ul>
+<li><code>Input</code>: mandatory, the name of input file, could use relative or absolute
+path. If no path is given then it assumed that the input file is in the same
+directory with configuration file.</li>
+<li><code>InputMetadata</code>: mandatory, list of metadata.</li>
+<li><code>Skip</code>: optional, number, default 0. Skip define the number of line that will
+be skipped when first input file is opened.</li>
+<li><code>TrimSpace</code>: optional, boolean, default is true. If its true, before parsed, the
+white space in the beginning and end of each input line will be removed,
+otherwise it will leave unmodified.</li>
+<li><code>Rejected</code>: optional, default to <code>rejected.dat</code>. Rejected is file where
+data that does not match with metadata will be saved. One can inspect the
+rejected file fix it for re-process or ignore it.</li>
+<li><code>MaxRows</code>: optional, default to <code>256</code>. Maximum number of rows for one read
+operation that will be saved in memory. If its negative, i.e. <code>-1</code>, all data
+in input file will be processed.</li>
+<li><code>DatasetMode</code>: optional, default to &quot;rows&quot;. Mode of dataset in memory.
+Valid values are &quot;rows&quot;, &quot;columns&quot;, or &quot;matrix&quot;. Matrix mode is combination of
+rows and columns, it give more flexibility when processing the dataset but
+will require additional memory.</li>
+</ul>
+<h4><code>DatasetMode</code> Explained</h4>
+<p>For example, given input data file,</p>
+<pre><code>col1,col2,col3
+a,b,c
+1,2,3
+</code></pre>
+<p>&quot;rows&quot; mode is where each line saved in its own slice, resulting in Rows:</p>
+<pre><code>Rows[0]: [a b c]
+Rows[1]: [1 2 3]
+</code></pre>
+<p>&quot;columns&quot; mode is where each line saved by columns, resulting in Columns:</p>
+<pre><code>Columns[0]: {col1 0 0 [] [a 1]}
+Columns[1]: {col2 0 0 [] [b 2]}
+Columns[1]: {col3 0 0 [] [c 3]}
+</code></pre>
+<p>Unlike rows mode, each column contain metadata including column name, type,
+flag, and value space (all possible value that <em>may</em> contain in column value).</p>
+<p>&quot;matrix&quot; mode is where each record saved both in row and column.</p>
+<h3>Output</h3>
+<p>Output configuration contain information about output file when writing the
+dataset.</p>
+<ul>
+<li><code>Output</code>: mandatory, the name of output file, could use relative or absolute
+path. If no path is given then it assumed that the output file is in the same
+directory with configuration file.</li>
+<li><code>OutputMetadata</code>: mandatory, list of metadata.</li>
+</ul>
+<h2>Working with DSV</h2>
+<h3>Processing each Rows/Columns</h3>
+<p>After opening the input file, we can process the dataset based on rows/columns
+mode using simple <code>for</code> loop. Example,</p>
+<pre><code>// Save dataset object for used later.
+dataset := dsvReader.GetDataset().(tabula.DatasetInterface)
+
+for {
+ n, e := dsv.Read(dsvReader)
+
+ if n &gt; 0 {
+ // Process each row ...
+ for x, row := dataset.GetDataAsRows() {
+
+ for y, record := range row.Records {
+ // process each record in row
+ }
+ }
+
+ // Or, process each columns
+ for x, column := dataset.GetDataAsColumns() {
+
+ for y, record := range column.Records {
+ // process each record in column
+ }
+ }
+
+ // Write the dataset to file after processed
+ dsvWriter.Write(dsvReader)
+ }
+ if e == io.EOF {
+ break
+ }
+ if e != nil {
+ // handle error
+ }
+}
+</code></pre>
+<h3>Using different Dataset</h3>
+<p>Default dataset used by Reader is
+<a href="https://godoc.org/github.com/shuLhan/share/lib/tabula#Dataset">tabula.Dataset</a>.</p>
+<p>You can extend and implement
+<a href="https://godoc.org/github.com/shuLhan/share/lib/tabula#DatasetInterface">DatasetInterface</a>
+and use it in reader object, either by</p>
+<ul>
+<li>
+<p>passing it in the second parameter in <code>NewReader</code>, for example,</p>
+<pre><code>myset := MySet{
+ ...
+}
+reader, e := dsv.NewReader(&quot;config.dsv&quot;, &amp;myset)
+</code></pre>
+</li>
+<li>
+<p>or by calling <code>reader.Init</code> after creating new Reader,</p>
+<pre><code>myset := MySet{
+ ...
+}
+reader := dsv.Reader{
+ ...
+}
+reader.Init(&quot;config.dsv&quot;, &amp;myset)
+</code></pre>
+</li>
+</ul>
+<h3>Builtin Functions for Dataset</h3>
+<p>Since we use tabula package to manage data, any features in those package
+can be used in our dataset.
+For more information see <a href="https://godoc.org/github.com/shuLhan/share/lib/tabula">tabula
+package</a>.</p>
+<h2>Limitations</h2>
+<ul>
+<li>
+<p>New line is <code>\n</code> for each row.</p>
+</li>
+<li>
+<p>Reader and Writer operate in ASCII (8 bit or char type), UTF-8 is not
+supported yet, since we can not test it. Patch for supporting UTF-8 (or
+runes type) are welcome.</p>
+</li>
+<li>
+<p>About escaped character in content of data.</p>
+<p>Since we said that we handle free-style form of CSV, what we mean was the
+left-quote, right-quote and separator can be string. Its not only one single
+character like single quote or double quote or any single character, but
+literally one or more characters without space. Any escaped character will be
+read as is (along with <code>'\'</code>) unless its followed by right-quote or separator.
+For example,</p>
+<pre><code>&quot;test\'&quot;
+</code></pre>
+<p>will be readed as <code>test\'</code>. But</p>
+<pre><code>&quot;test\&quot;&quot;
+</code></pre>
+<p>will be readed as <code>test&quot;</code>, since the right-quote is matched with escaped
+token.</p>
+</li>
+</ul>
+
+ </div>
+
+ </div>
+
+
+ <div class="footer">
+ Copyright 2019, Shulhan &lt;ms@kilabit.info&gt;. All rights reserved.
+ <br />
+ Use of this source code is governed by a BSD-style license that can be
+ found in the <a href="/LICENSE">LICENSE</a> file.
+ </div>
+ </body>
+</html>
diff --git a/lib/mining/README.html b/lib/mining/README.html
new file mode 100644
index 00000000..76909fc1
--- /dev/null
+++ b/lib/mining/README.html
@@ -0,0 +1,63 @@
+<!DOCTYPE html>
+<html>
+ <head>
+ <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
+ <meta name="viewport" content="width=device-width, initial-scale=1" />
+ <meta name="theme-color" content="#375EAB" />
+
+ <title></title>
+ </head>
+ <body>
+ <div class="topbar">
+ <div class="container">
+ <div class="top-heading">
+ <a href="/">github.com/shuLhan/share</a>
+ </div>
+ <div class="menu">
+ <a href="https://godoc.org/github.com/shuLhan/share">GoDoc</a>
+ </div>
+ <div class="menu">
+ <a href="/CHANGELOG.html">Changelog</a>
+ </div>
+ </div>
+ </div>
+
+ <div class="page">
+ <div class="container">
+ <h1></h1>
+ <p><a href="https://godoc.org/github.com/shuLhan/share/lib/mining"><img src="https://godoc.org/github.com/shuLhan/share/lib/mining?status.svg" alt="GoDoc"></a>
+<a href="https://goreportcard.com/report/github.com/shuLhan/share/lib/mining"><img src="https://goreportcard.com/badge/github.com/shuLhan/share/lib/mining" alt="Go Report Card"></a></p>
+<h1>go-mining</h1>
+<p>Go-mining is a small library for data mining.</p>
+<p>The library is written in <a href="golang/go">Go language</a>.</p>
+<h2>Features</h2>
+<h3>Classifiers</h3>
+<ul>
+<li>CART</li>
+<li>Random Forest</li>
+<li>Cascaded Random Forest</li>
+<li>K-Nearest Neighbourhood</li>
+</ul>
+<h3>Resampling</h3>
+<ul>
+<li>SMOTE</li>
+<li>LN-SMOTE (Local Neigbourhood SMOTE)</li>
+</ul>
+<h3>Miscellaneous</h3>
+<ul>
+<li>Gini index</li>
+</ul>
+
+ </div>
+
+ </div>
+
+
+ <div class="footer">
+ Copyright 2019, Shulhan &lt;ms@kilabit.info&gt;. All rights reserved.
+ <br />
+ Use of this source code is governed by a BSD-style license that can be
+ found in the <a href="/LICENSE">LICENSE</a> file.
+ </div>
+ </body>
+</html>
diff --git a/lib/numbers/README.html b/lib/numbers/README.html
new file mode 100644
index 00000000..22ec9243
--- /dev/null
+++ b/lib/numbers/README.html
@@ -0,0 +1,55 @@
+<!DOCTYPE html>
+<html>
+ <head>
+ <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
+ <meta name="viewport" content="width=device-width, initial-scale=1" />
+ <meta name="theme-color" content="#375EAB" />
+
+ <title></title>
+ </head>
+ <body>
+ <div class="topbar">
+ <div class="container">
+ <div class="top-heading">
+ <a href="/">github.com/shuLhan/share</a>
+ </div>
+ <div class="menu">
+ <a href="https://godoc.org/github.com/shuLhan/share">GoDoc</a>
+ </div>
+ <div class="menu">
+ <a href="/CHANGELOG.html">Changelog</a>
+ </div>
+ </div>
+ </div>
+
+ <div class="page">
+ <div class="container">
+ <h1></h1>
+ <p><a href="https://godoc.org/github.com/shuLhan/share/lib/numbers"><img src="https://godoc.org/github.com/shuLhan/share/lib/numbers?status.svg" alt="GoDoc"></a>
+<a href="https://goreportcard.com/report/github.com/shuLhan/share/lib/numbers"><img src="https://goreportcard.com/badge/github.com/shuLhan/share/lib/numbers" alt="Go Report Card"></a></p>
+<p>Package <code>numbers</code> provide functions for working with integer, float, slice of
+integers, and slice of floats.</p>
+<p>Currently it have function to,</p>
+<ul>
+<li>sort slice of floats using in-place mergesort algorithm</li>
+<li>sort slice of integer/floats by predefined index</li>
+<li>count number of value occurence in slice of integer/float</li>
+<li>find minimum or maximum value in slice of integer/float</li>
+<li>sum slice of integer/float</li>
+</ul>
+<p>See <a href="https://godoc.org/github.com/shuLhan/share/lib/numbers">documentation</a>
+for more information.</p>
+
+ </div>
+
+ </div>
+
+
+ <div class="footer">
+ Copyright 2019, Shulhan &lt;ms@kilabit.info&gt;. All rights reserved.
+ <br />
+ Use of this source code is governed by a BSD-style license that can be
+ found in the <a href="/LICENSE">LICENSE</a> file.
+ </div>
+ </body>
+</html>
diff --git a/lib/tabula/README.html b/lib/tabula/README.html
new file mode 100644
index 00000000..ca10e819
--- /dev/null
+++ b/lib/tabula/README.html
@@ -0,0 +1,177 @@
+<!DOCTYPE html>
+<html>
+ <head>
+ <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
+ <meta name="viewport" content="width=device-width, initial-scale=1" />
+ <meta name="theme-color" content="#375EAB" />
+
+ <title></title>
+ </head>
+ <body>
+ <div class="topbar">
+ <div class="container">
+ <div class="top-heading">
+ <a href="/">github.com/shuLhan/share</a>
+ </div>
+ <div class="menu">
+ <a href="https://godoc.org/github.com/shuLhan/share">GoDoc</a>
+ </div>
+ <div class="menu">
+ <a href="/CHANGELOG.html">Changelog</a>
+ </div>
+ </div>
+ </div>
+
+ <div class="page">
+ <div class="container">
+ <h1></h1>
+ <p><a href="https://godoc.org/github.com/shuLhan/share/lib/tabula"><img src="https://godoc.org/github.com/shuLhan/share/lib/tabula?status.svg" alt="GoDoc"></a>
+<a href="https://goreportcard.com/report/github.com/shuLhan/share/lib/tabula"><img src="https://goreportcard.com/badge/github.com/shuLhan/share/lib/tabula" alt="Go Report Card"></a>
+<img src="https://cover.run/go/github.com/shuLhan/share/lib/tabula.svg" alt="cover.run go"></p>
+<p>Package tabula is a Go library for working with rows, columns, or matrix
+(table), or in another terms working with data set.</p>
+<h1>Overview</h1>
+<p>Go's slice gave a flexible way to manage sequence of data in one type, but what
+if you want to manage a sequence of value but with different type of data?
+Or manage a bunch of values like a table?</p>
+<p>You can use this library to manage sequence of value with different type
+and manage data in two dimensional tuple.</p>
+<h2>Terminology</h2>
+<p>Here are some terminologies that we used in developing this library, which may
+help reader understand the internal and API.</p>
+<p>Record is a single cell in row or column, or the smallest building block of
+dataset.</p>
+<p>Row is a horizontal representation of records in dataset.</p>
+<p>Column is a vertical representation of records in dataset.
+Each column has a unique name and has the same type data.</p>
+<p>Dataset is a collection of rows and columns.</p>
+<p>Given those definitions we can draw the representation of rows, columns, or
+matrix:</p>
+<pre><code> COL-0 COL-1 ... COL-x
+ROW-0: record record ... record
+ROW-1: record record ... record
+...
+ROW-y: record record ... record
+</code></pre>
+<h2>What make this package different from other dataset packages?</h2>
+<h3>Record Type</h3>
+<p>There are only three valid type in record: int64, float64, and string.</p>
+<p>Each record is a pointer to interface value. Which means,</p>
+<ul>
+<li>Switching between rows to columns mode, or vice versa, is only a matter of
+pointer switching, no memory relocations.</li>
+<li>When using matrix mode, additional memory is used only to allocate slice, the
+record in each rows and columns is shared.</li>
+</ul>
+<h3>Dataset Mode</h3>
+<p>Tabula has three mode for dataset: rows, columns, or matrix.</p>
+<p>For example, given a table of data,</p>
+<pre><code>col1,col2,col3
+a,b,c
+1,2,3
+</code></pre>
+<ul>
+<li>
+<p>When in &quot;rows&quot; mode, each line is saved in its own slice, resulting in Rows:</p>
+<pre><code>Rows[0]: [a b c]
+Rows[1]: [1 2 3]
+</code></pre>
+<p>Columns is used only to save record metadata: column name, type, flag and
+value space.</p>
+</li>
+<li>
+<p>When in &quot;columns&quot; mode, each line saved in columns, resulting in Columns:</p>
+<pre><code>Columns[0]: {col1 0 0 [] [a 1]}
+Columns[1]: {col2 0 0 [] [b 2]}
+Columns[1]: {col3 0 0 [] [c 3]}
+</code></pre>
+<p>Each column will contain metadata including column name, type, flag, and
+value space (all possible value that <em>may</em> contain in column value).</p>
+<p>Rows in &quot;columns&quot; mode is empty.</p>
+</li>
+<li>
+<p>When in &quot;matrix&quot; mode, each record is saved both in row and column using
+shared pointer to record.</p>
+<p>Matrix mode consume more memory by allocating two slice in rows and columns,
+but give flexible way to manage records.</p>
+</li>
+</ul>
+<h2>Features</h2>
+<ul>
+<li>
+<p><strong>Switching between rows and columns mode</strong>.</p>
+</li>
+<li>
+<p><a href="https://godoc.org/github.com/shuLhan/share/lib/tabula#RandomPickRows"><strong>Random pick rows with or without replacement</strong></a>.</p>
+</li>
+<li>
+<p><a href="https://godoc.org/github.com/shuLhan/share/lib/tabula#RandomPickColumns"><strong>Random pick columns with or without replacement</strong></a>.</p>
+</li>
+<li>
+<p><a href="https://godoc.org/github.com/shuLhan/share/lib/tabula#SelectColumnsByIdx"><strong>Select column from dataset by index</strong></a>.</p>
+</li>
+<li>
+<p><a href="https://godoc.org/github.com/shuLhan/share/lib/tabula#SortColumnsByIndex"><strong>Sort columns by index</strong></a>,
+or indirect sort.</p>
+</li>
+<li>
+<p><a href="https://godoc.org/github.com/shuLhan/share/lib/tabula#SplitRowsByNumeric"><strong>Split rows value by numeric</strong></a>.
+For example, given two numeric rows,</p>
+<pre><code>A: {1,2,3,4}
+B: {5,6,7,8}
+</code></pre>
+<p>if we split row by value 7, the data will splitted into left set</p>
+<pre><code>A': {1,2}
+B': {5,6}
+</code></pre>
+<p>and the right set would be</p>
+<pre><code>A'': {3,4}
+B'': {7,8}
+</code></pre>
+</li>
+<li>
+<p><a href="https://godoc.org/github.com/shuLhan/share/lib/tabula#SplitRowsByCategorical"><strong>Split rows by string</strong></a>.
+For example, given two rows,</p>
+<pre><code>X: [A,B,A,B,C,D,C,D]
+Y: [1,2,3,4,5,6,7,8]
+</code></pre>
+<p>if we split the rows with value set <code>[A,C]</code>, the data will splitted into left
+set which contain all rows that have A or C,</p>
+<pre><code> X': [A,A,C,C]
+ Y': [1,3,5,7]
+</code></pre>
+<p>and the right set, excluded set, will contain all rows which is not A or C,</p>
+<pre><code> X'': [B,B,D,D]
+ Y'': [2,4,6,8]
+</code></pre>
+</li>
+<li>
+<p><a href="https://godoc.org/github.com/shuLhan/share/lib/tabula#SelectRowsWhere"><strong>Select row where</strong></a>.
+Select row at column index x where their value is equal to y (an analogy to
+<em>select where</em> in SQL).
+For example, given a rows of dataset,</p>
+<pre><code>ROW-1: {1,A}
+ROW-2: {2,B}
+ROW-3: {3,A}
+ROW-4: {4,C}
+</code></pre>
+<p>we can select row where the second column contain 'A', which result in,</p>
+<pre><code>ROW-1: {1,A}
+ROW-3: {3,A}
+</code></pre>
+</li>
+</ul>
+
+ </div>
+
+ </div>
+
+
+ <div class="footer">
+ Copyright 2019, Shulhan &lt;ms@kilabit.info&gt;. All rights reserved.
+ <br />
+ Use of this source code is governed by a BSD-style license that can be
+ found in the <a href="/LICENSE">LICENSE</a> file.
+ </div>
+ </body>
+</html>
diff --git a/lib/websocket/AUTOBAHN.html b/lib/websocket/AUTOBAHN.html
index 8f339c86..f8e58fa3 100644
--- a/lib/websocket/AUTOBAHN.html
+++ b/lib/websocket/AUTOBAHN.html
@@ -1,20 +1,31 @@
<!DOCTYPE html>
-<html lang="en">
-<head>
-<meta charset="UTF-8">
-<meta http-equiv="X-UA-Compatible" content="IE=edge">
-<meta name="viewport" content="width=device-width, initial-scale=1.0">
-<meta name="generator" content="Asciidoctor 2.0.9">
-<title>Autobahn WebSocket Testsuite Status Report</title>
-<link rel="stylesheet" href="https://fonts.googleapis.com/css?family=Open+Sans:300,300italic,400,400italic,600,600italic%7CNoto+Serif:400,400italic,700,700italic%7CDroid+Sans+Mono:400,700">
-<link rel="stylesheet" href="./asciidoctor.css">
-</head>
-<body class="article">
-<div id="header">
-<h1>Autobahn WebSocket Testsuite Status Report</h1>
-</div>
-<div id="content">
-<div id="preamble">
+<html>
+ <head>
+ <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
+ <meta name="viewport" content="width=device-width, initial-scale=1" />
+ <meta name="theme-color" content="#375EAB" />
+
+ <title>Autobahn WebSocket Testsuite Status Report</title>
+ </head>
+ <body>
+ <div class="topbar">
+ <div class="container">
+ <div class="top-heading">
+ <a href="/">github.com/shuLhan/share</a>
+ </div>
+ <div class="menu">
+ <a href="https://godoc.org/github.com/shuLhan/share">GoDoc</a>
+ </div>
+ <div class="menu">
+ <a href="/CHANGELOG.html">Changelog</a>
+ </div>
+ </div>
+ </div>
+
+ <div class="page">
+ <div class="container">
+ <h1>Autobahn WebSocket Testsuite Status Report</h1>
+ <div id="preamble">
<div class="sectionbody">
<div class="paragraph">
<p>This document track the status report from autobahn testsuite [1].</p>
@@ -30,10 +41,10 @@ package,</p>
</div>
<div class="literalblock">
<div class="content">
-<pre>$ cd testdata
-$ virtualenv .
-$ source ./bin/activate
-$ pip install autobahntestsuite</pre>
+<pre> $ cd testdata
+ $ virtualenv .
+ $ source ./bin/activate
+ $ pip install autobahntestsuite</pre>
</div>
</div>
</div>
@@ -46,9 +57,9 @@ $ pip install autobahntestsuite</pre>
</div>
<div class="literalblock">
<div class="content">
-<pre>$ cd testdata/server
-$ go build .
-$ ./server</pre>
+<pre> $ cd testdata/server
+ $ go build .
+ $ ./server</pre>
</div>
</div>
<div class="paragraph">
@@ -56,14 +67,14 @@ $ ./server</pre>
</div>
<div class="literalblock">
<div class="content">
-<pre>$ cd testdata/server
-$ source ../bin/activate
-$ wstest -m fuzzingclient</pre>
+<pre> $ cd testdata/server
+ $ source ../bin/activate
+ $ wstest -m fuzzingclient</pre>
</div>
</div>
<div class="paragraph">
<p>Wait for the test to complete. After that, we can view the reports on
-"reports/index.html".</p>
+&#34;reports/index.html&#34;.</p>
</div>
<div class="sect2">
<h3 id="_server_reports_status">Server Reports Status</h3>
@@ -166,8 +177,8 @@ points (11/11)
</ol>
</div>
<div class="paragraph">
-<p>Total test cases : 16 + 11 + 7 + 10 + 20 + 145 + 37 + 0 + 54 + 1 + 0 + 0 + 0 = 301
-Total success cases: 16 + 11 + 7 + 10 + 20 + 145 + 37 + 0 + 54 + 1 + 0 + 0 + 0 = 301</p>
+<p>Total test cases : 16 &#43; 11 &#43; 7 &#43; 10 &#43; 20 &#43; 145 &#43; 37 &#43; 0 &#43; 54 &#43; 1 &#43; 0 &#43; 0 &#43; 0 = 301
+Total success cases: 16 &#43; 11 &#43; 7 &#43; 10 &#43; 20 &#43; 145 &#43; 37 &#43; 0 &#43; 54 &#43; 1 &#43; 0 &#43; 0 &#43; 0 = 301</p>
</div>
<div class="paragraph">
<p>Success Rate = 100%</p>
@@ -183,9 +194,9 @@ Total success cases: 16 + 11 + 7 + 10 + 20 + 145 + 37 + 0 + 54 + 1 + 0 + 0 + 0 =
</div>
<div class="literalblock">
<div class="content">
-<pre>$ cd testdata/client
-$ source ../bin/activate
-$ wstest -m fuzzingserver</pre>
+<pre> $ cd testdata/client
+ $ source ../bin/activate
+ $ wstest -m fuzzingserver</pre>
</div>
</div>
<div class="paragraph">
@@ -193,15 +204,15 @@ $ wstest -m fuzzingserver</pre>
</div>
<div class="literalblock">
<div class="content">
-<pre>$ cd testdata/client
-$ go build .
-$ ./client</pre>
+<pre> $ cd testdata/client
+ $ go build .
+ $ ./client</pre>
</div>
</div>
<div class="paragraph">
<p>Wait for the test to complete. After that, open the browser at
-<a href="http://127.0.0.1:8080/test_browser.html" class="bare">http://127.0.0.1:8080/test_browser.html</a> , and click on "Update Reports
-(Manual)" to update client reports at "testdata/client/reports/index.html".</p>
+<a href="http://127.0.0.1:8080/test_browser.html , and click on "Update Reports" class="bare">http://127.0.0.1:8080/test_browser.html , and click on "Update Reports</a>
+(Manual)&#34; to update client reports at &#34;testdata/client/reports/index.html&#34;.</p>
</div>
<div class="sect2">
<h3 id="_client_reports_status">Client Reports Status</h3>
@@ -304,8 +315,8 @@ points (11/11)
</ol>
</div>
<div class="paragraph">
-<p>Total test cases : 16 + 11 + 7 + 10 + 20 + 145 + 37 + 0 + 54 + 1 + 0 + 0 + 0 = 301
-Total success cases: 16 + 11 + 7 + 10 + 20 + 145 + 37 + 0 + 54 + 1 + 0 + 0 + 0 = 301</p>
+<p>Total test cases : 16 &#43; 11 &#43; 7 &#43; 10 &#43; 20 &#43; 145 &#43; 37 &#43; 0 &#43; 54 &#43; 1 &#43; 0 &#43; 0 &#43; 0 = 301
+Total success cases: 16 &#43; 11 &#43; 7 &#43; 10 &#43; 20 &#43; 145 &#43; 37 &#43; 0 &#43; 54 &#43; 1 &#43; 0 &#43; 0 &#43; 0 = 301</p>
</div>
<div class="paragraph">
<p>Success Rate = 100%</p>
@@ -321,11 +332,16 @@ Total success cases: 16 + 11 + 7 + 10 + 20 + 145 + 37 + 0 + 54 + 1 + 0 + 0 + 0 =
</div>
</div>
</div>
-</div>
-<div id="footer">
-<div id="footer-text">
-Last updated 2019-04-04 13:49:10 +0700
-</div>
-</div>
-</body>
-</html> \ No newline at end of file
+ </div>
+
+ </div>
+
+
+ <div class="footer">
+ Copyright 2019, Shulhan &lt;ms@kilabit.info&gt;. All rights reserved.
+ <br />
+ Use of this source code is governed by a BSD-style license that can be
+ found in the <a href="/LICENSE">LICENSE</a> file.
+ </div>
+ </body>
+</html>
diff --git a/lib/websocket/BENCHMARK.html b/lib/websocket/BENCHMARK.html
new file mode 100644
index 00000000..93ea2c24
--- /dev/null
+++ b/lib/websocket/BENCHMARK.html
@@ -0,0 +1,175 @@
+<!DOCTYPE html>
+<html>
+ <head>
+ <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
+ <meta name="viewport" content="width=device-width, initial-scale=1" />
+ <meta name="theme-color" content="#375EAB" />
+
+ <title></title>
+ </head>
+ <body>
+ <div class="topbar">
+ <div class="container">
+ <div class="top-heading">
+ <a href="/">github.com/shuLhan/share</a>
+ </div>
+ <div class="menu">
+ <a href="https://godoc.org/github.com/shuLhan/share">GoDoc</a>
+ </div>
+ <div class="menu">
+ <a href="/CHANGELOG.html">Changelog</a>
+ </div>
+ </div>
+ </div>
+
+ <div class="page">
+ <div class="container">
+ <h1></h1>
+ <p>This note document a benchmark between gobwas vs our websocket library.</p>
+<h1>github.com/gobwas/ws@v0.1.0</h1>
+<h2>Go v1.10.3</h2>
+<pre><code>goos: linux
+goarch: amd64
+pkg: github.com/gobwas/ws
+BenchmarkUpgrader/base-8 5000000 377 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/lowercase-8 5000000 380 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/uppercase-8 5000000 394 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/subproto-8 3000000 529 ns/op 1 B/op 1 allocs/op
+BenchmarkUpgrader/subproto_comma-8 3000000 453 ns/op 1 B/op 1 allocs/op
+BenchmarkUpgrader/#00-8 1000000 1824 ns/op 1354 B/op 4 allocs/op
+BenchmarkUpgrader/bad_http_method-8 10000000 143 ns/op 3 B/op 1 allocs/op
+BenchmarkUpgrader/bad_http_proto-8 10000000 135 ns/op 3 B/op 1 allocs/op
+BenchmarkUpgrader/bad_host-8 10000000 224 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/bad_upgrade-8 10000000 215 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/bad_upgrade#01-8 10000000 235 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/bad_upgrade#02-8 10000000 229 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/bad_connection-8 10000000 216 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/bad_connection#01-8 10000000 175 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/bad_sec_version_x-8 10000000 216 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/bad_sec_version-8 5000000 237 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/bad_sec_key-8 5000000 379 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/bad_sec_key#01-8 5000000 382 ns/op 0 B/op 0 allocs/op
+PASS
+ok github.com/gobwas/ws 58.827s
+</code></pre>
+<h2>Go version devel +d6a27e8edc</h2>
+<pre><code>goos: linux
+goarch: amd64
+pkg: github.com/gobwas/ws
+BenchmarkUpgrader/base-8 5000000 378 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/lowercase-8 5000000 374 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/uppercase-8 5000000 398 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/subproto-8 3000000 533 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/subproto_comma-8 3000000 449 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/#00-8 1000000 1653 ns/op 1354 B/op 4 allocs/op
+BenchmarkUpgrader/bad_http_method-8 10000000 142 ns/op 3 B/op 1 allocs/op
+BenchmarkUpgrader/bad_http_proto-8 10000000 138 ns/op 3 B/op 1 allocs/op
+BenchmarkUpgrader/bad_host-8 10000000 219 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/bad_upgrade-8 10000000 217 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/bad_upgrade#01-8 5000000 233 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/bad_upgrade#02-8 5000000 227 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/bad_connection-8 10000000 215 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/bad_connection#01-8 10000000 176 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/bad_sec_version_x-8 10000000 217 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/bad_sec_version-8 5000000 266 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/bad_sec_key-8 5000000 398 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/bad_sec_key#01-8 5000000 391 ns/op 0 B/op 0 allocs/op
+PASS
+ok github.com/gobwas/ws 57.334s
+</code></pre>
+<h1>github.com/shuLhan/share/lib/websocket</h1>
+<h2>Go v1.10.3</h2>
+<pre><code>goos: linux
+goarch: amd64
+pkg: github.com/shuLhan/share/lib/websocket
+BenchmarkUpgrader/base-8 5000000 339 ns/op 176 B/op 1 allocs/op
+BenchmarkUpgrader/lowercase-8 5000000 358 ns/op 176 B/op 1 allocs/op
+BenchmarkUpgrader/uppercase-8 5000000 352 ns/op 176 B/op 1 allocs/op
+BenchmarkUpgrader/subproto-8 10000000 172 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/subproto_comma-8 3000000 389 ns/op 176 B/op 1 allocs/op
+BenchmarkUpgrader/#00-8 10000000 174 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/bad_http_method-8 100000000 23.8 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/bad_http_proto-8 50000000 29.3 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/bad_host-8 100000000 23.1 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/bad_upgrade-8 100000000 23.2 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/bad_upgrade#01-8 3000000 440 ns/op 453 B/op 6 allocs/op
+BenchmarkUpgrader/bad_upgrade#02-8 10000000 167 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/bad_connection-8 50000000 24.4 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/bad_connection#01-8 20000000 108 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/bad_sec_version_x-8 50000000 24.2 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/bad_sec_version-8 10000000 138 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/bad_sec_key-8 5000000 343 ns/op 176 B/op 1 allocs/op
+BenchmarkUpgrader/bad_sec_key#01-8 5000000 369 ns/op 176 B/op 1 allocs/op
+PASS
+ok github.com/shuLhan/share/lib/websocket 50.192s
+</code></pre>
+<h2>Go v1.12</h2>
+<pre><code>websocket version: 8dec8c9
+Benchmark date : Thu 7 Mar 22:09:17 WIB 2019
+
+goos: linux
+goarch: amd64
+pkg: github.com/shuLhan/share/lib/websocket
+BenchmarkUpgrader/base-8 10000000 165 ns/op 32 B/op 1 allocs/op
+BenchmarkUpgrader/lowercase-8 10000000 165 ns/op 32 B/op 1 allocs/op
+BenchmarkUpgrader/uppercase-8 10000000 163 ns/op 32 B/op 1 allocs/op
+BenchmarkUpgrader/subproto-8 10000000 133 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/subproto_comma-8 10000000 192 ns/op 32 B/op 1 allocs/op
+BenchmarkUpgrader/#00-8 10000000 144 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/bad_http_method-8 50000000 25.4 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/bad_http_proto-8 50000000 30.9 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/bad_host-8 50000000 24.2 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/bad_upgrade-8 50000000 24.3 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/bad_upgrade#01-8 5000000 381 ns/op 453 B/op 6 allocs/op
+BenchmarkUpgrader/bad_upgrade#02-8 10000000 133 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/bad_connection-8 50000000 24.4 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/bad_connection#01-8 20000000 91.8 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/bad_sec_version_x-8 50000000 24.4 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/bad_sec_version-8 20000000 112 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/bad_sec_key-8 10000000 165 ns/op 32 B/op 1 allocs/op
+BenchmarkUpgrader/bad_sec_key#01-8 10000000 166 ns/op 32 B/op 1 allocs/op
+PASS
+ok github.com/shuLhan/share/lib/websocket 49.379s
+</code></pre>
+<h2>Go version devel +05b3db24 (&gt;1.12)</h2>
+<pre><code>websocket version: 8dec8c9
+Benchmark date : Thu 7 Mar 22:09:17 WIB 2019
+
+goos: linux
+goarch: amd64
+pkg: github.com/shuLhan/share/lib/websocket
+BenchmarkUpgrader/base-8 10000000 156 ns/op 32 B/op 1 allocs/op
+BenchmarkUpgrader/lowercase-8 10000000 160 ns/op 32 B/op 1 allocs/op
+BenchmarkUpgrader/uppercase-8 10000000 153 ns/op 32 B/op 1 allocs/op
+BenchmarkUpgrader/subproto-8 10000000 137 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/subproto_comma-8 10000000 181 ns/op 32 B/op 1 allocs/op
+BenchmarkUpgrader/#00-8 10000000 143 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/bad_http_method-8 50000000 25.0 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/bad_http_proto-8 50000000 31.6 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/bad_host-8 50000000 24.6 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/bad_upgrade-8 50000000 24.5 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/bad_upgrade#01-8 5000000 372 ns/op 453 B/op 6 allocs/op
+BenchmarkUpgrader/bad_upgrade#02-8 10000000 133 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/bad_connection-8 100000000 23.4 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/bad_connection#01-8 20000000 92.7 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/bad_sec_version_x-8 100000000 23.3 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/bad_sec_version-8 20000000 113 ns/op 0 B/op 0 allocs/op
+BenchmarkUpgrader/bad_sec_key-8 10000000 154 ns/op 32 B/op 1 allocs/op
+BenchmarkUpgrader/bad_sec_key#01-8 10000000 157 ns/op 32 B/op 1 allocs/op
+PASS
+ok github.com/shuLhan/share/lib/websocket 52.285s
+</code></pre>
+
+ </div>
+
+ </div>
+
+
+ <div class="footer">
+ Copyright 2019, Shulhan &lt;ms@kilabit.info&gt;. All rights reserved.
+ <br />
+ Use of this source code is governed by a BSD-style license that can be
+ found in the <a href="/LICENSE">LICENSE</a> file.
+ </div>
+ </body>
+</html>