From 08c0a4d93c1754eb2f3a5b4b6483685ca6c5769d Mon Sep 17 00:00:00 2001 From: kayahr Date: Sat, 16 Mar 2024 15:17:07 +0000 Subject: [PATCH] =?UTF-8?q?Deploying=20to=20gh-pages=20from=20@=20kayahr/d?= =?UTF-8?q?atastream@e85b4ba893f9aaf6d1784dae0de50a9c6caf12a1=20?= =?UTF-8?q?=F0=9F=9A=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- assets/icons.js | 15 ++ assets/icons.svg | 1 + assets/main.js | 8 +- assets/search.js | 2 +- assets/style.css | 53 +++-- classes/index.DataReader.html | 216 +++++++++--------- classes/index.DataWriter.html | 164 ++++++------- classes/index.Uint8ArraySink.html | 42 ++-- classes/index.Uint8ArraySource.html | 14 +- classes/node.FileInputStream.html | 17 +- classes/node.FileOutputStream.html | 11 +- enums/index.Endianness.html | 12 +- functions/index.getNativeEndianness.html | 4 +- functions/index.readDataFromStream.html | 10 +- functions/index.swap16.html | 6 +- functions/index.swap32.html | 6 +- functions/index.swap64.html | 6 +- functions/index.writeDataToStream.html | 10 +- hierarchy.html | 1 + index.html | 14 +- interfaces/index.DataReaderOptions.html | 12 +- interfaces/index.DataReaderSource.html | 10 +- interfaces/index.DataWriterOptions.html | 16 +- interfaces/index.DataWriterSink.html | 12 +- interfaces/index.ReadArrayOptions.html | 12 +- interfaces/index.ReadLineOptions.html | 18 +- .../index.ReadMultiByteArrayOptions.html | 16 +- interfaces/index.ReadStringOptions.html | 14 +- modules/index.html | 40 ++-- modules/node.html | 6 +- 30 files changed, 404 insertions(+), 364 deletions(-) create mode 100644 assets/icons.js create mode 100644 assets/icons.svg create mode 100644 hierarchy.html diff --git a/assets/icons.js b/assets/icons.js new file mode 100644 index 0000000..b79c9e8 --- /dev/null +++ b/assets/icons.js @@ -0,0 +1,15 @@ +(function(svg) { + svg.innerHTML = ``; + svg.style.display = 'none'; + if (location.protocol === 'file:') { + if (document.readyState === 'loading') document.addEventListener('DOMContentLoaded', updateUseElements); + else updateUseElements() + function updateUseElements() { + document.querySelectorAll('use').forEach(el => { + if (el.getAttribute('href').includes('#icon-')) { + el.setAttribute('href', el.getAttribute('href').replace(/.*#/, '#')); + } + }); + } + } +})(document.body.appendChild(document.createElementNS('http://www.w3.org/2000/svg', 'svg'))) \ No newline at end of file diff --git a/assets/icons.svg b/assets/icons.svg new file mode 100644 index 0000000..7dead61 --- /dev/null +++ b/assets/icons.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/assets/main.js b/assets/main.js index d0aa8d5..1daeb69 100644 --- a/assets/main.js +++ b/assets/main.js @@ -1,8 +1,8 @@ "use strict"; -"use strict";(()=>{var Pe=Object.create;var ne=Object.defineProperty;var Ie=Object.getOwnPropertyDescriptor;var Oe=Object.getOwnPropertyNames;var _e=Object.getPrototypeOf,Re=Object.prototype.hasOwnProperty;var Me=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports);var Fe=(t,e,n,r)=>{if(e&&typeof e=="object"||typeof e=="function")for(let i of Oe(e))!Re.call(t,i)&&i!==n&&ne(t,i,{get:()=>e[i],enumerable:!(r=Ie(e,i))||r.enumerable});return t};var De=(t,e,n)=>(n=t!=null?Pe(_e(t)):{},Fe(e||!t||!t.__esModule?ne(n,"default",{value:t,enumerable:!0}):n,t));var ae=Me((se,oe)=>{(function(){var t=function(e){var n=new t.Builder;return n.pipeline.add(t.trimmer,t.stopWordFilter,t.stemmer),n.searchPipeline.add(t.stemmer),e.call(n,n),n.build()};t.version="2.3.9";t.utils={},t.utils.warn=function(e){return function(n){e.console&&console.warn&&console.warn(n)}}(this),t.utils.asString=function(e){return e==null?"":e.toString()},t.utils.clone=function(e){if(e==null)return e;for(var n=Object.create(null),r=Object.keys(e),i=0;i0){var d=t.utils.clone(n)||{};d.position=[a,u],d.index=s.length,s.push(new t.Token(r.slice(a,o),d))}a=o+1}}return s},t.tokenizer.separator=/[\s\-]+/;t.Pipeline=function(){this._stack=[]},t.Pipeline.registeredFunctions=Object.create(null),t.Pipeline.registerFunction=function(e,n){n in this.registeredFunctions&&t.utils.warn("Overwriting existing registered function: "+n),e.label=n,t.Pipeline.registeredFunctions[e.label]=e},t.Pipeline.warnIfFunctionNotRegistered=function(e){var n=e.label&&e.label in this.registeredFunctions;n||t.utils.warn(`Function is not registered with pipeline. This may cause problems when serialising the index. -`,e)},t.Pipeline.load=function(e){var n=new t.Pipeline;return e.forEach(function(r){var i=t.Pipeline.registeredFunctions[r];if(i)n.add(i);else throw new Error("Cannot load unregistered function: "+r)}),n},t.Pipeline.prototype.add=function(){var e=Array.prototype.slice.call(arguments);e.forEach(function(n){t.Pipeline.warnIfFunctionNotRegistered(n),this._stack.push(n)},this)},t.Pipeline.prototype.after=function(e,n){t.Pipeline.warnIfFunctionNotRegistered(n);var r=this._stack.indexOf(e);if(r==-1)throw new Error("Cannot find existingFn");r=r+1,this._stack.splice(r,0,n)},t.Pipeline.prototype.before=function(e,n){t.Pipeline.warnIfFunctionNotRegistered(n);var r=this._stack.indexOf(e);if(r==-1)throw new Error("Cannot find existingFn");this._stack.splice(r,0,n)},t.Pipeline.prototype.remove=function(e){var n=this._stack.indexOf(e);n!=-1&&this._stack.splice(n,1)},t.Pipeline.prototype.run=function(e){for(var n=this._stack.length,r=0;r1&&(oe&&(r=s),o!=e);)i=r-n,s=n+Math.floor(i/2),o=this.elements[s*2];if(o==e||o>e)return s*2;if(ol?d+=2:a==l&&(n+=r[u+1]*i[d+1],u+=2,d+=2);return n},t.Vector.prototype.similarity=function(e){return this.dot(e)/this.magnitude()||0},t.Vector.prototype.toArray=function(){for(var e=new Array(this.elements.length/2),n=1,r=0;n0){var o=s.str.charAt(0),a;o in s.node.edges?a=s.node.edges[o]:(a=new t.TokenSet,s.node.edges[o]=a),s.str.length==1&&(a.final=!0),i.push({node:a,editsRemaining:s.editsRemaining,str:s.str.slice(1)})}if(s.editsRemaining!=0){if("*"in s.node.edges)var l=s.node.edges["*"];else{var l=new t.TokenSet;s.node.edges["*"]=l}if(s.str.length==0&&(l.final=!0),i.push({node:l,editsRemaining:s.editsRemaining-1,str:s.str}),s.str.length>1&&i.push({node:s.node,editsRemaining:s.editsRemaining-1,str:s.str.slice(1)}),s.str.length==1&&(s.node.final=!0),s.str.length>=1){if("*"in s.node.edges)var u=s.node.edges["*"];else{var u=new t.TokenSet;s.node.edges["*"]=u}s.str.length==1&&(u.final=!0),i.push({node:u,editsRemaining:s.editsRemaining-1,str:s.str.slice(1)})}if(s.str.length>1){var d=s.str.charAt(0),v=s.str.charAt(1),f;v in s.node.edges?f=s.node.edges[v]:(f=new t.TokenSet,s.node.edges[v]=f),s.str.length==1&&(f.final=!0),i.push({node:f,editsRemaining:s.editsRemaining-1,str:d+s.str.slice(2)})}}}return r},t.TokenSet.fromString=function(e){for(var n=new t.TokenSet,r=n,i=0,s=e.length;i=e;n--){var r=this.uncheckedNodes[n],i=r.child.toString();i in this.minimizedNodes?r.parent.edges[r.char]=this.minimizedNodes[i]:(r.child._str=i,this.minimizedNodes[i]=r.child),this.uncheckedNodes.pop()}};t.Index=function(e){this.invertedIndex=e.invertedIndex,this.fieldVectors=e.fieldVectors,this.tokenSet=e.tokenSet,this.fields=e.fields,this.pipeline=e.pipeline},t.Index.prototype.search=function(e){return this.query(function(n){var r=new t.QueryParser(e,n);r.parse()})},t.Index.prototype.query=function(e){for(var n=new t.Query(this.fields),r=Object.create(null),i=Object.create(null),s=Object.create(null),o=Object.create(null),a=Object.create(null),l=0;l1?this._b=1:this._b=e},t.Builder.prototype.k1=function(e){this._k1=e},t.Builder.prototype.add=function(e,n){var r=e[this._ref],i=Object.keys(this._fields);this._documents[r]=n||{},this.documentCount+=1;for(var s=0;s=this.length)return t.QueryLexer.EOS;var e=this.str.charAt(this.pos);return this.pos+=1,e},t.QueryLexer.prototype.width=function(){return this.pos-this.start},t.QueryLexer.prototype.ignore=function(){this.start==this.pos&&(this.pos+=1),this.start=this.pos},t.QueryLexer.prototype.backup=function(){this.pos-=1},t.QueryLexer.prototype.acceptDigitRun=function(){var e,n;do e=this.next(),n=e.charCodeAt(0);while(n>47&&n<58);e!=t.QueryLexer.EOS&&this.backup()},t.QueryLexer.prototype.more=function(){return this.pos1&&(e.backup(),e.emit(t.QueryLexer.TERM)),e.ignore(),e.more())return t.QueryLexer.lexText},t.QueryLexer.lexEditDistance=function(e){return e.ignore(),e.acceptDigitRun(),e.emit(t.QueryLexer.EDIT_DISTANCE),t.QueryLexer.lexText},t.QueryLexer.lexBoost=function(e){return e.ignore(),e.acceptDigitRun(),e.emit(t.QueryLexer.BOOST),t.QueryLexer.lexText},t.QueryLexer.lexEOS=function(e){e.width()>0&&e.emit(t.QueryLexer.TERM)},t.QueryLexer.termSeparator=t.tokenizer.separator,t.QueryLexer.lexText=function(e){for(;;){var n=e.next();if(n==t.QueryLexer.EOS)return t.QueryLexer.lexEOS;if(n.charCodeAt(0)==92){e.escapeCharacter();continue}if(n==":")return t.QueryLexer.lexField;if(n=="~")return e.backup(),e.width()>0&&e.emit(t.QueryLexer.TERM),t.QueryLexer.lexEditDistance;if(n=="^")return e.backup(),e.width()>0&&e.emit(t.QueryLexer.TERM),t.QueryLexer.lexBoost;if(n=="+"&&e.width()===1||n=="-"&&e.width()===1)return e.emit(t.QueryLexer.PRESENCE),t.QueryLexer.lexText;if(n.match(t.QueryLexer.termSeparator))return t.QueryLexer.lexTerm}},t.QueryParser=function(e,n){this.lexer=new t.QueryLexer(e),this.query=n,this.currentClause={},this.lexemeIdx=0},t.QueryParser.prototype.parse=function(){this.lexer.run(),this.lexemes=this.lexer.lexemes;for(var e=t.QueryParser.parseClause;e;)e=e(this);return this.query},t.QueryParser.prototype.peekLexeme=function(){return this.lexemes[this.lexemeIdx]},t.QueryParser.prototype.consumeLexeme=function(){var e=this.peekLexeme();return this.lexemeIdx+=1,e},t.QueryParser.prototype.nextClause=function(){var e=this.currentClause;this.query.clause(e),this.currentClause={}},t.QueryParser.parseClause=function(e){var n=e.peekLexeme();if(n!=null)switch(n.type){case t.QueryLexer.PRESENCE:return t.QueryParser.parsePresence;case t.QueryLexer.FIELD:return t.QueryParser.parseField;case t.QueryLexer.TERM:return t.QueryParser.parseTerm;default:var r="expected either a field or a term, found "+n.type;throw n.str.length>=1&&(r+=" with value '"+n.str+"'"),new t.QueryParseError(r,n.start,n.end)}},t.QueryParser.parsePresence=function(e){var n=e.consumeLexeme();if(n!=null){switch(n.str){case"-":e.currentClause.presence=t.Query.presence.PROHIBITED;break;case"+":e.currentClause.presence=t.Query.presence.REQUIRED;break;default:var r="unrecognised presence operator'"+n.str+"'";throw new t.QueryParseError(r,n.start,n.end)}var i=e.peekLexeme();if(i==null){var r="expecting term or field, found nothing";throw new t.QueryParseError(r,n.start,n.end)}switch(i.type){case t.QueryLexer.FIELD:return t.QueryParser.parseField;case t.QueryLexer.TERM:return t.QueryParser.parseTerm;default:var r="expecting term or field, found '"+i.type+"'";throw new t.QueryParseError(r,i.start,i.end)}}},t.QueryParser.parseField=function(e){var n=e.consumeLexeme();if(n!=null){if(e.query.allFields.indexOf(n.str)==-1){var r=e.query.allFields.map(function(o){return"'"+o+"'"}).join(", "),i="unrecognised field '"+n.str+"', possible fields: "+r;throw new t.QueryParseError(i,n.start,n.end)}e.currentClause.fields=[n.str];var s=e.peekLexeme();if(s==null){var i="expecting term, found nothing";throw new t.QueryParseError(i,n.start,n.end)}switch(s.type){case t.QueryLexer.TERM:return t.QueryParser.parseTerm;default:var i="expecting term, found '"+s.type+"'";throw new t.QueryParseError(i,s.start,s.end)}}},t.QueryParser.parseTerm=function(e){var n=e.consumeLexeme();if(n!=null){e.currentClause.term=n.str.toLowerCase(),n.str.indexOf("*")!=-1&&(e.currentClause.usePipeline=!1);var r=e.peekLexeme();if(r==null){e.nextClause();return}switch(r.type){case t.QueryLexer.TERM:return e.nextClause(),t.QueryParser.parseTerm;case t.QueryLexer.FIELD:return e.nextClause(),t.QueryParser.parseField;case t.QueryLexer.EDIT_DISTANCE:return t.QueryParser.parseEditDistance;case t.QueryLexer.BOOST:return t.QueryParser.parseBoost;case t.QueryLexer.PRESENCE:return e.nextClause(),t.QueryParser.parsePresence;default:var i="Unexpected lexeme type '"+r.type+"'";throw new t.QueryParseError(i,r.start,r.end)}}},t.QueryParser.parseEditDistance=function(e){var n=e.consumeLexeme();if(n!=null){var r=parseInt(n.str,10);if(isNaN(r)){var i="edit distance must be numeric";throw new t.QueryParseError(i,n.start,n.end)}e.currentClause.editDistance=r;var s=e.peekLexeme();if(s==null){e.nextClause();return}switch(s.type){case t.QueryLexer.TERM:return e.nextClause(),t.QueryParser.parseTerm;case t.QueryLexer.FIELD:return e.nextClause(),t.QueryParser.parseField;case t.QueryLexer.EDIT_DISTANCE:return t.QueryParser.parseEditDistance;case t.QueryLexer.BOOST:return t.QueryParser.parseBoost;case t.QueryLexer.PRESENCE:return e.nextClause(),t.QueryParser.parsePresence;default:var i="Unexpected lexeme type '"+s.type+"'";throw new t.QueryParseError(i,s.start,s.end)}}},t.QueryParser.parseBoost=function(e){var n=e.consumeLexeme();if(n!=null){var r=parseInt(n.str,10);if(isNaN(r)){var i="boost must be numeric";throw new t.QueryParseError(i,n.start,n.end)}e.currentClause.boost=r;var s=e.peekLexeme();if(s==null){e.nextClause();return}switch(s.type){case t.QueryLexer.TERM:return e.nextClause(),t.QueryParser.parseTerm;case t.QueryLexer.FIELD:return e.nextClause(),t.QueryParser.parseField;case t.QueryLexer.EDIT_DISTANCE:return t.QueryParser.parseEditDistance;case t.QueryLexer.BOOST:return t.QueryParser.parseBoost;case t.QueryLexer.PRESENCE:return e.nextClause(),t.QueryParser.parsePresence;default:var i="Unexpected lexeme type '"+s.type+"'";throw new t.QueryParseError(i,s.start,s.end)}}},function(e,n){typeof define=="function"&&define.amd?define(n):typeof se=="object"?oe.exports=n():e.lunr=n()}(this,function(){return t})})()});var re=[];function G(t,e){re.push({selector:e,constructor:t})}var U=class{constructor(){this.alwaysVisibleMember=null;this.createComponents(document.body),this.ensureActivePageVisible(),this.ensureFocusedElementVisible(),this.listenForCodeCopies(),window.addEventListener("hashchange",()=>this.ensureFocusedElementVisible())}createComponents(e){re.forEach(n=>{e.querySelectorAll(n.selector).forEach(r=>{r.dataset.hasInstance||(new n.constructor({el:r,app:this}),r.dataset.hasInstance=String(!0))})})}filterChanged(){this.ensureFocusedElementVisible()}ensureActivePageVisible(){let e=document.querySelector(".tsd-navigation .current"),n=e?.parentElement;for(;n&&!n.classList.contains(".tsd-navigation");)n instanceof HTMLDetailsElement&&(n.open=!0),n=n.parentElement;if(e){let r=e.getBoundingClientRect().top-document.documentElement.clientHeight/4;document.querySelector(".site-menu").scrollTop=r}}ensureFocusedElementVisible(){if(this.alwaysVisibleMember&&(this.alwaysVisibleMember.classList.remove("always-visible"),this.alwaysVisibleMember.firstElementChild.remove(),this.alwaysVisibleMember=null),!location.hash)return;let e=document.getElementById(location.hash.substring(1));if(!e)return;let n=e.parentElement;for(;n&&n.tagName!=="SECTION";)n=n.parentElement;if(n&&n.offsetParent==null){this.alwaysVisibleMember=n,n.classList.add("always-visible");let r=document.createElement("p");r.classList.add("warning"),r.textContent="This member is normally hidden due to your filter settings.",n.prepend(r)}}listenForCodeCopies(){document.querySelectorAll("pre > button").forEach(e=>{let n;e.addEventListener("click",()=>{e.previousElementSibling instanceof HTMLElement&&navigator.clipboard.writeText(e.previousElementSibling.innerText.trim()),e.textContent="Copied!",e.classList.add("visible"),clearTimeout(n),n=setTimeout(()=>{e.classList.remove("visible"),n=setTimeout(()=>{e.textContent="Copy"},100)},1e3)})})}};var ie=(t,e=100)=>{let n;return()=>{clearTimeout(n),n=setTimeout(()=>t(),e)}};var de=De(ae());async function le(t,e){if(!window.searchData)return;let n=await fetch(window.searchData),r=new Blob([await n.arrayBuffer()]).stream().pipeThrough(new DecompressionStream("gzip")),i=await new Response(r).json();t.data=i,t.index=de.Index.load(i.index),e.classList.remove("loading"),e.classList.add("ready")}function he(){let t=document.getElementById("tsd-search");if(!t)return;let e={base:t.dataset.base+"/"},n=document.getElementById("tsd-search-script");t.classList.add("loading"),n&&(n.addEventListener("error",()=>{t.classList.remove("loading"),t.classList.add("failure")}),n.addEventListener("load",()=>{le(e,t)}),le(e,t));let r=document.querySelector("#tsd-search input"),i=document.querySelector("#tsd-search .results");if(!r||!i)throw new Error("The input field or the result list wrapper was not found");let s=!1;i.addEventListener("mousedown",()=>s=!0),i.addEventListener("mouseup",()=>{s=!1,t.classList.remove("has-focus")}),r.addEventListener("focus",()=>t.classList.add("has-focus")),r.addEventListener("blur",()=>{s||(s=!1,t.classList.remove("has-focus"))}),Ae(t,i,r,e)}function Ae(t,e,n,r){n.addEventListener("input",ie(()=>{Ne(t,e,n,r)},200));let i=!1;n.addEventListener("keydown",s=>{i=!0,s.key=="Enter"?Ve(e,n):s.key=="Escape"?n.blur():s.key=="ArrowUp"?ue(e,-1):s.key==="ArrowDown"?ue(e,1):i=!1}),n.addEventListener("keypress",s=>{i&&s.preventDefault()}),document.body.addEventListener("keydown",s=>{s.altKey||s.ctrlKey||s.metaKey||!n.matches(":focus")&&s.key==="/"&&(n.focus(),s.preventDefault())})}function Ne(t,e,n,r){if(!r.index||!r.data)return;e.textContent="";let i=n.value.trim(),s;if(i){let o=i.split(" ").map(a=>a.length?`*${a}*`:"").join(" ");s=r.index.search(o)}else s=[];for(let o=0;oa.score-o.score);for(let o=0,a=Math.min(10,s.length);o`,d=ce(l.name,i);globalThis.DEBUG_SEARCH_WEIGHTS&&(d+=` (score: ${s[o].score.toFixed(2)})`),l.parent&&(d=` - ${ce(l.parent,i)}.${d}`);let v=document.createElement("li");v.classList.value=l.classes??"";let f=document.createElement("a");f.href=r.base+l.url,f.innerHTML=u+d,v.append(f),e.appendChild(v)}}function ue(t,e){let n=t.querySelector(".current");if(!n)n=t.querySelector(e==1?"li:first-child":"li:last-child"),n&&n.classList.add("current");else{let r=n;if(e===1)do r=r.nextElementSibling??void 0;while(r instanceof HTMLElement&&r.offsetParent==null);else do r=r.previousElementSibling??void 0;while(r instanceof HTMLElement&&r.offsetParent==null);r&&(n.classList.remove("current"),r.classList.add("current"))}}function Ve(t,e){let n=t.querySelector(".current");if(n||(n=t.querySelector("li:first-child")),n){let r=n.querySelector("a");r&&(window.location.href=r.href),e.blur()}}function ce(t,e){if(e==="")return t;let n=t.toLocaleLowerCase(),r=e.toLocaleLowerCase(),i=[],s=0,o=n.indexOf(r);for(;o!=-1;)i.push(K(t.substring(s,o)),`${K(t.substring(o,o+r.length))}`),s=o+r.length,o=n.indexOf(r,s);return i.push(K(t.substring(s))),i.join("")}var Be={"&":"&","<":"<",">":">","'":"'",'"':"""};function K(t){return t.replace(/[&<>"'"]/g,e=>Be[e])}var C=class{constructor(e){this.el=e.el,this.app=e.app}};var F="mousedown",pe="mousemove",B="mouseup",J={x:0,y:0},fe=!1,ee=!1,He=!1,D=!1,me=/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent);document.documentElement.classList.add(me?"is-mobile":"not-mobile");me&&"ontouchstart"in document.documentElement&&(He=!0,F="touchstart",pe="touchmove",B="touchend");document.addEventListener(F,t=>{ee=!0,D=!1;let e=F=="touchstart"?t.targetTouches[0]:t;J.y=e.pageY||0,J.x=e.pageX||0});document.addEventListener(pe,t=>{if(ee&&!D){let e=F=="touchstart"?t.targetTouches[0]:t,n=J.x-(e.pageX||0),r=J.y-(e.pageY||0);D=Math.sqrt(n*n+r*r)>10}});document.addEventListener(B,()=>{ee=!1});document.addEventListener("click",t=>{fe&&(t.preventDefault(),t.stopImmediatePropagation(),fe=!1)});var X=class extends C{constructor(n){super(n);this.className=this.el.dataset.toggle||"",this.el.addEventListener(B,r=>this.onPointerUp(r)),this.el.addEventListener("click",r=>r.preventDefault()),document.addEventListener(F,r=>this.onDocumentPointerDown(r)),document.addEventListener(B,r=>this.onDocumentPointerUp(r))}setActive(n){if(this.active==n)return;this.active=n,document.documentElement.classList.toggle("has-"+this.className,n),this.el.classList.toggle("active",n);let r=(this.active?"to-has-":"from-has-")+this.className;document.documentElement.classList.add(r),setTimeout(()=>document.documentElement.classList.remove(r),500)}onPointerUp(n){D||(this.setActive(!0),n.preventDefault())}onDocumentPointerDown(n){if(this.active){if(n.target.closest(".col-sidebar, .tsd-filter-group"))return;this.setActive(!1)}}onDocumentPointerUp(n){if(!D&&this.active&&n.target.closest(".col-sidebar")){let r=n.target.closest("a");if(r){let i=window.location.href;i.indexOf("#")!=-1&&(i=i.substring(0,i.indexOf("#"))),r.href.substring(0,i.length)==i&&setTimeout(()=>this.setActive(!1),250)}}}};var te;try{te=localStorage}catch{te={getItem(){return null},setItem(){}}}var Q=te;var ve=document.head.appendChild(document.createElement("style"));ve.dataset.for="filters";var Y=class extends C{constructor(n){super(n);this.key=`filter-${this.el.name}`,this.value=this.el.checked,this.el.addEventListener("change",()=>{this.setLocalStorage(this.el.checked)}),this.setLocalStorage(this.fromLocalStorage()),ve.innerHTML+=`html:not(.${this.key}) .tsd-is-${this.el.name} { display: none; } -`}fromLocalStorage(){let n=Q.getItem(this.key);return n?n==="true":this.el.checked}setLocalStorage(n){Q.setItem(this.key,n.toString()),this.value=n,this.handleValueChange()}handleValueChange(){this.el.checked=this.value,document.documentElement.classList.toggle(this.key,this.value),this.app.filterChanged(),document.querySelectorAll(".tsd-index-section").forEach(n=>{n.style.display="block";let r=Array.from(n.querySelectorAll(".tsd-index-link")).every(i=>i.offsetParent==null);n.style.display=r?"none":"block"})}};var Z=class extends C{constructor(n){super(n);this.summary=this.el.querySelector(".tsd-accordion-summary"),this.icon=this.summary.querySelector("svg"),this.key=`tsd-accordion-${this.summary.dataset.key??this.summary.textContent.trim().replace(/\s+/g,"-").toLowerCase()}`;let r=Q.getItem(this.key);this.el.open=r?r==="true":this.el.open,this.el.addEventListener("toggle",()=>this.update());let i=this.summary.querySelector("a");i&&i.addEventListener("click",()=>{location.assign(i.href)}),this.update()}update(){this.icon.style.transform=`rotate(${this.el.open?0:-90}deg)`,Q.setItem(this.key,this.el.open.toString())}};function ge(t){let e=Q.getItem("tsd-theme")||"os";t.value=e,ye(e),t.addEventListener("change",()=>{Q.setItem("tsd-theme",t.value),ye(t.value)})}function ye(t){document.documentElement.dataset.theme=t}var Le;function be(){let t=document.getElementById("tsd-nav-script");t&&(t.addEventListener("load",xe),xe())}async function xe(){let t=document.getElementById("tsd-nav-container");if(!t||!window.navigationData)return;let n=await(await fetch(window.navigationData)).arrayBuffer(),r=new Blob([n]).stream().pipeThrough(new DecompressionStream("gzip")),i=await new Response(r).json();Le=t.dataset.base+"/",t.innerHTML="";for(let s of i)we(s,t,[]);window.app.createComponents(t),window.app.ensureActivePageVisible()}function we(t,e,n){let r=e.appendChild(document.createElement("li"));if(t.children){let i=[...n,t.text],s=r.appendChild(document.createElement("details"));s.className=t.class?`${t.class} tsd-index-accordion`:"tsd-index-accordion",s.dataset.key=i.join("$");let o=s.appendChild(document.createElement("summary"));o.className="tsd-accordion-summary",o.innerHTML='',Ee(t,o);let a=s.appendChild(document.createElement("div"));a.className="tsd-accordion-details";let l=a.appendChild(document.createElement("ul"));l.className="tsd-nested-navigation";for(let u of t.children)we(u,l,i)}else Ee(t,r,t.class)}function Ee(t,e,n){if(t.path){let r=e.appendChild(document.createElement("a"));r.href=Le+t.path,n&&(r.className=n),location.href===r.href&&r.classList.add("current"),t.kind&&(r.innerHTML=``),r.appendChild(document.createElement("span")).textContent=t.text}else e.appendChild(document.createElement("span")).textContent=t.text}G(X,"a[data-toggle]");G(Z,".tsd-index-accordion");G(Y,".tsd-filter-item input[type=checkbox]");var Se=document.getElementById("tsd-theme");Se&&ge(Se);var je=new U;Object.defineProperty(window,"app",{value:je});he();be();})(); +"use strict";(()=>{var Ce=Object.create;var ne=Object.defineProperty;var Pe=Object.getOwnPropertyDescriptor;var Oe=Object.getOwnPropertyNames;var _e=Object.getPrototypeOf,Re=Object.prototype.hasOwnProperty;var Me=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports);var Fe=(t,e,n,r)=>{if(e&&typeof e=="object"||typeof e=="function")for(let i of Oe(e))!Re.call(t,i)&&i!==n&&ne(t,i,{get:()=>e[i],enumerable:!(r=Pe(e,i))||r.enumerable});return t};var De=(t,e,n)=>(n=t!=null?Ce(_e(t)):{},Fe(e||!t||!t.__esModule?ne(n,"default",{value:t,enumerable:!0}):n,t));var ae=Me((se,oe)=>{(function(){var t=function(e){var n=new t.Builder;return n.pipeline.add(t.trimmer,t.stopWordFilter,t.stemmer),n.searchPipeline.add(t.stemmer),e.call(n,n),n.build()};t.version="2.3.9";t.utils={},t.utils.warn=function(e){return function(n){e.console&&console.warn&&console.warn(n)}}(this),t.utils.asString=function(e){return e==null?"":e.toString()},t.utils.clone=function(e){if(e==null)return e;for(var n=Object.create(null),r=Object.keys(e),i=0;i0){var d=t.utils.clone(n)||{};d.position=[a,u],d.index=s.length,s.push(new t.Token(r.slice(a,o),d))}a=o+1}}return s},t.tokenizer.separator=/[\s\-]+/;t.Pipeline=function(){this._stack=[]},t.Pipeline.registeredFunctions=Object.create(null),t.Pipeline.registerFunction=function(e,n){n in this.registeredFunctions&&t.utils.warn("Overwriting existing registered function: "+n),e.label=n,t.Pipeline.registeredFunctions[e.label]=e},t.Pipeline.warnIfFunctionNotRegistered=function(e){var n=e.label&&e.label in this.registeredFunctions;n||t.utils.warn(`Function is not registered with pipeline. This may cause problems when serialising the index. +`,e)},t.Pipeline.load=function(e){var n=new t.Pipeline;return e.forEach(function(r){var i=t.Pipeline.registeredFunctions[r];if(i)n.add(i);else throw new Error("Cannot load unregistered function: "+r)}),n},t.Pipeline.prototype.add=function(){var e=Array.prototype.slice.call(arguments);e.forEach(function(n){t.Pipeline.warnIfFunctionNotRegistered(n),this._stack.push(n)},this)},t.Pipeline.prototype.after=function(e,n){t.Pipeline.warnIfFunctionNotRegistered(n);var r=this._stack.indexOf(e);if(r==-1)throw new Error("Cannot find existingFn");r=r+1,this._stack.splice(r,0,n)},t.Pipeline.prototype.before=function(e,n){t.Pipeline.warnIfFunctionNotRegistered(n);var r=this._stack.indexOf(e);if(r==-1)throw new Error("Cannot find existingFn");this._stack.splice(r,0,n)},t.Pipeline.prototype.remove=function(e){var n=this._stack.indexOf(e);n!=-1&&this._stack.splice(n,1)},t.Pipeline.prototype.run=function(e){for(var n=this._stack.length,r=0;r1&&(oe&&(r=s),o!=e);)i=r-n,s=n+Math.floor(i/2),o=this.elements[s*2];if(o==e||o>e)return s*2;if(ol?d+=2:a==l&&(n+=r[u+1]*i[d+1],u+=2,d+=2);return n},t.Vector.prototype.similarity=function(e){return this.dot(e)/this.magnitude()||0},t.Vector.prototype.toArray=function(){for(var e=new Array(this.elements.length/2),n=1,r=0;n0){var o=s.str.charAt(0),a;o in s.node.edges?a=s.node.edges[o]:(a=new t.TokenSet,s.node.edges[o]=a),s.str.length==1&&(a.final=!0),i.push({node:a,editsRemaining:s.editsRemaining,str:s.str.slice(1)})}if(s.editsRemaining!=0){if("*"in s.node.edges)var l=s.node.edges["*"];else{var l=new t.TokenSet;s.node.edges["*"]=l}if(s.str.length==0&&(l.final=!0),i.push({node:l,editsRemaining:s.editsRemaining-1,str:s.str}),s.str.length>1&&i.push({node:s.node,editsRemaining:s.editsRemaining-1,str:s.str.slice(1)}),s.str.length==1&&(s.node.final=!0),s.str.length>=1){if("*"in s.node.edges)var u=s.node.edges["*"];else{var u=new t.TokenSet;s.node.edges["*"]=u}s.str.length==1&&(u.final=!0),i.push({node:u,editsRemaining:s.editsRemaining-1,str:s.str.slice(1)})}if(s.str.length>1){var d=s.str.charAt(0),y=s.str.charAt(1),p;y in s.node.edges?p=s.node.edges[y]:(p=new t.TokenSet,s.node.edges[y]=p),s.str.length==1&&(p.final=!0),i.push({node:p,editsRemaining:s.editsRemaining-1,str:d+s.str.slice(2)})}}}return r},t.TokenSet.fromString=function(e){for(var n=new t.TokenSet,r=n,i=0,s=e.length;i=e;n--){var r=this.uncheckedNodes[n],i=r.child.toString();i in this.minimizedNodes?r.parent.edges[r.char]=this.minimizedNodes[i]:(r.child._str=i,this.minimizedNodes[i]=r.child),this.uncheckedNodes.pop()}};t.Index=function(e){this.invertedIndex=e.invertedIndex,this.fieldVectors=e.fieldVectors,this.tokenSet=e.tokenSet,this.fields=e.fields,this.pipeline=e.pipeline},t.Index.prototype.search=function(e){return this.query(function(n){var r=new t.QueryParser(e,n);r.parse()})},t.Index.prototype.query=function(e){for(var n=new t.Query(this.fields),r=Object.create(null),i=Object.create(null),s=Object.create(null),o=Object.create(null),a=Object.create(null),l=0;l1?this._b=1:this._b=e},t.Builder.prototype.k1=function(e){this._k1=e},t.Builder.prototype.add=function(e,n){var r=e[this._ref],i=Object.keys(this._fields);this._documents[r]=n||{},this.documentCount+=1;for(var s=0;s=this.length)return t.QueryLexer.EOS;var e=this.str.charAt(this.pos);return this.pos+=1,e},t.QueryLexer.prototype.width=function(){return this.pos-this.start},t.QueryLexer.prototype.ignore=function(){this.start==this.pos&&(this.pos+=1),this.start=this.pos},t.QueryLexer.prototype.backup=function(){this.pos-=1},t.QueryLexer.prototype.acceptDigitRun=function(){var e,n;do e=this.next(),n=e.charCodeAt(0);while(n>47&&n<58);e!=t.QueryLexer.EOS&&this.backup()},t.QueryLexer.prototype.more=function(){return this.pos1&&(e.backup(),e.emit(t.QueryLexer.TERM)),e.ignore(),e.more())return t.QueryLexer.lexText},t.QueryLexer.lexEditDistance=function(e){return e.ignore(),e.acceptDigitRun(),e.emit(t.QueryLexer.EDIT_DISTANCE),t.QueryLexer.lexText},t.QueryLexer.lexBoost=function(e){return e.ignore(),e.acceptDigitRun(),e.emit(t.QueryLexer.BOOST),t.QueryLexer.lexText},t.QueryLexer.lexEOS=function(e){e.width()>0&&e.emit(t.QueryLexer.TERM)},t.QueryLexer.termSeparator=t.tokenizer.separator,t.QueryLexer.lexText=function(e){for(;;){var n=e.next();if(n==t.QueryLexer.EOS)return t.QueryLexer.lexEOS;if(n.charCodeAt(0)==92){e.escapeCharacter();continue}if(n==":")return t.QueryLexer.lexField;if(n=="~")return e.backup(),e.width()>0&&e.emit(t.QueryLexer.TERM),t.QueryLexer.lexEditDistance;if(n=="^")return e.backup(),e.width()>0&&e.emit(t.QueryLexer.TERM),t.QueryLexer.lexBoost;if(n=="+"&&e.width()===1||n=="-"&&e.width()===1)return e.emit(t.QueryLexer.PRESENCE),t.QueryLexer.lexText;if(n.match(t.QueryLexer.termSeparator))return t.QueryLexer.lexTerm}},t.QueryParser=function(e,n){this.lexer=new t.QueryLexer(e),this.query=n,this.currentClause={},this.lexemeIdx=0},t.QueryParser.prototype.parse=function(){this.lexer.run(),this.lexemes=this.lexer.lexemes;for(var e=t.QueryParser.parseClause;e;)e=e(this);return this.query},t.QueryParser.prototype.peekLexeme=function(){return this.lexemes[this.lexemeIdx]},t.QueryParser.prototype.consumeLexeme=function(){var e=this.peekLexeme();return this.lexemeIdx+=1,e},t.QueryParser.prototype.nextClause=function(){var e=this.currentClause;this.query.clause(e),this.currentClause={}},t.QueryParser.parseClause=function(e){var n=e.peekLexeme();if(n!=null)switch(n.type){case t.QueryLexer.PRESENCE:return t.QueryParser.parsePresence;case t.QueryLexer.FIELD:return t.QueryParser.parseField;case t.QueryLexer.TERM:return t.QueryParser.parseTerm;default:var r="expected either a field or a term, found "+n.type;throw n.str.length>=1&&(r+=" with value '"+n.str+"'"),new t.QueryParseError(r,n.start,n.end)}},t.QueryParser.parsePresence=function(e){var n=e.consumeLexeme();if(n!=null){switch(n.str){case"-":e.currentClause.presence=t.Query.presence.PROHIBITED;break;case"+":e.currentClause.presence=t.Query.presence.REQUIRED;break;default:var r="unrecognised presence operator'"+n.str+"'";throw new t.QueryParseError(r,n.start,n.end)}var i=e.peekLexeme();if(i==null){var r="expecting term or field, found nothing";throw new t.QueryParseError(r,n.start,n.end)}switch(i.type){case t.QueryLexer.FIELD:return t.QueryParser.parseField;case t.QueryLexer.TERM:return t.QueryParser.parseTerm;default:var r="expecting term or field, found '"+i.type+"'";throw new t.QueryParseError(r,i.start,i.end)}}},t.QueryParser.parseField=function(e){var n=e.consumeLexeme();if(n!=null){if(e.query.allFields.indexOf(n.str)==-1){var r=e.query.allFields.map(function(o){return"'"+o+"'"}).join(", "),i="unrecognised field '"+n.str+"', possible fields: "+r;throw new t.QueryParseError(i,n.start,n.end)}e.currentClause.fields=[n.str];var s=e.peekLexeme();if(s==null){var i="expecting term, found nothing";throw new t.QueryParseError(i,n.start,n.end)}switch(s.type){case t.QueryLexer.TERM:return t.QueryParser.parseTerm;default:var i="expecting term, found '"+s.type+"'";throw new t.QueryParseError(i,s.start,s.end)}}},t.QueryParser.parseTerm=function(e){var n=e.consumeLexeme();if(n!=null){e.currentClause.term=n.str.toLowerCase(),n.str.indexOf("*")!=-1&&(e.currentClause.usePipeline=!1);var r=e.peekLexeme();if(r==null){e.nextClause();return}switch(r.type){case t.QueryLexer.TERM:return e.nextClause(),t.QueryParser.parseTerm;case t.QueryLexer.FIELD:return e.nextClause(),t.QueryParser.parseField;case t.QueryLexer.EDIT_DISTANCE:return t.QueryParser.parseEditDistance;case t.QueryLexer.BOOST:return t.QueryParser.parseBoost;case t.QueryLexer.PRESENCE:return e.nextClause(),t.QueryParser.parsePresence;default:var i="Unexpected lexeme type '"+r.type+"'";throw new t.QueryParseError(i,r.start,r.end)}}},t.QueryParser.parseEditDistance=function(e){var n=e.consumeLexeme();if(n!=null){var r=parseInt(n.str,10);if(isNaN(r)){var i="edit distance must be numeric";throw new t.QueryParseError(i,n.start,n.end)}e.currentClause.editDistance=r;var s=e.peekLexeme();if(s==null){e.nextClause();return}switch(s.type){case t.QueryLexer.TERM:return e.nextClause(),t.QueryParser.parseTerm;case t.QueryLexer.FIELD:return e.nextClause(),t.QueryParser.parseField;case t.QueryLexer.EDIT_DISTANCE:return t.QueryParser.parseEditDistance;case t.QueryLexer.BOOST:return t.QueryParser.parseBoost;case t.QueryLexer.PRESENCE:return e.nextClause(),t.QueryParser.parsePresence;default:var i="Unexpected lexeme type '"+s.type+"'";throw new t.QueryParseError(i,s.start,s.end)}}},t.QueryParser.parseBoost=function(e){var n=e.consumeLexeme();if(n!=null){var r=parseInt(n.str,10);if(isNaN(r)){var i="boost must be numeric";throw new t.QueryParseError(i,n.start,n.end)}e.currentClause.boost=r;var s=e.peekLexeme();if(s==null){e.nextClause();return}switch(s.type){case t.QueryLexer.TERM:return e.nextClause(),t.QueryParser.parseTerm;case t.QueryLexer.FIELD:return e.nextClause(),t.QueryParser.parseField;case t.QueryLexer.EDIT_DISTANCE:return t.QueryParser.parseEditDistance;case t.QueryLexer.BOOST:return t.QueryParser.parseBoost;case t.QueryLexer.PRESENCE:return e.nextClause(),t.QueryParser.parsePresence;default:var i="Unexpected lexeme type '"+s.type+"'";throw new t.QueryParseError(i,s.start,s.end)}}},function(e,n){typeof define=="function"&&define.amd?define(n):typeof se=="object"?oe.exports=n():e.lunr=n()}(this,function(){return t})})()});var re=[];function G(t,e){re.push({selector:e,constructor:t})}var U=class{constructor(){this.alwaysVisibleMember=null;this.createComponents(document.body),this.ensureFocusedElementVisible(),this.listenForCodeCopies(),window.addEventListener("hashchange",()=>this.ensureFocusedElementVisible()),document.body.style.display||(this.scrollToHash(),this.updateIndexVisibility())}createComponents(e){re.forEach(n=>{e.querySelectorAll(n.selector).forEach(r=>{r.dataset.hasInstance||(new n.constructor({el:r,app:this}),r.dataset.hasInstance=String(!0))})})}filterChanged(){this.ensureFocusedElementVisible()}showPage(){document.body.style.display&&(document.body.style.removeProperty("display"),this.scrollToHash(),this.updateIndexVisibility())}scrollToHash(){if(location.hash){let e=document.getElementById(location.hash.substring(1));if(!e)return;e.scrollIntoView({behavior:"instant",block:"start"})}}ensureActivePageVisible(){let e=document.querySelector(".tsd-navigation .current"),n=e?.parentElement;for(;n&&!n.classList.contains(".tsd-navigation");)n instanceof HTMLDetailsElement&&(n.open=!0),n=n.parentElement;if(e&&!e.checkVisibility()){let r=e.getBoundingClientRect().top-document.documentElement.clientHeight/4;document.querySelector(".site-menu").scrollTop=r}}updateIndexVisibility(){let e=document.querySelector(".tsd-index-content"),n=e?.open;e&&(e.open=!0),document.querySelectorAll(".tsd-index-section").forEach(r=>{r.style.display="block";let i=Array.from(r.querySelectorAll(".tsd-index-link")).every(s=>s.offsetParent==null);r.style.display=i?"none":"block"}),e&&(e.open=n)}ensureFocusedElementVisible(){if(this.alwaysVisibleMember&&(this.alwaysVisibleMember.classList.remove("always-visible"),this.alwaysVisibleMember.firstElementChild.remove(),this.alwaysVisibleMember=null),!location.hash)return;let e=document.getElementById(location.hash.substring(1));if(!e)return;let n=e.parentElement;for(;n&&n.tagName!=="SECTION";)n=n.parentElement;if(n&&n.offsetParent==null){this.alwaysVisibleMember=n,n.classList.add("always-visible");let r=document.createElement("p");r.classList.add("warning"),r.textContent="This member is normally hidden due to your filter settings.",n.prepend(r)}}listenForCodeCopies(){document.querySelectorAll("pre > button").forEach(e=>{let n;e.addEventListener("click",()=>{e.previousElementSibling instanceof HTMLElement&&navigator.clipboard.writeText(e.previousElementSibling.innerText.trim()),e.textContent="Copied!",e.classList.add("visible"),clearTimeout(n),n=setTimeout(()=>{e.classList.remove("visible"),n=setTimeout(()=>{e.textContent="Copy"},100)},1e3)})})}};var ie=(t,e=100)=>{let n;return()=>{clearTimeout(n),n=setTimeout(()=>t(),e)}};var de=De(ae());async function le(t,e){if(!window.searchData)return;let n=await fetch(window.searchData),r=new Blob([await n.arrayBuffer()]).stream().pipeThrough(new DecompressionStream("gzip")),i=await new Response(r).json();t.data=i,t.index=de.Index.load(i.index),e.classList.remove("loading"),e.classList.add("ready")}function he(){let t=document.getElementById("tsd-search");if(!t)return;let e={base:t.dataset.base+"/"},n=document.getElementById("tsd-search-script");t.classList.add("loading"),n&&(n.addEventListener("error",()=>{t.classList.remove("loading"),t.classList.add("failure")}),n.addEventListener("load",()=>{le(e,t)}),le(e,t));let r=document.querySelector("#tsd-search input"),i=document.querySelector("#tsd-search .results");if(!r||!i)throw new Error("The input field or the result list wrapper was not found");let s=!1;i.addEventListener("mousedown",()=>s=!0),i.addEventListener("mouseup",()=>{s=!1,t.classList.remove("has-focus")}),r.addEventListener("focus",()=>t.classList.add("has-focus")),r.addEventListener("blur",()=>{s||(s=!1,t.classList.remove("has-focus"))}),Ae(t,i,r,e)}function Ae(t,e,n,r){n.addEventListener("input",ie(()=>{Ne(t,e,n,r)},200));let i=!1;n.addEventListener("keydown",s=>{i=!0,s.key=="Enter"?Ve(e,n):s.key=="Escape"?n.blur():s.key=="ArrowUp"?ue(e,-1):s.key==="ArrowDown"?ue(e,1):i=!1}),n.addEventListener("keypress",s=>{i&&s.preventDefault()}),document.body.addEventListener("keydown",s=>{s.altKey||s.ctrlKey||s.metaKey||!n.matches(":focus")&&s.key==="/"&&(n.focus(),s.preventDefault())})}function Ne(t,e,n,r){if(!r.index||!r.data)return;e.textContent="";let i=n.value.trim(),s;if(i){let o=i.split(" ").map(a=>a.length?`*${a}*`:"").join(" ");s=r.index.search(o)}else s=[];for(let o=0;oa.score-o.score);for(let o=0,a=Math.min(10,s.length);o`,d=ce(l.name,i);globalThis.DEBUG_SEARCH_WEIGHTS&&(d+=` (score: ${s[o].score.toFixed(2)})`),l.parent&&(d=` + ${ce(l.parent,i)}.${d}`);let y=document.createElement("li");y.classList.value=l.classes??"";let p=document.createElement("a");p.href=r.base+l.url,p.innerHTML=u+d,y.append(p),e.appendChild(y)}}function ue(t,e){let n=t.querySelector(".current");if(!n)n=t.querySelector(e==1?"li:first-child":"li:last-child"),n&&n.classList.add("current");else{let r=n;if(e===1)do r=r.nextElementSibling??void 0;while(r instanceof HTMLElement&&r.offsetParent==null);else do r=r.previousElementSibling??void 0;while(r instanceof HTMLElement&&r.offsetParent==null);r&&(n.classList.remove("current"),r.classList.add("current"))}}function Ve(t,e){let n=t.querySelector(".current");if(n||(n=t.querySelector("li:first-child")),n){let r=n.querySelector("a");r&&(window.location.href=r.href),e.blur()}}function ce(t,e){if(e==="")return t;let n=t.toLocaleLowerCase(),r=e.toLocaleLowerCase(),i=[],s=0,o=n.indexOf(r);for(;o!=-1;)i.push(K(t.substring(s,o)),`${K(t.substring(o,o+r.length))}`),s=o+r.length,o=n.indexOf(r,s);return i.push(K(t.substring(s))),i.join("")}var He={"&":"&","<":"<",">":">","'":"'",'"':"""};function K(t){return t.replace(/[&<>"'"]/g,e=>He[e])}var I=class{constructor(e){this.el=e.el,this.app=e.app}};var F="mousedown",fe="mousemove",H="mouseup",J={x:0,y:0},pe=!1,ee=!1,Be=!1,D=!1,me=/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent);document.documentElement.classList.add(me?"is-mobile":"not-mobile");me&&"ontouchstart"in document.documentElement&&(Be=!0,F="touchstart",fe="touchmove",H="touchend");document.addEventListener(F,t=>{ee=!0,D=!1;let e=F=="touchstart"?t.targetTouches[0]:t;J.y=e.pageY||0,J.x=e.pageX||0});document.addEventListener(fe,t=>{if(ee&&!D){let e=F=="touchstart"?t.targetTouches[0]:t,n=J.x-(e.pageX||0),r=J.y-(e.pageY||0);D=Math.sqrt(n*n+r*r)>10}});document.addEventListener(H,()=>{ee=!1});document.addEventListener("click",t=>{pe&&(t.preventDefault(),t.stopImmediatePropagation(),pe=!1)});var X=class extends I{constructor(e){super(e),this.className=this.el.dataset.toggle||"",this.el.addEventListener(H,n=>this.onPointerUp(n)),this.el.addEventListener("click",n=>n.preventDefault()),document.addEventListener(F,n=>this.onDocumentPointerDown(n)),document.addEventListener(H,n=>this.onDocumentPointerUp(n))}setActive(e){if(this.active==e)return;this.active=e,document.documentElement.classList.toggle("has-"+this.className,e),this.el.classList.toggle("active",e);let n=(this.active?"to-has-":"from-has-")+this.className;document.documentElement.classList.add(n),setTimeout(()=>document.documentElement.classList.remove(n),500)}onPointerUp(e){D||(this.setActive(!0),e.preventDefault())}onDocumentPointerDown(e){if(this.active){if(e.target.closest(".col-sidebar, .tsd-filter-group"))return;this.setActive(!1)}}onDocumentPointerUp(e){if(!D&&this.active&&e.target.closest(".col-sidebar")){let n=e.target.closest("a");if(n){let r=window.location.href;r.indexOf("#")!=-1&&(r=r.substring(0,r.indexOf("#"))),n.href.substring(0,r.length)==r&&setTimeout(()=>this.setActive(!1),250)}}}};var te;try{te=localStorage}catch{te={getItem(){return null},setItem(){}}}var Q=te;var ye=document.head.appendChild(document.createElement("style"));ye.dataset.for="filters";var Y=class extends I{constructor(e){super(e),this.key=`filter-${this.el.name}`,this.value=this.el.checked,this.el.addEventListener("change",()=>{this.setLocalStorage(this.el.checked)}),this.setLocalStorage(this.fromLocalStorage()),ye.innerHTML+=`html:not(.${this.key}) .tsd-is-${this.el.name} { display: none; } +`,this.app.updateIndexVisibility()}fromLocalStorage(){let e=Q.getItem(this.key);return e?e==="true":this.el.checked}setLocalStorage(e){Q.setItem(this.key,e.toString()),this.value=e,this.handleValueChange()}handleValueChange(){this.el.checked=this.value,document.documentElement.classList.toggle(this.key,this.value),this.app.filterChanged(),this.app.updateIndexVisibility()}};var Z=class extends I{constructor(e){super(e),this.summary=this.el.querySelector(".tsd-accordion-summary"),this.icon=this.summary.querySelector("svg"),this.key=`tsd-accordion-${this.summary.dataset.key??this.summary.textContent.trim().replace(/\s+/g,"-").toLowerCase()}`;let n=Q.getItem(this.key);this.el.open=n?n==="true":this.el.open,this.el.addEventListener("toggle",()=>this.update());let r=this.summary.querySelector("a");r&&r.addEventListener("click",()=>{location.assign(r.href)}),this.update()}update(){this.icon.style.transform=`rotate(${this.el.open?0:-90}deg)`,Q.setItem(this.key,this.el.open.toString())}};function ge(t){let e=Q.getItem("tsd-theme")||"os";t.value=e,ve(e),t.addEventListener("change",()=>{Q.setItem("tsd-theme",t.value),ve(t.value)})}function ve(t){document.documentElement.dataset.theme=t}var Le;function be(){let t=document.getElementById("tsd-nav-script");t&&(t.addEventListener("load",xe),xe())}async function xe(){let t=document.getElementById("tsd-nav-container");if(!t||!window.navigationData)return;let n=await(await fetch(window.navigationData)).arrayBuffer(),r=new Blob([n]).stream().pipeThrough(new DecompressionStream("gzip")),i=await new Response(r).json();Le=t.dataset.base+"/",t.innerHTML="";for(let s of i)we(s,t,[]);window.app.createComponents(t),window.app.showPage(),window.app.ensureActivePageVisible()}function we(t,e,n){let r=e.appendChild(document.createElement("li"));if(t.children){let i=[...n,t.text],s=r.appendChild(document.createElement("details"));s.className=t.class?`${t.class} tsd-index-accordion`:"tsd-index-accordion",s.dataset.key=i.join("$");let o=s.appendChild(document.createElement("summary"));o.className="tsd-accordion-summary",o.innerHTML='',Ee(t,o);let a=s.appendChild(document.createElement("div"));a.className="tsd-accordion-details";let l=a.appendChild(document.createElement("ul"));l.className="tsd-nested-navigation";for(let u of t.children)we(u,l,i)}else Ee(t,r,t.class)}function Ee(t,e,n){if(t.path){let r=e.appendChild(document.createElement("a"));r.href=Le+t.path,n&&(r.className=n),location.pathname===r.pathname&&r.classList.add("current"),t.kind&&(r.innerHTML=``),r.appendChild(document.createElement("span")).textContent=t.text}else e.appendChild(document.createElement("span")).textContent=t.text}G(X,"a[data-toggle]");G(Z,".tsd-index-accordion");G(Y,".tsd-filter-item input[type=checkbox]");var Se=document.getElementById("tsd-theme");Se&&ge(Se);var je=new U;Object.defineProperty(window,"app",{value:je});he();be();})(); /*! Bundled license information: lunr/lunr.js: diff --git a/assets/search.js b/assets/search.js index b2f0192..d7fd85f 100644 --- a/assets/search.js +++ b/assets/search.js @@ -1 +1 @@ -window.searchData = "data:application/octet-stream;base64,H4sIAAAAAAAAA7WcUY/bOA6A/4vnNTsbS7Ikz9v2rnsYoLcFrr27h6A4uBPP1GjiDBKn7d5g/vuCthOTNmVLifvU3QkpUvwoSqKdvET73fdDdLd6ib4W5Tq6E4uozLZ5dBcV5Tr/ES2i434T3UXb3fq4yQ+/1n+9/VJtN9Eiethkh0N+iO6i6HUxHKHcrfPBAPDHUX2tzgPs82z996zKft/vth+qfZ5tz8M9HsuHqtiVJ4+GooyRRfSc7fOyOs8OeZ3os1kY5195ts73759rG2erRVnl+8fs4RyIgWiY1Xgputnm5brIyjI/BNu7Iaojpof6bmceduuifLrAlbPipY5gFiDzodoX5dMki4HoVSymps9b853+cFoOR4qyqIps87fsOXsoqj+D/Rnqz+LWNvvx5s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PVG4HO4vYIW23OS8s7r8Be0MHq0yG0uMnXdVMBjgc/HUvomMdlQUbDXm+0k5a94ERBNB5pWr7LYjHIf2UQylq6YQ7aEDKMuVq5w1QxB8AhUA6aLe6pGAC7SlSlcNA0UooI/73Xa4WaFZjw3QfmUA6aGyL13F56w5CJVES1qN5Vr7xj7SRJTlGOVac2gY+a0m/LZkwshjOeGxHZpFpNRYoDf1F0tRTqHcSMZyAxSZNUkO4yPqW/g5JihkzsWNHInH4l4eN5vq/BXdQ/vKLJoRWujJmEuMKspWNbZGG1VmFqjWjcE/DvMd1XQ5VtuOjoRHlpVr8zrp9zIelRU5VlaOjpRHrqsp12nOI6fllNNM0uMTujt3e5uZTXDKuhOkefkK6Wms5zLXP0TFKBvj9tognMpfi+dBDUb1SLjWRa3YPyUIXHtd2Xx6kRmdZ1B8rCsdTm8oIzUUHuv0s331GKnhs5fLyQ5//7JoUe6mrgxC6oObsjWYqqtytm+dIrcRVtue8lNX7tfa3JlEI0LGVfOJ9mANGBQAO+o+eyrRKLuMK35UfeCCRnuAdaV2OwZZiQlav9pVLmtFOF9Uu+HpQiF6yWgABwU3QVXLuKpApzqcNcp348r3kz5dKhoxM6PM+IKrket2ynVScBO8P005PSy4GgEzo8CGe6tBmWZHM224OSYIs3YVCaQ7dBzVNOOqaecBKK0EpbcZTW/H/qiR92bSe8oL+a0n/WaAoTJl2PL0aRE9F895fSy8W316ff0Ld4R/yHNeAAA="; \ No newline at end of file +window.searchData = "data:application/octet-stream;base64,H4sIAAAAAAAAA7WcX4/bRg7Av4v21d1a80+jfWuu7WGBXANccncPxqJQbO1GiFde2HLS3CLfvaAkW6TEkWZs5Sntmhxy+ONwZijZr9F+9/UQ3a1eo89FuYnuxCIqs+c8uouKcpP/FS2i434b3UXPu81xmx9+rv96+6l63kaLaL3NDof8EN1F0ffFcIRyt8kHA8AfR/WNOg+wz7PNr1mV/b7fPb+v9nn2fB7u8Viuq2JXnjwaijJGFtFLts/L6jw75LU2Z7Mwzr/z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kgPoU9dAX7KKy4LY8RXtHloXEuwHoPLvThBo7TZZ1xF/CmvyvqNJH6sBM3GjkSwj80ibOmI3tfT9wAQcRR441rD7S9l5bstmTnewFwzbmSRFlJyrcn2V6e4PEHBPu2YrjTdFlW1JWFKEPDU5TD8LkT2qb+qcJV3uf2c/fWx+SkLRAZZbP11Bbn5dUYUXhRdh8rpx3yQEsIZt3uicDncX8AKbbn6vLO6/AXtDJ6JMxtLjJ13VTAY4GPx1L5CjnZUFGw15vtJOWte4UQTQeaVaytpRzgO7aMYSldNIdpDB1CWK1c5a4Yg+AQqANJFvdUjARdoS5WuGgaKUEAf97vn4WaFZj02QPtdD6SHyr50FZ+z5iBUEi1pNZZr7VctkCaiLMco15pDw8hvNeG3JRNGHssJj+3QLCKlxgK9rb8RjHIK5YYeyw1QZNYkOYyPqD/D72hBIXMubuRIPBb38rjdVufvVh/ad53RjNBC12MuMaooW9XYGm1UmVmgWjcG/zjMd1TT5VhtOzoSHllWrs3rpN/LeFRW5FhZOTpSHrmuplynOY+cllNOM0mPT+ju3O1tZlbjlHUnSPPWHNIzWM9lrn+IilE2xu21QTiVPxcvgxqM6pFwrYtasX9KELj2urL59AY6Os+g+FhXOpxeLUdqKDzW6Wf7zjhSw2cvl5Md/v5l0aLcTV0ZhNQHN2WbYKquytm+LozcRlhte8pPXblfa3NnEoMIJa6aT7QHayBBAbCj7rOnEoOyK3HFj6oPXDBoD7Cu1G7HICtRo/VrXOWyVoTzRbUbni4UoqdHAzgouBpVrcRVBTrV4axRvieufD/p06ViELNklBlfcA1y3U65TgquxvvTlNPDgmsQsGQU2HBvTVCm2dFMG26OGmE2riKBdIeOo5qWuGraeQBKS6P0TkbT27E/GuR9Muk95YX8NpN+M8BQmUrY8vSwiF6Kl7w+Ft6tHr5//xsm/UN1LGAAAA=="; \ No newline at end of file diff --git a/assets/style.css b/assets/style.css index 07a385b..072daed 100644 --- a/assets/style.css +++ b/assets/style.css @@ -29,7 +29,7 @@ --light-color-ts-constructor-signature: var(--light-color-ts-constructor); --light-color-ts-parameter: var(--light-color-ts-variable); /* type literal not included as links will never be generated to it */ - --light-color-ts-type-parameter: var(--light-color-ts-type-alias); + --light-color-ts-type-parameter: #a55c0e; --light-color-ts-accessor: var(--light-color-ts-property); --light-color-ts-get-signature: var(--light-color-ts-accessor); --light-color-ts-set-signature: var(--light-color-ts-accessor); @@ -69,7 +69,7 @@ --dark-color-ts-constructor-signature: var(--dark-color-ts-constructor); --dark-color-ts-parameter: var(--dark-color-ts-variable); /* type literal not included as links will never be generated to it */ - --dark-color-ts-type-parameter: var(--dark-color-ts-type-alias); + --dark-color-ts-type-parameter: #e07d13; --dark-color-ts-accessor: var(--dark-color-ts-property); --dark-color-ts-get-signature: var(--dark-color-ts-accessor); --dark-color-ts-set-signature: var(--dark-color-ts-accessor); @@ -266,12 +266,12 @@ h6 { line-height: 1.2; } -h1 > a, -h2 > a, -h3 > a, -h4 > a, -h5 > a, -h6 > a { +h1 > a:not(.link), +h2 > a:not(.link), +h3 > a:not(.link), +h4 > a:not(.link), +h5 > a:not(.link), +h6 > a:not(.link) { text-decoration: none; color: var(--color-text); } @@ -405,7 +405,8 @@ dd { } body { background: var(--color-background); - font-family: "Segoe UI", sans-serif; + font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans", + Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji"; font-size: 16px; color: var(--color-text); } @@ -649,6 +650,28 @@ input[type="checkbox"]:checked ~ svg .tsd-checkbox-checkmark { font-weight: bold; } +.tsd-full-hierarchy:not(:last-child) { + margin-bottom: 1em; + padding-bottom: 1em; + border-bottom: 1px solid var(--color-accent); +} +.tsd-full-hierarchy, +.tsd-full-hierarchy ul { + list-style: none; + margin: 0; + padding: 0; +} +.tsd-full-hierarchy ul { + padding-left: 1.5rem; +} +.tsd-full-hierarchy a { + padding: 0.25rem 0 !important; + font-size: 1rem; + display: inline-flex; + align-items: center; + color: var(--color-text); +} + .tsd-panel-group.tsd-index-group { margin-bottom: 0; } @@ -714,12 +737,15 @@ input[type="checkbox"]:checked ~ svg .tsd-checkbox-checkmark { } .tsd-navigation > a, .tsd-navigation .tsd-accordion-summary { - width: calc(100% - 0.5rem); + width: calc(100% - 0.25rem); + display: flex; + align-items: center; } .tsd-navigation a, .tsd-navigation summary > span, .tsd-page-navigation a { - display: inline-flex; + display: flex; + width: calc(100% - 0.25rem); align-items: center; padding: 0.25rem; color: var(--color-text); @@ -759,11 +785,6 @@ input[type="checkbox"]:checked ~ svg .tsd-checkbox-checkmark { margin-left: -1.5rem; } -.tsd-nested-navigation > li > a, -.tsd-nested-navigation > li > span { - width: calc(100% - 1.75rem - 0.5rem); -} - .tsd-page-navigation ul { padding-left: 1.75rem; } diff --git a/classes/index.DataReader.html b/classes/index.DataReader.html index 1296a0f..f3fb52c 100644 --- a/classes/index.DataReader.html +++ b/classes/index.DataReader.html @@ -1,127 +1,127 @@ -DataReader | @kayahr/datastream

Reads all kind of data values from the specified source.

-

Constructors

Methods

  • Returns number

    the number of bits that have been read so far.

    -
  • Returns number

    the number of bytes that have been read so far.

    -
  • Returns the default encoding of the reader.

    +DataReader | @kayahr/datastream

    Reads all kind of data values from the specified source.

    +

    Constructors

    Methods

    • Returns number

      the number of bits that have been read so far.

      +
    • Returns number

      the number of bytes that have been read so far.

      +
    • Returns the default encoding of the reader.

      Returns string

      the default encoding used when no encoding is specified as parameter to the various string read methods.

      -
    • Returns the default endianness of the reader.

      Returns Endianness

      the default endianness used when no endianness is specified as parameter to the various read methods.

      -
    • Executes the given operation as a look-ahead operation. So any reading from the reader is a look-ahead and the +

    • Executes the given operation as a look-ahead operation. So any reading from the reader is a look-ahead and the stream position will be reset when operation is finished. Look-ahead operations can be nested.

      Note that while reading data in a look-ahead operation buffers read from the stream pile up in memory because it is not possible to seek in a stream. So the only way to rewind to the previous position in the stream is to remember all the buffers read since then. So keep look-ahead operations short so in the best case the operation takes place in the same or the next buffer.

      -

      Type Parameters

      • T

      Parameters

      • operation: ((commit) => Promise<T>)

        The look-ahead operation to perform.

        -
          • (commit): Promise<T>
          • Parameters

            • commit: ((values?, bitsPerValue?) => void)
                • (values?, bitsPerValue?): void
                • Parameters

                  • Optional values: number
                  • Optional bitsPerValue: number

                  Returns void

            Returns Promise<T>

      Returns Promise<T>

    • Reads a signed 64 bit value.

      -

      Parameters

      • endianness: Endianness = ...

        Optional endianness. Defaults to endianness the reader was configured with.

        -

      Returns Promise<null | bigint>

    • Reads an array of signed 64 bit values.

      -

      Parameters

      • buffer: BigInt64Array

        The buffer to write the read bytes to.

        -
      • Optional options: ReadMultiByteArrayOptions

        Optional read array option.

        -

      Returns Promise<number>

      the number of read 16 bit values. 0 when end of stream is reached or 0 bytes were requested to read.

      -
    • Reads a unsigned 64 bit value.

      -

      Parameters

      • endianness: Endianness = ...

        Optional endianness. Defaults to endianness the reader was configured with.

        -

      Returns Promise<null | bigint>

    • Reads an array of unsigned 64 bit values.

      -

      Parameters

      • buffer: BigUint64Array

        The buffer to write the read bytes to.

        -
      • options: ReadMultiByteArrayOptions = {}

        Optional read array option.

        -

      Returns Promise<number>

      the number of read 16 bit values. 0 when end of stream is reached or 0 bytes were requested to read.

      -
    • Reads and returns a single bit from the stream.

      -

      Returns Promise<null | number>

      the read bit. Null if end of stream has been reached.

      -
    • Reads the given number of bits and returns them as a number array.

      +

      Type Parameters

      • T

      Parameters

      • operation: ((commit) => Promise<T>)

        The look-ahead operation to perform.

        +
          • (commit): Promise<T>
          • Parameters

            • commit: ((values?, bitsPerValue?) => void)
                • (values?, bitsPerValue?): void
                • Parameters

                  • Optional values: number
                  • Optional bitsPerValue: number

                  Returns void

            Returns Promise<T>

      Returns Promise<T>

    • Reads a signed 64 bit value.

      +

      Parameters

      • endianness: Endianness = ...

        Optional endianness. Defaults to endianness the reader was configured with.

        +

      Returns Promise<null | bigint>

    • Reads an array of signed 64 bit values.

      +

      Parameters

      • buffer: BigInt64Array

        The buffer to write the read bytes to.

        +
      • Optional options: ReadMultiByteArrayOptions

        Optional read array option.

        +

      Returns Promise<number>

      the number of read 16 bit values. 0 when end of stream is reached or 0 bytes were requested to read.

      +
    • Reads a unsigned 64 bit value.

      +

      Parameters

      • endianness: Endianness = ...

        Optional endianness. Defaults to endianness the reader was configured with.

        +

      Returns Promise<null | bigint>

    • Reads an array of unsigned 64 bit values.

      +

      Parameters

      • buffer: BigUint64Array

        The buffer to write the read bytes to.

        +
      • options: ReadMultiByteArrayOptions = {}

        Optional read array option.

        +

      Returns Promise<number>

      the number of read 16 bit values. 0 when end of stream is reached or 0 bytes were requested to read.

      +
    • Reads and returns a single bit from the stream.

      +

      Returns Promise<null | number>

      the read bit. Null if end of stream has been reached.

      +
    • Reads the given number of bits and returns them as a number array.

      TODO This can be optimized by reading the bits directly from the buffer instead of asynchronously reading bit by bit.

      -

      Parameters

      • numBits: number

        The number of bits to read.

        -

      Returns Promise<number[]>

      The read bits. Empty array when end of stream has been reached without reading any bit.

      -
    • Reads a signed 16 bit value.

      -

      Parameters

      • endianness: Endianness = ...

        Optional endianness. Defaults to endianness the reader was configured with.

        -

      Returns Promise<null | number>

    • Reads an array of signed 16 bit values.

      -

      Parameters

      • buffer: Int16Array

        The buffer to write the read bytes to.

        -
      • Optional options: ReadMultiByteArrayOptions

        Optional read array option.

        -

      Returns Promise<number>

      the number of read 16 bit values. 0 when end of stream is reached or 0 bytes were requested to read.

      -
    • Reads a signed 32 bit value.

      -

      Parameters

      • endianness: Endianness = ...

        Optional endianness. Defaults to endianness the reader was configured with.

        -

      Returns Promise<null | number>

    • Reads an array of signed 32 bit values.

      -

      Parameters

      • buffer: Int32Array

        The buffer to write the read bytes to.

        -
      • Optional options: ReadMultiByteArrayOptions

        Optional read array option.

        -

      Returns Promise<number>

      the number of read 16 bit values. 0 when end of stream is reached or 0 bytes were requested to read.

      -
    • Reads and returns an signed 8 bit value.

      -

      Returns Promise<null | number>

      the read value. Null if end of stream has been reached.

      -
    • Reads an array of signed 8 bit values.

      -

      Parameters

      • buffer: Int8Array

        The buffer to write the read bytes to.

        -
      • offset: number = 0

        Offset within the buffer to start writing to. Defaults to 0.

        -
      • size: number = ...

        Number of bytes to read. Defaults to buffer size minus offset.

        -

      Returns Promise<number>

      the number of read bytes. 0 when end of stream is reached or 0 bytes were requested to read.

      -
    • Reads a line from the stream. EOL marker can be defined in the options and by default stops at CRLF or LF +

      Parameters

      • numBits: number

        The number of bits to read.

        +

      Returns Promise<number[]>

      The read bits. Empty array when end of stream has been reached without reading any bit.

      +
    • Reads a signed 16 bit value.

      +

      Parameters

      • endianness: Endianness = ...

        Optional endianness. Defaults to endianness the reader was configured with.

        +

      Returns Promise<null | number>

    • Reads an array of signed 16 bit values.

      +

      Parameters

      • buffer: Int16Array

        The buffer to write the read bytes to.

        +
      • Optional options: ReadMultiByteArrayOptions

        Optional read array option.

        +

      Returns Promise<number>

      the number of read 16 bit values. 0 when end of stream is reached or 0 bytes were requested to read.

      +
    • Reads a signed 32 bit value.

      +

      Parameters

      • endianness: Endianness = ...

        Optional endianness. Defaults to endianness the reader was configured with.

        +

      Returns Promise<null | number>

    • Reads an array of signed 32 bit values.

      +

      Parameters

      • buffer: Int32Array

        The buffer to write the read bytes to.

        +
      • Optional options: ReadMultiByteArrayOptions

        Optional read array option.

        +

      Returns Promise<number>

      the number of read 16 bit values. 0 when end of stream is reached or 0 bytes were requested to read.

      +
    • Reads and returns an signed 8 bit value.

      +

      Returns Promise<null | number>

      the read value. Null if end of stream has been reached.

      +
    • Reads an array of signed 8 bit values.

      +

      Parameters

      • buffer: Int8Array

        The buffer to write the read bytes to.

        +
      • offset: number = 0

        Offset within the buffer to start writing to. Defaults to 0.

        +
      • size: number = ...

        Number of bytes to read. Defaults to buffer size minus offset.

        +

      Returns Promise<number>

      the number of read bytes. 0 when end of stream is reached or 0 bytes were requested to read.

      +
    • Reads a line from the stream. EOL marker can be defined in the options and by default stops at CRLF or LF without including the EOL marker in the returned string.

      -

      Parameters

      Returns Promise<null | string>

      the read line. Null when end of stream is reached.

      -
    • Reads a null-terminated string from the stream.

      -

      Parameters

      Returns Promise<null | string>

      the read line. Null when end of stream is reached.

      -
    • Reads a string from the stream.

      -

      Parameters

      • size: number

        The maximum number of bytes to read. Only in ASCII encoding this is the same as the length +

        Parameters

        Returns Promise<null | string>

        the read line. Null when end of stream is reached.

        +
    • Reads a null-terminated string from the stream.

      +

      Parameters

      Returns Promise<null | string>

      the read line. Null when end of stream is reached.

      +
    • Reads a string from the stream.

      +

      Parameters

      • size: number

        The maximum number of bytes to read. Only in ASCII encoding this is the same as the length of the string. In other encodings the returned string may be shorter.

        -
      • encoding: string = ...

        The encoding. Defaults to encoding the reader was configured with.

        -

      Returns Promise<string>

      the read string. May be smaller than requested size. Empty when end of stream is reached.

      -
    • Reads an unsigned 16 bit value.

      -

      Parameters

      • endianness: Endianness = ...

        Optional endianness. Defaults to endianness the reader was configured with.

        -

      Returns Promise<null | number>

    • Reads an array of unsigned 16 bit values.

      -

      Parameters

      • buffer: Uint16Array

        The buffer to write the read bytes to.

        -
      • options: ReadMultiByteArrayOptions = {}

        Optional read array option.

        -

      Returns Promise<number>

      the number of read 16 bit values. 0 when end of stream is reached or 0 bytes were requested to read.

      -
    • Reads an unsigned 32 bit value.

      -

      Parameters

      • endianness: Endianness = ...

        Optional endianness. Defaults to endianness the reader was configured with.

        -

      Returns Promise<null | number>

    • Reads an array of unsigned 32 bit values.

      -

      Parameters

      • buffer: Uint32Array

        The buffer to write the read bytes to.

        -
      • options: ReadMultiByteArrayOptions = {}

        Optional read array option.

        -

      Returns Promise<number>

      the number of read 16 bit values. 0 when end of stream is reached or 0 bytes were requested to read.

      -
    • Reads and returns an unsigned 8 bit value.

      -

      Returns Promise<null | number>

      the read value. Null if end of stream has been reached.

      -
    • Reads an array of unsigned 8 bit values.

      -

      Parameters

      • buffer: Uint8Array | Uint8ClampedArray

        The buffer to write the read bytes to.

        -
      • offset: number = 0

        Offset within the buffer to start writing to. Defaults to 0.

        -
      • size: number = ...

        Number of bytes to read. Defaults to buffer size minus offset.

        -

      Returns Promise<number>

      the number of read bytes. 0 when end of stream is reached or 0 bytes were requested to read.

      -
    • Skips the given number of bits. This is not the same as simply reading the given number of bits and ignoring +

    • encoding: string = ...

      The encoding. Defaults to encoding the reader was configured with.

      +

    Returns Promise<string>

    the read string. May be smaller than requested size. Empty when end of stream is reached.

    +
  • Reads an unsigned 16 bit value.

    +

    Parameters

    • endianness: Endianness = ...

      Optional endianness. Defaults to endianness the reader was configured with.

      +

    Returns Promise<null | number>

  • Reads an array of unsigned 16 bit values.

    +

    Parameters

    • buffer: Uint16Array

      The buffer to write the read bytes to.

      +
    • options: ReadMultiByteArrayOptions = {}

      Optional read array option.

      +

    Returns Promise<number>

    the number of read 16 bit values. 0 when end of stream is reached or 0 bytes were requested to read.

    +
  • Reads an unsigned 32 bit value.

    +

    Parameters

    • endianness: Endianness = ...

      Optional endianness. Defaults to endianness the reader was configured with.

      +

    Returns Promise<null | number>

  • Reads an array of unsigned 32 bit values.

    +

    Parameters

    • buffer: Uint32Array

      The buffer to write the read bytes to.

      +
    • options: ReadMultiByteArrayOptions = {}

      Optional read array option.

      +

    Returns Promise<number>

    the number of read 16 bit values. 0 when end of stream is reached or 0 bytes were requested to read.

    +
  • Reads and returns an unsigned 8 bit value.

    +

    Returns Promise<null | number>

    the read value. Null if end of stream has been reached.

    +
  • Reads an array of unsigned 8 bit values.

    +

    Parameters

    • buffer: Uint8Array | Uint8ClampedArray

      The buffer to write the read bytes to.

      +
    • offset: number = 0

      Offset within the buffer to start writing to. Defaults to 0.

      +
    • size: number = ...

      Number of bytes to read. Defaults to buffer size minus offset.

      +

    Returns Promise<number>

    the number of read bytes. 0 when end of stream is reached or 0 bytes were requested to read.

    +
  • Skips the given number of bits. This is not the same as simply reading the given number of bits and ignoring the read data. Instead it is optimized to first skip as many bits as needed to get to a byte boundary then skipping full bytes inside current buffer, optionally fetching new buffers and finally skipping the remaining number of bits.

    -

    Parameters

    • bits: number

      The number of bits to skip.

      -

    Returns Promise<number>

    The actual number of skipped bits. Will be lower than given number if end of stream has been reached.

    -
  • Skips the given number of bytes. This is not the same as simply reading the given number of bytes and ignoring +

    Parameters

    • bits: number

      The number of bits to skip.

      +

    Returns Promise<number>

    The actual number of skipped bits. Will be lower than given number if end of stream has been reached.

    +
  • Skips the given number of bytes. This is not the same as simply reading the given number of bytes and ignoring the read data. Instead it is optimized to first skip as many bits as needed to get to a byte boundary then skipping full bytes inside the current buffer, optionally fetching new buffers and finally skipping the remaining bits.

    Actually this is the same as calling skipBits with the number of bytes converted to the number of bits.

    -

    Parameters

    • bytes: number

      The number of bytes to skip.

      -

    Returns Promise<number>

    The actual number of fully skipped bytes (not counting partially skipped bytes). Will be lower than +

Parameters

  • bytes: number

    The number of bytes to skip.

    +

Returns Promise<number>

The actual number of fully skipped bytes (not counting partially skipped bytes). Will be lower than given number if end of stream has been reached.

-

Generated using TypeDoc

\ No newline at end of file +

Generated using TypeDoc

\ No newline at end of file diff --git a/classes/index.DataWriter.html b/classes/index.DataWriter.html index 086c534..c9eb91a 100644 --- a/classes/index.DataWriter.html +++ b/classes/index.DataWriter.html @@ -1,94 +1,94 @@ -DataWriter | @kayahr/datastream

Writes all kind of data values to a specified sink.

+DataWriter | @kayahr/datastream

Writes all kind of data values to a specified sink.

Written data is buffered so you have to call the flush method when you are done writing all data to ensure that all data is written to the sink.

All methods of the writer are asynchronous but can safely be used synchronously when you have no reason to wait for it. Usually you only want to wait for the flush method at the end of a write operation.

-

Constructors

Methods

  • Writes all buffered data to the sink. If an incomplete byte is buffered then it is padded with zeroes so the +

Constructors

Methods

  • Writes all buffered data to the sink. If an incomplete byte is buffered then it is padded with zeroes so the writer points to the beginning of a new byte after flushing.

    -

    Returns Promise<void>

  • Returns number

    The buffer size of the writer.

    -
  • Returns the default encoding of the writer.

    +

    Returns Promise<void>

  • Returns number

    The buffer size of the writer.

    +
  • Returns the default encoding of the writer.

    Returns string

    the default encoding used when no encoding is specified as parameter to the various string write methods.

    -
  • Returns the default endianness of the writer.

    Returns Endianness

    the default endianness used when no endianness is specified as parameter to the various write methods.

    -
  • Returns the number of written bytes. This value reflects the number of bytes the writer was told to write so +

  • Returns the number of written bytes. This value reflects the number of bytes the writer was told to write so far, not the actual number of written bytes (which may not be finished because writing happens asynchronously). When a write operation fails then this counter is invalid and may not be in sync with the output sink any longer.

    Returns number

    the number of written bytes.

    -
  • Writes an signed 64 bit value.

    -

    Parameters

    • value: bigint

      The value to write.

      -
    • endianness: Endianness = ...

      Optional endianness. Defaults to endianness the writer was configured with.

      -

    Returns Promise<void>

  • Writes an array of signed 64 bit values.

    -

    Parameters

    • values: BigInt64Array

      The values to write.

      -
    • endianness: Endianness = ...

      Optional endianness. Defaults to endianness the writer was configured with.

      -

    Returns Promise<void>

  • Writes an unsigned 64 bit value.

    -

    Parameters

    • value: bigint

      The value to write.

      -
    • endianness: Endianness = ...

      Optional endianness. Defaults to endianness the writer was configured with.

      -

    Returns Promise<void>

  • Writes an array of unsigned 64 bit values.

    -

    Parameters

    • values: BigUint64Array

      The values to write.

      -
    • endianness: Endianness = ...

      Optional endianness. Defaults to endianness the writer was configured with.

      -

    Returns Promise<void>

  • Writes a single bit.

    -

    Parameters

    • value: number

      The bit to write.

      -

    Returns Promise<void>

  • Writes a signed 16 bit value.

    -

    Parameters

    • value: number

      The value to write.

      -
    • endianness: Endianness = ...

      Optional endianness. Defaults to endianness the writer was configured with.

      -

    Returns Promise<void>

  • Writes an array of signed 16 bit values.

    -

    Parameters

    • values: Int16Array

      The values to write.

      -
    • endianness: Endianness = ...

      Optional endianness. Defaults to endianness the writer was configured with.

      -

    Returns Promise<void>

  • Writes a signed 32 bit value.

    -

    Parameters

    • value: number

      The value to write.

      -
    • endianness: Endianness = ...

      Optional endianness. Defaults to endianness the writer was configured with.

      -

    Returns Promise<void>

  • Writes an array of signed 32 bit values.

    -

    Parameters

    • values: Int32Array

      The values to write.

      -
    • endianness: Endianness = ...

      Optional endianness. Defaults to endianness the writer was configured with.

      -

    Returns Promise<void>

  • Writes a signed 8 bit value.

    -

    Parameters

    • value: number

      The value to write.

      -

    Returns Promise<void>

  • Writes an array of signed 8 bit values.

    -

    Parameters

    • values: Int8Array

      The values to write.

      -

    Returns Promise<void>

  • Writes a string.

    -

    Parameters

    • text: string

      The text to write.

      -
    • encoding: string = ...

      The encoding. Defaults to encoding the writer was configured with.

      -

    Returns Promise<void>

  • Writes an unsigned 16 bit value.

    -

    Parameters

    • value: number

      The value to write.

      -
    • endianness: Endianness = ...

      Optional endianness. Defaults to endianness the writer was configured with.

      -

    Returns Promise<void>

  • Writes an array of unsigned 16 bit values.

    -

    Parameters

    • values: Uint16Array

      The values to write.

      -
    • endianness: Endianness = ...

      Optional endianness. Defaults to endianness the writer was configured with.

      -

    Returns Promise<void>

  • Writes an unsigned 32 bit value.

    -

    Parameters

    • value: number

      The value to write.

      -
    • endianness: Endianness = ...

      Optional endianness. Defaults to endianness the writer was configured with.

      -

    Returns Promise<void>

  • Writes an array of unsigned 32 bit values.

    -

    Parameters

    • values: Uint32Array

      The values to write.

      -
    • endianness: Endianness = ...

      Optional endianness. Defaults to endianness the writer was configured with.

      -

    Returns Promise<void>

  • Writes an unsigned 8 bit value.

    -

    Parameters

    • value: number

      The value to write.

      -

    Returns Promise<void>

  • Writes an array of unsigned 8 bit values.

    -

    Parameters

    • values: Uint8Array | Uint8ClampedArray

      The values to write.

      -

    Returns Promise<void>

Generated using TypeDoc

\ No newline at end of file +
  • Writes an signed 64 bit value.

    +

    Parameters

    • value: bigint

      The value to write.

      +
    • endianness: Endianness = ...

      Optional endianness. Defaults to endianness the writer was configured with.

      +

    Returns void

  • Writes an array of signed 64 bit values.

    +

    Parameters

    • values: BigInt64Array

      The values to write.

      +
    • endianness: Endianness = ...

      Optional endianness. Defaults to endianness the writer was configured with.

      +

    Returns void

  • Writes an unsigned 64 bit value.

    +

    Parameters

    • value: bigint

      The value to write.

      +
    • endianness: Endianness = ...

      Optional endianness. Defaults to endianness the writer was configured with.

      +

    Returns void

  • Writes an array of unsigned 64 bit values.

    +

    Parameters

    • values: BigUint64Array

      The values to write.

      +
    • endianness: Endianness = ...

      Optional endianness. Defaults to endianness the writer was configured with.

      +

    Returns void

  • Writes a single bit.

    +

    Parameters

    • value: number

      The bit to write.

      +

    Returns void

  • Writes a signed 16 bit value.

    +

    Parameters

    • value: number

      The value to write.

      +
    • endianness: Endianness = ...

      Optional endianness. Defaults to endianness the writer was configured with.

      +

    Returns void

  • Writes an array of signed 16 bit values.

    +

    Parameters

    • values: Int16Array

      The values to write.

      +
    • endianness: Endianness = ...

      Optional endianness. Defaults to endianness the writer was configured with.

      +

    Returns void

  • Writes a signed 32 bit value.

    +

    Parameters

    • value: number

      The value to write.

      +
    • endianness: Endianness = ...

      Optional endianness. Defaults to endianness the writer was configured with.

      +

    Returns void

  • Writes an array of signed 32 bit values.

    +

    Parameters

    • values: Int32Array

      The values to write.

      +
    • endianness: Endianness = ...

      Optional endianness. Defaults to endianness the writer was configured with.

      +

    Returns void

  • Writes a signed 8 bit value.

    +

    Parameters

    • value: number

      The value to write.

      +

    Returns void

  • Writes an array of signed 8 bit values.

    +

    Parameters

    • values: Int8Array

      The values to write.

      +

    Returns void

  • Writes a string.

    +

    Parameters

    • text: string

      The text to write.

      +
    • encoding: string = ...

      The encoding. Defaults to encoding the writer was configured with.

      +

    Returns void

  • Writes an unsigned 16 bit value.

    +

    Parameters

    • value: number

      The value to write.

      +
    • endianness: Endianness = ...

      Optional endianness. Defaults to endianness the writer was configured with.

      +

    Returns void

  • Writes an array of unsigned 16 bit values.

    +

    Parameters

    • values: Uint16Array

      The values to write.

      +
    • endianness: Endianness = ...

      Optional endianness. Defaults to endianness the writer was configured with.

      +

    Returns void

  • Writes an unsigned 32 bit value.

    +

    Parameters

    • value: number

      The value to write.

      +
    • endianness: Endianness = ...

      Optional endianness. Defaults to endianness the writer was configured with.

      +

    Returns void

  • Writes an array of unsigned 32 bit values.

    +

    Parameters

    • values: Uint32Array

      The values to write.

      +
    • endianness: Endianness = ...

      Optional endianness. Defaults to endianness the writer was configured with.

      +

    Returns void

  • Writes an unsigned 8 bit value.

    +

    Parameters

    • value: number

      The value to write.

      +

    Returns void

  • Writes an array of unsigned 8 bit values.

    +

    Parameters

    • values: Uint8Array | Uint8ClampedArray

      The values to write.

      +

    Returns void

Generated using TypeDoc

\ No newline at end of file diff --git a/classes/index.Uint8ArraySink.html b/classes/index.Uint8ArraySink.html index 2c95ea5..f4424b0 100644 --- a/classes/index.Uint8ArraySink.html +++ b/classes/index.Uint8ArraySink.html @@ -1,25 +1,25 @@ -Uint8ArraySink | @kayahr/datastream

Sink which writes into a growing Uint8Array.

-

Implements

Constructors

Methods

  • Returns the byte at the given index.

    -

    Parameters

    • index: number

      The index. Negative indices references bytes from the end.

      +Uint8ArraySink | @kayahr/datastream

      Sink which writes into a growing Uint8Array.

      +

      Implements

      Constructors

      Methods

      • Returns the byte at the given index.

        +

        Parameters

        • index: number

          The index. Negative indices references bytes from the end.

        Returns undefined | number

        The found byte or undefined if out of bounds.

        -
      • Returns number

        the current capacity. When size reaches this capacity then the internal buffer must grow.

        -
      • Resets the sink so it can be used for another operation. This keeps the current capacity and reuses the same +

      • Returns number

        the current capacity. When size reaches this capacity then the internal buffer must grow.

        +
      • Resets the sink so it can be used for another operation. This keeps the current capacity and reuses the same buffer so make sure you finished processing the previous data.

        -

        Returns void

      • Rewinds the sink by the given number of bytes. The size shrinks accordingly but the capacity stays the same as +

        Returns void

      • Rewinds the sink by the given number of bytes. The size shrinks accordingly but the capacity stays the same as before.

        -

        Parameters

        • numBytes: number

          The number of bytes to remove from the end of the sink.

          -

        Returns void

      • Writes the given chunk to the sink.

        -

        Parameters

        • chunk: number | Uint8Array

          Chunk of data to write to the sink.

          +

          Parameters

          • numBytes: number

            The number of bytes to remove from the end of the sink.

            +

          Returns void

      • Writes the given chunk to the sink.

        +

        Parameters

        • chunk: number | Uint8Array

          Chunk of data to write to the sink.

        Returns void

        a promise if write operation is asynchronous, nothing when write operation is synchronous.

        -

      Generated using TypeDoc

      \ No newline at end of file +

Generated using TypeDoc

\ No newline at end of file diff --git a/classes/index.Uint8ArraySource.html b/classes/index.Uint8ArraySource.html index 1abe143..ac33cf2 100644 --- a/classes/index.Uint8ArraySource.html +++ b/classes/index.Uint8ArraySource.html @@ -1,7 +1,7 @@ -Uint8ArraySource | @kayahr/datastream

Source which reads from a Uint8Array.

-

Implements

Constructors

Methods

Constructors

Methods

  • Reads a chunk from the source.

    -

    Returns ReadableStreamReadResult<Uint8Array>

    the read result.

    -

Generated using TypeDoc

\ No newline at end of file +Uint8ArraySource | @kayahr/datastream

Source which reads from a Uint8Array.

+

Implements

Constructors

Methods

Constructors

Methods

  • Reads a chunk from the source.

    +

    Returns ReadableStreamReadResult<Uint8Array>

    the read result.

    +

Generated using TypeDoc

\ No newline at end of file diff --git a/classes/node.FileInputStream.html b/classes/node.FileInputStream.html index 12f4f4b..12b1f75 100644 --- a/classes/node.FileInputStream.html +++ b/classes/node.FileInputStream.html @@ -1,8 +1,9 @@ -FileInputStream | @kayahr/datastream

File input stream for Node.js.

-

Hierarchy

  • ReadableStream<Uint8Array>
    • FileInputStream

Constructors

Methods

Constructors

  • Creates a new file input stream reading to the given file.

    -

    Parameters

    • filename: string

      The name of the file to read.

      -
    • chunkSize: number = 8192

      The size of the chunks to read from the file.

      -

    Returns FileInputStream

Methods

Generated using TypeDoc

\ No newline at end of file +FileInputStream | @kayahr/datastream

File input stream for Node.js.

+

Hierarchy

  • ReadableStream<Uint8Array>
    • FileInputStream

Implements

  • AsyncDisposable

Constructors

Methods

Constructors

  • Creates a new file input stream reading to the given file.

    +

    Parameters

    • filename: string

      The name of the file to read.

      +
    • chunkSize: number = 8192

      The size of the chunks to read from the file.

      +

    Returns FileInputStream

Methods

  • Returns PromiseLike<void>

    Inherit Doc

Generated using TypeDoc

\ No newline at end of file diff --git a/classes/node.FileOutputStream.html b/classes/node.FileOutputStream.html index 91338f3..32ce0f1 100644 --- a/classes/node.FileOutputStream.html +++ b/classes/node.FileOutputStream.html @@ -1,5 +1,6 @@ -FileOutputStream | @kayahr/datastream

File output stream for Node.js.

-

Hierarchy

  • WritableStream<Uint8Array>
    • FileOutputStream

Constructors

Constructors

Generated using TypeDoc

\ No newline at end of file +FileOutputStream | @kayahr/datastream

File output stream for Node.js.

+

Hierarchy

  • WritableStream<Uint8Array>
    • FileOutputStream

Implements

  • AsyncDisposable

Constructors

Methods

Constructors

Methods

  • Returns PromiseLike<void>

    Inherit Doc

Generated using TypeDoc

\ No newline at end of file diff --git a/enums/index.Endianness.html b/enums/index.Endianness.html index f3dde9c..bee03e1 100644 --- a/enums/index.Endianness.html +++ b/enums/index.Endianness.html @@ -1,6 +1,6 @@ -Endianness | @kayahr/datastream

Enumeration Endianness

Enum for specifying endianness

-

Enumeration Members

Enumeration Members

BIG: 1

Big Endian (High byte before low byte)

-
LITTLE: 0

Little Endian (Low byte before high byte)

-

Generated using TypeDoc

\ No newline at end of file +Endianness | @kayahr/datastream

Enumeration Endianness

Enum for specifying endianness

+

Enumeration Members

Enumeration Members

BIG: 1

Big Endian (High byte before low byte)

+
LITTLE: 0

Little Endian (Low byte before high byte)

+

Generated using TypeDoc

\ No newline at end of file diff --git a/functions/index.getNativeEndianness.html b/functions/index.getNativeEndianness.html index dba55ca..cff8132 100644 --- a/functions/index.getNativeEndianness.html +++ b/functions/index.getNativeEndianness.html @@ -1,3 +1,3 @@ -getNativeEndianness | @kayahr/datastream

Function getNativeEndianness

  • Returns the native endianness of the system.

    +getNativeEndianness | @kayahr/datastream

    Function getNativeEndianness

    Generated using TypeDoc

    \ No newline at end of file +

Generated using TypeDoc

\ No newline at end of file diff --git a/functions/index.readDataFromStream.html b/functions/index.readDataFromStream.html index 437d3af..60171cc 100644 --- a/functions/index.readDataFromStream.html +++ b/functions/index.readDataFromStream.html @@ -1,6 +1,6 @@ -readDataFromStream | @kayahr/datastream
  • Creates a data reader for the given stream, passes it to the given callback function and releases the stream reader +readDataFromStream | @kayahr/datastream

    • Creates a data reader for the given stream, passes it to the given callback function and releases the stream reader lock after callback execution.

      -

      Parameters

      • stream: ReadableStream<Uint8Array>

        The stream to read from.

        -
      • callback: ((reader) => void | Promise<void>)

        The callback function to call with the created data reader as argument.

        -
          • (reader): void | Promise<void>
          • Parameters

            Returns void | Promise<void>

      • Optional options: DataReaderOptions

        Optional data reader options.

        -

      Returns Promise<void>

    Generated using TypeDoc

    \ No newline at end of file +

    Parameters

    • stream: ReadableStream<Uint8Array>

      The stream to read from.

      +
    • callback: ((reader) => void | Promise<void>)

      The callback function to call with the created data reader as argument.

      +
        • (reader): void | Promise<void>
        • Parameters

          Returns void | Promise<void>

    • Optional options: DataReaderOptions

      Optional data reader options.

      +

    Returns Promise<void>

Generated using TypeDoc

\ No newline at end of file diff --git a/functions/index.swap16.html b/functions/index.swap16.html index cfc96f5..1476dd6 100644 --- a/functions/index.swap16.html +++ b/functions/index.swap16.html @@ -1,4 +1,4 @@ -swap16 | @kayahr/datastream
  • Swaps endianness of given 16 bit value.

    -

    Parameters

    • value: number

      The value to swap.

      +swap16 | @kayahr/datastream
      • Swaps endianness of given 16 bit value.

        +

        Parameters

        • value: number

          The value to swap.

        Returns number

        the swapped value.

        -

      Generated using TypeDoc

      \ No newline at end of file +

Generated using TypeDoc

\ No newline at end of file diff --git a/functions/index.swap32.html b/functions/index.swap32.html index b7c82d9..3dd7b13 100644 --- a/functions/index.swap32.html +++ b/functions/index.swap32.html @@ -1,4 +1,4 @@ -swap32 | @kayahr/datastream
  • Swaps endianness of given 32 bit value.

    -

    Parameters

    • value: number

      The value to swap.

      +swap32 | @kayahr/datastream
      • Swaps endianness of given 32 bit value.

        +

        Parameters

        • value: number

          The value to swap.

        Returns number

        the swapped value.

        -

      Generated using TypeDoc

      \ No newline at end of file +

Generated using TypeDoc

\ No newline at end of file diff --git a/functions/index.swap64.html b/functions/index.swap64.html index 0eb96f9..4370b69 100644 --- a/functions/index.swap64.html +++ b/functions/index.swap64.html @@ -1,4 +1,4 @@ -swap64 | @kayahr/datastream
  • Swaps endianness of given 64 bit value.

    -

    Parameters

    • value: bigint

      The value to swap.

      +swap64 | @kayahr/datastream
      • Swaps endianness of given 64 bit value.

        +

        Parameters

        • value: bigint

          The value to swap.

        Returns bigint

        the swapped value.

        -

      Generated using TypeDoc

      \ No newline at end of file +

Generated using TypeDoc

\ No newline at end of file diff --git a/functions/index.writeDataToStream.html b/functions/index.writeDataToStream.html index 50e0163..0519fbd 100644 --- a/functions/index.writeDataToStream.html +++ b/functions/index.writeDataToStream.html @@ -1,6 +1,6 @@ -writeDataToStream | @kayahr/datastream
  • Creates a data writer for the given stream, passes it to the given callback function, flushes the data writer +writeDataToStream | @kayahr/datastream

    • Creates a data writer for the given stream, passes it to the given callback function, flushes the data writer and release the stream writer lock after callback execution.

      -

      Parameters

      • stream: WritableStream<Uint8Array>

        The stream to write to.

        -
      • callback: ((writer) => void | Promise<void>)

        The callback function to call with the created data writer as argument.

        -
          • (writer): void | Promise<void>
          • Parameters

            Returns void | Promise<void>

      • Optional options: DataWriterOptions

        Optional data writer options.

        -

      Returns Promise<void>

    Generated using TypeDoc

    \ No newline at end of file +

    Parameters

    • stream: WritableStream<Uint8Array>

      The stream to write to.

      +
    • callback: ((writer) => void | Promise<void>)

      The callback function to call with the created data writer as argument.

      +
        • (writer): void | Promise<void>
        • Parameters

          Returns void | Promise<void>

    • Optional options: DataWriterOptions

      Optional data writer options.

      +

    Returns Promise<void>

Generated using TypeDoc

\ No newline at end of file diff --git a/hierarchy.html b/hierarchy.html new file mode 100644 index 0000000..6cb1049 --- /dev/null +++ b/hierarchy.html @@ -0,0 +1 @@ +@kayahr/datastream

Generated using TypeDoc

\ No newline at end of file diff --git a/index.html b/index.html index a5058a8..cfa14c5 100644 --- a/index.html +++ b/index.html @@ -1,4 +1,4 @@ -@kayahr/datastream

@kayahr/datastream

Datastream

GitHub | NPM | API Doc

+@kayahr/datastream

@kayahr/datastream

Datastream

GitHub | NPM | API Doc

Data stream classes for reading and writing all kinds of data types. For input and output the data stream classes uses very simple source and sink interfaces which are compatible to the readers and writers provided by ReadableStream and WritableStream from the Streams API. But this library also provides some easy to use stream implementations to use Node.js files and Byte Arrays as source/sink.

The following data types are currently supported:

    @@ -104,17 +104,17 @@
    import { Endianness } from "@kayahr/datastream";

    const writer = new DataWriter(sink, {
    endianness: Endianness.BIG,
    encoding: "utf-16be",
    bufferSize: 8192
    });

    Writing values

    Writing single bits, bytes, multi-byte values, arrays and strings works like this:

    -
    await writer.writeBit(1);
    await writer.writeUint8(5);
    await writer.writeInt8(-3);
    await writer.writeUint16(10000);
    await writer.writeInt16(-5000);
    await writer.writeUint32(5762874);
    await writer.writeInt32(-2357622);
    await writer.writeBigUint64(75721771n);
    await writer.writeBigInt64(-3247534n);
    await writer.writeUint8Array(new Uint8Array(values));
    await writer.writeUint8Array(new Int8Array(values));
    await writer.writeUint16Array(new Uint16Array(values));
    await writer.writeUInt16Array(new Int16Array(values));
    await writer.writeUint32Array(new Uint32Array(values));
    await writer.writeUInt32Array(new Int32Array(values));
    await writer.writeBigUint64Array(new BigUint64Array(values));
    await writer.writeBigInt64Array(new BigInt64Array(values));
    await writer.writeString("Foo"); +
    writer.writeBit(1);
    writer.writeUint8(5);
    writer.writeInt8(-3);
    writer.writeUint16(10000);
    writer.writeInt16(-5000);
    writer.writeUint32(5762874);
    writer.writeInt32(-2357622);
    writer.writeBigUint64(75721771n);
    writer.writeBigInt64(-3247534n);
    writer.writeUint8Array(new Uint8Array(values));
    writer.writeUint8Array(new Int8Array(values));
    writer.writeUint16Array(new Uint16Array(values));
    writer.writeUInt16Array(new Int16Array(values));
    writer.writeUint32Array(new Uint32Array(values));
    writer.writeUInt32Array(new Int32Array(values));
    writer.writeBigUint64Array(new BigUint64Array(values));
    writer.writeBigInt64Array(new BigInt64Array(values));
    writer.writeString("Foo");
    -

    All write methods return a promise but you don't actually need to await it. The write operation is only asynchronous when the buffer is full and is asynchronously written to the sink. It is perfectly fine to write more data while the asynchronous write operation is still running. So usually it is is enough to just await the last write operation.

    -

    In case you are finished writing to the writer you have to flush the buffer to ensure it is written to the sink:

    +

    All write methods synchronously fills the write buffer and flushes the buffer asynchronously when full.

    +

    In case you are finished writing to the writer you have to flush the buffer a last time and await the returned promise to ensure it is fully written to the sink:

    await writer.flush();
     

    When writing multi-bytes you can specify the endianness. If you don't do this then the global endianness of the writer is used which defaults to the native endianness. Example for specifying endianness:

    -
    await writer.writeUint32(123456, Endianness.BIG)
    +
    writer.writeUint32(123456, Endianness.BIG)
     

    When writing strings then you can specify the text encoding. If you don't do this then the global encoding of the writer is used which defaults to UTF-8. Example for specifying encoding:

    -
    await writer.writeString("灯台もと暗し。", "Shift-JIS")
    +
    writer.writeString("灯台もと暗し。", "Shift-JIS")
     

    If you want to write null-terminated strings or lines then append "\0" or EOF characters like "\r\n" yourself.

    Text-Encodings

    This project depends on the text-encodings project to support a lot of text encodings. But by default no encoding is loaded so only the default UTF-8 encoding is available. If you want to write strings in other encodings then you have to import the specific encodings or all encodings yourself:

    @@ -127,4 +127,4 @@ writer and also releases the lock on the stream writer. But closing the stream is still your own responsibility:

    import { writeDataToStream } from "@kayahr/datastream";

    const stream = new FileOutputStream(filename);
    try {
    await writeDataToStream(stream, async writer => {
    // Read stuff from data reader
    await writer.flush();
    });
    } finally {
    await stream.close();
    }
    -

Generated using TypeDoc

\ No newline at end of file +

Generated using TypeDoc

\ No newline at end of file diff --git a/interfaces/index.DataReaderOptions.html b/interfaces/index.DataReaderOptions.html index c057693..d5e0b41 100644 --- a/interfaces/index.DataReaderOptions.html +++ b/interfaces/index.DataReaderOptions.html @@ -1,6 +1,6 @@ -DataReaderOptions | @kayahr/datastream

Interface DataReaderOptions

Options for constructing a data reader.

-
interface DataReaderOptions {
    encoding?: string;
    endianness?: Endianness;
}

Properties

Properties

encoding?: string

The encoding used to read strings. Defaults to "utf-8".

-
endianness?: Endianness

The endianness to use for reading multi-byte values. Defaults to native endianness.

-

Generated using TypeDoc

\ No newline at end of file +DataReaderOptions | @kayahr/datastream

Interface DataReaderOptions

Options for constructing a data reader.

+
interface DataReaderOptions {
    encoding?: string;
    endianness?: Endianness;
}

Properties

Properties

encoding?: string

The encoding used to read strings. Defaults to "utf-8".

+
endianness?: Endianness

The endianness to use for reading multi-byte values. Defaults to native endianness.

+

Generated using TypeDoc

\ No newline at end of file diff --git a/interfaces/index.DataReaderSource.html b/interfaces/index.DataReaderSource.html index 33f28cf..184c3a1 100644 --- a/interfaces/index.DataReaderSource.html +++ b/interfaces/index.DataReaderSource.html @@ -1,5 +1,5 @@ -DataReaderSource | @kayahr/datastream

Interface DataReaderSource

Interface for a data reader source.

-
interface DataReaderSource {
    read(): ReadableStreamReadResult<Uint8Array> | Promise<ReadableStreamReadResult<Uint8Array>>;
}

Implemented by

Methods

Methods

  • Reads a chunk from the source.

    -

    Returns ReadableStreamReadResult<Uint8Array> | Promise<ReadableStreamReadResult<Uint8Array>>

    the read result.

    -

Generated using TypeDoc

\ No newline at end of file +DataReaderSource | @kayahr/datastream

Interface DataReaderSource

Interface for a data reader source.

+
interface DataReaderSource {
    read(): ReadableStreamReadResult<Uint8Array> | Promise<ReadableStreamReadResult<Uint8Array>>;
}

Implemented by

Methods

Methods

  • Reads a chunk from the source.

    +

    Returns ReadableStreamReadResult<Uint8Array> | Promise<ReadableStreamReadResult<Uint8Array>>

    the read result.

    +

Generated using TypeDoc

\ No newline at end of file diff --git a/interfaces/index.DataWriterOptions.html b/interfaces/index.DataWriterOptions.html index 9698f4e..6c6a636 100644 --- a/interfaces/index.DataWriterOptions.html +++ b/interfaces/index.DataWriterOptions.html @@ -1,8 +1,8 @@ -DataWriterOptions | @kayahr/datastream

Interface DataWriterOptions

Options for constructing a data writer.

-
interface DataWriterOptions {
    bufferSize?: number;
    encoding?: string;
    endianness?: Endianness;
}

Properties

bufferSize?: number

The buffer size. Defaults to 64KB.

-
encoding?: string

The encoding used to write strings. Defaults to "utf-8".

-
endianness?: Endianness

The endianness to use for writing multi-byte values. Defaults to native endianness.

-

Generated using TypeDoc

\ No newline at end of file +DataWriterOptions | @kayahr/datastream

Interface DataWriterOptions

Options for constructing a data writer.

+
interface DataWriterOptions {
    bufferSize?: number;
    encoding?: string;
    endianness?: Endianness;
}

Properties

bufferSize?: number

The buffer size. Defaults to 64KB.

+
encoding?: string

The encoding used to write strings. Defaults to "utf-8".

+
endianness?: Endianness

The endianness to use for writing multi-byte values. Defaults to native endianness.

+

Generated using TypeDoc

\ No newline at end of file diff --git a/interfaces/index.DataWriterSink.html b/interfaces/index.DataWriterSink.html index e8ce055..3b92c86 100644 --- a/interfaces/index.DataWriterSink.html +++ b/interfaces/index.DataWriterSink.html @@ -1,6 +1,6 @@ -DataWriterSink | @kayahr/datastream

Interface for a data writer sink.

-
interface DataWriterSink {
    write(chunk): void | Promise<void>;
}

Implemented by

Methods

Methods

  • Writes the given chunk to the sink.

    -

    Parameters

    • chunk: Uint8Array

      Chunk of data to write to the sink.

      -

    Returns void | Promise<void>

    a promise if write operation is asynchronous, nothing when write operation is synchronous.

    -

Generated using TypeDoc

\ No newline at end of file +DataWriterSink | @kayahr/datastream

Interface for a data writer sink.

+
interface DataWriterSink {
    write(chunk): void | Promise<void>;
}

Implemented by

Methods

Methods

  • Writes the given chunk to the sink.

    +

    Parameters

    • chunk: Uint8Array

      Chunk of data to write to the sink.

      +

    Returns void | Promise<void>

    a promise if write operation is asynchronous, nothing when write operation is synchronous.

    +

Generated using TypeDoc

\ No newline at end of file diff --git a/interfaces/index.ReadArrayOptions.html b/interfaces/index.ReadArrayOptions.html index ffea8a2..b151435 100644 --- a/interfaces/index.ReadArrayOptions.html +++ b/interfaces/index.ReadArrayOptions.html @@ -1,6 +1,6 @@ -ReadArrayOptions | @kayahr/datastream

Interface ReadArrayOptions

Options for the various read array methods of a data reader.

-
interface ReadArrayOptions {
    offset?: number;
    size?: number;
}

Hierarchy

Properties

Properties

offset?: number

Optional offset within the buffer to start writing to. Defaults to 0.

-
size?: number

Optional number of bytes to read. Defaults to buffer size minus offset.

-

Generated using TypeDoc

\ No newline at end of file +ReadArrayOptions | @kayahr/datastream

Interface ReadArrayOptions

Options for the various read array methods of a data reader.

+
interface ReadArrayOptions {
    offset?: number;
    size?: number;
}

Hierarchy (view full)

Properties

Properties

offset?: number

Optional offset within the buffer to start writing to. Defaults to 0.

+
size?: number

Optional number of bytes to read. Defaults to buffer size minus offset.

+

Generated using TypeDoc

\ No newline at end of file diff --git a/interfaces/index.ReadLineOptions.html b/interfaces/index.ReadLineOptions.html index b9841f7..0fb6cf8 100644 --- a/interfaces/index.ReadLineOptions.html +++ b/interfaces/index.ReadLineOptions.html @@ -1,11 +1,11 @@ -ReadLineOptions | @kayahr/datastream
interface ReadLineOptions {
    encoding?: string;
    includeEOL?: boolean;
    initialCapacity?: number;
    maxBytes?: number;
}

Hierarchy

Properties

encoding?: string

The text encoding. Defaults to encoding the reader was configured with.

-
includeEOL?: boolean

True to include EOL marker in returned line. Defaults to false.

-
initialCapacity?: number

The initial buffer capacity for creating the string bytes. The buffer size duplicates itself when full, so the +ReadLineOptions | @kayahr/datastream

interface ReadLineOptions {
    encoding?: string;
    includeEOL?: boolean;
    initialCapacity?: number;
    maxBytes?: number;
}

Hierarchy (view full)

Properties

encoding?: string

The text encoding. Defaults to encoding the reader was configured with.

+
includeEOL?: boolean

True to include EOL marker in returned line. Defaults to false.

+
initialCapacity?: number

The initial buffer capacity for creating the string bytes. The buffer size duplicates itself when full, so the higher this value is set the less buffer grows happen but the more memory is wasted for reading small lines. Defaults to 1024.

-
maxBytes?: number

The maximum number of bytes (not characters!) to read. Default is unlimited.

-

Generated using TypeDoc

\ No newline at end of file +
maxBytes?: number

The maximum number of bytes (not characters!) to read. Default is unlimited.

+

Generated using TypeDoc

\ No newline at end of file diff --git a/interfaces/index.ReadMultiByteArrayOptions.html b/interfaces/index.ReadMultiByteArrayOptions.html index a894a98..59bd884 100644 --- a/interfaces/index.ReadMultiByteArrayOptions.html +++ b/interfaces/index.ReadMultiByteArrayOptions.html @@ -1,8 +1,8 @@ -ReadMultiByteArrayOptions | @kayahr/datastream

Interface ReadMultiByteArrayOptions

Options for the various multi-byte read array methods of a data reader.

-
interface ReadMultiByteArrayOptions {
    endianness?: Endianness;
    offset?: number;
    size?: number;
}

Hierarchy

Properties

Properties

endianness?: Endianness

Optional endianness. Defaults to endianness the reader was configured with.

-
offset?: number

Optional offset within the buffer to start writing to. Defaults to 0.

-
size?: number

Optional number of bytes to read. Defaults to buffer size minus offset.

-

Generated using TypeDoc

\ No newline at end of file +ReadMultiByteArrayOptions | @kayahr/datastream

Interface ReadMultiByteArrayOptions

Options for the various multi-byte read array methods of a data reader.

+
interface ReadMultiByteArrayOptions {
    endianness?: Endianness;
    offset?: number;
    size?: number;
}

Hierarchy (view full)

Properties

Properties

endianness?: Endianness

Optional endianness. Defaults to endianness the reader was configured with.

+
offset?: number

Optional offset within the buffer to start writing to. Defaults to 0.

+
size?: number

Optional number of bytes to read. Defaults to buffer size minus offset.

+

Generated using TypeDoc

\ No newline at end of file diff --git a/interfaces/index.ReadStringOptions.html b/interfaces/index.ReadStringOptions.html index 7a0ee91..a8683f3 100644 --- a/interfaces/index.ReadStringOptions.html +++ b/interfaces/index.ReadStringOptions.html @@ -1,9 +1,9 @@ -ReadStringOptions | @kayahr/datastream

Interface ReadStringOptions

interface ReadStringOptions {
    encoding?: string;
    initialCapacity?: number;
    maxBytes?: number;
}

Hierarchy

Properties

encoding?: string

The text encoding. Defaults to encoding the reader was configured with.

-
initialCapacity?: number

The initial buffer capacity for creating the string bytes. The buffer size duplicates itself when full, so the +ReadStringOptions | @kayahr/datastream

Interface ReadStringOptions

interface ReadStringOptions {
    encoding?: string;
    initialCapacity?: number;
    maxBytes?: number;
}

Hierarchy (view full)

Properties

encoding?: string

The text encoding. Defaults to encoding the reader was configured with.

+
initialCapacity?: number

The initial buffer capacity for creating the string bytes. The buffer size duplicates itself when full, so the higher this value is set the less buffer grows happen but the more memory is wasted for reading small lines. Defaults to 1024.

-
maxBytes?: number

The maximum number of bytes (not characters!) to read. Default is unlimited.

-

Generated using TypeDoc

\ No newline at end of file +
maxBytes?: number

The maximum number of bytes (not characters!) to read. Default is unlimited.

+

Generated using TypeDoc

\ No newline at end of file diff --git a/modules/index.html b/modules/index.html index e6b38c3..875e514 100644 --- a/modules/index.html +++ b/modules/index.html @@ -1,20 +1,20 @@ -index | @kayahr/datastream

Generated using TypeDoc

\ No newline at end of file +index | @kayahr/datastream

Generated using TypeDoc

\ No newline at end of file diff --git a/modules/node.html b/modules/node.html index 99ab667..e57ba92 100644 --- a/modules/node.html +++ b/modules/node.html @@ -1,3 +1,3 @@ -node | @kayahr/datastream

Generated using TypeDoc

\ No newline at end of file +node | @kayahr/datastream

Generated using TypeDoc

\ No newline at end of file