UNPKG

1.46 MBJavaScriptView Raw
1var solid="object"==typeof solid?solid:{};solid.data=function(e){var t={};function r(n){if(t[n])return t[n].exports;var i=t[n]={i:n,l:!1,exports:{}};return e[n].call(i.exports,i,i.exports,r),i.l=!0,i.exports}return r.m=e,r.c=t,r.d=function(e,t,n){r.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:n})},r.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.t=function(e,t){if(1&t&&(e=r(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var n=Object.create(null);if(r.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var i in e)r.d(n,i,function(t){return e[t]}.bind(null,i));return n},r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,"a",t),t},r.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r.p="",r(r.s=706)}([function(e,t,r){"use strict";(function(e){function n(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}Object.defineProperty(t,"__esModule",{value:!0}),e&&e.env.COMUNICA_DEBUG||(Error.stackTraceLimit=!1),n(r(138)),n(r(318)),n(r(319)),n(r(320)),n(r(139)),n(r(321))}).call(this,r(13))},function(e,t){"function"==typeof Object.create?e.exports=function(e,t){t&&(e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}))}:e.exports=function(e,t){if(t){e.super_=t;var r=function(){};r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e}}},function(e,t,r){var n=r(7),i=n.Buffer;function a(e,t){for(var r in e)t[r]=e[r]}function o(e,t,r){return i(e,t,r)}i.from&&i.alloc&&i.allocUnsafe&&i.allocUnsafeSlow?e.exports=n:(a(n,t),t.Buffer=o),o.prototype=Object.create(i.prototype),a(i,o),o.from=function(e,t,r){if("number"==typeof e)throw new TypeError("Argument must not be a number");return i(e,t,r)},o.alloc=function(e,t,r){if("number"!=typeof e)throw new TypeError("Argument must be a number");var n=i(e);return void 0!==t?"string"==typeof r?n.fill(t,r):n.fill(t):n.fill(0),n},o.allocUnsafe=function(e){if("number"!=typeof e)throw new TypeError("Argument must be a number");return i(e)},o.allocUnsafeSlow=function(e){if("number"!=typeof e)throw new TypeError("Argument must be a number");return n.SlowBuffer(e)}},function(e,t,r){e.exports=i;var n=r(31).EventEmitter;function i(){n.call(this)}r(1)(i,n),i.Readable=r(89),i.Writable=r(336),i.Duplex=r(337),i.Transform=r(338),i.PassThrough=r(339),i.Stream=i,i.prototype.pipe=function(e,t){var r=this;function i(t){e.writable&&!1===e.write(t)&&r.pause&&r.pause()}function a(){r.readable&&r.resume&&r.resume()}r.on("data",i),e.on("drain",a),e._isStdio||t&&!1===t.end||(r.on("end",s),r.on("close",c));var o=!1;function s(){o||(o=!0,e.end())}function c(){o||(o=!0,"function"==typeof e.destroy&&e.destroy())}function u(e){if(l(),0===n.listenerCount(this,"error"))throw e}function l(){r.removeListener("data",i),e.removeListener("drain",a),r.removeListener("end",s),r.removeListener("close",c),r.removeListener("error",u),e.removeListener("error",u),r.removeListener("end",l),r.removeListener("close",l),e.removeListener("close",l)}return r.on("error",u),e.on("error",u),r.on("end",l),r.on("close",l),e.on("close",l),e.emit("pipe",r),e}},function(e,t,r){"use strict";function n(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}Object.defineProperty(t,"__esModule",{value:!0}),n(r(215)),n(r(216)),n(r(494)),n(r(495))},function(e,t,r){var n=r(302);e.exports=n},function(e,t,r){(function(t){var n=r(31).EventEmitter,i=c.STATES=["INIT","OPEN","CLOSING","CLOSED","ENDED","DESTROYED"],a=0,o=1,s=4;function c(){if(!(this instanceof c))return new c;n.call(this),this.on("newListener",d),this._state=o,this._readable=!1}function u(e,t){e.emit(t)}function l(e,t){e._end(t)}function f(e){t(l,e)}function d(e){"data"===e&&(this.removeListener("newListener",d),this._addSingleListener("readable",h),this.readable&&t(p,h,this))}function h(){for(var e;this._hasListeners("data")&&null!==(e=this.read());)this.emit("data",e);this._hasListeners("data")||this.done||(this.removeListener("readable",h),this._addSingleListener("newListener",d))}function p(e,t){e.call(t)}function y(e,t,r){e.getProperty(r,function(e){t.setProperty(r,e)})}function m(){if(!(this instanceof m))return new m;c.call(this),this._changeState(s,!0)}function g(e){if(!(this instanceof g))return new g(e);c.call(this),this._item=e,null===e?this.close():this.readable=!0}function b(e){return this instanceof b?(c.call(this),e&&e.length>0?(this._buffer=Array.prototype.slice.call(e),void(this.readable=!0)):this.close()):new b(e)}function v(e){if(!(this instanceof v))return new v(e);c.call(this);var t,r=(e=e||{}).step,n=e.end,i=e.start;this._step=r=isFinite(r)?~~r:1,t=r>=0?1/0:-1/0,this._last=n=isFinite(n)?~~n:n===-t?n:t,this._next=i="number"!=typeof i?0:isFinite(i)?~~i:i,!isFinite(i)||(r>=0?i>n:i<n)?this.close():this.readable=!0}function _(e){if(!(this instanceof _))return new _(e);c.call(this);var r=(e=e||{}).maxBufferSize,n=e.autoStart;this._state=a,this._buffer=[],this._pushedCount=0,this.maxBufferSize=r,this._reading=!0,t(w,this,!1!==n||n)}function w(e,t){e._init(t)}function S(e){e._reading||(e._reading=!0,t(E,e))}function E(e){e._reading=!1,e._fillBuffer()}function x(e,t){if(!(this instanceof x))return new x(e,t);e&&L(e.read)||(t||(t=e),e=t&&t.source),_.call(this,t),e&&(this.source=e),this._optional=!(!t||!t.optional),this._destroySource=!t||!1!==t.destroySource}function T(){return this._source}function O(e){this._destination.emit("error",e)}function A(){this._destination._closeWhenDone()}function I(){this._destination._fillBuffer()}function N(e,t,r){var n,i=e._source;i&&!i.ended&&null!==(n=i.read())?e._optional?R(e,n,t):e._transform(n,t):r()}function R(e,t,r){var n=e._pushedCount;e._transform(t,function(){n===e._pushedCount&&e._push(t),r()})}function k(e,t){if(!(this instanceof k))return new k(e,t);if(x.call(this,e,t),t=t||!L(e&&e.read)&&e){var r=t.limit,n=t.offset,i=t.filter,a=t.map,o=L(t)?t:t.transform,s=t.prepend,c=t.append;n===1/0||r===-1/0?this._limit=0:(isFinite(n)&&(this._offset=Math.max(~~n,0)),isFinite(r)&&(this._limit=Math.max(~~r,0)),L(i)&&(this._filter=i),L(a)&&(this._map=a),L(o)&&(this._transform=o)),s&&(this._prepender=s.on?s:new b(s)),c&&(this._appender=c.on?c:new b(c))}}function P(e,t,r,n){var i,a=e._source;if(a&&!a.ended){for(0===e._limit&&e.close();!e.closed&&e._pushedCount<t&&null!==(i=a.read());)if(e._filter(i)&&(0===e._offset||!e._offset--)){var o=null===e._map?i:e._map(i);if(null===o)e._optional&&e._push(i);else{if(null!==e._transform)return void(e._optional?R(e,o,r):e._transform(o,r));e._push(o)}0==--e._limit&&e.close()}n()}else n()}function j(e,t){if(!(this instanceof j))return new j(e,t);x.call(this,e,t),this._transformerQueue=[]}function D(e){if(!(this instanceof D))return new D(e);c.call(this),this._readPosition=0,e&&(this.source=e)}function C(e,t,r,n){t.getProperty(r,function(t){e._properties&&r in e._properties||n(t)})}function M(e){var t,r=[];if(this.readAt=function(t){var n=null;return t<r.length?n=r[t]:e.ended||null===(n=e.read())||(r[t]=n),n},this.endsAt=function(t){return t===r.length&&e.ended},this.register=function(e){t&&t.push(e)},this.unregister=function(e){var r;t&&(r=t.indexOf(e))>=0&&t.splice(r,1)},!e.ended){function n(){for(var e=0;e<t.length;e++)t[e].readable=!0}function i(e){for(var r=0;r<t.length;r++)t[r].emit("error",e)}t=[],e.on("readable",n),e.on("end",function a(){for(var o=0;o<t.length;o++)t[o]._readPosition===r.length&&t[o].close();t=null;e.removeListener("end",a);e.removeListener("error",i);e.removeListener("readable",n)}),e.on("error",i)}}function L(e){return"function"==typeof e}i.forEach(function(e,t){c[e]=t}),function e(t){t.prototype=Object.create(this.prototype,{constructor:{value:t,configurable:!0,writable:!0}}),t.subclass=e}.call(n,c),c.prototype._changeState=function(e,r){var n=e>this._state&&this._state<s;return n&&(this._state=e,e===s&&(r?t(u,this,"end"):this.emit("end"))),n},c.prototype.read=function(){return null},c.prototype.each=function(e,t){this.on("data",t?e.bind(t):e)},c.prototype._hasListeners=function(e){return this._events&&e in this._events},c.prototype._addSingleListener=function(e,t){var r=this._events&&this._events[e];r&&!(L(r)?r!==t:r.indexOf(t)<0)||this.on(e,t)},c.prototype.close=function(){this._changeState(3)&&f(this)},c.prototype.destroy=function(e){if(!this.done){var t=this;this._destroy(e,function(r){(e=e||r)&&t.emit("error",e),l(t,!0)})}},c.prototype._destroy=function(e,t){t()},c.prototype._end=function(e){this._changeState(e?5:s)&&(this._readable=!1,this.removeAllListeners("readable"),this.removeAllListeners("data"),this.removeAllListeners("end"))},Object.defineProperty(c.prototype,"readable",{get:function(){return this._readable},set:function(e){e=!!e&&!this.done,this._readable!==e&&(this._readable=e,e&&t(u,this,"readable"))},enumerable:!0}),Object.defineProperty(c.prototype,"closed",{get:function(){return this._state>=2},enumerable:!0}),Object.defineProperty(c.prototype,"ended",{get:function(){return this._state===s},enumerable:!0}),Object.defineProperty(c.prototype,"destroyed",{get:function(){return 5===this._state},enumerable:!0}),Object.defineProperty(c.prototype,"done",{get:function(){return this._state>=s},enumerable:!0}),c.prototype.getProperty=function(e,r){var n,i=this._properties;if(!r)return i&&i[e];i&&e in i?t(r,i[e]):((n=this._propertyCallbacks)||(this._propertyCallbacks=n=Object.create(null)),e in n?n[e].push(r):n[e]=[r])},c.prototype.setProperty=function(e,r){(this._properties||(this._properties=Object.create(null)))[e]=r;var n,i=this._propertyCallbacks;if(n=i&&i[e]){for(e in delete i[e],1===n.length?t(n[0],r):t(function(){for(var e=0;e<n.length;e++)n[e](r)}),i)return;delete this._propertyCallbacks}},c.prototype.getProperties=function(){var e=this._properties,t={};for(var r in e)t[r]=e[r];return t},c.prototype.setProperties=function(e){for(var t in e)this.setProperty(t,e[t])},c.prototype.copyProperties=function(e,t){for(var r=0;r<t.length;r++)y(e,this,t[r])},c.prototype.toString=function(){var e=this._toStringDetails();return"["+this.constructor.name+(e?" "+e+"]":"]")},c.prototype._toStringDetails=function(){},c.subclass(m),c.subclass(g),g.prototype.read=function(){var e=this._item;return this._item=null,this.close(),e},g.prototype._toStringDetails=function(){return null===this._item?"":"("+this._item+")"},c.subclass(b),b.prototype.read=function(){var e=this._buffer,t=null;return e&&(t=e.shift(),e.length||(delete this._buffer,this.close())),t},b.prototype._toStringDetails=function(){return"("+(this._buffer&&this._buffer.length||0)+")"},b.prototype._destroy=function(e,t){delete this._buffer,t()},c.subclass(v),v.prototype.read=function(){if(this.closed)return null;var e=this._next,t=this._step,r=this._last,n=this._next+=t;return(t>=0?n>r:n<r)&&this.close(),e},v.prototype._toStringDetails=function(){return"("+this._next+"..."+this._last+")"},c.range=function(e,t,r){return new v({start:e,end:t,step:r})},c.subclass(_),Object.defineProperty(_.prototype,"maxBufferSize",{set:function(e){e!==1/0&&(e=isFinite(e)?Math.max(~~e,1):4),this._maxBufferSize!==e&&(this._maxBufferSize=e,this._state===o&&this._fillBuffer())},get:function(){return this._maxBufferSize},enumerable:!0}),_.prototype._init=function(e){var t=this;this._reading=!0,this._begin(function(){if(!t)throw new Error("done callback called multiple times");t._reading=!1,t._changeState(o),e?S(t):t.readable=!0,t=null})},_.prototype._begin=function(e){e()},_.prototype.read=function(){if(this.done)return null;var e,t=this._buffer;return t.length?e=t.shift():(e=null,this.readable=!1),!this._reading&&t.length<this._maxBufferSize&&(this.closed?t.length||f(this):S(this)),e},_.prototype._read=function(e,t){t()},_.prototype._push=function(e){this.done||(this._pushedCount++,this._buffer.push(e),this.readable=!0)},_.prototype._fillBuffer=function(){var e,t=this;this._reading||(this.closed?this._completeClose():(e=Math.min(this._maxBufferSize-this._buffer.length,128))>0&&(this._pushedCount=0,this._reading=!0,this._read(e,function(){if(!e)throw new Error("done callback called multiple times");e=0,t._reading=!1,t.closed?t._completeClose():t._pushedCount&&(t.readable=!0,t._buffer.length<t._maxBufferSize/2&&S(t))})))},_.prototype.close=function(){this._reading?this._changeState(2):this._completeClose()},_.prototype._completeClose=function(){if(this._changeState(3)){var e=this;this._reading=!0,this._flush(function(){if(!e._reading)throw new Error("done callback called multiple times");e._reading=!1,e._buffer.length||f(e)})}},_.prototype._destroy=function(e,t){this._buffer=[],t()},_.prototype._flush=function(e){e()},_.prototype._toStringDetails=function(){var e=this._buffer,t=e.length;return"{"+(t?"next: "+e[0]+", ":"")+"buffer: "+t+"}"},_.subclass(x),Object.defineProperty(x.prototype,"source",{set:function(e){this._validateSource(e),this._source=e,e._destination=this,e.ended?this.close():(e.on("end",A),e.on("readable",I),e.on("error",O))},get:T,enumerable:!0}),x.prototype._validateSource=function(e,t){if(this._source)throw new Error("The source cannot be changed after it has been set");if(!e||!L(e.read)||!L(e.on))throw new Error("Invalid source: "+e);if(!t&&e._destination)throw new Error("The source already has a destination")},x.prototype._read=function(e,r){var n=this;N(n,function i(){n._pushedCount<e&&!n.closed?t(N,n,i,r):r()},r)},x.prototype._transform=function(e,t){this._push(e),t()},x.prototype._closeWhenDone=function(){this.close()},x.prototype._end=function(e){var t=this._source;t&&(t.removeListener("end",A),t.removeListener("error",O),t.removeListener("readable",I),delete t._destination,this._destroySource&&t.destroy()),_.prototype._end.call(this,e)},c.wrap=x,x.subclass(k),k.prototype._offset=0,k.prototype._limit=1/0,k.prototype._filter=function(){return!0},k.prototype._map=null,k.prototype._transform=null,k.prototype._read=function(e,r){var n=this;P(n,e,function i(){t(P,n,e,i,r)},r)},k.prototype._begin=function(e){this._insert(this._prepender,e),delete this._prepender},k.prototype._flush=function(e){this._insert(this._appender,e),delete this._appender},k.prototype._insert=function(e,t){var r=this;function n(e){r._push(e)}!e||e.ended?t():(e.on("data",n),e.on("end",function r(){e.removeListener("data",n);e.removeListener("end",r);t()}))},c.prototype.transform=function(e){return new k(this,e)},c.prototype.map=function(e,t){return this.transform({map:t?e.bind(t):e})},c.prototype.filter=function(e,t){return this.transform({filter:t?e.bind(t):e})},c.prototype.prepend=function(e){return this.transform({prepend:e})},c.prototype.append=function(e){return this.transform({append:e})},c.prototype.surround=function(e,t){return this.transform({prepend:e,append:t})},c.prototype.skip=function(e){return this.transform({offset:e})},c.prototype.take=function(e){return this.transform({limit:e})},c.prototype.range=function(e,t){return this.transform({offset:e,limit:Math.max(t-e+1,0)})},x.subclass(j),j.prototype._read=function(e,t){for(var r,n,i,a=this._transformerQueue,o=this._source,s=this._optional;(n=a[0])&&n.transformer.ended;)s&&null!==n.item&&(this._push(n.item),e--),(i=(n=a.shift()).transformer).removeListener("end",I),i.removeListener("readable",I),i.removeListener("error",O);for(;o&&!o.ended&&a.length<this._maxBufferSize&&null!==(r=this._source.read());)(i=this._createTransformer(r)||new m)._destination=this,i.on("end",I),i.on("readable",I),i.on("error",O),a.push({transformer:i,item:r});if(n=a[0])for(i=n.transformer;e-- >0&&null!==(r=i.read());)this._push(r),s&&(n.item=null);else o&&o.ended&&this.close();t()},j.prototype._createTransformer=g,j.prototype._closeWhenDone=function(){this._transformerQueue.length||this.close()},x.subclass(D),Object.defineProperty(D.prototype,"source",{set:function(e){var t=e&&e._destination;this._validateSource(e,!t||t instanceof M),this._source=e,t||(t=e._destination=new M(e)),t.endsAt(0)?this.close():(t.register(this),null!==t.readAt(0)&&(this.readable=!0));var r=this._propertyCallbacks;for(var n in r)for(var i=r[n],a=0;a<i.length;a++)C(this,e,n,i[a])},get:T,enumerable:!0}),D.prototype.getProperty=function(e,t){var r=this._properties,n=this._source,i=r&&e in r;if(!t)return i?r[e]:n&&n.getProperty(e);c.prototype.getProperty.call(this,e,t),n&&!i&&C(this,n,e,t)},D.prototype.getProperties=function(){var e=this._source?this._source.getProperties():{},t=this._properties;for(var r in t)e[r]=t[r];return e},D.prototype._toStringDetails=function(){var e=this._source;return"{source: "+(e?e.toString():"none")+"}"},D.prototype.read=function(){var e=this._source,t=null;if(!this.done&&e){var r=e._destination;null!==(t=r.readAt(this._readPosition))?this._readPosition++:this.readable=!1,r.endsAt(this._readPosition)&&this.close()}return t},D.prototype._end=function(e){var t=this._source&&this._source._destination;t&&t.unregister(this),_.prototype._end.call(this,e)},D.prototype.close=c.prototype.close,c.prototype.clone=function(){return new D(this)},e.exports=c,c.AsyncIterator=c,c.EmptyIterator=c.empty=m,c.SingletonIterator=c.single=g,c.ArrayIterator=c.fromArray=b,c.IntegerIterator=v,c.BufferedIterator=_,c.TransformIterator=x,c.SimpleTransformIterator=k,c.MultiTransformIterator=j,c.ClonedIterator=D}).call(this,r(15).setImmediate)},function(e,t,r){"use strict";(function(e){
2/*!
3 * The buffer module from node.js, for the browser.
4 *
5 * @author Feross Aboukhadijeh <feross@feross.org> <http://feross.org>
6 * @license MIT
7 */
8var n=r(328),i=r(329),a=r(141);function o(){return c.TYPED_ARRAY_SUPPORT?2147483647:1073741823}function s(e,t){if(o()<t)throw new RangeError("Invalid typed array length");return c.TYPED_ARRAY_SUPPORT?(e=new Uint8Array(t)).__proto__=c.prototype:(null===e&&(e=new c(t)),e.length=t),e}function c(e,t,r){if(!(c.TYPED_ARRAY_SUPPORT||this instanceof c))return new c(e,t,r);if("number"==typeof e){if("string"==typeof t)throw new Error("If encoding is specified then the first argument must be a string");return f(this,e)}return u(this,e,t,r)}function u(e,t,r,n){if("number"==typeof t)throw new TypeError('"value" argument must not be a number');return"undefined"!=typeof ArrayBuffer&&t instanceof ArrayBuffer?function(e,t,r,n){if(t.byteLength,r<0||t.byteLength<r)throw new RangeError("'offset' is out of bounds");if(t.byteLength<r+(n||0))throw new RangeError("'length' is out of bounds");t=void 0===r&&void 0===n?new Uint8Array(t):void 0===n?new Uint8Array(t,r):new Uint8Array(t,r,n);c.TYPED_ARRAY_SUPPORT?(e=t).__proto__=c.prototype:e=d(e,t);return e}(e,t,r,n):"string"==typeof t?function(e,t,r){"string"==typeof r&&""!==r||(r="utf8");if(!c.isEncoding(r))throw new TypeError('"encoding" must be a valid string encoding');var n=0|p(t,r),i=(e=s(e,n)).write(t,r);i!==n&&(e=e.slice(0,i));return e}(e,t,r):function(e,t){if(c.isBuffer(t)){var r=0|h(t.length);return 0===(e=s(e,r)).length?e:(t.copy(e,0,0,r),e)}if(t){if("undefined"!=typeof ArrayBuffer&&t.buffer instanceof ArrayBuffer||"length"in t)return"number"!=typeof t.length||(n=t.length)!=n?s(e,0):d(e,t);if("Buffer"===t.type&&a(t.data))return d(e,t.data)}var n;throw new TypeError("First argument must be a string, Buffer, ArrayBuffer, Array, or array-like object.")}(e,t)}function l(e){if("number"!=typeof e)throw new TypeError('"size" argument must be a number');if(e<0)throw new RangeError('"size" argument must not be negative')}function f(e,t){if(l(t),e=s(e,t<0?0:0|h(t)),!c.TYPED_ARRAY_SUPPORT)for(var r=0;r<t;++r)e[r]=0;return e}function d(e,t){var r=t.length<0?0:0|h(t.length);e=s(e,r);for(var n=0;n<r;n+=1)e[n]=255&t[n];return e}function h(e){if(e>=o())throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+o().toString(16)+" bytes");return 0|e}function p(e,t){if(c.isBuffer(e))return e.length;if("undefined"!=typeof ArrayBuffer&&"function"==typeof ArrayBuffer.isView&&(ArrayBuffer.isView(e)||e instanceof ArrayBuffer))return e.byteLength;"string"!=typeof e&&(e=""+e);var r=e.length;if(0===r)return 0;for(var n=!1;;)switch(t){case"ascii":case"latin1":case"binary":return r;case"utf8":case"utf-8":case void 0:return U(e).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*r;case"hex":return r>>>1;case"base64":return V(e).length;default:if(n)return U(e).length;t=(""+t).toLowerCase(),n=!0}}function y(e,t,r){var n=!1;if((void 0===t||t<0)&&(t=0),t>this.length)return"";if((void 0===r||r>this.length)&&(r=this.length),r<=0)return"";if((r>>>=0)<=(t>>>=0))return"";for(e||(e="utf8");;)switch(e){case"hex":return R(this,t,r);case"utf8":case"utf-8":return O(this,t,r);case"ascii":return I(this,t,r);case"latin1":case"binary":return N(this,t,r);case"base64":return T(this,t,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return k(this,t,r);default:if(n)throw new TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase(),n=!0}}function m(e,t,r){var n=e[t];e[t]=e[r],e[r]=n}function g(e,t,r,n,i){if(0===e.length)return-1;if("string"==typeof r?(n=r,r=0):r>2147483647?r=2147483647:r<-2147483648&&(r=-2147483648),r=+r,isNaN(r)&&(r=i?0:e.length-1),r<0&&(r=e.length+r),r>=e.length){if(i)return-1;r=e.length-1}else if(r<0){if(!i)return-1;r=0}if("string"==typeof t&&(t=c.from(t,n)),c.isBuffer(t))return 0===t.length?-1:b(e,t,r,n,i);if("number"==typeof t)return t&=255,c.TYPED_ARRAY_SUPPORT&&"function"==typeof Uint8Array.prototype.indexOf?i?Uint8Array.prototype.indexOf.call(e,t,r):Uint8Array.prototype.lastIndexOf.call(e,t,r):b(e,[t],r,n,i);throw new TypeError("val must be string, number or Buffer")}function b(e,t,r,n,i){var a,o=1,s=e.length,c=t.length;if(void 0!==n&&("ucs2"===(n=String(n).toLowerCase())||"ucs-2"===n||"utf16le"===n||"utf-16le"===n)){if(e.length<2||t.length<2)return-1;o=2,s/=2,c/=2,r/=2}function u(e,t){return 1===o?e[t]:e.readUInt16BE(t*o)}if(i){var l=-1;for(a=r;a<s;a++)if(u(e,a)===u(t,-1===l?0:a-l)){if(-1===l&&(l=a),a-l+1===c)return l*o}else-1!==l&&(a-=a-l),l=-1}else for(r+c>s&&(r=s-c),a=r;a>=0;a--){for(var f=!0,d=0;d<c;d++)if(u(e,a+d)!==u(t,d)){f=!1;break}if(f)return a}return-1}function v(e,t,r,n){r=Number(r)||0;var i=e.length-r;n?(n=Number(n))>i&&(n=i):n=i;var a=t.length;if(a%2!=0)throw new TypeError("Invalid hex string");n>a/2&&(n=a/2);for(var o=0;o<n;++o){var s=parseInt(t.substr(2*o,2),16);if(isNaN(s))return o;e[r+o]=s}return o}function _(e,t,r,n){return H(U(t,e.length-r),e,r,n)}function w(e,t,r,n){return H(function(e){for(var t=[],r=0;r<e.length;++r)t.push(255&e.charCodeAt(r));return t}(t),e,r,n)}function S(e,t,r,n){return w(e,t,r,n)}function E(e,t,r,n){return H(V(t),e,r,n)}function x(e,t,r,n){return H(function(e,t){for(var r,n,i,a=[],o=0;o<e.length&&!((t-=2)<0);++o)r=e.charCodeAt(o),n=r>>8,i=r%256,a.push(i),a.push(n);return a}(t,e.length-r),e,r,n)}function T(e,t,r){return 0===t&&r===e.length?n.fromByteArray(e):n.fromByteArray(e.slice(t,r))}function O(e,t,r){r=Math.min(e.length,r);for(var n=[],i=t;i<r;){var a,o,s,c,u=e[i],l=null,f=u>239?4:u>223?3:u>191?2:1;if(i+f<=r)switch(f){case 1:u<128&&(l=u);break;case 2:128==(192&(a=e[i+1]))&&(c=(31&u)<<6|63&a)>127&&(l=c);break;case 3:a=e[i+1],o=e[i+2],128==(192&a)&&128==(192&o)&&(c=(15&u)<<12|(63&a)<<6|63&o)>2047&&(c<55296||c>57343)&&(l=c);break;case 4:a=e[i+1],o=e[i+2],s=e[i+3],128==(192&a)&&128==(192&o)&&128==(192&s)&&(c=(15&u)<<18|(63&a)<<12|(63&o)<<6|63&s)>65535&&c<1114112&&(l=c)}null===l?(l=65533,f=1):l>65535&&(l-=65536,n.push(l>>>10&1023|55296),l=56320|1023&l),n.push(l),i+=f}return function(e){var t=e.length;if(t<=A)return String.fromCharCode.apply(String,e);var r="",n=0;for(;n<t;)r+=String.fromCharCode.apply(String,e.slice(n,n+=A));return r}(n)}t.Buffer=c,t.SlowBuffer=function(e){+e!=e&&(e=0);return c.alloc(+e)},t.INSPECT_MAX_BYTES=50,c.TYPED_ARRAY_SUPPORT=void 0!==e.TYPED_ARRAY_SUPPORT?e.TYPED_ARRAY_SUPPORT:function(){try{var e=new Uint8Array(1);return e.__proto__={__proto__:Uint8Array.prototype,foo:function(){return 42}},42===e.foo()&&"function"==typeof e.subarray&&0===e.subarray(1,1).byteLength}catch(e){return!1}}(),t.kMaxLength=o(),c.poolSize=8192,c._augment=function(e){return e.__proto__=c.prototype,e},c.from=function(e,t,r){return u(null,e,t,r)},c.TYPED_ARRAY_SUPPORT&&(c.prototype.__proto__=Uint8Array.prototype,c.__proto__=Uint8Array,"undefined"!=typeof Symbol&&Symbol.species&&c[Symbol.species]===c&&Object.defineProperty(c,Symbol.species,{value:null,configurable:!0})),c.alloc=function(e,t,r){return function(e,t,r,n){return l(t),t<=0?s(e,t):void 0!==r?"string"==typeof n?s(e,t).fill(r,n):s(e,t).fill(r):s(e,t)}(null,e,t,r)},c.allocUnsafe=function(e){return f(null,e)},c.allocUnsafeSlow=function(e){return f(null,e)},c.isBuffer=function(e){return!(null==e||!e._isBuffer)},c.compare=function(e,t){if(!c.isBuffer(e)||!c.isBuffer(t))throw new TypeError("Arguments must be Buffers");if(e===t)return 0;for(var r=e.length,n=t.length,i=0,a=Math.min(r,n);i<a;++i)if(e[i]!==t[i]){r=e[i],n=t[i];break}return r<n?-1:n<r?1:0},c.isEncoding=function(e){switch(String(e).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}},c.concat=function(e,t){if(!a(e))throw new TypeError('"list" argument must be an Array of Buffers');if(0===e.length)return c.alloc(0);var r;if(void 0===t)for(t=0,r=0;r<e.length;++r)t+=e[r].length;var n=c.allocUnsafe(t),i=0;for(r=0;r<e.length;++r){var o=e[r];if(!c.isBuffer(o))throw new TypeError('"list" argument must be an Array of Buffers');o.copy(n,i),i+=o.length}return n},c.byteLength=p,c.prototype._isBuffer=!0,c.prototype.swap16=function(){var e=this.length;if(e%2!=0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(var t=0;t<e;t+=2)m(this,t,t+1);return this},c.prototype.swap32=function(){var e=this.length;if(e%4!=0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(var t=0;t<e;t+=4)m(this,t,t+3),m(this,t+1,t+2);return this},c.prototype.swap64=function(){var e=this.length;if(e%8!=0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(var t=0;t<e;t+=8)m(this,t,t+7),m(this,t+1,t+6),m(this,t+2,t+5),m(this,t+3,t+4);return this},c.prototype.toString=function(){var e=0|this.length;return 0===e?"":0===arguments.length?O(this,0,e):y.apply(this,arguments)},c.prototype.equals=function(e){if(!c.isBuffer(e))throw new TypeError("Argument must be a Buffer");return this===e||0===c.compare(this,e)},c.prototype.inspect=function(){var e="",r=t.INSPECT_MAX_BYTES;return this.length>0&&(e=this.toString("hex",0,r).match(/.{2}/g).join(" "),this.length>r&&(e+=" ... ")),"<Buffer "+e+">"},c.prototype.compare=function(e,t,r,n,i){if(!c.isBuffer(e))throw new TypeError("Argument must be a Buffer");if(void 0===t&&(t=0),void 0===r&&(r=e?e.length:0),void 0===n&&(n=0),void 0===i&&(i=this.length),t<0||r>e.length||n<0||i>this.length)throw new RangeError("out of range index");if(n>=i&&t>=r)return 0;if(n>=i)return-1;if(t>=r)return 1;if(this===e)return 0;for(var a=(i>>>=0)-(n>>>=0),o=(r>>>=0)-(t>>>=0),s=Math.min(a,o),u=this.slice(n,i),l=e.slice(t,r),f=0;f<s;++f)if(u[f]!==l[f]){a=u[f],o=l[f];break}return a<o?-1:o<a?1:0},c.prototype.includes=function(e,t,r){return-1!==this.indexOf(e,t,r)},c.prototype.indexOf=function(e,t,r){return g(this,e,t,r,!0)},c.prototype.lastIndexOf=function(e,t,r){return g(this,e,t,r,!1)},c.prototype.write=function(e,t,r,n){if(void 0===t)n="utf8",r=this.length,t=0;else if(void 0===r&&"string"==typeof t)n=t,r=this.length,t=0;else{if(!isFinite(t))throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");t|=0,isFinite(r)?(r|=0,void 0===n&&(n="utf8")):(n=r,r=void 0)}var i=this.length-t;if((void 0===r||r>i)&&(r=i),e.length>0&&(r<0||t<0)||t>this.length)throw new RangeError("Attempt to write outside buffer bounds");n||(n="utf8");for(var a=!1;;)switch(n){case"hex":return v(this,e,t,r);case"utf8":case"utf-8":return _(this,e,t,r);case"ascii":return w(this,e,t,r);case"latin1":case"binary":return S(this,e,t,r);case"base64":return E(this,e,t,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return x(this,e,t,r);default:if(a)throw new TypeError("Unknown encoding: "+n);n=(""+n).toLowerCase(),a=!0}},c.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};var A=4096;function I(e,t,r){var n="";r=Math.min(e.length,r);for(var i=t;i<r;++i)n+=String.fromCharCode(127&e[i]);return n}function N(e,t,r){var n="";r=Math.min(e.length,r);for(var i=t;i<r;++i)n+=String.fromCharCode(e[i]);return n}function R(e,t,r){var n=e.length;(!t||t<0)&&(t=0),(!r||r<0||r>n)&&(r=n);for(var i="",a=t;a<r;++a)i+=B(e[a]);return i}function k(e,t,r){for(var n=e.slice(t,r),i="",a=0;a<n.length;a+=2)i+=String.fromCharCode(n[a]+256*n[a+1]);return i}function P(e,t,r){if(e%1!=0||e<0)throw new RangeError("offset is not uint");if(e+t>r)throw new RangeError("Trying to access beyond buffer length")}function j(e,t,r,n,i,a){if(!c.isBuffer(e))throw new TypeError('"buffer" argument must be a Buffer instance');if(t>i||t<a)throw new RangeError('"value" argument is out of bounds');if(r+n>e.length)throw new RangeError("Index out of range")}function D(e,t,r,n){t<0&&(t=65535+t+1);for(var i=0,a=Math.min(e.length-r,2);i<a;++i)e[r+i]=(t&255<<8*(n?i:1-i))>>>8*(n?i:1-i)}function C(e,t,r,n){t<0&&(t=4294967295+t+1);for(var i=0,a=Math.min(e.length-r,4);i<a;++i)e[r+i]=t>>>8*(n?i:3-i)&255}function M(e,t,r,n,i,a){if(r+n>e.length)throw new RangeError("Index out of range");if(r<0)throw new RangeError("Index out of range")}function L(e,t,r,n,a){return a||M(e,0,r,4),i.write(e,t,r,n,23,4),r+4}function q(e,t,r,n,a){return a||M(e,0,r,8),i.write(e,t,r,n,52,8),r+8}c.prototype.slice=function(e,t){var r,n=this.length;if((e=~~e)<0?(e+=n)<0&&(e=0):e>n&&(e=n),(t=void 0===t?n:~~t)<0?(t+=n)<0&&(t=0):t>n&&(t=n),t<e&&(t=e),c.TYPED_ARRAY_SUPPORT)(r=this.subarray(e,t)).__proto__=c.prototype;else{var i=t-e;r=new c(i,void 0);for(var a=0;a<i;++a)r[a]=this[a+e]}return r},c.prototype.readUIntLE=function(e,t,r){e|=0,t|=0,r||P(e,t,this.length);for(var n=this[e],i=1,a=0;++a<t&&(i*=256);)n+=this[e+a]*i;return n},c.prototype.readUIntBE=function(e,t,r){e|=0,t|=0,r||P(e,t,this.length);for(var n=this[e+--t],i=1;t>0&&(i*=256);)n+=this[e+--t]*i;return n},c.prototype.readUInt8=function(e,t){return t||P(e,1,this.length),this[e]},c.prototype.readUInt16LE=function(e,t){return t||P(e,2,this.length),this[e]|this[e+1]<<8},c.prototype.readUInt16BE=function(e,t){return t||P(e,2,this.length),this[e]<<8|this[e+1]},c.prototype.readUInt32LE=function(e,t){return t||P(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+16777216*this[e+3]},c.prototype.readUInt32BE=function(e,t){return t||P(e,4,this.length),16777216*this[e]+(this[e+1]<<16|this[e+2]<<8|this[e+3])},c.prototype.readIntLE=function(e,t,r){e|=0,t|=0,r||P(e,t,this.length);for(var n=this[e],i=1,a=0;++a<t&&(i*=256);)n+=this[e+a]*i;return n>=(i*=128)&&(n-=Math.pow(2,8*t)),n},c.prototype.readIntBE=function(e,t,r){e|=0,t|=0,r||P(e,t,this.length);for(var n=t,i=1,a=this[e+--n];n>0&&(i*=256);)a+=this[e+--n]*i;return a>=(i*=128)&&(a-=Math.pow(2,8*t)),a},c.prototype.readInt8=function(e,t){return t||P(e,1,this.length),128&this[e]?-1*(255-this[e]+1):this[e]},c.prototype.readInt16LE=function(e,t){t||P(e,2,this.length);var r=this[e]|this[e+1]<<8;return 32768&r?4294901760|r:r},c.prototype.readInt16BE=function(e,t){t||P(e,2,this.length);var r=this[e+1]|this[e]<<8;return 32768&r?4294901760|r:r},c.prototype.readInt32LE=function(e,t){return t||P(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},c.prototype.readInt32BE=function(e,t){return t||P(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},c.prototype.readFloatLE=function(e,t){return t||P(e,4,this.length),i.read(this,e,!0,23,4)},c.prototype.readFloatBE=function(e,t){return t||P(e,4,this.length),i.read(this,e,!1,23,4)},c.prototype.readDoubleLE=function(e,t){return t||P(e,8,this.length),i.read(this,e,!0,52,8)},c.prototype.readDoubleBE=function(e,t){return t||P(e,8,this.length),i.read(this,e,!1,52,8)},c.prototype.writeUIntLE=function(e,t,r,n){(e=+e,t|=0,r|=0,n)||j(this,e,t,r,Math.pow(2,8*r)-1,0);var i=1,a=0;for(this[t]=255&e;++a<r&&(i*=256);)this[t+a]=e/i&255;return t+r},c.prototype.writeUIntBE=function(e,t,r,n){(e=+e,t|=0,r|=0,n)||j(this,e,t,r,Math.pow(2,8*r)-1,0);var i=r-1,a=1;for(this[t+i]=255&e;--i>=0&&(a*=256);)this[t+i]=e/a&255;return t+r},c.prototype.writeUInt8=function(e,t,r){return e=+e,t|=0,r||j(this,e,t,1,255,0),c.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),this[t]=255&e,t+1},c.prototype.writeUInt16LE=function(e,t,r){return e=+e,t|=0,r||j(this,e,t,2,65535,0),c.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8):D(this,e,t,!0),t+2},c.prototype.writeUInt16BE=function(e,t,r){return e=+e,t|=0,r||j(this,e,t,2,65535,0),c.TYPED_ARRAY_SUPPORT?(this[t]=e>>>8,this[t+1]=255&e):D(this,e,t,!1),t+2},c.prototype.writeUInt32LE=function(e,t,r){return e=+e,t|=0,r||j(this,e,t,4,4294967295,0),c.TYPED_ARRAY_SUPPORT?(this[t+3]=e>>>24,this[t+2]=e>>>16,this[t+1]=e>>>8,this[t]=255&e):C(this,e,t,!0),t+4},c.prototype.writeUInt32BE=function(e,t,r){return e=+e,t|=0,r||j(this,e,t,4,4294967295,0),c.TYPED_ARRAY_SUPPORT?(this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e):C(this,e,t,!1),t+4},c.prototype.writeIntLE=function(e,t,r,n){if(e=+e,t|=0,!n){var i=Math.pow(2,8*r-1);j(this,e,t,r,i-1,-i)}var a=0,o=1,s=0;for(this[t]=255&e;++a<r&&(o*=256);)e<0&&0===s&&0!==this[t+a-1]&&(s=1),this[t+a]=(e/o>>0)-s&255;return t+r},c.prototype.writeIntBE=function(e,t,r,n){if(e=+e,t|=0,!n){var i=Math.pow(2,8*r-1);j(this,e,t,r,i-1,-i)}var a=r-1,o=1,s=0;for(this[t+a]=255&e;--a>=0&&(o*=256);)e<0&&0===s&&0!==this[t+a+1]&&(s=1),this[t+a]=(e/o>>0)-s&255;return t+r},c.prototype.writeInt8=function(e,t,r){return e=+e,t|=0,r||j(this,e,t,1,127,-128),c.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),e<0&&(e=255+e+1),this[t]=255&e,t+1},c.prototype.writeInt16LE=function(e,t,r){return e=+e,t|=0,r||j(this,e,t,2,32767,-32768),c.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8):D(this,e,t,!0),t+2},c.prototype.writeInt16BE=function(e,t,r){return e=+e,t|=0,r||j(this,e,t,2,32767,-32768),c.TYPED_ARRAY_SUPPORT?(this[t]=e>>>8,this[t+1]=255&e):D(this,e,t,!1),t+2},c.prototype.writeInt32LE=function(e,t,r){return e=+e,t|=0,r||j(this,e,t,4,2147483647,-2147483648),c.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8,this[t+2]=e>>>16,this[t+3]=e>>>24):C(this,e,t,!0),t+4},c.prototype.writeInt32BE=function(e,t,r){return e=+e,t|=0,r||j(this,e,t,4,2147483647,-2147483648),e<0&&(e=4294967295+e+1),c.TYPED_ARRAY_SUPPORT?(this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e):C(this,e,t,!1),t+4},c.prototype.writeFloatLE=function(e,t,r){return L(this,e,t,!0,r)},c.prototype.writeFloatBE=function(e,t,r){return L(this,e,t,!1,r)},c.prototype.writeDoubleLE=function(e,t,r){return q(this,e,t,!0,r)},c.prototype.writeDoubleBE=function(e,t,r){return q(this,e,t,!1,r)},c.prototype.copy=function(e,t,r,n){if(r||(r=0),n||0===n||(n=this.length),t>=e.length&&(t=e.length),t||(t=0),n>0&&n<r&&(n=r),n===r)return 0;if(0===e.length||0===this.length)return 0;if(t<0)throw new RangeError("targetStart out of bounds");if(r<0||r>=this.length)throw new RangeError("sourceStart out of bounds");if(n<0)throw new RangeError("sourceEnd out of bounds");n>this.length&&(n=this.length),e.length-t<n-r&&(n=e.length-t+r);var i,a=n-r;if(this===e&&r<t&&t<n)for(i=a-1;i>=0;--i)e[i+t]=this[i+r];else if(a<1e3||!c.TYPED_ARRAY_SUPPORT)for(i=0;i<a;++i)e[i+t]=this[i+r];else Uint8Array.prototype.set.call(e,this.subarray(r,r+a),t);return a},c.prototype.fill=function(e,t,r,n){if("string"==typeof e){if("string"==typeof t?(n=t,t=0,r=this.length):"string"==typeof r&&(n=r,r=this.length),1===e.length){var i=e.charCodeAt(0);i<256&&(e=i)}if(void 0!==n&&"string"!=typeof n)throw new TypeError("encoding must be a string");if("string"==typeof n&&!c.isEncoding(n))throw new TypeError("Unknown encoding: "+n)}else"number"==typeof e&&(e&=255);if(t<0||this.length<t||this.length<r)throw new RangeError("Out of range index");if(r<=t)return this;var a;if(t>>>=0,r=void 0===r?this.length:r>>>0,e||(e=0),"number"==typeof e)for(a=t;a<r;++a)this[a]=e;else{var o=c.isBuffer(e)?e:U(new c(e,n).toString()),s=o.length;for(a=0;a<r-t;++a)this[a+t]=o[a%s]}return this};var F=/[^+\/0-9A-Za-z-_]/g;function B(e){return e<16?"0"+e.toString(16):e.toString(16)}function U(e,t){var r;t=t||1/0;for(var n=e.length,i=null,a=[],o=0;o<n;++o){if((r=e.charCodeAt(o))>55295&&r<57344){if(!i){if(r>56319){(t-=3)>-1&&a.push(239,191,189);continue}if(o+1===n){(t-=3)>-1&&a.push(239,191,189);continue}i=r;continue}if(r<56320){(t-=3)>-1&&a.push(239,191,189),i=r;continue}r=65536+(i-55296<<10|r-56320)}else i&&(t-=3)>-1&&a.push(239,191,189);if(i=null,r<128){if((t-=1)<0)break;a.push(r)}else if(r<2048){if((t-=2)<0)break;a.push(r>>6|192,63&r|128)}else if(r<65536){if((t-=3)<0)break;a.push(r>>12|224,r>>6&63|128,63&r|128)}else{if(!(r<1114112))throw new Error("Invalid code point");if((t-=4)<0)break;a.push(r>>18|240,r>>12&63|128,r>>6&63|128,63&r|128)}}return a}function V(e){return n.toByteArray(function(e){if((e=function(e){return e.trim?e.trim():e.replace(/^\s+|\s+$/g,"")}(e).replace(F,"")).length<2)return"";for(;e.length%4!=0;)e+="=";return e}(e))}function H(e,t,r,n){for(var i=0;i<n&&!(i+r>=t.length||i>=e.length);++i)t[i+r]=e[i];return i}}).call(this,r(9))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(455);t.getLiteralLanguage=n.getLiteralLanguage,t.getLiteralType=n.getLiteralType,t.getLiteralValue=n.getLiteralValue,t.quadToStringQuad=n.quadToStringQuad,t.stringQuadToQuad=n.stringQuadToQuad,t.stringToTerm=n.stringToTerm,t.termToString=n.termToString},function(e,t){var r;r=function(){return this}();try{r=r||new Function("return this")()}catch(e){"object"==typeof window&&(r=window)}e.exports=r},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(454);t.translate=n.default;const i=r(72);t.Algebra=i;const a=r(73);t.Factory=a.default;const o=r(461);t.toSparql=o.toSparql,t.toSparqlJs=o.toSparqlJs;const s=r(197);t.Util=s.default},function(e,t,r){(function(e){!function(e,t){"use strict";function n(e,t){if(!e)throw new Error(t||"Assertion failed")}function i(e,t){e.super_=t;var r=function(){};r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e}function a(e,t,r){if(a.isBN(e))return e;this.negative=0,this.words=null,this.length=0,this.red=null,null!==e&&("le"!==t&&"be"!==t||(r=t,t=10),this._init(e||0,t||10,r||"be"))}var o;"object"==typeof e?e.exports=a:t.BN=a,a.BN=a,a.wordSize=26;try{o=r(621).Buffer}catch(e){}function s(e,t,r){for(var n=0,i=Math.min(e.length,r),a=t;a<i;a++){var o=e.charCodeAt(a)-48;n<<=4,n|=o>=49&&o<=54?o-49+10:o>=17&&o<=22?o-17+10:15&o}return n}function c(e,t,r,n){for(var i=0,a=Math.min(e.length,r),o=t;o<a;o++){var s=e.charCodeAt(o)-48;i*=n,i+=s>=49?s-49+10:s>=17?s-17+10:s}return i}a.isBN=function(e){return e instanceof a||null!==e&&"object"==typeof e&&e.constructor.wordSize===a.wordSize&&Array.isArray(e.words)},a.max=function(e,t){return e.cmp(t)>0?e:t},a.min=function(e,t){return e.cmp(t)<0?e:t},a.prototype._init=function(e,t,r){if("number"==typeof e)return this._initNumber(e,t,r);if("object"==typeof e)return this._initArray(e,t,r);"hex"===t&&(t=16),n(t===(0|t)&&t>=2&&t<=36);var i=0;"-"===(e=e.toString().replace(/\s+/g,""))[0]&&i++,16===t?this._parseHex(e,i):this._parseBase(e,t,i),"-"===e[0]&&(this.negative=1),this.strip(),"le"===r&&this._initArray(this.toArray(),t,r)},a.prototype._initNumber=function(e,t,r){e<0&&(this.negative=1,e=-e),e<67108864?(this.words=[67108863&e],this.length=1):e<4503599627370496?(this.words=[67108863&e,e/67108864&67108863],this.length=2):(n(e<9007199254740992),this.words=[67108863&e,e/67108864&67108863,1],this.length=3),"le"===r&&this._initArray(this.toArray(),t,r)},a.prototype._initArray=function(e,t,r){if(n("number"==typeof e.length),e.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(e.length/3),this.words=new Array(this.length);for(var i=0;i<this.length;i++)this.words[i]=0;var a,o,s=0;if("be"===r)for(i=e.length-1,a=0;i>=0;i-=3)o=e[i]|e[i-1]<<8|e[i-2]<<16,this.words[a]|=o<<s&67108863,this.words[a+1]=o>>>26-s&67108863,(s+=24)>=26&&(s-=26,a++);else if("le"===r)for(i=0,a=0;i<e.length;i+=3)o=e[i]|e[i+1]<<8|e[i+2]<<16,this.words[a]|=o<<s&67108863,this.words[a+1]=o>>>26-s&67108863,(s+=24)>=26&&(s-=26,a++);return this.strip()},a.prototype._parseHex=function(e,t){this.length=Math.ceil((e.length-t)/6),this.words=new Array(this.length);for(var r=0;r<this.length;r++)this.words[r]=0;var n,i,a=0;for(r=e.length-6,n=0;r>=t;r-=6)i=s(e,r,r+6),this.words[n]|=i<<a&67108863,this.words[n+1]|=i>>>26-a&4194303,(a+=24)>=26&&(a-=26,n++);r+6!==t&&(i=s(e,t,r+6),this.words[n]|=i<<a&67108863,this.words[n+1]|=i>>>26-a&4194303),this.strip()},a.prototype._parseBase=function(e,t,r){this.words=[0],this.length=1;for(var n=0,i=1;i<=67108863;i*=t)n++;n--,i=i/t|0;for(var a=e.length-r,o=a%n,s=Math.min(a,a-o)+r,u=0,l=r;l<s;l+=n)u=c(e,l,l+n,t),this.imuln(i),this.words[0]+u<67108864?this.words[0]+=u:this._iaddn(u);if(0!==o){var f=1;for(u=c(e,l,e.length,t),l=0;l<o;l++)f*=t;this.imuln(f),this.words[0]+u<67108864?this.words[0]+=u:this._iaddn(u)}},a.prototype.copy=function(e){e.words=new Array(this.length);for(var t=0;t<this.length;t++)e.words[t]=this.words[t];e.length=this.length,e.negative=this.negative,e.red=this.red},a.prototype.clone=function(){var e=new a(null);return this.copy(e),e},a.prototype._expand=function(e){for(;this.length<e;)this.words[this.length++]=0;return this},a.prototype.strip=function(){for(;this.length>1&&0===this.words[this.length-1];)this.length--;return this._normSign()},a.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},a.prototype.inspect=function(){return(this.red?"<BN-R: ":"<BN: ")+this.toString(16)+">"};var u=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],l=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],f=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];function d(e,t,r){r.negative=t.negative^e.negative;var n=e.length+t.length|0;r.length=n,n=n-1|0;var i=0|e.words[0],a=0|t.words[0],o=i*a,s=67108863&o,c=o/67108864|0;r.words[0]=s;for(var u=1;u<n;u++){for(var l=c>>>26,f=67108863&c,d=Math.min(u,t.length-1),h=Math.max(0,u-e.length+1);h<=d;h++){var p=u-h|0;l+=(o=(i=0|e.words[p])*(a=0|t.words[h])+f)/67108864|0,f=67108863&o}r.words[u]=0|f,c=0|l}return 0!==c?r.words[u]=0|c:r.length--,r.strip()}a.prototype.toString=function(e,t){var r;if(t=0|t||1,16===(e=e||10)||"hex"===e){r="";for(var i=0,a=0,o=0;o<this.length;o++){var s=this.words[o],c=(16777215&(s<<i|a)).toString(16);r=0!==(a=s>>>24-i&16777215)||o!==this.length-1?u[6-c.length]+c+r:c+r,(i+=2)>=26&&(i-=26,o--)}for(0!==a&&(r=a.toString(16)+r);r.length%t!=0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}if(e===(0|e)&&e>=2&&e<=36){var d=l[e],h=f[e];r="";var p=this.clone();for(p.negative=0;!p.isZero();){var y=p.modn(h).toString(e);r=(p=p.idivn(h)).isZero()?y+r:u[d-y.length]+y+r}for(this.isZero()&&(r="0"+r);r.length%t!=0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}n(!1,"Base should be between 2 and 36")},a.prototype.toNumber=function(){var e=this.words[0];return 2===this.length?e+=67108864*this.words[1]:3===this.length&&1===this.words[2]?e+=4503599627370496+67108864*this.words[1]:this.length>2&&n(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-e:e},a.prototype.toJSON=function(){return this.toString(16)},a.prototype.toBuffer=function(e,t){return n(void 0!==o),this.toArrayLike(o,e,t)},a.prototype.toArray=function(e,t){return this.toArrayLike(Array,e,t)},a.prototype.toArrayLike=function(e,t,r){var i=this.byteLength(),a=r||Math.max(1,i);n(i<=a,"byte array longer than desired length"),n(a>0,"Requested array length <= 0"),this.strip();var o,s,c="le"===t,u=new e(a),l=this.clone();if(c){for(s=0;!l.isZero();s++)o=l.andln(255),l.iushrn(8),u[s]=o;for(;s<a;s++)u[s]=0}else{for(s=0;s<a-i;s++)u[s]=0;for(s=0;!l.isZero();s++)o=l.andln(255),l.iushrn(8),u[a-s-1]=o}return u},Math.clz32?a.prototype._countBits=function(e){return 32-Math.clz32(e)}:a.prototype._countBits=function(e){var t=e,r=0;return t>=4096&&(r+=13,t>>>=13),t>=64&&(r+=7,t>>>=7),t>=8&&(r+=4,t>>>=4),t>=2&&(r+=2,t>>>=2),r+t},a.prototype._zeroBits=function(e){if(0===e)return 26;var t=e,r=0;return 0==(8191&t)&&(r+=13,t>>>=13),0==(127&t)&&(r+=7,t>>>=7),0==(15&t)&&(r+=4,t>>>=4),0==(3&t)&&(r+=2,t>>>=2),0==(1&t)&&r++,r},a.prototype.bitLength=function(){var e=this.words[this.length-1],t=this._countBits(e);return 26*(this.length-1)+t},a.prototype.zeroBits=function(){if(this.isZero())return 0;for(var e=0,t=0;t<this.length;t++){var r=this._zeroBits(this.words[t]);if(e+=r,26!==r)break}return e},a.prototype.byteLength=function(){return Math.ceil(this.bitLength()/8)},a.prototype.toTwos=function(e){return 0!==this.negative?this.abs().inotn(e).iaddn(1):this.clone()},a.prototype.fromTwos=function(e){return this.testn(e-1)?this.notn(e).iaddn(1).ineg():this.clone()},a.prototype.isNeg=function(){return 0!==this.negative},a.prototype.neg=function(){return this.clone().ineg()},a.prototype.ineg=function(){return this.isZero()||(this.negative^=1),this},a.prototype.iuor=function(e){for(;this.length<e.length;)this.words[this.length++]=0;for(var t=0;t<e.length;t++)this.words[t]=this.words[t]|e.words[t];return this.strip()},a.prototype.ior=function(e){return n(0==(this.negative|e.negative)),this.iuor(e)},a.prototype.or=function(e){return this.length>e.length?this.clone().ior(e):e.clone().ior(this)},a.prototype.uor=function(e){return this.length>e.length?this.clone().iuor(e):e.clone().iuor(this)},a.prototype.iuand=function(e){var t;t=this.length>e.length?e:this;for(var r=0;r<t.length;r++)this.words[r]=this.words[r]&e.words[r];return this.length=t.length,this.strip()},a.prototype.iand=function(e){return n(0==(this.negative|e.negative)),this.iuand(e)},a.prototype.and=function(e){return this.length>e.length?this.clone().iand(e):e.clone().iand(this)},a.prototype.uand=function(e){return this.length>e.length?this.clone().iuand(e):e.clone().iuand(this)},a.prototype.iuxor=function(e){var t,r;this.length>e.length?(t=this,r=e):(t=e,r=this);for(var n=0;n<r.length;n++)this.words[n]=t.words[n]^r.words[n];if(this!==t)for(;n<t.length;n++)this.words[n]=t.words[n];return this.length=t.length,this.strip()},a.prototype.ixor=function(e){return n(0==(this.negative|e.negative)),this.iuxor(e)},a.prototype.xor=function(e){return this.length>e.length?this.clone().ixor(e):e.clone().ixor(this)},a.prototype.uxor=function(e){return this.length>e.length?this.clone().iuxor(e):e.clone().iuxor(this)},a.prototype.inotn=function(e){n("number"==typeof e&&e>=0);var t=0|Math.ceil(e/26),r=e%26;this._expand(t),r>0&&t--;for(var i=0;i<t;i++)this.words[i]=67108863&~this.words[i];return r>0&&(this.words[i]=~this.words[i]&67108863>>26-r),this.strip()},a.prototype.notn=function(e){return this.clone().inotn(e)},a.prototype.setn=function(e,t){n("number"==typeof e&&e>=0);var r=e/26|0,i=e%26;return this._expand(r+1),this.words[r]=t?this.words[r]|1<<i:this.words[r]&~(1<<i),this.strip()},a.prototype.iadd=function(e){var t,r,n;if(0!==this.negative&&0===e.negative)return this.negative=0,t=this.isub(e),this.negative^=1,this._normSign();if(0===this.negative&&0!==e.negative)return e.negative=0,t=this.isub(e),e.negative=1,t._normSign();this.length>e.length?(r=this,n=e):(r=e,n=this);for(var i=0,a=0;a<n.length;a++)t=(0|r.words[a])+(0|n.words[a])+i,this.words[a]=67108863&t,i=t>>>26;for(;0!==i&&a<r.length;a++)t=(0|r.words[a])+i,this.words[a]=67108863&t,i=t>>>26;if(this.length=r.length,0!==i)this.words[this.length]=i,this.length++;else if(r!==this)for(;a<r.length;a++)this.words[a]=r.words[a];return this},a.prototype.add=function(e){var t;return 0!==e.negative&&0===this.negative?(e.negative=0,t=this.sub(e),e.negative^=1,t):0===e.negative&&0!==this.negative?(this.negative=0,t=e.sub(this),this.negative=1,t):this.length>e.length?this.clone().iadd(e):e.clone().iadd(this)},a.prototype.isub=function(e){if(0!==e.negative){e.negative=0;var t=this.iadd(e);return e.negative=1,t._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(e),this.negative=1,this._normSign();var r,n,i=this.cmp(e);if(0===i)return this.negative=0,this.length=1,this.words[0]=0,this;i>0?(r=this,n=e):(r=e,n=this);for(var a=0,o=0;o<n.length;o++)a=(t=(0|r.words[o])-(0|n.words[o])+a)>>26,this.words[o]=67108863&t;for(;0!==a&&o<r.length;o++)a=(t=(0|r.words[o])+a)>>26,this.words[o]=67108863&t;if(0===a&&o<r.length&&r!==this)for(;o<r.length;o++)this.words[o]=r.words[o];return this.length=Math.max(this.length,o),r!==this&&(this.negative=1),this.strip()},a.prototype.sub=function(e){return this.clone().isub(e)};var h=function(e,t,r){var n,i,a,o=e.words,s=t.words,c=r.words,u=0,l=0|o[0],f=8191&l,d=l>>>13,h=0|o[1],p=8191&h,y=h>>>13,m=0|o[2],g=8191&m,b=m>>>13,v=0|o[3],_=8191&v,w=v>>>13,S=0|o[4],E=8191&S,x=S>>>13,T=0|o[5],O=8191&T,A=T>>>13,I=0|o[6],N=8191&I,R=I>>>13,k=0|o[7],P=8191&k,j=k>>>13,D=0|o[8],C=8191&D,M=D>>>13,L=0|o[9],q=8191&L,F=L>>>13,B=0|s[0],U=8191&B,V=B>>>13,H=0|s[1],z=8191&H,G=H>>>13,Q=0|s[2],X=8191&Q,$=Q>>>13,J=0|s[3],Y=8191&J,K=J>>>13,W=0|s[4],Z=8191&W,ee=W>>>13,te=0|s[5],re=8191&te,ne=te>>>13,ie=0|s[6],ae=8191&ie,oe=ie>>>13,se=0|s[7],ce=8191&se,ue=se>>>13,le=0|s[8],fe=8191&le,de=le>>>13,he=0|s[9],pe=8191&he,ye=he>>>13;r.negative=e.negative^t.negative,r.length=19;var me=(u+(n=Math.imul(f,U))|0)+((8191&(i=(i=Math.imul(f,V))+Math.imul(d,U)|0))<<13)|0;u=((a=Math.imul(d,V))+(i>>>13)|0)+(me>>>26)|0,me&=67108863,n=Math.imul(p,U),i=(i=Math.imul(p,V))+Math.imul(y,U)|0,a=Math.imul(y,V);var ge=(u+(n=n+Math.imul(f,z)|0)|0)+((8191&(i=(i=i+Math.imul(f,G)|0)+Math.imul(d,z)|0))<<13)|0;u=((a=a+Math.imul(d,G)|0)+(i>>>13)|0)+(ge>>>26)|0,ge&=67108863,n=Math.imul(g,U),i=(i=Math.imul(g,V))+Math.imul(b,U)|0,a=Math.imul(b,V),n=n+Math.imul(p,z)|0,i=(i=i+Math.imul(p,G)|0)+Math.imul(y,z)|0,a=a+Math.imul(y,G)|0;var be=(u+(n=n+Math.imul(f,X)|0)|0)+((8191&(i=(i=i+Math.imul(f,$)|0)+Math.imul(d,X)|0))<<13)|0;u=((a=a+Math.imul(d,$)|0)+(i>>>13)|0)+(be>>>26)|0,be&=67108863,n=Math.imul(_,U),i=(i=Math.imul(_,V))+Math.imul(w,U)|0,a=Math.imul(w,V),n=n+Math.imul(g,z)|0,i=(i=i+Math.imul(g,G)|0)+Math.imul(b,z)|0,a=a+Math.imul(b,G)|0,n=n+Math.imul(p,X)|0,i=(i=i+Math.imul(p,$)|0)+Math.imul(y,X)|0,a=a+Math.imul(y,$)|0;var ve=(u+(n=n+Math.imul(f,Y)|0)|0)+((8191&(i=(i=i+Math.imul(f,K)|0)+Math.imul(d,Y)|0))<<13)|0;u=((a=a+Math.imul(d,K)|0)+(i>>>13)|0)+(ve>>>26)|0,ve&=67108863,n=Math.imul(E,U),i=(i=Math.imul(E,V))+Math.imul(x,U)|0,a=Math.imul(x,V),n=n+Math.imul(_,z)|0,i=(i=i+Math.imul(_,G)|0)+Math.imul(w,z)|0,a=a+Math.imul(w,G)|0,n=n+Math.imul(g,X)|0,i=(i=i+Math.imul(g,$)|0)+Math.imul(b,X)|0,a=a+Math.imul(b,$)|0,n=n+Math.imul(p,Y)|0,i=(i=i+Math.imul(p,K)|0)+Math.imul(y,Y)|0,a=a+Math.imul(y,K)|0;var _e=(u+(n=n+Math.imul(f,Z)|0)|0)+((8191&(i=(i=i+Math.imul(f,ee)|0)+Math.imul(d,Z)|0))<<13)|0;u=((a=a+Math.imul(d,ee)|0)+(i>>>13)|0)+(_e>>>26)|0,_e&=67108863,n=Math.imul(O,U),i=(i=Math.imul(O,V))+Math.imul(A,U)|0,a=Math.imul(A,V),n=n+Math.imul(E,z)|0,i=(i=i+Math.imul(E,G)|0)+Math.imul(x,z)|0,a=a+Math.imul(x,G)|0,n=n+Math.imul(_,X)|0,i=(i=i+Math.imul(_,$)|0)+Math.imul(w,X)|0,a=a+Math.imul(w,$)|0,n=n+Math.imul(g,Y)|0,i=(i=i+Math.imul(g,K)|0)+Math.imul(b,Y)|0,a=a+Math.imul(b,K)|0,n=n+Math.imul(p,Z)|0,i=(i=i+Math.imul(p,ee)|0)+Math.imul(y,Z)|0,a=a+Math.imul(y,ee)|0;var we=(u+(n=n+Math.imul(f,re)|0)|0)+((8191&(i=(i=i+Math.imul(f,ne)|0)+Math.imul(d,re)|0))<<13)|0;u=((a=a+Math.imul(d,ne)|0)+(i>>>13)|0)+(we>>>26)|0,we&=67108863,n=Math.imul(N,U),i=(i=Math.imul(N,V))+Math.imul(R,U)|0,a=Math.imul(R,V),n=n+Math.imul(O,z)|0,i=(i=i+Math.imul(O,G)|0)+Math.imul(A,z)|0,a=a+Math.imul(A,G)|0,n=n+Math.imul(E,X)|0,i=(i=i+Math.imul(E,$)|0)+Math.imul(x,X)|0,a=a+Math.imul(x,$)|0,n=n+Math.imul(_,Y)|0,i=(i=i+Math.imul(_,K)|0)+Math.imul(w,Y)|0,a=a+Math.imul(w,K)|0,n=n+Math.imul(g,Z)|0,i=(i=i+Math.imul(g,ee)|0)+Math.imul(b,Z)|0,a=a+Math.imul(b,ee)|0,n=n+Math.imul(p,re)|0,i=(i=i+Math.imul(p,ne)|0)+Math.imul(y,re)|0,a=a+Math.imul(y,ne)|0;var Se=(u+(n=n+Math.imul(f,ae)|0)|0)+((8191&(i=(i=i+Math.imul(f,oe)|0)+Math.imul(d,ae)|0))<<13)|0;u=((a=a+Math.imul(d,oe)|0)+(i>>>13)|0)+(Se>>>26)|0,Se&=67108863,n=Math.imul(P,U),i=(i=Math.imul(P,V))+Math.imul(j,U)|0,a=Math.imul(j,V),n=n+Math.imul(N,z)|0,i=(i=i+Math.imul(N,G)|0)+Math.imul(R,z)|0,a=a+Math.imul(R,G)|0,n=n+Math.imul(O,X)|0,i=(i=i+Math.imul(O,$)|0)+Math.imul(A,X)|0,a=a+Math.imul(A,$)|0,n=n+Math.imul(E,Y)|0,i=(i=i+Math.imul(E,K)|0)+Math.imul(x,Y)|0,a=a+Math.imul(x,K)|0,n=n+Math.imul(_,Z)|0,i=(i=i+Math.imul(_,ee)|0)+Math.imul(w,Z)|0,a=a+Math.imul(w,ee)|0,n=n+Math.imul(g,re)|0,i=(i=i+Math.imul(g,ne)|0)+Math.imul(b,re)|0,a=a+Math.imul(b,ne)|0,n=n+Math.imul(p,ae)|0,i=(i=i+Math.imul(p,oe)|0)+Math.imul(y,ae)|0,a=a+Math.imul(y,oe)|0;var Ee=(u+(n=n+Math.imul(f,ce)|0)|0)+((8191&(i=(i=i+Math.imul(f,ue)|0)+Math.imul(d,ce)|0))<<13)|0;u=((a=a+Math.imul(d,ue)|0)+(i>>>13)|0)+(Ee>>>26)|0,Ee&=67108863,n=Math.imul(C,U),i=(i=Math.imul(C,V))+Math.imul(M,U)|0,a=Math.imul(M,V),n=n+Math.imul(P,z)|0,i=(i=i+Math.imul(P,G)|0)+Math.imul(j,z)|0,a=a+Math.imul(j,G)|0,n=n+Math.imul(N,X)|0,i=(i=i+Math.imul(N,$)|0)+Math.imul(R,X)|0,a=a+Math.imul(R,$)|0,n=n+Math.imul(O,Y)|0,i=(i=i+Math.imul(O,K)|0)+Math.imul(A,Y)|0,a=a+Math.imul(A,K)|0,n=n+Math.imul(E,Z)|0,i=(i=i+Math.imul(E,ee)|0)+Math.imul(x,Z)|0,a=a+Math.imul(x,ee)|0,n=n+Math.imul(_,re)|0,i=(i=i+Math.imul(_,ne)|0)+Math.imul(w,re)|0,a=a+Math.imul(w,ne)|0,n=n+Math.imul(g,ae)|0,i=(i=i+Math.imul(g,oe)|0)+Math.imul(b,ae)|0,a=a+Math.imul(b,oe)|0,n=n+Math.imul(p,ce)|0,i=(i=i+Math.imul(p,ue)|0)+Math.imul(y,ce)|0,a=a+Math.imul(y,ue)|0;var xe=(u+(n=n+Math.imul(f,fe)|0)|0)+((8191&(i=(i=i+Math.imul(f,de)|0)+Math.imul(d,fe)|0))<<13)|0;u=((a=a+Math.imul(d,de)|0)+(i>>>13)|0)+(xe>>>26)|0,xe&=67108863,n=Math.imul(q,U),i=(i=Math.imul(q,V))+Math.imul(F,U)|0,a=Math.imul(F,V),n=n+Math.imul(C,z)|0,i=(i=i+Math.imul(C,G)|0)+Math.imul(M,z)|0,a=a+Math.imul(M,G)|0,n=n+Math.imul(P,X)|0,i=(i=i+Math.imul(P,$)|0)+Math.imul(j,X)|0,a=a+Math.imul(j,$)|0,n=n+Math.imul(N,Y)|0,i=(i=i+Math.imul(N,K)|0)+Math.imul(R,Y)|0,a=a+Math.imul(R,K)|0,n=n+Math.imul(O,Z)|0,i=(i=i+Math.imul(O,ee)|0)+Math.imul(A,Z)|0,a=a+Math.imul(A,ee)|0,n=n+Math.imul(E,re)|0,i=(i=i+Math.imul(E,ne)|0)+Math.imul(x,re)|0,a=a+Math.imul(x,ne)|0,n=n+Math.imul(_,ae)|0,i=(i=i+Math.imul(_,oe)|0)+Math.imul(w,ae)|0,a=a+Math.imul(w,oe)|0,n=n+Math.imul(g,ce)|0,i=(i=i+Math.imul(g,ue)|0)+Math.imul(b,ce)|0,a=a+Math.imul(b,ue)|0,n=n+Math.imul(p,fe)|0,i=(i=i+Math.imul(p,de)|0)+Math.imul(y,fe)|0,a=a+Math.imul(y,de)|0;var Te=(u+(n=n+Math.imul(f,pe)|0)|0)+((8191&(i=(i=i+Math.imul(f,ye)|0)+Math.imul(d,pe)|0))<<13)|0;u=((a=a+Math.imul(d,ye)|0)+(i>>>13)|0)+(Te>>>26)|0,Te&=67108863,n=Math.imul(q,z),i=(i=Math.imul(q,G))+Math.imul(F,z)|0,a=Math.imul(F,G),n=n+Math.imul(C,X)|0,i=(i=i+Math.imul(C,$)|0)+Math.imul(M,X)|0,a=a+Math.imul(M,$)|0,n=n+Math.imul(P,Y)|0,i=(i=i+Math.imul(P,K)|0)+Math.imul(j,Y)|0,a=a+Math.imul(j,K)|0,n=n+Math.imul(N,Z)|0,i=(i=i+Math.imul(N,ee)|0)+Math.imul(R,Z)|0,a=a+Math.imul(R,ee)|0,n=n+Math.imul(O,re)|0,i=(i=i+Math.imul(O,ne)|0)+Math.imul(A,re)|0,a=a+Math.imul(A,ne)|0,n=n+Math.imul(E,ae)|0,i=(i=i+Math.imul(E,oe)|0)+Math.imul(x,ae)|0,a=a+Math.imul(x,oe)|0,n=n+Math.imul(_,ce)|0,i=(i=i+Math.imul(_,ue)|0)+Math.imul(w,ce)|0,a=a+Math.imul(w,ue)|0,n=n+Math.imul(g,fe)|0,i=(i=i+Math.imul(g,de)|0)+Math.imul(b,fe)|0,a=a+Math.imul(b,de)|0;var Oe=(u+(n=n+Math.imul(p,pe)|0)|0)+((8191&(i=(i=i+Math.imul(p,ye)|0)+Math.imul(y,pe)|0))<<13)|0;u=((a=a+Math.imul(y,ye)|0)+(i>>>13)|0)+(Oe>>>26)|0,Oe&=67108863,n=Math.imul(q,X),i=(i=Math.imul(q,$))+Math.imul(F,X)|0,a=Math.imul(F,$),n=n+Math.imul(C,Y)|0,i=(i=i+Math.imul(C,K)|0)+Math.imul(M,Y)|0,a=a+Math.imul(M,K)|0,n=n+Math.imul(P,Z)|0,i=(i=i+Math.imul(P,ee)|0)+Math.imul(j,Z)|0,a=a+Math.imul(j,ee)|0,n=n+Math.imul(N,re)|0,i=(i=i+Math.imul(N,ne)|0)+Math.imul(R,re)|0,a=a+Math.imul(R,ne)|0,n=n+Math.imul(O,ae)|0,i=(i=i+Math.imul(O,oe)|0)+Math.imul(A,ae)|0,a=a+Math.imul(A,oe)|0,n=n+Math.imul(E,ce)|0,i=(i=i+Math.imul(E,ue)|0)+Math.imul(x,ce)|0,a=a+Math.imul(x,ue)|0,n=n+Math.imul(_,fe)|0,i=(i=i+Math.imul(_,de)|0)+Math.imul(w,fe)|0,a=a+Math.imul(w,de)|0;var Ae=(u+(n=n+Math.imul(g,pe)|0)|0)+((8191&(i=(i=i+Math.imul(g,ye)|0)+Math.imul(b,pe)|0))<<13)|0;u=((a=a+Math.imul(b,ye)|0)+(i>>>13)|0)+(Ae>>>26)|0,Ae&=67108863,n=Math.imul(q,Y),i=(i=Math.imul(q,K))+Math.imul(F,Y)|0,a=Math.imul(F,K),n=n+Math.imul(C,Z)|0,i=(i=i+Math.imul(C,ee)|0)+Math.imul(M,Z)|0,a=a+Math.imul(M,ee)|0,n=n+Math.imul(P,re)|0,i=(i=i+Math.imul(P,ne)|0)+Math.imul(j,re)|0,a=a+Math.imul(j,ne)|0,n=n+Math.imul(N,ae)|0,i=(i=i+Math.imul(N,oe)|0)+Math.imul(R,ae)|0,a=a+Math.imul(R,oe)|0,n=n+Math.imul(O,ce)|0,i=(i=i+Math.imul(O,ue)|0)+Math.imul(A,ce)|0,a=a+Math.imul(A,ue)|0,n=n+Math.imul(E,fe)|0,i=(i=i+Math.imul(E,de)|0)+Math.imul(x,fe)|0,a=a+Math.imul(x,de)|0;var Ie=(u+(n=n+Math.imul(_,pe)|0)|0)+((8191&(i=(i=i+Math.imul(_,ye)|0)+Math.imul(w,pe)|0))<<13)|0;u=((a=a+Math.imul(w,ye)|0)+(i>>>13)|0)+(Ie>>>26)|0,Ie&=67108863,n=Math.imul(q,Z),i=(i=Math.imul(q,ee))+Math.imul(F,Z)|0,a=Math.imul(F,ee),n=n+Math.imul(C,re)|0,i=(i=i+Math.imul(C,ne)|0)+Math.imul(M,re)|0,a=a+Math.imul(M,ne)|0,n=n+Math.imul(P,ae)|0,i=(i=i+Math.imul(P,oe)|0)+Math.imul(j,ae)|0,a=a+Math.imul(j,oe)|0,n=n+Math.imul(N,ce)|0,i=(i=i+Math.imul(N,ue)|0)+Math.imul(R,ce)|0,a=a+Math.imul(R,ue)|0,n=n+Math.imul(O,fe)|0,i=(i=i+Math.imul(O,de)|0)+Math.imul(A,fe)|0,a=a+Math.imul(A,de)|0;var Ne=(u+(n=n+Math.imul(E,pe)|0)|0)+((8191&(i=(i=i+Math.imul(E,ye)|0)+Math.imul(x,pe)|0))<<13)|0;u=((a=a+Math.imul(x,ye)|0)+(i>>>13)|0)+(Ne>>>26)|0,Ne&=67108863,n=Math.imul(q,re),i=(i=Math.imul(q,ne))+Math.imul(F,re)|0,a=Math.imul(F,ne),n=n+Math.imul(C,ae)|0,i=(i=i+Math.imul(C,oe)|0)+Math.imul(M,ae)|0,a=a+Math.imul(M,oe)|0,n=n+Math.imul(P,ce)|0,i=(i=i+Math.imul(P,ue)|0)+Math.imul(j,ce)|0,a=a+Math.imul(j,ue)|0,n=n+Math.imul(N,fe)|0,i=(i=i+Math.imul(N,de)|0)+Math.imul(R,fe)|0,a=a+Math.imul(R,de)|0;var Re=(u+(n=n+Math.imul(O,pe)|0)|0)+((8191&(i=(i=i+Math.imul(O,ye)|0)+Math.imul(A,pe)|0))<<13)|0;u=((a=a+Math.imul(A,ye)|0)+(i>>>13)|0)+(Re>>>26)|0,Re&=67108863,n=Math.imul(q,ae),i=(i=Math.imul(q,oe))+Math.imul(F,ae)|0,a=Math.imul(F,oe),n=n+Math.imul(C,ce)|0,i=(i=i+Math.imul(C,ue)|0)+Math.imul(M,ce)|0,a=a+Math.imul(M,ue)|0,n=n+Math.imul(P,fe)|0,i=(i=i+Math.imul(P,de)|0)+Math.imul(j,fe)|0,a=a+Math.imul(j,de)|0;var ke=(u+(n=n+Math.imul(N,pe)|0)|0)+((8191&(i=(i=i+Math.imul(N,ye)|0)+Math.imul(R,pe)|0))<<13)|0;u=((a=a+Math.imul(R,ye)|0)+(i>>>13)|0)+(ke>>>26)|0,ke&=67108863,n=Math.imul(q,ce),i=(i=Math.imul(q,ue))+Math.imul(F,ce)|0,a=Math.imul(F,ue),n=n+Math.imul(C,fe)|0,i=(i=i+Math.imul(C,de)|0)+Math.imul(M,fe)|0,a=a+Math.imul(M,de)|0;var Pe=(u+(n=n+Math.imul(P,pe)|0)|0)+((8191&(i=(i=i+Math.imul(P,ye)|0)+Math.imul(j,pe)|0))<<13)|0;u=((a=a+Math.imul(j,ye)|0)+(i>>>13)|0)+(Pe>>>26)|0,Pe&=67108863,n=Math.imul(q,fe),i=(i=Math.imul(q,de))+Math.imul(F,fe)|0,a=Math.imul(F,de);var je=(u+(n=n+Math.imul(C,pe)|0)|0)+((8191&(i=(i=i+Math.imul(C,ye)|0)+Math.imul(M,pe)|0))<<13)|0;u=((a=a+Math.imul(M,ye)|0)+(i>>>13)|0)+(je>>>26)|0,je&=67108863;var De=(u+(n=Math.imul(q,pe))|0)+((8191&(i=(i=Math.imul(q,ye))+Math.imul(F,pe)|0))<<13)|0;return u=((a=Math.imul(F,ye))+(i>>>13)|0)+(De>>>26)|0,De&=67108863,c[0]=me,c[1]=ge,c[2]=be,c[3]=ve,c[4]=_e,c[5]=we,c[6]=Se,c[7]=Ee,c[8]=xe,c[9]=Te,c[10]=Oe,c[11]=Ae,c[12]=Ie,c[13]=Ne,c[14]=Re,c[15]=ke,c[16]=Pe,c[17]=je,c[18]=De,0!==u&&(c[19]=u,r.length++),r};function p(e,t,r){return(new y).mulp(e,t,r)}function y(e,t){this.x=e,this.y=t}Math.imul||(h=d),a.prototype.mulTo=function(e,t){var r=this.length+e.length;return 10===this.length&&10===e.length?h(this,e,t):r<63?d(this,e,t):r<1024?function(e,t,r){r.negative=t.negative^e.negative,r.length=e.length+t.length;for(var n=0,i=0,a=0;a<r.length-1;a++){var o=i;i=0;for(var s=67108863&n,c=Math.min(a,t.length-1),u=Math.max(0,a-e.length+1);u<=c;u++){var l=a-u,f=(0|e.words[l])*(0|t.words[u]),d=67108863&f;s=67108863&(d=d+s|0),i+=(o=(o=o+(f/67108864|0)|0)+(d>>>26)|0)>>>26,o&=67108863}r.words[a]=s,n=o,o=i}return 0!==n?r.words[a]=n:r.length--,r.strip()}(this,e,t):p(this,e,t)},y.prototype.makeRBT=function(e){for(var t=new Array(e),r=a.prototype._countBits(e)-1,n=0;n<e;n++)t[n]=this.revBin(n,r,e);return t},y.prototype.revBin=function(e,t,r){if(0===e||e===r-1)return e;for(var n=0,i=0;i<t;i++)n|=(1&e)<<t-i-1,e>>=1;return n},y.prototype.permute=function(e,t,r,n,i,a){for(var o=0;o<a;o++)n[o]=t[e[o]],i[o]=r[e[o]]},y.prototype.transform=function(e,t,r,n,i,a){this.permute(a,e,t,r,n,i);for(var o=1;o<i;o<<=1)for(var s=o<<1,c=Math.cos(2*Math.PI/s),u=Math.sin(2*Math.PI/s),l=0;l<i;l+=s)for(var f=c,d=u,h=0;h<o;h++){var p=r[l+h],y=n[l+h],m=r[l+h+o],g=n[l+h+o],b=f*m-d*g;g=f*g+d*m,m=b,r[l+h]=p+m,n[l+h]=y+g,r[l+h+o]=p-m,n[l+h+o]=y-g,h!==s&&(b=c*f-u*d,d=c*d+u*f,f=b)}},y.prototype.guessLen13b=function(e,t){var r=1|Math.max(t,e),n=1&r,i=0;for(r=r/2|0;r;r>>>=1)i++;return 1<<i+1+n},y.prototype.conjugate=function(e,t,r){if(!(r<=1))for(var n=0;n<r/2;n++){var i=e[n];e[n]=e[r-n-1],e[r-n-1]=i,i=t[n],t[n]=-t[r-n-1],t[r-n-1]=-i}},y.prototype.normalize13b=function(e,t){for(var r=0,n=0;n<t/2;n++){var i=8192*Math.round(e[2*n+1]/t)+Math.round(e[2*n]/t)+r;e[n]=67108863&i,r=i<67108864?0:i/67108864|0}return e},y.prototype.convert13b=function(e,t,r,i){for(var a=0,o=0;o<t;o++)a+=0|e[o],r[2*o]=8191&a,a>>>=13,r[2*o+1]=8191&a,a>>>=13;for(o=2*t;o<i;++o)r[o]=0;n(0===a),n(0==(-8192&a))},y.prototype.stub=function(e){for(var t=new Array(e),r=0;r<e;r++)t[r]=0;return t},y.prototype.mulp=function(e,t,r){var n=2*this.guessLen13b(e.length,t.length),i=this.makeRBT(n),a=this.stub(n),o=new Array(n),s=new Array(n),c=new Array(n),u=new Array(n),l=new Array(n),f=new Array(n),d=r.words;d.length=n,this.convert13b(e.words,e.length,o,n),this.convert13b(t.words,t.length,u,n),this.transform(o,a,s,c,n,i),this.transform(u,a,l,f,n,i);for(var h=0;h<n;h++){var p=s[h]*l[h]-c[h]*f[h];c[h]=s[h]*f[h]+c[h]*l[h],s[h]=p}return this.conjugate(s,c,n),this.transform(s,c,d,a,n,i),this.conjugate(d,a,n),this.normalize13b(d,n),r.negative=e.negative^t.negative,r.length=e.length+t.length,r.strip()},a.prototype.mul=function(e){var t=new a(null);return t.words=new Array(this.length+e.length),this.mulTo(e,t)},a.prototype.mulf=function(e){var t=new a(null);return t.words=new Array(this.length+e.length),p(this,e,t)},a.prototype.imul=function(e){return this.clone().mulTo(e,this)},a.prototype.imuln=function(e){n("number"==typeof e),n(e<67108864);for(var t=0,r=0;r<this.length;r++){var i=(0|this.words[r])*e,a=(67108863&i)+(67108863&t);t>>=26,t+=i/67108864|0,t+=a>>>26,this.words[r]=67108863&a}return 0!==t&&(this.words[r]=t,this.length++),this},a.prototype.muln=function(e){return this.clone().imuln(e)},a.prototype.sqr=function(){return this.mul(this)},a.prototype.isqr=function(){return this.imul(this.clone())},a.prototype.pow=function(e){var t=function(e){for(var t=new Array(e.bitLength()),r=0;r<t.length;r++){var n=r/26|0,i=r%26;t[r]=(e.words[n]&1<<i)>>>i}return t}(e);if(0===t.length)return new a(1);for(var r=this,n=0;n<t.length&&0===t[n];n++,r=r.sqr());if(++n<t.length)for(var i=r.sqr();n<t.length;n++,i=i.sqr())0!==t[n]&&(r=r.mul(i));return r},a.prototype.iushln=function(e){n("number"==typeof e&&e>=0);var t,r=e%26,i=(e-r)/26,a=67108863>>>26-r<<26-r;if(0!==r){var o=0;for(t=0;t<this.length;t++){var s=this.words[t]&a,c=(0|this.words[t])-s<<r;this.words[t]=c|o,o=s>>>26-r}o&&(this.words[t]=o,this.length++)}if(0!==i){for(t=this.length-1;t>=0;t--)this.words[t+i]=this.words[t];for(t=0;t<i;t++)this.words[t]=0;this.length+=i}return this.strip()},a.prototype.ishln=function(e){return n(0===this.negative),this.iushln(e)},a.prototype.iushrn=function(e,t,r){var i;n("number"==typeof e&&e>=0),i=t?(t-t%26)/26:0;var a=e%26,o=Math.min((e-a)/26,this.length),s=67108863^67108863>>>a<<a,c=r;if(i-=o,i=Math.max(0,i),c){for(var u=0;u<o;u++)c.words[u]=this.words[u];c.length=o}if(0===o);else if(this.length>o)for(this.length-=o,u=0;u<this.length;u++)this.words[u]=this.words[u+o];else this.words[0]=0,this.length=1;var l=0;for(u=this.length-1;u>=0&&(0!==l||u>=i);u--){var f=0|this.words[u];this.words[u]=l<<26-a|f>>>a,l=f&s}return c&&0!==l&&(c.words[c.length++]=l),0===this.length&&(this.words[0]=0,this.length=1),this.strip()},a.prototype.ishrn=function(e,t,r){return n(0===this.negative),this.iushrn(e,t,r)},a.prototype.shln=function(e){return this.clone().ishln(e)},a.prototype.ushln=function(e){return this.clone().iushln(e)},a.prototype.shrn=function(e){return this.clone().ishrn(e)},a.prototype.ushrn=function(e){return this.clone().iushrn(e)},a.prototype.testn=function(e){n("number"==typeof e&&e>=0);var t=e%26,r=(e-t)/26,i=1<<t;return!(this.length<=r)&&!!(this.words[r]&i)},a.prototype.imaskn=function(e){n("number"==typeof e&&e>=0);var t=e%26,r=(e-t)/26;if(n(0===this.negative,"imaskn works only with positive numbers"),this.length<=r)return this;if(0!==t&&r++,this.length=Math.min(r,this.length),0!==t){var i=67108863^67108863>>>t<<t;this.words[this.length-1]&=i}return this.strip()},a.prototype.maskn=function(e){return this.clone().imaskn(e)},a.prototype.iaddn=function(e){return n("number"==typeof e),n(e<67108864),e<0?this.isubn(-e):0!==this.negative?1===this.length&&(0|this.words[0])<e?(this.words[0]=e-(0|this.words[0]),this.negative=0,this):(this.negative=0,this.isubn(e),this.negative=1,this):this._iaddn(e)},a.prototype._iaddn=function(e){this.words[0]+=e;for(var t=0;t<this.length&&this.words[t]>=67108864;t++)this.words[t]-=67108864,t===this.length-1?this.words[t+1]=1:this.words[t+1]++;return this.length=Math.max(this.length,t+1),this},a.prototype.isubn=function(e){if(n("number"==typeof e),n(e<67108864),e<0)return this.iaddn(-e);if(0!==this.negative)return this.negative=0,this.iaddn(e),this.negative=1,this;if(this.words[0]-=e,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var t=0;t<this.length&&this.words[t]<0;t++)this.words[t]+=67108864,this.words[t+1]-=1;return this.strip()},a.prototype.addn=function(e){return this.clone().iaddn(e)},a.prototype.subn=function(e){return this.clone().isubn(e)},a.prototype.iabs=function(){return this.negative=0,this},a.prototype.abs=function(){return this.clone().iabs()},a.prototype._ishlnsubmul=function(e,t,r){var i,a,o=e.length+r;this._expand(o);var s=0;for(i=0;i<e.length;i++){a=(0|this.words[i+r])+s;var c=(0|e.words[i])*t;s=((a-=67108863&c)>>26)-(c/67108864|0),this.words[i+r]=67108863&a}for(;i<this.length-r;i++)s=(a=(0|this.words[i+r])+s)>>26,this.words[i+r]=67108863&a;if(0===s)return this.strip();for(n(-1===s),s=0,i=0;i<this.length;i++)s=(a=-(0|this.words[i])+s)>>26,this.words[i]=67108863&a;return this.negative=1,this.strip()},a.prototype._wordDiv=function(e,t){var r=(this.length,e.length),n=this.clone(),i=e,o=0|i.words[i.length-1];0!==(r=26-this._countBits(o))&&(i=i.ushln(r),n.iushln(r),o=0|i.words[i.length-1]);var s,c=n.length-i.length;if("mod"!==t){(s=new a(null)).length=c+1,s.words=new Array(s.length);for(var u=0;u<s.length;u++)s.words[u]=0}var l=n.clone()._ishlnsubmul(i,1,c);0===l.negative&&(n=l,s&&(s.words[c]=1));for(var f=c-1;f>=0;f--){var d=67108864*(0|n.words[i.length+f])+(0|n.words[i.length+f-1]);for(d=Math.min(d/o|0,67108863),n._ishlnsubmul(i,d,f);0!==n.negative;)d--,n.negative=0,n._ishlnsubmul(i,1,f),n.isZero()||(n.negative^=1);s&&(s.words[f]=d)}return s&&s.strip(),n.strip(),"div"!==t&&0!==r&&n.iushrn(r),{div:s||null,mod:n}},a.prototype.divmod=function(e,t,r){return n(!e.isZero()),this.isZero()?{div:new a(0),mod:new a(0)}:0!==this.negative&&0===e.negative?(s=this.neg().divmod(e,t),"mod"!==t&&(i=s.div.neg()),"div"!==t&&(o=s.mod.neg(),r&&0!==o.negative&&o.iadd(e)),{div:i,mod:o}):0===this.negative&&0!==e.negative?(s=this.divmod(e.neg(),t),"mod"!==t&&(i=s.div.neg()),{div:i,mod:s.mod}):0!=(this.negative&e.negative)?(s=this.neg().divmod(e.neg(),t),"div"!==t&&(o=s.mod.neg(),r&&0!==o.negative&&o.isub(e)),{div:s.div,mod:o}):e.length>this.length||this.cmp(e)<0?{div:new a(0),mod:this}:1===e.length?"div"===t?{div:this.divn(e.words[0]),mod:null}:"mod"===t?{div:null,mod:new a(this.modn(e.words[0]))}:{div:this.divn(e.words[0]),mod:new a(this.modn(e.words[0]))}:this._wordDiv(e,t);var i,o,s},a.prototype.div=function(e){return this.divmod(e,"div",!1).div},a.prototype.mod=function(e){return this.divmod(e,"mod",!1).mod},a.prototype.umod=function(e){return this.divmod(e,"mod",!0).mod},a.prototype.divRound=function(e){var t=this.divmod(e);if(t.mod.isZero())return t.div;var r=0!==t.div.negative?t.mod.isub(e):t.mod,n=e.ushrn(1),i=e.andln(1),a=r.cmp(n);return a<0||1===i&&0===a?t.div:0!==t.div.negative?t.div.isubn(1):t.div.iaddn(1)},a.prototype.modn=function(e){n(e<=67108863);for(var t=(1<<26)%e,r=0,i=this.length-1;i>=0;i--)r=(t*r+(0|this.words[i]))%e;return r},a.prototype.idivn=function(e){n(e<=67108863);for(var t=0,r=this.length-1;r>=0;r--){var i=(0|this.words[r])+67108864*t;this.words[r]=i/e|0,t=i%e}return this.strip()},a.prototype.divn=function(e){return this.clone().idivn(e)},a.prototype.egcd=function(e){n(0===e.negative),n(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var i=new a(1),o=new a(0),s=new a(0),c=new a(1),u=0;t.isEven()&&r.isEven();)t.iushrn(1),r.iushrn(1),++u;for(var l=r.clone(),f=t.clone();!t.isZero();){for(var d=0,h=1;0==(t.words[0]&h)&&d<26;++d,h<<=1);if(d>0)for(t.iushrn(d);d-- >0;)(i.isOdd()||o.isOdd())&&(i.iadd(l),o.isub(f)),i.iushrn(1),o.iushrn(1);for(var p=0,y=1;0==(r.words[0]&y)&&p<26;++p,y<<=1);if(p>0)for(r.iushrn(p);p-- >0;)(s.isOdd()||c.isOdd())&&(s.iadd(l),c.isub(f)),s.iushrn(1),c.iushrn(1);t.cmp(r)>=0?(t.isub(r),i.isub(s),o.isub(c)):(r.isub(t),s.isub(i),c.isub(o))}return{a:s,b:c,gcd:r.iushln(u)}},a.prototype._invmp=function(e){n(0===e.negative),n(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var i,o=new a(1),s=new a(0),c=r.clone();t.cmpn(1)>0&&r.cmpn(1)>0;){for(var u=0,l=1;0==(t.words[0]&l)&&u<26;++u,l<<=1);if(u>0)for(t.iushrn(u);u-- >0;)o.isOdd()&&o.iadd(c),o.iushrn(1);for(var f=0,d=1;0==(r.words[0]&d)&&f<26;++f,d<<=1);if(f>0)for(r.iushrn(f);f-- >0;)s.isOdd()&&s.iadd(c),s.iushrn(1);t.cmp(r)>=0?(t.isub(r),o.isub(s)):(r.isub(t),s.isub(o))}return(i=0===t.cmpn(1)?o:s).cmpn(0)<0&&i.iadd(e),i},a.prototype.gcd=function(e){if(this.isZero())return e.abs();if(e.isZero())return this.abs();var t=this.clone(),r=e.clone();t.negative=0,r.negative=0;for(var n=0;t.isEven()&&r.isEven();n++)t.iushrn(1),r.iushrn(1);for(;;){for(;t.isEven();)t.iushrn(1);for(;r.isEven();)r.iushrn(1);var i=t.cmp(r);if(i<0){var a=t;t=r,r=a}else if(0===i||0===r.cmpn(1))break;t.isub(r)}return r.iushln(n)},a.prototype.invm=function(e){return this.egcd(e).a.umod(e)},a.prototype.isEven=function(){return 0==(1&this.words[0])},a.prototype.isOdd=function(){return 1==(1&this.words[0])},a.prototype.andln=function(e){return this.words[0]&e},a.prototype.bincn=function(e){n("number"==typeof e);var t=e%26,r=(e-t)/26,i=1<<t;if(this.length<=r)return this._expand(r+1),this.words[r]|=i,this;for(var a=i,o=r;0!==a&&o<this.length;o++){var s=0|this.words[o];a=(s+=a)>>>26,s&=67108863,this.words[o]=s}return 0!==a&&(this.words[o]=a,this.length++),this},a.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},a.prototype.cmpn=function(e){var t,r=e<0;if(0!==this.negative&&!r)return-1;if(0===this.negative&&r)return 1;if(this.strip(),this.length>1)t=1;else{r&&(e=-e),n(e<=67108863,"Number is too big");var i=0|this.words[0];t=i===e?0:i<e?-1:1}return 0!==this.negative?0|-t:t},a.prototype.cmp=function(e){if(0!==this.negative&&0===e.negative)return-1;if(0===this.negative&&0!==e.negative)return 1;var t=this.ucmp(e);return 0!==this.negative?0|-t:t},a.prototype.ucmp=function(e){if(this.length>e.length)return 1;if(this.length<e.length)return-1;for(var t=0,r=this.length-1;r>=0;r--){var n=0|this.words[r],i=0|e.words[r];if(n!==i){n<i?t=-1:n>i&&(t=1);break}}return t},a.prototype.gtn=function(e){return 1===this.cmpn(e)},a.prototype.gt=function(e){return 1===this.cmp(e)},a.prototype.gten=function(e){return this.cmpn(e)>=0},a.prototype.gte=function(e){return this.cmp(e)>=0},a.prototype.ltn=function(e){return-1===this.cmpn(e)},a.prototype.lt=function(e){return-1===this.cmp(e)},a.prototype.lten=function(e){return this.cmpn(e)<=0},a.prototype.lte=function(e){return this.cmp(e)<=0},a.prototype.eqn=function(e){return 0===this.cmpn(e)},a.prototype.eq=function(e){return 0===this.cmp(e)},a.red=function(e){return new S(e)},a.prototype.toRed=function(e){return n(!this.red,"Already a number in reduction context"),n(0===this.negative,"red works only with positives"),e.convertTo(this)._forceRed(e)},a.prototype.fromRed=function(){return n(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},a.prototype._forceRed=function(e){return this.red=e,this},a.prototype.forceRed=function(e){return n(!this.red,"Already a number in reduction context"),this._forceRed(e)},a.prototype.redAdd=function(e){return n(this.red,"redAdd works only with red numbers"),this.red.add(this,e)},a.prototype.redIAdd=function(e){return n(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,e)},a.prototype.redSub=function(e){return n(this.red,"redSub works only with red numbers"),this.red.sub(this,e)},a.prototype.redISub=function(e){return n(this.red,"redISub works only with red numbers"),this.red.isub(this,e)},a.prototype.redShl=function(e){return n(this.red,"redShl works only with red numbers"),this.red.shl(this,e)},a.prototype.redMul=function(e){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.mul(this,e)},a.prototype.redIMul=function(e){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.imul(this,e)},a.prototype.redSqr=function(){return n(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},a.prototype.redISqr=function(){return n(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},a.prototype.redSqrt=function(){return n(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},a.prototype.redInvm=function(){return n(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},a.prototype.redNeg=function(){return n(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},a.prototype.redPow=function(e){return n(this.red&&!e.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,e)};var m={k256:null,p224:null,p192:null,p25519:null};function g(e,t){this.name=e,this.p=new a(t,16),this.n=this.p.bitLength(),this.k=new a(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function b(){g.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function v(){g.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function _(){g.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function w(){g.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function S(e){if("string"==typeof e){var t=a._prime(e);this.m=t.p,this.prime=t}else n(e.gtn(1),"modulus must be greater than 1"),this.m=e,this.prime=null}function E(e){S.call(this,e),this.shift=this.m.bitLength(),this.shift%26!=0&&(this.shift+=26-this.shift%26),this.r=new a(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}g.prototype._tmp=function(){var e=new a(null);return e.words=new Array(Math.ceil(this.n/13)),e},g.prototype.ireduce=function(e){var t,r=e;do{this.split(r,this.tmp),t=(r=(r=this.imulK(r)).iadd(this.tmp)).bitLength()}while(t>this.n);var n=t<this.n?-1:r.ucmp(this.p);return 0===n?(r.words[0]=0,r.length=1):n>0?r.isub(this.p):r.strip(),r},g.prototype.split=function(e,t){e.iushrn(this.n,0,t)},g.prototype.imulK=function(e){return e.imul(this.k)},i(b,g),b.prototype.split=function(e,t){for(var r=Math.min(e.length,9),n=0;n<r;n++)t.words[n]=e.words[n];if(t.length=r,e.length<=9)return e.words[0]=0,void(e.length=1);var i=e.words[9];for(t.words[t.length++]=4194303&i,n=10;n<e.length;n++){var a=0|e.words[n];e.words[n-10]=(4194303&a)<<4|i>>>22,i=a}i>>>=22,e.words[n-10]=i,0===i&&e.length>10?e.length-=10:e.length-=9},b.prototype.imulK=function(e){e.words[e.length]=0,e.words[e.length+1]=0,e.length+=2;for(var t=0,r=0;r<e.length;r++){var n=0|e.words[r];t+=977*n,e.words[r]=67108863&t,t=64*n+(t/67108864|0)}return 0===e.words[e.length-1]&&(e.length--,0===e.words[e.length-1]&&e.length--),e},i(v,g),i(_,g),i(w,g),w.prototype.imulK=function(e){for(var t=0,r=0;r<e.length;r++){var n=19*(0|e.words[r])+t,i=67108863&n;n>>>=26,e.words[r]=i,t=n}return 0!==t&&(e.words[e.length++]=t),e},a._prime=function(e){if(m[e])return m[e];var t;if("k256"===e)t=new b;else if("p224"===e)t=new v;else if("p192"===e)t=new _;else{if("p25519"!==e)throw new Error("Unknown prime "+e);t=new w}return m[e]=t,t},S.prototype._verify1=function(e){n(0===e.negative,"red works only with positives"),n(e.red,"red works only with red numbers")},S.prototype._verify2=function(e,t){n(0==(e.negative|t.negative),"red works only with positives"),n(e.red&&e.red===t.red,"red works only with red numbers")},S.prototype.imod=function(e){return this.prime?this.prime.ireduce(e)._forceRed(this):e.umod(this.m)._forceRed(this)},S.prototype.neg=function(e){return e.isZero()?e.clone():this.m.sub(e)._forceRed(this)},S.prototype.add=function(e,t){this._verify2(e,t);var r=e.add(t);return r.cmp(this.m)>=0&&r.isub(this.m),r._forceRed(this)},S.prototype.iadd=function(e,t){this._verify2(e,t);var r=e.iadd(t);return r.cmp(this.m)>=0&&r.isub(this.m),r},S.prototype.sub=function(e,t){this._verify2(e,t);var r=e.sub(t);return r.cmpn(0)<0&&r.iadd(this.m),r._forceRed(this)},S.prototype.isub=function(e,t){this._verify2(e,t);var r=e.isub(t);return r.cmpn(0)<0&&r.iadd(this.m),r},S.prototype.shl=function(e,t){return this._verify1(e),this.imod(e.ushln(t))},S.prototype.imul=function(e,t){return this._verify2(e,t),this.imod(e.imul(t))},S.prototype.mul=function(e,t){return this._verify2(e,t),this.imod(e.mul(t))},S.prototype.isqr=function(e){return this.imul(e,e.clone())},S.prototype.sqr=function(e){return this.mul(e,e)},S.prototype.sqrt=function(e){if(e.isZero())return e.clone();var t=this.m.andln(3);if(n(t%2==1),3===t){var r=this.m.add(new a(1)).iushrn(2);return this.pow(e,r)}for(var i=this.m.subn(1),o=0;!i.isZero()&&0===i.andln(1);)o++,i.iushrn(1);n(!i.isZero());var s=new a(1).toRed(this),c=s.redNeg(),u=this.m.subn(1).iushrn(1),l=this.m.bitLength();for(l=new a(2*l*l).toRed(this);0!==this.pow(l,u).cmp(c);)l.redIAdd(c);for(var f=this.pow(l,i),d=this.pow(e,i.addn(1).iushrn(1)),h=this.pow(e,i),p=o;0!==h.cmp(s);){for(var y=h,m=0;0!==y.cmp(s);m++)y=y.redSqr();n(m<p);var g=this.pow(f,new a(1).iushln(p-m-1));d=d.redMul(g),f=g.redSqr(),h=h.redMul(f),p=m}return d},S.prototype.invm=function(e){var t=e._invmp(this.m);return 0!==t.negative?(t.negative=0,this.imod(t).redNeg()):this.imod(t)},S.prototype.pow=function(e,t){if(t.isZero())return new a(1).toRed(this);if(0===t.cmpn(1))return e.clone();var r=new Array(16);r[0]=new a(1).toRed(this),r[1]=e;for(var n=2;n<r.length;n++)r[n]=this.mul(r[n-1],e);var i=r[0],o=0,s=0,c=t.bitLength()%26;for(0===c&&(c=26),n=t.length-1;n>=0;n--){for(var u=t.words[n],l=c-1;l>=0;l--){var f=u>>l&1;i!==r[0]&&(i=this.sqr(i)),0!==f||0!==o?(o<<=1,o|=f,(4===++s||0===n&&0===l)&&(i=this.mul(i,r[o]),s=0,o=0)):s=0}c=26}return i},S.prototype.convertTo=function(e){var t=e.umod(this.m);return t===e?t.clone():t},S.prototype.convertFrom=function(e){var t=e.clone();return t.red=null,t},a.mont=function(e){return new E(e)},i(E,S),E.prototype.convertTo=function(e){return this.imod(e.ushln(this.shift))},E.prototype.convertFrom=function(e){var t=this.imod(e.mul(this.rinv));return t.red=null,t},E.prototype.imul=function(e,t){if(e.isZero()||t.isZero())return e.words[0]=0,e.length=1,e;var r=e.imul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),i=r.isub(n).iushrn(this.shift),a=i;return i.cmp(this.m)>=0?a=i.isub(this.m):i.cmpn(0)<0&&(a=i.iadd(this.m)),a._forceRed(this)},E.prototype.mul=function(e,t){if(e.isZero()||t.isZero())return new a(0)._forceRed(this);var r=e.mul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),i=r.isub(n).iushrn(this.shift),o=i;return i.cmp(this.m)>=0?o=i.isub(this.m):i.cmpn(0)<0&&(o=i.iadd(this.m)),o._forceRed(this)},E.prototype.invm=function(e){return this.imod(e._invmp(this.m).mul(this.r2))._forceRed(this)}}(e,this)}).call(this,r(40)(e))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(351))},function(e,t){var r,n,i=e.exports={};function a(){throw new Error("setTimeout has not been defined")}function o(){throw new Error("clearTimeout has not been defined")}function s(e){if(r===setTimeout)return setTimeout(e,0);if((r===a||!r)&&setTimeout)return r=setTimeout,setTimeout(e,0);try{return r(e,0)}catch(t){try{return r.call(null,e,0)}catch(t){return r.call(this,e,0)}}}!function(){try{r="function"==typeof setTimeout?setTimeout:a}catch(e){r=a}try{n="function"==typeof clearTimeout?clearTimeout:o}catch(e){n=o}}();var c,u=[],l=!1,f=-1;function d(){l&&c&&(l=!1,c.length?u=c.concat(u):f=-1,u.length&&h())}function h(){if(!l){var e=s(d);l=!0;for(var t=u.length;t;){for(c=u,u=[];++f<t;)c&&c[f].run();f=-1,t=u.length}c=null,l=!1,function(e){if(n===clearTimeout)return clearTimeout(e);if((n===o||!n)&&clearTimeout)return n=clearTimeout,clearTimeout(e);try{n(e)}catch(t){try{return n.call(null,e)}catch(t){return n.call(this,e)}}}(e)}}function p(e,t){this.fun=e,this.array=t}function y(){}i.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var r=1;r<arguments.length;r++)t[r-1]=arguments[r];u.push(new p(e,t)),1!==u.length||l||s(h)},p.prototype.run=function(){this.fun.apply(null,this.array)},i.title="browser",i.browser=!0,i.env={},i.argv=[],i.version="",i.versions={},i.on=y,i.addListener=y,i.once=y,i.off=y,i.removeListener=y,i.removeAllListeners=y,i.emit=y,i.prependListener=y,i.prependOnceListener=y,i.listeners=function(e){return[]},i.binding=function(e){throw new Error("process.binding is not supported")},i.cwd=function(){return"/"},i.chdir=function(e){throw new Error("process.chdir is not supported")},i.umask=function(){return 0}},function(e,t,r){"use strict";var n=r(19);Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"DataHandler",{enumerable:!0,get:function(){return i.default}}),Object.defineProperty(t,"DeleteFunctionHandler",{enumerable:!0,get:function(){return a.default}}),Object.defineProperty(t,"ExecuteQueryHandler",{enumerable:!0,get:function(){return o.default}}),Object.defineProperty(t,"InsertFunctionHandler",{enumerable:!0,get:function(){return s.default}}),Object.defineProperty(t,"JSONLDResolver",{enumerable:!0,get:function(){return c.default}}),Object.defineProperty(t,"MutationExpressionsHandler",{enumerable:!0,get:function(){return u.default}}),Object.defineProperty(t,"MutationFunctionHandler",{enumerable:!0,get:function(){return l.default}}),Object.defineProperty(t,"PathExpressionHandler",{enumerable:!0,get:function(){return f.default}}),Object.defineProperty(t,"PathProxy",{enumerable:!0,get:function(){return d.default}}),Object.defineProperty(t,"PathFactory",{enumerable:!0,get:function(){return h.default}}),Object.defineProperty(t,"ReplaceFunctionHandler",{enumerable:!0,get:function(){return p.default}}),Object.defineProperty(t,"SetFunctionHandler",{enumerable:!0,get:function(){return y.default}}),Object.defineProperty(t,"SparqlHandler",{enumerable:!0,get:function(){return m.default}}),Object.defineProperty(t,"SubjectHandler",{enumerable:!0,get:function(){return g.default}}),Object.defineProperty(t,"StringToLDflexHandler",{enumerable:!0,get:function(){return b.default}}),Object.defineProperty(t,"defaultHandlers",{enumerable:!0,get:function(){return v.default}}),Object.defineProperty(t,"getFirstItem",{enumerable:!0,get:function(){return _.getFirstItem}}),Object.defineProperty(t,"iteratorFor",{enumerable:!0,get:function(){return _.iteratorFor}}),Object.defineProperty(t,"getThen",{enumerable:!0,get:function(){return w.getThen}}),Object.defineProperty(t,"toIterablePromise",{enumerable:!0,get:function(){return w.toIterablePromise}});var i=n(r(115)),a=n(r(116)),o=n(r(119)),s=n(r(123)),c=n(r(124)),u=n(r(126)),l=n(r(85)),f=n(r(127)),d=n(r(128)),h=n(r(311)),p=n(r(133)),y=n(r(132)),m=n(r(131)),g=n(r(130)),b=n(r(134)),v=n(r(129)),_=r(87),w=r(64)},function(e,t,r){(function(e){var n=void 0!==e&&e||"undefined"!=typeof self&&self||window,i=Function.prototype.apply;function a(e,t){this._id=e,this._clearFn=t}t.setTimeout=function(){return new a(i.call(setTimeout,n,arguments),clearTimeout)},t.setInterval=function(){return new a(i.call(setInterval,n,arguments),clearInterval)},t.clearTimeout=t.clearInterval=function(e){e&&e.close()},a.prototype.unref=a.prototype.ref=function(){},a.prototype.close=function(){this._clearFn.call(n,this._id)},t.enroll=function(e,t){clearTimeout(e._idleTimeoutId),e._idleTimeout=t},t.unenroll=function(e){clearTimeout(e._idleTimeoutId),e._idleTimeout=-1},t._unrefActive=t.active=function(e){clearTimeout(e._idleTimeoutId);var t=e._idleTimeout;t>=0&&(e._idleTimeoutId=setTimeout(function(){e._onTimeout&&e._onTimeout()},t))},r(333),t.setImmediate="undefined"!=typeof self&&self.setImmediate||void 0!==e&&e.setImmediate||this&&this.setImmediate,t.clearImmediate="undefined"!=typeof self&&self.clearImmediate||void 0!==e&&e.clearImmediate||this&&this.clearImmediate}).call(this,r(9))},function(e,t){function r(e,t){if(!e)throw new Error(t||"Assertion failed")}e.exports=r,r.equal=function(e,t,r){if(e!=t)throw new Error(r||"Assertion failed: "+e+" != "+t)}},function(e,t,r){"use strict";var n=t,i=r(11),a=r(16),o=r(266);n.assert=a,n.toArray=o.toArray,n.zero2=o.zero2,n.toHex=o.toHex,n.encode=o.encode,n.getNAF=function(e,t){for(var r=[],n=1<<t+1,i=e.clone();i.cmpn(1)>=0;){var a;if(i.isOdd()){var o=i.andln(n-1);a=o>(n>>1)-1?(n>>1)-o:o,i.isubn(a)}else a=0;r.push(a);for(var s=0!==i.cmpn(0)&&0===i.andln(n-1)?t+1:1,c=1;c<s;c++)r.push(0);i.iushrn(s)}return r},n.getJSF=function(e,t){var r=[[],[]];e=e.clone(),t=t.clone();for(var n=0,i=0;e.cmpn(-n)>0||t.cmpn(-i)>0;){var a,o,s,c=e.andln(3)+n&3,u=t.andln(3)+i&3;if(3===c&&(c=-1),3===u&&(u=-1),0==(1&c))a=0;else a=3!==(s=e.andln(7)+n&7)&&5!==s||2!==u?c:-c;if(r[0].push(a),0==(1&u))o=0;else o=3!==(s=t.andln(7)+i&7)&&5!==s||2!==c?u:-u;r[1].push(o),2*n===a+1&&(n=1-n),2*i===o+1&&(i=1-i),e.iushrn(1),t.iushrn(1)}return r},n.cachedProperty=function(e,t,r){var n="_"+t;e.prototype[t]=function(){return void 0!==this[n]?this[n]:this[n]=r.call(this)}},n.parseBytes=function(e){return"string"==typeof e?n.toArray(e,"hex"):e},n.intFromLE=function(e){return new i(e,"hex","le")}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(5),i=r(25);var a,o,s;t.TRUE_STR='"true"^^xsd:boolean',t.FALSE_STR='"false"^^xsd:boolean',t.EVB_ERR_STR='"not an dateTime"^^xsd:dateTime',function(e){e.XSD_ANY_URI="http://www.w3.org/2001/XMLSchema#anyURI",e.XSD_STRING="http://www.w3.org/2001/XMLSchema#string",e.RDF_LANG_STRING="http://www.w3.org/1999/02/22-rdf-syntax-ns#langString",e.XSD_BOOLEAN="http://www.w3.org/2001/XMLSchema#boolean",e.XSD_DATE_TIME="http://www.w3.org/2001/XMLSchema#dateTime",e.XSD_DATE="http://www.w3.org/2001/XMLSchema#date",e.XSD_INTEGER="http://www.w3.org/2001/XMLSchema#integer",e.XSD_DECIMAL="http://www.w3.org/2001/XMLSchema#decimal",e.XSD_FLOAT="http://www.w3.org/2001/XMLSchema#float",e.XSD_DOUBLE="http://www.w3.org/2001/XMLSchema#double",e.XSD_NON_POSITIVE_INTEGER="http://www.w3.org/2001/XMLSchema#nonPositiveInteger",e.XSD_NEGATIVE_INTEGER="http://www.w3.org/2001/XMLSchema#negativeInteger",e.XSD_LONG="http://www.w3.org/2001/XMLSchema#long",e.XSD_INT="http://www.w3.org/2001/XMLSchema#int",e.XSD_SHORT="http://www.w3.org/2001/XMLSchema#short",e.XSD_BYTE="http://www.w3.org/2001/XMLSchema#byte",e.XSD_NON_NEGATIVE_INTEGER="http://www.w3.org/2001/XMLSchema#nonNegativeInteger",e.XSD_UNSIGNED_LONG="http://www.w3.org/2001/XMLSchema#unsignedLong",e.XSD_UNSIGNED_INT="http://www.w3.org/2001/XMLSchema#unsignedInt",e.XSD_UNSIGNED_SHORT="http://www.w3.org/2001/XMLSchema#unsignedShort",e.XSD_UNSIGNED_BYTE="http://www.w3.org/2001/XMLSchema#unsignedByte",e.XSD_POSITIVE_INTEGER="http://www.w3.org/2001/XMLSchema#positiveInteger",e.XSD_DAYTIME_DURATION="http://www.w3.org/2001/XMLSchema#dayTimeDuration"}(a=t.TypeURL||(t.TypeURL={})),t.make=function(e){return n.namedNode(e)},function(e){e.XSD_INTEGER="http://www.w3.org/2001/XMLSchema#integer",e.XSD_DECIMAL="http://www.w3.org/2001/XMLSchema#decimal",e.XSD_FLOAT="http://www.w3.org/2001/XMLSchema#float",e.XSD_DOUBLE="http://www.w3.org/2001/XMLSchema#double",e.XSD_NON_POSITIVE_INTEGER="http://www.w3.org/2001/XMLSchema#nonPositiveInteger",e.XSD_NEGATIVE_INTEGER="http://www.w3.org/2001/XMLSchema#negativeInteger",e.XSD_LONG="http://www.w3.org/2001/XMLSchema#long",e.XSD_INT="http://www.w3.org/2001/XMLSchema#int",e.XSD_SHORT="http://www.w3.org/2001/XMLSchema#short",e.XSD_BYTE="http://www.w3.org/2001/XMLSchema#byte",e.XSD_NON_NEGATIVE_INTEGER="http://www.w3.org/2001/XMLSchema#nonNegativeInteger",e.XSD_UNSIGNED_LONG="http://www.w3.org/2001/XMLSchema#unsignedLong",e.XSD_UNSIGNED_INT="http://www.w3.org/2001/XMLSchema#unsignedInt",e.XSD_UNSIGNED_SHORT="http://www.w3.org/2001/XMLSchema#unsignedShort",e.XSD_UNSIGNED_BYTE="http://www.w3.org/2001/XMLSchema#unsignedByte",e.XSD_POSITIVE_INTEGER="http://www.w3.org/2001/XMLSchema#positiveInteger"}(o=t.NumericTypeURL||(t.NumericTypeURL={})),function(e){e.XSD_NON_POSITIVE_INTEGER="http://www.w3.org/2001/XMLSchema#nonPositiveInteger",e.XSD_NEGATIVE_INTEGER="http://www.w3.org/2001/XMLSchema#negativeInteger",e.XSD_LONG="http://www.w3.org/2001/XMLSchema#long",e.XSD_INT="http://www.w3.org/2001/XMLSchema#int",e.XSD_SHORT="http://www.w3.org/2001/XMLSchema#short",e.XSD_BYTE="http://www.w3.org/2001/XMLSchema#byte",e.XSD_NON_NEGATIVE_INTEGER="http://www.w3.org/2001/XMLSchema#nonNegativeInteger",e.XSD_UNSIGNED_LONG="http://www.w3.org/2001/XMLSchema#unsignedLong",e.XSD_UNSIGNED_INT="http://www.w3.org/2001/XMLSchema#unsignedInt",e.XSD_UNSIGNED_SHORT="http://www.w3.org/2001/XMLSchema#unsignedShort",e.XSD_UNSIGNED_BYTE="http://www.w3.org/2001/XMLSchema#unsignedByte",e.XSD_POSITIVE_INTEGER="http://www.w3.org/2001/XMLSchema#positiveInteger"}(s=t.DerivedIntegerTypeURL||(t.DerivedIntegerTypeURL={})),t.NumericTypeURLs=i.Set(Object.values(o)),t.DerivedIntegerTypeURLs=i.Set(Object.values(s)),t.commonTerms={true:n.literal("true",n.namedNode(a.XSD_BOOLEAN)),false:n.literal("false",n.namedNode(a.XSD_BOOLEAN))},t.PrimitiveNumericTypes=i.Set(["integer","decimal","float","double"]),t.type=function(e){switch(e){case null:case void 0:case"":case a.XSD_ANY_URI:case a.XSD_STRING:return"string";case a.RDF_LANG_STRING:return"langString";case a.XSD_DATE_TIME:return"date";case a.XSD_BOOLEAN:return"boolean";case a.XSD_DECIMAL:return"decimal";case a.XSD_FLOAT:return"float";case a.XSD_DOUBLE:return"double";case a.XSD_INTEGER:case a.XSD_NON_POSITIVE_INTEGER:case a.XSD_NEGATIVE_INTEGER:case a.XSD_LONG:case a.XSD_INT:case a.XSD_SHORT:case a.XSD_BYTE:case a.XSD_NON_NEGATIVE_INTEGER:case a.XSD_UNSIGNED_LONG:case a.XSD_UNSIGNED_INT:case a.XSD_UNSIGNED_SHORT:case a.XSD_UNSIGNED_BYTE:case a.XSD_POSITIVE_INTEGER:return"integer";default:return"other"}};const c=i.Map([["integer",a.XSD_INTEGER],["float",a.XSD_FLOAT],["double",a.XSD_DOUBLE],["decimal",a.XSD_DECIMAL]]);var u,l,f;t.decategorize=function(e){return c.get(e)},function(e){e.NOT="!",e.UMINUS="UMINUS",e.UPLUS="UPLUS",e.EQUAL="=",e.NOT_EQUAL="!=",e.LT="<",e.GT=">",e.LTE="<=",e.GTE=">=",e.MULTIPLICATION="*",e.DIVISION="/",e.ADDITION="+",e.SUBTRACTION="-",e.IS_IRI="isiri",e.IS_BLANK="isblank",e.IS_LITERAL="isliteral",e.IS_NUMERIC="isnumeric",e.STR="str",e.LANG="lang",e.DATATYPE="datatype",e.STRDT="strdt",e.STRLANG="strlang",e.UUID="uuid",e.STRUUID="struuid",e.STRLEN="strlen",e.SUBSTR="substr",e.UCASE="ucase",e.LCASE="lcase",e.STRSTARTS="strstarts",e.STRENDS="strends",e.CONTAINS="contains",e.STRBEFORE="strbefore",e.STRAFTER="strafter",e.ENCODE_FOR_URI="encode_for_uri",e.LANG_MATCHES="langmatches",e.REGEX="regex",e.REPLACE="replace",e.ABS="abs",e.ROUND="round",e.CEIL="ceil",e.FLOOR="floor",e.RAND="rand",e.YEAR="year",e.MONTH="month",e.DAY="day",e.HOURS="hours",e.MINUTES="minutes",e.SECONDS="seconds",e.TIMEZONE="timezone",e.TZ="tz",e.MD5="md5",e.SHA1="sha1",e.SHA256="sha256",e.SHA384="sha384",e.SHA512="sha512"}(u=t.RegularOperator||(t.RegularOperator={})),function(e){e.BOUND="bound",e.IF="if",e.COALESCE="coalesce",e.LOGICAL_OR="||",e.LOGICAL_AND="&&",e.SAME_TERM="sameterm",e.IN="in",e.NOT_IN="notin",e.CONCAT="concat",e.NOW="now",e.IRI="iri",e.URI="uri",e.BNODE="BNODE"}(l=t.SpecialOperator||(t.SpecialOperator={})),t.RegularOperators=i.Set(Object.values(u)),t.SpecialOperators=i.Set(Object.values(l)),t.Operators=t.RegularOperators.union(t.SpecialOperators),function(e){e.COUNT="count",e.SUM="sum",e.MIN="min",e.MAX="max",e.AVG="avg",e.GROUP_CONCAT="group_concat",e.SAMPLE="sample"}(f=t.SetFunction||(t.SetFunction={})),t.SetFunctions=i.Set(Object.values(f)),t.NamedOperators=i.Set([a.XSD_STRING,a.XSD_FLOAT,a.XSD_DOUBLE,a.XSD_DECIMAL,a.XSD_INTEGER,a.XSD_DATE_TIME,a.XSD_DATE,a.XSD_BOOLEAN])},function(e,t){e.exports=function(e){return e&&e.__esModule?e:{default:e}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});t.NodeValueHandlerAdapter=class{constructor(e,t,r){this.targetKind=e,this.util=t,this.settings=r}}},function(e,t,r){"use strict";var n=r(16),i=r(1);function a(e,t){return 55296==(64512&e.charCodeAt(t))&&(!(t<0||t+1>=e.length)&&56320==(64512&e.charCodeAt(t+1)))}function o(e){return(e>>>24|e>>>8&65280|e<<8&16711680|(255&e)<<24)>>>0}function s(e){return 1===e.length?"0"+e:e}function c(e){return 7===e.length?"0"+e:6===e.length?"00"+e:5===e.length?"000"+e:4===e.length?"0000"+e:3===e.length?"00000"+e:2===e.length?"000000"+e:1===e.length?"0000000"+e:e}t.inherits=i,t.toArray=function(e,t){if(Array.isArray(e))return e.slice();if(!e)return[];var r=[];if("string"==typeof e)if(t){if("hex"===t)for((e=e.replace(/[^a-z0-9]+/gi,"")).length%2!=0&&(e="0"+e),i=0;i<e.length;i+=2)r.push(parseInt(e[i]+e[i+1],16))}else for(var n=0,i=0;i<e.length;i++){var o=e.charCodeAt(i);o<128?r[n++]=o:o<2048?(r[n++]=o>>6|192,r[n++]=63&o|128):a(e,i)?(o=65536+((1023&o)<<10)+(1023&e.charCodeAt(++i)),r[n++]=o>>18|240,r[n++]=o>>12&63|128,r[n++]=o>>6&63|128,r[n++]=63&o|128):(r[n++]=o>>12|224,r[n++]=o>>6&63|128,r[n++]=63&o|128)}else for(i=0;i<e.length;i++)r[i]=0|e[i];return r},t.toHex=function(e){for(var t="",r=0;r<e.length;r++)t+=s(e[r].toString(16));return t},t.htonl=o,t.toHex32=function(e,t){for(var r="",n=0;n<e.length;n++){var i=e[n];"little"===t&&(i=o(i)),r+=c(i.toString(16))}return r},t.zero2=s,t.zero8=c,t.join32=function(e,t,r,i){var a=r-t;n(a%4==0);for(var o=new Array(a/4),s=0,c=t;s<o.length;s++,c+=4){var u;u="big"===i?e[c]<<24|e[c+1]<<16|e[c+2]<<8|e[c+3]:e[c+3]<<24|e[c+2]<<16|e[c+1]<<8|e[c],o[s]=u>>>0}return o},t.split32=function(e,t){for(var r=new Array(4*e.length),n=0,i=0;n<e.length;n++,i+=4){var a=e[n];"big"===t?(r[i]=a>>>24,r[i+1]=a>>>16&255,r[i+2]=a>>>8&255,r[i+3]=255&a):(r[i+3]=a>>>24,r[i+2]=a>>>16&255,r[i+1]=a>>>8&255,r[i]=255&a)}return r},t.rotr32=function(e,t){return e>>>t|e<<32-t},t.rotl32=function(e,t){return e<<t|e>>>32-t},t.sum32=function(e,t){return e+t>>>0},t.sum32_3=function(e,t,r){return e+t+r>>>0},t.sum32_4=function(e,t,r,n){return e+t+r+n>>>0},t.sum32_5=function(e,t,r,n,i){return e+t+r+n+i>>>0},t.sum64=function(e,t,r,n){var i=e[t],a=n+e[t+1]>>>0,o=(a<n?1:0)+r+i;e[t]=o>>>0,e[t+1]=a},t.sum64_hi=function(e,t,r,n){return(t+n>>>0<t?1:0)+e+r>>>0},t.sum64_lo=function(e,t,r,n){return t+n>>>0},t.sum64_4_hi=function(e,t,r,n,i,a,o,s){var c=0,u=t;return c+=(u=u+n>>>0)<t?1:0,c+=(u=u+a>>>0)<a?1:0,e+r+i+o+(c+=(u=u+s>>>0)<s?1:0)>>>0},t.sum64_4_lo=function(e,t,r,n,i,a,o,s){return t+n+a+s>>>0},t.sum64_5_hi=function(e,t,r,n,i,a,o,s,c,u){var l=0,f=t;return l+=(f=f+n>>>0)<t?1:0,l+=(f=f+a>>>0)<a?1:0,l+=(f=f+s>>>0)<s?1:0,e+r+i+o+c+(l+=(f=f+u>>>0)<u?1:0)>>>0},t.sum64_5_lo=function(e,t,r,n,i,a,o,s,c,u){return t+n+a+s+u>>>0},t.rotr64_hi=function(e,t,r){return(t<<32-r|e>>>r)>>>0},t.rotr64_lo=function(e,t,r){return(e<<32-r|t>>>r)>>>0},t.shr64_hi=function(e,t,r){return e>>>r},t.shr64_lo=function(e,t,r){return(e<<32-r|t>>>r)>>>0}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});class n extends Error{}t.ExpressionError=n,t.isExpressionError=function(e){return e instanceof n};t.InvalidLexicalForm=class extends n{constructor(e){super(`Invalid lexical form '${i(e)}'`),this.arg=e}};t.UnboundVariableError=class extends n{constructor(e,t){super(`Unbound variable '${i(e)}'`),this.variable=e,this.bindings=t}};t.EBVCoercionError=class extends n{constructor(e){super(`Cannot coerce term to EBV '${i(e)}'`),this.arg=e}};t.RDFEqualTypeError=class extends n{constructor(e){super("Equality test for literals with unsupported datatypes"),this.args=e}};t.CoalesceError=class extends n{constructor(e){super("All COALESCE arguments threw errors"),this.errors=e}};t.InError=class extends n{constructor(e){super("Some argument to IN errorred and none where equal. "+e.map(e=>`(${e.toString()}) `).join("and ")),this.errors=e}};t.InvalidArgumentTypes=class extends n{constructor(e,t){super(`Argument types not valid for operator: '${i(t)}' with '${i(e)}`),this.args=e,this.op=t}};t.CastError=class extends n{constructor(e,t){super(`Invalid cast: '${i(e)}' to '${i(t)}'`),this.arg=e}};t.InvalidTimezoneCall=class extends n{constructor(e){super(`TIMEZONE call on ${e} which has no timezone`),this.dateString=e}};t.IncompatibleLanguageOperation=class extends n{constructor(e,t){super(`Operation on incompatible language literals '${i(e)}' and '${i(t)}'`),this.arg1=e,this.arg2=t}};t.EmptyAggregateError=class extends n{constructor(){super("Empty aggregate expression")}};t.UnexpectedError=class extends Error{constructor(e,t){super(`Programmer Error '${e}'`),this.payload=t}};t.UnimplementedError=class extends Error{constructor(e){super(`Unimplemented feature '${e}!'`)}};t.InvalidArity=class extends Error{constructor(e,t){super(`The number of args does not match the arity of the operator '${i(t)}'.`),this.args=e,this.op=t}};t.InvalidExpression=class extends Error{constructor(e){super(`Invalid SPARQL Expression '${i(e)}'`)}};t.InvalidExpressionType=class extends Error{constructor(e){super(`Invalid expression type for SPARQL Expression '${i(e)}'`),this.expr=e}};t.InvalidTermType=class extends Error{constructor(e){super(`Invalid term type for term '${i(e)}'`),this.term=e}};t.UnknownOperator=class extends Error{constructor(e){super(`Unknown operator: '${i(e)}`)}};t.UnknownNamedOperator=class extends Error{constructor(e){super(`Unknown named operator: '${i(e)}'`)}};t.NoAggregator=class extends Error{constructor(e){super(`Aggregate expression ${i(e)} found, but no aggregate hook provided.`)}};function i(e){return JSON.stringify(e)}t.NoExistenceHook=class extends Error{constructor(){super("EXISTS found, but no existence hook provided.")}}},function(e,t,r){"use strict";function n(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}Object.defineProperty(t,"__esModule",{value:!0}),n(r(308)),n(r(125))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(352))},function(e,t,r){e.exports=function(){"use strict";var e=Array.prototype.slice;function t(e,t){t&&(e.prototype=Object.create(t.prototype)),e.prototype.constructor=e}function r(e){return o(e)?e:Q(e)}function n(e){return s(e)?e:X(e)}function i(e){return c(e)?e:$(e)}function a(e){return o(e)&&!u(e)?e:J(e)}function o(e){return!(!e||!e[f])}function s(e){return!(!e||!e[d])}function c(e){return!(!e||!e[h])}function u(e){return s(e)||c(e)}function l(e){return!(!e||!e[p])}t(n,r),t(i,r),t(a,r),r.isIterable=o,r.isKeyed=s,r.isIndexed=c,r.isAssociative=u,r.isOrdered=l,r.Keyed=n,r.Indexed=i,r.Set=a;var f="@@__IMMUTABLE_ITERABLE__@@",d="@@__IMMUTABLE_KEYED__@@",h="@@__IMMUTABLE_INDEXED__@@",p="@@__IMMUTABLE_ORDERED__@@",y=5,m=1<<y,g=m-1,b={},v={value:!1},_={value:!1};function w(e){return e.value=!1,e}function S(e){e&&(e.value=!0)}function E(){}function x(e,t){t=t||0;for(var r=Math.max(0,e.length-t),n=new Array(r),i=0;i<r;i++)n[i]=e[i+t];return n}function T(e){return void 0===e.size&&(e.size=e.__iterate(A)),e.size}function O(e,t){if("number"!=typeof t){var r=t>>>0;if(""+r!==t||4294967295===r)return NaN;t=r}return t<0?T(e)+t:t}function A(){return!0}function I(e,t,r){return(0===e||void 0!==r&&e<=-r)&&(void 0===t||void 0!==r&&t>=r)}function N(e,t){return k(e,t,0)}function R(e,t){return k(e,t,t)}function k(e,t,r){return void 0===e?r:e<0?Math.max(0,t+e):void 0===t?e:Math.min(t,e)}var P=0,j=1,D=2,C="function"==typeof Symbol&&Symbol.iterator,M="@@iterator",L=C||M;function q(e){this.next=e}function F(e,t,r,n){var i=0===e?t:1===e?r:[t,r];return n?n.value=i:n={value:i,done:!1},n}function B(){return{value:void 0,done:!0}}function U(e){return!!z(e)}function V(e){return e&&"function"==typeof e.next}function H(e){var t=z(e);return t&&t.call(e)}function z(e){var t=e&&(C&&e[C]||e[M]);if("function"==typeof t)return t}function G(e){return e&&"number"==typeof e.length}function Q(e){return null==e?ae():o(e)?e.toSeq():function(e){var t=ce(e)||"object"==typeof e&&new te(e);if(!t)throw new TypeError("Expected Array or iterable object of values, or keyed object: "+e);return t}(e)}function X(e){return null==e?ae().toKeyedSeq():o(e)?s(e)?e.toSeq():e.fromEntrySeq():oe(e)}function $(e){return null==e?ae():o(e)?s(e)?e.entrySeq():e.toIndexedSeq():se(e)}function J(e){return(null==e?ae():o(e)?s(e)?e.entrySeq():e:se(e)).toSetSeq()}q.prototype.toString=function(){return"[Iterator]"},q.KEYS=P,q.VALUES=j,q.ENTRIES=D,q.prototype.inspect=q.prototype.toSource=function(){return this.toString()},q.prototype[L]=function(){return this},t(Q,r),Q.of=function(){return Q(arguments)},Q.prototype.toSeq=function(){return this},Q.prototype.toString=function(){return this.__toString("Seq {","}")},Q.prototype.cacheResult=function(){return!this._cache&&this.__iterateUncached&&(this._cache=this.entrySeq().toArray(),this.size=this._cache.length),this},Q.prototype.__iterate=function(e,t){return ue(this,e,t,!0)},Q.prototype.__iterator=function(e,t){return le(this,e,t,!0)},t(X,Q),X.prototype.toKeyedSeq=function(){return this},t($,Q),$.of=function(){return $(arguments)},$.prototype.toIndexedSeq=function(){return this},$.prototype.toString=function(){return this.__toString("Seq [","]")},$.prototype.__iterate=function(e,t){return ue(this,e,t,!1)},$.prototype.__iterator=function(e,t){return le(this,e,t,!1)},t(J,Q),J.of=function(){return J(arguments)},J.prototype.toSetSeq=function(){return this},Q.isSeq=ie,Q.Keyed=X,Q.Set=J,Q.Indexed=$;var Y,K,W,Z="@@__IMMUTABLE_SEQ__@@";function ee(e){this._array=e,this.size=e.length}function te(e){var t=Object.keys(e);this._object=e,this._keys=t,this.size=t.length}function re(e){this._iterable=e,this.size=e.length||e.size}function ne(e){this._iterator=e,this._iteratorCache=[]}function ie(e){return!(!e||!e[Z])}function ae(){return Y||(Y=new ee([]))}function oe(e){var t=Array.isArray(e)?new ee(e).fromEntrySeq():V(e)?new ne(e).fromEntrySeq():U(e)?new re(e).fromEntrySeq():"object"==typeof e?new te(e):void 0;if(!t)throw new TypeError("Expected Array or iterable object of [k, v] entries, or keyed object: "+e);return t}function se(e){var t=ce(e);if(!t)throw new TypeError("Expected Array or iterable object of values: "+e);return t}function ce(e){return G(e)?new ee(e):V(e)?new ne(e):U(e)?new re(e):void 0}function ue(e,t,r,n){var i=e._cache;if(i){for(var a=i.length-1,o=0;o<=a;o++){var s=i[r?a-o:o];if(!1===t(s[1],n?s[0]:o,e))return o+1}return o}return e.__iterateUncached(t,r)}function le(e,t,r,n){var i=e._cache;if(i){var a=i.length-1,o=0;return new q(function(){var e=i[r?a-o:o];return o++>a?{value:void 0,done:!0}:F(t,n?e[0]:o-1,e[1])})}return e.__iteratorUncached(t,r)}function fe(e,t){return t?function e(t,r,n,i){return Array.isArray(r)?t.call(i,n,$(r).map(function(n,i){return e(t,n,i,r)})):he(r)?t.call(i,n,X(r).map(function(n,i){return e(t,n,i,r)})):r}(t,e,"",{"":e}):de(e)}function de(e){return Array.isArray(e)?$(e).map(de).toList():he(e)?X(e).map(de).toMap():e}function he(e){return e&&(e.constructor===Object||void 0===e.constructor)}function pe(e,t){if(e===t||e!=e&&t!=t)return!0;if(!e||!t)return!1;if("function"==typeof e.valueOf&&"function"==typeof t.valueOf){if((e=e.valueOf())===(t=t.valueOf())||e!=e&&t!=t)return!0;if(!e||!t)return!1}return!("function"!=typeof e.equals||"function"!=typeof t.equals||!e.equals(t))}function ye(e,t){if(e===t)return!0;if(!o(t)||void 0!==e.size&&void 0!==t.size&&e.size!==t.size||void 0!==e.__hash&&void 0!==t.__hash&&e.__hash!==t.__hash||s(e)!==s(t)||c(e)!==c(t)||l(e)!==l(t))return!1;if(0===e.size&&0===t.size)return!0;var r=!u(e);if(l(e)){var n=e.entries();return t.every(function(e,t){var i=n.next().value;return i&&pe(i[1],e)&&(r||pe(i[0],t))})&&n.next().done}var i=!1;if(void 0===e.size)if(void 0===t.size)"function"==typeof e.cacheResult&&e.cacheResult();else{i=!0;var a=e;e=t,t=a}var f=!0,d=t.__iterate(function(t,n){if(r?!e.has(t):i?!pe(t,e.get(n,b)):!pe(e.get(n,b),t))return f=!1,!1});return f&&e.size===d}function me(e,t){if(!(this instanceof me))return new me(e,t);if(this._value=e,this.size=void 0===t?1/0:Math.max(0,t),0===this.size){if(K)return K;K=this}}function ge(e,t){if(!e)throw new Error(t)}function be(e,t,r){if(!(this instanceof be))return new be(e,t,r);if(ge(0!==r,"Cannot step a Range by 0"),e=e||0,void 0===t&&(t=1/0),r=void 0===r?1:Math.abs(r),t<e&&(r=-r),this._start=e,this._end=t,this._step=r,this.size=Math.max(0,Math.ceil((t-e)/r-1)+1),0===this.size){if(W)return W;W=this}}function ve(){throw TypeError("Abstract")}function _e(){}function we(){}function Se(){}Q.prototype[Z]=!0,t(ee,$),ee.prototype.get=function(e,t){return this.has(e)?this._array[O(this,e)]:t},ee.prototype.__iterate=function(e,t){for(var r=this._array,n=r.length-1,i=0;i<=n;i++)if(!1===e(r[t?n-i:i],i,this))return i+1;return i},ee.prototype.__iterator=function(e,t){var r=this._array,n=r.length-1,i=0;return new q(function(){return i>n?{value:void 0,done:!0}:F(e,i,r[t?n-i++:i++])})},t(te,X),te.prototype.get=function(e,t){return void 0===t||this.has(e)?this._object[e]:t},te.prototype.has=function(e){return this._object.hasOwnProperty(e)},te.prototype.__iterate=function(e,t){for(var r=this._object,n=this._keys,i=n.length-1,a=0;a<=i;a++){var o=n[t?i-a:a];if(!1===e(r[o],o,this))return a+1}return a},te.prototype.__iterator=function(e,t){var r=this._object,n=this._keys,i=n.length-1,a=0;return new q(function(){var o=n[t?i-a:a];return a++>i?{value:void 0,done:!0}:F(e,o,r[o])})},te.prototype[p]=!0,t(re,$),re.prototype.__iterateUncached=function(e,t){if(t)return this.cacheResult().__iterate(e,t);var r=H(this._iterable),n=0;if(V(r))for(var i;!(i=r.next()).done&&!1!==e(i.value,n++,this););return n},re.prototype.__iteratorUncached=function(e,t){if(t)return this.cacheResult().__iterator(e,t);var r=H(this._iterable);if(!V(r))return new q(B);var n=0;return new q(function(){var t=r.next();return t.done?t:F(e,n++,t.value)})},t(ne,$),ne.prototype.__iterateUncached=function(e,t){if(t)return this.cacheResult().__iterate(e,t);for(var r,n=this._iterator,i=this._iteratorCache,a=0;a<i.length;)if(!1===e(i[a],a++,this))return a;for(;!(r=n.next()).done;){var o=r.value;if(i[a]=o,!1===e(o,a++,this))break}return a},ne.prototype.__iteratorUncached=function(e,t){if(t)return this.cacheResult().__iterator(e,t);var r=this._iterator,n=this._iteratorCache,i=0;return new q(function(){if(i>=n.length){var t=r.next();if(t.done)return t;n[i]=t.value}return F(e,i,n[i++])})},t(me,$),me.prototype.toString=function(){return 0===this.size?"Repeat []":"Repeat [ "+this._value+" "+this.size+" times ]"},me.prototype.get=function(e,t){return this.has(e)?this._value:t},me.prototype.includes=function(e){return pe(this._value,e)},me.prototype.slice=function(e,t){var r=this.size;return I(e,t,r)?this:new me(this._value,R(t,r)-N(e,r))},me.prototype.reverse=function(){return this},me.prototype.indexOf=function(e){return pe(this._value,e)?0:-1},me.prototype.lastIndexOf=function(e){return pe(this._value,e)?this.size:-1},me.prototype.__iterate=function(e,t){for(var r=0;r<this.size;r++)if(!1===e(this._value,r,this))return r+1;return r},me.prototype.__iterator=function(e,t){var r=this,n=0;return new q(function(){return n<r.size?F(e,n++,r._value):{value:void 0,done:!0}})},me.prototype.equals=function(e){return e instanceof me?pe(this._value,e._value):ye(e)},t(be,$),be.prototype.toString=function(){return 0===this.size?"Range []":"Range [ "+this._start+"..."+this._end+(1!==this._step?" by "+this._step:"")+" ]"},be.prototype.get=function(e,t){return this.has(e)?this._start+O(this,e)*this._step:t},be.prototype.includes=function(e){var t=(e-this._start)/this._step;return t>=0&&t<this.size&&t===Math.floor(t)},be.prototype.slice=function(e,t){return I(e,t,this.size)?this:(e=N(e,this.size),(t=R(t,this.size))<=e?new be(0,0):new be(this.get(e,this._end),this.get(t,this._end),this._step))},be.prototype.indexOf=function(e){var t=e-this._start;if(t%this._step==0){var r=t/this._step;if(r>=0&&r<this.size)return r}return-1},be.prototype.lastIndexOf=function(e){return this.indexOf(e)},be.prototype.__iterate=function(e,t){for(var r=this.size-1,n=this._step,i=t?this._start+r*n:this._start,a=0;a<=r;a++){if(!1===e(i,a,this))return a+1;i+=t?-n:n}return a},be.prototype.__iterator=function(e,t){var r=this.size-1,n=this._step,i=t?this._start+r*n:this._start,a=0;return new q(function(){var o=i;return i+=t?-n:n,a>r?{value:void 0,done:!0}:F(e,a++,o)})},be.prototype.equals=function(e){return e instanceof be?this._start===e._start&&this._end===e._end&&this._step===e._step:ye(this,e)},t(ve,r),t(_e,ve),t(we,ve),t(Se,ve),ve.Keyed=_e,ve.Indexed=we,ve.Set=Se;var Ee="function"==typeof Math.imul&&-2===Math.imul(4294967295,2)?Math.imul:function(e,t){var r=65535&(e|=0),n=65535&(t|=0);return r*n+((e>>>16)*n+r*(t>>>16)<<16>>>0)|0};function xe(e){return e>>>1&1073741824|3221225471&e}function Te(e){if(!1===e||null==e)return 0;if("function"==typeof e.valueOf&&(!1===(e=e.valueOf())||null==e))return 0;if(!0===e)return 1;var t=typeof e;if("number"===t){if(e!=e||e===1/0)return 0;var r=0|e;for(r!==e&&(r^=4294967295*e);e>4294967295;)r^=e/=4294967295;return xe(r)}if("string"===t)return e.length>je?function(e){var t=Me[e];return void 0===t&&(t=Oe(e),Ce===De&&(Ce=0,Me={}),Ce++,Me[e]=t),t}(e):Oe(e);if("function"==typeof e.hashCode)return e.hashCode();if("object"===t)return function(e){var t;if(Re&&void 0!==(t=Ae.get(e)))return t;if(void 0!==(t=e[Pe]))return t;if(!Ne){if(void 0!==(t=e.propertyIsEnumerable&&e.propertyIsEnumerable[Pe]))return t;if(void 0!==(t=function(e){if(e&&e.nodeType>0)switch(e.nodeType){case 1:return e.uniqueID;case 9:return e.documentElement&&e.documentElement.uniqueID}}(e)))return t}if(t=++ke,1073741824&ke&&(ke=0),Re)Ae.set(e,t);else{if(void 0!==Ie&&!1===Ie(e))throw new Error("Non-extensible objects are not allowed as keys.");if(Ne)Object.defineProperty(e,Pe,{enumerable:!1,configurable:!1,writable:!1,value:t});else if(void 0!==e.propertyIsEnumerable&&e.propertyIsEnumerable===e.constructor.prototype.propertyIsEnumerable)e.propertyIsEnumerable=function(){return this.constructor.prototype.propertyIsEnumerable.apply(this,arguments)},e.propertyIsEnumerable[Pe]=t;else{if(void 0===e.nodeType)throw new Error("Unable to set a non-enumerable property on object.");e[Pe]=t}}return t}(e);if("function"==typeof e.toString)return Oe(e.toString());throw new Error("Value type "+t+" cannot be hashed.")}function Oe(e){for(var t=0,r=0;r<e.length;r++)t=31*t+e.charCodeAt(r)|0;return xe(t)}var Ae,Ie=Object.isExtensible,Ne=function(){try{return Object.defineProperty({},"@",{}),!0}catch(e){return!1}}(),Re="function"==typeof WeakMap;Re&&(Ae=new WeakMap);var ke=0,Pe="__immutablehash__";"function"==typeof Symbol&&(Pe=Symbol(Pe));var je=16,De=255,Ce=0,Me={};function Le(e){ge(e!==1/0,"Cannot perform this action with an infinite size.")}function qe(e){return null==e?We():Fe(e)&&!l(e)?e:We().withMutations(function(t){var r=n(e);Le(r.size),r.forEach(function(e,r){return t.set(r,e)})})}function Fe(e){return!(!e||!e[Ue])}t(qe,_e),qe.of=function(){var t=e.call(arguments,0);return We().withMutations(function(e){for(var r=0;r<t.length;r+=2){if(r+1>=t.length)throw new Error("Missing value for key: "+t[r]);e.set(t[r],t[r+1])}})},qe.prototype.toString=function(){return this.__toString("Map {","}")},qe.prototype.get=function(e,t){return this._root?this._root.get(0,void 0,e,t):t},qe.prototype.set=function(e,t){return Ze(this,e,t)},qe.prototype.setIn=function(e,t){return this.updateIn(e,b,function(){return t})},qe.prototype.remove=function(e){return Ze(this,e,b)},qe.prototype.deleteIn=function(e){return this.updateIn(e,function(){return b})},qe.prototype.update=function(e,t,r){return 1===arguments.length?e(this):this.updateIn([e],t,r)},qe.prototype.updateIn=function(e,t,r){r||(r=t,t=void 0);var n=function e(t,r,n,i){var a=t===b,o=r.next();if(o.done){var s=a?n:t,c=i(s);return c===s?t:c}ge(a||t&&t.set,"invalid keyPath");var u=o.value,l=a?b:t.get(u,b),f=e(l,r,n,i);return f===l?t:f===b?t.remove(u):(a?We():t).set(u,f)}(this,nr(e),t,r);return n===b?void 0:n},qe.prototype.clear=function(){return 0===this.size?this:this.__ownerID?(this.size=0,this._root=null,this.__hash=void 0,this.__altered=!0,this):We()},qe.prototype.merge=function(){return nt(this,void 0,arguments)},qe.prototype.mergeWith=function(t){var r=e.call(arguments,1);return nt(this,t,r)},qe.prototype.mergeIn=function(t){var r=e.call(arguments,1);return this.updateIn(t,We(),function(e){return"function"==typeof e.merge?e.merge.apply(e,r):r[r.length-1]})},qe.prototype.mergeDeep=function(){return nt(this,it,arguments)},qe.prototype.mergeDeepWith=function(t){var r=e.call(arguments,1);return nt(this,at(t),r)},qe.prototype.mergeDeepIn=function(t){var r=e.call(arguments,1);return this.updateIn(t,We(),function(e){return"function"==typeof e.mergeDeep?e.mergeDeep.apply(e,r):r[r.length-1]})},qe.prototype.sort=function(e){return Nt(Qt(this,e))},qe.prototype.sortBy=function(e,t){return Nt(Qt(this,t,e))},qe.prototype.withMutations=function(e){var t=this.asMutable();return e(t),t.wasAltered()?t.__ensureOwner(this.__ownerID):this},qe.prototype.asMutable=function(){return this.__ownerID?this:this.__ensureOwner(new E)},qe.prototype.asImmutable=function(){return this.__ensureOwner()},qe.prototype.wasAltered=function(){return this.__altered},qe.prototype.__iterator=function(e,t){return new $e(this,e,t)},qe.prototype.__iterate=function(e,t){var r=this,n=0;return this._root&&this._root.iterate(function(t){return n++,e(t[1],t[0],r)},t),n},qe.prototype.__ensureOwner=function(e){return e===this.__ownerID?this:e?Ke(this.size,this._root,e,this.__hash):(this.__ownerID=e,this.__altered=!1,this)},qe.isMap=Fe;var Be,Ue="@@__IMMUTABLE_MAP__@@",Ve=qe.prototype;function He(e,t){this.ownerID=e,this.entries=t}function ze(e,t,r){this.ownerID=e,this.bitmap=t,this.nodes=r}function Ge(e,t,r){this.ownerID=e,this.count=t,this.nodes=r}function Qe(e,t,r){this.ownerID=e,this.keyHash=t,this.entries=r}function Xe(e,t,r){this.ownerID=e,this.keyHash=t,this.entry=r}function $e(e,t,r){this._type=t,this._reverse=r,this._stack=e._root&&Ye(e._root)}function Je(e,t){return F(e,t[0],t[1])}function Ye(e,t){return{node:e,index:0,__prev:t}}function Ke(e,t,r,n){var i=Object.create(Ve);return i.size=e,i._root=t,i.__ownerID=r,i.__hash=n,i.__altered=!1,i}function We(){return Be||(Be=Ke(0))}function Ze(e,t,r){var n,i;if(e._root){var a=w(v),o=w(_);if(n=et(e._root,e.__ownerID,0,void 0,t,r,a,o),!o.value)return e;i=e.size+(a.value?r===b?-1:1:0)}else{if(r===b)return e;i=1,n=new He(e.__ownerID,[[t,r]])}return e.__ownerID?(e.size=i,e._root=n,e.__hash=void 0,e.__altered=!0,e):n?Ke(i,n):We()}function et(e,t,r,n,i,a,o,s){return e?e.update(t,r,n,i,a,o,s):a===b?e:(S(s),S(o),new Xe(t,n,[i,a]))}function tt(e){return e.constructor===Xe||e.constructor===Qe}function rt(e,t,r,n,i){if(e.keyHash===n)return new Qe(t,n,[e.entry,i]);var a,o=(0===r?e.keyHash:e.keyHash>>>r)&g,s=(0===r?n:n>>>r)&g;return new ze(t,1<<o|1<<s,o===s?[rt(e,t,r+y,n,i)]:(a=new Xe(t,n,i),o<s?[e,a]:[a,e]))}function nt(e,t,r){for(var i=[],a=0;a<r.length;a++){var s=r[a],c=n(s);o(s)||(c=c.map(function(e){return fe(e)})),i.push(c)}return ot(e,t,i)}function it(e,t,r){return e&&e.mergeDeep&&o(t)?e.mergeDeep(t):pe(e,t)?e:t}function at(e){return function(t,r,n){if(t&&t.mergeDeepWith&&o(r))return t.mergeDeepWith(e,r);var i=e(t,r,n);return pe(t,i)?t:i}}function ot(e,t,r){return 0===(r=r.filter(function(e){return 0!==e.size})).length?e:0!==e.size||e.__ownerID||1!==r.length?e.withMutations(function(e){for(var n=t?function(r,n){e.update(n,b,function(e){return e===b?r:t(e,r,n)})}:function(t,r){e.set(r,t)},i=0;i<r.length;i++)r[i].forEach(n)}):e.constructor(r[0])}function st(e){return e=(e=(858993459&(e-=e>>1&1431655765))+(e>>2&858993459))+(e>>4)&252645135,e+=e>>8,127&(e+=e>>16)}function ct(e,t,r,n){var i=n?e:x(e);return i[t]=r,i}Ve[Ue]=!0,Ve.delete=Ve.remove,Ve.removeIn=Ve.deleteIn,He.prototype.get=function(e,t,r,n){for(var i=this.entries,a=0,o=i.length;a<o;a++)if(pe(r,i[a][0]))return i[a][1];return n},He.prototype.update=function(e,t,r,n,i,a,o){for(var s=i===b,c=this.entries,u=0,l=c.length;u<l&&!pe(n,c[u][0]);u++);var f=u<l;if(f?c[u][1]===i:s)return this;if(S(o),(s||!f)&&S(a),!s||1!==c.length){if(!f&&!s&&c.length>=ut)return function(e,t,r,n){e||(e=new E);for(var i=new Xe(e,Te(r),[r,n]),a=0;a<t.length;a++){var o=t[a];i=i.update(e,0,void 0,o[0],o[1])}return i}(e,c,n,i);var d=e&&e===this.ownerID,h=d?c:x(c);return f?s?u===l-1?h.pop():h[u]=h.pop():h[u]=[n,i]:h.push([n,i]),d?(this.entries=h,this):new He(e,h)}},ze.prototype.get=function(e,t,r,n){void 0===t&&(t=Te(r));var i=1<<((0===e?t:t>>>e)&g),a=this.bitmap;return 0==(a&i)?n:this.nodes[st(a&i-1)].get(e+y,t,r,n)},ze.prototype.update=function(e,t,r,n,i,a,o){void 0===r&&(r=Te(n));var s=(0===t?r:r>>>t)&g,c=1<<s,u=this.bitmap,l=0!=(u&c);if(!l&&i===b)return this;var f=st(u&c-1),d=this.nodes,h=l?d[f]:void 0,p=et(h,e,t+y,r,n,i,a,o);if(p===h)return this;if(!l&&p&&d.length>=lt)return function(e,t,r,n,i){for(var a=0,o=new Array(m),s=0;0!==r;s++,r>>>=1)o[s]=1&r?t[a++]:void 0;return o[n]=i,new Ge(e,a+1,o)}(e,d,u,s,p);if(l&&!p&&2===d.length&&tt(d[1^f]))return d[1^f];if(l&&p&&1===d.length&&tt(p))return p;var v=e&&e===this.ownerID,_=l?p?u:u^c:u|c,w=l?p?ct(d,f,p,v):function(e,t,r){var n=e.length-1;if(r&&t===n)return e.pop(),e;for(var i=new Array(n),a=0,o=0;o<n;o++)o===t&&(a=1),i[o]=e[o+a];return i}(d,f,v):function(e,t,r,n){var i=e.length+1;if(n&&t+1===i)return e[t]=r,e;for(var a=new Array(i),o=0,s=0;s<i;s++)s===t?(a[s]=r,o=-1):a[s]=e[s+o];return a}(d,f,p,v);return v?(this.bitmap=_,this.nodes=w,this):new ze(e,_,w)},Ge.prototype.get=function(e,t,r,n){void 0===t&&(t=Te(r));var i=(0===e?t:t>>>e)&g,a=this.nodes[i];return a?a.get(e+y,t,r,n):n},Ge.prototype.update=function(e,t,r,n,i,a,o){void 0===r&&(r=Te(n));var s=(0===t?r:r>>>t)&g,c=i===b,u=this.nodes,l=u[s];if(c&&!l)return this;var f=et(l,e,t+y,r,n,i,a,o);if(f===l)return this;var d=this.count;if(l){if(!f&&--d<ft)return function(e,t,r,n){for(var i=0,a=0,o=new Array(r),s=0,c=1,u=t.length;s<u;s++,c<<=1){var l=t[s];void 0!==l&&s!==n&&(i|=c,o[a++]=l)}return new ze(e,i,o)}(e,u,d,s)}else d++;var h=e&&e===this.ownerID,p=ct(u,s,f,h);return h?(this.count=d,this.nodes=p,this):new Ge(e,d,p)},Qe.prototype.get=function(e,t,r,n){for(var i=this.entries,a=0,o=i.length;a<o;a++)if(pe(r,i[a][0]))return i[a][1];return n},Qe.prototype.update=function(e,t,r,n,i,a,o){void 0===r&&(r=Te(n));var s=i===b;if(r!==this.keyHash)return s?this:(S(o),S(a),rt(this,e,t,r,[n,i]));for(var c=this.entries,u=0,l=c.length;u<l&&!pe(n,c[u][0]);u++);var f=u<l;if(f?c[u][1]===i:s)return this;if(S(o),(s||!f)&&S(a),s&&2===l)return new Xe(e,this.keyHash,c[1^u]);var d=e&&e===this.ownerID,h=d?c:x(c);return f?s?u===l-1?h.pop():h[u]=h.pop():h[u]=[n,i]:h.push([n,i]),d?(this.entries=h,this):new Qe(e,this.keyHash,h)},Xe.prototype.get=function(e,t,r,n){return pe(r,this.entry[0])?this.entry[1]:n},Xe.prototype.update=function(e,t,r,n,i,a,o){var s=i===b,c=pe(n,this.entry[0]);return(c?i===this.entry[1]:s)?this:(S(o),s?void S(a):c?e&&e===this.ownerID?(this.entry[1]=i,this):new Xe(e,this.keyHash,[n,i]):(S(a),rt(this,e,t,Te(n),[n,i])))},He.prototype.iterate=Qe.prototype.iterate=function(e,t){for(var r=this.entries,n=0,i=r.length-1;n<=i;n++)if(!1===e(r[t?i-n:n]))return!1},ze.prototype.iterate=Ge.prototype.iterate=function(e,t){for(var r=this.nodes,n=0,i=r.length-1;n<=i;n++){var a=r[t?i-n:n];if(a&&!1===a.iterate(e,t))return!1}},Xe.prototype.iterate=function(e,t){return e(this.entry)},t($e,q),$e.prototype.next=function(){for(var e=this._type,t=this._stack;t;){var r,n=t.node,i=t.index++;if(n.entry){if(0===i)return Je(e,n.entry)}else if(n.entries){if(i<=(r=n.entries.length-1))return Je(e,n.entries[this._reverse?r-i:i])}else if(i<=(r=n.nodes.length-1)){var a=n.nodes[this._reverse?r-i:i];if(a){if(a.entry)return Je(e,a.entry);t=this._stack=Ye(a,t)}continue}t=this._stack=this._stack.__prev}return{value:void 0,done:!0}};var ut=m/4,lt=m/2,ft=m/4;function dt(e){var t=St();if(null==e)return t;if(ht(e))return e;var r=i(e),n=r.size;return 0===n?t:(Le(n),n>0&&n<m?wt(0,n,y,null,new mt(r.toArray())):t.withMutations(function(e){e.setSize(n),r.forEach(function(t,r){return e.set(r,t)})}))}function ht(e){return!(!e||!e[pt])}t(dt,we),dt.of=function(){return this(arguments)},dt.prototype.toString=function(){return this.__toString("List [","]")},dt.prototype.get=function(e,t){if((e=O(this,e))>=0&&e<this.size){var r=Tt(this,e+=this._origin);return r&&r.array[e&g]}return t},dt.prototype.set=function(e,t){return function(e,t,r){if((t=O(e,t))!=t)return e;if(t>=e.size||t<0)return e.withMutations(function(e){t<0?Ot(e,t).set(0,r):Ot(e,0,t+1).set(t,r)});t+=e._origin;var n=e._tail,i=e._root,a=w(_);return t>=It(e._capacity)?n=Et(n,e.__ownerID,0,t,r,a):i=Et(i,e.__ownerID,e._level,t,r,a),a.value?e.__ownerID?(e._root=i,e._tail=n,e.__hash=void 0,e.__altered=!0,e):wt(e._origin,e._capacity,e._level,i,n):e}(this,e,t)},dt.prototype.remove=function(e){return this.has(e)?0===e?this.shift():e===this.size-1?this.pop():this.splice(e,1):this},dt.prototype.insert=function(e,t){return this.splice(e,0,t)},dt.prototype.clear=function(){return 0===this.size?this:this.__ownerID?(this.size=this._origin=this._capacity=0,this._level=y,this._root=this._tail=null,this.__hash=void 0,this.__altered=!0,this):St()},dt.prototype.push=function(){var e=arguments,t=this.size;return this.withMutations(function(r){Ot(r,0,t+e.length);for(var n=0;n<e.length;n++)r.set(t+n,e[n])})},dt.prototype.pop=function(){return Ot(this,0,-1)},dt.prototype.unshift=function(){var e=arguments;return this.withMutations(function(t){Ot(t,-e.length);for(var r=0;r<e.length;r++)t.set(r,e[r])})},dt.prototype.shift=function(){return Ot(this,1)},dt.prototype.merge=function(){return At(this,void 0,arguments)},dt.prototype.mergeWith=function(t){var r=e.call(arguments,1);return At(this,t,r)},dt.prototype.mergeDeep=function(){return At(this,it,arguments)},dt.prototype.mergeDeepWith=function(t){var r=e.call(arguments,1);return At(this,at(t),r)},dt.prototype.setSize=function(e){return Ot(this,0,e)},dt.prototype.slice=function(e,t){var r=this.size;return I(e,t,r)?this:Ot(this,N(e,r),R(t,r))},dt.prototype.__iterator=function(e,t){var r=0,n=_t(this,t);return new q(function(){var t=n();return t===vt?{value:void 0,done:!0}:F(e,r++,t)})},dt.prototype.__iterate=function(e,t){for(var r,n=0,i=_t(this,t);(r=i())!==vt&&!1!==e(r,n++,this););return n},dt.prototype.__ensureOwner=function(e){return e===this.__ownerID?this:e?wt(this._origin,this._capacity,this._level,this._root,this._tail,e,this.__hash):(this.__ownerID=e,this)},dt.isList=ht;var pt="@@__IMMUTABLE_LIST__@@",yt=dt.prototype;function mt(e,t){this.array=e,this.ownerID=t}yt[pt]=!0,yt.delete=yt.remove,yt.setIn=Ve.setIn,yt.deleteIn=yt.removeIn=Ve.removeIn,yt.update=Ve.update,yt.updateIn=Ve.updateIn,yt.mergeIn=Ve.mergeIn,yt.mergeDeepIn=Ve.mergeDeepIn,yt.withMutations=Ve.withMutations,yt.asMutable=Ve.asMutable,yt.asImmutable=Ve.asImmutable,yt.wasAltered=Ve.wasAltered,mt.prototype.removeBefore=function(e,t,r){if(r===t?1<<t:0===this.array.length)return this;var n=r>>>t&g;if(n>=this.array.length)return new mt([],e);var i,a=0===n;if(t>0){var o=this.array[n];if((i=o&&o.removeBefore(e,t-y,r))===o&&a)return this}if(a&&!i)return this;var s=xt(this,e);if(!a)for(var c=0;c<n;c++)s.array[c]=void 0;return i&&(s.array[n]=i),s},mt.prototype.removeAfter=function(e,t,r){if(r===(t?1<<t:0)||0===this.array.length)return this;var n,i=r-1>>>t&g;if(i>=this.array.length)return this;if(t>0){var a=this.array[i];if((n=a&&a.removeAfter(e,t-y,r))===a&&i===this.array.length-1)return this}var o=xt(this,e);return o.array.splice(i+1),n&&(o.array[i]=n),o};var gt,bt,vt={};function _t(e,t){var r=e._origin,n=e._capacity,i=It(n),a=e._tail;return o(e._root,e._level,0);function o(e,s,c){return 0===s?function(e,o){var s=o===i?a&&a.array:e&&e.array,c=o>r?0:r-o,u=n-o;return u>m&&(u=m),function(){if(c===u)return vt;var e=t?--u:c++;return s&&s[e]}}(e,c):function(e,i,a){var s,c=e&&e.array,u=a>r?0:r-a>>i,l=1+(n-a>>i);return l>m&&(l=m),function(){for(;;){if(s){var e=s();if(e!==vt)return e;s=null}if(u===l)return vt;var r=t?--l:u++;s=o(c&&c[r],i-y,a+(r<<i))}}}(e,s,c)}}function wt(e,t,r,n,i,a,o){var s=Object.create(yt);return s.size=t-e,s._origin=e,s._capacity=t,s._level=r,s._root=n,s._tail=i,s.__ownerID=a,s.__hash=o,s.__altered=!1,s}function St(){return gt||(gt=wt(0,0,y))}function Et(e,t,r,n,i,a){var o,s=n>>>r&g,c=e&&s<e.array.length;if(!c&&void 0===i)return e;if(r>0){var u=e&&e.array[s],l=Et(u,t,r-y,n,i,a);return l===u?e:((o=xt(e,t)).array[s]=l,o)}return c&&e.array[s]===i?e:(S(a),o=xt(e,t),void 0===i&&s===o.array.length-1?o.array.pop():o.array[s]=i,o)}function xt(e,t){return t&&e&&t===e.ownerID?e:new mt(e?e.array.slice():[],t)}function Tt(e,t){if(t>=It(e._capacity))return e._tail;if(t<1<<e._level+y){for(var r=e._root,n=e._level;r&&n>0;)r=r.array[t>>>n&g],n-=y;return r}}function Ot(e,t,r){void 0!==t&&(t|=0),void 0!==r&&(r|=0);var n=e.__ownerID||new E,i=e._origin,a=e._capacity,o=i+t,s=void 0===r?a:r<0?a+r:i+r;if(o===i&&s===a)return e;if(o>=s)return e.clear();for(var c=e._level,u=e._root,l=0;o+l<0;)u=new mt(u&&u.array.length?[void 0,u]:[],n),l+=1<<(c+=y);l&&(o+=l,i+=l,s+=l,a+=l);for(var f=It(a),d=It(s);d>=1<<c+y;)u=new mt(u&&u.array.length?[u]:[],n),c+=y;var h=e._tail,p=d<f?Tt(e,s-1):d>f?new mt([],n):h;if(h&&d>f&&o<a&&h.array.length){for(var m=u=xt(u,n),b=c;b>y;b-=y){var v=f>>>b&g;m=m.array[v]=xt(m.array[v],n)}m.array[f>>>y&g]=h}if(s<a&&(p=p&&p.removeAfter(n,0,s)),o>=d)o-=d,s-=d,c=y,u=null,p=p&&p.removeBefore(n,0,o);else if(o>i||d<f){for(l=0;u;){var _=o>>>c&g;if(_!==d>>>c&g)break;_&&(l+=(1<<c)*_),c-=y,u=u.array[_]}u&&o>i&&(u=u.removeBefore(n,c,o-l)),u&&d<f&&(u=u.removeAfter(n,c,d-l)),l&&(o-=l,s-=l)}return e.__ownerID?(e.size=s-o,e._origin=o,e._capacity=s,e._level=c,e._root=u,e._tail=p,e.__hash=void 0,e.__altered=!0,e):wt(o,s,c,u,p)}function At(e,t,r){for(var n=[],a=0,s=0;s<r.length;s++){var c=r[s],u=i(c);u.size>a&&(a=u.size),o(c)||(u=u.map(function(e){return fe(e)})),n.push(u)}return a>e.size&&(e=e.setSize(a)),ot(e,t,n)}function It(e){return e<m?0:e-1>>>y<<y}function Nt(e){return null==e?Pt():Rt(e)?e:Pt().withMutations(function(t){var r=n(e);Le(r.size),r.forEach(function(e,r){return t.set(r,e)})})}function Rt(e){return Fe(e)&&l(e)}function kt(e,t,r,n){var i=Object.create(Nt.prototype);return i.size=e?e.size:0,i._map=e,i._list=t,i.__ownerID=r,i.__hash=n,i}function Pt(){return bt||(bt=kt(We(),St()))}function jt(e,t,r){var n,i,a=e._map,o=e._list,s=a.get(t),c=void 0!==s;if(r===b){if(!c)return e;o.size>=m&&o.size>=2*a.size?(n=(i=o.filter(function(e,t){return void 0!==e&&s!==t})).toKeyedSeq().map(function(e){return e[0]}).flip().toMap(),e.__ownerID&&(n.__ownerID=i.__ownerID=e.__ownerID)):(n=a.remove(t),i=s===o.size-1?o.pop():o.set(s,void 0))}else if(c){if(r===o.get(s)[1])return e;n=a,i=o.set(s,[t,r])}else n=a.set(t,o.size),i=o.set(o.size,[t,r]);return e.__ownerID?(e.size=n.size,e._map=n,e._list=i,e.__hash=void 0,e):kt(n,i)}function Dt(e,t){this._iter=e,this._useKeys=t,this.size=e.size}function Ct(e){this._iter=e,this.size=e.size}function Mt(e){this._iter=e,this.size=e.size}function Lt(e){this._iter=e,this.size=e.size}function qt(e){var t=er(e);return t._iter=e,t.size=e.size,t.flip=function(){return e},t.reverse=function(){var t=e.reverse.apply(this);return t.flip=function(){return e.reverse()},t},t.has=function(t){return e.includes(t)},t.includes=function(t){return e.has(t)},t.cacheResult=tr,t.__iterateUncached=function(t,r){var n=this;return e.__iterate(function(e,r){return!1!==t(r,e,n)},r)},t.__iteratorUncached=function(t,r){if(t===D){var n=e.__iterator(t,r);return new q(function(){var e=n.next();if(!e.done){var t=e.value[0];e.value[0]=e.value[1],e.value[1]=t}return e})}return e.__iterator(t===j?P:j,r)},t}function Ft(e,t,r){var n=er(e);return n.size=e.size,n.has=function(t){return e.has(t)},n.get=function(n,i){var a=e.get(n,b);return a===b?i:t.call(r,a,n,e)},n.__iterateUncached=function(n,i){var a=this;return e.__iterate(function(e,i,o){return!1!==n(t.call(r,e,i,o),i,a)},i)},n.__iteratorUncached=function(n,i){var a=e.__iterator(D,i);return new q(function(){var i=a.next();if(i.done)return i;var o=i.value,s=o[0];return F(n,s,t.call(r,o[1],s,e),i)})},n}function Bt(e,t){var r=er(e);return r._iter=e,r.size=e.size,r.reverse=function(){return e},e.flip&&(r.flip=function(){var t=qt(e);return t.reverse=function(){return e.flip()},t}),r.get=function(r,n){return e.get(t?r:-1-r,n)},r.has=function(r){return e.has(t?r:-1-r)},r.includes=function(t){return e.includes(t)},r.cacheResult=tr,r.__iterate=function(t,r){var n=this;return e.__iterate(function(e,r){return t(e,r,n)},!r)},r.__iterator=function(t,r){return e.__iterator(t,!r)},r}function Ut(e,t,r,n){var i=er(e);return n&&(i.has=function(n){var i=e.get(n,b);return i!==b&&!!t.call(r,i,n,e)},i.get=function(n,i){var a=e.get(n,b);return a!==b&&t.call(r,a,n,e)?a:i}),i.__iterateUncached=function(i,a){var o=this,s=0;return e.__iterate(function(e,a,c){if(t.call(r,e,a,c))return s++,i(e,n?a:s-1,o)},a),s},i.__iteratorUncached=function(i,a){var o=e.__iterator(D,a),s=0;return new q(function(){for(;;){var a=o.next();if(a.done)return a;var c=a.value,u=c[0],l=c[1];if(t.call(r,l,u,e))return F(i,n?u:s++,l,a)}})},i}function Vt(e,t,r,n){var i=e.size;if(void 0!==t&&(t|=0),void 0!==r&&(r===1/0?r=i:r|=0),I(t,r,i))return e;var a=N(t,i),o=R(r,i);if(a!=a||o!=o)return Vt(e.toSeq().cacheResult(),t,r,n);var s,c=o-a;c==c&&(s=c<0?0:c);var u=er(e);return u.size=0===s?s:e.size&&s||void 0,!n&&ie(e)&&s>=0&&(u.get=function(t,r){return(t=O(this,t))>=0&&t<s?e.get(t+a,r):r}),u.__iterateUncached=function(t,r){var i=this;if(0===s)return 0;if(r)return this.cacheResult().__iterate(t,r);var o=0,c=!0,u=0;return e.__iterate(function(e,r){if(!c||!(c=o++<a))return u++,!1!==t(e,n?r:u-1,i)&&u!==s}),u},u.__iteratorUncached=function(t,r){if(0!==s&&r)return this.cacheResult().__iterator(t,r);var i=0!==s&&e.__iterator(t,r),o=0,c=0;return new q(function(){for(;o++<a;)i.next();if(++c>s)return{value:void 0,done:!0};var e=i.next();return n||t===j?e:F(t,c-1,t===P?void 0:e.value[1],e)})},u}function Ht(e,t,r,n){var i=er(e);return i.__iterateUncached=function(i,a){var o=this;if(a)return this.cacheResult().__iterate(i,a);var s=!0,c=0;return e.__iterate(function(e,a,u){if(!s||!(s=t.call(r,e,a,u)))return c++,i(e,n?a:c-1,o)}),c},i.__iteratorUncached=function(i,a){var o=this;if(a)return this.cacheResult().__iterator(i,a);var s=e.__iterator(D,a),c=!0,u=0;return new q(function(){var e,a,l;do{if((e=s.next()).done)return n||i===j?e:F(i,u++,i===P?void 0:e.value[1],e);var f=e.value;a=f[0],l=f[1],c&&(c=t.call(r,l,a,o))}while(c);return i===D?e:F(i,a,l,e)})},i}function zt(e,t){var r=s(e),i=[e].concat(t).map(function(e){return o(e)?r&&(e=n(e)):e=r?oe(e):se(Array.isArray(e)?e:[e]),e}).filter(function(e){return 0!==e.size});if(0===i.length)return e;if(1===i.length){var a=i[0];if(a===e||r&&s(a)||c(e)&&c(a))return a}var u=new ee(i);return r?u=u.toKeyedSeq():c(e)||(u=u.toSetSeq()),(u=u.flatten(!0)).size=i.reduce(function(e,t){if(void 0!==e){var r=t.size;if(void 0!==r)return e+r}},0),u}function Gt(e,t,r){var n=er(e);return n.__iterateUncached=function(n,i){var a=0,s=!1;return function e(c,u){var l=this;c.__iterate(function(i,c){return(!t||u<t)&&o(i)?e(i,u+1):!1===n(i,r?c:a++,l)&&(s=!0),!s},i)}(e,0),a},n.__iteratorUncached=function(n,i){var a=e.__iterator(n,i),s=[],c=0;return new q(function(){for(;a;){var e=a.next();if(!1===e.done){var u=e.value;if(n===D&&(u=u[1]),t&&!(s.length<t)||!o(u))return r?e:F(n,c++,u,e);s.push(a),a=u.__iterator(n,i)}else a=s.pop()}return{value:void 0,done:!0}})},n}function Qt(e,t,r){t||(t=rr);var n=s(e),i=0,a=e.toSeq().map(function(t,n){return[n,t,i++,r?r(t,n,e):t]}).toArray();return a.sort(function(e,r){return t(e[3],r[3])||e[2]-r[2]}).forEach(n?function(e,t){a[t].length=2}:function(e,t){a[t]=e[1]}),n?X(a):c(e)?$(a):J(a)}function Xt(e,t,r){if(t||(t=rr),r){var n=e.toSeq().map(function(t,n){return[t,r(t,n,e)]}).reduce(function(e,r){return $t(t,e[1],r[1])?r:e});return n&&n[0]}return e.reduce(function(e,r){return $t(t,e,r)?r:e})}function $t(e,t,r){var n=e(r,t);return 0===n&&r!==t&&(null==r||r!=r)||n>0}function Jt(e,t,n){var i=er(e);return i.size=new ee(n).map(function(e){return e.size}).min(),i.__iterate=function(e,t){for(var r,n=this.__iterator(j,t),i=0;!(r=n.next()).done&&!1!==e(r.value,i++,this););return i},i.__iteratorUncached=function(e,i){var a=n.map(function(e){return e=r(e),H(i?e.reverse():e)}),o=0,s=!1;return new q(function(){var r;return s||(r=a.map(function(e){return e.next()}),s=r.some(function(e){return e.done})),s?{value:void 0,done:!0}:F(e,o++,t.apply(null,r.map(function(e){return e.value})))})},i}function Yt(e,t){return ie(e)?t:e.constructor(t)}function Kt(e){if(e!==Object(e))throw new TypeError("Expected [K, V] tuple: "+e)}function Wt(e){return Le(e.size),T(e)}function Zt(e){return s(e)?n:c(e)?i:a}function er(e){return Object.create((s(e)?X:c(e)?$:J).prototype)}function tr(){return this._iter.cacheResult?(this._iter.cacheResult(),this.size=this._iter.size,this):Q.prototype.cacheResult.call(this)}function rr(e,t){return e>t?1:e<t?-1:0}function nr(e){var t=H(e);if(!t){if(!G(e))throw new TypeError("Expected iterable or array-like: "+e);t=H(r(e))}return t}function ir(e,t){var r,n=function(a){if(a instanceof n)return a;if(!(this instanceof n))return new n(a);if(!r){r=!0;var o=Object.keys(e);!function(e,t){try{t.forEach(function(e,t){Object.defineProperty(e,t,{get:function(){return this.get(t)},set:function(e){ge(this.__ownerID,"Cannot set on an immutable record."),this.set(t,e)}})}.bind(void 0,e))}catch(e){}}(i,o),i.size=o.length,i._name=t,i._keys=o,i._defaultValues=e}this._map=qe(a)},i=n.prototype=Object.create(ar);return i.constructor=n,n}t(Nt,qe),Nt.of=function(){return this(arguments)},Nt.prototype.toString=function(){return this.__toString("OrderedMap {","}")},Nt.prototype.get=function(e,t){var r=this._map.get(e);return void 0!==r?this._list.get(r)[1]:t},Nt.prototype.clear=function(){return 0===this.size?this:this.__ownerID?(this.size=0,this._map.clear(),this._list.clear(),this):Pt()},Nt.prototype.set=function(e,t){return jt(this,e,t)},Nt.prototype.remove=function(e){return jt(this,e,b)},Nt.prototype.wasAltered=function(){return this._map.wasAltered()||this._list.wasAltered()},Nt.prototype.__iterate=function(e,t){var r=this;return this._list.__iterate(function(t){return t&&e(t[1],t[0],r)},t)},Nt.prototype.__iterator=function(e,t){return this._list.fromEntrySeq().__iterator(e,t)},Nt.prototype.__ensureOwner=function(e){if(e===this.__ownerID)return this;var t=this._map.__ensureOwner(e),r=this._list.__ensureOwner(e);return e?kt(t,r,e,this.__hash):(this.__ownerID=e,this._map=t,this._list=r,this)},Nt.isOrderedMap=Rt,Nt.prototype[p]=!0,Nt.prototype.delete=Nt.prototype.remove,t(Dt,X),Dt.prototype.get=function(e,t){return this._iter.get(e,t)},Dt.prototype.has=function(e){return this._iter.has(e)},Dt.prototype.valueSeq=function(){return this._iter.valueSeq()},Dt.prototype.reverse=function(){var e=this,t=Bt(this,!0);return this._useKeys||(t.valueSeq=function(){return e._iter.toSeq().reverse()}),t},Dt.prototype.map=function(e,t){var r=this,n=Ft(this,e,t);return this._useKeys||(n.valueSeq=function(){return r._iter.toSeq().map(e,t)}),n},Dt.prototype.__iterate=function(e,t){var r,n=this;return this._iter.__iterate(this._useKeys?function(t,r){return e(t,r,n)}:(r=t?Wt(this):0,function(i){return e(i,t?--r:r++,n)}),t)},Dt.prototype.__iterator=function(e,t){if(this._useKeys)return this._iter.__iterator(e,t);var r=this._iter.__iterator(j,t),n=t?Wt(this):0;return new q(function(){var i=r.next();return i.done?i:F(e,t?--n:n++,i.value,i)})},Dt.prototype[p]=!0,t(Ct,$),Ct.prototype.includes=function(e){return this._iter.includes(e)},Ct.prototype.__iterate=function(e,t){var r=this,n=0;return this._iter.__iterate(function(t){return e(t,n++,r)},t)},Ct.prototype.__iterator=function(e,t){var r=this._iter.__iterator(j,t),n=0;return new q(function(){var t=r.next();return t.done?t:F(e,n++,t.value,t)})},t(Mt,J),Mt.prototype.has=function(e){return this._iter.includes(e)},Mt.prototype.__iterate=function(e,t){var r=this;return this._iter.__iterate(function(t){return e(t,t,r)},t)},Mt.prototype.__iterator=function(e,t){var r=this._iter.__iterator(j,t);return new q(function(){var t=r.next();return t.done?t:F(e,t.value,t.value,t)})},t(Lt,X),Lt.prototype.entrySeq=function(){return this._iter.toSeq()},Lt.prototype.__iterate=function(e,t){var r=this;return this._iter.__iterate(function(t){if(t){Kt(t);var n=o(t);return e(n?t.get(1):t[1],n?t.get(0):t[0],r)}},t)},Lt.prototype.__iterator=function(e,t){var r=this._iter.__iterator(j,t);return new q(function(){for(;;){var t=r.next();if(t.done)return t;var n=t.value;if(n){Kt(n);var i=o(n);return F(e,i?n.get(0):n[0],i?n.get(1):n[1],t)}}})},Ct.prototype.cacheResult=Dt.prototype.cacheResult=Mt.prototype.cacheResult=Lt.prototype.cacheResult=tr,t(ir,_e),ir.prototype.toString=function(){return this.__toString(sr(this)+" {","}")},ir.prototype.has=function(e){return this._defaultValues.hasOwnProperty(e)},ir.prototype.get=function(e,t){if(!this.has(e))return t;var r=this._defaultValues[e];return this._map?this._map.get(e,r):r},ir.prototype.clear=function(){if(this.__ownerID)return this._map&&this._map.clear(),this;var e=this.constructor;return e._empty||(e._empty=or(this,We()))},ir.prototype.set=function(e,t){if(!this.has(e))throw new Error('Cannot set unknown key "'+e+'" on '+sr(this));if(this._map&&!this._map.has(e)&&t===this._defaultValues[e])return this;var r=this._map&&this._map.set(e,t);return this.__ownerID||r===this._map?this:or(this,r)},ir.prototype.remove=function(e){if(!this.has(e))return this;var t=this._map&&this._map.remove(e);return this.__ownerID||t===this._map?this:or(this,t)},ir.prototype.wasAltered=function(){return this._map.wasAltered()},ir.prototype.__iterator=function(e,t){var r=this;return n(this._defaultValues).map(function(e,t){return r.get(t)}).__iterator(e,t)},ir.prototype.__iterate=function(e,t){var r=this;return n(this._defaultValues).map(function(e,t){return r.get(t)}).__iterate(e,t)},ir.prototype.__ensureOwner=function(e){if(e===this.__ownerID)return this;var t=this._map&&this._map.__ensureOwner(e);return e?or(this,t,e):(this.__ownerID=e,this._map=t,this)};var ar=ir.prototype;function or(e,t,r){var n=Object.create(Object.getPrototypeOf(e));return n._map=t,n.__ownerID=r,n}function sr(e){return e._name||e.constructor.name||"Record"}function cr(e){return null==e?yr():ur(e)&&!l(e)?e:yr().withMutations(function(t){var r=a(e);Le(r.size),r.forEach(function(e){return t.add(e)})})}function ur(e){return!(!e||!e[fr])}ar.delete=ar.remove,ar.deleteIn=ar.removeIn=Ve.removeIn,ar.merge=Ve.merge,ar.mergeWith=Ve.mergeWith,ar.mergeIn=Ve.mergeIn,ar.mergeDeep=Ve.mergeDeep,ar.mergeDeepWith=Ve.mergeDeepWith,ar.mergeDeepIn=Ve.mergeDeepIn,ar.setIn=Ve.setIn,ar.update=Ve.update,ar.updateIn=Ve.updateIn,ar.withMutations=Ve.withMutations,ar.asMutable=Ve.asMutable,ar.asImmutable=Ve.asImmutable,t(cr,Se),cr.of=function(){return this(arguments)},cr.fromKeys=function(e){return this(n(e).keySeq())},cr.prototype.toString=function(){return this.__toString("Set {","}")},cr.prototype.has=function(e){return this._map.has(e)},cr.prototype.add=function(e){return hr(this,this._map.set(e,!0))},cr.prototype.remove=function(e){return hr(this,this._map.remove(e))},cr.prototype.clear=function(){return hr(this,this._map.clear())},cr.prototype.union=function(){var t=e.call(arguments,0);return 0===(t=t.filter(function(e){return 0!==e.size})).length?this:0!==this.size||this.__ownerID||1!==t.length?this.withMutations(function(e){for(var r=0;r<t.length;r++)a(t[r]).forEach(function(t){return e.add(t)})}):this.constructor(t[0])},cr.prototype.intersect=function(){var t=e.call(arguments,0);if(0===t.length)return this;t=t.map(function(e){return a(e)});var r=this;return this.withMutations(function(e){r.forEach(function(r){t.every(function(e){return e.includes(r)})||e.remove(r)})})},cr.prototype.subtract=function(){var t=e.call(arguments,0);if(0===t.length)return this;t=t.map(function(e){return a(e)});var r=this;return this.withMutations(function(e){r.forEach(function(r){t.some(function(e){return e.includes(r)})&&e.remove(r)})})},cr.prototype.merge=function(){return this.union.apply(this,arguments)},cr.prototype.mergeWith=function(t){var r=e.call(arguments,1);return this.union.apply(this,r)},cr.prototype.sort=function(e){return mr(Qt(this,e))},cr.prototype.sortBy=function(e,t){return mr(Qt(this,t,e))},cr.prototype.wasAltered=function(){return this._map.wasAltered()},cr.prototype.__iterate=function(e,t){var r=this;return this._map.__iterate(function(t,n){return e(n,n,r)},t)},cr.prototype.__iterator=function(e,t){return this._map.map(function(e,t){return t}).__iterator(e,t)},cr.prototype.__ensureOwner=function(e){if(e===this.__ownerID)return this;var t=this._map.__ensureOwner(e);return e?this.__make(t,e):(this.__ownerID=e,this._map=t,this)},cr.isSet=ur;var lr,fr="@@__IMMUTABLE_SET__@@",dr=cr.prototype;function hr(e,t){return e.__ownerID?(e.size=t.size,e._map=t,e):t===e._map?e:0===t.size?e.__empty():e.__make(t)}function pr(e,t){var r=Object.create(dr);return r.size=e?e.size:0,r._map=e,r.__ownerID=t,r}function yr(){return lr||(lr=pr(We()))}function mr(e){return null==e?wr():gr(e)?e:wr().withMutations(function(t){var r=a(e);Le(r.size),r.forEach(function(e){return t.add(e)})})}function gr(e){return ur(e)&&l(e)}dr[fr]=!0,dr.delete=dr.remove,dr.mergeDeep=dr.merge,dr.mergeDeepWith=dr.mergeWith,dr.withMutations=Ve.withMutations,dr.asMutable=Ve.asMutable,dr.asImmutable=Ve.asImmutable,dr.__empty=yr,dr.__make=pr,t(mr,cr),mr.of=function(){return this(arguments)},mr.fromKeys=function(e){return this(n(e).keySeq())},mr.prototype.toString=function(){return this.__toString("OrderedSet {","}")},mr.isOrderedSet=gr;var br,vr=mr.prototype;function _r(e,t){var r=Object.create(vr);return r.size=e?e.size:0,r._map=e,r.__ownerID=t,r}function wr(){return br||(br=_r(Pt()))}function Sr(e){return null==e?Ir():Er(e)?e:Ir().unshiftAll(e)}function Er(e){return!(!e||!e[Tr])}vr[p]=!0,vr.__empty=wr,vr.__make=_r,t(Sr,we),Sr.of=function(){return this(arguments)},Sr.prototype.toString=function(){return this.__toString("Stack [","]")},Sr.prototype.get=function(e,t){var r=this._head;for(e=O(this,e);r&&e--;)r=r.next;return r?r.value:t},Sr.prototype.peek=function(){return this._head&&this._head.value},Sr.prototype.push=function(){if(0===arguments.length)return this;for(var e=this.size+arguments.length,t=this._head,r=arguments.length-1;r>=0;r--)t={value:arguments[r],next:t};return this.__ownerID?(this.size=e,this._head=t,this.__hash=void 0,this.__altered=!0,this):Ar(e,t)},Sr.prototype.pushAll=function(e){if(0===(e=i(e)).size)return this;Le(e.size);var t=this.size,r=this._head;return e.reverse().forEach(function(e){t++,r={value:e,next:r}}),this.__ownerID?(this.size=t,this._head=r,this.__hash=void 0,this.__altered=!0,this):Ar(t,r)},Sr.prototype.pop=function(){return this.slice(1)},Sr.prototype.unshift=function(){return this.push.apply(this,arguments)},Sr.prototype.unshiftAll=function(e){return this.pushAll(e)},Sr.prototype.shift=function(){return this.pop.apply(this,arguments)},Sr.prototype.clear=function(){return 0===this.size?this:this.__ownerID?(this.size=0,this._head=void 0,this.__hash=void 0,this.__altered=!0,this):Ir()},Sr.prototype.slice=function(e,t){if(I(e,t,this.size))return this;var r=N(e,this.size);if(R(t,this.size)!==this.size)return we.prototype.slice.call(this,e,t);for(var n=this.size-r,i=this._head;r--;)i=i.next;return this.__ownerID?(this.size=n,this._head=i,this.__hash=void 0,this.__altered=!0,this):Ar(n,i)},Sr.prototype.__ensureOwner=function(e){return e===this.__ownerID?this:e?Ar(this.size,this._head,e,this.__hash):(this.__ownerID=e,this.__altered=!1,this)},Sr.prototype.__iterate=function(e,t){if(t)return this.reverse().__iterate(e);for(var r=0,n=this._head;n&&!1!==e(n.value,r++,this);)n=n.next;return r},Sr.prototype.__iterator=function(e,t){if(t)return this.reverse().__iterator(e);var r=0,n=this._head;return new q(function(){if(n){var t=n.value;return n=n.next,F(e,r++,t)}return{value:void 0,done:!0}})},Sr.isStack=Er;var xr,Tr="@@__IMMUTABLE_STACK__@@",Or=Sr.prototype;function Ar(e,t,r,n){var i=Object.create(Or);return i.size=e,i._head=t,i.__ownerID=r,i.__hash=n,i.__altered=!1,i}function Ir(){return xr||(xr=Ar(0))}function Nr(e,t){var r=function(r){e.prototype[r]=t[r]};return Object.keys(t).forEach(r),Object.getOwnPropertySymbols&&Object.getOwnPropertySymbols(t).forEach(r),e}Or[Tr]=!0,Or.withMutations=Ve.withMutations,Or.asMutable=Ve.asMutable,Or.asImmutable=Ve.asImmutable,Or.wasAltered=Ve.wasAltered,r.Iterator=q,Nr(r,{toArray:function(){Le(this.size);var e=new Array(this.size||0);return this.valueSeq().__iterate(function(t,r){e[r]=t}),e},toIndexedSeq:function(){return new Ct(this)},toJS:function(){return this.toSeq().map(function(e){return e&&"function"==typeof e.toJS?e.toJS():e}).__toJS()},toJSON:function(){return this.toSeq().map(function(e){return e&&"function"==typeof e.toJSON?e.toJSON():e}).__toJS()},toKeyedSeq:function(){return new Dt(this,!0)},toMap:function(){return qe(this.toKeyedSeq())},toObject:function(){Le(this.size);var e={};return this.__iterate(function(t,r){e[r]=t}),e},toOrderedMap:function(){return Nt(this.toKeyedSeq())},toOrderedSet:function(){return mr(s(this)?this.valueSeq():this)},toSet:function(){return cr(s(this)?this.valueSeq():this)},toSetSeq:function(){return new Mt(this)},toSeq:function(){return c(this)?this.toIndexedSeq():s(this)?this.toKeyedSeq():this.toSetSeq()},toStack:function(){return Sr(s(this)?this.valueSeq():this)},toList:function(){return dt(s(this)?this.valueSeq():this)},toString:function(){return"[Iterable]"},__toString:function(e,t){return 0===this.size?e+t:e+" "+this.toSeq().map(this.__toStringMapper).join(", ")+" "+t},concat:function(){var t=e.call(arguments,0);return Yt(this,zt(this,t))},includes:function(e){return this.some(function(t){return pe(t,e)})},entries:function(){return this.__iterator(D)},every:function(e,t){Le(this.size);var r=!0;return this.__iterate(function(n,i,a){if(!e.call(t,n,i,a))return r=!1,!1}),r},filter:function(e,t){return Yt(this,Ut(this,e,t,!0))},find:function(e,t,r){var n=this.findEntry(e,t);return n?n[1]:r},forEach:function(e,t){return Le(this.size),this.__iterate(t?e.bind(t):e)},join:function(e){Le(this.size),e=void 0!==e?""+e:",";var t="",r=!0;return this.__iterate(function(n){r?r=!1:t+=e,t+=null!=n?n.toString():""}),t},keys:function(){return this.__iterator(P)},map:function(e,t){return Yt(this,Ft(this,e,t))},reduce:function(e,t,r){var n,i;return Le(this.size),arguments.length<2?i=!0:n=t,this.__iterate(function(t,a,o){i?(i=!1,n=t):n=e.call(r,n,t,a,o)}),n},reduceRight:function(e,t,r){var n=this.toKeyedSeq().reverse();return n.reduce.apply(n,arguments)},reverse:function(){return Yt(this,Bt(this,!0))},slice:function(e,t){return Yt(this,Vt(this,e,t,!0))},some:function(e,t){return!this.every(Dr(e),t)},sort:function(e){return Yt(this,Qt(this,e))},values:function(){return this.__iterator(j)},butLast:function(){return this.slice(0,-1)},isEmpty:function(){return void 0!==this.size?0===this.size:!this.some(function(){return!0})},count:function(e,t){return T(e?this.toSeq().filter(e,t):this)},countBy:function(e,t){return function(e,t,r){var n=qe().asMutable();return e.__iterate(function(i,a){n.update(t.call(r,i,a,e),0,function(e){return e+1})}),n.asImmutable()}(this,e,t)},equals:function(e){return ye(this,e)},entrySeq:function(){var e=this;if(e._cache)return new ee(e._cache);var t=e.toSeq().map(jr).toIndexedSeq();return t.fromEntrySeq=function(){return e.toSeq()},t},filterNot:function(e,t){return this.filter(Dr(e),t)},findEntry:function(e,t,r){var n=r;return this.__iterate(function(r,i,a){if(e.call(t,r,i,a))return n=[i,r],!1}),n},findKey:function(e,t){var r=this.findEntry(e,t);return r&&r[0]},findLast:function(e,t,r){return this.toKeyedSeq().reverse().find(e,t,r)},findLastEntry:function(e,t,r){return this.toKeyedSeq().reverse().findEntry(e,t,r)},findLastKey:function(e,t){return this.toKeyedSeq().reverse().findKey(e,t)},first:function(){return this.find(A)},flatMap:function(e,t){return Yt(this,function(e,t,r){var n=Zt(e);return e.toSeq().map(function(i,a){return n(t.call(r,i,a,e))}).flatten(!0)}(this,e,t))},flatten:function(e){return Yt(this,Gt(this,e,!0))},fromEntrySeq:function(){return new Lt(this)},get:function(e,t){return this.find(function(t,r){return pe(r,e)},void 0,t)},getIn:function(e,t){for(var r,n=this,i=nr(e);!(r=i.next()).done;){var a=r.value;if((n=n&&n.get?n.get(a,b):b)===b)return t}return n},groupBy:function(e,t){return function(e,t,r){var n=s(e),i=(l(e)?Nt():qe()).asMutable();e.__iterate(function(a,o){i.update(t.call(r,a,o,e),function(e){return(e=e||[]).push(n?[o,a]:a),e})});var a=Zt(e);return i.map(function(t){return Yt(e,a(t))})}(this,e,t)},has:function(e){return this.get(e,b)!==b},hasIn:function(e){return this.getIn(e,b)!==b},isSubset:function(e){return e="function"==typeof e.includes?e:r(e),this.every(function(t){return e.includes(t)})},isSuperset:function(e){return(e="function"==typeof e.isSubset?e:r(e)).isSubset(this)},keyOf:function(e){return this.findKey(function(t){return pe(t,e)})},keySeq:function(){return this.toSeq().map(Pr).toIndexedSeq()},last:function(){return this.toSeq().reverse().first()},lastKeyOf:function(e){return this.toKeyedSeq().reverse().keyOf(e)},max:function(e){return Xt(this,e)},maxBy:function(e,t){return Xt(this,t,e)},min:function(e){return Xt(this,e?Cr(e):qr)},minBy:function(e,t){return Xt(this,t?Cr(t):qr,e)},rest:function(){return this.slice(1)},skip:function(e){return this.slice(Math.max(0,e))},skipLast:function(e){return Yt(this,this.toSeq().reverse().skip(e).reverse())},skipWhile:function(e,t){return Yt(this,Ht(this,e,t,!0))},skipUntil:function(e,t){return this.skipWhile(Dr(e),t)},sortBy:function(e,t){return Yt(this,Qt(this,t,e))},take:function(e){return this.slice(0,Math.max(0,e))},takeLast:function(e){return Yt(this,this.toSeq().reverse().take(e).reverse())},takeWhile:function(e,t){return Yt(this,function(e,t,r){var n=er(e);return n.__iterateUncached=function(n,i){var a=this;if(i)return this.cacheResult().__iterate(n,i);var o=0;return e.__iterate(function(e,i,s){return t.call(r,e,i,s)&&++o&&n(e,i,a)}),o},n.__iteratorUncached=function(n,i){var a=this;if(i)return this.cacheResult().__iterator(n,i);var o=e.__iterator(D,i),s=!0;return new q(function(){if(!s)return{value:void 0,done:!0};var e=o.next();if(e.done)return e;var i=e.value,c=i[0],u=i[1];return t.call(r,u,c,a)?n===D?e:F(n,c,u,e):(s=!1,{value:void 0,done:!0})})},n}(this,e,t))},takeUntil:function(e,t){return this.takeWhile(Dr(e),t)},valueSeq:function(){return this.toIndexedSeq()},hashCode:function(){return this.__hash||(this.__hash=function(e){if(e.size===1/0)return 0;var t=l(e),r=s(e),n=t?1:0;return function(e,t){return t=Ee(t,3432918353),t=Ee(t<<15|t>>>-15,461845907),t=Ee(t<<13|t>>>-13,5),t=Ee((t=(t+3864292196|0)^e)^t>>>16,2246822507),t=xe((t=Ee(t^t>>>13,3266489909))^t>>>16)}(e.__iterate(r?t?function(e,t){n=31*n+Fr(Te(e),Te(t))|0}:function(e,t){n=n+Fr(Te(e),Te(t))|0}:t?function(e){n=31*n+Te(e)|0}:function(e){n=n+Te(e)|0}),n)}(this))}});var Rr=r.prototype;Rr[f]=!0,Rr[L]=Rr.values,Rr.__toJS=Rr.toArray,Rr.__toStringMapper=Mr,Rr.inspect=Rr.toSource=function(){return this.toString()},Rr.chain=Rr.flatMap,Rr.contains=Rr.includes,Nr(n,{flip:function(){return Yt(this,qt(this))},mapEntries:function(e,t){var r=this,n=0;return Yt(this,this.toSeq().map(function(i,a){return e.call(t,[a,i],n++,r)}).fromEntrySeq())},mapKeys:function(e,t){var r=this;return Yt(this,this.toSeq().flip().map(function(n,i){return e.call(t,n,i,r)}).flip())}});var kr=n.prototype;function Pr(e,t){return t}function jr(e,t){return[t,e]}function Dr(e){return function(){return!e.apply(this,arguments)}}function Cr(e){return function(){return-e.apply(this,arguments)}}function Mr(e){return"string"==typeof e?JSON.stringify(e):String(e)}function Lr(){return x(arguments)}function qr(e,t){return e<t?1:e>t?-1:0}function Fr(e,t){return e^t+2654435769+(e<<6)+(e>>2)|0}return kr[d]=!0,kr[L]=Rr.entries,kr.__toJS=Rr.toObject,kr.__toStringMapper=function(e,t){return JSON.stringify(t)+": "+Mr(e)},Nr(i,{toKeyedSeq:function(){return new Dt(this,!1)},filter:function(e,t){return Yt(this,Ut(this,e,t,!1))},findIndex:function(e,t){var r=this.findEntry(e,t);return r?r[0]:-1},indexOf:function(e){var t=this.keyOf(e);return void 0===t?-1:t},lastIndexOf:function(e){var t=this.lastKeyOf(e);return void 0===t?-1:t},reverse:function(){return Yt(this,Bt(this,!1))},slice:function(e,t){return Yt(this,Vt(this,e,t,!1))},splice:function(e,t){var r=arguments.length;if(t=Math.max(0|t,0),0===r||2===r&&!t)return this;e=N(e,e<0?this.count():this.size);var n=this.slice(0,e);return Yt(this,1===r?n:n.concat(x(arguments,2),this.slice(e+t)))},findLastIndex:function(e,t){var r=this.findLastEntry(e,t);return r?r[0]:-1},first:function(){return this.get(0)},flatten:function(e){return Yt(this,Gt(this,e,!1))},get:function(e,t){return(e=O(this,e))<0||this.size===1/0||void 0!==this.size&&e>this.size?t:this.find(function(t,r){return r===e},void 0,t)},has:function(e){return(e=O(this,e))>=0&&(void 0!==this.size?this.size===1/0||e<this.size:-1!==this.indexOf(e))},interpose:function(e){return Yt(this,function(e,t){var r=er(e);return r.size=e.size&&2*e.size-1,r.__iterateUncached=function(r,n){var i=this,a=0;return e.__iterate(function(e,n){return(!a||!1!==r(t,a++,i))&&!1!==r(e,a++,i)},n),a},r.__iteratorUncached=function(r,n){var i,a=e.__iterator(j,n),o=0;return new q(function(){return(!i||o%2)&&(i=a.next()).done?i:o%2?F(r,o++,t):F(r,o++,i.value,i)})},r}(this,e))},interleave:function(){var e=[this].concat(x(arguments)),t=Jt(this.toSeq(),$.of,e),r=t.flatten(!0);return t.size&&(r.size=t.size*e.length),Yt(this,r)},keySeq:function(){return be(0,this.size)},last:function(){return this.get(-1)},skipWhile:function(e,t){return Yt(this,Ht(this,e,t,!1))},zip:function(){var e=[this].concat(x(arguments));return Yt(this,Jt(this,Lr,e))},zipWith:function(e){var t=x(arguments);return t[0]=this,Yt(this,Jt(this,e,t))}}),i.prototype[h]=!0,i.prototype[p]=!0,Nr(a,{get:function(e,t){return this.has(e)?e:t},includes:function(e){return this.has(e)},keySeq:function(){return this.valueSeq()}}),a.prototype.has=Rr.includes,a.prototype.contains=a.prototype.includes,Nr(X,n.prototype),Nr($,i.prototype),Nr(J,a.prototype),Nr(_e,n.prototype),Nr(we,i.prototype),Nr(Se,a.prototype),{Iterable:r,Seq:Q,Collection:ve,Map:qe,OrderedMap:Nt,List:dt,Stack:Sr,Set:cr,OrderedSet:mr,Record:ir,Range:be,Repeat:me,is:pe,fromJS:fe}}()},function(e,t,r){"use strict";function n(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}Object.defineProperty(t,"__esModule",{value:!0}),n(r(187)),n(r(428))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(500);t.collectNamedTerms=n.collectNamedTerms,t.everyTerms=n.everyTerms,t.filterQuadTermNames=n.filterQuadTermNames,t.filterTerms=n.filterTerms,t.forEachTerms=n.forEachTerms,t.getNamedTerms=n.getNamedTerms,t.getTerms=n.getTerms,t.mapTerms=n.mapTerms,t.matchPattern=n.matchPattern,t.matchPatternComplete=n.matchPatternComplete,t.QUAD_TERM_NAMES=n.QUAD_TERM_NAMES,t.reduceTerms=n.reduceTerms,t.someTerms=n.someTerms,t.TRIPLE_TERM_NAMES=n.TRIPLE_TERM_NAMES;const i=r(501);t.getBlankNodes=i.getBlankNodes,t.getDefaultGraphs=i.getDefaultGraphs,t.getLiterals=i.getLiterals,t.getNamedNodes=i.getNamedNodes,t.getTermsOfType=i.getTermsOfType,t.getVariables=i.getVariables,t.TERM_TYPES=i.TERM_TYPES,t.uniqTerms=i.uniqTerms},function(e,t,r){"use strict";function n(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}Object.defineProperty(t,"__esModule",{value:!0}),n(r(537)),n(r(538))},function(e,t,r){var n=r(2).Buffer,i=r(3).Transform,a=r(51).StringDecoder;function o(e){i.call(this),this.hashMode="string"==typeof e,this.hashMode?this[e]=this._finalOrDigest:this.final=this._finalOrDigest,this._final&&(this.__final=this._final,this._final=null),this._decoder=null,this._encoding=null}r(1)(o,i),o.prototype.update=function(e,t,r){"string"==typeof e&&(e=n.from(e,t));var i=this._update(e);return this.hashMode?this:(r&&(i=this._toString(i,r)),i)},o.prototype.setAutoPadding=function(){},o.prototype.getAuthTag=function(){throw new Error("trying to get auth tag in unsupported state")},o.prototype.setAuthTag=function(){throw new Error("trying to set auth tag in unsupported state")},o.prototype.setAAD=function(){throw new Error("trying to set aad in unsupported state")},o.prototype._transform=function(e,t,r){var n;try{this.hashMode?this._update(e):this.push(this._update(e))}catch(e){n=e}finally{r(n)}},o.prototype._flush=function(e){var t;try{this.push(this.__final())}catch(e){t=e}e(t)},o.prototype._finalOrDigest=function(e){var t=this.__final()||n.alloc(0);return e&&(t=this._toString(t,e,!0)),t},o.prototype._toString=function(e,t,r){if(this._decoder||(this._decoder=new a(t),this._encoding=t),this._encoding!==t)throw new Error("can't switch encodings");var n=this._decoder.write(e);return r&&(n+=this._decoder.end()),n},e.exports=o},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){e.Aggregate="aggregate",e.Existence="existence",e.Named="named",e.Operator="operator",e.SpecialOperator="specialOperator",e.Term="term",e.Variable="variable"}(t.ExpressionType||(t.ExpressionType={}))},function(e,t,r){"use strict";var n,i="object"==typeof Reflect?Reflect:null,a=i&&"function"==typeof i.apply?i.apply:function(e,t,r){return Function.prototype.apply.call(e,t,r)};n=i&&"function"==typeof i.ownKeys?i.ownKeys:Object.getOwnPropertySymbols?function(e){return Object.getOwnPropertyNames(e).concat(Object.getOwnPropertySymbols(e))}:function(e){return Object.getOwnPropertyNames(e)};var o=Number.isNaN||function(e){return e!=e};function s(){s.init.call(this)}e.exports=s,s.EventEmitter=s,s.prototype._events=void 0,s.prototype._eventsCount=0,s.prototype._maxListeners=void 0;var c=10;function u(e){return void 0===e._maxListeners?s.defaultMaxListeners:e._maxListeners}function l(e,t,r,n){var i,a,o,s;if("function"!=typeof r)throw new TypeError('The "listener" argument must be of type Function. Received type '+typeof r);if(void 0===(a=e._events)?(a=e._events=Object.create(null),e._eventsCount=0):(void 0!==a.newListener&&(e.emit("newListener",t,r.listener?r.listener:r),a=e._events),o=a[t]),void 0===o)o=a[t]=r,++e._eventsCount;else if("function"==typeof o?o=a[t]=n?[r,o]:[o,r]:n?o.unshift(r):o.push(r),(i=u(e))>0&&o.length>i&&!o.warned){o.warned=!0;var c=new Error("Possible EventEmitter memory leak detected. "+o.length+" "+String(t)+" listeners added. Use emitter.setMaxListeners() to increase limit");c.name="MaxListenersExceededWarning",c.emitter=e,c.type=t,c.count=o.length,s=c,console&&console.warn&&console.warn(s)}return e}function f(e,t,r){var n={fired:!1,wrapFn:void 0,target:e,type:t,listener:r},i=function(){for(var e=[],t=0;t<arguments.length;t++)e.push(arguments[t]);this.fired||(this.target.removeListener(this.type,this.wrapFn),this.fired=!0,a(this.listener,this.target,e))}.bind(n);return i.listener=r,n.wrapFn=i,i}function d(e,t,r){var n=e._events;if(void 0===n)return[];var i=n[t];return void 0===i?[]:"function"==typeof i?r?[i.listener||i]:[i]:r?function(e){for(var t=new Array(e.length),r=0;r<t.length;++r)t[r]=e[r].listener||e[r];return t}(i):p(i,i.length)}function h(e){var t=this._events;if(void 0!==t){var r=t[e];if("function"==typeof r)return 1;if(void 0!==r)return r.length}return 0}function p(e,t){for(var r=new Array(t),n=0;n<t;++n)r[n]=e[n];return r}Object.defineProperty(s,"defaultMaxListeners",{enumerable:!0,get:function(){return c},set:function(e){if("number"!=typeof e||e<0||o(e))throw new RangeError('The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received '+e+".");c=e}}),s.init=function(){void 0!==this._events&&this._events!==Object.getPrototypeOf(this)._events||(this._events=Object.create(null),this._eventsCount=0),this._maxListeners=this._maxListeners||void 0},s.prototype.setMaxListeners=function(e){if("number"!=typeof e||e<0||o(e))throw new RangeError('The value of "n" is out of range. It must be a non-negative number. Received '+e+".");return this._maxListeners=e,this},s.prototype.getMaxListeners=function(){return u(this)},s.prototype.emit=function(e){for(var t=[],r=1;r<arguments.length;r++)t.push(arguments[r]);var n="error"===e,i=this._events;if(void 0!==i)n=n&&void 0===i.error;else if(!n)return!1;if(n){var o;if(t.length>0&&(o=t[0]),o instanceof Error)throw o;var s=new Error("Unhandled error."+(o?" ("+o.message+")":""));throw s.context=o,s}var c=i[e];if(void 0===c)return!1;if("function"==typeof c)a(c,this,t);else{var u=c.length,l=p(c,u);for(r=0;r<u;++r)a(l[r],this,t)}return!0},s.prototype.addListener=function(e,t){return l(this,e,t,!1)},s.prototype.on=s.prototype.addListener,s.prototype.prependListener=function(e,t){return l(this,e,t,!0)},s.prototype.once=function(e,t){if("function"!=typeof t)throw new TypeError('The "listener" argument must be of type Function. Received type '+typeof t);return this.on(e,f(this,e,t)),this},s.prototype.prependOnceListener=function(e,t){if("function"!=typeof t)throw new TypeError('The "listener" argument must be of type Function. Received type '+typeof t);return this.prependListener(e,f(this,e,t)),this},s.prototype.removeListener=function(e,t){var r,n,i,a,o;if("function"!=typeof t)throw new TypeError('The "listener" argument must be of type Function. Received type '+typeof t);if(void 0===(n=this._events))return this;if(void 0===(r=n[e]))return this;if(r===t||r.listener===t)0==--this._eventsCount?this._events=Object.create(null):(delete n[e],n.removeListener&&this.emit("removeListener",e,r.listener||t));else if("function"!=typeof r){for(i=-1,a=r.length-1;a>=0;a--)if(r[a]===t||r[a].listener===t){o=r[a].listener,i=a;break}if(i<0)return this;0===i?r.shift():function(e,t){for(;t+1<e.length;t++)e[t]=e[t+1];e.pop()}(r,i),1===r.length&&(n[e]=r[0]),void 0!==n.removeListener&&this.emit("removeListener",e,o||t)}return this},s.prototype.off=s.prototype.removeListener,s.prototype.removeAllListeners=function(e){var t,r,n;if(void 0===(r=this._events))return this;if(void 0===r.removeListener)return 0===arguments.length?(this._events=Object.create(null),this._eventsCount=0):void 0!==r[e]&&(0==--this._eventsCount?this._events=Object.create(null):delete r[e]),this;if(0===arguments.length){var i,a=Object.keys(r);for(n=0;n<a.length;++n)"removeListener"!==(i=a[n])&&this.removeAllListeners(i);return this.removeAllListeners("removeListener"),this._events=Object.create(null),this._eventsCount=0,this}if("function"==typeof(t=r[e]))this.removeListener(e,t);else if(void 0!==t)for(n=t.length-1;n>=0;n--)this.removeListener(e,t[n]);return this},s.prototype.listeners=function(e){return d(this,e,!0)},s.prototype.rawListeners=function(e){return d(this,e,!1)},s.listenerCount=function(e,t){return"function"==typeof e.listenerCount?e.listenerCount(t):h.call(e,t)},s.prototype.listenerCount=h,s.prototype.eventNames=function(){return this._eventsCount>0?n(this._events):[]}},function(e,t,r){"use strict";var n=r(67),i=Object.keys||function(e){var t=[];for(var r in e)t.push(r);return t};e.exports=f;var a=r(50);a.inherits=r(1);var o=r(142),s=r(91);a.inherits(f,o);for(var c=i(s.prototype),u=0;u<c.length;u++){var l=c[u];f.prototype[l]||(f.prototype[l]=s.prototype[l])}function f(e){if(!(this instanceof f))return new f(e);o.call(this,e),s.call(this,e),e&&!1===e.readable&&(this.readable=!1),e&&!1===e.writable&&(this.writable=!1),this.allowHalfOpen=!0,e&&!1===e.allowHalfOpen&&(this.allowHalfOpen=!1),this.once("end",d)}function d(){this.allowHalfOpen||this._writableState.ended||n.nextTick(h,this)}function h(e){e.end()}Object.defineProperty(f.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),Object.defineProperty(f.prototype,"destroyed",{get:function(){return void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed&&this._writableState.destroyed)},set:function(e){void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed=e,this._writableState.destroyed=e)}}),f.prototype._destroy=function(e,t){this.push(null),this.end(),n.nextTick(t,e)}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(499))},function(e,t){},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(293))},function(e){e.exports=JSON.parse('{"@context":{"acl":"http://www.w3.org/ns/auth/acl#","app":"http://www.w3.org/ns/solid/app#","as":"https://www.w3.org/ns/activitystreams#","cert":"http://www.w3.org/ns/auth/cert#","dc":"http://purl.org/dc/elements/1.1/","dct":"http://purl.org/dc/terms/","foaf":"http://xmlns.com/foaf/0.1/","ldp":"http://www.w3.org/ns/ldp#","owl":"http://www.w3.org/2002/07/owl#","pim":"http://www.w3.org/ns/pim/space#","rdf":"http://www.w3.org/1999/02/22-rdf-syntax-ns#","rdfs":"http://www.w3.org/2000/01/rdf-schema#","schema":"http://schema.org/","sioc":"http://rdfs.org/sioc/ns#","solid":"http://www.w3.org/ns/solid/terms#","stat":"http://www.w3.org/ns/posix/stat#","vcard":"http://www.w3.org/2006/vcard/ns#","xsd":"http://www.w3.org/2001/XMLSchema#","accessControl":"acl:accessControl","accessTo":"acl:accessTo","accessToClass":"acl:accessToClass","agent":"acl:agent","agents":"acl:agent","agentClass":"acl:agentClass","agentClasses":"acl:agentClass","agentGroup":"acl:agentGroup","agentGroups":"acl:agentGroup","defaultAcl":"acl:default","defaultAclForNew":"acl:defaultForNew","delegates":"acl:delegates","mode":"acl:mode","modes":"acl:mode","origin":"acl:origin","origins":"acl:origin","actor":"as:actor","attachment":"as:attachment","attributedTo":"as:attributedTo","author":"as:author","bcc":"as:bcc","bto":"as:bto","cc":"as:cc","inReplyTo":"as:inReplyTo","object":"as:object","publicationDate":"as:published","subject":"as:subject","summary":"as:summary","target":"as:target","to":"as:to","abstract":"dc:abstract","abstracts":"dc:abstract","created":"dc:created","license":"dc:license","modified":"dc:modified","title":"dc:title","titles":"dc:title","account":"foaf:account","accounts":"foaf:account","age":"foaf:age","basedNear":"foaf:based_near","birthday":"foaf:birthday","blog":"foaf:weblog","depiction":"foaf:depiction","depicts":"foaf:depicts","email":"foaf:mbox","familyName":"foaf:familyName","firstName":"foaf:givenName","friend":"foaf:knows","friends":"foaf:knows","gender":"foaf:gender","givenName":"foaf:givenName","homepage":"foaf:homepage","image":"foaf:img","images":"foaf:img","interest":"foaf:topic_interest","interests":"foaf:topic_interest","knows":"foaf:knows","lastName":"foaf:familyName","logo":"foaf:logo","made":"foaf:made","maker":"foaf:maker","member":"foaf:member","name":"foaf:name","nick":"foaf:nick","page":"foaf:page","pages":"foaf:page","primaryTopic":"foaf:primaryTopic","primaryTopicOf":"foaf:primaryTopicOf","publication":"foaf:publications","publications":"foaf:publications","thumbnail":"foaf:thumbnail","thumbnails":"foaf:thumbnail","topic":"foaf:topic","topics":"foaf:topic","inbox":"ldp:inbox","inboxes":"ldp:inbox","storage":"pim:storage","preferences":"pim:preferencesFile","workspace":"pim:workspace","type":"rdf:type","types":"rdf:type","comment":"rdfs:comment","comments":"rdfs:comment","label":"rdfs:label","labels":"rdfs:label","seeAlso":"rdfs:seeAlso","definedBy":"rdfs:isDefinedBy","oidcIssuer":"solid:oidcIssuer","publicTypeIndex":"solid:publicTypeIndex","publicTypeIndexes":"solid:publicTypeIndex","privateTypeIndex":"solid:privateTypeIndex","privateTypeIndexes":"solid:privateTypeIndex"}}')},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(326))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(341))},function(e,t,r){"use strict";function n(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}Object.defineProperty(t,"__esModule",{value:!0}),n(r(152)),n(r(356))},function(e,t){e.exports=function(e){return e.webpackPolyfill||(e.deprecate=function(){},e.paths=[],e.children||(e.children=[]),Object.defineProperty(e,"loaded",{enumerable:!0,get:function(){return e.l}}),Object.defineProperty(e,"id",{enumerable:!0,get:function(){return e.i}}),e.webpackPolyfill=1),e}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(23);class i{constructor(e){this.parsingContext=e.parsingContext,this.dataFactory=e.dataFactory||r(5),this.rdfFirst=this.dataFactory.namedNode(i.RDF+"first"),this.rdfRest=this.dataFactory.namedNode(i.RDF+"rest"),this.rdfNil=this.dataFactory.namedNode(i.RDF+"nil"),this.rdfType=this.dataFactory.namedNode(i.RDF+"type")}static getContextValue(e,t,r,n){const i=e[r];if(!i)return n;const a=i[t];return void 0===a?n:a}static getContextValueContainer(e,t){return i.getContextValue(e,"@container",t,"@set")}static getContextValueType(e,t){return i.getContextValue(e,"@type",t,null)}static getContextValueLanguage(e,t){return i.getContextValue(e,"@language",t,e["@language"]||null)}static isContextValueReverse(e,t){return!!i.getContextValue(e,"@reverse",t,null)}static isPropertyReverse(e,t,r){return"@reverse"===r!==i.isContextValueReverse(e,t)}static isKeyword(e){return"string"==typeof e&&"@"===e[0]}static isValidIri(e){return n.ContextParser.isValidIri(e)}async validateValueIndexes(e){if(this.parsingContext.validateValueIndexes){const t={};for(const r of e)if(r&&"object"==typeof r){const e=r["@id"],n=r["@index"];if(e&&n){const r=t[e];if(r&&r!==n)throw new Error(`Conflicting @index value for ${e}`);t[e]=n}}}}async valueToTerm(e,t,r,n,a){const o=typeof r;switch(o){case"object":if(null==r)return null;if(Array.isArray(r))return"@list"===i.getContextValueContainer(e,t)&&0===r.length?this.rdfNil:(await this.validateValueIndexes(r),null);if("@value"in(r=await this.unaliasKeywords(r,a,n))){let i,o,s,c;for(t in r){const e=r[t];switch(t){case"@value":i=e;break;case"@language":o=e;break;case"@type":s=e;break;case"@index":c=e;break;default:throw new Error(`Unknown value entry '${t}' in @value: ${JSON.stringify(r)}`)}}if(null===i)return null;if("object"==typeof i)throw new Error(`The value of an '@value' can not be an object, got '${JSON.stringify(i)}'`);if(this.parsingContext.validateValueIndexes&&c&&"string"!=typeof c)throw new Error(`The value of an '@index' must be a string, got '${JSON.stringify(c)}'`);if(o){if(s)throw new Error(`Can not have both '@language' and '@type' in a value: '${JSON.stringify(r)}'`);if("string"!=typeof o)throw new Error(`The value of an '@language' must be a string, got '${JSON.stringify(o)}'`);if("string"!=typeof i)throw new Error(`When an '@language' is set, the value of '@value' must be a string, got '${JSON.stringify(i)}'`);return this.dataFactory.literal(i,o)}if(s){if("string"!=typeof s)throw new Error(`The value of an '@type' must be a string, got '${JSON.stringify(s)}'`);const t=this.createVocabOrBaseTerm(e,s);if(!t)return null;if("NamedNode"!==t.termType)throw new Error(`Illegal value type (${t.termType}): ${s}`);return this.dataFactory.literal(i,t)}return await this.valueToTerm({},t,i,n,a)}if("@set"in r){if(Object.keys(r).length>1)throw new Error(`Found illegal neighbouring entries next to @set in value: ${JSON.stringify(r)}`);return null}if("@list"in r){if(Object.keys(r).length>1)throw new Error(`Found illegal neighbouring entries next to @set in value: ${JSON.stringify(r)}`);const e=r["@list"];return Array.isArray(e)?0===e.length?this.rdfNil:null:this.valueToTerm(await this.parsingContext.getContext(a),t,e,n-1,a.slice(0,-1))}return"@reverse"in r?null:"@id"in r?"@vocab"===r["@type"]?this.createVocabOrBaseTerm(e,r["@id"]):this.resourceToTerm(e,r["@id"]):this.parsingContext.emittedStack[n+1]?this.parsingContext.idStack[n+1]||(this.parsingContext.idStack[n+1]=this.dataFactory.blankNode()):null;case"string":return this.stringValueToTerm(e,t,r,null);case"boolean":return this.stringValueToTerm(e,t,Boolean(r).toString(),this.dataFactory.namedNode(i.XSD_BOOLEAN));case"number":return this.stringValueToTerm(e,t,r,this.dataFactory.namedNode(r%1==0?i.XSD_INTEGER:i.XSD_DOUBLE));default:this.parsingContext.emitError(new Error(`Could not determine the RDF type of a ${o}`))}}predicateToTerm(e,t){const r=n.ContextParser.expandTerm(t,e,!0);return r?"_"===r[0]&&":"===r[1]?this.parsingContext.produceGeneralizedRdf?this.dataFactory.blankNode(r.substr(2)):null:i.isValidIri(r)?this.dataFactory.namedNode(r):r&&this.parsingContext.errorOnInvalidProperties?void this.parsingContext.emitError(new Error(`Invalid predicate IRI: ${r}`)):null:null}resourceToTerm(e,t){if(t.startsWith("_:"))return this.dataFactory.blankNode(t.substr(2));const r=n.ContextParser.expandTerm(t,e,!1);if(!i.isValidIri(r)){if(!r||!this.parsingContext.errorOnInvalidProperties)return null;this.parsingContext.emitError(new Error(`Invalid resource IRI: ${r}`))}return this.dataFactory.namedNode(r)}createVocabOrBaseTerm(e,t){if(t.startsWith("_:"))return this.dataFactory.blankNode(t.substr(2));let r=n.ContextParser.expandTerm(t,e,!0);if(r===t&&(r=n.ContextParser.expandTerm(t,e,!1)),!i.isValidIri(r)){if(!r||!this.parsingContext.errorOnInvalidProperties)return null;this.parsingContext.emitError(new Error(`Invalid term IRI: ${r}`))}return this.dataFactory.namedNode(r)}intToString(e,t){if("number"==typeof e){if(Number.isFinite(e)){return e%1==0&&t.value!==i.XSD_DOUBLE?Number(e).toString():e.toExponential(15).replace(/(\d)0*e\+?/,"$1E")}return e>0?"INF":"-INF"}return e}stringValueToTerm(e,t,r,n){const a=i.getContextValueType(e,t);if(a){if("@id"===a)return this.resourceToTerm(e,this.intToString(r,n));if("@vocab"===a)return this.createVocabOrBaseTerm(e,this.intToString(r,n));n=this.dataFactory.namedNode(a)}if(!n){const a=i.getContextValueLanguage(e,t);if(a)return this.dataFactory.literal(this.intToString(r,n),a)}return this.dataFactory.literal(this.intToString(r,n),n)}async unaliasKeyword(e,t,r,n){if(Number.isInteger(e))return e;if(!n){const e=this.parsingContext.unaliasedKeywordCacheStack[r];if(e)return e}if(!i.isKeyword(e)){let r=(await this.parsingContext.getContext(t))[e];r&&"object"==typeof r&&(r=r["@id"]),i.isKeyword(r)&&(e=r)}return n?e:this.parsingContext.unaliasedKeywordCacheStack[r]=e}async unaliasKeywordParent(e,t){return await this.unaliasKeyword(t>0&&e[t-1],e,t-1)}async unaliasKeywords(e,t,r){const n={};for(const i in e)n[await this.unaliasKeyword(i,t,r+1,!0)]=e[i];return n}isLiteral(e){for(let t=e;t>=0;t--)if(this.parsingContext.literalStack[t])return!0;return!1}async getDepthOffsetGraph(e,t){for(let r=e-1;r>0;r--)if("@graph"===await this.unaliasKeyword(t[r],t,r))return e-r-1;return-1}validateReverseSubject(e){if("Literal"===e.termType)throw new Error(`Found illegal literal in subject position: ${e.value}`)}getDefaultGraph(){return this.parsingContext.defaultGraph||this.dataFactory.defaultGraph()}}i.XSD="http://www.w3.org/2001/XMLSchema#",i.XSD_BOOLEAN=i.XSD+"boolean",i.XSD_INTEGER=i.XSD+"integer",i.XSD_DOUBLE=i.XSD+"double",i.RDF="http://www.w3.org/1999/02/22-rdf-syntax-ns#",t.Util=i},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});t.DirectiveNodeHandlerAdapter=class{constructor(e,t,r){this.targetKind=e,this.util=t,this.settings=r}getDirectiveConditionalValue(e,t){const r=this.util.getArgument(e.arguments,"if");if(!r)throw new Error(`The directive ${e.name.value} is missing an if-argument.`);const n=this.util.handleNodeValue(r.value,r.name.value,t);if(1!==n.terms.length)throw new Error(`Can not apply the directive ${e.name.value} with a list.`);return n.terms[0]}isDirectiveScopeAll(e){const t=this.util.getArgument(e.arguments,"scope");return t&&"EnumValue"===t.value.kind&&"all"===t.value.value}}},function(e,t,r){"use strict";(function(t,n){var i=65536,a=4294967295;var o=r(2).Buffer,s=t.crypto||t.msCrypto;s&&s.getRandomValues?e.exports=function(e,t){if(e>a)throw new RangeError("requested too many random bytes");var r=o.allocUnsafe(e);if(e>0)if(e>i)for(var c=0;c<e;c+=i)s.getRandomValues(r.slice(c,c+i));else s.getRandomValues(r);if("function"==typeof t)return n.nextTick(function(){t(null,r)});return r}:e.exports=function(){throw new Error("Secure random number generation is not supported by this browser.\nUse Chrome, Firefox or Internet Explorer 11")}}).call(this,r(9),r(13))},function(e,t,r){"use strict";var n=r(1),i=r(101),a=r(102),o=r(103),s=r(29);function c(e){s.call(this,"digest"),this._hash=e}n(c,s),c.prototype._update=function(e){this._hash.update(e)},c.prototype._final=function(){return this._hash.digest()},e.exports=function(e){return"md5"===(e=e.toLowerCase())?new i:"rmd160"===e||"ripemd160"===e?new a:new c(o(e))}},function(e,t,r){var n=r(2).Buffer;function i(e,t){this._block=n.alloc(e),this._finalSize=t,this._blockSize=e,this._len=0}i.prototype.update=function(e,t){"string"==typeof e&&(t=t||"utf8",e=n.from(e,t));for(var r=this._block,i=this._blockSize,a=e.length,o=this._len,s=0;s<a;){for(var c=o%i,u=Math.min(a-s,i-c),l=0;l<u;l++)r[c+l]=e[s+l];s+=u,(o+=u)%i==0&&this._update(r)}return this._len+=a,this},i.prototype.digest=function(e){var t=this._len%this._blockSize;this._block[t]=128,this._block.fill(0,t+1),t>=this._finalSize&&(this._update(this._block),this._block.fill(0));var r=8*this._len;if(r<=4294967295)this._block.writeUInt32BE(r,this._blockSize-4);else{var n=(4294967295&r)>>>0,i=(r-n)/4294967296;this._block.writeUInt32BE(i,this._blockSize-8),this._block.writeUInt32BE(n,this._blockSize-4)}this._update(this._block);var a=this._hash();return e?a.toString(e):a},i.prototype._update=function(){throw new Error("_update must be implemented by subclass")},e.exports=i},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(669);t.AsyncEvaluator=n.AsyncEvaluator;var i=r(282);t.SyncEvaluator=i.SyncEvaluator;var a=r(684);t.AggregateEvaluator=a.AggregateEvaluator;var o=r(22);t.ExpressionError=o.ExpressionError,t.isExpressionError=o.isExpressionError},function(e,t,r){"use strict";function n(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}Object.defineProperty(t,"__esModule",{value:!0}),n(r(30)),n(r(670)),n(r(671)),n(r(672)),n(r(673)),n(r(674)),n(r(675)),n(r(676))},function(e,t,r){r(309),e.exports=self.fetch.bind(self)},function(e,t){var r=9007199254740991,n="[object Arguments]",i="[object Function]",a="[object GeneratorFunction]",o=/^(?:0|[1-9]\d*)$/;function s(e,t,r){switch(r.length){case 0:return e.call(t);case 1:return e.call(t,r[0]);case 2:return e.call(t,r[0],r[1]);case 3:return e.call(t,r[0],r[1],r[2])}return e.apply(t,r)}var c,u,l=Object.prototype,f=l.hasOwnProperty,d=l.toString,h=l.propertyIsEnumerable,p=(c=Object.keys,u=Object,function(e){return c(u(e))}),y=Math.max,m=!h.call({valueOf:1},"valueOf");function g(e,t){var r=S(e)||function(e){return function(e){return function(e){return!!e&&"object"==typeof e}(e)&&E(e)}(e)&&f.call(e,"callee")&&(!h.call(e,"callee")||d.call(e)==n)}(e)?function(e,t){for(var r=-1,n=Array(e);++r<e;)n[r]=t(r);return n}(e.length,String):[],i=r.length,a=!!i;for(var o in e)!t&&!f.call(e,o)||a&&("length"==o||v(o,i))||r.push(o);return r}function b(e,t,r){var n=e[t];f.call(e,t)&&w(n,r)&&(void 0!==r||t in e)||(e[t]=r)}function v(e,t){return!!(t=null==t?r:t)&&("number"==typeof e||o.test(e))&&e>-1&&e%1==0&&e<t}function _(e){var t=e&&e.constructor;return e===("function"==typeof t&&t.prototype||l)}function w(e,t){return e===t||e!=e&&t!=t}var S=Array.isArray;function E(e){return null!=e&&function(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=r}(e.length)&&!function(e){var t=x(e)?d.call(e):"";return t==i||t==a}(e)}function x(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}var T,O=(T=function(e,t){if(m||_(t)||E(t))!function(e,t,r,n){r||(r={});for(var i=-1,a=t.length;++i<a;){var o=t[i],s=n?n(r[o],e[o],o,r,e):void 0;b(r,o,void 0===s?e[o]:s)}}(t,function(e){return E(e)?g(e):function(e){if(!_(e))return p(e);var t=[];for(var r in Object(e))f.call(e,r)&&"constructor"!=r&&t.push(r);return t}(e)}(t),e);else for(var r in t)f.call(t,r)&&b(e,r,t[r])},function(e,t){return t=y(void 0===t?e.length-1:t,0),function(){for(var r=arguments,n=-1,i=y(r.length-t,0),a=Array(i);++n<i;)a[n]=r[t+n];n=-1;for(var o=Array(t+1);++n<t;)o[n]=r[n];return o[t]=a,s(e,this,o)}}(function(e,t){var r=-1,n=t.length,i=n>1?t[n-1]:void 0,a=n>2?t[2]:void 0;for(i=T.length>3&&"function"==typeof i?(n--,i):void 0,a&&function(e,t,r){if(!x(r))return!1;var n=typeof t;return!!("number"==n?E(r)&&v(t,r.length):"string"==n&&t in r)&&w(r[t],e)}(t[0],t[1],a)&&(i=n<3?void 0:i,n=1),e=Object(e);++r<n;){var o=t[r];o&&T(e,o,r,i)}return e}));e.exports=O},function(e,t,r){(function(e){function r(e){return Object.prototype.toString.call(e)}t.isArray=function(e){return Array.isArray?Array.isArray(e):"[object Array]"===r(e)},t.isBoolean=function(e){return"boolean"==typeof e},t.isNull=function(e){return null===e},t.isNullOrUndefined=function(e){return null==e},t.isNumber=function(e){return"number"==typeof e},t.isString=function(e){return"string"==typeof e},t.isSymbol=function(e){return"symbol"==typeof e},t.isUndefined=function(e){return void 0===e},t.isRegExp=function(e){return"[object RegExp]"===r(e)},t.isObject=function(e){return"object"==typeof e&&null!==e},t.isDate=function(e){return"[object Date]"===r(e)},t.isError=function(e){return"[object Error]"===r(e)||e instanceof Error},t.isFunction=function(e){return"function"==typeof e},t.isPrimitive=function(e){return null===e||"boolean"==typeof e||"number"==typeof e||"string"==typeof e||"symbol"==typeof e||void 0===e},t.isBuffer=e.isBuffer}).call(this,r(7).Buffer)},function(e,t,r){"use strict";var n=r(2).Buffer,i=n.isEncoding||function(e){switch((e=""+e)&&e.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return!0;default:return!1}};function a(e){var t;switch(this.encoding=function(e){var t=function(e){if(!e)return"utf8";for(var t;;)switch(e){case"utf8":case"utf-8":return"utf8";case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return"utf16le";case"latin1":case"binary":return"latin1";case"base64":case"ascii":case"hex":return e;default:if(t)return;e=(""+e).toLowerCase(),t=!0}}(e);if("string"!=typeof t&&(n.isEncoding===i||!i(e)))throw new Error("Unknown encoding: "+e);return t||e}(e),this.encoding){case"utf16le":this.text=c,this.end=u,t=4;break;case"utf8":this.fillLast=s,t=4;break;case"base64":this.text=l,this.end=f,t=3;break;default:return this.write=d,void(this.end=h)}this.lastNeed=0,this.lastTotal=0,this.lastChar=n.allocUnsafe(t)}function o(e){return e<=127?0:e>>5==6?2:e>>4==14?3:e>>3==30?4:e>>6==2?-1:-2}function s(e){var t=this.lastTotal-this.lastNeed,r=function(e,t,r){if(128!=(192&t[0]))return e.lastNeed=0,"�";if(e.lastNeed>1&&t.length>1){if(128!=(192&t[1]))return e.lastNeed=1,"�";if(e.lastNeed>2&&t.length>2&&128!=(192&t[2]))return e.lastNeed=2,"�"}}(this,e);return void 0!==r?r:this.lastNeed<=e.length?(e.copy(this.lastChar,t,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal)):(e.copy(this.lastChar,t,0,e.length),void(this.lastNeed-=e.length))}function c(e,t){if((e.length-t)%2==0){var r=e.toString("utf16le",t);if(r){var n=r.charCodeAt(r.length-1);if(n>=55296&&n<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1],r.slice(0,-1)}return r}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=e[e.length-1],e.toString("utf16le",t,e.length-1)}function u(e){var t=e&&e.length?this.write(e):"";if(this.lastNeed){var r=this.lastTotal-this.lastNeed;return t+this.lastChar.toString("utf16le",0,r)}return t}function l(e,t){var r=(e.length-t)%3;return 0===r?e.toString("base64",t):(this.lastNeed=3-r,this.lastTotal=3,1===r?this.lastChar[0]=e[e.length-1]:(this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1]),e.toString("base64",t,e.length-r))}function f(e){var t=e&&e.length?this.write(e):"";return this.lastNeed?t+this.lastChar.toString("base64",0,3-this.lastNeed):t}function d(e){return e.toString(this.encoding)}function h(e){return e&&e.length?this.write(e):""}t.StringDecoder=a,a.prototype.write=function(e){if(0===e.length)return"";var t,r;if(this.lastNeed){if(void 0===(t=this.fillLast(e)))return"";r=this.lastNeed,this.lastNeed=0}else r=0;return r<e.length?t?t+this.text(e,r):this.text(e,r):t||""},a.prototype.end=function(e){var t=e&&e.length?this.write(e):"";return this.lastNeed?t+"�":t},a.prototype.text=function(e,t){var r=function(e,t,r){var n=t.length-1;if(n<r)return 0;var i=o(t[n]);if(i>=0)return i>0&&(e.lastNeed=i-1),i;if(--n<r||-2===i)return 0;if((i=o(t[n]))>=0)return i>0&&(e.lastNeed=i-2),i;if(--n<r||-2===i)return 0;if((i=o(t[n]))>=0)return i>0&&(2===i?i=0:e.lastNeed=i-3),i;return 0}(this,e,t);if(!this.lastNeed)return e.toString("utf8",t);this.lastTotal=r;var n=e.length-(r-this.lastNeed);return e.copy(this.lastChar,0,n),e.toString("utf8",t,n)},a.prototype.fillLast=function(e){if(this.lastNeed<=e.length)return e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,e.length),this.lastNeed-=e.length}},function(e,t,r){"use strict";function n(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}Object.defineProperty(t,"__esModule",{value:!0}),n(r(355)),n(r(358))},function(e,t,r){var n,i,a=r(69),o=a.rdf,s=a.xsd,c=0;class u{constructor(e){this.id=e}get value(){return this.id}equals(e){return e instanceof u?this.id===e.id:!!e&&this.termType===e.termType&&this.value===e.value}toJSON(){return{termType:this.termType,value:this.value}}}class l extends u{get termType(){return"NamedNode"}}class f extends u{get termType(){return"Literal"}get value(){return this.id.substring(1,this.id.lastIndexOf('"'))}get language(){var e=this.id,t=e.lastIndexOf('"')+1;return t<e.length&&"@"===e[t++]?e.substr(t).toLowerCase():""}get datatype(){return new l(this.datatypeString)}get datatypeString(){var e,t=this.id,r=t.lastIndexOf('"')+1;return r<t.length&&"^"===(e=t[r])?t.substr(r+2):"@"!==e?s.string:o.langString}equals(e){return e instanceof f?this.id===e.id:!!e&&!!e.datatype&&this.termType===e.termType&&this.value===e.value&&this.language===e.language&&this.datatype.value===e.datatype.value}toJSON(){return{termType:this.termType,value:this.value,language:this.language,datatype:{termType:"NamedNode",value:this.datatypeString}}}}class d extends u{constructor(e){super("_:"+e)}get termType(){return"BlankNode"}get value(){return this.id.substr(2)}}class h extends u{constructor(e){super("?"+e)}get termType(){return"Variable"}get value(){return this.id.substr(1)}}class p extends u{constructor(){return super(""),i||this}get termType(){return"DefaultGraph"}equals(e){return this===e||!!e&&this.termType===e.termType}}i=new p;class y{constructor(e,t,r,n){this.subject=e,this.predicate=t,this.object=r,this.graph=n||i}toJSON(){return{subject:this.subject.toJSON(),predicate:this.predicate.toJSON(),object:this.object.toJSON(),graph:this.graph.toJSON()}}equals(e){return!!e&&this.subject.equals(e.subject)&&this.predicate.equals(e.predicate)&&this.object.equals(e.object)&&this.graph.equals(e.graph)}}function m(e,t,r,n){return new y(e,t,r,n)}e.exports=n={namedNode:function(e){return new l(e)},blankNode:function(e){return e||(e="n3-"+c++),new d(e)},variable:function(e){return new h(e)},literal:function(e,t){if("string"==typeof t)return new f('"'+e+'"@'+t.toLowerCase());var r=t&&t.value||"";if(!r)switch(typeof e){case"boolean":r=s.boolean;break;case"number":Number.isFinite(e)?r=Number.isInteger(e)?s.integer:s.double:(r=s.double,Number.isNaN(e)||(e=e>0?"INF":"-INF"));break;default:return new f('"'+e+'"')}return new f('"'+e+'"^^'+r)},defaultGraph:function(){return i},quad:m,triple:m,internal:{Term:u,NamedNode:l,BlankNode:d,Variable:h,Literal:f,DefaultGraph:p,Quad:y,Triple:y,fromId:function(e,t){if(t=t||n,!e)return t.defaultGraph();switch(e[0]){case"_":return t.blankNode(e.substr(2));case"?":return t.variable(e.substr(1));case'"':if(t===n)return new f(e);if('"'===e[e.length-1])return t.literal(e.substr(1,e.length-2));var r=e.lastIndexOf('"',e.length-1);return t.literal(e.substr(1,r-1),"@"===e[r+1]?e.substr(r+2):t.namedNode(e.substr(r+3)));default:return t.namedNode(e)}},toId:function(e){if("string"==typeof e)return e;if(e instanceof u)return e.id;if(!e)return i.id;switch(e.termType){case"NamedNode":return e.value;case"BlankNode":return"_:"+e.value;case"Variable":return"?"+e.value;case"DefaultGraph":return"";case"Literal":return'"'+e.value+'"'+(e.language?"@"+e.language:e.datatype&&e.datatype.value!==s.string?"^^"+e.datatype.value:"");default:throw new Error("Unexpected termType: "+e.termType)}}}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});t.EntryHandlerKeyword=class{constructor(e){this.keyword=e}isPropertyHandler(){return!1}async validate(e,t,r,n,i){return!1}async test(e,t,r,n,i){return r===this.keyword}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(167);t.isTag=function(e){return n.isTag(e)},t.isCDATA=function(e){return"cdata"===e.type},t.isText=function(e){return"text"===e.type},t.isComment=function(e){return"comment"===e.type},t.hasChildren=function(e){return Object.prototype.hasOwnProperty.call(e,"children")}},function(e,t){e.exports={Text:"text",Directive:"directive",Comment:"comment",Script:"script",Style:"style",Tag:"tag",CDATA:"cdata",Doctype:"doctype",isTag:function(e){return"tag"===e.type||"script"===e.type||"style"===e.type}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){e[e.SINGLE=0]="SINGLE",e[e.PLURAL=1]="PLURAL"}(t.SingularizeState||(t.SingularizeState={}))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});t.Translator=class{constructor(){this.supportedRdfDatatypes=[],this.fromRdfHandlers={},this.toRdfHandlers={}}static incorrectRdfDataType(e){throw new Error(`Invalid RDF ${e.datatype.value} value: '${e.value}'`)}registerHandler(e,t,r){for(const r of t)this.supportedRdfDatatypes.push(r),this.fromRdfHandlers[r.value]=e;for(const t of r){let r=this.toRdfHandlers[t];r||(this.toRdfHandlers[t]=r=[]),r.push(e)}}fromRdf(e,t){const r=this.fromRdfHandlers[e.datatype.value];return r?r.fromRdf(e,t):e.value}toRdf(e,t){const r=this.toRdfHandlers[typeof e];if(r)for(const n of r){const r=n.toRdf(e,t);if(r)return r}throw new Error(`Invalid JavaScript value: '${e}'`)}getSupportedRdfDatatypes(){return this.supportedRdfDatatypes}getSupportedJavaScriptPrimitives(){return Object.keys(this.toRdfHandlers)}}},function(e,t,r){(function(t){e.exports=function(e,r){for(var n=Math.min(e.length,r.length),i=new t(n),a=0;a<n;++a)i[a]=e[a]^r[a];return i}}).call(this,r(7).Buffer)},function(e,t,r){"use strict";var n=r(21),i=r(16);function a(){this.pending=null,this.pendingTotal=0,this.blockSize=this.constructor.blockSize,this.outSize=this.constructor.outSize,this.hmacStrength=this.constructor.hmacStrength,this.padLength=this.constructor.padLength/8,this.endian="big",this._delta8=this.blockSize/8,this._delta32=this.blockSize/32}t.BlockHash=a,a.prototype.update=function(e,t){if(e=n.toArray(e,t),this.pending?this.pending=this.pending.concat(e):this.pending=e,this.pendingTotal+=e.length,this.pending.length>=this._delta8){var r=(e=this.pending).length%this._delta8;this.pending=e.slice(e.length-r,e.length),0===this.pending.length&&(this.pending=null),e=n.join32(e,0,e.length-r,this.endian);for(var i=0;i<e.length;i+=this._delta32)this._update(e,i,i+this._delta32)}return this},a.prototype.digest=function(e){return this.update(this._pad()),i(null===this.pending),this._digest(e)},a.prototype._pad=function(){var e=this.pendingTotal,t=this._delta8,r=t-(e+this.padLength)%t,n=new Array(r+this.padLength);n[0]=128;for(var i=1;i<r;i++)n[i]=0;if(e<<=3,"big"===this.endian){for(var a=8;a<this.padLength;a++)n[i++]=0;n[i++]=0,n[i++]=0,n[i++]=0,n[i++]=0,n[i++]=e>>>24&255,n[i++]=e>>>16&255,n[i++]=e>>>8&255,n[i++]=255&e}else for(n[i++]=255&e,n[i++]=e>>>8&255,n[i++]=e>>>16&255,n[i++]=e>>>24&255,n[i++]=0,n[i++]=0,n[i++]=0,n[i++]=0,a=8;a<this.padLength;a++)n[i++]=0;return n}},function(e,t,r){var n=t;n.bignum=r(11),n.define=r(646).define,n.base=r(62),n.constants=r(272),n.decoders=r(651),n.encoders=r(653)},function(e,t,r){var n=t;n.Reporter=r(648).Reporter,n.DecoderBuffer=r(271).DecoderBuffer,n.EncoderBuffer=r(271).EncoderBuffer,n.Node=r(649)},function(e,t){e.exports=solid.auth},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getThen=i,t.toIterablePromise=function(e){"function"==typeof e&&(e=a(e()));return{[Symbol.asyncIterator]:()=>e[Symbol.asyncIterator](),get then(){return i(()=>(0,n.getFirstItem)(this))},catch(e){return this.then(null,e)},finally(e){return this.then().finally(e)}}},t.memoizeIterable=a;var n=r(87);function i(e){return(t,r)=>e().then(t,r)}function a(e){const t=[];let r=e[Symbol.asyncIterator]();return{[Symbol.asyncIterator](){let e=0;return{async next(){if(e<t.length)return t[e++];if(!r)return{done:!0};const n=t[e++]=r.next();return(await n).done&&(r=null),n}}}}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(310))},function(e,t,r){(function(e){var n=Object.getOwnPropertyDescriptors||function(e){for(var t=Object.keys(e),r={},n=0;n<t.length;n++)r[t[n]]=Object.getOwnPropertyDescriptor(e,t[n]);return r},i=/%[sdj%]/g;t.format=function(e){if(!g(e)){for(var t=[],r=0;r<arguments.length;r++)t.push(s(arguments[r]));return t.join(" ")}r=1;for(var n=arguments,a=n.length,o=String(e).replace(i,function(e){if("%%"===e)return"%";if(r>=a)return e;switch(e){case"%s":return String(n[r++]);case"%d":return Number(n[r++]);case"%j":try{return JSON.stringify(n[r++])}catch(e){return"[Circular]"}default:return e}}),c=n[r];r<a;c=n[++r])y(c)||!_(c)?o+=" "+c:o+=" "+s(c);return o},t.deprecate=function(r,n){if(void 0!==e&&!0===e.noDeprecation)return r;if(void 0===e)return function(){return t.deprecate(r,n).apply(this,arguments)};var i=!1;return function(){if(!i){if(e.throwDeprecation)throw new Error(n);e.traceDeprecation?console.trace(n):console.error(n),i=!0}return r.apply(this,arguments)}};var a,o={};function s(e,r){var n={seen:[],stylize:u};return arguments.length>=3&&(n.depth=arguments[2]),arguments.length>=4&&(n.colors=arguments[3]),p(r)?n.showHidden=r:r&&t._extend(n,r),b(n.showHidden)&&(n.showHidden=!1),b(n.depth)&&(n.depth=2),b(n.colors)&&(n.colors=!1),b(n.customInspect)&&(n.customInspect=!0),n.colors&&(n.stylize=c),l(n,e,n.depth)}function c(e,t){var r=s.styles[t];return r?"["+s.colors[r][0]+"m"+e+"["+s.colors[r][1]+"m":e}function u(e,t){return e}function l(e,r,n){if(e.customInspect&&r&&E(r.inspect)&&r.inspect!==t.inspect&&(!r.constructor||r.constructor.prototype!==r)){var i=r.inspect(n,e);return g(i)||(i=l(e,i,n)),i}var a=function(e,t){if(b(t))return e.stylize("undefined","undefined");if(g(t)){var r="'"+JSON.stringify(t).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return e.stylize(r,"string")}if(m(t))return e.stylize(""+t,"number");if(p(t))return e.stylize(""+t,"boolean");if(y(t))return e.stylize("null","null")}(e,r);if(a)return a;var o=Object.keys(r),s=function(e){var t={};return e.forEach(function(e,r){t[e]=!0}),t}(o);if(e.showHidden&&(o=Object.getOwnPropertyNames(r)),S(r)&&(o.indexOf("message")>=0||o.indexOf("description")>=0))return f(r);if(0===o.length){if(E(r)){var c=r.name?": "+r.name:"";return e.stylize("[Function"+c+"]","special")}if(v(r))return e.stylize(RegExp.prototype.toString.call(r),"regexp");if(w(r))return e.stylize(Date.prototype.toString.call(r),"date");if(S(r))return f(r)}var u,_="",x=!1,T=["{","}"];(h(r)&&(x=!0,T=["[","]"]),E(r))&&(_=" [Function"+(r.name?": "+r.name:"")+"]");return v(r)&&(_=" "+RegExp.prototype.toString.call(r)),w(r)&&(_=" "+Date.prototype.toUTCString.call(r)),S(r)&&(_=" "+f(r)),0!==o.length||x&&0!=r.length?n<0?v(r)?e.stylize(RegExp.prototype.toString.call(r),"regexp"):e.stylize("[Object]","special"):(e.seen.push(r),u=x?function(e,t,r,n,i){for(var a=[],o=0,s=t.length;o<s;++o)I(t,String(o))?a.push(d(e,t,r,n,String(o),!0)):a.push("");return i.forEach(function(i){i.match(/^\d+$/)||a.push(d(e,t,r,n,i,!0))}),a}(e,r,n,s,o):o.map(function(t){return d(e,r,n,s,t,x)}),e.seen.pop(),function(e,t,r){if(e.reduce(function(e,t){return 0,t.indexOf("\n")>=0&&0,e+t.replace(/\u001b\[\d\d?m/g,"").length+1},0)>60)return r[0]+(""===t?"":t+"\n ")+" "+e.join(",\n ")+" "+r[1];return r[0]+t+" "+e.join(", ")+" "+r[1]}(u,_,T)):T[0]+_+T[1]}function f(e){return"["+Error.prototype.toString.call(e)+"]"}function d(e,t,r,n,i,a){var o,s,c;if((c=Object.getOwnPropertyDescriptor(t,i)||{value:t[i]}).get?s=c.set?e.stylize("[Getter/Setter]","special"):e.stylize("[Getter]","special"):c.set&&(s=e.stylize("[Setter]","special")),I(n,i)||(o="["+i+"]"),s||(e.seen.indexOf(c.value)<0?(s=y(r)?l(e,c.value,null):l(e,c.value,r-1)).indexOf("\n")>-1&&(s=a?s.split("\n").map(function(e){return" "+e}).join("\n").substr(2):"\n"+s.split("\n").map(function(e){return" "+e}).join("\n")):s=e.stylize("[Circular]","special")),b(o)){if(a&&i.match(/^\d+$/))return s;(o=JSON.stringify(""+i)).match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)?(o=o.substr(1,o.length-2),o=e.stylize(o,"name")):(o=o.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),o=e.stylize(o,"string"))}return o+": "+s}function h(e){return Array.isArray(e)}function p(e){return"boolean"==typeof e}function y(e){return null===e}function m(e){return"number"==typeof e}function g(e){return"string"==typeof e}function b(e){return void 0===e}function v(e){return _(e)&&"[object RegExp]"===x(e)}function _(e){return"object"==typeof e&&null!==e}function w(e){return _(e)&&"[object Date]"===x(e)}function S(e){return _(e)&&("[object Error]"===x(e)||e instanceof Error)}function E(e){return"function"==typeof e}function x(e){return Object.prototype.toString.call(e)}function T(e){return e<10?"0"+e.toString(10):e.toString(10)}t.debuglog=function(r){if(b(a)&&(a=e.env.NODE_DEBUG||""),r=r.toUpperCase(),!o[r])if(new RegExp("\\b"+r+"\\b","i").test(a)){var n=e.pid;o[r]=function(){var e=t.format.apply(t,arguments);console.error("%s %d: %s",r,n,e)}}else o[r]=function(){};return o[r]},t.inspect=s,s.colors={bold:[1,22],italic:[3,23],underline:[4,24],inverse:[7,27],white:[37,39],grey:[90,39],black:[30,39],blue:[34,39],cyan:[36,39],green:[32,39],magenta:[35,39],red:[31,39],yellow:[33,39]},s.styles={special:"cyan",number:"yellow",boolean:"yellow",undefined:"grey",null:"bold",string:"green",date:"magenta",regexp:"red"},t.isArray=h,t.isBoolean=p,t.isNull=y,t.isNullOrUndefined=function(e){return null==e},t.isNumber=m,t.isString=g,t.isSymbol=function(e){return"symbol"==typeof e},t.isUndefined=b,t.isRegExp=v,t.isObject=_,t.isDate=w,t.isError=S,t.isFunction=E,t.isPrimitive=function(e){return null===e||"boolean"==typeof e||"number"==typeof e||"string"==typeof e||"symbol"==typeof e||void 0===e},t.isBuffer=r(322);var O=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];function A(){var e=new Date,t=[T(e.getHours()),T(e.getMinutes()),T(e.getSeconds())].join(":");return[e.getDate(),O[e.getMonth()],t].join(" ")}function I(e,t){return Object.prototype.hasOwnProperty.call(e,t)}t.log=function(){console.log("%s - %s",A(),t.format.apply(t,arguments))},t.inherits=r(323),t._extend=function(e,t){if(!t||!_(t))return e;for(var r=Object.keys(t),n=r.length;n--;)e[r[n]]=t[r[n]];return e};var N="undefined"!=typeof Symbol?Symbol("util.promisify.custom"):void 0;function R(e,t){if(!e){var r=new Error("Promise was rejected with a falsy value");r.reason=e,e=r}return t(e)}t.promisify=function(e){if("function"!=typeof e)throw new TypeError('The "original" argument must be of type Function');if(N&&e[N]){var t;if("function"!=typeof(t=e[N]))throw new TypeError('The "util.promisify.custom" argument must be of type Function');return Object.defineProperty(t,N,{value:t,enumerable:!1,writable:!1,configurable:!0}),t}function t(){for(var t,r,n=new Promise(function(e,n){t=e,r=n}),i=[],a=0;a<arguments.length;a++)i.push(arguments[a]);i.push(function(e,n){e?r(e):t(n)});try{e.apply(this,i)}catch(e){r(e)}return n}return Object.setPrototypeOf(t,Object.getPrototypeOf(e)),N&&Object.defineProperty(t,N,{value:t,enumerable:!1,writable:!1,configurable:!0}),Object.defineProperties(t,n(e))},t.promisify.custom=N,t.callbackify=function(t){if("function"!=typeof t)throw new TypeError('The "original" argument must be of type Function');function r(){for(var r=[],n=0;n<arguments.length;n++)r.push(arguments[n]);var i=r.pop();if("function"!=typeof i)throw new TypeError("The last argument must be of type Function");var a=this,o=function(){return i.apply(a,arguments)};t.apply(this,r).then(function(t){e.nextTick(o,null,t)},function(t){e.nextTick(R,t,o)})}return Object.setPrototypeOf(r,Object.getPrototypeOf(t)),Object.defineProperties(r,n(t)),r}}).call(this,r(13))},function(e,t,r){"use strict";(function(t){void 0===t||!t.version||0===t.version.indexOf("v0.")||0===t.version.indexOf("v1.")&&0!==t.version.indexOf("v1.8.")?e.exports={nextTick:function(e,r,n,i){if("function"!=typeof e)throw new TypeError('"callback" argument must be a function');var a,o,s=arguments.length;switch(s){case 0:case 1:return t.nextTick(e);case 2:return t.nextTick(function(){e.call(null,r)});case 3:return t.nextTick(function(){e.call(null,r,n)});case 4:return t.nextTick(function(){e.call(null,r,n,i)});default:for(a=new Array(s-1),o=0;o<a.length;)a[o++]=arguments[o];return t.nextTick(function(){e.apply(null,a)})}}}:e.exports=t}).call(this,r(13))},function(e,t,r){e.exports={DataFactory:r(53),Lexer:r(153),Parser:r(154),Writer:r(155),Store:r(359),StreamParser:r(360),StreamWriter:r(361),Util:r(362)}},function(e,t){var r="http://www.w3.org/1999/02/22-rdf-syntax-ns#",n="http://www.w3.org/2001/XMLSchema#",i="http://www.w3.org/2000/10/swap/";e.exports={xsd:{decimal:n+"decimal",boolean:n+"boolean",double:n+"double",integer:n+"integer",string:n+"string"},rdf:{type:r+"type",nil:r+"nil",first:r+"first",rest:r+"rest",langString:r+"langString"},owl:{sameAs:"http://www.w3.org/2002/07/owl#sameAs"},r:{forSome:i+"reify#forSome",forAll:i+"reify#forAll"},log:{implies:i+"log#implies"}}},function(e,t,r){var n=r(178),i=r(180);function a(t,r){return delete e.exports[t],e.exports[t]=r,r}e.exports={Parser:n,Tokenizer:r(179),ElementType:r(56),DomHandler:i,get FeedHandler(){return a("FeedHandler",r(414))},get Stream(){return a("Stream",r(421))},get WritableStream(){return a("WritableStream",r(183))},get ProxyHandler(){return a("ProxyHandler",r(423))},get DomUtils(){return a("DomUtils",r(182))},get CollectingHandler(){return a("CollectingHandler",r(424))},DefaultHandler:i,get RssHandler(){return a("RssHandler",this.FeedHandler)},parseDOM:function(e,t){var r=new i(t);return new n(r,t).end(e),r.dom},parseFeed:function(t,r){var i=new e.exports.FeedHandler(r);return new n(i,r).end(t),i.dom},createDomStream:function(e,t,r){var a=new i(e,t,r);return new n(a,t)},EVENTS:{attribute:2,cdatastart:0,cdataend:0,text:1,processinginstruction:2,comment:1,commentend:0,closetag:1,opentag:2,opentagname:1,error:1,end:0}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});t.NodeHandlerAdapter=class{constructor(e,t,r){this.targetKind=e,this.util=t,this.settings=r}getNodeQuadContextSelectionSet(e,t,r){const n={};if(e)for(const t of e.selections)if("Field"===t.kind){const e=t;this.handleNodeQuadContextField(e,r,n,"id","subject"),this.handleNodeQuadContextField(e,r,n,"graph","graph")}return n}handleNodeQuadContextField(e,t,r,n,i){if(!r[i]&&e.name.value===n){if(!r[i]){const a=this.util.getArgument(e.arguments,"_");if(a){const o=this.util.handleNodeValue(a.value,e.name.value,t);if(1!==o.terms.length)throw new Error(`Only single values can be set as ${n}, but got ${o.terms.length} at ${e.name.value}`);r[i]=o.terms[0],o.auxiliaryPatterns&&(r.auxiliaryPatterns||(r.auxiliaryPatterns=[]),r.auxiliaryPatterns.concat(o.auxiliaryPatterns))}}if(!r[i]){const n=this.util.nameToVariable(this.util.getFieldLabel(e),t);t.terminalVariables.push(n),r[i]=n}}}getDirectiveOutputs(e,t,r){const n=[];if(e)for(const i of e){const e=this.util.handleDirectiveNode({directive:i,fieldLabel:t},r);if(e){if(e.ignore)return null;n.push(e)}}return n}handleDirectiveOutputs(e,t){for(const r of e){if(r.ignore)return this.util.operationFactory.createBgp([]);r.operationOverrider&&(t=r.operationOverrider(t))}return t}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.types=Object.freeze({ALT:"alt",ASK:"ask",BGP:"bgp",CONSTRUCT:"construct",DESC:"desc",DESCRIBE:"describe",DISTINCT:"distinct",EXPRESSION:"expression",EXTEND:"extend",FILTER:"filter",FROM:"from",GRAPH:"graph",GROUP:"group",INV:"inv",JOIN:"join",LEFT_JOIN:"leftjoin",LINK:"link",MINUS:"minus",NPS:"nps",ONE_OR_MORE_PATH:"OneOrMorePath",ORDER_BY:"orderby",PATH:"path",PATTERN:"pattern",PROJECT:"project",REDUCED:"reduced",SEQ:"seq",SERVICE:"service",SLICE:"slice",UNION:"union",VALUES:"values",ZERO_OR_MORE_PATH:"ZeroOrMorePath",ZERO_OR_ONE_PATH:"ZeroOrOnePath"}),t.expressionTypes=Object.freeze({AGGREGATE:"aggregate",EXISTENCE:"existence",NAMED:"named",OPERATOR:"operator",TERM:"term"})},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(5),i=r(8);t.default=class{constructor(e){this.dataFactory=e||n,this.stringType=this.createTerm("http://www.w3.org/2001/XMLSchema#string")}createAlt(e,t){return{type:"alt",left:e,right:t}}createAsk(e){return{type:"ask",input:e}}createBoundAggregate(e,t,r,n,i){let a=this.createAggregateExpression(t,r,n,i);return a.variable=e,a}createBgp(e){return{type:"bgp",patterns:e}}createConstruct(e,t){return{type:"construct",input:e,template:t}}createDescribe(e,t){return{type:"describe",input:e,terms:t}}createDistinct(e){return{type:"distinct",input:e}}createExtend(e,t,r){return{type:"extend",input:e,variable:t,expression:r}}createFrom(e,t,r){return{type:"from",input:e,default:t,named:r}}createFilter(e,t){return{type:"filter",input:e,expression:t}}createGraph(e,t){return{type:"graph",input:e,name:t}}createGroup(e,t,r){return{type:"group",input:e,variables:t,aggregates:r}}createInv(e){return{type:"inv",path:e}}createJoin(e,t){return{type:"join",left:e,right:t}}createLeftJoin(e,t,r){return r?{type:"leftjoin",left:e,right:t,expression:r}:{type:"leftjoin",left:e,right:t}}createLink(e){return{type:"link",iri:e}}createMinus(e,t){return{type:"minus",left:e,right:t}}createNps(e){return{type:"nps",iris:e}}createOneOrMorePath(e){return{type:"OneOrMorePath",path:e}}createOrderBy(e,t){return{type:"orderby",input:e,expressions:t}}createPath(e,t,r,n){return n?{type:"path",subject:e,predicate:t,object:r,graph:n}:{type:"path",subject:e,predicate:t,object:r,graph:this.dataFactory.defaultGraph()}}createPattern(e,t,r,n){let i;return(i=n?this.dataFactory.quad(e,t,r,n):this.dataFactory.triple(e,t,r)).type="pattern",i}createProject(e,t){return{type:"project",input:e,variables:t}}createReduced(e){return{type:"reduced",input:e}}createSeq(e,t){return{type:"seq",left:e,right:t}}createService(e,t,r){return{type:"service",input:e,name:t,silent:r}}createSlice(e,t,r){return void 0===t&&(t=0),void 0!==r?{type:"slice",input:e,start:t,length:r}:{type:"slice",input:e,start:t}}createUnion(e,t){return{type:"union",left:e,right:t}}createValues(e,t){return{type:"values",variables:e,bindings:t}}createZeroOrMorePath(e){return{type:"ZeroOrMorePath",path:e}}createZeroOrOnePath(e){return{type:"ZeroOrOnePath",path:e}}createAggregateExpression(e,t,r,n){return n?{type:"expression",expressionType:"aggregate",aggregator:e,expression:t,separator:n,distinct:r}:{type:"expression",expressionType:"aggregate",aggregator:e,expression:t,distinct:r}}createExistenceExpression(e,t){return{type:"expression",expressionType:"existence",not:e,input:t}}createNamedExpression(e,t){return{type:"expression",expressionType:"named",name:e,args:t}}createOperatorExpression(e,t){return{type:"expression",expressionType:"operator",operator:e,args:t}}createTermExpression(e){return{type:"expression",expressionType:"term",term:e}}createTerm(e){return i.stringToTerm(e,this.dataFactory)}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(57),i=r(71);t.NodeHandlerSelectionAdapter=class extends i.NodeHandlerAdapter{constructor(e,t,r){super(e,t,r)}getNodeQuadContextFieldNode(e,t,r){return this.getNodeQuadContextSelectionSet(e.selectionSet,t,Object.assign({},r,{path:this.util.appendFieldToPath(r.path,t)}))}fieldToOperation(e,t,r,i){const a=r;let o,s=0;if(("id"===t.name.value||"graph"===t.name.value)&&(r=!1,t.arguments))for(const r of t.arguments)"_"===r.name.value&&this.util.handleNodeValue(r.value,t.name.value,e);const c=this.util.getFieldLabel(t);if(e.singularizeState===n.SingularizeState.SINGLE&&(e.singularizeVariables[this.util.nameToVariable(c,e).value]=!0),r){const t=this.handleMetaField(e,c,i);if(t)return t}const u=i?[this.util.operationFactory.createBgp(i)]:[],l=this.getNodeQuadContextFieldNode(t,c,e);let f=l.subject||this.util.nameToVariable(c,e),d=l.graph||e.graph;l.auxiliaryPatterns&&u.push(this.util.operationFactory.createBgp(l.auxiliaryPatterns));let h=!0,p=null;if(r&&t.arguments&&t.arguments.length)for(const n of t.arguments){if("_"===n.name.value){const i=this.util.handleNodeValue(n.value,t.name.value,e);p=i.terms,u.push(this.util.operationFactory.createBgp(i.terms.map(r=>this.util.createQuadPattern(e.subject,t.name,r,e.graph,e.context)))),i.auxiliaryPatterns&&u.push(this.util.operationFactory.createBgp(l.auxiliaryPatterns)),r=!1;break}if("graph"===n.name.value){const r=this.util.handleNodeValue(n.value,t.name.value,e);if(1!==r.terms.length)throw new Error(`Only single values can be set as graph, but got ${r.terms.length} at ${t.name.value}`);d=r.terms[0],e=Object.assign({},e,{graph:d}),r.auxiliaryPatterns&&u.push(this.util.operationFactory.createBgp(l.auxiliaryPatterns));break}if("alt"===n.name.value){let r=n.value;"ListValue"!==r.kind&&(r={kind:"ListValue",values:[r]}),u.push(this.util.createQuadPath(e.subject,t.name,r,f,e.graph,e.context)),h=!1;break}}if(r&&h&&u.push(this.util.operationFactory.createBgp([this.util.createQuadPattern(e.subject,t.name,f,e.graph,e.context)])),t.arguments&&t.arguments.length)for(const r of t.arguments)if("_"===r.name.value||"graph"===r.name.value||"alt"===r.name.value);else if("first"===r.name.value){if("IntValue"!==r.value.kind)throw new Error("Invalid value type for 'first' argument: "+r.value.kind);o=parseInt(r.value.value,10)}else if("offset"===r.name.value){if("IntValue"!==r.value.kind)throw new Error("Invalid value type for 'offset' argument: "+r.value.kind);s=parseInt(r.value.value,10)}else{const t=this.util.handleNodeValue(r.value,r.name.value,e);u.push(this.util.operationFactory.createBgp(t.terms.map(t=>this.util.createQuadPattern(f,r.name,t,e.graph,e.context)))),t.auxiliaryPatterns&&u.push(this.util.operationFactory.createBgp(l.auxiliaryPatterns))}const y=this.getDirectiveOutputs(t.directives,c,e);if(!y)return this.util.operationFactory.createBgp([]);let m=this.util.joinOperations(u);if(t.selectionSet&&t.selectionSet.selections.length){if(p){if(1!==p.length)throw new Error(`Only single values can be set as id, but got ${p.length} at ${t.name.value}`);f=p[0]}const r=Object.assign({},e,a?{path:this.util.appendFieldToPath(e.path,c)}:{},{graph:d,subject:a?f:e.subject});let n=!1;const i=t.selectionSet.selections.filter(e=>"Field"!==e.kind||"totalCount"!==e.name.value||(n=!0,!1));let o=this.util.joinOperations(u.concat(i.map(e=>this.util.handleNode(e,r))));if(n){const t=this.util.dataFactory.variable("var"+this.settings.expressionVariableCounter++),r=this.util.dataFactory.variable(f.value+this.settings.variableDelimiter+"totalCount"),n=this.util.operationFactory.createBoundAggregate(t,"count",this.util.operationFactory.createTermExpression(f),!1),a=this.util.operationFactory.createProject(this.util.operationFactory.createExtend(this.util.operationFactory.createGroup(m,[],[n]),r,this.util.operationFactory.createTermExpression(t)),[r]);e.terminalVariables.push(r),o=i.length?this.util.operationFactory.createJoin(this.util.operationFactory.createProject(o,[]),a):a}m=o}else r&&"Variable"===f.termType&&e.terminalVariables.push(f);return(s||o)&&(m=this.util.operationFactory.createSlice(this.util.operationFactory.createProject(m,[]),s,o)),this.handleDirectiveOutputs(y,m)}handleMetaField(e,t,r){if("__typename"===t){const n=this.util.nameToVariable(t,e);return e.terminalVariables.push(n),this.util.operationFactory.createBgp([this.util.operationFactory.createPattern(e.subject,this.util.dataFactory.namedNode("http://www.w3.org/1999/02/22-rdf-syntax-ns#type"),this.util.nameToVariable(t,e),e.graph)].concat(r||[]))}return null}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(490))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(524))},function(e,t,r){"use strict";function n(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}Object.defineProperty(t,"__esModule",{value:!0}),n(r(594)),n(r(248))},function(e,t,r){var n=r(2).Buffer;function i(e){n.isBuffer(e)||(e=n.from(e));for(var t=e.length/4|0,r=new Array(t),i=0;i<t;i++)r[i]=e.readUInt32BE(4*i);return r}function a(e){for(;0<e.length;e++)e[0]=0}function o(e,t,r,n,i){for(var a,o,s,c,u=r[0],l=r[1],f=r[2],d=r[3],h=e[0]^t[0],p=e[1]^t[1],y=e[2]^t[2],m=e[3]^t[3],g=4,b=1;b<i;b++)a=u[h>>>24]^l[p>>>16&255]^f[y>>>8&255]^d[255&m]^t[g++],o=u[p>>>24]^l[y>>>16&255]^f[m>>>8&255]^d[255&h]^t[g++],s=u[y>>>24]^l[m>>>16&255]^f[h>>>8&255]^d[255&p]^t[g++],c=u[m>>>24]^l[h>>>16&255]^f[p>>>8&255]^d[255&y]^t[g++],h=a,p=o,y=s,m=c;return a=(n[h>>>24]<<24|n[p>>>16&255]<<16|n[y>>>8&255]<<8|n[255&m])^t[g++],o=(n[p>>>24]<<24|n[y>>>16&255]<<16|n[m>>>8&255]<<8|n[255&h])^t[g++],s=(n[y>>>24]<<24|n[m>>>16&255]<<16|n[h>>>8&255]<<8|n[255&p])^t[g++],c=(n[m>>>24]<<24|n[h>>>16&255]<<16|n[p>>>8&255]<<8|n[255&y])^t[g++],[a>>>=0,o>>>=0,s>>>=0,c>>>=0]}var s=[0,1,2,4,8,16,32,64,128,27,54],c=function(){for(var e=new Array(256),t=0;t<256;t++)e[t]=t<128?t<<1:t<<1^283;for(var r=[],n=[],i=[[],[],[],[]],a=[[],[],[],[]],o=0,s=0,c=0;c<256;++c){var u=s^s<<1^s<<2^s<<3^s<<4;u=u>>>8^255&u^99,r[o]=u,n[u]=o;var l=e[o],f=e[l],d=e[f],h=257*e[u]^16843008*u;i[0][o]=h<<24|h>>>8,i[1][o]=h<<16|h>>>16,i[2][o]=h<<8|h>>>24,i[3][o]=h,h=16843009*d^65537*f^257*l^16843008*o,a[0][u]=h<<24|h>>>8,a[1][u]=h<<16|h>>>16,a[2][u]=h<<8|h>>>24,a[3][u]=h,0===o?o=s=1:(o=l^e[e[e[d^l]]],s^=e[e[s]])}return{SBOX:r,INV_SBOX:n,SUB_MIX:i,INV_SUB_MIX:a}}();function u(e){this._key=i(e),this._reset()}u.blockSize=16,u.keySize=32,u.prototype.blockSize=u.blockSize,u.prototype.keySize=u.keySize,u.prototype._reset=function(){for(var e=this._key,t=e.length,r=t+6,n=4*(r+1),i=[],a=0;a<t;a++)i[a]=e[a];for(a=t;a<n;a++){var o=i[a-1];a%t==0?(o=o<<8|o>>>24,o=c.SBOX[o>>>24]<<24|c.SBOX[o>>>16&255]<<16|c.SBOX[o>>>8&255]<<8|c.SBOX[255&o],o^=s[a/t|0]<<24):t>6&&a%t==4&&(o=c.SBOX[o>>>24]<<24|c.SBOX[o>>>16&255]<<16|c.SBOX[o>>>8&255]<<8|c.SBOX[255&o]),i[a]=i[a-t]^o}for(var u=[],l=0;l<n;l++){var f=n-l,d=i[f-(l%4?0:4)];u[l]=l<4||f<=4?d:c.INV_SUB_MIX[0][c.SBOX[d>>>24]]^c.INV_SUB_MIX[1][c.SBOX[d>>>16&255]]^c.INV_SUB_MIX[2][c.SBOX[d>>>8&255]]^c.INV_SUB_MIX[3][c.SBOX[255&d]]}this._nRounds=r,this._keySchedule=i,this._invKeySchedule=u},u.prototype.encryptBlockRaw=function(e){return o(e=i(e),this._keySchedule,c.SUB_MIX,c.SBOX,this._nRounds)},u.prototype.encryptBlock=function(e){var t=this.encryptBlockRaw(e),r=n.allocUnsafe(16);return r.writeUInt32BE(t[0],0),r.writeUInt32BE(t[1],4),r.writeUInt32BE(t[2],8),r.writeUInt32BE(t[3],12),r},u.prototype.decryptBlock=function(e){var t=(e=i(e))[1];e[1]=e[3],e[3]=t;var r=o(e,this._invKeySchedule,c.INV_SUB_MIX,c.INV_SBOX,this._nRounds),a=n.allocUnsafe(16);return a.writeUInt32BE(r[0],0),a.writeUInt32BE(r[3],4),a.writeUInt32BE(r[2],8),a.writeUInt32BE(r[1],12),a},u.prototype.scrub=function(){a(this._keySchedule),a(this._invKeySchedule),a(this._key)},e.exports.AES=u},function(e,t,r){var n=r(2).Buffer,i=r(101);e.exports=function(e,t,r,a){if(n.isBuffer(e)||(e=n.from(e,"binary")),t&&(n.isBuffer(t)||(t=n.from(t,"binary")),8!==t.length))throw new RangeError("salt should be Buffer with 8 byte length");for(var o=r/8,s=n.alloc(o),c=n.alloc(a||0),u=n.alloc(0);o>0||a>0;){var l=new i;l.update(u),l.update(e),t&&l.update(t),u=l.digest();var f=0;if(o>0){var d=s.length-o;f=Math.min(o,u.length),u.copy(s,d,0,f),o-=f}if(f<u.length&&a>0){var h=c.length-a,p=Math.min(a,u.length-f);u.copy(c,h,f,f+p),a-=p}}return u.fill(0),{key:s,iv:c}}},function(e,t,r){"use strict";var n=r(11),i=r(17),a=i.getNAF,o=i.getJSF,s=i.assert;function c(e,t){this.type=e,this.p=new n(t.p,16),this.red=t.prime?n.red(t.prime):n.mont(this.p),this.zero=new n(0).toRed(this.red),this.one=new n(1).toRed(this.red),this.two=new n(2).toRed(this.red),this.n=t.n&&new n(t.n,16),this.g=t.g&&this.pointFromJSON(t.g,t.gRed),this._wnafT1=new Array(4),this._wnafT2=new Array(4),this._wnafT3=new Array(4),this._wnafT4=new Array(4);var r=this.n&&this.p.div(this.n);!r||r.cmpn(100)>0?this.redN=null:(this._maxwellTrick=!0,this.redN=this.n.toRed(this.red))}function u(e,t){this.curve=e,this.type=t,this.precomputed=null}e.exports=c,c.prototype.point=function(){throw new Error("Not implemented")},c.prototype.validate=function(){throw new Error("Not implemented")},c.prototype._fixedNafMul=function(e,t){s(e.precomputed);var r=e._getDoubles(),n=a(t,1),i=(1<<r.step+1)-(r.step%2==0?2:1);i/=3;for(var o=[],c=0;c<n.length;c+=r.step){var u=0;for(t=c+r.step-1;t>=c;t--)u=(u<<1)+n[t];o.push(u)}for(var l=this.jpoint(null,null,null),f=this.jpoint(null,null,null),d=i;d>0;d--){for(c=0;c<o.length;c++){(u=o[c])===d?f=f.mixedAdd(r.points[c]):u===-d&&(f=f.mixedAdd(r.points[c].neg()))}l=l.add(f)}return l.toP()},c.prototype._wnafMul=function(e,t){var r=4,n=e._getNAFPoints(r);r=n.wnd;for(var i=n.points,o=a(t,r),c=this.jpoint(null,null,null),u=o.length-1;u>=0;u--){for(t=0;u>=0&&0===o[u];u--)t++;if(u>=0&&t++,c=c.dblp(t),u<0)break;var l=o[u];s(0!==l),c="affine"===e.type?l>0?c.mixedAdd(i[l-1>>1]):c.mixedAdd(i[-l-1>>1].neg()):l>0?c.add(i[l-1>>1]):c.add(i[-l-1>>1].neg())}return"affine"===e.type?c.toP():c},c.prototype._wnafMulAdd=function(e,t,r,n,i){for(var s=this._wnafT1,c=this._wnafT2,u=this._wnafT3,l=0,f=0;f<n;f++){var d=(T=t[f])._getNAFPoints(e);s[f]=d.wnd,c[f]=d.points}for(f=n-1;f>=1;f-=2){var h=f-1,p=f;if(1===s[h]&&1===s[p]){var y=[t[h],null,null,t[p]];0===t[h].y.cmp(t[p].y)?(y[1]=t[h].add(t[p]),y[2]=t[h].toJ().mixedAdd(t[p].neg())):0===t[h].y.cmp(t[p].y.redNeg())?(y[1]=t[h].toJ().mixedAdd(t[p]),y[2]=t[h].add(t[p].neg())):(y[1]=t[h].toJ().mixedAdd(t[p]),y[2]=t[h].toJ().mixedAdd(t[p].neg()));var m=[-3,-1,-5,-7,0,7,5,1,3],g=o(r[h],r[p]);l=Math.max(g[0].length,l),u[h]=new Array(l),u[p]=new Array(l);for(var b=0;b<l;b++){var v=0|g[0][b],_=0|g[1][b];u[h][b]=m[3*(v+1)+(_+1)],u[p][b]=0,c[h]=y}}else u[h]=a(r[h],s[h]),u[p]=a(r[p],s[p]),l=Math.max(u[h].length,l),l=Math.max(u[p].length,l)}var w=this.jpoint(null,null,null),S=this._wnafT4;for(f=l;f>=0;f--){for(var E=0;f>=0;){var x=!0;for(b=0;b<n;b++)S[b]=0|u[b][f],0!==S[b]&&(x=!1);if(!x)break;E++,f--}if(f>=0&&E++,w=w.dblp(E),f<0)break;for(b=0;b<n;b++){var T,O=S[b];0!==O&&(O>0?T=c[b][O-1>>1]:O<0&&(T=c[b][-O-1>>1].neg()),w="affine"===T.type?w.mixedAdd(T):w.add(T))}}for(f=0;f<n;f++)c[f]=null;return i?w:w.toP()},c.BasePoint=u,u.prototype.eq=function(){throw new Error("Not implemented")},u.prototype.validate=function(){return this.curve.validate(this)},c.prototype.decodePoint=function(e,t){e=i.toArray(e,t);var r=this.p.byteLength();if((4===e[0]||6===e[0]||7===e[0])&&e.length-1==2*r)return 6===e[0]?s(e[e.length-1]%2==0):7===e[0]&&s(e[e.length-1]%2==1),this.point(e.slice(1,1+r),e.slice(1+r,1+2*r));if((2===e[0]||3===e[0])&&e.length-1===r)return this.pointFromX(e.slice(1,1+r),3===e[0]);throw new Error("Unknown point format")},u.prototype.encodeCompressed=function(e){return this.encode(e,!0)},u.prototype._encode=function(e){var t=this.curve.p.byteLength(),r=this.getX().toArray("be",t);return e?[this.getY().isEven()?2:3].concat(r):[4].concat(r,this.getY().toArray("be",t))},u.prototype.encode=function(e,t){return i.encode(this._encode(t),e)},u.prototype.precompute=function(e){if(this.precomputed)return this;var t={doubles:null,naf:null,beta:null};return t.naf=this._getNAFPoints(8),t.doubles=this._getDoubles(4,e),t.beta=this._getBeta(),this.precomputed=t,this},u.prototype._hasDoubles=function(e){if(!this.precomputed)return!1;var t=this.precomputed.doubles;return!!t&&t.points.length>=Math.ceil((e.bitLength()+1)/t.step)},u.prototype._getDoubles=function(e,t){if(this.precomputed&&this.precomputed.doubles)return this.precomputed.doubles;for(var r=[this],n=this,i=0;i<t;i+=e){for(var a=0;a<e;a++)n=n.dbl();r.push(n)}return{step:e,points:r}},u.prototype._getNAFPoints=function(e){if(this.precomputed&&this.precomputed.naf)return this.precomputed.naf;for(var t=[this],r=(1<<e)-1,n=1===r?null:this.dbl(),i=1;i<r;i++)t[i]=t[i-1].add(n);return{wnd:e,points:t}},u.prototype._getBeta=function(){return null},u.prototype.dblp=function(e){for(var t=this,r=0;r<e;r++)t=t.dbl();return t}},function(e,t,r){var n=r(645),i=r(656),a=r(657),o=r(105),s=r(255),c=r(2).Buffer;function u(e){var t;"object"!=typeof e||c.isBuffer(e)||(t=e.passphrase,e=e.key),"string"==typeof e&&(e=c.from(e));var r,u,l=a(e,t),f=l.tag,d=l.data;switch(f){case"CERTIFICATE":u=n.certificate.decode(d,"der").tbsCertificate.subjectPublicKeyInfo;case"PUBLIC KEY":switch(u||(u=n.PublicKey.decode(d,"der")),r=u.algorithm.algorithm.join(".")){case"1.2.840.113549.1.1.1":return n.RSAPublicKey.decode(u.subjectPublicKey.data,"der");case"1.2.840.10045.2.1":return u.subjectPrivateKey=u.subjectPublicKey,{type:"ec",data:u};case"1.2.840.10040.4.1":return u.algorithm.params.pub_key=n.DSAparam.decode(u.subjectPublicKey.data,"der"),{type:"dsa",data:u.algorithm.params};default:throw new Error("unknown key id "+r)}throw new Error("unknown key type "+f);case"ENCRYPTED PRIVATE KEY":d=function(e,t){var r=e.algorithm.decrypt.kde.kdeparams.salt,n=parseInt(e.algorithm.decrypt.kde.kdeparams.iters.toString(),10),a=i[e.algorithm.decrypt.cipher.algo.join(".")],u=e.algorithm.decrypt.cipher.iv,l=e.subjectPrivateKey,f=parseInt(a.split("-")[1],10)/8,d=s.pbkdf2Sync(t,r,n,f,"sha1"),h=o.createDecipheriv(a,d,u),p=[];return p.push(h.update(l)),p.push(h.final()),c.concat(p)}(d=n.EncryptedPrivateKey.decode(d,"der"),t);case"PRIVATE KEY":switch(r=(u=n.PrivateKey.decode(d,"der")).algorithm.algorithm.join(".")){case"1.2.840.113549.1.1.1":return n.RSAPrivateKey.decode(u.subjectPrivateKey,"der");case"1.2.840.10045.2.1":return{curve:u.algorithm.curve,privateKey:n.ECPrivateKey.decode(u.subjectPrivateKey,"der").privateKey};case"1.2.840.10040.4.1":return u.algorithm.params.priv_key=n.DSAparam.decode(u.subjectPrivateKey,"der"),{type:"dsa",params:u.algorithm.params};default:throw new Error("unknown key id "+r)}throw new Error("unknown key type "+f);case"RSA PUBLIC KEY":return n.RSAPublicKey.decode(d,"der");case"RSA PRIVATE KEY":return n.RSAPrivateKey.decode(d,"der");case"DSA PRIVATE KEY":return{type:"dsa",params:n.DSAPrivateKey.decode(d,"der")};case"EC PRIVATE KEY":return{curve:(d=n.ECPrivateKey.decode(d,"der")).parameters.value,privateKey:d.privateKey};default:throw new Error("unknown key type "+f)}}e.exports=u,u.signature=n.signature},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(8),i=r(10),a=r(47),o=r(18),s=r(22),c=r(83),u=r(112),l=r(18);function f(e){if(!e)throw new s.InvalidExpression(e);const t=i.Algebra.expressionTypes;switch(e.expressionType){case t.TERM:return d(e);case t.OPERATOR:return function(e){if(o.SpecialOperators.contains(e.operator)){const t=e.operator,r=e.args.map(e=>f(e)),n=u.specialFunctions.get(t);if(!n.checkArity(r))throw new s.InvalidArity(r,t);return new a.SpecialOperator(r,n.applyAsync,n.applySync)}{if(!o.Operators.contains(e.operator))throw new s.UnknownOperator(e.operator);const t=e.operator,r=e.args.map(e=>f(e)),n=u.regularFunctions.get(t);if(!function(e,t){if(t===1/0)return!0;if(Array.isArray(t))return t.indexOf(e.length)>=0;return e.length===t}(r,n.arity))throw new s.InvalidArity(r,t);return new a.Operator(r,n.apply)}}(e);case t.NAMED:return p(e);case t.EXISTENCE:return m(e);case t.AGGREGATE:return y(e);default:throw new s.InvalidExpressionType(e)}}function d(e){if(!e.term)throw new s.InvalidExpression(e);switch(e.term.termType){case"Variable":return new a.Variable(n.termToString(e.term));case"Literal":return h(e.term);case"NamedNode":return new a.NamedNode(e.term.value);case"BlankNode":return new a.BlankNode(e.term.value);default:throw new s.InvalidTermType(e)}}function h(e){if(!e.datatype)return e.language?new a.LangStringLiteral(e.value,e.language):new a.StringLiteral(e.value);switch(e.datatype.value){case null:case void 0:case"":return e.language?new a.LangStringLiteral(e.value,e.language):new a.StringLiteral(e.value);case l.TypeURL.XSD_STRING:return new a.StringLiteral(e.value);case l.TypeURL.RDF_LANG_STRING:return new a.LangStringLiteral(e.value,e.language);case l.TypeURL.XSD_DATE_TIME:case l.TypeURL.XSD_DATE:{const t=new Date(e.value);return isNaN(t.getTime())?new a.NonLexicalLiteral(void 0,e.datatype,e.value):new a.DateTimeLiteral(new Date(e.value),e.value)}case l.TypeURL.XSD_BOOLEAN:return"true"!==e.value&&"false"!==e.value?new a.NonLexicalLiteral(void 0,e.datatype,e.value):new a.BooleanLiteral("true"===e.value,e.value);case l.TypeURL.XSD_INTEGER:case l.TypeURL.XSD_DECIMAL:case l.TypeURL.XSD_NEGATIVE_INTEGER:case l.TypeURL.XSD_NON_NEGATIVE_INTEGER:case l.TypeURL.XSD_NON_POSITIVE_INTEGER:case l.TypeURL.XSD_POSITIVE_INTEGER:case l.TypeURL.XSD_LONG:case l.TypeURL.XSD_INT:case l.TypeURL.XSD_SHORT:case l.TypeURL.XSD_BYTE:case l.TypeURL.XSD_UNSIGNED_LONG:case l.TypeURL.XSD_UNSIGNED_INT:case l.TypeURL.XSD_UNSIGNED_SHORT:case l.TypeURL.XSD_UNSIGNED_BYTE:case l.TypeURL.XSD_INT:{const t=c.parseXSDDecimal(e.value);return void 0===t?new a.NonLexicalLiteral(void 0,e.datatype,e.value):new a.NumericLiteral(t,e.datatype,e.value)}case l.TypeURL.XSD_FLOAT:case l.TypeURL.XSD_DOUBLE:{const t=c.parseXSDFloat(e.value);return void 0===t?new a.NonLexicalLiteral(void 0,e.datatype,e.value):new a.NumericLiteral(t,e.datatype,e.value)}default:return new a.Literal(e.value,e.datatype,e.value)}}function p(e){const t=e.name.value;if(!o.NamedOperators.contains(t))throw new s.UnknownNamedOperator(e.name.value);const r=e.name.value,n=e.args.map(e=>f(e)),i=u.namedFunctions.get(r);return new a.Named(e.name,n,i.apply)}function y(e){const t=e.aggregator;return new a.Aggregate(t,e)}function m(e){return new a.Existence(e)}t.transformAlgebra=f,t.transformRDFTermUnsafe=function(e){return d({term:e,type:"expression",expressionType:"term"})},t.transformLiteral=h,t.transformNamed=p,t.transformAggregate=y,t.transformExistence=m},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.parseXSDFloat=function(e){const t=Number(e);return isNaN(t)?"NaN"===e?NaN:"INF"===e?1/0:"-INF"===e?-1/0:void 0:t},t.parseXSDDecimal=function(e){if(/^(\-|\+)?([0-9]+(\.[0-9]+)?)$/.test(e)){const t=Number(e);return isNaN(t)?void 0:t}},t.parseXSDInteger=function(e){if(/^(\-|\+)?([0-9]+)$/.test(e)){const t=Number(e);return isNaN(t)?void 0:t}},t.parseXSDDateTime=function(e){const t=e.indexOf("T"),r=t>=0?e.substr(0,t):e,[n,i,a]=r.split("-");let o="",s="",c="",u="";if(t>=0){const r=e.substr(t+1),[n,i]=r.split(/[\+\-Z]/);[o,s,c]=n.split(":");const a=new RegExp(/([\+\-Z].*)/).exec(r);u=a?a[0]:""}else o="00",s="00",c="00",u="";return{year:n,month:i,day:a,hours:o,minutes:s,seconds:c,timezone:u}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(25),i=r(47),a=r(18),o=r(22),s=r(18),c=r(113);t.declare=function(){return new u};class u{constructor(){this.implementations=[]}collect(){return d(this.implementations)}log(){return console.log(this.implementations),this}add(e){return this.implementations.push(e),this}set(e,t){const r=n.List(e);return this.add(new f({types:r,func:t}))}copy({from:e,to:t}){const r=this.implementations.length-1,i=n.List(e);for(let e=r;e>=0;e--){const r=this.implementations[e];if(r.get("types").equals(i))return this.set(t,r.get("func"))}throw new o.UnexpectedError("Tried to copy implementation, but types not found",{from:e,to:t})}onUnary(e,t){return this.set([e],([e])=>t(e))}onUnaryTyped(e,t){return this.set([e],([e])=>t(e.typedValue))}onBinary(e,t){return this.set(e,([e,r])=>t(e,r))}onBinaryTyped(e,t){return this.set(e,([e,r])=>t(e.typedValue,r.typedValue))}onTernaryTyped(e,t){return this.set(e,([e,r,n])=>t(e.typedValue,r.typedValue,n.typedValue))}onTernary(e,t){return this.set(e,([e,r,n])=>t(e,r,n))}onQuaternaryTyped(e,t){return this.set(e,([e,r,n,i])=>t(e.typedValue,r.typedValue,n.typedValue,i.typedValue))}unimplemented(e){for(let t=0;t<=5;t++){const r=Array(t).fill("term"),n=t=>{throw new o.UnimplementedError(e)};this.set(r,n)}return this}onTerm1(e){return this.set(["term"],([t])=>e(t))}onLiteral1(e){return this.set(["literal"],([t])=>e(t))}onBoolean1(e){return this.set(["boolean"],([t])=>e(t))}onBoolean1Typed(e){return this.set(["boolean"],([t])=>e(t.typedValue))}onString1(e){return this.set(["string"],([t])=>e(t))}onString1Typed(e){return this.set(["string"],([t])=>e(t.typedValue))}onLangString1(e){return this.set(["langString"],([t])=>e(t))}onStringly1(e){return this.set(["string"],([t])=>e(t)).set(["langString"],([t])=>e(t))}onStringly1Typed(e){return this.set(["string"],([t])=>e(t.typedValue)).set(["langString"],([t])=>e(t.typedValue))}onNumeric1(e){return this.set(["integer"],([t])=>e(t)).set(["decimal"],([t])=>e(t)).set(["float"],([t])=>e(t)).set(["double"],([t])=>e(t)).invalidLexicalForm(["nonlexical"],1)}onDateTime1(e){return this.set(["date"],([t])=>e(t)).invalidLexicalForm(["nonlexical"],1)}arithmetic(e){return this.numeric(([t,r])=>{const n=c.promote(t.type,r.type),i=a.decategorize(n);return p(e(t.typedValue,r.typedValue),i)})}numberTest(e){return this.numeric(([t,r])=>{return h(e(t.typedValue,r.typedValue))})}stringTest(e){return this.set(["string","string"],([t,r])=>{return h(e(t.typedValue,r.typedValue))}).invalidLexicalForm(["nonlexical","string"],1).invalidLexicalForm(["string","nonlexical"],2)}booleanTest(e){return this.set(["boolean","boolean"],([t,r])=>{return h(e(t.typedValue,r.typedValue))}).invalidLexicalForm(["nonlexical","boolean"],1).invalidLexicalForm(["boolean","nonlexical"],2)}dateTimeTest(e){return this.set(["date","date"],([t,r])=>{return h(e(t.typedValue,r.typedValue))}).invalidLexicalForm(["nonlexical","date"],1).invalidLexicalForm(["date","nonlexical"],2)}numeric(e){return this.set(["integer","integer"],e).set(["integer","decimal"],e).set(["integer","float"],e).set(["integer","double"],e).invalidLexicalForm(["integer","nonlexical"],2).set(["decimal","integer"],e).set(["decimal","decimal"],e).set(["decimal","float"],e).set(["decimal","double"],e).invalidLexicalForm(["decimal","nonlexical"],2).set(["float","integer"],e).set(["float","decimal"],e).set(["float","float"],e).set(["float","double"],e).invalidLexicalForm(["float","nonlexical"],2).set(["double","integer"],e).set(["double","decimal"],e).set(["double","float"],e).set(["double","double"],e).invalidLexicalForm(["double","nonlexical"],2).invalidLexicalForm(["nonlexical","integer"],1).invalidLexicalForm(["nonlexical","decimal"],1).invalidLexicalForm(["nonlexical","float"],1).invalidLexicalForm(["nonlexical","double"],1)}invalidLexicalForm(e,t){return this.set(e,e=>{throw new o.InvalidLexicalForm(e[t-1].toRDF())})}chain(e){return this.implementations=this.implementations.concat(e),this}}t.Builder=u;const l={types:[],func(){throw new o.UnexpectedError("Implementation not set yet declared as implemented")}};class f extends(n.Record(l)){constructor(e){super(e)}get(e){return super.get(e)}toPair(){return[this.get("types"),this.get("func")]}}function d(e){const t=e.map(e=>e.toPair());return n.Map(t)}function h(e){return new i.BooleanLiteral(e)}function p(e,t){return new i.NumericLiteral(e,a.make(t||s.TypeURL.XSD_FLOAT),void 0)}t.Impl=f,t.map=d,t.bool=h,t.number=p,t.numberFromString=function(e,t){const r=Number(e);return new i.NumericLiteral(r,a.make(t||s.TypeURL.XSD_FLOAT),void 0)},t.string=function(e){return new i.StringLiteral(e)},t.langString=function(e,t){return new i.LangStringLiteral(e,t)},t.dateTime=function(e,t){return new i.DateTimeLiteral(e,t)},t.log=function(e,...t){return console.log(e,t),e},t.typeCheckLit=function(e,t,r,n){if("literal"!==e.termType)throw new o.InvalidArgumentTypes(r,n);const i=e;if(!t.includes(i.type))throw new o.InvalidArgumentTypes(r,n);return i}},function(e,t,r){"use strict";var n=r(19);Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var i=n(r(86)),a=r(5),o=r(64);t.default=class{constructor(e,t){this._mutationType=e,this._allowZeroArgs=t}handle(e,t){return(...r)=>{if(!this._allowZeroArgs&&!r.length)throw new Error(`Mutation on ${e} can not be invoked without arguments`);const n=(0,o.getThen)(()=>this.createMutationExpressions(e,t,r));return e.extendPath({mutationExpressions:{then:n}})}}async createMutationExpressions(e,t,r){const n=await t.pathExpression;if(!Array.isArray(n))throw new Error(`${e} has no pathExpression property`);if(n.length<2)throw new Error(`${e} should at least contain a subject and a predicate`);const i=await this.extractObjects(e,t,r),a=this._mutationType;if(!i)return[{mutationType:a,conditions:n}];if(0===i.length)return[];const{predicate:o}=n.pop();if(!o)throw new Error(`Expected predicate in ${e}`);return[{mutationType:a,conditions:n,predicate:o,objects:i}]}async extractObjects(e,t,r){if(0===r.length)return null;const n=[];for(const f of r)if(f&&f[Symbol.asyncIterator]){var a,o=!0,s=!1;try{for(var c,u,l=(0,i.default)(f);o=(c=await l.next()).done,u=await c.value,!o;o=!0){const r=u;n.push(this.extractObject(e,t,r))}}catch(e){s=!0,a=e}finally{try{o||null==l.return||await l.return()}finally{if(s)throw a}}}else n.push(this.extractObject(e,t,await f));return n}extractObject(e,t,r){if("string"==typeof r)return(0,a.literal)(r);if(r&&r.termType)return r;throw new Error(`Invalid object: ${r}`)}}},function(e,t){e.exports=function(e){var t;if("undefined"!=typeof Symbol){if(Symbol.asyncIterator&&null!=(t=e[Symbol.asyncIterator]))return t.call(e);if(Symbol.iterator&&null!=(t=e[Symbol.iterator]))return t.call(e)}throw new TypeError("Object is not async iterable")}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getFirstItem=function(e){return e[Symbol.asyncIterator]().next().then(e=>e.value)},t.iteratorFor=function(e){return{async next(){if(e!==n){const t=await e;return e=n,{value:t}}return{done:!0}}}};const n={}},function(e,t){e.exports=function(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}},function(e,t,r){(t=e.exports=r(142)).Stream=t,t.Readable=t,t.Writable=r(91),t.Duplex=r(32),t.Transform=r(145),t.PassThrough=r(335)},function(e,t,r){var n=r(7),i=n.Buffer;function a(e,t){for(var r in e)t[r]=e[r]}function o(e,t,r){return i(e,t,r)}i.from&&i.alloc&&i.allocUnsafe&&i.allocUnsafeSlow?e.exports=n:(a(n,t),t.Buffer=o),a(i,o),o.from=function(e,t,r){if("number"==typeof e)throw new TypeError("Argument must not be a number");return i(e,t,r)},o.alloc=function(e,t,r){if("number"!=typeof e)throw new TypeError("Argument must be a number");var n=i(e);return void 0!==t?"string"==typeof r?n.fill(t,r):n.fill(t):n.fill(0),n},o.allocUnsafe=function(e){if("number"!=typeof e)throw new TypeError("Argument must be a number");return i(e)},o.allocUnsafeSlow=function(e){if("number"!=typeof e)throw new TypeError("Argument must be a number");return n.SlowBuffer(e)}},function(e,t,r){"use strict";(function(t,n,i){var a=r(67);function o(e){var t=this;this.next=null,this.entry=null,this.finish=function(){!function(e,t,r){var n=e.entry;e.entry=null;for(;n;){var i=n.callback;t.pendingcb--,i(r),n=n.next}t.corkedRequestsFree?t.corkedRequestsFree.next=e:t.corkedRequestsFree=e}(t,e)}}e.exports=b;var s,c=!t.browser&&["v0.10","v0.9."].indexOf(t.version.slice(0,5))>-1?n:a.nextTick;b.WritableState=g;var u=r(50);u.inherits=r(1);var l={deprecate:r(334)},f=r(143),d=r(90).Buffer,h=i.Uint8Array||function(){};var p,y=r(144);function m(){}function g(e,t){s=s||r(32),e=e||{};var n=t instanceof s;this.objectMode=!!e.objectMode,n&&(this.objectMode=this.objectMode||!!e.writableObjectMode);var i=e.highWaterMark,u=e.writableHighWaterMark,l=this.objectMode?16:16384;this.highWaterMark=i||0===i?i:n&&(u||0===u)?u:l,this.highWaterMark=Math.floor(this.highWaterMark),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var f=!1===e.decodeStrings;this.decodeStrings=!f,this.defaultEncoding=e.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(e){!function(e,t){var r=e._writableState,n=r.sync,i=r.writecb;if(function(e){e.writing=!1,e.writecb=null,e.length-=e.writelen,e.writelen=0}(r),t)!function(e,t,r,n,i){--t.pendingcb,r?(a.nextTick(i,n),a.nextTick(x,e,t),e._writableState.errorEmitted=!0,e.emit("error",n)):(i(n),e._writableState.errorEmitted=!0,e.emit("error",n),x(e,t))}(e,r,n,t,i);else{var o=S(r);o||r.corked||r.bufferProcessing||!r.bufferedRequest||w(e,r),n?c(_,e,r,o,i):_(e,r,o,i)}}(t,e)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.bufferedRequestCount=0,this.corkedRequestsFree=new o(this)}function b(e){if(s=s||r(32),!(p.call(b,this)||this instanceof s))return new b(e);this._writableState=new g(e,this),this.writable=!0,e&&("function"==typeof e.write&&(this._write=e.write),"function"==typeof e.writev&&(this._writev=e.writev),"function"==typeof e.destroy&&(this._destroy=e.destroy),"function"==typeof e.final&&(this._final=e.final)),f.call(this)}function v(e,t,r,n,i,a,o){t.writelen=n,t.writecb=o,t.writing=!0,t.sync=!0,r?e._writev(i,t.onwrite):e._write(i,a,t.onwrite),t.sync=!1}function _(e,t,r,n){r||function(e,t){0===t.length&&t.needDrain&&(t.needDrain=!1,e.emit("drain"))}(e,t),t.pendingcb--,n(),x(e,t)}function w(e,t){t.bufferProcessing=!0;var r=t.bufferedRequest;if(e._writev&&r&&r.next){var n=t.bufferedRequestCount,i=new Array(n),a=t.corkedRequestsFree;a.entry=r;for(var s=0,c=!0;r;)i[s]=r,r.isBuf||(c=!1),r=r.next,s+=1;i.allBuffers=c,v(e,t,!0,t.length,i,"",a.finish),t.pendingcb++,t.lastBufferedRequest=null,a.next?(t.corkedRequestsFree=a.next,a.next=null):t.corkedRequestsFree=new o(t),t.bufferedRequestCount=0}else{for(;r;){var u=r.chunk,l=r.encoding,f=r.callback;if(v(e,t,!1,t.objectMode?1:u.length,u,l,f),r=r.next,t.bufferedRequestCount--,t.writing)break}null===r&&(t.lastBufferedRequest=null)}t.bufferedRequest=r,t.bufferProcessing=!1}function S(e){return e.ending&&0===e.length&&null===e.bufferedRequest&&!e.finished&&!e.writing}function E(e,t){e._final(function(r){t.pendingcb--,r&&e.emit("error",r),t.prefinished=!0,e.emit("prefinish"),x(e,t)})}function x(e,t){var r=S(t);return r&&(!function(e,t){t.prefinished||t.finalCalled||("function"==typeof e._final?(t.pendingcb++,t.finalCalled=!0,a.nextTick(E,e,t)):(t.prefinished=!0,e.emit("prefinish")))}(e,t),0===t.pendingcb&&(t.finished=!0,e.emit("finish"))),r}u.inherits(b,f),g.prototype.getBuffer=function(){for(var e=this.bufferedRequest,t=[];e;)t.push(e),e=e.next;return t},function(){try{Object.defineProperty(g.prototype,"buffer",{get:l.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch(e){}}(),"function"==typeof Symbol&&Symbol.hasInstance&&"function"==typeof Function.prototype[Symbol.hasInstance]?(p=Function.prototype[Symbol.hasInstance],Object.defineProperty(b,Symbol.hasInstance,{value:function(e){return!!p.call(this,e)||this===b&&(e&&e._writableState instanceof g)}})):p=function(e){return e instanceof this},b.prototype.pipe=function(){this.emit("error",new Error("Cannot pipe, not readable"))},b.prototype.write=function(e,t,r){var n,i=this._writableState,o=!1,s=!i.objectMode&&(n=e,d.isBuffer(n)||n instanceof h);return s&&!d.isBuffer(e)&&(e=function(e){return d.from(e)}(e)),"function"==typeof t&&(r=t,t=null),s?t="buffer":t||(t=i.defaultEncoding),"function"!=typeof r&&(r=m),i.ended?function(e,t){var r=new Error("write after end");e.emit("error",r),a.nextTick(t,r)}(this,r):(s||function(e,t,r,n){var i=!0,o=!1;return null===r?o=new TypeError("May not write null values to stream"):"string"==typeof r||void 0===r||t.objectMode||(o=new TypeError("Invalid non-string/buffer chunk")),o&&(e.emit("error",o),a.nextTick(n,o),i=!1),i}(this,i,e,r))&&(i.pendingcb++,o=function(e,t,r,n,i,a){if(!r){var o=function(e,t,r){e.objectMode||!1===e.decodeStrings||"string"!=typeof t||(t=d.from(t,r));return t}(t,n,i);n!==o&&(r=!0,i="buffer",n=o)}var s=t.objectMode?1:n.length;t.length+=s;var c=t.length<t.highWaterMark;c||(t.needDrain=!0);if(t.writing||t.corked){var u=t.lastBufferedRequest;t.lastBufferedRequest={chunk:n,encoding:i,isBuf:r,callback:a,next:null},u?u.next=t.lastBufferedRequest:t.bufferedRequest=t.lastBufferedRequest,t.bufferedRequestCount+=1}else v(e,t,!1,s,n,i,a);return c}(this,i,s,e,t,r)),o},b.prototype.cork=function(){this._writableState.corked++},b.prototype.uncork=function(){var e=this._writableState;e.corked&&(e.corked--,e.writing||e.corked||e.finished||e.bufferProcessing||!e.bufferedRequest||w(this,e))},b.prototype.setDefaultEncoding=function(e){if("string"==typeof e&&(e=e.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((e+"").toLowerCase())>-1))throw new TypeError("Unknown encoding: "+e);return this._writableState.defaultEncoding=e,this},Object.defineProperty(b.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),b.prototype._write=function(e,t,r){r(new Error("_write() is not implemented"))},b.prototype._writev=null,b.prototype.end=function(e,t,r){var n=this._writableState;"function"==typeof e?(r=e,e=null,t=null):"function"==typeof t&&(r=t,t=null),null!=e&&this.write(e,t),n.corked&&(n.corked=1,this.uncork()),n.ending||n.finished||function(e,t,r){t.ending=!0,x(e,t),r&&(t.finished?a.nextTick(r):e.once("finish",r));t.ended=!0,e.writable=!1}(this,n,r)},Object.defineProperty(b.prototype,"destroyed",{get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(e){this._writableState&&(this._writableState.destroyed=e)}}),b.prototype.destroy=y.destroy,b.prototype._undestroy=y.undestroy,b.prototype._destroy=function(e,t){this.end(),t(e)}}).call(this,r(13),r(15).setImmediate,r(9))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.RDFA_FEATURES={"":{baseTag:!0,xmlBase:!0,langAttribute:!0,onlyAllowUriRelRevIfProperty:!0,inheritSubjectInHeadBody:!0,datetimeAttribute:!0,timeTag:!0,htmlDatatype:!0,copyRdfaPatterns:!0,xmlnsPrefixMappings:!0,xhtmlInitialContext:!0,roleAttribute:!0},core:{baseTag:!1,xmlBase:!1,langAttribute:!0,onlyAllowUriRelRevIfProperty:!0,inheritSubjectInHeadBody:!1,datetimeAttribute:!1,timeTag:!1,htmlDatatype:!1,copyRdfaPatterns:!0,xmlnsPrefixMappings:!0,xhtmlInitialContext:!1,roleAttribute:!1},html:{baseTag:!0,xmlBase:!1,langAttribute:!0,onlyAllowUriRelRevIfProperty:!0,inheritSubjectInHeadBody:!0,datetimeAttribute:!0,timeTag:!0,htmlDatatype:!0,copyRdfaPatterns:!0,xmlnsPrefixMappings:!0,xhtmlInitialContext:!1,roleAttribute:!0},xhtml:{baseTag:!0,xmlBase:!1,langAttribute:!0,onlyAllowUriRelRevIfProperty:!0,inheritSubjectInHeadBody:!0,datetimeAttribute:!0,timeTag:!0,htmlDatatype:!0,copyRdfaPatterns:!0,xmlnsPrefixMappings:!0,xhtmlInitialContext:!0,roleAttribute:!0},xml:{baseTag:!1,xmlBase:!0,langAttribute:!0,onlyAllowUriRelRevIfProperty:!1,inheritSubjectInHeadBody:!1,datetimeAttribute:!0,timeTag:!0,htmlDatatype:!1,copyRdfaPatterns:!1,xmlnsPrefixMappings:!0,xhtmlInitialContext:!1,roleAttribute:!0}},t.RDFA_CONTENTTYPES={"text/html":"html","application/xhtml+xml":"xhtml","application/xml":"xml","text/xml":"xml","image/svg+xml":"xml"}},function(e,t,r){"use strict";function n(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}Object.defineProperty(t,"__esModule",{value:!0}),n(r(193)),n(r(433)),n(r(203))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(71);t.NodeHandlerDefinitionAdapter=class extends n.NodeHandlerAdapter{constructor(e,t,r){super(e,t,r)}}},function(e,t,r){var n=r(456).Parser,i=r(459);e.exports={Parser:function(e,t){var r={};for(var i in e||{})r[i]=e[i];var a=new n;return a.parse=function(){return n.base=t||"",n.prefixes=Object.create(r),n.prototype.parse.apply(a,arguments)},a._resetBlanks=n._resetBlanks,a},Generator:i}},function(e,t,r){"use strict";function n(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}Object.defineProperty(t,"__esModule",{value:!0}),n(r(472)),n(r(201))},function(e,t,r){"use strict";(function(e){var n=r(158),i=r(473),a=e.from&&e.from!==Uint8Array.from;function o(e,t){return"string"==typeof e?t==e:e&&"function"==typeof e.exec?e.exec(t):"boolean"==typeof e||"object"==typeof e?e:"function"==typeof e&&e(t)}t.parse=function(t,r){var s,c,u=new n,l=i(function(t){"string"==typeof t&&(t=a?e.from(t):new e(t)),u.write(t)},function(e){e&&l.write(e),s&&l.emit("header",s),c&&l.emit("footer",c),l.queue(null)});"string"==typeof t&&(t=t.split(".").map(function(e){return"$*"===e?{emitKey:!0}:"*"===e||(""===e?{recurse:!0}:e)}));return t&&t.length||(t=null),u.onValue=function(e){if(this.root||(l.root=e),t){for(var n=0,i=0,a=!1,c=!1;n<t.length;){var u,d=t[n];if(i++,d&&!d.recurse){if(!(u=i===this.stack.length?this:this.stack[i]))return;if(!o(d,u.key))return void f(u.key,e);a=!!d.emitKey,c=!!d.emitPath,n++}else{var h=t[++n];if(!h)return;for(;;){if(!(u=i===this.stack.length?this:this.stack[i]))return;if(o(h,u.key)){n++,Object.isFrozen(this.stack[i])||(this.stack[i].value=null);break}f(u.key,e),i++}}}if(s&&(l.emit("header",s),s=!1),i===this.stack.length){0;var p=this.stack.slice(1).map(function(e){return e.key}).concat([this.key]),y=e;for(var m in null!=y&&null!=(y=r?r(y,p):y)&&((a||c)&&(y={value:y},a&&(y.key=this.key),c&&(y.path=p)),l.queue(y)),this.value&&delete this.value[this.key],this.stack)Object.isFrozen(this.stack[m])||(this.stack[m].value=null)}}},u._onToken=u.onToken,u.onToken=function(e,r){u._onToken(e,r),0===this.stack.length&&l.root&&(t||l.queue(l.root),0,l.root=null)},u.onError=function(e){e.message.indexOf("at position")>-1&&(e.message="Invalid JSON ("+e.message+")"),l.emit("error",e)},l;function f(e,t){!1!==s&&((s=s||{})[e]=t),!1!==c&&!1===s&&((c=c||{})[e]=t)}},t.stringify=function(e,t,r,n){n=n||0,!1===e?(e="",t="\n",r=""):null==e&&(e="[\n",t="\n,\n",r="\n]\n");var a,o=!0,s=!1;return a=i(function(r){s=!0;try{var i=JSON.stringify(r,null,n)}catch(e){return a.emit("error",e)}o?(o=!1,a.queue(e+i)):a.queue(t+i)},function(t){s||a.queue(e),a.queue(r),a.queue(null)})},t.stringifyObject=function(e,t,r,n){n=n||0,!1===e?(e="",t="\n",r=""):null==e&&(e="{\n",t="\n,\n",r="\n}\n");var a=!0,o=!1;return i(function(r){o=!0;var i=JSON.stringify(r[0])+":"+JSON.stringify(r[1],null,n);a?(a=!1,this.queue(e+i)):this.queue(t+i)},function(t){o||this.queue(e),this.queue(r),this.queue(null)})}}).call(this,r(7).Buffer)},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(480))},function(e,t,r){"use strict";const n=r(529),i=Symbol("max"),a=Symbol("length"),o=Symbol("lengthCalculator"),s=Symbol("allowStale"),c=Symbol("maxAge"),u=Symbol("dispose"),l=Symbol("noDisposeOnSet"),f=Symbol("lruList"),d=Symbol("cache"),h=Symbol("updateAgeOnGet"),p=()=>1;const y=(e,t,r)=>{const n=e[d].get(t);if(n){const t=n.value;if(m(e,t)){if(b(e,n),!e[s])return}else r&&(e[h]&&(n.value.now=Date.now()),e[f].unshiftNode(n));return t.value}},m=(e,t)=>{if(!t||!t.maxAge&&!e[c])return!1;const r=Date.now()-t.now;return t.maxAge?r>t.maxAge:e[c]&&r>e[c]},g=e=>{if(e[a]>e[i])for(let t=e[f].tail;e[a]>e[i]&&null!==t;){const r=t.prev;b(e,t),t=r}},b=(e,t)=>{if(t){const r=t.value;e[u]&&e[u](r.key,r.value),e[a]-=r.length,e[d].delete(r.key),e[f].removeNode(t)}};class v{constructor(e,t,r,n,i){this.key=e,this.value=t,this.length=r,this.now=n,this.maxAge=i||0}}const _=(e,t,r,n)=>{let i=r.value;m(e,i)&&(b(e,r),e[s]||(i=void 0)),i&&t.call(n,i.value,i.key,e)};e.exports=class{constructor(e){if("number"==typeof e&&(e={max:e}),e||(e={}),e.max&&("number"!=typeof e.max||e.max<0))throw new TypeError("max must be a non-negative number");this[i]=e.max||1/0;const t=e.length||p;if(this[o]="function"!=typeof t?p:t,this[s]=e.stale||!1,e.maxAge&&"number"!=typeof e.maxAge)throw new TypeError("maxAge must be a number");this[c]=e.maxAge||0,this[u]=e.dispose,this[l]=e.noDisposeOnSet||!1,this[h]=e.updateAgeOnGet||!1,this.reset()}set max(e){if("number"!=typeof e||e<0)throw new TypeError("max must be a non-negative number");this[i]=e||1/0,g(this)}get max(){return this[i]}set allowStale(e){this[s]=!!e}get allowStale(){return this[s]}set maxAge(e){if("number"!=typeof e)throw new TypeError("maxAge must be a non-negative number");this[c]=e,g(this)}get maxAge(){return this[c]}set lengthCalculator(e){"function"!=typeof e&&(e=p),e!==this[o]&&(this[o]=e,this[a]=0,this[f].forEach(e=>{e.length=this[o](e.value,e.key),this[a]+=e.length})),g(this)}get lengthCalculator(){return this[o]}get length(){return this[a]}get itemCount(){return this[f].length}rforEach(e,t){t=t||this;for(let r=this[f].tail;null!==r;){const n=r.prev;_(this,e,r,t),r=n}}forEach(e,t){t=t||this;for(let r=this[f].head;null!==r;){const n=r.next;_(this,e,r,t),r=n}}keys(){return this[f].toArray().map(e=>e.key)}values(){return this[f].toArray().map(e=>e.value)}reset(){this[u]&&this[f]&&this[f].length&&this[f].forEach(e=>this[u](e.key,e.value)),this[d]=new Map,this[f]=new n,this[a]=0}dump(){return this[f].map(e=>!m(this,e)&&{k:e.key,v:e.value,e:e.now+(e.maxAge||0)}).toArray().filter(e=>e)}dumpLru(){return this[f]}set(e,t,r){if((r=r||this[c])&&"number"!=typeof r)throw new TypeError("maxAge must be a number");const n=r?Date.now():0,s=this[o](t,e);if(this[d].has(e)){if(s>this[i])return b(this,this[d].get(e)),!1;const o=this[d].get(e).value;return this[u]&&(this[l]||this[u](e,o.value)),o.now=n,o.maxAge=r,o.value=t,this[a]+=s-o.length,o.length=s,this.get(e),g(this),!0}const h=new v(e,t,s,n,r);return h.length>this[i]?(this[u]&&this[u](e,t),!1):(this[a]+=h.length,this[f].unshift(h),this[d].set(e,this[f].head),g(this),!0)}has(e){if(!this[d].has(e))return!1;const t=this[d].get(e).value;return!m(this,t)}get(e){return y(this,e,!0)}peek(e){return y(this,e,!1)}pop(){const e=this[f].tail;return e?(b(this,e),e.value):null}del(e){b(this,this[d].get(e))}load(e){this.reset();const t=Date.now();for(let r=e.length-1;r>=0;r--){const n=e[r],i=n.e||0;if(0===i)this.set(n.k,n.v);else{const e=i-t;e>0&&this.set(n.k,n.v,e)}}}prune(){this[d].forEach((e,t)=>y(this,t,!1))}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(592))},function(e,t,r){"use strict";var n=r(1),i=r(249),a=r(2).Buffer,o=new Array(16);function s(){i.call(this,64),this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878}function c(e,t){return e<<t|e>>>32-t}function u(e,t,r,n,i,a,o){return c(e+(t&r|~t&n)+i+a|0,o)+t|0}function l(e,t,r,n,i,a,o){return c(e+(t&n|r&~n)+i+a|0,o)+t|0}function f(e,t,r,n,i,a,o){return c(e+(t^r^n)+i+a|0,o)+t|0}function d(e,t,r,n,i,a,o){return c(e+(r^(t|~n))+i+a|0,o)+t|0}n(s,i),s.prototype._update=function(){for(var e=o,t=0;t<16;++t)e[t]=this._block.readInt32LE(4*t);var r=this._a,n=this._b,i=this._c,a=this._d;r=u(r,n,i,a,e[0],3614090360,7),a=u(a,r,n,i,e[1],3905402710,12),i=u(i,a,r,n,e[2],606105819,17),n=u(n,i,a,r,e[3],3250441966,22),r=u(r,n,i,a,e[4],4118548399,7),a=u(a,r,n,i,e[5],1200080426,12),i=u(i,a,r,n,e[6],2821735955,17),n=u(n,i,a,r,e[7],4249261313,22),r=u(r,n,i,a,e[8],1770035416,7),a=u(a,r,n,i,e[9],2336552879,12),i=u(i,a,r,n,e[10],4294925233,17),n=u(n,i,a,r,e[11],2304563134,22),r=u(r,n,i,a,e[12],1804603682,7),a=u(a,r,n,i,e[13],4254626195,12),i=u(i,a,r,n,e[14],2792965006,17),r=l(r,n=u(n,i,a,r,e[15],1236535329,22),i,a,e[1],4129170786,5),a=l(a,r,n,i,e[6],3225465664,9),i=l(i,a,r,n,e[11],643717713,14),n=l(n,i,a,r,e[0],3921069994,20),r=l(r,n,i,a,e[5],3593408605,5),a=l(a,r,n,i,e[10],38016083,9),i=l(i,a,r,n,e[15],3634488961,14),n=l(n,i,a,r,e[4],3889429448,20),r=l(r,n,i,a,e[9],568446438,5),a=l(a,r,n,i,e[14],3275163606,9),i=l(i,a,r,n,e[3],4107603335,14),n=l(n,i,a,r,e[8],1163531501,20),r=l(r,n,i,a,e[13],2850285829,5),a=l(a,r,n,i,e[2],4243563512,9),i=l(i,a,r,n,e[7],1735328473,14),r=f(r,n=l(n,i,a,r,e[12],2368359562,20),i,a,e[5],4294588738,4),a=f(a,r,n,i,e[8],2272392833,11),i=f(i,a,r,n,e[11],1839030562,16),n=f(n,i,a,r,e[14],4259657740,23),r=f(r,n,i,a,e[1],2763975236,4),a=f(a,r,n,i,e[4],1272893353,11),i=f(i,a,r,n,e[7],4139469664,16),n=f(n,i,a,r,e[10],3200236656,23),r=f(r,n,i,a,e[13],681279174,4),a=f(a,r,n,i,e[0],3936430074,11),i=f(i,a,r,n,e[3],3572445317,16),n=f(n,i,a,r,e[6],76029189,23),r=f(r,n,i,a,e[9],3654602809,4),a=f(a,r,n,i,e[12],3873151461,11),i=f(i,a,r,n,e[15],530742520,16),r=d(r,n=f(n,i,a,r,e[2],3299628645,23),i,a,e[0],4096336452,6),a=d(a,r,n,i,e[7],1126891415,10),i=d(i,a,r,n,e[14],2878612391,15),n=d(n,i,a,r,e[5],4237533241,21),r=d(r,n,i,a,e[12],1700485571,6),a=d(a,r,n,i,e[3],2399980690,10),i=d(i,a,r,n,e[10],4293915773,15),n=d(n,i,a,r,e[1],2240044497,21),r=d(r,n,i,a,e[8],1873313359,6),a=d(a,r,n,i,e[15],4264355552,10),i=d(i,a,r,n,e[6],2734768916,15),n=d(n,i,a,r,e[13],1309151649,21),r=d(r,n,i,a,e[4],4149444226,6),a=d(a,r,n,i,e[11],3174756917,10),i=d(i,a,r,n,e[2],718787259,15),n=d(n,i,a,r,e[9],3951481745,21),this._a=this._a+r|0,this._b=this._b+n|0,this._c=this._c+i|0,this._d=this._d+a|0},s.prototype._digest=function(){this._block[this._blockOffset++]=128,this._blockOffset>56&&(this._block.fill(0,this._blockOffset,64),this._update(),this._blockOffset=0),this._block.fill(0,this._blockOffset,56),this._block.writeUInt32LE(this._length[0],56),this._block.writeUInt32LE(this._length[1],60),this._update();var e=a.allocUnsafe(16);return e.writeInt32LE(this._a,0),e.writeInt32LE(this._b,4),e.writeInt32LE(this._c,8),e.writeInt32LE(this._d,12),e},e.exports=s},function(e,t,r){"use strict";var n=r(7).Buffer,i=r(1),a=r(249),o=new Array(16),s=[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,7,4,13,1,10,6,15,3,12,0,9,5,2,14,11,8,3,10,14,4,9,15,8,1,2,7,0,6,13,11,5,12,1,9,11,10,0,8,12,4,13,3,7,15,14,5,6,2,4,0,5,9,7,12,2,10,14,1,3,8,11,6,15,13],c=[5,14,7,0,9,2,11,4,13,6,15,8,1,10,3,12,6,11,3,7,0,13,5,10,14,15,8,12,4,9,1,2,15,5,1,3,7,14,6,9,11,8,12,2,10,0,4,13,8,6,4,1,3,11,15,0,5,12,2,13,9,7,10,14,12,15,10,4,1,5,8,7,6,2,13,14,0,3,9,11],u=[11,14,15,12,5,8,7,9,11,13,14,15,6,7,9,8,7,6,8,13,11,9,7,15,7,12,15,9,11,7,13,12,11,13,6,7,14,9,13,15,14,8,13,6,5,12,7,5,11,12,14,15,14,15,9,8,9,14,5,6,8,6,5,12,9,15,5,11,6,8,13,12,5,12,13,14,11,8,5,6],l=[8,9,9,11,13,15,15,5,7,7,8,11,14,14,12,6,9,13,15,7,12,8,9,11,7,7,12,7,6,15,13,11,9,7,15,11,8,6,6,14,12,13,5,14,13,13,7,5,15,5,8,11,14,14,6,14,6,9,12,9,12,5,15,8,8,5,12,9,12,5,14,6,8,13,6,5,15,13,11,11],f=[0,1518500249,1859775393,2400959708,2840853838],d=[1352829926,1548603684,1836072691,2053994217,0];function h(){a.call(this,64),this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520}function p(e,t){return e<<t|e>>>32-t}function y(e,t,r,n,i,a,o,s){return p(e+(t^r^n)+a+o|0,s)+i|0}function m(e,t,r,n,i,a,o,s){return p(e+(t&r|~t&n)+a+o|0,s)+i|0}function g(e,t,r,n,i,a,o,s){return p(e+((t|~r)^n)+a+o|0,s)+i|0}function b(e,t,r,n,i,a,o,s){return p(e+(t&n|r&~n)+a+o|0,s)+i|0}function v(e,t,r,n,i,a,o,s){return p(e+(t^(r|~n))+a+o|0,s)+i|0}i(h,a),h.prototype._update=function(){for(var e=o,t=0;t<16;++t)e[t]=this._block.readInt32LE(4*t);for(var r=0|this._a,n=0|this._b,i=0|this._c,a=0|this._d,h=0|this._e,_=0|this._a,w=0|this._b,S=0|this._c,E=0|this._d,x=0|this._e,T=0;T<80;T+=1){var O,A;T<16?(O=y(r,n,i,a,h,e[s[T]],f[0],u[T]),A=v(_,w,S,E,x,e[c[T]],d[0],l[T])):T<32?(O=m(r,n,i,a,h,e[s[T]],f[1],u[T]),A=b(_,w,S,E,x,e[c[T]],d[1],l[T])):T<48?(O=g(r,n,i,a,h,e[s[T]],f[2],u[T]),A=g(_,w,S,E,x,e[c[T]],d[2],l[T])):T<64?(O=b(r,n,i,a,h,e[s[T]],f[3],u[T]),A=m(_,w,S,E,x,e[c[T]],d[3],l[T])):(O=v(r,n,i,a,h,e[s[T]],f[4],u[T]),A=y(_,w,S,E,x,e[c[T]],d[4],l[T])),r=h,h=a,a=p(i,10),i=n,n=O,_=x,x=E,E=p(S,10),S=w,w=A}var I=this._b+i+E|0;this._b=this._c+a+x|0,this._c=this._d+h+_|0,this._d=this._e+r+w|0,this._e=this._a+n+S|0,this._a=I},h.prototype._digest=function(){this._block[this._blockOffset++]=128,this._blockOffset>56&&(this._block.fill(0,this._blockOffset,64),this._update(),this._blockOffset=0),this._block.fill(0,this._blockOffset,56),this._block.writeUInt32LE(this._length[0],56),this._block.writeUInt32LE(this._length[1],60),this._update();var e=n.alloc?n.alloc(20):new n(20);return e.writeInt32LE(this._a,0),e.writeInt32LE(this._b,4),e.writeInt32LE(this._c,8),e.writeInt32LE(this._d,12),e.writeInt32LE(this._e,16),e},e.exports=h},function(e,t,r){(t=e.exports=function(e){e=e.toLowerCase();var r=t[e];if(!r)throw new Error(e+" is not supported (we accept pull requests)");return new r}).sha=r(596),t.sha1=r(597),t.sha224=r(598),t.sha256=r(250),t.sha384=r(599),t.sha512=r(251)},function(e,t,r){"use strict";t.utils=r(605),t.Cipher=r(606),t.DES=r(607),t.CBC=r(608),t.EDE=r(609)},function(e,t,r){var n=r(610),i=r(618),a=r(261);t.createCipher=t.Cipher=n.createCipher,t.createCipheriv=t.Cipheriv=n.createCipheriv,t.createDecipher=t.Decipher=i.createDecipher,t.createDecipheriv=t.Decipheriv=i.createDecipheriv,t.listCiphers=t.getCiphers=function(){return Object.keys(a)}},function(e,t,r){var n={ECB:r(611),CBC:r(612),CFB:r(613),CFB8:r(614),CFB1:r(615),OFB:r(616),CTR:r(259),GCM:r(259)},i=r(261);for(var a in i)i[a].module=n[i[a].mode];e.exports=i},function(e,t,r){var n;function i(e){this.rand=e}if(e.exports=function(e){return n||(n=new i(null)),n.generate(e)},e.exports.Rand=i,i.prototype.generate=function(e){return this._rand(e)},i.prototype._rand=function(e){if(this.rand.getBytes)return this.rand.getBytes(e);for(var t=new Uint8Array(e),r=0;r<t.length;r++)t[r]=this.rand.getByte();return t},"object"==typeof self)self.crypto&&self.crypto.getRandomValues?i.prototype._rand=function(e){var t=new Uint8Array(e);return self.crypto.getRandomValues(t),t}:self.msCrypto&&self.msCrypto.getRandomValues?i.prototype._rand=function(e){var t=new Uint8Array(e);return self.msCrypto.getRandomValues(t),t}:"object"==typeof window&&(i.prototype._rand=function(){throw new Error("Not implemented yet")});else try{var a=r(622);if("function"!=typeof a.randomBytes)throw new Error("Not supported");i.prototype._rand=function(e){return a.randomBytes(e)}}catch(e){}},function(e,t,r){(function(t){var n=r(11),i=r(43);function a(e,r){var i=function(e){var t=o(e);return{blinder:t.toRed(n.mont(e.modulus)).redPow(new n(e.publicExponent)).fromRed(),unblinder:t.invm(e.modulus)}}(r),a=r.modulus.byteLength(),s=(n.mont(r.modulus),new n(e).mul(i.blinder).umod(r.modulus)),c=s.toRed(n.mont(r.prime1)),u=s.toRed(n.mont(r.prime2)),l=r.coefficient,f=r.prime1,d=r.prime2,h=c.redPow(r.exponent1),p=u.redPow(r.exponent2);h=h.fromRed(),p=p.fromRed();var y=h.isub(p).imul(l).umod(f);return y.imul(d),p.iadd(y),new t(p.imul(i.unblinder).umod(r.modulus).toArray(!1,a))}function o(e){for(var t=e.modulus.byteLength(),r=new n(i(t));r.cmp(e.modulus)>=0||!r.umod(e.prime1)||!r.umod(e.prime2);)r=new n(i(t));return r}e.exports=a,a.getr=o}).call(this,r(7).Buffer)},function(e,t,r){"use strict";var n=t;n.version=r(627).version,n.utils=r(17),n.rand=r(107),n.curve=r(267),n.curves=r(110),n.ec=r(638),n.eddsa=r(642)},function(e,t,r){"use strict";var n,i=t,a=r(111),o=r(267),s=r(17).assert;function c(e){"short"===e.type?this.curve=new o.short(e):"edwards"===e.type?this.curve=new o.edwards(e):this.curve=new o.mont(e),this.g=this.curve.g,this.n=this.curve.n,this.hash=e.hash,s(this.g.validate(),"Invalid curve"),s(this.g.mul(this.n).isInfinity(),"Invalid curve, G*N != O")}function u(e,t){Object.defineProperty(i,e,{configurable:!0,enumerable:!0,get:function(){var r=new c(t);return Object.defineProperty(i,e,{configurable:!0,enumerable:!0,value:r}),r}})}i.PresetCurve=c,u("p192",{type:"short",prime:"p192",p:"ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff",a:"ffffffff ffffffff ffffffff fffffffe ffffffff fffffffc",b:"64210519 e59c80e7 0fa7e9ab 72243049 feb8deec c146b9b1",n:"ffffffff ffffffff ffffffff 99def836 146bc9b1 b4d22831",hash:a.sha256,gRed:!1,g:["188da80e b03090f6 7cbf20eb 43a18800 f4ff0afd 82ff1012","07192b95 ffc8da78 631011ed 6b24cdd5 73f977a1 1e794811"]}),u("p224",{type:"short",prime:"p224",p:"ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001",a:"ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff fffffffe",b:"b4050a85 0c04b3ab f5413256 5044b0b7 d7bfd8ba 270b3943 2355ffb4",n:"ffffffff ffffffff ffffffff ffff16a2 e0b8f03e 13dd2945 5c5c2a3d",hash:a.sha256,gRed:!1,g:["b70e0cbd 6bb4bf7f 321390b9 4a03c1d3 56c21122 343280d6 115c1d21","bd376388 b5f723fb 4c22dfe6 cd4375a0 5a074764 44d58199 85007e34"]}),u("p256",{type:"short",prime:null,p:"ffffffff 00000001 00000000 00000000 00000000 ffffffff ffffffff ffffffff",a:"ffffffff 00000001 00000000 00000000 00000000 ffffffff ffffffff fffffffc",b:"5ac635d8 aa3a93e7 b3ebbd55 769886bc 651d06b0 cc53b0f6 3bce3c3e 27d2604b",n:"ffffffff 00000000 ffffffff ffffffff bce6faad a7179e84 f3b9cac2 fc632551",hash:a.sha256,gRed:!1,g:["6b17d1f2 e12c4247 f8bce6e5 63a440f2 77037d81 2deb33a0 f4a13945 d898c296","4fe342e2 fe1a7f9b 8ee7eb4a 7c0f9e16 2bce3357 6b315ece cbb64068 37bf51f5"]}),u("p384",{type:"short",prime:null,p:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe ffffffff 00000000 00000000 ffffffff",a:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe ffffffff 00000000 00000000 fffffffc",b:"b3312fa7 e23ee7e4 988e056b e3f82d19 181d9c6e fe814112 0314088f 5013875a c656398d 8a2ed19d 2a85c8ed d3ec2aef",n:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff c7634d81 f4372ddf 581a0db2 48b0a77a ecec196a ccc52973",hash:a.sha384,gRed:!1,g:["aa87ca22 be8b0537 8eb1c71e f320ad74 6e1d3b62 8ba79b98 59f741e0 82542a38 5502f25d bf55296c 3a545e38 72760ab7","3617de4a 96262c6f 5d9e98bf 9292dc29 f8f41dbd 289a147c e9da3113 b5f0b8c0 0a60b1ce 1d7e819d 7a431d7c 90ea0e5f"]}),u("p521",{type:"short",prime:null,p:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff",a:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffc",b:"00000051 953eb961 8e1c9a1f 929a21a0 b68540ee a2da725b 99b315f3 b8b48991 8ef109e1 56193951 ec7e937b 1652c0bd 3bb1bf07 3573df88 3d2c34f1 ef451fd4 6b503f00",n:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffa 51868783 bf2f966b 7fcc0148 f709a5d0 3bb5c9b8 899c47ae bb6fb71e 91386409",hash:a.sha512,gRed:!1,g:["000000c6 858e06b7 0404e9cd 9e3ecb66 2395b442 9c648139 053fb521 f828af60 6b4d3dba a14b5e77 efe75928 fe1dc127 a2ffa8de 3348b3c1 856a429b f97e7e31 c2e5bd66","00000118 39296a78 9a3bc004 5c8a5fb4 2c7d1bd9 98f54449 579b4468 17afbd17 273e662c 97ee7299 5ef42640 c550b901 3fad0761 353c7086 a272c240 88be9476 9fd16650"]}),u("curve25519",{type:"mont",prime:"p25519",p:"7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed",a:"76d06",b:"1",n:"1000000000000000 0000000000000000 14def9dea2f79cd6 5812631a5cf5d3ed",hash:a.sha256,gRed:!1,g:["9"]}),u("ed25519",{type:"edwards",prime:"p25519",p:"7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed",a:"-1",c:"1",d:"52036cee2b6ffe73 8cc740797779e898 00700a4d4141d8ab 75eb4dca135978a3",n:"1000000000000000 0000000000000000 14def9dea2f79cd6 5812631a5cf5d3ed",hash:a.sha256,gRed:!1,g:["216936d3cd6e53fec0a4e231fdd6dc5c692cc7609525a7b2c9562d608f25d51a","6666666666666666666666666666666666666666666666666666666666666658"]});try{n=r(637)}catch(e){n=void 0}u("secp256k1",{type:"short",prime:"k256",p:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f",a:"0",b:"7",n:"ffffffff ffffffff ffffffff fffffffe baaedce6 af48a03b bfd25e8c d0364141",h:"1",hash:a.sha256,beta:"7ae96a2b657c07106e64479eac3434e99cf0497512f58995c1396c28719501ee",lambda:"5363ad4cc05c30e0a5261c028812645a122e22ea20816678df02967c1b23bd72",basis:[{a:"3086d221a7d46bcde86c90e49284eb15",b:"-e4437ed6010e88286f547fa90abfe4c3"},{a:"114ca50f7a8e2f3f657c1108d9d44cfd8",b:"3086d221a7d46bcde86c90e49284eb15"}],gRed:!1,g:["79be667ef9dcbbac55a06295ce870b07029bfcdb2dce28d959f2815b16f81798","483ada7726a3c4655da4fbfc0e1108a8fd17b448a68554199c47d08ffb10d4b8",n]})},function(e,t,r){var n=t;n.utils=r(21),n.common=r(60),n.sha=r(631),n.ripemd=r(635),n.hmac=r(636),n.sha1=n.sha.sha1,n.sha256=n.sha.sha256,n.sha224=n.sha.sha224,n.sha384=n.sha.sha384,n.sha512=n.sha.sha512,n.ripemd160=n.ripemd.ripemd160},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(113),i=r(677),a=r(678),o=r(682);!function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(113)),t.regularFunctions=a.definitions.map((e,t)=>new n.RegularFunction(t,e)).toMap(),t.specialFunctions=o.specialDefinitions.map((e,t)=>new n.SpecialFunction(t,e)).toMap(),t.namedFunctions=i.namedDefinitions.map((e,t)=>new n.NamedFunction(t,e)).toMap()},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(25),i=r(22);class a{constructor(e,t){this.operator=e,this.apply=e=>{return(this.monomorph(e)||this.handleInvalidTypes(e))(e)},this.arity=t.arity,this.overloads=t.overloads}monomorph(e){return this.overloads.get(o.asConcreteTypes(e))||this.overloads.get(o.asTermTypes(e))||this.overloads.get(o.asGenericTerms(e))}}t.BaseFunction=a;class o{static asConcreteTypes(e){return n.List(e.map(e=>e.type||e.termType))}static asTermTypes(e){return n.List(e.map(e=>e.termType))}static asGenericTerms(e){return n.List(Array(e.length).fill("term"))}}t.RegularFunction=class extends a{constructor(e,t){super(e,t),this.functionClass="regular"}handleInvalidTypes(e){throw new i.InvalidArgumentTypes(e,this.operator)}};t.NamedFunction=class extends a{constructor(e,t){super(e,t),this.functionClass="named"}handleInvalidTypes(e){throw new i.InvalidArgumentTypes(e,this.operator)}};t.SpecialFunction=class{constructor(e,t){var r;this.operator=e,this.functionClass="special",this.arity=t.arity,this.applySync=t.applySync,this.applyAsync=t.applyAsync,this.checkArity=t.checkArity||(r=this.arity,e=>r===1/0||(Array.isArray(r)?r.indexOf(e.length)>=0:e.length===r))}};const s={integer:{integer:"integer",decimal:"decimal",float:"float",double:"double"},decimal:{integer:"decimal",decimal:"decimal",float:"float",double:"double"},float:{integer:"float",decimal:"float",float:"float",double:"double"},double:{integer:"double",decimal:"double",float:"double",double:"double"}};t.promote=function(e,t){return s[e][t]}},function(e,t,r){var n=r(135),i=r(136);e.exports=function(e,t,r){var a=t&&r||0;"string"==typeof e&&(t="binary"===e?new Array(16):null,e=null);var o=(e=e||{}).random||(e.rng||n)();if(o[6]=15&o[6]|64,o[8]=63&o[8]|128,t)for(var s=0;s<16;++s)t[a+s]=o[s];return t||i(o)}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;class n{constructor(e,...t){this._isAsync=e.async,this._isFunction=e.function,this._dataProperties=t}static sync(...e){return new n({async:!1},...e)}static syncFunction(...e){return new n({async:!1,function:!0},...e)}static async(...e){return new n({async:!0},...e)}static asyncFunction(...e){return new n({async:!0,function:!0},...e)}handle(e){return this._isFunction?()=>this._resolveDataPath(e):this._resolveDataPath(e)}_resolveDataPath(e){if(!this._isAsync){for(const t of this._dataProperties)e=e&&e[t];return e}return new Promise(async t=>{for(const t of this._dataProperties)e=e&&await e[t];t(e)})}}t.default=n},function(e,t,r){"use strict";var n=r(19);Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var i=n(r(85));t.default=class extends i.default{constructor(){super("DELETE",!0)}}},function(e,t){function r(){this.value=""}r.prototype.equals=function(e){return!!e&&e.termType===this.termType},r.prototype.termType="DefaultGraph",e.exports=r},function(e,t){function r(e){this.value=e}r.prototype.equals=function(e){return!!e&&e.termType===this.termType&&e.value===this.value},r.prototype.termType="NamedNode",e.exports=r},function(e,t,r){"use strict";var n=r(19);Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var i=n(r(120)),a=n(r(122)),o=n(r(86));t.default=class{handle(e,t){var r=this;return(0,a.default)(function*(){const{queryEngine:n}=e.settings;if(!n)throw new Error(`${e} has no queryEngine setting`);const a=yield(0,i.default)(t.sparql);if(!a)throw new Error(`${e} has no sparql property`);var s,c=!0,u=!1;try{for(var l,f,d=(0,o.default)(n.execute(a));c=(l=yield(0,i.default)(d.next())).done,f=yield(0,i.default)(l.value),!c;c=!0){const t=f;yield r.extractTerm(t,e)}}catch(e){u=!0,s=e}finally{try{c||null==d.return||(yield(0,i.default)(d.return()))}finally{if(u)throw s}}})()}extractTerm(e,t){if(1!==e.size)throw new Error("Only single-variable queries are supported");const r=e.values().next().value;return t.extendPath({subject:r},null)}}},function(e,t,r){var n=r(121);e.exports=function(e){return new n(e)}},function(e,t){e.exports=function(e){this.wrapped=e}},function(e,t,r){var n=r(307);e.exports=function(e){return function(){return new n(e.apply(this,arguments))}}},function(e,t,r){"use strict";var n=r(19);Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var i=n(r(85));t.default=class extends i.default{constructor(){super("INSERT",!1)}}},function(e,t,r){"use strict";var n=r(19);Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var i=n(r(88)),a=r(23),o=r(5),s=r(64);t.default=class{constructor(...e){(0,i.default)(this,"_context",Promise.resolve({})),this.extendContext(...e)}supports(e){return"string"==typeof e}resolve(e,t){const r={then:(0,s.getThen)(()=>this.expandProperty(e))};return t.extendPath({property:e,predicate:r})}async expandProperty(e){e=e.replace(/[_$]/,":");const t=a.ContextParser.expandTerm(e,await this._context,!0);if(!a.ContextParser.isValidIri(t))throw new Error(`The JSON-LD context cannot expand the '${e}' property`);return(0,o.namedNode)(t)}async extendContext(...e){await(this._context=this._context.then(t=>(new a.ContextParser).parse([t,...e])))}}},function(e,t,r){"use strict";var n=this&&this.__awaiter||function(e,t,r,n){return new(r||(r=Promise))(function(i,a){function o(e){try{c(n.next(e))}catch(e){a(e)}}function s(e){try{c(n.throw(e))}catch(e){a(e)}}function c(e){e.done?i(e.value):new r(function(t){t(e.value)}).then(o,s)}c((n=n.apply(e,t||[])).next())})};Object.defineProperty(t,"__esModule",{value:!0}),r(48);t.FetchDocumentLoader=class{load(e){return n(this,void 0,void 0,function*(){const t=yield fetch(e,{headers:{accept:"application/ld+json"}});if(t.ok)return yield t.json();throw new Error(`No valid context was found at ${e}: ${t.statusText}`)})}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;t.default=class{async handle(e){const t=[];let r=e;for(;r;)r.mutationExpressions&&t.unshift(...await r.mutationExpressions),r=r.parent;return t}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;t.default=class{async handle(e){const t=[];let r=e;for(;r.parent;){if(r.predicate){const e=await r.predicate;t.unshift({predicate:e})}r=r.parent}if(!r.subject)throw new Error(`Expected root subject in ${r}`);const n=await r.subject;return t.unshift({subject:n}),t}}},function(e,t,r){"use strict";var n=r(19);Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var i=n(r(88));function a(e,t){var r=Object.keys(e);return Object.getOwnPropertySymbols&&r.push.apply(r,Object.getOwnPropertySymbols(e)),t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r}function o(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?a(r,!0).forEach(function(t){(0,i.default)(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):a(r).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}const s=Object.create(null);t.default=class{constructor({handlers:e=s,resolvers:t=[]}={}){this._handlers=e,this._resolvers=t}createPath(e={},t){void 0===t&&([t,e]=[e,{}]);const r=o({settings:e},t),n=r.proxy=new Proxy(r,this);if(!r.extendPath){const t=this;r.extendPath=function r(n,i=this){return t.createPath(e,o({parent:i,extendPath:r},n))}}return n}get(e,t){const r=this._handlers[t];if(r&&"function"==typeof r.handle)return r.handle(e,e.proxy);for(const r of this._resolvers)if(r.supports(t))return r.resolve(t,e,e.proxy)}}},function(e,t,r){"use strict";var n=r(19);Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var i=n(r(115)),a=n(r(130)),o=n(r(312)),s=n(r(313)),c=n(r(127)),u=n(r(131)),l=n(r(119)),f=n(r(126)),d=n(r(123)),h=n(r(132)),p=n(r(133)),y=n(r(314)),m=n(r(116)),g=n(r(134)),b=r(87),v=r(64),_={__esModule:()=>void 0,then:({subject:e},t)=>e?e.then&&(0,v.getThen)(()=>t.subject):(0,v.getThen)(()=>(0,b.getFirstItem)(t.results)),[Symbol.asyncIterator]:({subject:e},t)=>()=>e?(0,b.iteratorFor)(t.subject):t.results[Symbol.asyncIterator](),subject:new a.default,properties:new s.default,predicates:new o.default,pathExpression:new c.default,sparql:new u.default,subjects:new y.default,results:new l.default,mutationExpressions:new f.default,add:new d.default,set:new h.default,replace:new p.default,delete:new m.default,termType:i.default.sync("subject","termType"),value:i.default.sync("subject","value"),equals:i.default.sync("subject","equals"),language:i.default.sync("subject","language"),datatype:i.default.sync("subject","datatype"),toString:i.default.syncFunction("subject","value"),toPrimitive:i.default.syncFunction("subject","value"),resolve:new g.default};t.default=_},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;t.default=class{handle(e){let{subject:t,parent:r}=e;for(;!t&&r;)({subject:t,parent:r}=r);return t?Promise.resolve(t).then(t=>e.extendPath({subject:t},null)):void 0}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;const n=/["\\\t\n\r\b\f\u0000-\u0019\ud800-\udbff]/,i=/["\\\t\n\r\b\f\u0000-\u0019]|[\ud800-\udbff][\udc00-\udfff]/g,a={"\\":"\\\\",'"':'\\"',"\t":"\\t","\n":"\\n","\r":"\\r","\b":"\\b","\f":"\\f"};function o(e){let t=a[e];return void 0===t&&(1===e.length?(t=e.charCodeAt(0).toString(16),t="\\u0000".substr(0,6-t.length)+t):(t=(1024*(e.charCodeAt(0)-55296)+e.charCodeAt(1)+9216).toString(16),t="\\U00000000".substr(0,10-t.length)+t)),t}t.default=class{async handle(e,t){const r=await t.mutationExpressions;if(Array.isArray(r)&&r.length)return r.map(e=>this.mutationExpressionToQuery(e)).join("\n;\n");const n=await t.pathExpression;if(!Array.isArray(n))throw new Error(`${e} has no pathExpression property`);return this.pathExpressionToQuery(e,t,n)}pathExpressionToQuery(e,t,r){if(r.length<2&&!e.finalClause)throw new Error(`${e} should at least contain a subject and a predicate`);let n="?subject";const i=[];return r.length>1&&(n=this.createVar(e.property),i.push(...this.expressionToTriplePatterns(r,n))),e.finalClause&&i.push(e.finalClause(n)),`${`SELECT ${e.distinct?"DISTINCT ":""}${e.select?e.select:n}`} ${`WHERE {\n ${i.join("\n ")}\n}`}`}mutationExpressionToQuery({mutationType:e,conditions:t,predicate:r,objects:n}){const i={};let a,o;if(1===t.length)a=this.termToString(t[0].subject),o=[];else{const e=t[t.length-1].predicate;a=this.createVar(e.value,i),o=this.expressionToTriplePatterns(t,a,i)}const s=n&&n.map(e=>this.termToString(e)).join(", "),c=s?`${a} ${this.termToString(r)} ${s}.`:o[o.length-1];return 0===o.length?`${e} DATA {\n ${c}\n}`:`${e} {\n ${c}\n} WHERE {\n ${o.join("\n ")}\n}`}expressionToTriplePatterns([e,...t],r,n={}){const i=t.length-1;let a=this.termToString(e.subject);return t.map((e,t)=>{const o=a,{predicate:s}=e;return a=t<i?this.createVar(`v${t}`,n):r,`${o} ${this.termToString(s)} ${a}.`})}createVar(e="",t){let r=0,n=`?${e.match(/[a-z0-9]*$/i)[0]||"result"}`;if(t){for(;t[n];)n=`?${e}_${r++}`;t[n]=!0}return n}termToString(e){let{value:t}=e;switch(n.test(t)&&(t=t.replace(i,o)),e.termType){case"NamedNode":return`<${t}>`;case"BlankNode":return`_:${t}`;case"Literal":let r="";return e.language?r=`@${e.language}`:"http://www.w3.org/2001/XMLSchema#string"!==e.datatype.value&&(r=`^^<${e.datatype.value}>`),`"${t}"${r}`;default:throw new Error(`Could not convert a term of type ${e.termType}`)}}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;t.default=class{handle(e,t){return(...e)=>t.delete().add(...e)}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;t.default=class{handle(e,t){return function(e,...r){if(!e||!r.length)throw new Error("Replacing values requires at least two arguments, old value followed by all new values");return t.delete(e).add(...r)}}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;t.default=class{handle(e,t){return(e="",r=t)=>{const n=`"use strict";return ldflex${e.replace(/^(https?:\/\/[^()[\]'"]+)$/,'["$1"]').replace(/^(?=[a-z$_])/i,".").replace(/\[([^'"`\](]*)\]/g,'["$1"]')}`;let i;try{i=Function("ldflex",n)}catch({message:t}){throw new Error(`Expression "${e}" is invalid: ${t}`)}return i(r)}}}},function(e,t){var r="undefined"!=typeof crypto&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto)||"undefined"!=typeof msCrypto&&"function"==typeof window.msCrypto.getRandomValues&&msCrypto.getRandomValues.bind(msCrypto);if(r){var n=new Uint8Array(16);e.exports=function(){return r(n),n}}else{var i=new Array(16);e.exports=function(){for(var e,t=0;t<16;t++)0==(3&t)&&(e=4294967296*Math.random()),i[t]=e>>>((3&t)<<3)&255;return i}}},function(e,t){for(var r=[],n=0;n<256;++n)r[n]=(n+256).toString(16).substr(1);e.exports=function(e,t){var n=t||0,i=r;return[i[e[n++]],i[e[n++]],i[e[n++]],i[e[n++]],"-",i[e[n++]],i[e[n++]],"-",i[e[n++]],i[e[n++]],"-",i[e[n++]],i[e[n++]],"-",i[e[n++]],i[e[n++]],i[e[n++]],i[e[n++]],i[e[n++]],i[e[n++]]].join("")}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(317))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});t.Bus=class{constructor(e){this.actors=[],this.observers=[],this.dependencyLinks=new Map,r(49)(this,e)}subscribe(e){this.actors.push(e),this.reorderForDependencies()}subscribeObserver(e){this.observers.push(e)}unsubscribe(e){const t=this.actors.indexOf(e);return t>=0&&(this.actors.splice(t,1),!0)}unsubscribeObserver(e){const t=this.observers.indexOf(e);return t>=0&&(this.observers.splice(t,1),!0)}publish(e){return this.actors.map(t=>({actor:t,reply:t.test(e)}))}onRun(e,t,r){for(const n of this.observers)n.onRun(e,t,r)}addDependencies(e,t){for(const r of t){let t=this.dependencyLinks.get(r);t||(t=[],this.dependencyLinks.set(r,t)),t.push(e)}this.reorderForDependencies()}reorderForDependencies(){if(this.dependencyLinks.size>0){const e=[];for(const t of this.dependencyLinks.keys()){const r=this.actors.indexOf(t);r>=0&&(this.actors.splice(r,1),e.push(t))}for(;e.length>0;){let t=-1;for(let r=0;r<e.length;r++){let n=!0;for(const t of this.dependencyLinks.get(e[r]))if(this.actors.indexOf(t)<0&&e.indexOf(t)>=0){n=!1;break}if(n){t=r;break}}if(t<0)throw new Error("Cyclic dependency links detected in bus "+this.name);const r=e.splice(t,1)[0];this.actors.push(r)}}}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});class n{static getLevelOrdinal(e){return n.LEVELS[e]}}n.LEVELS={trace:0,debug:1,info:2,warn:3,error:4,fatal:5},t.Logger=n,t.KEY_CONTEXT_LOG="@comunica/core:log"},function(e,t,r){"use strict";(function(t){r(3);const n=r(146),i=r(340);e.exports=r(147),e.exports.toNodeReadable=function(t){if(t instanceof e.exports.ReadableStream||t&&"function"==typeof t.getReader)return i.readable.webToNode(t);throw new TypeError("Expected a ReadableStream.")},e.exports.toWebReadableStream=function(e){if(n(e)&&e.readable)return i.readable.nodeToWeb(e);if(Array.isArray(e))return i.readable.arrayToWeb(e);if(t.isBuffer(e)||"string"==typeof e)return i.readable.arrayToWeb([e]);throw new TypeError("Expected a Node streams.Readable, an Array, Buffer or String.")}}).call(this,r(7).Buffer)},function(e,t){var r={}.toString;e.exports=Array.isArray||function(e){return"[object Array]"==r.call(e)}},function(e,t,r){"use strict";(function(t,n){var i=r(67);e.exports=v;var a,o=r(141);v.ReadableState=b;r(31).EventEmitter;var s=function(e,t){return e.listeners(t).length},c=r(143),u=r(90).Buffer,l=t.Uint8Array||function(){};var f=r(50);f.inherits=r(1);var d=r(330),h=void 0;h=d&&d.debuglog?d.debuglog("stream"):function(){};var p,y=r(331),m=r(144);f.inherits(v,c);var g=["error","close","destroy","pause","resume"];function b(e,t){e=e||{};var n=t instanceof(a=a||r(32));this.objectMode=!!e.objectMode,n&&(this.objectMode=this.objectMode||!!e.readableObjectMode);var i=e.highWaterMark,o=e.readableHighWaterMark,s=this.objectMode?16:16384;this.highWaterMark=i||0===i?i:n&&(o||0===o)?o:s,this.highWaterMark=Math.floor(this.highWaterMark),this.buffer=new y,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.destroyed=!1,this.defaultEncoding=e.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,e.encoding&&(p||(p=r(51).StringDecoder),this.decoder=new p(e.encoding),this.encoding=e.encoding)}function v(e){if(a=a||r(32),!(this instanceof v))return new v(e);this._readableState=new b(e,this),this.readable=!0,e&&("function"==typeof e.read&&(this._read=e.read),"function"==typeof e.destroy&&(this._destroy=e.destroy)),c.call(this)}function _(e,t,r,n,i){var a,o=e._readableState;null===t?(o.reading=!1,function(e,t){if(t.ended)return;if(t.decoder){var r=t.decoder.end();r&&r.length&&(t.buffer.push(r),t.length+=t.objectMode?1:r.length)}t.ended=!0,x(e)}(e,o)):(i||(a=function(e,t){var r;n=t,u.isBuffer(n)||n instanceof l||"string"==typeof t||void 0===t||e.objectMode||(r=new TypeError("Invalid non-string/buffer chunk"));var n;return r}(o,t)),a?e.emit("error",a):o.objectMode||t&&t.length>0?("string"==typeof t||o.objectMode||Object.getPrototypeOf(t)===u.prototype||(t=function(e){return u.from(e)}(t)),n?o.endEmitted?e.emit("error",new Error("stream.unshift() after end event")):w(e,o,t,!0):o.ended?e.emit("error",new Error("stream.push() after EOF")):(o.reading=!1,o.decoder&&!r?(t=o.decoder.write(t),o.objectMode||0!==t.length?w(e,o,t,!1):O(e,o)):w(e,o,t,!1))):n||(o.reading=!1));return function(e){return!e.ended&&(e.needReadable||e.length<e.highWaterMark||0===e.length)}(o)}function w(e,t,r,n){t.flowing&&0===t.length&&!t.sync?(e.emit("data",r),e.read(0)):(t.length+=t.objectMode?1:r.length,n?t.buffer.unshift(r):t.buffer.push(r),t.needReadable&&x(e)),O(e,t)}Object.defineProperty(v.prototype,"destroyed",{get:function(){return void 0!==this._readableState&&this._readableState.destroyed},set:function(e){this._readableState&&(this._readableState.destroyed=e)}}),v.prototype.destroy=m.destroy,v.prototype._undestroy=m.undestroy,v.prototype._destroy=function(e,t){this.push(null),t(e)},v.prototype.push=function(e,t){var r,n=this._readableState;return n.objectMode?r=!0:"string"==typeof e&&((t=t||n.defaultEncoding)!==n.encoding&&(e=u.from(e,t),t=""),r=!0),_(this,e,t,!1,r)},v.prototype.unshift=function(e){return _(this,e,null,!0,!1)},v.prototype.isPaused=function(){return!1===this._readableState.flowing},v.prototype.setEncoding=function(e){return p||(p=r(51).StringDecoder),this._readableState.decoder=new p(e),this._readableState.encoding=e,this};var S=8388608;function E(e,t){return e<=0||0===t.length&&t.ended?0:t.objectMode?1:e!=e?t.flowing&&t.length?t.buffer.head.data.length:t.length:(e>t.highWaterMark&&(t.highWaterMark=function(e){return e>=S?e=S:(e--,e|=e>>>1,e|=e>>>2,e|=e>>>4,e|=e>>>8,e|=e>>>16,e++),e}(e)),e<=t.length?e:t.ended?t.length:(t.needReadable=!0,0))}function x(e){var t=e._readableState;t.needReadable=!1,t.emittedReadable||(h("emitReadable",t.flowing),t.emittedReadable=!0,t.sync?i.nextTick(T,e):T(e))}function T(e){h("emit readable"),e.emit("readable"),R(e)}function O(e,t){t.readingMore||(t.readingMore=!0,i.nextTick(A,e,t))}function A(e,t){for(var r=t.length;!t.reading&&!t.flowing&&!t.ended&&t.length<t.highWaterMark&&(h("maybeReadMore read 0"),e.read(0),r!==t.length);)r=t.length;t.readingMore=!1}function I(e){h("readable nexttick read 0"),e.read(0)}function N(e,t){t.reading||(h("resume read 0"),e.read(0)),t.resumeScheduled=!1,t.awaitDrain=0,e.emit("resume"),R(e),t.flowing&&!t.reading&&e.read(0)}function R(e){var t=e._readableState;for(h("flow",t.flowing);t.flowing&&null!==e.read(););}function k(e,t){return 0===t.length?null:(t.objectMode?r=t.buffer.shift():!e||e>=t.length?(r=t.decoder?t.buffer.join(""):1===t.buffer.length?t.buffer.head.data:t.buffer.concat(t.length),t.buffer.clear()):r=function(e,t,r){var n;e<t.head.data.length?(n=t.head.data.slice(0,e),t.head.data=t.head.data.slice(e)):n=e===t.head.data.length?t.shift():r?function(e,t){var r=t.head,n=1,i=r.data;e-=i.length;for(;r=r.next;){var a=r.data,o=e>a.length?a.length:e;if(o===a.length?i+=a:i+=a.slice(0,e),0===(e-=o)){o===a.length?(++n,r.next?t.head=r.next:t.head=t.tail=null):(t.head=r,r.data=a.slice(o));break}++n}return t.length-=n,i}(e,t):function(e,t){var r=u.allocUnsafe(e),n=t.head,i=1;n.data.copy(r),e-=n.data.length;for(;n=n.next;){var a=n.data,o=e>a.length?a.length:e;if(a.copy(r,r.length-e,0,o),0===(e-=o)){o===a.length?(++i,n.next?t.head=n.next:t.head=t.tail=null):(t.head=n,n.data=a.slice(o));break}++i}return t.length-=i,r}(e,t);return n}(e,t.buffer,t.decoder),r);var r}function P(e){var t=e._readableState;if(t.length>0)throw new Error('"endReadable()" called on non-empty stream');t.endEmitted||(t.ended=!0,i.nextTick(j,t,e))}function j(e,t){e.endEmitted||0!==e.length||(e.endEmitted=!0,t.readable=!1,t.emit("end"))}function D(e,t){for(var r=0,n=e.length;r<n;r++)if(e[r]===t)return r;return-1}v.prototype.read=function(e){h("read",e),e=parseInt(e,10);var t=this._readableState,r=e;if(0!==e&&(t.emittedReadable=!1),0===e&&t.needReadable&&(t.length>=t.highWaterMark||t.ended))return h("read: emitReadable",t.length,t.ended),0===t.length&&t.ended?P(this):x(this),null;if(0===(e=E(e,t))&&t.ended)return 0===t.length&&P(this),null;var n,i=t.needReadable;return h("need readable",i),(0===t.length||t.length-e<t.highWaterMark)&&h("length less than watermark",i=!0),t.ended||t.reading?h("reading or ended",i=!1):i&&(h("do read"),t.reading=!0,t.sync=!0,0===t.length&&(t.needReadable=!0),this._read(t.highWaterMark),t.sync=!1,t.reading||(e=E(r,t))),null===(n=e>0?k(e,t):null)?(t.needReadable=!0,e=0):t.length-=e,0===t.length&&(t.ended||(t.needReadable=!0),r!==e&&t.ended&&P(this)),null!==n&&this.emit("data",n),n},v.prototype._read=function(e){this.emit("error",new Error("_read() is not implemented"))},v.prototype.pipe=function(e,t){var r=this,a=this._readableState;switch(a.pipesCount){case 0:a.pipes=e;break;case 1:a.pipes=[a.pipes,e];break;default:a.pipes.push(e)}a.pipesCount+=1,h("pipe count=%d opts=%j",a.pipesCount,t);var c=(!t||!1!==t.end)&&e!==n.stdout&&e!==n.stderr?l:v;function u(t,n){h("onunpipe"),t===r&&n&&!1===n.hasUnpiped&&(n.hasUnpiped=!0,h("cleanup"),e.removeListener("close",g),e.removeListener("finish",b),e.removeListener("drain",f),e.removeListener("error",m),e.removeListener("unpipe",u),r.removeListener("end",l),r.removeListener("end",v),r.removeListener("data",y),d=!0,!a.awaitDrain||e._writableState&&!e._writableState.needDrain||f())}function l(){h("onend"),e.end()}a.endEmitted?i.nextTick(c):r.once("end",c),e.on("unpipe",u);var f=function(e){return function(){var t=e._readableState;h("pipeOnDrain",t.awaitDrain),t.awaitDrain&&t.awaitDrain--,0===t.awaitDrain&&s(e,"data")&&(t.flowing=!0,R(e))}}(r);e.on("drain",f);var d=!1;var p=!1;function y(t){h("ondata"),p=!1,!1!==e.write(t)||p||((1===a.pipesCount&&a.pipes===e||a.pipesCount>1&&-1!==D(a.pipes,e))&&!d&&(h("false write response, pause",r._readableState.awaitDrain),r._readableState.awaitDrain++,p=!0),r.pause())}function m(t){h("onerror",t),v(),e.removeListener("error",m),0===s(e,"error")&&e.emit("error",t)}function g(){e.removeListener("finish",b),v()}function b(){h("onfinish"),e.removeListener("close",g),v()}function v(){h("unpipe"),r.unpipe(e)}return r.on("data",y),function(e,t,r){if("function"==typeof e.prependListener)return e.prependListener(t,r);e._events&&e._events[t]?o(e._events[t])?e._events[t].unshift(r):e._events[t]=[r,e._events[t]]:e.on(t,r)}(e,"error",m),e.once("close",g),e.once("finish",b),e.emit("pipe",r),a.flowing||(h("pipe resume"),r.resume()),e},v.prototype.unpipe=function(e){var t=this._readableState,r={hasUnpiped:!1};if(0===t.pipesCount)return this;if(1===t.pipesCount)return e&&e!==t.pipes?this:(e||(e=t.pipes),t.pipes=null,t.pipesCount=0,t.flowing=!1,e&&e.emit("unpipe",this,r),this);if(!e){var n=t.pipes,i=t.pipesCount;t.pipes=null,t.pipesCount=0,t.flowing=!1;for(var a=0;a<i;a++)n[a].emit("unpipe",this,r);return this}var o=D(t.pipes,e);return-1===o?this:(t.pipes.splice(o,1),t.pipesCount-=1,1===t.pipesCount&&(t.pipes=t.pipes[0]),e.emit("unpipe",this,r),this)},v.prototype.on=function(e,t){var r=c.prototype.on.call(this,e,t);if("data"===e)!1!==this._readableState.flowing&&this.resume();else if("readable"===e){var n=this._readableState;n.endEmitted||n.readableListening||(n.readableListening=n.needReadable=!0,n.emittedReadable=!1,n.reading?n.length&&x(this):i.nextTick(I,this))}return r},v.prototype.addListener=v.prototype.on,v.prototype.resume=function(){var e=this._readableState;return e.flowing||(h("resume"),e.flowing=!0,function(e,t){t.resumeScheduled||(t.resumeScheduled=!0,i.nextTick(N,e,t))}(this,e)),this},v.prototype.pause=function(){return h("call pause flowing=%j",this._readableState.flowing),!1!==this._readableState.flowing&&(h("pause"),this._readableState.flowing=!1,this.emit("pause")),this},v.prototype.wrap=function(e){var t=this,r=this._readableState,n=!1;for(var i in e.on("end",function(){if(h("wrapped end"),r.decoder&&!r.ended){var e=r.decoder.end();e&&e.length&&t.push(e)}t.push(null)}),e.on("data",function(i){(h("wrapped data"),r.decoder&&(i=r.decoder.write(i)),r.objectMode&&null==i)||(r.objectMode||i&&i.length)&&(t.push(i)||(n=!0,e.pause()))}),e)void 0===this[i]&&"function"==typeof e[i]&&(this[i]=function(t){return function(){return e[t].apply(e,arguments)}}(i));for(var a=0;a<g.length;a++)e.on(g[a],this.emit.bind(this,g[a]));return this._read=function(t){h("wrapped _read",t),n&&(n=!1,e.resume())},this},Object.defineProperty(v.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}}),v._fromList=k}).call(this,r(9),r(13))},function(e,t,r){e.exports=r(31).EventEmitter},function(e,t,r){"use strict";var n=r(67);function i(e,t){e.emit("error",t)}e.exports={destroy:function(e,t){var r=this,a=this._readableState&&this._readableState.destroyed,o=this._writableState&&this._writableState.destroyed;return a||o?(t?t(e):!e||this._writableState&&this._writableState.errorEmitted||n.nextTick(i,this,e),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(e||null,function(e){!t&&e?(n.nextTick(i,r,e),r._writableState&&(r._writableState.errorEmitted=!0)):t&&t(e)}),this)},undestroy:function(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}}},function(e,t,r){"use strict";e.exports=o;var n=r(32),i=r(50);function a(e,t){var r=this._transformState;r.transforming=!1;var n=r.writecb;if(!n)return this.emit("error",new Error("write callback called multiple times"));r.writechunk=null,r.writecb=null,null!=t&&this.push(t),n(e);var i=this._readableState;i.reading=!1,(i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}function o(e){if(!(this instanceof o))return new o(e);n.call(this,e),this._transformState={afterTransform:a.bind(this),needTransform:!1,transforming:!1,writecb:null,writechunk:null,writeencoding:null},this._readableState.needReadable=!0,this._readableState.sync=!1,e&&("function"==typeof e.transform&&(this._transform=e.transform),"function"==typeof e.flush&&(this._flush=e.flush)),this.on("prefinish",s)}function s(){var e=this;"function"==typeof this._flush?this._flush(function(t,r){c(e,t,r)}):c(this,null,null)}function c(e,t,r){if(t)return e.emit("error",t);if(null!=r&&e.push(r),e._writableState.length)throw new Error("Calling transform done when ws.length != 0");if(e._transformState.transforming)throw new Error("Calling transform done when still transforming");return e.push(null)}i.inherits=r(1),i.inherits(o,n),o.prototype.push=function(e,t){return this._transformState.needTransform=!1,n.prototype.push.call(this,e,t)},o.prototype._transform=function(e,t,r){throw new Error("_transform() is not implemented")},o.prototype._write=function(e,t,r){var n=this._transformState;if(n.writecb=r,n.writechunk=e,n.writeencoding=t,!n.transforming){var i=this._readableState;(n.needTransform||i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}},o.prototype._read=function(e){var t=this._transformState;null!==t.writechunk&&t.writecb&&!t.transforming?(t.transforming=!0,this._transform(t.writechunk,t.writeencoding,t.afterTransform)):t.needTransform=!0},o.prototype._destroy=function(e,t){var r=this;n.prototype._destroy.call(this,e,function(e){t(e),r.emit("close")})}},function(e,t,r){"use strict";var n=e.exports=function(e){return null!==e&&"object"==typeof e&&"function"==typeof e.pipe};n.writable=function(e){return n(e)&&!1!==e.writable&&"function"==typeof e._write&&"object"==typeof e._writableState},n.readable=function(e){return n(e)&&!1!==e.readable&&"function"==typeof e._read&&"object"==typeof e._readableState},n.duplex=function(e){return n.writable(e)&&n.readable(e)},n.transform=function(e){return n.duplex(e)&&"function"==typeof e._transform&&"object"==typeof e._transformState}},function(e,t,r){(function(t){var r;e.exports=function e(t,n,i){function a(s,c){if(!n[s]){if(!t[s]){if(!c&&"function"==typeof r&&r)return r(s,!0);if(o)return o(s,!0);var u=new Error("Cannot find module '"+s+"'");throw u.code="MODULE_NOT_FOUND",u}var l=n[s]={exports:{}};t[s][0].call(l.exports,function(e){var r=t[s][1][e];return a(r||e)},l,l.exports,e,t,n,i)}return n[s].exports}for(var o="function"==typeof r&&r,s=0;s<i.length;s++)a(i[s]);return a}({1:[function(e,t,r){"use strict";Object.defineProperty(r,"__esModule",{value:!0});var n=e("./spec/reference-implementation/lib/readable-stream").ReadableStream,i=e("./spec/reference-implementation/lib/writable-stream").WritableStream,a=e("./spec/reference-implementation/lib/byte-length-queuing-strategy"),o=e("./spec/reference-implementation/lib/count-queuing-strategy"),s=e("./spec/reference-implementation/lib/transform-stream");r.ByteLengthQueuingStrategy=a,r.CountQueuingStrategy=o,r.TransformStream=s,r.ReadableStream=n,r.WritableStream=i;var c={ReadableStream:n,WritableStream:i,ByteLengthQueuingStrategy:a,CountQueuingStrategy:o,TransformStream:s};r.default=c,"undefined"!=typeof window&&Object.assign(window,c)},{"./spec/reference-implementation/lib/byte-length-queuing-strategy":7,"./spec/reference-implementation/lib/count-queuing-strategy":8,"./spec/reference-implementation/lib/readable-stream":11,"./spec/reference-implementation/lib/transform-stream":12,"./spec/reference-implementation/lib/writable-stream":14}],2:[function(e,t,r){function n(e,t){return f.isUndefined(t)?""+t:f.isNumber(t)&&!isFinite(t)?t.toString():f.isFunction(t)||f.isRegExp(t)?t.toString():t}function i(e,t){return f.isString(e)?e.length<t?e:e.slice(0,t):e}function a(e,t,r,n,i){throw new p.AssertionError({message:r,actual:e,expected:t,operator:n,stackStartFunction:i})}function o(e,t){e||a(e,!0,t,"==",p.ok)}function s(e,t){if(e===t)return!0;if(f.isBuffer(e)&&f.isBuffer(t)){if(e.length!=t.length)return!1;for(var r=0;r<e.length;r++)if(e[r]!==t[r])return!1;return!0}return f.isDate(e)&&f.isDate(t)?e.getTime()===t.getTime():f.isRegExp(e)&&f.isRegExp(t)?e.source===t.source&&e.global===t.global&&e.multiline===t.multiline&&e.lastIndex===t.lastIndex&&e.ignoreCase===t.ignoreCase:f.isObject(e)||f.isObject(t)?function(e,t){if(f.isNullOrUndefined(e)||f.isNullOrUndefined(t))return!1;if(e.prototype!==t.prototype)return!1;if(f.isPrimitive(e)||f.isPrimitive(t))return e===t;var r=c(e),n=c(t);if(r&&!n||!r&&n)return!1;if(r)return e=d.call(e),t=d.call(t),s(e,t);var i,a,o=y(e),u=y(t);if(o.length!=u.length)return!1;for(o.sort(),u.sort(),a=o.length-1;a>=0;a--)if(o[a]!=u[a])return!1;for(a=o.length-1;a>=0;a--)if(i=o[a],!s(e[i],t[i]))return!1;return!0}(e,t):e==t}function c(e){return"[object Arguments]"==Object.prototype.toString.call(e)}function u(e,t){return!(!e||!t)&&("[object RegExp]"==Object.prototype.toString.call(t)?t.test(e):e instanceof t||!0===t.call({},e))}function l(e,t,r,n){var i;f.isString(r)&&(n=r,r=null);try{t()}catch(e){i=e}if(n=(r&&r.name?" ("+r.name+").":".")+(n?" "+n:"."),e&&!i&&a(i,r,"Missing expected exception"+n),!e&&u(i,r)&&a(i,r,"Got unwanted exception"+n),e&&i&&r&&!u(i,r)||!e&&i)throw i}var f=e("util/"),d=Array.prototype.slice,h=Object.prototype.hasOwnProperty,p=t.exports=o;p.AssertionError=function(e){this.name="AssertionError",this.actual=e.actual,this.expected=e.expected,this.operator=e.operator,e.message?(this.message=e.message,this.generatedMessage=!1):(this.message=function(e){return i(JSON.stringify(e.actual,n),128)+" "+e.operator+" "+i(JSON.stringify(e.expected,n),128)}(this),this.generatedMessage=!0);var t=e.stackStartFunction||a;if(Error.captureStackTrace)Error.captureStackTrace(this,t);else{var r=new Error;if(r.stack){var o=r.stack,s=t.name,c=o.indexOf("\n"+s);if(c>=0){var u=o.indexOf("\n",c+1);o=o.substring(u+1)}this.stack=o}}},f.inherits(p.AssertionError,Error),p.fail=a,p.ok=o,p.equal=function(e,t,r){e!=t&&a(e,t,r,"==",p.equal)},p.notEqual=function(e,t,r){e==t&&a(e,t,r,"!=",p.notEqual)},p.deepEqual=function(e,t,r){s(e,t)||a(e,t,r,"deepEqual",p.deepEqual)},p.notDeepEqual=function(e,t,r){s(e,t)&&a(e,t,r,"notDeepEqual",p.notDeepEqual)},p.strictEqual=function(e,t,r){e!==t&&a(e,t,r,"===",p.strictEqual)},p.notStrictEqual=function(e,t,r){e===t&&a(e,t,r,"!==",p.notStrictEqual)},p.throws=function(e,t,r){l.apply(this,[!0].concat(d.call(arguments)))},p.doesNotThrow=function(e,t){l.apply(this,[!1].concat(d.call(arguments)))},p.ifError=function(e){if(e)throw e};var y=Object.keys||function(e){var t=[];for(var r in e)h.call(e,r)&&t.push(r);return t}},{"util/":6}],3:[function(e,t,r){"function"==typeof Object.create?t.exports=function(e,t){e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}})}:t.exports=function(e,t){e.super_=t;var r=function(){};r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e}},{}],4:[function(e,t,r){function n(){d&&l&&(d=!1,l.length?f=l.concat(f):h=-1,f.length&&i())}function i(){if(!d){var e=s(n);d=!0;for(var t=f.length;t;){for(l=f,f=[];++h<t;)l&&l[h].run();h=-1,t=f.length}l=null,d=!1,c(e)}}function a(e,t){this.fun=e,this.array=t}function o(){}var s,c,u=t.exports={};!function(){try{s=setTimeout}catch(e){s=function(){throw new Error("setTimeout is not defined")}}try{c=clearTimeout}catch(e){c=function(){throw new Error("clearTimeout is not defined")}}}();var l,f=[],d=!1,h=-1;u.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var r=1;r<arguments.length;r++)t[r-1]=arguments[r];f.push(new a(e,t)),1!==f.length||d||s(i,0)},a.prototype.run=function(){this.fun.apply(null,this.array)},u.title="browser",u.browser=!0,u.env={},u.argv=[],u.version="",u.versions={},u.on=o,u.addListener=o,u.once=o,u.off=o,u.removeListener=o,u.removeAllListeners=o,u.emit=o,u.binding=function(e){throw new Error("process.binding is not supported")},u.cwd=function(){return"/"},u.chdir=function(e){throw new Error("process.chdir is not supported")},u.umask=function(){return 0}},{}],5:[function(e,t,r){t.exports=function(e){return e&&"object"==typeof e&&"function"==typeof e.copy&&"function"==typeof e.fill&&"function"==typeof e.readUInt8}},{}],6:[function(e,r,n){(function(t,r){function i(e,t){var r={seen:[],stylize:o};return arguments.length>=3&&(r.depth=arguments[2]),arguments.length>=4&&(r.colors=arguments[3]),f(t)?r.showHidden=t:t&&n._extend(r,t),y(r.showHidden)&&(r.showHidden=!1),y(r.depth)&&(r.depth=2),y(r.colors)&&(r.colors=!1),y(r.customInspect)&&(r.customInspect=!0),r.colors&&(r.stylize=a),s(r,e,r.depth)}function a(e,t){var r=i.styles[t];return r?"["+i.colors[r][0]+"m"+e+"["+i.colors[r][1]+"m":e}function o(e,t){return e}function s(e,t,r){if(e.customInspect&&t&&_(t.inspect)&&t.inspect!==n.inspect&&(!t.constructor||t.constructor.prototype!==t)){var i=t.inspect(r,e);return p(i)||(i=s(e,i,r)),i}var a=function(e,t){if(y(t))return e.stylize("undefined","undefined");if(p(t)){var r="'"+JSON.stringify(t).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return e.stylize(r,"string")}return h(t)?e.stylize(""+t,"number"):f(t)?e.stylize(""+t,"boolean"):d(t)?e.stylize("null","null"):void 0}(e,t);if(a)return a;var o=Object.keys(t),g=function(e){var t={};return e.forEach(function(e,r){t[e]=!0}),t}(o);if(e.showHidden&&(o=Object.getOwnPropertyNames(t)),v(t)&&(o.indexOf("message")>=0||o.indexOf("description")>=0))return c(t);if(0===o.length){if(_(t)){var w=t.name?": "+t.name:"";return e.stylize("[Function"+w+"]","special")}if(m(t))return e.stylize(RegExp.prototype.toString.call(t),"regexp");if(b(t))return e.stylize(Date.prototype.toString.call(t),"date");if(v(t))return c(t)}var S,E="",T=!1,O=["{","}"];return l(t)&&(T=!0,O=["[","]"]),_(t)&&(E=" [Function"+(t.name?": "+t.name:"")+"]"),m(t)&&(E=" "+RegExp.prototype.toString.call(t)),b(t)&&(E=" "+Date.prototype.toUTCString.call(t)),v(t)&&(E=" "+c(t)),0!==o.length||T&&0!=t.length?r<0?m(t)?e.stylize(RegExp.prototype.toString.call(t),"regexp"):e.stylize("[Object]","special"):(e.seen.push(t),S=T?function(e,t,r,n,i){for(var a=[],o=0,s=t.length;o<s;++o)x(t,String(o))?a.push(u(e,t,r,n,String(o),!0)):a.push("");return i.forEach(function(i){i.match(/^\d+$/)||a.push(u(e,t,r,n,i,!0))}),a}(e,t,r,g,o):o.map(function(n){return u(e,t,r,g,n,T)}),e.seen.pop(),function(e,t,r){return e.reduce(function(e,t){return t.indexOf("\n"),e+t.replace(/\u001b\[\d\d?m/g,"").length+1},0)>60?r[0]+(""===t?"":t+"\n ")+" "+e.join(",\n ")+" "+r[1]:r[0]+t+" "+e.join(", ")+" "+r[1]}(S,E,O)):O[0]+E+O[1]}function c(e){return"["+Error.prototype.toString.call(e)+"]"}function u(e,t,r,n,i,a){var o,c,u;if((u=Object.getOwnPropertyDescriptor(t,i)||{value:t[i]}).get?c=u.set?e.stylize("[Getter/Setter]","special"):e.stylize("[Getter]","special"):u.set&&(c=e.stylize("[Setter]","special")),x(n,i)||(o="["+i+"]"),c||(e.seen.indexOf(u.value)<0?(c=d(r)?s(e,u.value,null):s(e,u.value,r-1)).indexOf("\n")>-1&&(c=a?c.split("\n").map(function(e){return" "+e}).join("\n").substr(2):"\n"+c.split("\n").map(function(e){return" "+e}).join("\n")):c=e.stylize("[Circular]","special")),y(o)){if(a&&i.match(/^\d+$/))return c;(o=JSON.stringify(""+i)).match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)?(o=o.substr(1,o.length-2),o=e.stylize(o,"name")):(o=o.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),o=e.stylize(o,"string"))}return o+": "+c}function l(e){return Array.isArray(e)}function f(e){return"boolean"==typeof e}function d(e){return null===e}function h(e){return"number"==typeof e}function p(e){return"string"==typeof e}function y(e){return void 0===e}function m(e){return g(e)&&"[object RegExp]"===w(e)}function g(e){return"object"==typeof e&&null!==e}function b(e){return g(e)&&"[object Date]"===w(e)}function v(e){return g(e)&&("[object Error]"===w(e)||e instanceof Error)}function _(e){return"function"==typeof e}function w(e){return Object.prototype.toString.call(e)}function S(e){return e<10?"0"+e.toString(10):e.toString(10)}function E(){var e=new Date,t=[S(e.getHours()),S(e.getMinutes()),S(e.getSeconds())].join(":");return[e.getDate(),I[e.getMonth()],t].join(" ")}function x(e,t){return Object.prototype.hasOwnProperty.call(e,t)}var T=/%[sdj%]/g;n.format=function(e){if(!p(e)){for(var t=[],r=0;r<arguments.length;r++)t.push(i(arguments[r]));return t.join(" ")}r=1;for(var n=arguments,a=n.length,o=String(e).replace(T,function(e){if("%%"===e)return"%";if(r>=a)return e;switch(e){case"%s":return String(n[r++]);case"%d":return Number(n[r++]);case"%j":try{return JSON.stringify(n[r++])}catch(e){return"[Circular]"}default:return e}}),s=n[r];r<a;s=n[++r])o+=d(s)||!g(s)?" "+s:" "+i(s);return o},n.deprecate=function(e,i){if(y(r.process))return function(){return n.deprecate(e,i).apply(this,arguments)};if(!0===t.noDeprecation)return e;var a=!1;return function(){if(!a){if(t.throwDeprecation)throw new Error(i);t.traceDeprecation?console.trace(i):console.error(i),a=!0}return e.apply(this,arguments)}};var O,A={};n.debuglog=function(e){if(y(O)&&(O=t.env.NODE_DEBUG||""),e=e.toUpperCase(),!A[e])if(new RegExp("\\b"+e+"\\b","i").test(O)){var r=t.pid;A[e]=function(){var t=n.format.apply(n,arguments);console.error("%s %d: %s",e,r,t)}}else A[e]=function(){};return A[e]},n.inspect=i,i.colors={bold:[1,22],italic:[3,23],underline:[4,24],inverse:[7,27],white:[37,39],grey:[90,39],black:[30,39],blue:[34,39],cyan:[36,39],green:[32,39],magenta:[35,39],red:[31,39],yellow:[33,39]},i.styles={special:"cyan",number:"yellow",boolean:"yellow",undefined:"grey",null:"bold",string:"green",date:"magenta",regexp:"red"},n.isArray=l,n.isBoolean=f,n.isNull=d,n.isNullOrUndefined=function(e){return null==e},n.isNumber=h,n.isString=p,n.isSymbol=function(e){return"symbol"==typeof e},n.isUndefined=y,n.isRegExp=m,n.isObject=g,n.isDate=b,n.isError=v,n.isFunction=_,n.isPrimitive=function(e){return null===e||"boolean"==typeof e||"number"==typeof e||"string"==typeof e||"symbol"==typeof e||void 0===e},n.isBuffer=e("./support/isBuffer");var I=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];n.log=function(){console.log("%s - %s",E(),n.format.apply(n,arguments))},n.inherits=e("inherits"),n._extend=function(e,t){if(!t||!g(t))return e;for(var r=Object.keys(t),n=r.length;n--;)e[r[n]]=t[r[n]];return e}}).call(this,e("_process"),void 0!==t?t:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"./support/isBuffer":5,_process:4,inherits:3}],7:[function(e,t,r){"use strict";var n=function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}(),i=e("./helpers.js").createDataProperty;t.exports=function(){function e(t){var r=t.highWaterMark;(function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")})(this,e),i(this,"highWaterMark",r)}return n(e,[{key:"size",value:function(e){return e.byteLength}}]),e}()},{"./helpers.js":9}],8:[function(e,t,r){"use strict";var n=function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}(),i=e("./helpers.js").createDataProperty;t.exports=function(){function e(t){var r=t.highWaterMark;(function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")})(this,e),i(this,"highWaterMark",r)}return n(e,[{key:"size",value:function(e){return 1}}]),e}()},{"./helpers.js":9}],9:[function(e,t,r){"use strict";var n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol?"symbol":typeof e},i=e("assert");r.promiseCall=function(e){for(var t=arguments.length,r=Array(t>1?t-1:0),n=1;n<t;n++)r[n-1]=arguments[n];try{return Promise.resolve(e.apply(void 0,r))}catch(e){return Promise.reject(e)}},r.typeIsObject=function(e){return"object"===(void 0===e?"undefined":n(e))&&null!==e||"function"==typeof e},r.toInteger=function(e){return e=Number(e),isNaN(e)?0:e<0?-1*Math.floor(Math.abs(e)):Math.floor(Math.abs(e))},r.createDataProperty=function(e,t,n){i(r.typeIsObject(e)),e[t]=n},r.createArrayFromList=function(e){return e.slice()},r.ArrayBufferCopy=function(e,t,r,n,i){new Uint8Array(e).set(new Uint8Array(r,n,i),t)},r.CreateIterResultObject=function(e,t){return i("boolean"==typeof t),{value:e,done:t}},r.IsFiniteNonNegativeNumber=function(e){return!(Number.isNaN(e)||e===1/0||e<0)},r.InvokeOrNoop=function(e,t,r){var n=e[t];if(void 0!==n)return n.apply(e,r)},r.PromiseInvokeOrNoop=function(e,t,r){var n=void 0;try{return void 0===(n=e[t])?Promise.resolve(void 0):Promise.resolve(n.apply(e,r))}catch(e){return Promise.reject(e)}},r.PromiseInvokeOrFallbackOrNoop=function(e,t,n,i,a){var o=void 0;try{o=e[t]}catch(e){return Promise.reject(e)}if(void 0===o)return r.PromiseInvokeOrNoop(e,i,a);try{return Promise.resolve(o.apply(e,n))}catch(e){return Promise.reject(e)}},r.SameRealmTransfer=function(e){return e},r.ValidateAndNormalizeHighWaterMark=function(e){if(e=Number(e),Number.isNaN(e)||e<0)throw new RangeError("highWaterMark property of a queuing strategy must be nonnegative and non-NaN");return e},r.ValidateAndNormalizeQueuingStrategy=function(e,t){if(void 0!==e&&"function"!=typeof e)throw new TypeError("size property of a queuing strategy must be a function");return{size:e,highWaterMark:t=r.ValidateAndNormalizeHighWaterMark(t)}}},{assert:2}],10:[function(e,t,r){"use strict";var n=e("assert"),i=e("./helpers.js").IsFiniteNonNegativeNumber;r.DequeueValue=function(e){return n(e.length>0,"Spec-level failure: should never dequeue from an empty queue."),e.shift().value},r.EnqueueValueWithSize=function(e,t,r){if(r=Number(r),!i(r))throw new RangeError("Size must be a finite, non-NaN, non-negative number.");e.push({value:t,size:r})},r.GetTotalQueueSize=function(e){var t=0;return e.forEach(function(e){n("number"==typeof e.size&&!Number.isNaN(e.size)&&e.size!==1/0&&e.size!==-1/0,"Spec-level failure: should never find an invalid size in the queue."),t+=e.size}),t},r.PeekQueueValue=function(e){return n(e.length>0,"Spec-level failure: should never peek at an empty queue."),e[0].value}},{"./helpers.js":9,assert:2}],11:[function(e,t,r){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e){return new ve(e)}function a(e){return new be(e)}function o(e){return!!ue(e)&&!!Object.prototype.hasOwnProperty.call(e,"_readableStreamController")}function s(e){return Y(!0===o(e),"IsReadableStreamLocked should only be used on known readable streams"),void 0!==e._reader}function c(e,t){Y(!0===o(e)),Y("boolean"==typeof t);var r=a(e),n={closedOrErrored:!1,canceled1:!1,canceled2:!1,reason1:void 0,reason2:void 0};n.promise=new Promise(function(e){return n._resolve=e});var i=function e(){var t=e._branch1,r=e._branch2,n=e._teeState;return T(e._reader).then(function(e){Y(ue(e));var i=e.value,a=e.done;Y("boolean"==typeof a),!0===a&&!1===n.closedOrErrored&&(!1===n.canceled1&&I(t),!1===n.canceled2&&I(r),n.closedOrErrored=!0),!0!==n.closedOrErrored&&(!1===n.canceled1&&N(t,i),!1===n.canceled2&&N(r,i))})};i._reader=r,i._teeState=n,i._shouldClone=t;var s=function e(t){var r=e._stream,n=e._teeState;if(n.canceled1=!0,n.reason1=t,!0===n.canceled2){var i=f(r,se([n.reason1,n.reason2]));n._resolve(i)}return n.promise};s._stream=e,s._teeState=n;var c=function e(t){var r=e._stream,n=e._teeState;if(n.canceled2=!0,n.reason2=t,!0===n.canceled1){var i=f(r,se([n.reason1,n.reason2]));n._resolve(i)}return n.promise};c._stream=e,c._teeState=n;var u=Object.create(Object.prototype);ce(u,"pull",i),ce(u,"cancel",s);var l=new ge(u),d=Object.create(Object.prototype);ce(d,"pull",i),ce(d,"cancel",c);var h=new ge(d);return i._branch1=l._readableStreamController,i._branch2=h._readableStreamController,r._closedPromise.catch(function(e){!0!==n.closedOrErrored&&(R(i._branch1,e),R(i._branch2,e),n.closedOrErrored=!0)}),[l,h]}function u(e){return Y(!0===v(e._reader)),Y("readable"===e._state||"closed"===e._state),new Promise(function(t,r){var n={_resolve:t,_reject:r};e._reader._readIntoRequests.push(n)})}function l(e){return Y(!0===_(e._reader)),Y("readable"===e._state),new Promise(function(t,r){var n={_resolve:t,_reject:r};e._reader._readRequests.push(n)})}function f(e,t){return e._disturbed=!0,"closed"===e._state?Promise.resolve(void 0):"errored"===e._state?Promise.reject(e._storedError):(d(e),e._readableStreamController[ye](t).then(function(){}))}function d(e){Y("readable"===e._state),e._state="closed";var t=e._reader;if(void 0!==t){if(!0===_(t)){var r=!0,n=!1,i=void 0;try{for(var a,o=t._readRequests[Symbol.iterator]();!(r=(a=o.next()).done);r=!0)(0,a.value._resolve)(Z(void 0,!0))}catch(e){n=!0,i=e}finally{try{!r&&o.return&&o.return()}finally{if(n)throw i}}t._readRequests=[]}t._closedPromise_resolve(void 0),t._closedPromise_resolve=void 0,t._closedPromise_reject=void 0}}function h(e,t){Y(!0===o(e),"stream must be ReadableStream"),Y("readable"===e._state,"state must be readable"),e._state="errored",e._storedError=t;var r=e._reader;if(void 0!==r){if(!0===_(r)){var n=!0,i=!1,a=void 0;try{for(var s,c=r._readRequests[Symbol.iterator]();!(n=(s=c.next()).done);n=!0)s.value._reject(t)}catch(e){i=!0,a=e}finally{try{!n&&c.return&&c.return()}finally{if(i)throw a}}r._readRequests=[]}else{Y(v(r),"reader must be ReadableStreamBYOBReader");var u=!0,l=!1,f=void 0;try{for(var d,h=r._readIntoRequests[Symbol.iterator]();!(u=(d=h.next()).done);u=!0)d.value._reject(t)}catch(e){l=!0,f=e}finally{try{!u&&h.return&&h.return()}finally{if(l)throw f}}r._readIntoRequests=[]}r._closedPromise_reject(t),r._closedPromise_resolve=void 0,r._closedPromise_reject=void 0}}function p(e,t,r){var n=e._reader;Y(n._readRequests.length>0),n._readRequests.shift()._resolve(Z(t,r))}function y(e){return e._reader._readIntoRequests.length}function m(e){return e._reader._readRequests.length}function g(e){var t=e._reader;return void 0!==t&&!1!==v(t)}function b(e){var t=e._reader;return void 0!==t&&!1!==_(t)}function v(e){return!!ue(e)&&!!Object.prototype.hasOwnProperty.call(e,"_readIntoRequests")}function _(e){return!!ue(e)&&!!Object.prototype.hasOwnProperty.call(e,"_readRequests")}function w(e,t){e._ownerReadableStream=t,t._reader=e,"readable"===t._state?e._closedPromise=new Promise(function(t,r){e._closedPromise_resolve=t,e._closedPromise_reject=r}):"closed"===t._state?(e._closedPromise=Promise.resolve(void 0),e._closedPromise_resolve=void 0,e._closedPromise_reject=void 0):(Y("errored"===t._state,"state must be errored"),e._closedPromise=Promise.reject(t._storedError),e._closedPromise_resolve=void 0,e._closedPromise_reject=void 0)}function S(e,t){var r=e._ownerReadableStream;return Y(void 0!==r),f(r,t)}function E(e){Y(void 0!==e._ownerReadableStream),Y(e._ownerReadableStream._reader===e),"readable"===e._ownerReadableStream._state?e._closedPromise_reject(new TypeError("Reader was released and can no longer be used to monitor the stream's closedness")):e._closedPromise=Promise.reject(new TypeError("Reader was released and can no longer be used to monitor the stream's closedness")),e._ownerReadableStream._reader=void 0,e._ownerReadableStream=void 0}function x(e,t){var r=e._ownerReadableStream;return Y(void 0!==r),r._disturbed=!0,"errored"===r._state?Promise.reject(r._storedError):function(e,t){var r=e._controlledReadableStream,n=1;t.constructor!==DataView&&(n=t.constructor.BYTES_PER_ELEMENT);var i=t.constructor,a={buffer:t.buffer,byteOffset:t.byteOffset,byteLength:t.byteLength,bytesFilled:0,elementSize:n,ctor:i,readerType:"byob"};if(e._pendingPullIntos.length>0)return a.buffer=ne(a.buffer),e._pendingPullIntos.push(a),u(r);if("closed"===r._state){var o=new t.constructor(t.buffer,t.byteOffset,0);return Promise.resolve(Z(o,!0))}if(e._totalQueuedBytes>0){if(!0===F(e,a)){var s=L(a);return U(e),Promise.resolve(Z(s,!1))}if(!0===e._closeRequested){var c=new TypeError("Insufficient bytes to fill elements in the given buffer");return Q(e,c),Promise.reject(c)}}a.buffer=ne(a.buffer),e._pendingPullIntos.push(a);var l=u(r);return D(e),l}(r._readableStreamController,t)}function T(e){var t=e._ownerReadableStream;return Y(void 0!==t),t._disturbed=!0,"closed"===t._state?Promise.resolve(Z(void 0,!0)):"errored"===t._state?Promise.reject(t._storedError):(Y("readable"===t._state),t._readableStreamController[me]())}function O(e){return!!ue(e)&&!!Object.prototype.hasOwnProperty.call(e,"_underlyingSource")}function A(e){if(!1!==function(e){var t=e._controlledReadableStream;return"closed"!==t._state&&"errored"!==t._state&&!0!==e._closeRequested&&!1!==e._started&&(!0===s(t)&&m(t)>0||k(e)>0)}(e)){if(!0===e._pulling)return void(e._pullAgain=!0);e._pulling=!0,re(e._underlyingSource,"pull",[e]).then(function(){if(e._pulling=!1,!0===e._pullAgain)return e._pullAgain=!1,A(e)},function(t){if("readable"===e._controlledReadableStream._state)return R(e,t)}).catch(le)}}function I(e){var t=e._controlledReadableStream;Y(!1===e._closeRequested),Y("readable"===t._state),e._closeRequested=!0,0===e._queue.length&&d(t)}function N(e,t){var r=e._controlledReadableStream;if(Y(!1===e._closeRequested),Y("readable"===r._state),!0===s(r)&&m(r)>0)p(r,t,!1);else{var n=1;if(void 0!==e._strategySize)try{n=e._strategySize(t)}catch(t){throw"readable"===r._state&&R(e,t),t}try{he(e._queue,t,n)}catch(t){throw"readable"===r._state&&R(e,t),t}}A(e)}function R(e,t){var r=e._controlledReadableStream;Y("readable"===r._state),e._queue=[],h(r,t)}function k(e){var t=pe(e._queue);return e._strategyHWM-t}function P(e){return!!ue(e)&&!!Object.prototype.hasOwnProperty.call(e,"_underlyingByteSource")}function j(e){return!!ue(e)&&!!Object.prototype.hasOwnProperty.call(e,"_associatedReadableByteStreamController")}function D(e){if(!1!==function(e){var t=e._controlledReadableStream;return"readable"===t._state&&!0!==e._closeRequested&&!1!==e._started&&(!!(b(t)&&m(t)>0)||!!(g(t)&&y(t)>0)||X(e)>0)}(e)){if(!0===e._pulling)return void(e._pullAgain=!0);e._pullAgain=!1,e._pulling=!0,re(e._underlyingByteSource,"pull",[e]).then(function(){e._pulling=!1,!0===e._pullAgain&&(e._pullAgain=!1,D(e))},function(t){"readable"===e._controlledReadableStream._state&&Q(e,t)}).catch(le)}}function C(e){V(e),e._pendingPullIntos=[]}function M(e,t){Y("errored"!==e._state,"state must not be errored");var r=!1;"closed"===e._state&&(Y(0===t.bytesFilled),r=!0);var n=L(t);"default"===t.readerType?p(e,n,r):(Y("byob"===t.readerType),function(e,t,r){var n=e._reader;Y(n._readIntoRequests.length>0),n._readIntoRequests.shift()._resolve(Z(t,r))}(e,n,r))}function L(e){var t=e.bytesFilled,r=e.elementSize;return Y(t<=e.byteLength),Y(t%r==0),new e.ctor(e.buffer,e.byteOffset,t/r)}function q(e,t,r,n){e._queue.push({buffer:t,byteOffset:r,byteLength:n}),e._totalQueuedBytes+=n}function F(e,t){var r=t.elementSize,n=t.bytesFilled-t.bytesFilled%r,i=Math.min(e._totalQueuedBytes,t.byteLength-t.bytesFilled),a=t.bytesFilled+i,o=a-a%r,s=i,c=!1;o>n&&(s=o-t.bytesFilled,c=!0);for(var u=e._queue;s>0;){var l=u[0],f=Math.min(s,l.byteLength),d=t.byteOffset+t.bytesFilled;W(t.buffer,d,l.buffer,l.byteOffset,f),l.byteLength===f?u.shift():(l.byteOffset+=f,l.byteLength-=f),e._totalQueuedBytes-=f,B(e,f,t),s-=f}return!1===c&&(Y(0===e._totalQueuedBytes,"queue must be empty"),Y(t.bytesFilled>0),Y(t.bytesFilled<t.elementSize)),c}function B(e,t,r){Y(0===e._pendingPullIntos.length||e._pendingPullIntos[0]===r),V(e),r.bytesFilled+=t}function U(e){Y("readable"===e._controlledReadableStream._state),0===e._totalQueuedBytes&&!0===e._closeRequested?d(e._controlledReadableStream):D(e)}function V(e){void 0!==e._byobRequest&&(e._byobRequest._associatedReadableByteStreamController=void 0,e._byobRequest._view=void 0,e._byobRequest=void 0)}function H(e){for(Y(!1===e._closeRequested);e._pendingPullIntos.length>0;){if(0===e._totalQueuedBytes)return;var t=e._pendingPullIntos[0];!0===F(e,t)&&(G(e),M(e._controlledReadableStream,t))}}function z(e,t){var r=e._pendingPullIntos[0],n=e._controlledReadableStream;if("closed"===n._state){if(0!==t)throw new TypeError("bytesWritten must be 0 when calling respond() on a closed stream");!function(e,t){t.buffer=ne(t.buffer),Y(0===t.bytesFilled,"bytesFilled must be 0");for(var r=e._controlledReadableStream;y(r)>0;)M(r,G(e))}(e,r)}else Y("readable"===n._state),function(e,t,r){if(r.bytesFilled+t>r.byteLength)throw new RangeError("bytesWritten out of range");if(B(e,t,r),!(r.bytesFilled<r.elementSize)){G(e);var n=r.bytesFilled%r.elementSize;if(n>0){var i=r.byteOffset+r.bytesFilled,a=r.buffer.slice(i-n,i);q(e,a,0,a.byteLength)}r.buffer=ne(r.buffer),r.bytesFilled-=n,M(e._controlledReadableStream,r),H(e)}}(e,t,r)}function G(e){var t=e._pendingPullIntos.shift();return V(e),t}function Q(e,t){var r=e._controlledReadableStream;Y("readable"===r._state),C(e),e._queue=[],h(r,t)}function X(e){return e._strategyHWM-e._totalQueuedBytes}var $=function(e,t){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return function(e,t){var r=[],n=!0,i=!1,a=void 0;try{for(var o,s=e[Symbol.iterator]();!(n=(o=s.next()).done)&&(r.push(o.value),!t||r.length!==t);n=!0);}catch(e){i=!0,a=e}finally{try{!n&&s.return&&s.return()}finally{if(i)throw a}}return r}(e,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")},J=function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}(),Y=e("assert"),K=e("./helpers.js"),W=K.ArrayBufferCopy,Z=K.CreateIterResultObject,ee=K.IsFiniteNonNegativeNumber,te=K.InvokeOrNoop,re=K.PromiseInvokeOrNoop,ne=K.SameRealmTransfer,ie=K.ValidateAndNormalizeQueuingStrategy,ae=K.ValidateAndNormalizeHighWaterMark,oe=e("./helpers.js"),se=oe.createArrayFromList,ce=oe.createDataProperty,ue=oe.typeIsObject,le=e("./utils.js").rethrowAssertionErrorRejection,fe=e("./queue-with-sizes.js"),de=fe.DequeueValue,he=fe.EnqueueValueWithSize,pe=fe.GetTotalQueueSize,ye=Symbol("[[Cancel]]"),me=Symbol("[[Pull]]"),ge=function(){function e(){var t=arguments.length<=0||void 0===arguments[0]?{}:arguments[0],r=arguments.length<=1||void 0===arguments[1]?{}:arguments[1],i=r.size,a=r.highWaterMark;n(this,e),this._state="readable",this._reader=void 0,this._storedError=void 0,this._disturbed=!1,this._readableStreamController=void 0;var o=t.type;if("bytes"===String(o))void 0===a&&(a=0),this._readableStreamController=new Se(this,t,a);else{if(void 0!==o)throw new RangeError("Invalid type is specified");void 0===a&&(a=1),this._readableStreamController=new _e(this,t,i,a)}}return J(e,[{key:"cancel",value:function(e){return!1===o(this)?Promise.reject(new TypeError("ReadableStream.prototype.cancel can only be used on a ReadableStream")):!0===s(this)?Promise.reject(new TypeError("Cannot cancel a stream that already has a reader")):f(this,e)}},{key:"getReader",value:function(){var e=arguments.length<=0||void 0===arguments[0]?{}:arguments[0],t=e.mode;if(!1===o(this))throw new TypeError("ReadableStream.prototype.getReader can only be used on a ReadableStream");if("byob"===t){if(!1===P(this._readableStreamController))throw new TypeError("Cannot get a ReadableStreamBYOBReader for a stream not constructed with a byte source");return i(this)}if(void 0===t)return a(this);throw new RangeError("Invalid mode is specified")}},{key:"pipeThrough",value:function(e,t){var r=e.writable,n=e.readable;return this.pipeTo(r,t),n}},{key:"pipeTo",value:function(e){function t(){f=l.read(),Promise.all([f,e.ready]).then(function(r){var i=$(r,1)[0],a=i.value,o=i.done;!0===Boolean(o)?n():"writable"===e.state&&(d=e.write(a),t())}).catch(le)}function r(e){!1===c?(l.cancel(e),l.releaseLock(),y(e)):f.then(function(){l.releaseLock(),y(e)})}function n(){l.releaseLock();var t=e.state;!1!==o||"waiting"!==t&&"writable"!==t?void 0!==d?d.then(p,y):p():(h=!0,e.close().then(p,y))}function i(t){l.releaseLock(),!1===s&&e.abort(t),y(t)}var a=arguments.length<=1||void 0===arguments[1]?{}:arguments[1],o=a.preventClose,s=a.preventAbort,c=a.preventCancel;o=Boolean(o),s=Boolean(s),c=Boolean(c);var u=this,l=void 0,f=void 0,d=void 0,h=!1,p=void 0,y=void 0;return new Promise(function(n,a){p=n,y=a,(l=u.getReader()).closed.catch(i),e.closed.then(function(){h||r(new TypeError("destination is closing or closed and cannot be piped to anymore"))},r),t()})}},{key:"tee",value:function(){if(!1===o(this))throw new TypeError("ReadableStream.prototype.tee can only be used on a ReadableStream");var e=c(this,!1);return se(e)}},{key:"locked",get:function(){if(!1===o(this))throw new TypeError("ReadableStream.prototype.locked can only be used on a ReadableStream");return s(this)}}]),e}();r.ReadableStream=ge,r.IsReadableStreamDisturbed=function(e){return Y(!0===o(e),"IsReadableStreamDisturbed should only be used on known readable streams"),e._disturbed};var be=function(){function e(t){if(n(this,e),!1===o(t))throw new TypeError("ReadableStreamDefaultReader can only be constructed with a ReadableStream instance");if(!0===s(t))throw new TypeError("This stream has already been locked for exclusive reading by another reader");w(this,t),this._readRequests=[]}return J(e,[{key:"cancel",value:function(e){return!1===_(this)?Promise.reject(new TypeError("ReadableStreamDefaultReader.prototype.cancel can only be used on a ReadableStreamDefaultReader")):void 0===this._ownerReadableStream?Promise.reject(new TypeError("Cannot cancel a stream using a released reader")):S(this,e)}},{key:"read",value:function(){return!1===_(this)?Promise.reject(new TypeError("ReadableStreamDefaultReader.prototype.read can only be used on a ReadableStreamDefaultReader")):void 0===this._ownerReadableStream?Promise.reject(new TypeError("Cannot read from a released reader")):T(this)}},{key:"releaseLock",value:function(){if(!1===_(this))throw new TypeError("ReadableStreamDefaultReader.prototype.releaseLock can only be used on a ReadableStreamDefaultReader");if(void 0!==this._ownerReadableStream){if(this._readRequests.length>0)throw new TypeError("Tried to release a reader lock when that reader has pending read() calls un-settled");E(this)}}},{key:"closed",get:function(){return!1===_(this)?Promise.reject(new TypeError("ReadableStreamDefaultReader.prototype.closed can only be used on a ReadableStreamDefaultReader")):this._closedPromise}}]),e}(),ve=function(){function e(t){if(n(this,e),!o(t))throw new TypeError("ReadableStreamBYOBReader can only be constructed with a ReadableStream instance given a byte source");if(s(t))throw new TypeError("This stream has already been locked for exclusive reading by another reader");w(this,t),this._readIntoRequests=[]}return J(e,[{key:"cancel",value:function(e){return v(this)?void 0===this._ownerReadableStream?Promise.reject(new TypeError("Cannot cancel a stream using a released reader")):S(this,e):Promise.reject(new TypeError("ReadableStreamBYOBReader.prototype.cancel can only be used on a ReadableStreamBYOBReader"))}},{key:"read",value:function(e){return v(this)?void 0===this._ownerReadableStream?Promise.reject(new TypeError("Cannot read from a released reader")):ArrayBuffer.isView(e)?0===e.byteLength?Promise.reject(new TypeError("view must have non-zero byteLength")):x(this,e):Promise.reject(new TypeError("view must be an array buffer view")):Promise.reject(new TypeError("ReadableStreamBYOBReader.prototype.read can only be used on a ReadableStreamBYOBReader"))}},{key:"releaseLock",value:function(){if(!v(this))throw new TypeError("ReadableStreamBYOBReader.prototype.releaseLock can only be used on a ReadableStreamBYOBReader");if(void 0!==this._ownerReadableStream){if(this._readIntoRequests.length>0)throw new TypeError("Tried to release a reader lock when that reader has pending read() calls un-settled");E(this)}}},{key:"closed",get:function(){return v(this)?this._closedPromise:Promise.reject(new TypeError("ReadableStreamBYOBReader.prototype.closed can only be used on a ReadableStreamBYOBReader"))}}]),e}(),_e=function(){function e(t,r,i,a){if(n(this,e),!1===o(t))throw new TypeError("ReadableStreamDefaultController can only be constructed with a ReadableStream instance");if(void 0!==t._readableStreamController)throw new TypeError("ReadableStreamDefaultController instances can only be created by the ReadableStream constructor");this._controlledReadableStream=t,this._underlyingSource=r,this._queue=[],this._started=!1,this._closeRequested=!1,this._pullAgain=!1,this._pulling=!1;var s=ie(i,a);this._strategySize=s.size,this._strategyHWM=s.highWaterMark;var c=this,u=te(r,"start",[this]);Promise.resolve(u).then(function(){c._started=!0,A(c)},function(e){"readable"===t._state&&R(c,e)}).catch(le)}return J(e,[{key:"close",value:function(){if(!1===O(this))throw new TypeError("ReadableStreamDefaultController.prototype.close can only be used on a ReadableStreamDefaultController");if(!0===this._closeRequested)throw new TypeError("The stream has already been closed; do not close it again!");var e=this._controlledReadableStream._state;if("readable"!==e)throw new TypeError("The stream (in "+e+" state) is not in the readable state and cannot be closed");I(this)}},{key:"enqueue",value:function(e){if(!1===O(this))throw new TypeError("ReadableStreamDefaultController.prototype.enqueue can only be used on a ReadableStreamDefaultController");if(!0===this._closeRequested)throw new TypeError("stream is closed or draining");var t=this._controlledReadableStream._state;if("readable"!==t)throw new TypeError("The stream (in "+t+" state) is not in the readable state and cannot be enqueued to");return N(this,e)}},{key:"error",value:function(e){if(!1===O(this))throw new TypeError("ReadableStreamDefaultController.prototype.error can only be used on a ReadableStreamDefaultController");var t=this._controlledReadableStream;if("readable"!==t._state)throw new TypeError("The stream is "+t._state+" and so cannot be errored");R(this,e)}},{key:ye,value:function(e){return this._queue=[],re(this._underlyingSource,"cancel",[e])}},{key:me,value:function(){var e=this._controlledReadableStream;if(this._queue.length>0){var t=de(this._queue);return!0===this._closeRequested&&0===this._queue.length?d(e):A(this),Promise.resolve(Z(t,!1))}var r=l(e);return A(this),r}},{key:"desiredSize",get:function(){if(!1===O(this))throw new TypeError("ReadableStreamDefaultController.prototype.desiredSize can only be used on a ReadableStreamDefaultController");return k(this)}}]),e}(),we=function(){function e(t,r){n(this,e),this._associatedReadableByteStreamController=t,this._view=r}return J(e,[{key:"respond",value:function(e){if(!1===j(this))throw new TypeError("ReadableByteStreamController.prototype.respond can only be used on a ReadableByteStreamController");if(void 0===this._associatedReadableByteStreamController)throw new TypeError("This BYOB request has been invalidated");!function(e,t){if(t=Number(t),!1===ee(t))throw new RangeError("bytesWritten must be a finite");Y(e._pendingPullIntos.length>0),z(e,t)}(this._associatedReadableByteStreamController,e)}},{key:"respondWithNewView",value:function(e){if(!1===j(this))throw new TypeError("ReadableByteStreamController.prototype.respond can only be used on a ReadableByteStreamController");if(void 0===this._associatedReadableByteStreamController)throw new TypeError("This BYOB request has been invalidated");if(!ArrayBuffer.isView(e))throw new TypeError("You can only respond with array buffer views");!function(e,t){Y(e._pendingPullIntos.length>0);var r=e._pendingPullIntos[0];if(r.byteOffset+r.bytesFilled!==t.byteOffset)throw new RangeError("The region specified by view does not match byobRequest");if(r.byteLength!==t.byteLength)throw new RangeError("The buffer of view has different capacity than byobRequest");r.buffer=t.buffer,z(e,t.byteLength)}(this._associatedReadableByteStreamController,e)}},{key:"view",get:function(){return this._view}}]),e}(),Se=function(){function e(t,r,i){if(n(this,e),!1===o(t))throw new TypeError("ReadableByteStreamController can only be constructed with a ReadableStream instance given a byte source");if(void 0!==t._readableStreamController)throw new TypeError("ReadableByteStreamController instances can only be created by the ReadableStream constructor given a byte source");this._controlledReadableStream=t,this._underlyingByteSource=r,this._pullAgain=!1,this._pulling=!1,C(this),this._queue=[],this._totalQueuedBytes=0,this._closeRequested=!1,this._started=!1,this._strategyHWM=ae(i);var a=r.autoAllocateChunkSize;if(void 0!==a&&(!1===Number.isInteger(a)||a<0))throw new RangeError("autoAllocateChunkSize must be a non negative integer");this._autoAllocateChunkSize=a,this._pendingPullIntos=[];var s=this,c=te(r,"start",[this]);Promise.resolve(c).then(function(){s._started=!0,Y(!1===s._pulling),Y(!1===s._pullAgain),D(s)},function(e){"readable"===t._state&&Q(s,e)}).catch(le)}return J(e,[{key:"close",value:function(){if(!1===P(this))throw new TypeError("ReadableByteStreamController.prototype.close can only be used on a ReadableByteStreamController");if(!0===this._closeRequested)throw new TypeError("The stream has already been closed; do not close it again!");var e=this._controlledReadableStream._state;if("readable"!==e)throw new TypeError("The stream (in "+e+" state) is not in the readable state and cannot be closed");!function(e){var t=e._controlledReadableStream;if(Y(!1===e._closeRequested),Y("readable"===t._state),e._totalQueuedBytes>0)e._closeRequested=!0;else{if(e._pendingPullIntos.length>0&&e._pendingPullIntos[0].bytesFilled>0){var r=new TypeError("Insufficient bytes to fill elements in the given buffer");throw Q(e,r),r}d(t)}}(this)}},{key:"enqueue",value:function(e){if(!1===P(this))throw new TypeError("ReadableByteStreamController.prototype.enqueue can only be used on a ReadableByteStreamController");if(!0===this._closeRequested)throw new TypeError("stream is closed or draining");var t=this._controlledReadableStream._state;if("readable"!==t)throw new TypeError("The stream (in "+t+" state) is not in the readable state and cannot be enqueued to");if(!ArrayBuffer.isView(e))throw new TypeError("You can only enqueue array buffer views when using a ReadableByteStreamController");!function(e,t){var r=e._controlledReadableStream;Y(!1===e._closeRequested),Y("readable"===r._state);var n=t.buffer,i=t.byteOffset,a=t.byteLength,o=ne(n);!0===b(r)?0===m(r)?q(e,o,i,a):(Y(0===e._queue.length),p(r,new Uint8Array(o,i,a),!1)):!0===g(r)?(q(e,o,i,a),H(e)):(Y(!1===s(r),"stream must not be locked"),q(e,o,i,a))}(this,e)}},{key:"error",value:function(e){if(!1===P(this))throw new TypeError("ReadableByteStreamController.prototype.error can only be used on a ReadableByteStreamController");var t=this._controlledReadableStream;if("readable"!==t._state)throw new TypeError("The stream is "+t._state+" and so cannot be errored");Q(this,e)}},{key:ye,value:function(e){return this._pendingPullIntos.length>0&&(this._pendingPullIntos[0].bytesFilled=0),this._queue=[],this._totalQueuedBytes=0,re(this._underlyingByteSource,"cancel",[e])}},{key:me,value:function(){var e=this._controlledReadableStream;if(0===m(e)){if(this._totalQueuedBytes>0){var t=this._queue.shift();this._totalQueuedBytes-=t.byteLength,U(this);var r=void 0;try{r=new Uint8Array(t.buffer,t.byteOffset,t.byteLength)}catch(e){return Promise.reject(e)}return Promise.resolve(Z(r,!1))}var n=this._autoAllocateChunkSize;if(void 0!==n){var i=void 0;try{i=new ArrayBuffer(n)}catch(e){return Promise.reject(e)}var a={buffer:i,byteOffset:0,byteLength:n,bytesFilled:0,elementSize:1,ctor:Uint8Array,readerType:"default"};this._pendingPullIntos.push(a)}}else Y(void 0===this._autoAllocateChunkSize);var o=l(e);return D(this),o}},{key:"byobRequest",get:function(){if(!1===P(this))throw new TypeError("ReadableByteStreamController.prototype.byobRequest can only be used on a ReadableByteStreamController");if(void 0===this._byobRequest&&this._pendingPullIntos.length>0){var e=this._pendingPullIntos[0],t=new Uint8Array(e.buffer,e.byteOffset+e.bytesFilled,e.byteLength-e.bytesFilled);this._byobRequest=new we(this,t)}return this._byobRequest}},{key:"desiredSize",get:function(){if(!1===P(this))throw new TypeError("ReadableByteStreamController.prototype.desiredSize can only be used on a ReadableByteStreamController");return X(this)}}]),e}()},{"./helpers.js":9,"./queue-with-sizes.js":10,"./utils.js":13,assert:2}],12:[function(e,t,r){"use strict";var n=e("./readable-stream.js").ReadableStream,i=e("./writable-stream.js").WritableStream;t.exports=function e(t){function r(){if(!1===u){u=!0;try{t.transform(o,f,a),o=void 0,l=!1}catch(e){u=!1,c(e),h(e)}}}function a(){u=!1,s()}if(function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),void 0===t.flush&&(t.flush=function(e,t){return t()}),"function"!=typeof t.transform)throw new TypeError("transform must be a function");var o=void 0,s=void 0,c=void 0,u=!1,l=!1;this.writable=new i({start:function(e){c=e},write:function(e){o=e,l=!0;var t=new Promise(function(e){return s=e});return r(),t},close:function(){try{t.flush(f,d)}catch(e){c(e),h(e)}}},t.writableStrategy);var f=void 0,d=void 0,h=void 0;this.readable=new n({start:function(e){f=e.enqueue.bind(e),d=e.close.bind(e),h=e.error.bind(e)},pull:function(){!0===l&&r()}},t.readableStrategy)}},{"./readable-stream.js":11,"./writable-stream.js":14}],13:[function(e,t,r){"use strict";var n=e("assert");r.rethrowAssertionErrorRejection=function(e){e&&e.constructor===n.AssertionError&&setTimeout(function(){throw e},0)}},{assert:2}],14:[function(e,t,r){"use strict";function n(e){return!1===e._started?void e._startedPromise.then(function(){s(e)}).catch(m):!0===e._started?s(e):void 0}function i(e,t){if("closed"!==e._state&&"errored"!==e._state){for(;e._queue.length>0;){var r=b(e._queue);"close"!==r&&r._reject(t)}e._storedError=t,"waiting"===e._state&&e._readyPromise_resolve(void 0),e._closedPromise_reject(t),e._closedPromise_resolve=void 0,e._closedPromise_reject=void 0,e._state="errored"}}function a(e){return!!y(e)&&!!Object.prototype.hasOwnProperty.call(e,"_underlyingSink")}function o(e){if("closing"!==e._state){u("writable"===e._state||"waiting"===e._state,"stream must be in a writable or waiting state while calling SyncWritableStreamStateWithQueue");var t=_(e._queue)>e._strategyHWM;!0===t&&"writable"===e._state&&(e._state="waiting",e._readyPromise=new Promise(function(t,r){e._readyPromise_resolve=t})),!1===t&&"waiting"===e._state&&(e._state="writable",e._readyPromise_resolve(void 0))}}function s(e){if(0!==e._queue.length&&!0!==e._writing){var t=w(e._queue);return"close"===t?(u("closing"===e._state,"can't process final write record unless already closing"),b(e._queue),u(0===e._queue.length,"queue must be empty once the final write record is dequeued"),function(e){u("closing"===e._state,"stream must be in closing state while calling CloseWritableStream"),d(e._underlyingSink,"close").then(function(){"errored"!==e._state&&(u("closing"===e._state),e._closedPromise_resolve(void 0),e._closedPromise_resolve=void 0,e._closedPromise_reject=void 0,e._state="closed")},function(t){return i(e,t)}).catch(m)}(e)):(e._writing=!0,void d(e._underlyingSink,"write",[t.chunk]).then(function(){"errored"!==e._state&&(e._writing=!1,t._resolve(void 0),b(e._queue),o(e),s(e))},function(t){return i(e,t)}).catch(m))}}var c=function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}(),u=e("assert"),l=e("./helpers.js"),f=l.InvokeOrNoop,d=l.PromiseInvokeOrNoop,h=l.PromiseInvokeOrFallbackOrNoop,p=l.ValidateAndNormalizeQueuingStrategy,y=l.typeIsObject,m=e("./utils.js").rethrowAssertionErrorRejection,g=e("./queue-with-sizes.js"),b=g.DequeueValue,v=g.EnqueueValueWithSize,_=g.GetTotalQueueSize,w=g.PeekQueueValue,S=(e("./count-queuing-strategy.js"),function(){function e(){var t=this,r=arguments.length<=0||void 0===arguments[0]?{}:arguments[0],n=arguments.length<=1||void 0===arguments[1]?{}:arguments[1],a=n.size,s=n.highWaterMark,c=void 0===s?0:s;(function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")})(this,e),this._underlyingSink=r,this._closedPromise=new Promise(function(e,r){t._closedPromise_resolve=e,t._closedPromise_reject=r}),this._readyPromise=Promise.resolve(void 0),this._readyPromise_resolve=null,this._queue=[],this._state="writable",this._started=!1,this._writing=!1;var u=p(a,c);this._strategySize=u.size,this._strategyHWM=u.highWaterMark,o(this);var l=function e(t){return i(e._stream,t)};l._stream=this;var d=f(r,"start",[l]);this._startedPromise=Promise.resolve(d),this._startedPromise.then(function(){t._started=!0,t._startedPromise=void 0}),this._startedPromise.catch(function(e){return i(t,e)}).catch(m)}return c(e,[{key:"abort",value:function(e){return a(this)?"closed"===this._state?Promise.resolve(void 0):"errored"===this._state?Promise.reject(this._storedError):(i(this,e),h(this._underlyingSink,"abort",[e],"close",[]).then(function(){})):Promise.reject(new TypeError("WritableStream.prototype.abort can only be used on a WritableStream"))}},{key:"close",value:function(){return a(this)?"closing"===this._state?Promise.reject(new TypeError("cannot close an already-closing stream")):"closed"===this._state?Promise.reject(new TypeError("cannot close an already-closed stream")):"errored"===this._state?Promise.reject(this._storedError):("waiting"===this._state&&this._readyPromise_resolve(void 0),this._state="closing",v(this._queue,"close",0),n(this),this._closedPromise):Promise.reject(new TypeError("WritableStream.prototype.close can only be used on a WritableStream"))}},{key:"write",value:function(e){if(!a(this))return Promise.reject(new TypeError("WritableStream.prototype.write can only be used on a WritableStream"));if("closing"===this._state)return Promise.reject(new TypeError("cannot write while stream is closing"));if("closed"===this._state)return Promise.reject(new TypeError("cannot write after stream is closed"));if("errored"===this._state)return Promise.reject(this._storedError);u("waiting"===this._state||"writable"===this._state);var t=1;if(void 0!==this._strategySize)try{t=this._strategySize(e)}catch(e){return i(this,e),Promise.reject(e)}var r=void 0,s=void 0,c=new Promise(function(e,t){r=e,s=t}),l={promise:c,chunk:e,_resolve:r,_reject:s};try{v(this._queue,l,t)}catch(e){return i(this,e),Promise.reject(e)}return o(this),n(this),c}},{key:"closed",get:function(){return a(this)?this._closedPromise:Promise.reject(new TypeError("WritableStream.prototype.closed can only be used on a WritableStream"))}},{key:"state",get:function(){if(!a(this))throw new TypeError("WritableStream.prototype.state can only be used on a WritableStream");return this._state}},{key:"ready",get:function(){return a(this)?this._readyPromise:Promise.reject(new TypeError("WritableStream.prototype.ready can only be used on a WritableStream"))}}]),e}());r.WritableStream=S,r.IsWritableStream=a},{"./count-queuing-strategy.js":8,"./helpers.js":9,"./queue-with-sizes.js":10,"./utils.js":13,assert:2}]},{},[1])(1)}).call(this,r(9))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(342))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(343))},function(e,t,r){(function(t){var r=200,n="__lodash_hash_undefined__",i=9007199254740991,a="[object Arguments]",o="[object Function]",s="[object GeneratorFunction]",c=/^\[object .+?Constructor\]$/,u="object"==typeof t&&t&&t.Object===Object&&t,l="object"==typeof self&&self&&self.Object===Object&&self,f=u||l||Function("return this")();function d(e,t,r){switch(r.length){case 0:return e.call(t);case 1:return e.call(t,r[0]);case 2:return e.call(t,r[0],r[1]);case 3:return e.call(t,r[0],r[1],r[2])}return e.apply(t,r)}function h(e,t){return!!(e?e.length:0)&&function(e,t,r){if(t!=t)return function(e,t,r,n){var i=e.length,a=r+(n?1:-1);for(;n?a--:++a<i;)if(t(e[a],a,e))return a;return-1}(e,m,r);var n=r-1,i=e.length;for(;++n<i;)if(e[n]===t)return n;return-1}(e,t,0)>-1}function p(e,t,r){for(var n=-1,i=e?e.length:0;++n<i;)if(r(t,e[n]))return!0;return!1}function y(e,t){for(var r=-1,n=t.length,i=e.length;++r<n;)e[i+r]=t[r];return e}function m(e){return e!=e}function g(e,t){return e.has(t)}function b(e){var t=-1,r=Array(e.size);return e.forEach(function(e){r[++t]=e}),r}var v,_=Array.prototype,w=Function.prototype,S=Object.prototype,E=f["__core-js_shared__"],x=(v=/[^.]+$/.exec(E&&E.keys&&E.keys.IE_PROTO||""))?"Symbol(src)_1."+v:"",T=w.toString,O=S.hasOwnProperty,A=S.toString,I=RegExp("^"+T.call(O).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),N=f.Symbol,R=S.propertyIsEnumerable,k=_.splice,P=N?N.isConcatSpreadable:void 0,j=Math.max,D=G(f,"Map"),C=G(f,"Set"),M=G(Object,"create");function L(e){var t=-1,r=e?e.length:0;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}function q(e){var t=-1,r=e?e.length:0;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}function F(e){var t=-1,r=e?e.length:0;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}function B(e){var t=-1,r=e?e.length:0;for(this.__data__=new F;++t<r;)this.add(e[t])}function U(e,t){for(var r,n,i=e.length;i--;)if((r=e[i][0])===(n=t)||r!=r&&n!=n)return i;return-1}function V(e){return!(!ee(e)||(t=e,x&&x in t))&&(Z(e)||function(e){var t=!1;if(null!=e&&"function"!=typeof e.toString)try{t=!!(e+"")}catch(e){}return t}(e)?I:c).test(function(e){if(null!=e){try{return T.call(e)}catch(e){}try{return e+""}catch(e){}}return""}(e));var t}L.prototype.clear=function(){this.__data__=M?M(null):{}},L.prototype.delete=function(e){return this.has(e)&&delete this.__data__[e]},L.prototype.get=function(e){var t=this.__data__;if(M){var r=t[e];return r===n?void 0:r}return O.call(t,e)?t[e]:void 0},L.prototype.has=function(e){var t=this.__data__;return M?void 0!==t[e]:O.call(t,e)},L.prototype.set=function(e,t){return this.__data__[e]=M&&void 0===t?n:t,this},q.prototype.clear=function(){this.__data__=[]},q.prototype.delete=function(e){var t=this.__data__,r=U(t,e);return!(r<0)&&(r==t.length-1?t.pop():k.call(t,r,1),!0)},q.prototype.get=function(e){var t=this.__data__,r=U(t,e);return r<0?void 0:t[r][1]},q.prototype.has=function(e){return U(this.__data__,e)>-1},q.prototype.set=function(e,t){var r=this.__data__,n=U(r,e);return n<0?r.push([e,t]):r[n][1]=t,this},F.prototype.clear=function(){this.__data__={hash:new L,map:new(D||q),string:new L}},F.prototype.delete=function(e){return z(this,e).delete(e)},F.prototype.get=function(e){return z(this,e).get(e)},F.prototype.has=function(e){return z(this,e).has(e)},F.prototype.set=function(e,t){return z(this,e).set(e,t),this},B.prototype.add=B.prototype.push=function(e){return this.__data__.set(e,n),this},B.prototype.has=function(e){return this.__data__.has(e)};var H=C&&1/b(new C([,-0]))[1]==1/0?function(e){return new C(e)}:function(){};function z(e,t){var r,n,i=e.__data__;return("string"==(n=typeof(r=t))||"number"==n||"symbol"==n||"boolean"==n?"__proto__"!==r:null===r)?i["string"==typeof t?"string":"hash"]:i.map}function G(e,t){var r=function(e,t){return null==e?void 0:e[t]}(e,t);return V(r)?r:void 0}function Q(e){return Y(e)||function(e){return W(e)&&O.call(e,"callee")&&(!R.call(e,"callee")||A.call(e)==a)}(e)||!!(P&&e&&e[P])}var X,$,J=(X=function(e){return function(e,t,n){var i=-1,a=h,o=e.length,s=!0,c=[],u=c;if(n)s=!1,a=p;else if(o>=r){var l=t?null:H(e);if(l)return b(l);s=!1,a=g,u=new B}else u=t?[]:c;e:for(;++i<o;){var f=e[i],d=t?t(f):f;if(f=n||0!==f?f:0,s&&d==d){for(var y=u.length;y--;)if(u[y]===d)continue e;t&&u.push(d),c.push(f)}else a(u,d,n)||(u!==c&&u.push(d),c.push(f))}return c}(function e(t,r,n,i,a){var o=-1,s=t.length;for(n||(n=Q),a||(a=[]);++o<s;){var c=t[o];r>0&&n(c)?r>1?e(c,r-1,n,i,a):y(a,c):i||(a[a.length]=c)}return a}(e,1,W,!0))},$=j(void 0===$?X.length-1:$,0),function(){for(var e=arguments,t=-1,r=j(e.length-$,0),n=Array(r);++t<r;)n[t]=e[$+t];t=-1;for(var i=Array($+1);++t<$;)i[t]=e[t];return i[$]=n,d(X,this,i)});var Y=Array.isArray;function K(e){return null!=e&&function(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=i}(e.length)&&!Z(e)}function W(e){return function(e){return!!e&&"object"==typeof e}(e)&&K(e)}function Z(e){var t=ee(e)?A.call(e):"";return t==o||t==s}function ee(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}e.exports=J}).call(this,r(9))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(354))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(0);t.ActorAbstractMediaTyped=class extends n.Actor{constructor(e){super(e)}async run(e){if("handle"in e){const t=e;return{handle:await this.runHandle(t.handle,t.handleMediaType,e.context)}}if("mediaTypes"in e)return{mediaTypes:await this.getMediaTypes(e.context)};throw new Error("Either a handle or mediaType action needs to be provided")}async test(e){if("handle"in e){const t=e;return{handle:await this.testHandle(t.handle,t.handleMediaType,e.context)}}if("mediaTypes"in e)return{mediaTypes:await this.testMediaType(e.context)};throw new Error("Either a handle or mediaType action needs to be provided")}}},function(e,t,r){(function(t,n){var i=r(69).xsd,a=String.fromCharCode,o="function"==typeof t?t:function(e){setTimeout(e,0)},s=/\\u([a-fA-F0-9]{4})|\\U([a-fA-F0-9]{8})|\\[uU]|\\(.)/g,c={"\\":"\\","'":"'",'"':'"',n:"\n",r:"\r",t:"\t",f:"\f",b:"\b",_:"_","~":"~",".":".","-":"-","!":"!",$:"$","&":"&","(":"(",")":")","*":"*","+":"+",",":",",";":";","=":"=","/":"/","?":"?","#":"#","@":"@","%":"%"},u=/[\x00-\x20<>\\"\{\}\|\^\`]/,l={_iri:!0,_unescapedIri:!0,_unescapedQuote:!0,_singleQuote:!0,_langcode:!0,_blank:!0,_newline:!0,_comment:!0,_whitespace:!0,_endOfFile:!0},f=/$0^/;e.exports=class{constructor(e){if(this._iri=/^<((?:[^ <>{}\\]|\\[uU])+)>[ \t]*/,this._unescapedIri=/^<([^\x00-\x20<>\\"\{\}\|\^\`]*)>[ \t]*/,this._unescapedQuote=/^"([^"\\\r\n]+)"/,this._unescapedApos=/^'([^'\\\r\n]+)'/,this._singleQuote=/^"((?:[^"\\\r\n]|\\.)*)"(?=[^"])/,this._singleApos=/^'((?:[^'\\\r\n]|\\.)*)'(?=[^'])/,this._tripleQuote=/^"""([^"\\]*(?:(?:\\.|"(?!""))[^"\\]*)*)"""/,this._tripleApos=/^'''([^'\\]*(?:(?:\\.|'(?!''))[^'\\]*)*)'''/,this._langcode=/^@([a-z]+(?:-[a-z0-9]+)*)(?=[^a-z0-9\-])/i,this._prefix=/^((?:[A-Za-z\xc0-\xd6\xd8-\xf6\xf8-\u02ff\u0370-\u037d\u037f-\u1fff\u200c\u200d\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff])(?:\.?[\-0-9A-Z_a-z\xb7\xc0-\xd6\xd8-\xf6\xf8-\u037d\u037f-\u1fff\u200c\u200d\u203f\u2040\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff])*)?:(?=[#\s<])/,this._prefixed=/^((?:[A-Za-z\xc0-\xd6\xd8-\xf6\xf8-\u02ff\u0370-\u037d\u037f-\u1fff\u200c\u200d\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff])(?:\.?[\-0-9A-Z_a-z\xb7\xc0-\xd6\xd8-\xf6\xf8-\u037d\u037f-\u1fff\u200c\u200d\u203f\u2040\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff])*)?:((?:(?:[0-:A-Z_a-z\xc0-\xd6\xd8-\xf6\xf8-\u02ff\u0370-\u037d\u037f-\u1fff\u200c\u200d\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff]|%[0-9a-fA-F]{2}|\\[!#-\/;=?\-@_~])(?:(?:[\.\-0-:A-Z_a-z\xb7\xc0-\xd6\xd8-\xf6\xf8-\u037d\u037f-\u1fff\u200c\u200d\u203f\u2040\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff]|%[0-9a-fA-F]{2}|\\[!#-\/;=?\-@_~])*(?:[\-0-:A-Z_a-z\xb7\xc0-\xd6\xd8-\xf6\xf8-\u037d\u037f-\u1fff\u200c\u200d\u203f\u2040\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff]|%[0-9a-fA-F]{2}|\\[!#-\/;=?\-@_~]))?)?)(?:[ \t]+|(?=\.?[,;!\^\s#()\[\]\{\}"'<]))/,this._variable=/^\?(?:(?:[A-Z_a-z\xc0-\xd6\xd8-\xf6\xf8-\u02ff\u0370-\u037d\u037f-\u1fff\u200c\u200d\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff])(?:[\-0-:A-Z_a-z\xb7\xc0-\xd6\xd8-\xf6\xf8-\u037d\u037f-\u1fff\u200c\u200d\u203f\u2040\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff])*)(?=[.,;!\^\s#()\[\]\{\}"'<])/,this._blank=/^_:((?:[0-9A-Z_a-z\xc0-\xd6\xd8-\xf6\xf8-\u02ff\u0370-\u037d\u037f-\u1fff\u200c\u200d\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff])(?:\.?[\-0-9A-Z_a-z\xb7\xc0-\xd6\xd8-\xf6\xf8-\u037d\u037f-\u1fff\u200c\u200d\u203f\u2040\u2070-\u218f\u2c00-\u2fef\u3001-\ud7ff\uf900-\ufdcf\ufdf0-\ufffd]|[\ud800-\udb7f][\udc00-\udfff])*)(?:[ \t]+|(?=\.?[,;:\s#()\[\]\{\}"'<]))/,this._number=/^[\-+]?(?:\d+\.?\d*([eE](?:[\-\+])?\d+)|\d*\.?\d+)(?=\.?[,;:\s#()\[\]\{\}"'<])/,this._boolean=/^(?:true|false)(?=[.,;\s#()\[\]\{\}"'<])/,this._keyword=/^@[a-z]+(?=[\s#<:])/i,this._sparqlKeyword=/^(?:PREFIX|BASE|GRAPH)(?=[\s#<])/i,this._shortPredicates=/^a(?=[\s()\[\]\{\}"'<])/,this._newline=/^[ \t]*(?:#[^\n\r]*)?(?:\r\n|\n|\r)[ \t]*/,this._comment=/#([^\n\r]*)/,this._whitespace=/^[ \t]+/,this._endOfFile=/^(?:#[^\n\r]*)?$/,e=e||{},this._lineMode=!!e.lineMode)for(var t in this._n3Mode=!1,this)!(t in l)&&this[t]instanceof RegExp&&(this[t]=f);else this._n3Mode=!1!==e.n3;this._comments=!!e.comments}_tokenizeToEnd(e,t){for(var r=this._input,n=this._comments;;){for(var a,o;a=this._newline.exec(r);)n&&(o=this._comment.exec(a[0]))&&e(null,{line:this._line,type:"comment",value:o[1],prefix:""}),r=r.substr(a[0].length,r.length),this._line++;if((a=this._whitespace.exec(r))&&(r=r.substr(a[0].length,r.length)),this._endOfFile.test(r))return t&&(n&&(o=this._comment.exec(r))&&e(null,{line:this._line,type:"comment",value:o[1],prefix:""}),e(r=null,{line:this._line,type:"eof",value:"",prefix:""})),this._input=r;var s=this._line,c="",l="",f="",d=r[0],h=null,p=0,y=!1;switch(d){case"^":if(r.length<3)break;if("^"!==r[1]){this._n3Mode&&(p=1,c="^");break}if(this._previousMarker="^^","<"!==(r=r.substr(2))[0]){y=!0;break}case"<":if(h=this._unescapedIri.exec(r))c="IRI",l=h[1];else if(h=this._iri.exec(r)){if(null===(l=this._unescape(h[1]))||u.test(l))return g(this);c="IRI"}else this._n3Mode&&r.length>1&&"="===r[1]&&(c="inverse",p=2,l=">");break;case"_":((h=this._blank.exec(r))||t&&(h=this._blank.exec(r+" ")))&&(c="blank",f="_",l=h[1]);break;case'"':if(h=this._unescapedQuote.exec(r))l=h[1];else if(r.indexOf('"',1)>0&&((h=this._singleQuote.exec(r))?l=this._unescape(h[1]):(h=this._tripleQuote.exec(r))&&(l=h[1],this._line+=l.split(/\r\n|\r|\n/).length-1,l=this._unescape(l)),null===l))return g(this);null!==h&&(c="literal");break;case"'":if(h=this._unescapedApos.exec(r))l=h[1];else if(r.indexOf("'",1)>0&&((h=this._singleApos.exec(r))?l=this._unescape(h[1]):(h=this._tripleApos.exec(r))&&(l=h[1],this._line+=l.split(/\r\n|\r|\n/).length-1,l=this._unescape(l)),null===l))return g(this);null!==h&&(c="literal");break;case"?":this._n3Mode&&(h=this._variable.exec(r))&&(c="var",l=h[0]);break;case"@":"literal"===this._previousMarker&&(h=this._langcode.exec(r))?(c="langcode",l=h[1]):(h=this._keyword.exec(r))&&(c=h[0]);break;case".":if(1===r.length?t:r[1]<"0"||r[1]>"9"){c=".",p=1;break}case"0":case"1":case"2":case"3":case"4":case"5":case"6":case"7":case"8":case"9":case"+":case"-":(h=this._number.exec(r)||t&&(h=this._number.exec(r+" ")))&&(c="literal",l=h[0],f=h[1]?i.double:/^[+\-]?\d+$/.test(h[0])?i.integer:i.decimal);break;case"B":case"b":case"p":case"P":case"G":case"g":(h=this._sparqlKeyword.exec(r))?c=h[0].toUpperCase():y=!0;break;case"f":case"t":(h=this._boolean.exec(r))?(c="literal",l=h[0],f=i.boolean):y=!0;break;case"a":(h=this._shortPredicates.exec(r))?(c="abbreviation",l="a"):y=!0;break;case"=":this._n3Mode&&r.length>1&&(c="abbreviation",">"!==r[1]?(p=1,l="="):(p=2,l=">"));break;case"!":if(!this._n3Mode)break;case",":case";":case"[":case"]":case"(":case")":case"{":case"}":this._lineMode||(p=1,c=d);break;default:y=!0}if(y&&("@prefix"!==this._previousMarker&&"PREFIX"!==this._previousMarker||!(h=this._prefix.exec(r))?((h=this._prefixed.exec(r))||t&&(h=this._prefixed.exec(r+" ")))&&(c="prefixed",f=h[1]||"",l=this._unescape(h[2])):(c="prefix",l=h[1]||"")),"^^"===this._previousMarker)switch(c){case"prefixed":c="type";break;case"IRI":c="typeIRI";break;default:c=""}if(!c)return t||!/^'''|^"""/.test(r)&&/\n|\r/.test(r)?g(this):this._input=r;var m={line:s,type:c,value:l,prefix:f};e(null,m),this.previousToken=m,this._previousMarker=c,r=r.substr(p||h[0].length,r.length)}function g(t){e(t._syntaxError(/^\S*/.exec(r)[0]))}}_unescape(e){try{return e.replace(s,function(e,t,r,n){var i;if(t){if(i=parseInt(t,16),isNaN(i))throw new Error;return a(i)}if(r){if(i=parseInt(r,16),isNaN(i))throw new Error;return i<=65535?a(i):a(55296+(i-=65536)/1024,56320+(1023&i))}var o=c[n];if(!o)throw new Error;return o})}catch(e){return null}}_syntaxError(e){this._input=null;var t=new Error('Unexpected "'+e+'" on line '+this._line+".");return t.context={token:void 0,line:this._line,previousToken:this.previousToken},t}tokenize(e,t){var r=this;if(this._line=1,"string"==typeof e){if(this._input=e,"function"!=typeof t){var i,a=[];if(this._tokenizeToEnd(function(e,t){e?i=e:a.push(t)},!0),i)throw i;return a}o(function(){r._tokenizeToEnd(t,!0)})}else this._input="",this._pendingBuffer=null,"function"==typeof e.setEncoding&&e.setEncoding("utf8"),e.on("data",function(e){null!==r._input&&0!==e.length&&(r._pendingBuffer&&(e=n.concat([r._pendingBuffer,e]),r._pendingBuffer=null),128&e[e.length-1]?r._pendingBuffer=e:(r._input+=e,r._tokenizeToEnd(t,!1)))}),e.on("end",function(){null!==r._input&&r._tokenizeToEnd(t,!0)}),e.on("error",t)}}}).call(this,r(15).setImmediate,r(7).Buffer)},function(e,t,r){var n=r(153),i=r(53),a=r(69),o=0,s=0;class c{constructor(e){this._contextStack=[],this._graph=null,e=e||{},this._setBase(e.baseIRI),e.factory&&l(this,e.factory);var t="string"==typeof e.format?e.format.match(/\w*$/)[0].toLowerCase():"",r="turtle"===t,i="trig"===t,a=/triple/.test(t),o=/quad/.test(t),s=this._n3Mode=/n3/.test(t),c=a||o;(this._supportsNamedGraphs=!(r||s))||(this._readPredicateOrNamedGraph=this._readPredicate),this._supportsQuads=!(r||i||a||s),c&&(this._resolveRelativeIRI=function(e){return""}),this._blankNodePrefix="string"!=typeof e.blankNodePrefix?"":e.blankNodePrefix.replace(/^(?!_:)/,"_:"),this._lexer=e.lexer||new n({lineMode:c,n3:s}),this._explicitQuantifiers=!!e.explicitQuantifiers}static _resetBlankNodeIds(){o=s=0}_blank(){return this._blankNode("b"+s++)}_setBase(e){if(e){var t=e.indexOf("#");t>=0&&(e=e.substr(0,t)),this._base=e,this._basePath=e.indexOf("/")<0?e:e.replace(/[^\/?]*(?:\?.*)?$/,""),e=e.match(/^(?:([a-z][a-z0-9+.-]*:))?(?:\/\/[^\/]*)?/i),this._baseRoot=e[0],this._baseScheme=e[1]}else this._base=null}_saveContext(e,t,r,n,i){var a=this._n3Mode;this._contextStack.push({subject:r,predicate:n,object:i,graph:t,type:e,inverse:!!a&&this._inversePredicate,blankPrefix:a?this._prefixes._:"",quantified:a?this._quantified:null}),a&&(this._inversePredicate=!1,this._prefixes._=this._graph?this._graph.id.substr(2)+".":".",this._quantified=Object.create(this._quantified))}_restoreContext(){var e=this._contextStack.pop(),t=this._n3Mode;this._subject=e.subject,this._predicate=e.predicate,this._object=e.object,this._graph=e.graph,t&&(this._inversePredicate=e.inverse,this._prefixes._=e.blankPrefix,this._quantified=e.quantified)}_readInTopContext(e){switch(e.type){case"eof":return null!==this._graph?this._error("Unclosed graph",e):(delete this._prefixes._,this._callback(null,null,this._prefixes));case"PREFIX":this._sparqlStyle=!0;case"@prefix":return this._readPrefix;case"BASE":this._sparqlStyle=!0;case"@base":return this._readBaseIRI;case"{":if(this._supportsNamedGraphs)return this._graph="",this._subject=null,this._readSubject;case"GRAPH":if(this._supportsNamedGraphs)return this._readNamedGraphLabel;default:return this._readSubject(e)}}_readEntity(e,t){var r;switch(e.type){case"IRI":case"typeIRI":var n=this._resolveIRI(e.value);if(""===n)return this._error("Invalid IRI",e);r=this._namedNode(n);break;case"type":case"prefixed":var i=this._prefixes[e.prefix];if(void 0===i)return this._error('Undefined prefix "'+e.prefix+':"',e);r=this._namedNode(i+e.value);break;case"blank":r=this._blankNode(this._prefixes[e.prefix]+e.value);break;case"var":r=this._variable(e.value.substr(1));break;default:return this._error("Expected entity but got "+e.type,e)}return!t&&this._n3Mode&&r.id in this._quantified&&(r=this._quantified[r.id]),r}_readSubject(e){switch(this._predicate=null,e.type){case"[":return this._saveContext("blank",this._graph,this._subject=this._blank(),null,null),this._readBlankNodeHead;case"(":return this._saveContext("list",this._graph,this.RDF_NIL,null,null),this._subject=null,this._readListItem;case"{":return this._n3Mode?(this._saveContext("formula",this._graph,this._graph=this._blank(),null,null),this._readSubject):this._error("Unexpected graph",e);case"}":return this._readPunctuation(e);case"@forSome":return this._n3Mode?(this._subject=null,this._predicate=this.N3_FORSOME,this._quantifier=this._blankNode,this._readQuantifierList):this._error('Unexpected "@forSome"',e);case"@forAll":return this._n3Mode?(this._subject=null,this._predicate=this.N3_FORALL,this._quantifier=this._variable,this._readQuantifierList):this._error('Unexpected "@forAll"',e);default:if(void 0===(this._subject=this._readEntity(e)))return;if(this._n3Mode)return this._getPathReader(this._readPredicateOrNamedGraph)}return this._readPredicateOrNamedGraph}_readPredicate(e){var t=e.type;switch(t){case"inverse":this._inversePredicate=!0;case"abbreviation":this._predicate=this.ABBREVIATIONS[e.value];break;case".":case"]":case"}":return null===this._predicate?this._error("Unexpected "+t,e):(this._subject=null,"]"===t?this._readBlankNodeTail(e):this._readPunctuation(e));case";":return null!==this._predicate?this._readPredicate:this._error("Expected predicate but got ;",e);case"blank":if(!this._n3Mode)return this._error("Disallowed blank node as predicate",e);default:if(void 0===(this._predicate=this._readEntity(e)))return}return this._readObject}_readObject(e){switch(e.type){case"literal":if(0===e.prefix.length)return this._literalValue=e.value,this._readDataTypeOrLang;this._object=this._literal(e.value,this._namedNode(e.prefix));break;case"[":return this._saveContext("blank",this._graph,this._subject,this._predicate,this._subject=this._blank()),this._readBlankNodeHead;case"(":return this._saveContext("list",this._graph,this._subject,this._predicate,this.RDF_NIL),this._subject=null,this._readListItem;case"{":return this._n3Mode?(this._saveContext("formula",this._graph,this._subject,this._predicate,this._graph=this._blank()),this._readSubject):this._error("Unexpected graph",e);default:if(void 0===(this._object=this._readEntity(e)))return;if(this._n3Mode)return this._getPathReader(this._getContextEndReader())}return this._getContextEndReader()}_readPredicateOrNamedGraph(e){return"{"===e.type?this._readGraph(e):this._readPredicate(e)}_readGraph(e){return"{"!==e.type?this._error("Expected graph but got "+e.type,e):(this._graph=this._subject,this._subject=null,this._readSubject)}_readBlankNodeHead(e){return"]"===e.type?(this._subject=null,this._readBlankNodeTail(e)):(this._predicate=null,this._readPredicate(e))}_readBlankNodeTail(e){if("]"!==e.type)return this._readBlankNodePunctuation(e);null!==this._subject&&this._emit(this._subject,this._predicate,this._object,this._graph);var t=null===this._predicate;return this._restoreContext(),null===this._object?t?this._readPredicateOrNamedGraph:this._readPredicateAfterBlank:this._getContextEndReader()}_readPredicateAfterBlank(e){switch(e.type){case".":case"}":return this._subject=null,this._readPunctuation(e);default:return this._readPredicate(e)}}_readListItem(e){var t=null,r=null,n=this._subject,i=this._contextStack,a=i[i.length-1],o=this._readListItem;switch(e.type){case"[":this._saveContext("blank",this._graph,r=this._blank(),this.RDF_FIRST,this._subject=t=this._blank()),o=this._readBlankNodeHead;break;case"(":this._saveContext("list",this._graph,r=this._blank(),this.RDF_FIRST,this.RDF_NIL),this._subject=null;break;case")":if(this._restoreContext(),0!==i.length&&"list"===i[i.length-1].type&&this._emit(this._subject,this._predicate,this._object,this._graph),null===this._predicate){if(o=this._readPredicate,this._subject===this.RDF_NIL)return o}else if(o=this._getContextEndReader(),this._object===this.RDF_NIL)return o;r=this.RDF_NIL;break;case"literal":0===e.prefix.length?(this._literalValue=e.value,o=this._readListItemDataTypeOrLang):(t=this._literal(e.value,this._namedNode(e.prefix)),o=this._getContextEndReader());break;default:if(void 0===(t=this._readEntity(e)))return}if(null===r&&(this._subject=r=this._blank()),null===n?null===a.predicate?a.subject=r:a.object=r:this._emit(n,this.RDF_REST,r,this._graph),null!==t){if(this._n3Mode&&("IRI"===e.type||"prefixed"===e.type))return this._saveContext("item",this._graph,r,this.RDF_FIRST,t),this._subject=t,this._predicate=null,this._getPathReader(this._readListItem);this._emit(r,this.RDF_FIRST,t,this._graph)}return o}_readDataTypeOrLang(e){return this._completeLiteral(e,!1)}_readListItemDataTypeOrLang(e){return this._completeLiteral(e,!0)}_completeLiteral(e,t){switch(e.type){case"type":case"typeIRI":var r=this._readEntity(e);if(void 0===r)return;this._object=this._literal(this._literalValue,r),e=null;break;case"langcode":this._object=this._literal(this._literalValue,e.value),e=null;break;default:this._object=this._literal(this._literalValue)}return t&&this._emit(this._subject,this.RDF_FIRST,this._object,this._graph),null===e?this._getContextEndReader():(this._readCallback=this._getContextEndReader(),this._readCallback(e))}_readFormulaTail(e){return"}"!==e.type?this._readPunctuation(e):(null!==this._subject&&this._emit(this._subject,this._predicate,this._object,this._graph),this._restoreContext(),null===this._object?this._readPredicate:this._getContextEndReader())}_readPunctuation(e){var t,r=this._subject,n=this._graph,i=this._inversePredicate;switch(e.type){case"}":if(null===this._graph)return this._error("Unexpected graph closing",e);if(this._n3Mode)return this._readFormulaTail(e);this._graph=null;case".":this._subject=null,t=this._contextStack.length?this._readSubject:this._readInTopContext,i&&(this._inversePredicate=!1);break;case";":t=this._readPredicate;break;case",":t=this._readObject;break;default:if(this._supportsQuads&&null===this._graph&&void 0!==(n=this._readEntity(e))){t=this._readQuadPunctuation;break}return this._error('Expected punctuation to follow "'+this._object.id+'"',e)}if(null!==r){var a=this._predicate,o=this._object;i?this._emit(o,a,r,n):this._emit(r,a,o,n)}return t}_readBlankNodePunctuation(e){var t;switch(e.type){case";":t=this._readPredicate;break;case",":t=this._readObject;break;default:return this._error('Expected punctuation to follow "'+this._object.id+'"',e)}return this._emit(this._subject,this._predicate,this._object,this._graph),t}_readQuadPunctuation(e){return"."!==e.type?this._error("Expected dot to follow quad",e):this._readInTopContext}_readPrefix(e){return"prefix"!==e.type?this._error("Expected prefix to follow @prefix",e):(this._prefix=e.value,this._readPrefixIRI)}_readPrefixIRI(e){if("IRI"!==e.type)return this._error('Expected IRI to follow prefix "'+this._prefix+':"',e);var t=this._readEntity(e);return this._prefixes[this._prefix]=t.value,this._prefixCallback(this._prefix,t),this._readDeclarationPunctuation}_readBaseIRI(e){var t="IRI"===e.type&&this._resolveIRI(e.value);return t?(this._setBase(t),this._readDeclarationPunctuation):this._error("Expected valid IRI to follow base declaration",e)}_readNamedGraphLabel(e){switch(e.type){case"IRI":case"blank":case"prefixed":return this._readSubject(e),this._readGraph;case"[":return this._readNamedGraphBlankLabel;default:return this._error("Invalid graph label",e)}}_readNamedGraphBlankLabel(e){return"]"!==e.type?this._error("Invalid graph label",e):(this._subject=this._blank(),this._readGraph)}_readDeclarationPunctuation(e){return this._sparqlStyle?(this._sparqlStyle=!1,this._readInTopContext(e)):"."!==e.type?this._error("Expected declaration to end with a dot",e):this._readInTopContext}_readQuantifierList(e){var t;switch(e.type){case"IRI":case"prefixed":if(void 0!==(t=this._readEntity(e,!0)))break;default:return this._error("Unexpected "+e.type,e)}return this._explicitQuantifiers?(null===this._subject?this._emit(this._graph||this.DEFAULTGRAPH,this._predicate,this._subject=this._blank(),this.QUANTIFIERS_GRAPH):this._emit(this._subject,this.RDF_REST,this._subject=this._blank(),this.QUANTIFIERS_GRAPH),this._emit(this._subject,this.RDF_FIRST,t,this.QUANTIFIERS_GRAPH)):this._quantified[t.id]=this._quantifier("b"+s++),this._readQuantifierPunctuation}_readQuantifierPunctuation(e){return","===e.type?this._readQuantifierList:(this._explicitQuantifiers&&(this._emit(this._subject,this.RDF_REST,this.RDF_NIL,this.QUANTIFIERS_GRAPH),this._subject=null),this._readCallback=this._getContextEndReader(),this._readCallback(e))}_getPathReader(e){return this._afterPath=e,this._readPath}_readPath(e){switch(e.type){case"!":return this._readForwardPath;case"^":return this._readBackwardPath;default:var t=this._contextStack,r=t.length&&t[t.length-1];if(r&&"item"===r.type){var n=this._subject;this._restoreContext(),this._emit(this._subject,this.RDF_FIRST,n,this._graph)}return this._afterPath(e)}}_readForwardPath(e){var t,r,n=this._blank();if(void 0!==(r=this._readEntity(e)))return null===this._predicate?(t=this._subject,this._subject=n):(t=this._object,this._object=n),this._emit(t,r,n,this._graph),this._readPath}_readBackwardPath(e){var t,r,n=this._blank();if(void 0!==(t=this._readEntity(e)))return null===this._predicate?(r=this._subject,this._subject=n):(r=this._object,this._object=n),this._emit(n,t,r,this._graph),this._readPath}_getContextEndReader(){var e=this._contextStack;if(!e.length)return this._readPunctuation;switch(e[e.length-1].type){case"blank":return this._readBlankNodeTail;case"list":return this._readListItem;case"formula":return this._readFormulaTail}}_emit(e,t,r,n){this._callback(null,this._quad(e,t,r,n||this.DEFAULTGRAPH))}_error(e,t){var r=new Error(e+" on line "+t.line+".");r.context={token:t,line:t.line,previousToken:this._lexer.previousToken},this._callback(r),this._callback=u}_resolveIRI(e){return/^[a-z][a-z0-9+.-]*:/i.test(e)?e:this._resolveRelativeIRI(e)}_resolveRelativeIRI(e){if(!e.length)return this._base;switch(e[0]){case"#":return this._base+e;case"?":return this._base.replace(/(?:\?.*)?$/,e);case"/":return("/"===e[1]?this._baseScheme:this._baseRoot)+this._removeDotSegments(e);default:return/^[^\/:]*:/.test(e)?"":this._removeDotSegments(this._basePath+e)}}_removeDotSegments(e){if(!/(^|\/)\.\.?($|[\/#?])/.test(e))return e;for(var t="",r=e.length,n=-1,i=-1,a=0,o="/";n<r;){switch(o){case":":if(i<0&&"/"===e[++n]&&"/"===e[++n])for(;(i=n+1)<r&&"/"!==e[i];)n=i;break;case"?":case"#":n=r;break;case"/":if("."===e[n+1])switch(o=e[++n+1]){case"/":t+=e.substring(a,n-1),a=n+1;break;case void 0:case"?":case"#":return t+e.substring(a,n)+e.substr(n+1);case".":if(void 0===(o=e[++n+1])||"/"===o||"?"===o||"#"===o){if((a=(t+=e.substring(a,n-2)).lastIndexOf("/"))>=i&&(t=t.substr(0,a)),"/"!==o)return t+"/"+e.substr(n+1);a=n+1}}}o=e[++n]}return t+e.substring(a)}parse(e,t,r){var n=this;if(this._readCallback=this._readInTopContext,this._sparqlStyle=!1,this._prefixes=Object.create(null),this._prefixes._=this._blankNodePrefix?this._blankNodePrefix.substr(2):"b"+o+++"_",this._prefixCallback=r||u,this._inversePredicate=!1,this._quantified=Object.create(null),!t){var i,a=[];if(this._callback=function(e,t){e?i=e:t&&a.push(t)},this._lexer.tokenize(e).every(function(e){return n._readCallback=n._readCallback(e)}),i)throw i;return a}this._callback=t,this._lexer.tokenize(e,function(e,t){null!==e?(n._callback(e),n._callback=u):n._readCallback&&(n._readCallback=n._readCallback(t))})}}function u(){}function l(e,t){var r=t.namedNode;e._namedNode=r,e._blankNode=t.blankNode,e._literal=t.literal,e._variable=t.variable,e._quad=t.quad,e.DEFAULTGRAPH=t.defaultGraph(),e.RDF_FIRST=r(a.rdf.first),e.RDF_REST=r(a.rdf.rest),e.RDF_NIL=r(a.rdf.nil),e.N3_FORALL=r(a.r.forAll),e.N3_FORSOME=r(a.r.forSome),e.ABBREVIATIONS={a:r(a.rdf.type),"=":r(a.owl.sameAs),">":r(a.log.implies)},e.QUANTIFIERS_GRAPH=r("urn:n3:quantifiers")}l(c.prototype,i),e.exports=c},function(e,t,r){var n=r(69),i=r(53),a=i.defaultGraph(),o=n.rdf,s=n.xsd,c=/["\\\t\n\r\b\f\u0000-\u0019\ud800-\udbff]/,u=/["\\\t\n\r\b\f\u0000-\u0019]|[\ud800-\udbff][\udc00-\udfff]/g,l={"\\":"\\\\",'"':'\\"',"\t":"\\t","\n":"\\n","\r":"\\r","\b":"\\b","\f":"\\f"};class f extends i.internal.Term{equals(){return!1}}function d(e){var t=l[e];return void 0===t&&(1===e.length?(t=e.charCodeAt(0).toString(16),t="\\u0000".substr(0,6-t.length)+t):(t=(1024*(e.charCodeAt(0)-55296)+e.charCodeAt(1)+9216).toString(16),t="\\U00000000".substr(0,10-t.length)+t)),t}e.exports=class{constructor(e,t){if(this._prefixRegex=/$0^/,e&&"function"!=typeof e.write&&(t=e,e=null),t=t||{},e)this._outputStream=e,this._endStream=void 0===t.end||!!t.end;else{var r="";this._outputStream={write(e,t,n){r+=e,n&&n()},end:function(e){e&&e(null,r)}},this._endStream=!0}this._subject=null,/triple|quad/i.test(t.format)?this._writeQuad=this._writeQuadLine:(this._graph=a,this._prefixIRIs=Object.create(null),t.prefixes&&this.addPrefixes(t.prefixes))}get _inDefaultGraph(){return a.equals(this._graph)}_write(e,t){this._outputStream.write(e,"utf8",t)}_writeQuad(e,t,r,n,i){try{n.equals(this._graph)||(this._write((null===this._subject?"":this._inDefaultGraph?".\n":"\n}\n")+(a.equals(n)?"":this._encodeIriOrBlank(n)+" {\n")),this._graph=n,this._subject=null),e.equals(this._subject)?t.equals(this._predicate)?this._write(", "+this._encodeObject(r),i):this._write(";\n "+this._encodePredicate(this._predicate=t)+" "+this._encodeObject(r),i):this._write((null===this._subject?"":".\n")+this._encodeIriOrBlank(this._subject=e)+" "+this._encodePredicate(this._predicate=t)+" "+this._encodeObject(r),i)}catch(e){i&&i(e)}}_writeQuadLine(e,t,r,n,i){delete this._prefixMatch,this._write(this.quadToString(e,t,r,n),i)}quadToString(e,t,r,n){return this._encodeIriOrBlank(e)+" "+this._encodeIriOrBlank(t)+" "+this._encodeObject(r)+(n&&n.value?" "+this._encodeIriOrBlank(n)+" .\n":" .\n")}quadsToString(e){return e.map(function(e){return this.quadToString(e.subject,e.predicate,e.object,e.graph)},this).join("")}_encodeIriOrBlank(e){if("NamedNode"!==e.termType)return"id"in e?e.id:"_:"+e.value;var t=e.value;c.test(t)&&(t=t.replace(u,d));var r=this._prefixRegex.exec(t);return r?r[1]?this._prefixIRIs[r[1]]+r[2]:t:"<"+t+">"}_encodeLiteral(e){var t=e.value;return c.test(t)&&(t=t.replace(u,d)),e.language?'"'+t+'"@'+e.language:e.datatype.value!==s.string?'"'+t+'"^^'+this._encodeIriOrBlank(e.datatype):'"'+t+'"'}_encodePredicate(e){return e.value===o.type?"a":this._encodeIriOrBlank(e)}_encodeObject(e){return"Literal"===e.termType?this._encodeLiteral(e):this._encodeIriOrBlank(e)}_blockedWrite(){throw new Error("Cannot write because the writer has been closed.")}addQuad(e,t,r,n,i){void 0===r?this._writeQuad(e.subject,e.predicate,e.object,e.graph,t):"function"==typeof n?this._writeQuad(e,t,r,a,n):this._writeQuad(e,t,r,n||a,i)}addQuads(e){for(var t=0;t<e.length;t++)this.addQuad(e[t])}addPrefix(e,t,r){var n={};n[e]=t,this.addPrefixes(n,r)}addPrefixes(e,t){var r=this._prefixIRIs,n=!1;for(var i in e){var a=e[i];"string"!=typeof a&&(a=a.value),/[#\/]$/.test(a)&&r[a]!==(i+=":")&&(n=!0,r[a]=i,null!==this._subject&&(this._write(this._inDefaultGraph?".\n":"\n}\n"),this._subject=null,this._graph=""),this._write("@prefix "+i+" <"+a+">.\n"))}if(n){var o="",s="";for(var c in r)o+=o?"|"+c:c,s+=(s?"|":"")+r[c];o=o.replace(/[\]\/\(\)\*\+\?\.\\\$]/g,"\\$&"),this._prefixRegex=new RegExp("^(?:"+s+")[^/]*$|^("+o+")([a-zA-Z][\\-_a-zA-Z0-9]*)$")}this._write(n?"\n":"",t)}blank(e,t){var r,n,i=e;switch(void 0===e?i=[]:e.termType?i=[{predicate:e,object:t}]:"length"in e||(i=[e]),n=i.length){case 0:return new f("[]");case 1:if(!((r=i[0]).object instanceof f))return new f("[ "+this._encodePredicate(r.predicate)+" "+this._encodeObject(r.object)+" ]");default:for(var a="[",o=0;o<n;o++)(r=i[o]).predicate.equals(e)?a+=", "+this._encodeObject(r.object):(a+=(o?";\n ":"\n ")+this._encodePredicate(r.predicate)+" "+this._encodeObject(r.object),e=r.predicate);return new f(a+"\n]")}}list(e){for(var t=e&&e.length||0,r=new Array(t),n=0;n<t;n++)r[n]=this._encodeObject(e[n]);return new f("("+r.join(" ")+")")}end(e){null!==this._subject&&(this._write(this._inDefaultGraph?".\n":"\n}\n"),this._subject=null),this._write=this._blockedWrite;var t=e&&function(r,n){t=null,e(r,n)};if(this._endStream)try{return this._outputStream.end(t)}catch(e){}t&&t()}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(363))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(158),i=r(3),a=r(365),o=r(366),s=r(369),c=r(159),u=r(370),l=r(371),f=r(372),d=r(373),h=r(374),p=r(375),y=r(376),m=r(41);class g extends i.Transform{constructor(e){super({objectMode:!0}),e=e||{},this.options=e,this.parsingContext=new y.ParsingContext(Object.assign({parser:this},e)),this.util=new m.Util({dataFactory:e.dataFactory,parsingContext:this.parsingContext}),this.jsonParser=new n,this.contextAwaitingJobs=[],this.contextJobs=[],this.lastDepth=0,this.lastOnValueJob=Promise.resolve(),this.attachJsonParserListeners()}import(e){const t=new i.PassThrough({objectMode:!0});e.on("error",e=>r.emit("error",e)),e.on("data",e=>t.write(e)),e.on("end",()=>t.emit("end"));const r=t.pipe(new g(this.options));return r}_transform(e,t,r){this.jsonParser.write(e),this.lastOnValueJob.then(()=>r(),e=>r(e))}async newOnValueJob(e,t,r){if(r<this.lastDepth){const t=this.parsingContext.listPointerStack[this.lastDepth];t&&(t.term?this.emit("data",this.util.dataFactory.quad(t.term,this.util.rdfRest,this.util.rdfNil,this.util.getDefaultGraph())):this.parsingContext.getUnidentifiedValueBufferSafe(t.listRootDepth).push({predicate:t.initialPredicate,object:this.util.rdfNil,reverse:!1}),this.parsingContext.listPointerStack.splice(this.lastDepth,1)),await this.flushBuffer(this.lastDepth,e)}const n=await this.util.unaliasKeyword(e[r],e,r),i=await this.util.unaliasKeywordParent(e,r);this.parsingContext.emittedStack[r]=!0;let a=!0;m.Util.isKeyword(n)&&"@reverse"===i&&this.emit("error",new Error(`Found the @id '${t}' inside an @reverse property`));let o=!1;this.parsingContext.validationStack.length>1&&(o=this.parsingContext.validationStack[this.parsingContext.validationStack.length-1].property);for(let t=Math.max(1,this.parsingContext.validationStack.length-1);t<e.length-1;t++){const n=this.parsingContext.validationStack[t]||(this.parsingContext.validationStack[t]=await this.validateKey(e.slice(0,t+1),t,o));if(!n.valid){this.parsingContext.emittedStack[r]=!1,a=!1;break}!o&&n.property&&(o=!0)}if(this.util.isLiteral(r)&&(a=!1),a){for(const i of g.ENTRY_HANDLERS){const a=await i.test(this.parsingContext,this.util,n,e,r);if(a){await i.handle(this.parsingContext,this.util,n,e,t,r,a);break}}this.parsingContext.processingStack[r]=!0}0===r&&Array.isArray(t)&&await this.util.validateValueIndexes(t),r<this.lastDepth&&(this.parsingContext.processingStack.splice(this.lastDepth,1),this.parsingContext.emittedStack.splice(this.lastDepth,1),this.parsingContext.idStack.splice(this.lastDepth,1),this.parsingContext.graphStack.splice(this.lastDepth+1,1),this.parsingContext.literalStack.splice(this.lastDepth,1),this.parsingContext.validationStack.splice(this.lastDepth-1,2)),this.lastDepth=r,this.parsingContext.unaliasedKeywordCacheStack.splice(r-1)}async validateKey(e,t,r){for(const n of g.ENTRY_HANDLERS)if(await n.validate(this.parsingContext,this.util,e,t,r))return{valid:!0,property:r||n.isPropertyHandler()};return{valid:!1,property:!1}}attachJsonParserListeners(){this.jsonParser.onValue=e=>{const t=this.jsonParser.stack.length,r=new Array(t+1).fill(0).map((e,r)=>r===t?this.jsonParser.key:this.jsonParser.stack[r].key);if(!this.isParsingContextInner(t)){const n=()=>this.newOnValueJob(r,e,t);if(this.parsingContext.allowOutOfOrderContext&&!this.parsingContext.contextTree.getContext(r.slice(0,-1)))if("@context"===r[t]){let e=this.contextJobs[t];e||(e=this.contextJobs[t]=[]),e.push(n)}else this.contextAwaitingJobs.push(n);else this.lastOnValueJob=this.lastOnValueJob.then(n);this.parsingContext.allowOutOfOrderContext&&0===t&&(this.lastOnValueJob=this.lastOnValueJob.then(()=>this.executeBufferedJobs()))}},this.jsonParser.onError=e=>{this.emit("error",e)}}isParsingContextInner(e){for(let t=e;t>0;t--)if("@context"===this.jsonParser.stack[t-1].key)return!0;return!1}async executeBufferedJobs(){for(const e of this.contextJobs)if(e)for(const t of e)await t();for(const e of this.contextAwaitingJobs)await e()}async flushBuffer(e,t){let r=this.parsingContext.idStack[e];void 0===r&&(r=this.parsingContext.idStack[e]=this.util.dataFactory.blankNode());const n=this.parsingContext.unidentifiedValuesBuffer[e];if(n){if(r){const i=await this.util.getDepthOffsetGraph(e,t),a=this.parsingContext.graphStack[e]||i>=0?this.parsingContext.idStack[e-i-1]:this.util.getDefaultGraph();if(a){this.parsingContext.emittedStack[e]=!0;for(const t of n)t.reverse?this.parsingContext.emitQuad(e,this.util.dataFactory.quad(t.object,t.predicate,r,a)):this.parsingContext.emitQuad(e,this.util.dataFactory.quad(r,t.predicate,t.object,a))}else{const i=this.parsingContext.getUnidentifiedGraphBufferSafe(e-await this.util.getDepthOffsetGraph(e,t)-1);for(const e of n)e.reverse?i.push({object:r,predicate:e.predicate,subject:e.object}):i.push({object:e.object,predicate:e.predicate,subject:r})}}this.parsingContext.unidentifiedValuesBuffer.splice(e,1),this.parsingContext.literalStack.splice(e,1)}const i=this.parsingContext.unidentifiedGraphsBuffer[e];if(i){if(r){const t=1!==e||"BlankNode"!==r.termType||this.parsingContext.topLevelProperties?r:this.util.getDefaultGraph();this.parsingContext.emittedStack[e]=!0;for(const r of i)this.parsingContext.emitQuad(e,this.util.dataFactory.quad(r.subject,r.predicate,r.object,t))}this.parsingContext.unidentifiedGraphsBuffer.splice(e,1)}}}g.DEFAULT_PROCESSING_MODE="1.0",g.ENTRY_HANDLERS=[new a.EntryHandlerArrayValue,new u.EntryHandlerKeywordContext,new f.EntryHandlerKeywordId,new l.EntryHandlerKeywordGraph,new d.EntryHandlerKeywordType,new p.EntryHandlerKeywordValue,new h.EntryHandlerKeywordUnknownFallback,new o.EntryHandlerContainer,new c.EntryHandlerPredicate,new s.EntryHandlerInvalidFallback],t.JsonLdParser=g},function(e,t,r){(function(t){var r={},n=r.LEFT_BRACE=1,i=r.RIGHT_BRACE=2,a=r.LEFT_BRACKET=3,o=r.RIGHT_BRACKET=4,s=r.COLON=5,c=r.COMMA=6,u=r.TRUE=7,l=r.FALSE=8,f=r.NULL=9,d=r.STRING=10,h=r.NUMBER=11,p=r.START=17,y=r.STOP=18,m=r.TRUE1=33,g=r.TRUE2=34,b=r.TRUE3=35,v=r.FALSE1=49,_=r.FALSE2=50,w=r.FALSE3=51,S=r.FALSE4=52,E=r.NULL1=65,x=r.NULL2=66,T=r.NULL3=67,O=r.NUMBER1=81,A=r.NUMBER3=83,I=r.STRING1=97,N=r.STRING2=98,R=r.STRING3=99,k=r.STRING4=100,P=r.STRING5=101,j=r.STRING6=102,D=r.VALUE=113,C=r.KEY=114,M=r.OBJECT=129,L=r.ARRAY=130,q="\\".charCodeAt(0),F="/".charCodeAt(0),B="\b".charCodeAt(0),U="\f".charCodeAt(0),V="\n".charCodeAt(0),H="\r".charCodeAt(0),z="\t".charCodeAt(0),G=65536;function Q(){this.tState=p,this.value=void 0,this.string=void 0,this.stringBuffer=t.alloc?t.alloc(G):new t(G),this.stringBufferOffset=0,this.unicode=void 0,this.highSurrogate=void 0,this.key=void 0,this.mode=void 0,this.stack=[],this.state=D,this.bytes_remaining=0,this.bytes_in_sequence=0,this.temp_buffs={2:new t(2),3:new t(3),4:new t(4)},this.offset=-1}Q.toknam=function(e){for(var t=Object.keys(r),n=0,i=t.length;n<i;n++){var a=t[n];if(r[a]===e)return a}return e&&"0x"+e.toString(16)};var X=Q.prototype;X.onError=function(e){throw e},X.charError=function(e,t){this.tState=y,this.onError(new Error("Unexpected "+JSON.stringify(String.fromCharCode(e[t]))+" at position "+t+" in state "+Q.toknam(this.tState)))},X.appendStringChar=function(e){this.stringBufferOffset>=G&&(this.string+=this.stringBuffer.toString("utf8"),this.stringBufferOffset=0),this.stringBuffer[this.stringBufferOffset++]=e},X.appendStringBuf=function(e,t,r){var n=e.length;"number"==typeof t&&(n="number"==typeof r?r<0?e.length-t+r:r-t:e.length-t),n<0&&(n=0),this.stringBufferOffset+n>G&&(this.string+=this.stringBuffer.toString("utf8",0,this.stringBufferOffset),this.stringBufferOffset=0),e.copy(this.stringBuffer,this.stringBufferOffset,t,r),this.stringBufferOffset+=n},X.write=function(e){var r;"string"==typeof e&&(e=new t(e));for(var y=0,D=e.length;y<D;y++)if(this.tState===p){if(r=e[y],this.offset++,123===r)this.onToken(n,"{");else if(125===r)this.onToken(i,"}");else if(91===r)this.onToken(a,"[");else if(93===r)this.onToken(o,"]");else if(58===r)this.onToken(s,":");else if(44===r)this.onToken(c,",");else if(116===r)this.tState=m;else if(102===r)this.tState=v;else if(110===r)this.tState=E;else if(34===r)this.string="",this.stringBufferOffset=0,this.tState=I;else if(45===r)this.string="-",this.tState=O;else if(r>=48&&r<64)this.string=String.fromCharCode(r),this.tState=A;else if(32!==r&&9!==r&&10!==r&&13!==r)return this.charError(e,y)}else if(this.tState===I)if(r=e[y],this.bytes_remaining>0){for(var C=0;C<this.bytes_remaining;C++)this.temp_buffs[this.bytes_in_sequence][this.bytes_in_sequence-this.bytes_remaining+C]=e[C];this.appendStringBuf(this.temp_buffs[this.bytes_in_sequence]),this.bytes_in_sequence=this.bytes_remaining=0,y=y+C-1}else if(0===this.bytes_remaining&&r>=128){if(r<=193||r>244)return this.onError(new Error("Invalid UTF-8 character at position "+y+" in state "+Q.toknam(this.tState)));if(r>=194&&r<=223&&(this.bytes_in_sequence=2),r>=224&&r<=239&&(this.bytes_in_sequence=3),r>=240&&r<=244&&(this.bytes_in_sequence=4),this.bytes_in_sequence+y>e.length){for(var M=0;M<=e.length-1-y;M++)this.temp_buffs[this.bytes_in_sequence][M]=e[y+M];this.bytes_remaining=y+this.bytes_in_sequence-e.length,y=e.length-1}else this.appendStringBuf(e,y,y+this.bytes_in_sequence),y=y+this.bytes_in_sequence-1}else if(34===r)this.tState=p,this.string+=this.stringBuffer.toString("utf8",0,this.stringBufferOffset),this.stringBufferOffset=0,this.onToken(d,this.string),this.offset+=t.byteLength(this.string,"utf8")+1,this.string=void 0;else if(92===r)this.tState=N;else{if(!(r>=32))return this.charError(e,y);this.appendStringChar(r)}else if(this.tState===N)if(34===(r=e[y]))this.appendStringChar(r),this.tState=I;else if(92===r)this.appendStringChar(q),this.tState=I;else if(47===r)this.appendStringChar(F),this.tState=I;else if(98===r)this.appendStringChar(B),this.tState=I;else if(102===r)this.appendStringChar(U),this.tState=I;else if(110===r)this.appendStringChar(V),this.tState=I;else if(114===r)this.appendStringChar(H),this.tState=I;else if(116===r)this.appendStringChar(z),this.tState=I;else{if(117!==r)return this.charError(e,y);this.unicode="",this.tState=R}else if(this.tState===R||this.tState===k||this.tState===P||this.tState===j){if(!((r=e[y])>=48&&r<64||r>64&&r<=70||r>96&&r<=102))return this.charError(e,y);if(this.unicode+=String.fromCharCode(r),this.tState++===j){var L=parseInt(this.unicode,16);this.unicode=void 0,void 0!==this.highSurrogate&&L>=56320&&L<57344?(this.appendStringBuf(new t(String.fromCharCode(this.highSurrogate,L))),this.highSurrogate=void 0):void 0===this.highSurrogate&&L>=55296&&L<56320?this.highSurrogate=L:(void 0!==this.highSurrogate&&(this.appendStringBuf(new t(String.fromCharCode(this.highSurrogate))),this.highSurrogate=void 0),this.appendStringBuf(new t(String.fromCharCode(L)))),this.tState=I}}else if(this.tState===O||this.tState===A)switch(r=e[y]){case 48:case 49:case 50:case 51:case 52:case 53:case 54:case 55:case 56:case 57:case 46:case 101:case 69:case 43:case 45:this.string+=String.fromCharCode(r),this.tState=A;break;default:this.tState=p;var G=Number(this.string);if(isNaN(G))return this.charError(e,y);this.string.match(/[0-9]+/)==this.string&&G.toString()!=this.string?this.onToken(d,this.string):this.onToken(h,G),this.offset+=this.string.length-1,this.string=void 0,y--}else if(this.tState===m){if(114!==e[y])return this.charError(e,y);this.tState=g}else if(this.tState===g){if(117!==e[y])return this.charError(e,y);this.tState=b}else if(this.tState===b){if(101!==e[y])return this.charError(e,y);this.tState=p,this.onToken(u,!0),this.offset+=3}else if(this.tState===v){if(97!==e[y])return this.charError(e,y);this.tState=_}else if(this.tState===_){if(108!==e[y])return this.charError(e,y);this.tState=w}else if(this.tState===w){if(115!==e[y])return this.charError(e,y);this.tState=S}else if(this.tState===S){if(101!==e[y])return this.charError(e,y);this.tState=p,this.onToken(l,!1),this.offset+=4}else if(this.tState===E){if(117!==e[y])return this.charError(e,y);this.tState=x}else if(this.tState===x){if(108!==e[y])return this.charError(e,y);this.tState=T}else if(this.tState===T){if(108!==e[y])return this.charError(e,y);this.tState=p,this.onToken(f,null),this.offset+=3}},X.onToken=function(e,t){},X.parseError=function(e,t){this.tState=y,this.onError(new Error("Unexpected "+Q.toknam(e)+(t?"("+JSON.stringify(t)+")":"")+" in state "+Q.toknam(this.state)))},X.push=function(){this.stack.push({value:this.value,key:this.key,mode:this.mode})},X.pop=function(){var e=this.value,t=this.stack.pop();this.value=t.value,this.key=t.key,this.mode=t.mode,this.emit(e),this.mode||(this.state=D)},X.emit=function(e){this.mode&&(this.state=c),this.onValue(e)},X.onValue=function(e){},X.onToken=function(e,t){if(this.state===D)if(e===d||e===h||e===u||e===l||e===f)this.value&&(this.value[this.key]=t),this.emit(t);else if(e===n)this.push(),this.value?this.value=this.value[this.key]={}:this.value={},this.key=void 0,this.state=C,this.mode=M;else if(e===a)this.push(),this.value?this.value=this.value[this.key]=[]:this.value=[],this.key=0,this.mode=L,this.state=D;else if(e===i){if(this.mode!==M)return this.parseError(e,t);this.pop()}else{if(e!==o)return this.parseError(e,t);if(this.mode!==L)return this.parseError(e,t);this.pop()}else if(this.state===C)if(e===d)this.key=t,this.state=s;else{if(e!==i)return this.parseError(e,t);this.pop()}else if(this.state===s){if(e!==s)return this.parseError(e,t);this.state=D}else{if(this.state!==c)return this.parseError(e,t);if(e===c)this.mode===L?(this.key++,this.state=D):this.mode===M&&(this.state=C);else{if(!(e===o&&this.mode===L||e===i&&this.mode===M))return this.parseError(e,t);this.pop()}}},Q.C=r,e.exports=Q}).call(this,r(7).Buffer)},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(41);class i{static async handlePredicateObject(e,t,r,n,i,a,o,s){const c=n-("@reverse"===i?1:0),u=await t.getDepthOffsetGraph(n,r),l=n-u;if(e.idStack[c]){const r=e.idStack[c];if(u>=0){const i=e.idStack[l-1];i?s?(t.validateReverseSubject(o),e.emitQuad(n,t.dataFactory.quad(o,a,r,i))):e.emitQuad(n,t.dataFactory.quad(r,a,o,i)):s?(t.validateReverseSubject(o),e.getUnidentifiedGraphBufferSafe(l-1).push({subject:o,predicate:a,object:r})):e.getUnidentifiedGraphBufferSafe(l-1).push({subject:r,predicate:a,object:o})}else s?(t.validateReverseSubject(o),e.emitQuad(n,t.dataFactory.quad(o,a,r,t.getDefaultGraph()))):e.emitQuad(n,t.dataFactory.quad(r,a,o,t.getDefaultGraph()))}else s&&t.validateReverseSubject(o),e.getUnidentifiedValueBufferSafe(c).push({predicate:a,object:o,reverse:s})}isPropertyHandler(){return!0}async validate(e,t,r,n,i){return r[n]&&!!await t.predicateToTerm(await e.getContext(r),r[n])}async test(e,t,r,n,i){return n[i]}async handle(e,t,r,a,o,s,c){const u=a[s],l=await t.unaliasKeywordParent(a,s),f=await e.getContext(a),d=await t.predicateToTerm(f,r);if(d){const c=await e.getContext(a,0);let h=await t.valueToTerm(c,r,o,s,a);if(h){const c=n.Util.isPropertyReverse(f,u,l),p="@list"===n.Util.getContextValueContainer(f,r);if(p||o["@list"]){if((p||o["@list"]&&!Array.isArray(o["@list"]))&&h!==t.rdfNil){const r=t.dataFactory.blankNode();e.emitQuad(s,t.dataFactory.quad(r,t.rdfRest,t.rdfNil,t.getDefaultGraph())),e.emitQuad(s,t.dataFactory.quad(r,t.rdfFirst,h,t.getDefaultGraph())),h=r}if(c&&!e.allowSubjectList)throw new Error(`Found illegal list value in subject position at ${r}`)}await i.handlePredicateObject(e,t,a,s,l,d,h,c)}else e.emittedStack[s]=!1}}}t.EntryHandlerPredicate=i},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(378))},function(e,t,r){(function(e){!function(t){t.parser=function(e,t){return new a(e,t)},t.SAXParser=a,t.SAXStream=s,t.createStream=function(e,t){return new s(e,t)},t.MAX_BUFFER_LENGTH=65536;var n,i=["comment","sgmlDecl","textNode","tagName","doctype","procInstName","procInstBody","entity","attribName","attribValue","cdata","script"];function a(e,r){if(!(this instanceof a))return new a(e,r);!function(e){for(var t=0,r=i.length;t<r;t++)e[i[t]]=""}(this),this.q=this.c="",this.bufferCheckPosition=t.MAX_BUFFER_LENGTH,this.opt=r||{},this.opt.lowercase=this.opt.lowercase||this.opt.lowercasetags,this.looseCase=this.opt.lowercase?"toLowerCase":"toUpperCase",this.tags=[],this.closed=this.closedRoot=this.sawRoot=!1,this.tag=this.error=null,this.strict=!!e,this.noscript=!(!e&&!this.opt.noscript),this.state=T.BEGIN,this.strictEntities=this.opt.strictEntities,this.ENTITIES=this.strictEntities?Object.create(t.XML_ENTITIES):Object.create(t.ENTITIES),this.attribList=[],this.opt.xmlns&&(this.ns=Object.create(d)),this.trackPosition=!1!==this.opt.position,this.trackPosition&&(this.position=this.line=this.column=0),A(this,"onready")}t.EVENTS=["text","processinginstruction","sgmldeclaration","doctype","comment","opentagstart","attribute","opentag","closetag","opencdata","cdata","closecdata","error","end","ready","script","opennamespace","closenamespace"],Object.create||(Object.create=function(e){function t(){}return t.prototype=e,new t}),Object.keys||(Object.keys=function(e){var t=[];for(var r in e)e.hasOwnProperty(r)&&t.push(r);return t}),a.prototype={end:function(){P(this)},write:function(e){if(this.error)throw this.error;if(this.closed)return k(this,"Cannot write after close. Assign an onready handler.");if(null===e)return P(this);"object"==typeof e&&(e=e.toString());var r=0,n="";for(;n=U(e,r++),this.c=n,n;)switch(this.trackPosition&&(this.position++,"\n"===n?(this.line++,this.column=0):this.column++),this.state){case T.BEGIN:if(this.state=T.BEGIN_WHITESPACE,"\ufeff"===n)continue;B(this,n);continue;case T.BEGIN_WHITESPACE:B(this,n);continue;case T.TEXT:if(this.sawRoot&&!this.closedRoot){for(var a=r-1;n&&"<"!==n&&"&"!==n;)(n=U(e,r++))&&this.trackPosition&&(this.position++,"\n"===n?(this.line++,this.column=0):this.column++);this.textNode+=e.substring(a,r-1)}"<"!==n||this.sawRoot&&this.closedRoot&&!this.strict?(g(n)||this.sawRoot&&!this.closedRoot||j(this,"Text data outside of root node."),"&"===n?this.state=T.TEXT_ENTITY:this.textNode+=n):(this.state=T.OPEN_WAKA,this.startTagPosition=this.position);continue;case T.SCRIPT:"<"===n?this.state=T.SCRIPT_ENDING:this.script+=n;continue;case T.SCRIPT_ENDING:"/"===n?this.state=T.CLOSE_TAG:(this.script+="<"+n,this.state=T.SCRIPT);continue;case T.OPEN_WAKA:if("!"===n)this.state=T.SGML_DECL,this.sgmlDecl="";else if(g(n));else if(_(h,n))this.state=T.OPEN_TAG,this.tagName=n;else if("/"===n)this.state=T.CLOSE_TAG,this.tagName="";else if("?"===n)this.state=T.PROC_INST,this.procInstName=this.procInstBody="";else{if(j(this,"Unencoded <"),this.startTagPosition+1<this.position){var o=this.position-this.startTagPosition;n=new Array(o).join(" ")+n}this.textNode+="<"+n,this.state=T.TEXT}continue;case T.SGML_DECL:(this.sgmlDecl+n).toUpperCase()===c?(I(this,"onopencdata"),this.state=T.CDATA,this.sgmlDecl="",this.cdata=""):this.sgmlDecl+n==="--"?(this.state=T.COMMENT,this.comment="",this.sgmlDecl=""):(this.sgmlDecl+n).toUpperCase()===u?(this.state=T.DOCTYPE,(this.doctype||this.sawRoot)&&j(this,"Inappropriately located doctype declaration"),this.doctype="",this.sgmlDecl=""):">"===n?(I(this,"onsgmldeclaration",this.sgmlDecl),this.sgmlDecl="",this.state=T.TEXT):b(n)?(this.state=T.SGML_DECL_QUOTED,this.sgmlDecl+=n):this.sgmlDecl+=n;continue;case T.SGML_DECL_QUOTED:n===this.q&&(this.state=T.SGML_DECL,this.q=""),this.sgmlDecl+=n;continue;case T.DOCTYPE:">"===n?(this.state=T.TEXT,I(this,"ondoctype",this.doctype),this.doctype=!0):(this.doctype+=n,"["===n?this.state=T.DOCTYPE_DTD:b(n)&&(this.state=T.DOCTYPE_QUOTED,this.q=n));continue;case T.DOCTYPE_QUOTED:this.doctype+=n,n===this.q&&(this.q="",this.state=T.DOCTYPE);continue;case T.DOCTYPE_DTD:this.doctype+=n,"]"===n?this.state=T.DOCTYPE:b(n)&&(this.state=T.DOCTYPE_DTD_QUOTED,this.q=n);continue;case T.DOCTYPE_DTD_QUOTED:this.doctype+=n,n===this.q&&(this.state=T.DOCTYPE_DTD,this.q="");continue;case T.COMMENT:"-"===n?this.state=T.COMMENT_ENDING:this.comment+=n;continue;case T.COMMENT_ENDING:"-"===n?(this.state=T.COMMENT_ENDED,this.comment=R(this.opt,this.comment),this.comment&&I(this,"oncomment",this.comment),this.comment=""):(this.comment+="-"+n,this.state=T.COMMENT);continue;case T.COMMENT_ENDED:">"!==n?(j(this,"Malformed comment"),this.comment+="--"+n,this.state=T.COMMENT):this.state=T.TEXT;continue;case T.CDATA:"]"===n?this.state=T.CDATA_ENDING:this.cdata+=n;continue;case T.CDATA_ENDING:"]"===n?this.state=T.CDATA_ENDING_2:(this.cdata+="]"+n,this.state=T.CDATA);continue;case T.CDATA_ENDING_2:">"===n?(this.cdata&&I(this,"oncdata",this.cdata),I(this,"onclosecdata"),this.cdata="",this.state=T.TEXT):"]"===n?this.cdata+="]":(this.cdata+="]]"+n,this.state=T.CDATA);continue;case T.PROC_INST:"?"===n?this.state=T.PROC_INST_ENDING:g(n)?this.state=T.PROC_INST_BODY:this.procInstName+=n;continue;case T.PROC_INST_BODY:if(!this.procInstBody&&g(n))continue;"?"===n?this.state=T.PROC_INST_ENDING:this.procInstBody+=n;continue;case T.PROC_INST_ENDING:">"===n?(I(this,"onprocessinginstruction",{name:this.procInstName,body:this.procInstBody}),this.procInstName=this.procInstBody="",this.state=T.TEXT):(this.procInstBody+="?"+n,this.state=T.PROC_INST_BODY);continue;case T.OPEN_TAG:_(p,n)?this.tagName+=n:(D(this),">"===n?L(this):"/"===n?this.state=T.OPEN_TAG_SLASH:(g(n)||j(this,"Invalid character in tag name"),this.state=T.ATTRIB));continue;case T.OPEN_TAG_SLASH:">"===n?(L(this,!0),q(this)):(j(this,"Forward-slash in opening tag not followed by >"),this.state=T.ATTRIB);continue;case T.ATTRIB:if(g(n))continue;">"===n?L(this):"/"===n?this.state=T.OPEN_TAG_SLASH:_(h,n)?(this.attribName=n,this.attribValue="",this.state=T.ATTRIB_NAME):j(this,"Invalid attribute name");continue;case T.ATTRIB_NAME:"="===n?this.state=T.ATTRIB_VALUE:">"===n?(j(this,"Attribute without value"),this.attribValue=this.attribName,M(this),L(this)):g(n)?this.state=T.ATTRIB_NAME_SAW_WHITE:_(p,n)?this.attribName+=n:j(this,"Invalid attribute name");continue;case T.ATTRIB_NAME_SAW_WHITE:if("="===n)this.state=T.ATTRIB_VALUE;else{if(g(n))continue;j(this,"Attribute without value"),this.tag.attributes[this.attribName]="",this.attribValue="",I(this,"onattribute",{name:this.attribName,value:""}),this.attribName="",">"===n?L(this):_(h,n)?(this.attribName=n,this.state=T.ATTRIB_NAME):(j(this,"Invalid attribute name"),this.state=T.ATTRIB)}continue;case T.ATTRIB_VALUE:if(g(n))continue;b(n)?(this.q=n,this.state=T.ATTRIB_VALUE_QUOTED):(j(this,"Unquoted attribute value"),this.state=T.ATTRIB_VALUE_UNQUOTED,this.attribValue=n);continue;case T.ATTRIB_VALUE_QUOTED:if(n!==this.q){"&"===n?this.state=T.ATTRIB_VALUE_ENTITY_Q:this.attribValue+=n;continue}M(this),this.q="",this.state=T.ATTRIB_VALUE_CLOSED;continue;case T.ATTRIB_VALUE_CLOSED:g(n)?this.state=T.ATTRIB:">"===n?L(this):"/"===n?this.state=T.OPEN_TAG_SLASH:_(h,n)?(j(this,"No whitespace between attributes"),this.attribName=n,this.attribValue="",this.state=T.ATTRIB_NAME):j(this,"Invalid attribute name");continue;case T.ATTRIB_VALUE_UNQUOTED:if(!v(n)){"&"===n?this.state=T.ATTRIB_VALUE_ENTITY_U:this.attribValue+=n;continue}M(this),">"===n?L(this):this.state=T.ATTRIB;continue;case T.CLOSE_TAG:if(this.tagName)">"===n?q(this):_(p,n)?this.tagName+=n:this.script?(this.script+="</"+this.tagName,this.tagName="",this.state=T.SCRIPT):(g(n)||j(this,"Invalid tagname in closing tag"),this.state=T.CLOSE_TAG_SAW_WHITE);else{if(g(n))continue;w(h,n)?this.script?(this.script+="</"+n,this.state=T.SCRIPT):j(this,"Invalid tagname in closing tag."):this.tagName=n}continue;case T.CLOSE_TAG_SAW_WHITE:if(g(n))continue;">"===n?q(this):j(this,"Invalid characters in closing tag");continue;case T.TEXT_ENTITY:case T.ATTRIB_VALUE_ENTITY_Q:case T.ATTRIB_VALUE_ENTITY_U:var s,l;switch(this.state){case T.TEXT_ENTITY:s=T.TEXT,l="textNode";break;case T.ATTRIB_VALUE_ENTITY_Q:s=T.ATTRIB_VALUE_QUOTED,l="attribValue";break;case T.ATTRIB_VALUE_ENTITY_U:s=T.ATTRIB_VALUE_UNQUOTED,l="attribValue"}";"===n?(this[l]+=F(this),this.entity="",this.state=s):_(this.entity.length?m:y,n)?this.entity+=n:(j(this,"Invalid character in entity name"),this[l]+="&"+this.entity+n,this.entity="",this.state=s);continue;default:throw new Error(this,"Unknown state: "+this.state)}this.position>=this.bufferCheckPosition&&function(e){for(var r=Math.max(t.MAX_BUFFER_LENGTH,10),n=0,a=0,o=i.length;a<o;a++){var s=e[i[a]].length;if(s>r)switch(i[a]){case"textNode":N(e);break;case"cdata":I(e,"oncdata",e.cdata),e.cdata="";break;case"script":I(e,"onscript",e.script),e.script="";break;default:k(e,"Max buffer length exceeded: "+i[a])}n=Math.max(n,s)}var c=t.MAX_BUFFER_LENGTH-n;e.bufferCheckPosition=c+e.position}(this);return this}
9/*! http://mths.be/fromcodepoint v0.1.0 by @mathias */,resume:function(){return this.error=null,this},close:function(){return this.write(null)},flush:function(){var e;N(e=this),""!==e.cdata&&(I(e,"oncdata",e.cdata),e.cdata=""),""!==e.script&&(I(e,"onscript",e.script),e.script="")}};try{n=r(3).Stream}catch(e){n=function(){}}var o=t.EVENTS.filter(function(e){return"error"!==e&&"end"!==e});function s(e,t){if(!(this instanceof s))return new s(e,t);n.apply(this),this._parser=new a(e,t),this.writable=!0,this.readable=!0;var r=this;this._parser.onend=function(){r.emit("end")},this._parser.onerror=function(e){r.emit("error",e),r._parser.error=null},this._decoder=null,o.forEach(function(e){Object.defineProperty(r,"on"+e,{get:function(){return r._parser["on"+e]},set:function(t){if(!t)return r.removeAllListeners(e),r._parser["on"+e]=t,t;r.on(e,t)},enumerable:!0,configurable:!1})})}s.prototype=Object.create(n.prototype,{constructor:{value:s}}),s.prototype.write=function(t){if("function"==typeof e&&"function"==typeof e.isBuffer&&e.isBuffer(t)){if(!this._decoder){var n=r(51).StringDecoder;this._decoder=new n("utf8")}t=this._decoder.write(t)}return this._parser.write(t.toString()),this.emit("data",t),!0},s.prototype.end=function(e){return e&&e.length&&this.write(e),this._parser.end(),!0},s.prototype.on=function(e,t){var r=this;return r._parser["on"+e]||-1===o.indexOf(e)||(r._parser["on"+e]=function(){var t=1===arguments.length?[arguments[0]]:Array.apply(null,arguments);t.splice(0,0,e),r.emit.apply(r,t)}),n.prototype.on.call(r,e,t)};var c="[CDATA[",u="DOCTYPE",l="http://www.w3.org/XML/1998/namespace",f="http://www.w3.org/2000/xmlns/",d={xml:l,xmlns:f},h=/[:_A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]/,p=/[:_A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\u00B7\u0300-\u036F\u203F-\u2040.\d-]/,y=/[#:_A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]/,m=/[#:_A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\u00B7\u0300-\u036F\u203F-\u2040.\d-]/;function g(e){return" "===e||"\n"===e||"\r"===e||"\t"===e}function b(e){return'"'===e||"'"===e}function v(e){return">"===e||g(e)}function _(e,t){return e.test(t)}function w(e,t){return!_(e,t)}var S,E,x,T=0;for(var O in t.STATE={BEGIN:T++,BEGIN_WHITESPACE:T++,TEXT:T++,TEXT_ENTITY:T++,OPEN_WAKA:T++,SGML_DECL:T++,SGML_DECL_QUOTED:T++,DOCTYPE:T++,DOCTYPE_QUOTED:T++,DOCTYPE_DTD:T++,DOCTYPE_DTD_QUOTED:T++,COMMENT_STARTING:T++,COMMENT:T++,COMMENT_ENDING:T++,COMMENT_ENDED:T++,CDATA:T++,CDATA_ENDING:T++,CDATA_ENDING_2:T++,PROC_INST:T++,PROC_INST_BODY:T++,PROC_INST_ENDING:T++,OPEN_TAG:T++,OPEN_TAG_SLASH:T++,ATTRIB:T++,ATTRIB_NAME:T++,ATTRIB_NAME_SAW_WHITE:T++,ATTRIB_VALUE:T++,ATTRIB_VALUE_QUOTED:T++,ATTRIB_VALUE_CLOSED:T++,ATTRIB_VALUE_UNQUOTED:T++,ATTRIB_VALUE_ENTITY_Q:T++,ATTRIB_VALUE_ENTITY_U:T++,CLOSE_TAG:T++,CLOSE_TAG_SAW_WHITE:T++,SCRIPT:T++,SCRIPT_ENDING:T++},t.XML_ENTITIES={amp:"&",gt:">",lt:"<",quot:'"',apos:"'"},t.ENTITIES={amp:"&",gt:">",lt:"<",quot:'"',apos:"'",AElig:198,Aacute:193,Acirc:194,Agrave:192,Aring:197,Atilde:195,Auml:196,Ccedil:199,ETH:208,Eacute:201,Ecirc:202,Egrave:200,Euml:203,Iacute:205,Icirc:206,Igrave:204,Iuml:207,Ntilde:209,Oacute:211,Ocirc:212,Ograve:210,Oslash:216,Otilde:213,Ouml:214,THORN:222,Uacute:218,Ucirc:219,Ugrave:217,Uuml:220,Yacute:221,aacute:225,acirc:226,aelig:230,agrave:224,aring:229,atilde:227,auml:228,ccedil:231,eacute:233,ecirc:234,egrave:232,eth:240,euml:235,iacute:237,icirc:238,igrave:236,iuml:239,ntilde:241,oacute:243,ocirc:244,ograve:242,oslash:248,otilde:245,ouml:246,szlig:223,thorn:254,uacute:250,ucirc:251,ugrave:249,uuml:252,yacute:253,yuml:255,copy:169,reg:174,nbsp:160,iexcl:161,cent:162,pound:163,curren:164,yen:165,brvbar:166,sect:167,uml:168,ordf:170,laquo:171,not:172,shy:173,macr:175,deg:176,plusmn:177,sup1:185,sup2:178,sup3:179,acute:180,micro:181,para:182,middot:183,cedil:184,ordm:186,raquo:187,frac14:188,frac12:189,frac34:190,iquest:191,times:215,divide:247,OElig:338,oelig:339,Scaron:352,scaron:353,Yuml:376,fnof:402,circ:710,tilde:732,Alpha:913,Beta:914,Gamma:915,Delta:916,Epsilon:917,Zeta:918,Eta:919,Theta:920,Iota:921,Kappa:922,Lambda:923,Mu:924,Nu:925,Xi:926,Omicron:927,Pi:928,Rho:929,Sigma:931,Tau:932,Upsilon:933,Phi:934,Chi:935,Psi:936,Omega:937,alpha:945,beta:946,gamma:947,delta:948,epsilon:949,zeta:950,eta:951,theta:952,iota:953,kappa:954,lambda:955,mu:956,nu:957,xi:958,omicron:959,pi:960,rho:961,sigmaf:962,sigma:963,tau:964,upsilon:965,phi:966,chi:967,psi:968,omega:969,thetasym:977,upsih:978,piv:982,ensp:8194,emsp:8195,thinsp:8201,zwnj:8204,zwj:8205,lrm:8206,rlm:8207,ndash:8211,mdash:8212,lsquo:8216,rsquo:8217,sbquo:8218,ldquo:8220,rdquo:8221,bdquo:8222,dagger:8224,Dagger:8225,bull:8226,hellip:8230,permil:8240,prime:8242,Prime:8243,lsaquo:8249,rsaquo:8250,oline:8254,frasl:8260,euro:8364,image:8465,weierp:8472,real:8476,trade:8482,alefsym:8501,larr:8592,uarr:8593,rarr:8594,darr:8595,harr:8596,crarr:8629,lArr:8656,uArr:8657,rArr:8658,dArr:8659,hArr:8660,forall:8704,part:8706,exist:8707,empty:8709,nabla:8711,isin:8712,notin:8713,ni:8715,prod:8719,sum:8721,minus:8722,lowast:8727,radic:8730,prop:8733,infin:8734,ang:8736,and:8743,or:8744,cap:8745,cup:8746,int:8747,there4:8756,sim:8764,cong:8773,asymp:8776,ne:8800,equiv:8801,le:8804,ge:8805,sub:8834,sup:8835,nsub:8836,sube:8838,supe:8839,oplus:8853,otimes:8855,perp:8869,sdot:8901,lceil:8968,rceil:8969,lfloor:8970,rfloor:8971,lang:9001,rang:9002,loz:9674,spades:9824,clubs:9827,hearts:9829,diams:9830},Object.keys(t.ENTITIES).forEach(function(e){var r=t.ENTITIES[e],n="number"==typeof r?String.fromCharCode(r):r;t.ENTITIES[e]=n}),t.STATE)t.STATE[t.STATE[O]]=O;function A(e,t,r){e[t]&&e[t](r)}function I(e,t,r){e.textNode&&N(e),A(e,t,r)}function N(e){e.textNode=R(e.opt,e.textNode),e.textNode&&A(e,"ontext",e.textNode),e.textNode=""}function R(e,t){return e.trim&&(t=t.trim()),e.normalize&&(t=t.replace(/\s+/g," ")),t}function k(e,t){return N(e),e.trackPosition&&(t+="\nLine: "+e.line+"\nColumn: "+e.column+"\nChar: "+e.c),t=new Error(t),e.error=t,A(e,"onerror",t),e}function P(e){return e.sawRoot&&!e.closedRoot&&j(e,"Unclosed root tag"),e.state!==T.BEGIN&&e.state!==T.BEGIN_WHITESPACE&&e.state!==T.TEXT&&k(e,"Unexpected end"),N(e),e.c="",e.closed=!0,A(e,"onend"),a.call(e,e.strict,e.opt),e}function j(e,t){if("object"!=typeof e||!(e instanceof a))throw new Error("bad call to strictFail");e.strict&&k(e,t)}function D(e){e.strict||(e.tagName=e.tagName[e.looseCase]());var t=e.tags[e.tags.length-1]||e,r=e.tag={name:e.tagName,attributes:{}};e.opt.xmlns&&(r.ns=t.ns),e.attribList.length=0,I(e,"onopentagstart",r)}function C(e,t){var r=e.indexOf(":")<0?["",e]:e.split(":"),n=r[0],i=r[1];return t&&"xmlns"===e&&(n="xmlns",i=""),{prefix:n,local:i}}function M(e){if(e.strict||(e.attribName=e.attribName[e.looseCase]()),-1!==e.attribList.indexOf(e.attribName)||e.tag.attributes.hasOwnProperty(e.attribName))e.attribName=e.attribValue="";else{if(e.opt.xmlns){var t=C(e.attribName,!0),r=t.prefix,n=t.local;if("xmlns"===r)if("xml"===n&&e.attribValue!==l)j(e,"xml: prefix must be bound to "+l+"\nActual: "+e.attribValue);else if("xmlns"===n&&e.attribValue!==f)j(e,"xmlns: prefix must be bound to "+f+"\nActual: "+e.attribValue);else{var i=e.tag,a=e.tags[e.tags.length-1]||e;i.ns===a.ns&&(i.ns=Object.create(a.ns)),i.ns[n]=e.attribValue}e.attribList.push([e.attribName,e.attribValue])}else e.tag.attributes[e.attribName]=e.attribValue,I(e,"onattribute",{name:e.attribName,value:e.attribValue});e.attribName=e.attribValue=""}}function L(e,t){if(e.opt.xmlns){var r=e.tag,n=C(e.tagName);r.prefix=n.prefix,r.local=n.local,r.uri=r.ns[n.prefix]||"",r.prefix&&!r.uri&&(j(e,"Unbound namespace prefix: "+JSON.stringify(e.tagName)),r.uri=n.prefix);var i=e.tags[e.tags.length-1]||e;r.ns&&i.ns!==r.ns&&Object.keys(r.ns).forEach(function(t){I(e,"onopennamespace",{prefix:t,uri:r.ns[t]})});for(var a=0,o=e.attribList.length;a<o;a++){var s=e.attribList[a],c=s[0],u=s[1],l=C(c,!0),f=l.prefix,d=l.local,h=""===f?"":r.ns[f]||"",p={name:c,value:u,prefix:f,local:d,uri:h};f&&"xmlns"!==f&&!h&&(j(e,"Unbound namespace prefix: "+JSON.stringify(f)),p.uri=f),e.tag.attributes[c]=p,I(e,"onattribute",p)}e.attribList.length=0}e.tag.isSelfClosing=!!t,e.sawRoot=!0,e.tags.push(e.tag),I(e,"onopentag",e.tag),t||(e.noscript||"script"!==e.tagName.toLowerCase()?e.state=T.TEXT:e.state=T.SCRIPT,e.tag=null,e.tagName=""),e.attribName=e.attribValue="",e.attribList.length=0}function q(e){if(!e.tagName)return j(e,"Weird empty close tag."),e.textNode+="</>",void(e.state=T.TEXT);if(e.script){if("script"!==e.tagName)return e.script+="</"+e.tagName+">",e.tagName="",void(e.state=T.SCRIPT);I(e,"onscript",e.script),e.script=""}var t=e.tags.length,r=e.tagName;e.strict||(r=r[e.looseCase]());for(var n=r;t--;){if(e.tags[t].name===n)break;j(e,"Unexpected close tag")}if(t<0)return j(e,"Unmatched closing tag: "+e.tagName),e.textNode+="</"+e.tagName+">",void(e.state=T.TEXT);e.tagName=r;for(var i=e.tags.length;i-- >t;){var a=e.tag=e.tags.pop();e.tagName=e.tag.name,I(e,"onclosetag",e.tagName);var o={};for(var s in a.ns)o[s]=a.ns[s];var c=e.tags[e.tags.length-1]||e;e.opt.xmlns&&a.ns!==c.ns&&Object.keys(a.ns).forEach(function(t){var r=a.ns[t];I(e,"onclosenamespace",{prefix:t,uri:r})})}0===t&&(e.closedRoot=!0),e.tagName=e.attribValue=e.attribName="",e.attribList.length=0,e.state=T.TEXT}function F(e){var t,r=e.entity,n=r.toLowerCase(),i="";return e.ENTITIES[r]?e.ENTITIES[r]:e.ENTITIES[n]?e.ENTITIES[n]:("#"===(r=n).charAt(0)&&("x"===r.charAt(1)?(r=r.slice(2),i=(t=parseInt(r,16)).toString(16)):(r=r.slice(1),i=(t=parseInt(r,10)).toString(10))),r=r.replace(/^0+/,""),isNaN(t)||i.toLowerCase()!==r?(j(e,"Invalid character entity"),"&"+e.entity+";"):String.fromCodePoint(t))}function B(e,t){"<"===t?(e.state=T.OPEN_WAKA,e.startTagPosition=e.position):g(t)||(j(e,"Non-whitespace before first tag."),e.textNode=t,e.state=T.TEXT)}function U(e,t){var r="";return t<e.length&&(r=e.charAt(t)),r}T=t.STATE,String.fromCodePoint||(S=String.fromCharCode,E=Math.floor,x=function(){var e,t,r=16384,n=[],i=-1,a=arguments.length;if(!a)return"";for(var o="";++i<a;){var s=Number(arguments[i]);if(!isFinite(s)||s<0||s>1114111||E(s)!==s)throw RangeError("Invalid code point: "+s);s<=65535?n.push(s):(e=55296+((s-=65536)>>10),t=s%1024+56320,n.push(e,t)),(i+1===a||n.length>r)&&(o+=S.apply(null,n),n.length=0)}return o},Object.defineProperty?Object.defineProperty(String,"fromCodePoint",{value:x,configurable:!0,writable:!0}):String.fromCodePoint=x)}(t)}).call(this,r(7).Buffer)},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(382))},function(e,t,r){"use strict";function n(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}Object.defineProperty(t,"__esModule",{value:!0}),n(r(383)),n(r(92)),n(r(176))},function(e,t,r){"use strict";var n,i=this&&this.__extends||(n=function(e,t){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)}),a=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var o=a(r(165)),s=r(31),c=new Set(["input","option","optgroup","select","button","datalist","textarea"]),u=new Set(["p"]),l={tr:new Set(["tr","th","td"]),th:new Set(["th"]),td:new Set(["thead","th","td"]),body:new Set(["head","link","script"]),li:new Set(["li"]),p:u,h1:u,h2:u,h3:u,h4:u,h5:u,h6:u,select:c,input:c,output:c,button:c,datalist:c,textarea:c,option:new Set(["option"]),optgroup:new Set(["optgroup","option"]),dd:new Set(["dt","dd"]),dt:new Set(["dt","dd"]),address:u,article:u,aside:u,blockquote:u,details:u,div:u,dl:u,fieldset:u,figcaption:u,figure:u,footer:u,form:u,header:u,hr:u,main:u,nav:u,ol:u,pre:u,section:u,table:u,ul:u,rt:new Set(["rt","rp"]),rp:new Set(["rt","rp"]),tbody:new Set(["thead","tbody"]),tfoot:new Set(["thead","tbody"])},f=new Set(["area","base","basefont","br","col","command","embed","frame","hr","img","input","isindex","keygen","link","meta","param","source","track","wbr"]),d=new Set(["math","svg"]),h=new Set(["mi","mo","mn","ms","mtext","annotation-xml","foreignObject","desc","title"]),p=/\s|\//,y=function(e){function t(r,n){var i=e.call(this)||this;return i._tagname="",i._attribname="",i._attribvalue="",i._attribs=null,i._stack=[],i._foreignContext=[],i.startIndex=0,i.endIndex=null,i.parseChunk=t.prototype.write,i.done=t.prototype.end,i._options=n||{},i._cbs=r||{},i._tagname="",i._attribname="",i._attribvalue="",i._attribs=null,i._stack=[],i._foreignContext=[],i.startIndex=0,i.endIndex=null,i._lowerCaseTagNames="lowerCaseTags"in i._options?!!i._options.lowerCaseTags:!i._options.xmlMode,i._lowerCaseAttributeNames="lowerCaseAttributeNames"in i._options?!!i._options.lowerCaseAttributeNames:!i._options.xmlMode,i._tokenizer=new(i._options.Tokenizer||o.default)(i._options,i),i._cbs.onparserinit&&i._cbs.onparserinit(i),i}return i(t,e),t.prototype._updatePosition=function(e){null===this.endIndex?this._tokenizer._sectionStart<=e?this.startIndex=0:this.startIndex=this._tokenizer._sectionStart-e:this.startIndex=this.endIndex+1,this.endIndex=this._tokenizer.getAbsoluteIndex()},t.prototype.ontext=function(e){this._updatePosition(1),this.endIndex--,this._cbs.ontext&&this._cbs.ontext(e)},t.prototype.onopentagname=function(e){if(this._lowerCaseTagNames&&(e=e.toLowerCase()),this._tagname=e,!this._options.xmlMode&&e in l)for(var t=void 0;l[e].has(t=this._stack[this._stack.length-1]);this.onclosetag(t));!this._options.xmlMode&&f.has(e)||(this._stack.push(e),d.has(e)?this._foreignContext.push(!0):h.has(e)&&this._foreignContext.push(!1)),this._cbs.onopentagname&&this._cbs.onopentagname(e),this._cbs.onopentag&&(this._attribs={})},t.prototype.onopentagend=function(){this._updatePosition(1),this._attribs&&(this._cbs.onopentag&&this._cbs.onopentag(this._tagname,this._attribs),this._attribs=null),!this._options.xmlMode&&this._cbs.onclosetag&&f.has(this._tagname)&&this._cbs.onclosetag(this._tagname),this._tagname=""},t.prototype.onclosetag=function(e){if(this._updatePosition(1),this._lowerCaseTagNames&&(e=e.toLowerCase()),(d.has(e)||h.has(e))&&this._foreignContext.pop(),!this._stack.length||!this._options.xmlMode&&f.has(e))this._options.xmlMode||"br"!==e&&"p"!==e||(this.onopentagname(e),this._closeCurrentTag());else{var t=this._stack.lastIndexOf(e);if(-1!==t)if(this._cbs.onclosetag)for(t=this._stack.length-t;t--;)this._cbs.onclosetag(this._stack.pop());else this._stack.length=t;else"p"!==e||this._options.xmlMode||(this.onopentagname(e),this._closeCurrentTag())}},t.prototype.onselfclosingtag=function(){this._options.xmlMode||this._options.recognizeSelfClosing||this._foreignContext[this._foreignContext.length-1]?this._closeCurrentTag():this.onopentagend()},t.prototype._closeCurrentTag=function(){var e=this._tagname;this.onopentagend(),this._stack[this._stack.length-1]===e&&(this._cbs.onclosetag&&this._cbs.onclosetag(e),this._stack.pop())},t.prototype.onattribname=function(e){this._lowerCaseAttributeNames&&(e=e.toLowerCase()),this._attribname=e},t.prototype.onattribdata=function(e){this._attribvalue+=e},t.prototype.onattribend=function(){this._cbs.onattribute&&this._cbs.onattribute(this._attribname,this._attribvalue),this._attribs&&!Object.prototype.hasOwnProperty.call(this._attribs,this._attribname)&&(this._attribs[this._attribname]=this._attribvalue),this._attribname="",this._attribvalue=""},t.prototype._getInstructionName=function(e){var t=e.search(p),r=t<0?e:e.substr(0,t);return this._lowerCaseTagNames&&(r=r.toLowerCase()),r},t.prototype.ondeclaration=function(e){if(this._cbs.onprocessinginstruction){var t=this._getInstructionName(e);this._cbs.onprocessinginstruction("!"+t,"!"+e)}},t.prototype.onprocessinginstruction=function(e){if(this._cbs.onprocessinginstruction){var t=this._getInstructionName(e);this._cbs.onprocessinginstruction("?"+t,"?"+e)}},t.prototype.oncomment=function(e){this._updatePosition(4),this._cbs.oncomment&&this._cbs.oncomment(e),this._cbs.oncommentend&&this._cbs.oncommentend()},t.prototype.oncdata=function(e){this._updatePosition(1),this._options.xmlMode||this._options.recognizeCDATA?(this._cbs.oncdatastart&&this._cbs.oncdatastart(),this._cbs.ontext&&this._cbs.ontext(e),this._cbs.oncdataend&&this._cbs.oncdataend()):this.oncomment("[CDATA["+e+"]]")},t.prototype.onerror=function(e){this._cbs.onerror&&this._cbs.onerror(e)},t.prototype.onend=function(){if(this._cbs.onclosetag)for(var e=this._stack.length;e>0;this._cbs.onclosetag(this._stack[--e]));this._cbs.onend&&this._cbs.onend()},t.prototype.reset=function(){this._cbs.onreset&&this._cbs.onreset(),this._tokenizer.reset(),this._tagname="",this._attribname="",this._attribs=null,this._stack=[],this._cbs.onparserinit&&this._cbs.onparserinit(this)},t.prototype.parseComplete=function(e){this.reset(),this.end(e)},t.prototype.write=function(e){this._tokenizer.write(e)},t.prototype.end=function(e){this._tokenizer.end(e)},t.prototype.pause=function(){this._tokenizer.pause()},t.prototype.resume=function(){this._tokenizer.resume()},t}(s.EventEmitter);t.Parser=y},function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var i=n(r(385)),a=n(r(387)),o=n(r(388)),s=n(r(389));function c(e){return" "===e||"\n"===e||"\t"===e||"\f"===e||"\r"===e}function u(e,t,r){var n=e.toLowerCase();return e===n?function(e,i){i===n?e._state=t:(e._state=r,e._index--)}:function(i,a){a===n||a===e?i._state=t:(i._state=r,i._index--)}}function l(e,t){var r=e.toLowerCase();return function(n,i){i===r||i===e?n._state=t:(n._state=3,n._index--)}}var f=u("C",23,16),d=u("D",24,16),h=u("A",25,16),p=u("T",26,16),y=u("A",27,16),m=l("R",34),g=l("I",35),b=l("P",36),v=l("T",37),_=u("R",39,1),w=u("I",40,1),S=u("P",41,1),E=u("T",42,1),x=l("Y",44),T=l("L",45),O=l("E",46),A=u("Y",48,1),I=u("L",49,1),N=u("E",50,1),R=u("#",52,53),k=u("X",55,54),P=function(){function e(e,t){this._state=1,this._buffer="",this._sectionStart=0,this._index=0,this._bufferOffset=0,this._baseState=1,this._special=1,this._running=!0,this._ended=!1,this._cbs=t,this._xmlMode=!(!e||!e.xmlMode),this._decodeEntities=!(!e||!e.decodeEntities)}return e.prototype.reset=function(){this._state=1,this._buffer="",this._sectionStart=0,this._index=0,this._bufferOffset=0,this._baseState=1,this._special=1,this._running=!0,this._ended=!1},e.prototype._stateText=function(e){"<"===e?(this._index>this._sectionStart&&this._cbs.ontext(this._getSection()),this._state=2,this._sectionStart=this._index):this._decodeEntities&&1===this._special&&"&"===e&&(this._index>this._sectionStart&&this._cbs.ontext(this._getSection()),this._baseState=1,this._state=51,this._sectionStart=this._index)},e.prototype._stateBeforeTagName=function(e){"/"===e?this._state=5:"<"===e?(this._cbs.ontext(this._getSection()),this._sectionStart=this._index):">"===e||1!==this._special||c(e)?this._state=1:"!"===e?(this._state=15,this._sectionStart=this._index+1):"?"===e?(this._state=17,this._sectionStart=this._index+1):(this._state=this._xmlMode||"s"!==e&&"S"!==e?3:31,this._sectionStart=this._index)},e.prototype._stateInTagName=function(e){("/"===e||">"===e||c(e))&&(this._emitToken("onopentagname"),this._state=8,this._index--)},e.prototype._stateBeforeCloseingTagName=function(e){c(e)||(">"===e?this._state=1:1!==this._special?"s"===e||"S"===e?this._state=32:(this._state=1,this._index--):(this._state=6,this._sectionStart=this._index))},e.prototype._stateInCloseingTagName=function(e){(">"===e||c(e))&&(this._emitToken("onclosetag"),this._state=7,this._index--)},e.prototype._stateAfterCloseingTagName=function(e){">"===e&&(this._state=1,this._sectionStart=this._index+1)},e.prototype._stateBeforeAttributeName=function(e){">"===e?(this._cbs.onopentagend(),this._state=1,this._sectionStart=this._index+1):"/"===e?this._state=4:c(e)||(this._state=9,this._sectionStart=this._index)},e.prototype._stateInSelfClosingTag=function(e){">"===e?(this._cbs.onselfclosingtag(),this._state=1,this._sectionStart=this._index+1):c(e)||(this._state=8,this._index--)},e.prototype._stateInAttributeName=function(e){("="===e||"/"===e||">"===e||c(e))&&(this._cbs.onattribname(this._getSection()),this._sectionStart=-1,this._state=10,this._index--)},e.prototype._stateAfterAttributeName=function(e){"="===e?this._state=11:"/"===e||">"===e?(this._cbs.onattribend(),this._state=8,this._index--):c(e)||(this._cbs.onattribend(),this._state=9,this._sectionStart=this._index)},e.prototype._stateBeforeAttributeValue=function(e){'"'===e?(this._state=12,this._sectionStart=this._index+1):"'"===e?(this._state=13,this._sectionStart=this._index+1):c(e)||(this._state=14,this._sectionStart=this._index,this._index--)},e.prototype._stateInAttributeValueDoubleQuotes=function(e){'"'===e?(this._emitToken("onattribdata"),this._cbs.onattribend(),this._state=8):this._decodeEntities&&"&"===e&&(this._emitToken("onattribdata"),this._baseState=this._state,this._state=51,this._sectionStart=this._index)},e.prototype._stateInAttributeValueSingleQuotes=function(e){"'"===e?(this._emitToken("onattribdata"),this._cbs.onattribend(),this._state=8):this._decodeEntities&&"&"===e&&(this._emitToken("onattribdata"),this._baseState=this._state,this._state=51,this._sectionStart=this._index)},e.prototype._stateInAttributeValueNoQuotes=function(e){c(e)||">"===e?(this._emitToken("onattribdata"),this._cbs.onattribend(),this._state=8,this._index--):this._decodeEntities&&"&"===e&&(this._emitToken("onattribdata"),this._baseState=this._state,this._state=51,this._sectionStart=this._index)},e.prototype._stateBeforeDeclaration=function(e){this._state="["===e?22:"-"===e?18:16},e.prototype._stateInDeclaration=function(e){">"===e&&(this._cbs.ondeclaration(this._getSection()),this._state=1,this._sectionStart=this._index+1)},e.prototype._stateInProcessingInstruction=function(e){">"===e&&(this._cbs.onprocessinginstruction(this._getSection()),this._state=1,this._sectionStart=this._index+1)},e.prototype._stateBeforeComment=function(e){"-"===e?(this._state=19,this._sectionStart=this._index+1):this._state=16},e.prototype._stateInComment=function(e){"-"===e&&(this._state=20)},e.prototype._stateAfterComment1=function(e){this._state="-"===e?21:19},e.prototype._stateAfterComment2=function(e){">"===e?(this._cbs.oncomment(this._buffer.substring(this._sectionStart,this._index-2)),this._state=1,this._sectionStart=this._index+1):"-"!==e&&(this._state=19)},e.prototype._stateBeforeCdata6=function(e){"["===e?(this._state=28,this._sectionStart=this._index+1):(this._state=16,this._index--)},e.prototype._stateInCdata=function(e){"]"===e&&(this._state=29)},e.prototype._stateAfterCdata1=function(e){this._state="]"===e?30:28},e.prototype._stateAfterCdata2=function(e){">"===e?(this._cbs.oncdata(this._buffer.substring(this._sectionStart,this._index-2)),this._state=1,this._sectionStart=this._index+1):"]"!==e&&(this._state=28)},e.prototype._stateBeforeSpecial=function(e){"c"===e||"C"===e?this._state=33:"t"===e||"T"===e?this._state=43:(this._state=3,this._index--)},e.prototype._stateBeforeSpecialEnd=function(e){2!==this._special||"c"!==e&&"C"!==e?3!==this._special||"t"!==e&&"T"!==e?this._state=1:this._state=47:this._state=38},e.prototype._stateBeforeScript5=function(e){("/"===e||">"===e||c(e))&&(this._special=2),this._state=3,this._index--},e.prototype._stateAfterScript5=function(e){">"===e||c(e)?(this._special=1,this._state=6,this._sectionStart=this._index-6,this._index--):this._state=1},e.prototype._stateBeforeStyle4=function(e){("/"===e||">"===e||c(e))&&(this._special=3),this._state=3,this._index--},e.prototype._stateAfterStyle4=function(e){">"===e||c(e)?(this._special=1,this._state=6,this._sectionStart=this._index-5,this._index--):this._state=1},e.prototype._parseNamedEntityStrict=function(){if(this._sectionStart+1<this._index){var e=this._buffer.substring(this._sectionStart+1,this._index),t=this._xmlMode?s.default:a.default;Object.prototype.hasOwnProperty.call(t,e)&&(this._emitPartial(t[e]),this._sectionStart=this._index+1)}},e.prototype._parseLegacyEntity=function(){var e=this._sectionStart+1,t=this._index-e;for(t>6&&(t=6);t>=2;){var r=this._buffer.substr(e,t);if(Object.prototype.hasOwnProperty.call(o.default,r))return this._emitPartial(o.default[r]),void(this._sectionStart+=t+1);t--}},e.prototype._stateInNamedEntity=function(e){";"===e?(this._parseNamedEntityStrict(),this._sectionStart+1<this._index&&!this._xmlMode&&this._parseLegacyEntity(),this._state=this._baseState):(e<"a"||e>"z")&&(e<"A"||e>"Z")&&(e<"0"||e>"9")&&(this._xmlMode||this._sectionStart+1===this._index||(1!==this._baseState?"="!==e&&this._parseNamedEntityStrict():this._parseLegacyEntity()),this._state=this._baseState,this._index--)},e.prototype._decodeNumericEntity=function(e,t){var r=this._sectionStart+e;if(r!==this._index){var n=this._buffer.substring(r,this._index),a=parseInt(n,t);this._emitPartial(i.default(a)),this._sectionStart=this._index}else this._sectionStart--;this._state=this._baseState},e.prototype._stateInNumericEntity=function(e){";"===e?(this._decodeNumericEntity(2,10),this._sectionStart++):(e<"0"||e>"9")&&(this._xmlMode?this._state=this._baseState:this._decodeNumericEntity(2,10),this._index--)},e.prototype._stateInHexEntity=function(e){";"===e?(this._decodeNumericEntity(3,16),this._sectionStart++):(e<"a"||e>"f")&&(e<"A"||e>"F")&&(e<"0"||e>"9")&&(this._xmlMode?this._state=this._baseState:this._decodeNumericEntity(3,16),this._index--)},e.prototype._cleanup=function(){this._sectionStart<0?(this._buffer="",this._bufferOffset+=this._index,this._index=0):this._running&&(1===this._state?(this._sectionStart!==this._index&&this._cbs.ontext(this._buffer.substr(this._sectionStart)),this._buffer="",this._bufferOffset+=this._index,this._index=0):this._sectionStart===this._index?(this._buffer="",this._bufferOffset+=this._index,this._index=0):(this._buffer=this._buffer.substr(this._sectionStart),this._index-=this._sectionStart,this._bufferOffset+=this._sectionStart),this._sectionStart=0)},e.prototype.write=function(e){this._ended&&this._cbs.onerror(Error(".write() after done!")),this._buffer+=e,this._parse()},e.prototype._parse=function(){for(;this._index<this._buffer.length&&this._running;){var e=this._buffer.charAt(this._index);1===this._state?this._stateText(e):12===this._state?this._stateInAttributeValueDoubleQuotes(e):9===this._state?this._stateInAttributeName(e):19===this._state?this._stateInComment(e):8===this._state?this._stateBeforeAttributeName(e):3===this._state?this._stateInTagName(e):6===this._state?this._stateInCloseingTagName(e):2===this._state?this._stateBeforeTagName(e):10===this._state?this._stateAfterAttributeName(e):13===this._state?this._stateInAttributeValueSingleQuotes(e):11===this._state?this._stateBeforeAttributeValue(e):5===this._state?this._stateBeforeCloseingTagName(e):7===this._state?this._stateAfterCloseingTagName(e):31===this._state?this._stateBeforeSpecial(e):20===this._state?this._stateAfterComment1(e):14===this._state?this._stateInAttributeValueNoQuotes(e):4===this._state?this._stateInSelfClosingTag(e):16===this._state?this._stateInDeclaration(e):15===this._state?this._stateBeforeDeclaration(e):21===this._state?this._stateAfterComment2(e):18===this._state?this._stateBeforeComment(e):32===this._state?this._stateBeforeSpecialEnd(e):38===this._state?_(this,e):39===this._state?w(this,e):40===this._state?S(this,e):33===this._state?m(this,e):34===this._state?g(this,e):35===this._state?b(this,e):36===this._state?v(this,e):37===this._state?this._stateBeforeScript5(e):41===this._state?E(this,e):42===this._state?this._stateAfterScript5(e):43===this._state?x(this,e):28===this._state?this._stateInCdata(e):44===this._state?T(this,e):45===this._state?O(this,e):46===this._state?this._stateBeforeStyle4(e):47===this._state?A(this,e):48===this._state?I(this,e):49===this._state?N(this,e):50===this._state?this._stateAfterStyle4(e):17===this._state?this._stateInProcessingInstruction(e):53===this._state?this._stateInNamedEntity(e):22===this._state?f(this,e):51===this._state?R(this,e):23===this._state?d(this,e):24===this._state?h(this,e):29===this._state?this._stateAfterCdata1(e):30===this._state?this._stateAfterCdata2(e):25===this._state?p(this,e):26===this._state?y(this,e):27===this._state?this._stateBeforeCdata6(e):55===this._state?this._stateInHexEntity(e):54===this._state?this._stateInNumericEntity(e):52===this._state?k(this,e):this._cbs.onerror(Error("unknown _state"),this._state),this._index++}this._cleanup()},e.prototype.pause=function(){this._running=!1},e.prototype.resume=function(){this._running=!0,this._index<this._buffer.length&&this._parse(),this._ended&&this._finish()},e.prototype.end=function(e){this._ended&&this._cbs.onerror(Error(".end() after done!")),e&&this.write(e),this._ended=!0,this._running&&this._finish()},e.prototype._finish=function(){this._sectionStart<this._index&&this._handleTrailingData(),this._cbs.onend()},e.prototype._handleTrailingData=function(){var e=this._buffer.substr(this._sectionStart);28===this._state||29===this._state||30===this._state?this._cbs.oncdata(e):19===this._state||20===this._state||21===this._state?this._cbs.oncomment(e):53!==this._state||this._xmlMode?54!==this._state||this._xmlMode?55!==this._state||this._xmlMode?3!==this._state&&8!==this._state&&11!==this._state&&10!==this._state&&9!==this._state&&13!==this._state&&12!==this._state&&14!==this._state&&6!==this._state&&this._cbs.ontext(e):(this._decodeNumericEntity(3,16),this._sectionStart<this._index&&(this._state=this._baseState,this._handleTrailingData())):(this._decodeNumericEntity(2,10),this._sectionStart<this._index&&(this._state=this._baseState,this._handleTrailingData())):(this._parseLegacyEntity(),this._sectionStart<this._index&&(this._state=this._baseState,this._handleTrailingData()))},e.prototype.getAbsoluteIndex=function(){return this._bufferOffset+this._index},e.prototype._getSection=function(){return this._buffer.substring(this._sectionStart,this._index)},e.prototype._emitToken=function(e){this._cbs[e](this._getSection()),this._sectionStart=-1},e.prototype._emitPartial=function(e){1!==this._baseState?this._cbs.onattribdata(e):this._cbs.ontext(e)},e}();t.default=P},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(390);t.Node=n.Node,t.Element=n.Element,t.DataNode=n.DataNode,t.NodeWithChildren=n.NodeWithChildren;var i=/\s+/g,a={normalizeWhitespace:!1,withStartIndices:!1,withEndIndices:!1},o=function(){function e(e,t,r){this.dom=[],this._done=!1,this._tagStack=[],this._lastNode=null,this._parser=null,"function"==typeof t&&(r=t,t=a),"object"==typeof e&&(t=e,e=void 0),this._callback=e||null,this._options=t||a,this._elementCB=r||null}return e.prototype.onparserinit=function(e){this._parser=e},e.prototype.onreset=function(){this.dom=[],this._done=!1,this._tagStack=[],this._lastNode=null,this._parser=this._parser||null},e.prototype.onend=function(){this._done||(this._done=!0,this._parser=null,this.handleCallback(null))},e.prototype.onerror=function(e){this.handleCallback(e)},e.prototype.onclosetag=function(){this._lastNode=null;var e=this._tagStack.pop();e&&this._parser&&(this._options.withEndIndices&&(e.endIndex=this._parser.endIndex),this._elementCB&&this._elementCB(e))},e.prototype.onopentag=function(e,t){var r=new n.Element(e,t);this.addNode(r),this._tagStack.push(r)},e.prototype.ontext=function(e){var t=this._options.normalizeWhitespace,r=this._lastNode;if(r&&"text"===r.type)t?r.data=(r.data+e).replace(i," "):r.data+=e;else{t&&(e=e.replace(i," "));var a=new n.DataNode("text",e);this.addNode(a),this._lastNode=a}},e.prototype.oncomment=function(e){if(this._lastNode&&"comment"===this._lastNode.type)this._lastNode.data+=e;else{var t=new n.DataNode("comment",e);this.addNode(t),this._lastNode=t}},e.prototype.oncommentend=function(){this._lastNode=null},e.prototype.oncdatastart=function(){var e=new n.DataNode("text",""),t=new n.NodeWithChildren("cdata",[e]);this.addNode(t),e.parent=t,this._lastNode=e},e.prototype.oncdataend=function(){this._lastNode=null},e.prototype.onprocessinginstruction=function(e,t){var r=new n.ProcessingInstruction(e,t);this.addNode(r)},e.prototype.handleCallback=function(e){if("function"==typeof this._callback)this._callback(e,this.dom);else if(e)throw e},e.prototype.addNode=function(e){var t=this._tagStack[this._tagStack.length-1],r=t?t.children:this.dom,n=r[r.length-1];this._parser&&(this._options.withStartIndices&&(e.startIndex=this._parser.startIndex),this._options.withEndIndices&&(e.endIndex=this._parser.endIndex)),r.push(e),n&&(e.prev=n,n.next=e),t&&(e.parent=t),this._lastNode=null},e.prototype.addDataNode=function(e){this.addNode(e),this._lastNode=e},e}();t.DomHandler=o,t.default=o},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isTag=function(e){return"tag"===e.type||"script"===e.type||"style"===e.type},t.Text="text",t.Directive="directive",t.Comment="comment",t.Script="script",t.Style="style",t.Tag="tag",t.CDATA="cdata",t.Doctype="doctype"},function(e,t,r){"use strict";var n,i=this&&this.__extends||(n=function(e,t){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)}),a=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}},o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)Object.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t.default=e,t};Object.defineProperty(t,"__esModule",{value:!0});var s=a(r(166)),c=o(r(169)),u=r(164),l=function(e){function t(t,r){return"object"==typeof t&&null!==t&&(r=t=void 0),e.call(this,t,r)||this}return i(t,e),t.prototype.onend=function(){var e={},t=d(m,this.dom);if(t)if("feed"===t.name){var r=t.children;e.type="atom",y(e,"id","id",r),y(e,"title","title",r);var n=p("href",d("link",r));n&&(e.link=n),y(e,"description","subtitle",r),(i=h("updated",r))&&(e.updated=new Date(i)),y(e,"author","email",r,!0),e.items=f("entry",r).map(function(e){var t={},r=e.children;y(t,"id","id",r),y(t,"title","title",r);var n=p("href",d("link",r));n&&(t.link=n);var i=h("summary",r)||h("content",r);i&&(t.description=i);var a=h("updated",r);return a&&(t.pubDate=new Date(a)),t})}else{var i;r=d("channel",t.children).children;e.type=t.name.substr(0,3),e.id="",y(e,"title","title",r),y(e,"link","link",r),y(e,"description","description",r),(i=h("lastBuildDate",r))&&(e.updated=new Date(i)),y(e,"author","managingEditor",r,!0),e.items=f("item",t.children).map(function(e){var t={},r=e.children;y(t,"id","guid",r),y(t,"title","title",r),y(t,"link","link",r),y(t,"description","description",r);var n=h("pubDate",r);return n&&(t.pubDate=new Date(n)),t})}this.feed=e,this.handleCallback(t?null:Error("couldn't find root of feed"))},t}(s.default);function f(e,t){return c.getElementsByTagName(e,t,!0)}function d(e,t){return c.getElementsByTagName(e,t,!0,1)[0]}function h(e,t,r){return void 0===r&&(r=!1),c.getText(c.getElementsByTagName(e,t,r,1)).trim()}function p(e,t){return t?t.attribs[e]:null}function y(e,t,r,n,i){void 0===i&&(i=!1);var a=h(r,n,i);a&&(e[t]=a)}function m(e){return"rss"===e||"feed"===e||"rdf:RDF"===e}t.FeedHandler=l;var g={xmlMode:!0};t.parseFeed=function(e,t){void 0===t&&(t=g);var r=new l(t);return new u.Parser(r,t).end(e),r.feed}},function(e,t,r){"use strict";function n(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}Object.defineProperty(t,"__esModule",{value:!0}),n(r(391)),n(r(398)),n(r(399)),n(r(175)),n(r(400)),n(r(401)),n(r(55))},function(e,t,r){var n=r(392),i=r(393),a=r(397);a.elementNames.__proto__=null,a.attributeNames.__proto__=null;var o={__proto__:null,style:!0,script:!0,xmp:!0,iframe:!0,noembed:!0,noframes:!0,plaintext:!0,noscript:!0};var s={__proto__:null,area:!0,base:!0,basefont:!0,br:!0,col:!0,command:!0,embed:!0,frame:!0,hr:!0,img:!0,input:!0,isindex:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0},c=e.exports=function(e,t){Array.isArray(e)||e.cheerio||(e=[e]),t=t||{};for(var r="",i=0;i<e.length;i++){var a=e[i];"root"===a.type?r+=c(a.children,t):n.isTag(a)?r+=l(a,t):a.type===n.Directive?r+=f(a):a.type===n.Comment?r+=p(a):a.type===n.CDATA?r+=h(a):r+=d(a,t)}return r};const u=["mi","mo","mn","ms","mtext","annotation-xml","foreignObject","desc","title"];function l(e,t){"foreign"===t.xmlMode&&(e.name=a.elementNames[e.name]||e.name,e.parent&&u.indexOf(e.parent.name)>=0&&(t=Object.assign({},t,{xmlMode:!1}))),!t.xmlMode&&["svg","math"].indexOf(e.name)>=0&&(t=Object.assign({},t,{xmlMode:"foreign"}));var r="<"+e.name,n=function(e,t){if(e){var r,n="";for(var o in e)r=e[o],n&&(n+=" "),"foreign"===t.xmlMode&&(o=a.attributeNames[o]||o),n+=o,(null!==r&&""!==r||t.xmlMode)&&(n+='="'+(t.decodeEntities?i.encodeXML(r):r.replace(/\"/g,"&quot;"))+'"');return n}}(e.attribs,t);return n&&(r+=" "+n),!t.xmlMode||e.children&&0!==e.children.length?(r+=">",e.children&&(r+=c(e.children,t)),s[e.name]&&!t.xmlMode||(r+="</"+e.name+">")):r+="/>",r}function f(e){return"<"+e.data+">"}function d(e,t){var r=e.data||"";return!t.decodeEntities||e.parent&&e.parent.name in o||(r=i.encodeXML(r)),r}function h(e){return"<![CDATA["+e.children[0].data+"]]>"}function p(e){return"\x3c!--"+e.data+"--\x3e"}},function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var i=n(r(172)),a=n(r(394)),o=n(r(173)),s=n(r(395));function c(e){var t=Object.keys(e).join("|"),r=l(e),n=new RegExp("&(?:"+(t+="|#[xX][\\da-fA-F]+|#\\d+")+");","g");return function(e){return String(e).replace(n,r)}}t.decodeXML=c(o.default),t.decodeHTMLStrict=c(i.default);var u=function(e,t){return e<t?1:-1};function l(e){return function(t){return"#"===t.charAt(1)?"X"===t.charAt(2)||"x"===t.charAt(2)?s.default(parseInt(t.substr(3),16)):s.default(parseInt(t.substr(2),10)):e[t.slice(1,-1)]}}t.decodeHTML=function(){for(var e=Object.keys(a.default).sort(u),t=Object.keys(i.default).sort(u),r=0,n=0;r<t.length;r++)e[n]===t[r]?(t[r]+=";?",n++):t[r]+=";";var o=new RegExp("&(?:"+t.join("|")+"|#[xX][\\da-fA-F]+;?|#\\d+;?)","g"),s=l(i.default);function c(e){return";"!==e.substr(-1)&&(e+=";"),s(e)}return function(e){return String(e).replace(o,c)}}()},function(e){e.exports=JSON.parse('{"Aacute":"Á","aacute":"á","Abreve":"Ă","abreve":"ă","ac":"∾","acd":"∿","acE":"∾̳","Acirc":"Â","acirc":"â","acute":"´","Acy":"А","acy":"а","AElig":"Æ","aelig":"æ","af":"⁡","Afr":"𝔄","afr":"𝔞","Agrave":"À","agrave":"à","alefsym":"ℵ","aleph":"ℵ","Alpha":"Α","alpha":"α","Amacr":"Ā","amacr":"ā","amalg":"⨿","amp":"&","AMP":"&","andand":"⩕","And":"⩓","and":"∧","andd":"⩜","andslope":"⩘","andv":"⩚","ang":"∠","ange":"⦤","angle":"∠","angmsdaa":"⦨","angmsdab":"⦩","angmsdac":"⦪","angmsdad":"⦫","angmsdae":"⦬","angmsdaf":"⦭","angmsdag":"⦮","angmsdah":"⦯","angmsd":"∡","angrt":"∟","angrtvb":"⊾","angrtvbd":"⦝","angsph":"∢","angst":"Å","angzarr":"⍼","Aogon":"Ą","aogon":"ą","Aopf":"𝔸","aopf":"𝕒","apacir":"⩯","ap":"≈","apE":"⩰","ape":"≊","apid":"≋","apos":"\'","ApplyFunction":"⁡","approx":"≈","approxeq":"≊","Aring":"Å","aring":"å","Ascr":"𝒜","ascr":"𝒶","Assign":"≔","ast":"*","asymp":"≈","asympeq":"≍","Atilde":"Ã","atilde":"ã","Auml":"Ä","auml":"ä","awconint":"∳","awint":"⨑","backcong":"≌","backepsilon":"϶","backprime":"‵","backsim":"∽","backsimeq":"⋍","Backslash":"∖","Barv":"⫧","barvee":"⊽","barwed":"⌅","Barwed":"⌆","barwedge":"⌅","bbrk":"⎵","bbrktbrk":"⎶","bcong":"≌","Bcy":"Б","bcy":"б","bdquo":"„","becaus":"∵","because":"∵","Because":"∵","bemptyv":"⦰","bepsi":"϶","bernou":"ℬ","Bernoullis":"ℬ","Beta":"Β","beta":"β","beth":"ℶ","between":"≬","Bfr":"𝔅","bfr":"𝔟","bigcap":"⋂","bigcirc":"◯","bigcup":"⋃","bigodot":"⨀","bigoplus":"⨁","bigotimes":"⨂","bigsqcup":"⨆","bigstar":"★","bigtriangledown":"▽","bigtriangleup":"△","biguplus":"⨄","bigvee":"⋁","bigwedge":"⋀","bkarow":"⤍","blacklozenge":"⧫","blacksquare":"▪","blacktriangle":"▴","blacktriangledown":"▾","blacktriangleleft":"◂","blacktriangleright":"▸","blank":"␣","blk12":"▒","blk14":"░","blk34":"▓","block":"█","bne":"=⃥","bnequiv":"≡⃥","bNot":"⫭","bnot":"⌐","Bopf":"𝔹","bopf":"𝕓","bot":"⊥","bottom":"⊥","bowtie":"⋈","boxbox":"⧉","boxdl":"┐","boxdL":"╕","boxDl":"╖","boxDL":"╗","boxdr":"┌","boxdR":"╒","boxDr":"╓","boxDR":"╔","boxh":"─","boxH":"═","boxhd":"┬","boxHd":"╤","boxhD":"╥","boxHD":"╦","boxhu":"┴","boxHu":"╧","boxhU":"╨","boxHU":"╩","boxminus":"⊟","boxplus":"⊞","boxtimes":"⊠","boxul":"┘","boxuL":"╛","boxUl":"╜","boxUL":"╝","boxur":"└","boxuR":"╘","boxUr":"╙","boxUR":"╚","boxv":"│","boxV":"║","boxvh":"┼","boxvH":"╪","boxVh":"╫","boxVH":"╬","boxvl":"┤","boxvL":"╡","boxVl":"╢","boxVL":"╣","boxvr":"├","boxvR":"╞","boxVr":"╟","boxVR":"╠","bprime":"‵","breve":"˘","Breve":"˘","brvbar":"¦","bscr":"𝒷","Bscr":"ℬ","bsemi":"⁏","bsim":"∽","bsime":"⋍","bsolb":"⧅","bsol":"\\\\","bsolhsub":"⟈","bull":"•","bullet":"•","bump":"≎","bumpE":"⪮","bumpe":"≏","Bumpeq":"≎","bumpeq":"≏","Cacute":"Ć","cacute":"ć","capand":"⩄","capbrcup":"⩉","capcap":"⩋","cap":"∩","Cap":"⋒","capcup":"⩇","capdot":"⩀","CapitalDifferentialD":"ⅅ","caps":"∩︀","caret":"⁁","caron":"ˇ","Cayleys":"ℭ","ccaps":"⩍","Ccaron":"Č","ccaron":"č","Ccedil":"Ç","ccedil":"ç","Ccirc":"Ĉ","ccirc":"ĉ","Cconint":"∰","ccups":"⩌","ccupssm":"⩐","Cdot":"Ċ","cdot":"ċ","cedil":"¸","Cedilla":"¸","cemptyv":"⦲","cent":"¢","centerdot":"·","CenterDot":"·","cfr":"𝔠","Cfr":"ℭ","CHcy":"Ч","chcy":"ч","check":"✓","checkmark":"✓","Chi":"Χ","chi":"χ","circ":"ˆ","circeq":"≗","circlearrowleft":"↺","circlearrowright":"↻","circledast":"⊛","circledcirc":"⊚","circleddash":"⊝","CircleDot":"⊙","circledR":"®","circledS":"Ⓢ","CircleMinus":"⊖","CirclePlus":"⊕","CircleTimes":"⊗","cir":"○","cirE":"⧃","cire":"≗","cirfnint":"⨐","cirmid":"⫯","cirscir":"⧂","ClockwiseContourIntegral":"∲","CloseCurlyDoubleQuote":"”","CloseCurlyQuote":"’","clubs":"♣","clubsuit":"♣","colon":":","Colon":"∷","Colone":"⩴","colone":"≔","coloneq":"≔","comma":",","commat":"@","comp":"∁","compfn":"∘","complement":"∁","complexes":"ℂ","cong":"≅","congdot":"⩭","Congruent":"≡","conint":"∮","Conint":"∯","ContourIntegral":"∮","copf":"𝕔","Copf":"ℂ","coprod":"∐","Coproduct":"∐","copy":"©","COPY":"©","copysr":"℗","CounterClockwiseContourIntegral":"∳","crarr":"↵","cross":"✗","Cross":"⨯","Cscr":"𝒞","cscr":"𝒸","csub":"⫏","csube":"⫑","csup":"⫐","csupe":"⫒","ctdot":"⋯","cudarrl":"⤸","cudarrr":"⤵","cuepr":"⋞","cuesc":"⋟","cularr":"↶","cularrp":"⤽","cupbrcap":"⩈","cupcap":"⩆","CupCap":"≍","cup":"∪","Cup":"⋓","cupcup":"⩊","cupdot":"⊍","cupor":"⩅","cups":"∪︀","curarr":"↷","curarrm":"⤼","curlyeqprec":"⋞","curlyeqsucc":"⋟","curlyvee":"⋎","curlywedge":"⋏","curren":"¤","curvearrowleft":"↶","curvearrowright":"↷","cuvee":"⋎","cuwed":"⋏","cwconint":"∲","cwint":"∱","cylcty":"⌭","dagger":"†","Dagger":"‡","daleth":"ℸ","darr":"↓","Darr":"↡","dArr":"⇓","dash":"‐","Dashv":"⫤","dashv":"⊣","dbkarow":"⤏","dblac":"˝","Dcaron":"Ď","dcaron":"ď","Dcy":"Д","dcy":"д","ddagger":"‡","ddarr":"⇊","DD":"ⅅ","dd":"ⅆ","DDotrahd":"⤑","ddotseq":"⩷","deg":"°","Del":"∇","Delta":"Δ","delta":"δ","demptyv":"⦱","dfisht":"⥿","Dfr":"𝔇","dfr":"𝔡","dHar":"⥥","dharl":"⇃","dharr":"⇂","DiacriticalAcute":"´","DiacriticalDot":"˙","DiacriticalDoubleAcute":"˝","DiacriticalGrave":"`","DiacriticalTilde":"˜","diam":"⋄","diamond":"⋄","Diamond":"⋄","diamondsuit":"♦","diams":"♦","die":"¨","DifferentialD":"ⅆ","digamma":"ϝ","disin":"⋲","div":"÷","divide":"÷","divideontimes":"⋇","divonx":"⋇","DJcy":"Ђ","djcy":"ђ","dlcorn":"⌞","dlcrop":"⌍","dollar":"$","Dopf":"𝔻","dopf":"𝕕","Dot":"¨","dot":"˙","DotDot":"⃜","doteq":"≐","doteqdot":"≑","DotEqual":"≐","dotminus":"∸","dotplus":"∔","dotsquare":"⊡","doublebarwedge":"⌆","DoubleContourIntegral":"∯","DoubleDot":"¨","DoubleDownArrow":"⇓","DoubleLeftArrow":"⇐","DoubleLeftRightArrow":"⇔","DoubleLeftTee":"⫤","DoubleLongLeftArrow":"⟸","DoubleLongLeftRightArrow":"⟺","DoubleLongRightArrow":"⟹","DoubleRightArrow":"⇒","DoubleRightTee":"⊨","DoubleUpArrow":"⇑","DoubleUpDownArrow":"⇕","DoubleVerticalBar":"∥","DownArrowBar":"⤓","downarrow":"↓","DownArrow":"↓","Downarrow":"⇓","DownArrowUpArrow":"⇵","DownBreve":"̑","downdownarrows":"⇊","downharpoonleft":"⇃","downharpoonright":"⇂","DownLeftRightVector":"⥐","DownLeftTeeVector":"⥞","DownLeftVectorBar":"⥖","DownLeftVector":"↽","DownRightTeeVector":"⥟","DownRightVectorBar":"⥗","DownRightVector":"⇁","DownTeeArrow":"↧","DownTee":"⊤","drbkarow":"⤐","drcorn":"⌟","drcrop":"⌌","Dscr":"𝒟","dscr":"𝒹","DScy":"Ѕ","dscy":"ѕ","dsol":"⧶","Dstrok":"Đ","dstrok":"đ","dtdot":"⋱","dtri":"▿","dtrif":"▾","duarr":"⇵","duhar":"⥯","dwangle":"⦦","DZcy":"Џ","dzcy":"џ","dzigrarr":"⟿","Eacute":"É","eacute":"é","easter":"⩮","Ecaron":"Ě","ecaron":"ě","Ecirc":"Ê","ecirc":"ê","ecir":"≖","ecolon":"≕","Ecy":"Э","ecy":"э","eDDot":"⩷","Edot":"Ė","edot":"ė","eDot":"≑","ee":"ⅇ","efDot":"≒","Efr":"𝔈","efr":"𝔢","eg":"⪚","Egrave":"È","egrave":"è","egs":"⪖","egsdot":"⪘","el":"⪙","Element":"∈","elinters":"⏧","ell":"ℓ","els":"⪕","elsdot":"⪗","Emacr":"Ē","emacr":"ē","empty":"∅","emptyset":"∅","EmptySmallSquare":"◻","emptyv":"∅","EmptyVerySmallSquare":"▫","emsp13":" ","emsp14":" ","emsp":" ","ENG":"Ŋ","eng":"ŋ","ensp":" ","Eogon":"Ę","eogon":"ę","Eopf":"𝔼","eopf":"𝕖","epar":"⋕","eparsl":"⧣","eplus":"⩱","epsi":"ε","Epsilon":"Ε","epsilon":"ε","epsiv":"ϵ","eqcirc":"≖","eqcolon":"≕","eqsim":"≂","eqslantgtr":"⪖","eqslantless":"⪕","Equal":"⩵","equals":"=","EqualTilde":"≂","equest":"≟","Equilibrium":"⇌","equiv":"≡","equivDD":"⩸","eqvparsl":"⧥","erarr":"⥱","erDot":"≓","escr":"ℯ","Escr":"ℰ","esdot":"≐","Esim":"⩳","esim":"≂","Eta":"Η","eta":"η","ETH":"Ð","eth":"ð","Euml":"Ë","euml":"ë","euro":"€","excl":"!","exist":"∃","Exists":"∃","expectation":"ℰ","exponentiale":"ⅇ","ExponentialE":"ⅇ","fallingdotseq":"≒","Fcy":"Ф","fcy":"ф","female":"♀","ffilig":"ffi","fflig":"ff","ffllig":"ffl","Ffr":"𝔉","ffr":"𝔣","filig":"fi","FilledSmallSquare":"◼","FilledVerySmallSquare":"▪","fjlig":"fj","flat":"♭","fllig":"fl","fltns":"▱","fnof":"ƒ","Fopf":"𝔽","fopf":"𝕗","forall":"∀","ForAll":"∀","fork":"⋔","forkv":"⫙","Fouriertrf":"ℱ","fpartint":"⨍","frac12":"½","frac13":"⅓","frac14":"¼","frac15":"⅕","frac16":"⅙","frac18":"⅛","frac23":"⅔","frac25":"⅖","frac34":"¾","frac35":"⅗","frac38":"⅜","frac45":"⅘","frac56":"⅚","frac58":"⅝","frac78":"⅞","frasl":"⁄","frown":"⌢","fscr":"𝒻","Fscr":"ℱ","gacute":"ǵ","Gamma":"Γ","gamma":"γ","Gammad":"Ϝ","gammad":"ϝ","gap":"⪆","Gbreve":"Ğ","gbreve":"ğ","Gcedil":"Ģ","Gcirc":"Ĝ","gcirc":"ĝ","Gcy":"Г","gcy":"г","Gdot":"Ġ","gdot":"ġ","ge":"≥","gE":"≧","gEl":"⪌","gel":"⋛","geq":"≥","geqq":"≧","geqslant":"⩾","gescc":"⪩","ges":"⩾","gesdot":"⪀","gesdoto":"⪂","gesdotol":"⪄","gesl":"⋛︀","gesles":"⪔","Gfr":"𝔊","gfr":"𝔤","gg":"≫","Gg":"⋙","ggg":"⋙","gimel":"ℷ","GJcy":"Ѓ","gjcy":"ѓ","gla":"⪥","gl":"≷","glE":"⪒","glj":"⪤","gnap":"⪊","gnapprox":"⪊","gne":"⪈","gnE":"≩","gneq":"⪈","gneqq":"≩","gnsim":"⋧","Gopf":"𝔾","gopf":"𝕘","grave":"`","GreaterEqual":"≥","GreaterEqualLess":"⋛","GreaterFullEqual":"≧","GreaterGreater":"⪢","GreaterLess":"≷","GreaterSlantEqual":"⩾","GreaterTilde":"≳","Gscr":"𝒢","gscr":"ℊ","gsim":"≳","gsime":"⪎","gsiml":"⪐","gtcc":"⪧","gtcir":"⩺","gt":">","GT":">","Gt":"≫","gtdot":"⋗","gtlPar":"⦕","gtquest":"⩼","gtrapprox":"⪆","gtrarr":"⥸","gtrdot":"⋗","gtreqless":"⋛","gtreqqless":"⪌","gtrless":"≷","gtrsim":"≳","gvertneqq":"≩︀","gvnE":"≩︀","Hacek":"ˇ","hairsp":" ","half":"½","hamilt":"ℋ","HARDcy":"Ъ","hardcy":"ъ","harrcir":"⥈","harr":"↔","hArr":"⇔","harrw":"↭","Hat":"^","hbar":"ℏ","Hcirc":"Ĥ","hcirc":"ĥ","hearts":"♥","heartsuit":"♥","hellip":"…","hercon":"⊹","hfr":"𝔥","Hfr":"ℌ","HilbertSpace":"ℋ","hksearow":"⤥","hkswarow":"⤦","hoarr":"⇿","homtht":"∻","hookleftarrow":"↩","hookrightarrow":"↪","hopf":"𝕙","Hopf":"ℍ","horbar":"―","HorizontalLine":"─","hscr":"𝒽","Hscr":"ℋ","hslash":"ℏ","Hstrok":"Ħ","hstrok":"ħ","HumpDownHump":"≎","HumpEqual":"≏","hybull":"⁃","hyphen":"‐","Iacute":"Í","iacute":"í","ic":"⁣","Icirc":"Î","icirc":"î","Icy":"И","icy":"и","Idot":"İ","IEcy":"Е","iecy":"е","iexcl":"¡","iff":"⇔","ifr":"𝔦","Ifr":"ℑ","Igrave":"Ì","igrave":"ì","ii":"ⅈ","iiiint":"⨌","iiint":"∭","iinfin":"⧜","iiota":"℩","IJlig":"IJ","ijlig":"ij","Imacr":"Ī","imacr":"ī","image":"ℑ","ImaginaryI":"ⅈ","imagline":"ℐ","imagpart":"ℑ","imath":"ı","Im":"ℑ","imof":"⊷","imped":"Ƶ","Implies":"⇒","incare":"℅","in":"∈","infin":"∞","infintie":"⧝","inodot":"ı","intcal":"⊺","int":"∫","Int":"∬","integers":"ℤ","Integral":"∫","intercal":"⊺","Intersection":"⋂","intlarhk":"⨗","intprod":"⨼","InvisibleComma":"⁣","InvisibleTimes":"⁢","IOcy":"Ё","iocy":"ё","Iogon":"Į","iogon":"į","Iopf":"𝕀","iopf":"𝕚","Iota":"Ι","iota":"ι","iprod":"⨼","iquest":"¿","iscr":"𝒾","Iscr":"ℐ","isin":"∈","isindot":"⋵","isinE":"⋹","isins":"⋴","isinsv":"⋳","isinv":"∈","it":"⁢","Itilde":"Ĩ","itilde":"ĩ","Iukcy":"І","iukcy":"і","Iuml":"Ï","iuml":"ï","Jcirc":"Ĵ","jcirc":"ĵ","Jcy":"Й","jcy":"й","Jfr":"𝔍","jfr":"𝔧","jmath":"ȷ","Jopf":"𝕁","jopf":"𝕛","Jscr":"𝒥","jscr":"𝒿","Jsercy":"Ј","jsercy":"ј","Jukcy":"Є","jukcy":"є","Kappa":"Κ","kappa":"κ","kappav":"ϰ","Kcedil":"Ķ","kcedil":"ķ","Kcy":"К","kcy":"к","Kfr":"𝔎","kfr":"𝔨","kgreen":"ĸ","KHcy":"Х","khcy":"х","KJcy":"Ќ","kjcy":"ќ","Kopf":"𝕂","kopf":"𝕜","Kscr":"𝒦","kscr":"𝓀","lAarr":"⇚","Lacute":"Ĺ","lacute":"ĺ","laemptyv":"⦴","lagran":"ℒ","Lambda":"Λ","lambda":"λ","lang":"⟨","Lang":"⟪","langd":"⦑","langle":"⟨","lap":"⪅","Laplacetrf":"ℒ","laquo":"«","larrb":"⇤","larrbfs":"⤟","larr":"←","Larr":"↞","lArr":"⇐","larrfs":"⤝","larrhk":"↩","larrlp":"↫","larrpl":"⤹","larrsim":"⥳","larrtl":"↢","latail":"⤙","lAtail":"⤛","lat":"⪫","late":"⪭","lates":"⪭︀","lbarr":"⤌","lBarr":"⤎","lbbrk":"❲","lbrace":"{","lbrack":"[","lbrke":"⦋","lbrksld":"⦏","lbrkslu":"⦍","Lcaron":"Ľ","lcaron":"ľ","Lcedil":"Ļ","lcedil":"ļ","lceil":"⌈","lcub":"{","Lcy":"Л","lcy":"л","ldca":"⤶","ldquo":"“","ldquor":"„","ldrdhar":"⥧","ldrushar":"⥋","ldsh":"↲","le":"≤","lE":"≦","LeftAngleBracket":"⟨","LeftArrowBar":"⇤","leftarrow":"←","LeftArrow":"←","Leftarrow":"⇐","LeftArrowRightArrow":"⇆","leftarrowtail":"↢","LeftCeiling":"⌈","LeftDoubleBracket":"⟦","LeftDownTeeVector":"⥡","LeftDownVectorBar":"⥙","LeftDownVector":"⇃","LeftFloor":"⌊","leftharpoondown":"↽","leftharpoonup":"↼","leftleftarrows":"⇇","leftrightarrow":"↔","LeftRightArrow":"↔","Leftrightarrow":"⇔","leftrightarrows":"⇆","leftrightharpoons":"⇋","leftrightsquigarrow":"↭","LeftRightVector":"⥎","LeftTeeArrow":"↤","LeftTee":"⊣","LeftTeeVector":"⥚","leftthreetimes":"⋋","LeftTriangleBar":"⧏","LeftTriangle":"⊲","LeftTriangleEqual":"⊴","LeftUpDownVector":"⥑","LeftUpTeeVector":"⥠","LeftUpVectorBar":"⥘","LeftUpVector":"↿","LeftVectorBar":"⥒","LeftVector":"↼","lEg":"⪋","leg":"⋚","leq":"≤","leqq":"≦","leqslant":"⩽","lescc":"⪨","les":"⩽","lesdot":"⩿","lesdoto":"⪁","lesdotor":"⪃","lesg":"⋚︀","lesges":"⪓","lessapprox":"⪅","lessdot":"⋖","lesseqgtr":"⋚","lesseqqgtr":"⪋","LessEqualGreater":"⋚","LessFullEqual":"≦","LessGreater":"≶","lessgtr":"≶","LessLess":"⪡","lesssim":"≲","LessSlantEqual":"⩽","LessTilde":"≲","lfisht":"⥼","lfloor":"⌊","Lfr":"𝔏","lfr":"𝔩","lg":"≶","lgE":"⪑","lHar":"⥢","lhard":"↽","lharu":"↼","lharul":"⥪","lhblk":"▄","LJcy":"Љ","ljcy":"љ","llarr":"⇇","ll":"≪","Ll":"⋘","llcorner":"⌞","Lleftarrow":"⇚","llhard":"⥫","lltri":"◺","Lmidot":"Ŀ","lmidot":"ŀ","lmoustache":"⎰","lmoust":"⎰","lnap":"⪉","lnapprox":"⪉","lne":"⪇","lnE":"≨","lneq":"⪇","lneqq":"≨","lnsim":"⋦","loang":"⟬","loarr":"⇽","lobrk":"⟦","longleftarrow":"⟵","LongLeftArrow":"⟵","Longleftarrow":"⟸","longleftrightarrow":"⟷","LongLeftRightArrow":"⟷","Longleftrightarrow":"⟺","longmapsto":"⟼","longrightarrow":"⟶","LongRightArrow":"⟶","Longrightarrow":"⟹","looparrowleft":"↫","looparrowright":"↬","lopar":"⦅","Lopf":"𝕃","lopf":"𝕝","loplus":"⨭","lotimes":"⨴","lowast":"∗","lowbar":"_","LowerLeftArrow":"↙","LowerRightArrow":"↘","loz":"◊","lozenge":"◊","lozf":"⧫","lpar":"(","lparlt":"⦓","lrarr":"⇆","lrcorner":"⌟","lrhar":"⇋","lrhard":"⥭","lrm":"‎","lrtri":"⊿","lsaquo":"‹","lscr":"𝓁","Lscr":"ℒ","lsh":"↰","Lsh":"↰","lsim":"≲","lsime":"⪍","lsimg":"⪏","lsqb":"[","lsquo":"‘","lsquor":"‚","Lstrok":"Ł","lstrok":"ł","ltcc":"⪦","ltcir":"⩹","lt":"<","LT":"<","Lt":"≪","ltdot":"⋖","lthree":"⋋","ltimes":"⋉","ltlarr":"⥶","ltquest":"⩻","ltri":"◃","ltrie":"⊴","ltrif":"◂","ltrPar":"⦖","lurdshar":"⥊","luruhar":"⥦","lvertneqq":"≨︀","lvnE":"≨︀","macr":"¯","male":"♂","malt":"✠","maltese":"✠","Map":"⤅","map":"↦","mapsto":"↦","mapstodown":"↧","mapstoleft":"↤","mapstoup":"↥","marker":"▮","mcomma":"⨩","Mcy":"М","mcy":"м","mdash":"—","mDDot":"∺","measuredangle":"∡","MediumSpace":" ","Mellintrf":"ℳ","Mfr":"𝔐","mfr":"𝔪","mho":"℧","micro":"µ","midast":"*","midcir":"⫰","mid":"∣","middot":"·","minusb":"⊟","minus":"−","minusd":"∸","minusdu":"⨪","MinusPlus":"∓","mlcp":"⫛","mldr":"…","mnplus":"∓","models":"⊧","Mopf":"𝕄","mopf":"𝕞","mp":"∓","mscr":"𝓂","Mscr":"ℳ","mstpos":"∾","Mu":"Μ","mu":"μ","multimap":"⊸","mumap":"⊸","nabla":"∇","Nacute":"Ń","nacute":"ń","nang":"∠⃒","nap":"≉","napE":"⩰̸","napid":"≋̸","napos":"ʼn","napprox":"≉","natural":"♮","naturals":"ℕ","natur":"♮","nbsp":" ","nbump":"≎̸","nbumpe":"≏̸","ncap":"⩃","Ncaron":"Ň","ncaron":"ň","Ncedil":"Ņ","ncedil":"ņ","ncong":"≇","ncongdot":"⩭̸","ncup":"⩂","Ncy":"Н","ncy":"н","ndash":"–","nearhk":"⤤","nearr":"↗","neArr":"⇗","nearrow":"↗","ne":"≠","nedot":"≐̸","NegativeMediumSpace":"​","NegativeThickSpace":"​","NegativeThinSpace":"​","NegativeVeryThinSpace":"​","nequiv":"≢","nesear":"⤨","nesim":"≂̸","NestedGreaterGreater":"≫","NestedLessLess":"≪","NewLine":"\\n","nexist":"∄","nexists":"∄","Nfr":"𝔑","nfr":"𝔫","ngE":"≧̸","nge":"≱","ngeq":"≱","ngeqq":"≧̸","ngeqslant":"⩾̸","nges":"⩾̸","nGg":"⋙̸","ngsim":"≵","nGt":"≫⃒","ngt":"≯","ngtr":"≯","nGtv":"≫̸","nharr":"↮","nhArr":"⇎","nhpar":"⫲","ni":"∋","nis":"⋼","nisd":"⋺","niv":"∋","NJcy":"Њ","njcy":"њ","nlarr":"↚","nlArr":"⇍","nldr":"‥","nlE":"≦̸","nle":"≰","nleftarrow":"↚","nLeftarrow":"⇍","nleftrightarrow":"↮","nLeftrightarrow":"⇎","nleq":"≰","nleqq":"≦̸","nleqslant":"⩽̸","nles":"⩽̸","nless":"≮","nLl":"⋘̸","nlsim":"≴","nLt":"≪⃒","nlt":"≮","nltri":"⋪","nltrie":"⋬","nLtv":"≪̸","nmid":"∤","NoBreak":"⁠","NonBreakingSpace":" ","nopf":"𝕟","Nopf":"ℕ","Not":"⫬","not":"¬","NotCongruent":"≢","NotCupCap":"≭","NotDoubleVerticalBar":"∦","NotElement":"∉","NotEqual":"≠","NotEqualTilde":"≂̸","NotExists":"∄","NotGreater":"≯","NotGreaterEqual":"≱","NotGreaterFullEqual":"≧̸","NotGreaterGreater":"≫̸","NotGreaterLess":"≹","NotGreaterSlantEqual":"⩾̸","NotGreaterTilde":"≵","NotHumpDownHump":"≎̸","NotHumpEqual":"≏̸","notin":"∉","notindot":"⋵̸","notinE":"⋹̸","notinva":"∉","notinvb":"⋷","notinvc":"⋶","NotLeftTriangleBar":"⧏̸","NotLeftTriangle":"⋪","NotLeftTriangleEqual":"⋬","NotLess":"≮","NotLessEqual":"≰","NotLessGreater":"≸","NotLessLess":"≪̸","NotLessSlantEqual":"⩽̸","NotLessTilde":"≴","NotNestedGreaterGreater":"⪢̸","NotNestedLessLess":"⪡̸","notni":"∌","notniva":"∌","notnivb":"⋾","notnivc":"⋽","NotPrecedes":"⊀","NotPrecedesEqual":"⪯̸","NotPrecedesSlantEqual":"⋠","NotReverseElement":"∌","NotRightTriangleBar":"⧐̸","NotRightTriangle":"⋫","NotRightTriangleEqual":"⋭","NotSquareSubset":"⊏̸","NotSquareSubsetEqual":"⋢","NotSquareSuperset":"⊐̸","NotSquareSupersetEqual":"⋣","NotSubset":"⊂⃒","NotSubsetEqual":"⊈","NotSucceeds":"⊁","NotSucceedsEqual":"⪰̸","NotSucceedsSlantEqual":"⋡","NotSucceedsTilde":"≿̸","NotSuperset":"⊃⃒","NotSupersetEqual":"⊉","NotTilde":"≁","NotTildeEqual":"≄","NotTildeFullEqual":"≇","NotTildeTilde":"≉","NotVerticalBar":"∤","nparallel":"∦","npar":"∦","nparsl":"⫽⃥","npart":"∂̸","npolint":"⨔","npr":"⊀","nprcue":"⋠","nprec":"⊀","npreceq":"⪯̸","npre":"⪯̸","nrarrc":"⤳̸","nrarr":"↛","nrArr":"⇏","nrarrw":"↝̸","nrightarrow":"↛","nRightarrow":"⇏","nrtri":"⋫","nrtrie":"⋭","nsc":"⊁","nsccue":"⋡","nsce":"⪰̸","Nscr":"𝒩","nscr":"𝓃","nshortmid":"∤","nshortparallel":"∦","nsim":"≁","nsime":"≄","nsimeq":"≄","nsmid":"∤","nspar":"∦","nsqsube":"⋢","nsqsupe":"⋣","nsub":"⊄","nsubE":"⫅̸","nsube":"⊈","nsubset":"⊂⃒","nsubseteq":"⊈","nsubseteqq":"⫅̸","nsucc":"⊁","nsucceq":"⪰̸","nsup":"⊅","nsupE":"⫆̸","nsupe":"⊉","nsupset":"⊃⃒","nsupseteq":"⊉","nsupseteqq":"⫆̸","ntgl":"≹","Ntilde":"Ñ","ntilde":"ñ","ntlg":"≸","ntriangleleft":"⋪","ntrianglelefteq":"⋬","ntriangleright":"⋫","ntrianglerighteq":"⋭","Nu":"Ν","nu":"ν","num":"#","numero":"№","numsp":" ","nvap":"≍⃒","nvdash":"⊬","nvDash":"⊭","nVdash":"⊮","nVDash":"⊯","nvge":"≥⃒","nvgt":">⃒","nvHarr":"⤄","nvinfin":"⧞","nvlArr":"⤂","nvle":"≤⃒","nvlt":"<⃒","nvltrie":"⊴⃒","nvrArr":"⤃","nvrtrie":"⊵⃒","nvsim":"∼⃒","nwarhk":"⤣","nwarr":"↖","nwArr":"⇖","nwarrow":"↖","nwnear":"⤧","Oacute":"Ó","oacute":"ó","oast":"⊛","Ocirc":"Ô","ocirc":"ô","ocir":"⊚","Ocy":"О","ocy":"о","odash":"⊝","Odblac":"Ő","odblac":"ő","odiv":"⨸","odot":"⊙","odsold":"⦼","OElig":"Œ","oelig":"œ","ofcir":"⦿","Ofr":"𝔒","ofr":"𝔬","ogon":"˛","Ograve":"Ò","ograve":"ò","ogt":"⧁","ohbar":"⦵","ohm":"Ω","oint":"∮","olarr":"↺","olcir":"⦾","olcross":"⦻","oline":"‾","olt":"⧀","Omacr":"Ō","omacr":"ō","Omega":"Ω","omega":"ω","Omicron":"Ο","omicron":"ο","omid":"⦶","ominus":"⊖","Oopf":"𝕆","oopf":"𝕠","opar":"⦷","OpenCurlyDoubleQuote":"“","OpenCurlyQuote":"‘","operp":"⦹","oplus":"⊕","orarr":"↻","Or":"⩔","or":"∨","ord":"⩝","order":"ℴ","orderof":"ℴ","ordf":"ª","ordm":"º","origof":"⊶","oror":"⩖","orslope":"⩗","orv":"⩛","oS":"Ⓢ","Oscr":"𝒪","oscr":"ℴ","Oslash":"Ø","oslash":"ø","osol":"⊘","Otilde":"Õ","otilde":"õ","otimesas":"⨶","Otimes":"⨷","otimes":"⊗","Ouml":"Ö","ouml":"ö","ovbar":"⌽","OverBar":"‾","OverBrace":"⏞","OverBracket":"⎴","OverParenthesis":"⏜","para":"¶","parallel":"∥","par":"∥","parsim":"⫳","parsl":"⫽","part":"∂","PartialD":"∂","Pcy":"П","pcy":"п","percnt":"%","period":".","permil":"‰","perp":"⊥","pertenk":"‱","Pfr":"𝔓","pfr":"𝔭","Phi":"Φ","phi":"φ","phiv":"ϕ","phmmat":"ℳ","phone":"☎","Pi":"Π","pi":"π","pitchfork":"⋔","piv":"ϖ","planck":"ℏ","planckh":"ℎ","plankv":"ℏ","plusacir":"⨣","plusb":"⊞","pluscir":"⨢","plus":"+","plusdo":"∔","plusdu":"⨥","pluse":"⩲","PlusMinus":"±","plusmn":"±","plussim":"⨦","plustwo":"⨧","pm":"±","Poincareplane":"ℌ","pointint":"⨕","popf":"𝕡","Popf":"ℙ","pound":"£","prap":"⪷","Pr":"⪻","pr":"≺","prcue":"≼","precapprox":"⪷","prec":"≺","preccurlyeq":"≼","Precedes":"≺","PrecedesEqual":"⪯","PrecedesSlantEqual":"≼","PrecedesTilde":"≾","preceq":"⪯","precnapprox":"⪹","precneqq":"⪵","precnsim":"⋨","pre":"⪯","prE":"⪳","precsim":"≾","prime":"′","Prime":"″","primes":"ℙ","prnap":"⪹","prnE":"⪵","prnsim":"⋨","prod":"∏","Product":"∏","profalar":"⌮","profline":"⌒","profsurf":"⌓","prop":"∝","Proportional":"∝","Proportion":"∷","propto":"∝","prsim":"≾","prurel":"⊰","Pscr":"𝒫","pscr":"𝓅","Psi":"Ψ","psi":"ψ","puncsp":" ","Qfr":"𝔔","qfr":"𝔮","qint":"⨌","qopf":"𝕢","Qopf":"ℚ","qprime":"⁗","Qscr":"𝒬","qscr":"𝓆","quaternions":"ℍ","quatint":"⨖","quest":"?","questeq":"≟","quot":"\\"","QUOT":"\\"","rAarr":"⇛","race":"∽̱","Racute":"Ŕ","racute":"ŕ","radic":"√","raemptyv":"⦳","rang":"⟩","Rang":"⟫","rangd":"⦒","range":"⦥","rangle":"⟩","raquo":"»","rarrap":"⥵","rarrb":"⇥","rarrbfs":"⤠","rarrc":"⤳","rarr":"→","Rarr":"↠","rArr":"⇒","rarrfs":"⤞","rarrhk":"↪","rarrlp":"↬","rarrpl":"⥅","rarrsim":"⥴","Rarrtl":"⤖","rarrtl":"↣","rarrw":"↝","ratail":"⤚","rAtail":"⤜","ratio":"∶","rationals":"ℚ","rbarr":"⤍","rBarr":"⤏","RBarr":"⤐","rbbrk":"❳","rbrace":"}","rbrack":"]","rbrke":"⦌","rbrksld":"⦎","rbrkslu":"⦐","Rcaron":"Ř","rcaron":"ř","Rcedil":"Ŗ","rcedil":"ŗ","rceil":"⌉","rcub":"}","Rcy":"Р","rcy":"р","rdca":"⤷","rdldhar":"⥩","rdquo":"”","rdquor":"”","rdsh":"↳","real":"ℜ","realine":"ℛ","realpart":"ℜ","reals":"ℝ","Re":"ℜ","rect":"▭","reg":"®","REG":"®","ReverseElement":"∋","ReverseEquilibrium":"⇋","ReverseUpEquilibrium":"⥯","rfisht":"⥽","rfloor":"⌋","rfr":"𝔯","Rfr":"ℜ","rHar":"⥤","rhard":"⇁","rharu":"⇀","rharul":"⥬","Rho":"Ρ","rho":"ρ","rhov":"ϱ","RightAngleBracket":"⟩","RightArrowBar":"⇥","rightarrow":"→","RightArrow":"→","Rightarrow":"⇒","RightArrowLeftArrow":"⇄","rightarrowtail":"↣","RightCeiling":"⌉","RightDoubleBracket":"⟧","RightDownTeeVector":"⥝","RightDownVectorBar":"⥕","RightDownVector":"⇂","RightFloor":"⌋","rightharpoondown":"⇁","rightharpoonup":"⇀","rightleftarrows":"⇄","rightleftharpoons":"⇌","rightrightarrows":"⇉","rightsquigarrow":"↝","RightTeeArrow":"↦","RightTee":"⊢","RightTeeVector":"⥛","rightthreetimes":"⋌","RightTriangleBar":"⧐","RightTriangle":"⊳","RightTriangleEqual":"⊵","RightUpDownVector":"⥏","RightUpTeeVector":"⥜","RightUpVectorBar":"⥔","RightUpVector":"↾","RightVectorBar":"⥓","RightVector":"⇀","ring":"˚","risingdotseq":"≓","rlarr":"⇄","rlhar":"⇌","rlm":"‏","rmoustache":"⎱","rmoust":"⎱","rnmid":"⫮","roang":"⟭","roarr":"⇾","robrk":"⟧","ropar":"⦆","ropf":"𝕣","Ropf":"ℝ","roplus":"⨮","rotimes":"⨵","RoundImplies":"⥰","rpar":")","rpargt":"⦔","rppolint":"⨒","rrarr":"⇉","Rrightarrow":"⇛","rsaquo":"›","rscr":"𝓇","Rscr":"ℛ","rsh":"↱","Rsh":"↱","rsqb":"]","rsquo":"’","rsquor":"’","rthree":"⋌","rtimes":"⋊","rtri":"▹","rtrie":"⊵","rtrif":"▸","rtriltri":"⧎","RuleDelayed":"⧴","ruluhar":"⥨","rx":"℞","Sacute":"Ś","sacute":"ś","sbquo":"‚","scap":"⪸","Scaron":"Š","scaron":"š","Sc":"⪼","sc":"≻","sccue":"≽","sce":"⪰","scE":"⪴","Scedil":"Ş","scedil":"ş","Scirc":"Ŝ","scirc":"ŝ","scnap":"⪺","scnE":"⪶","scnsim":"⋩","scpolint":"⨓","scsim":"≿","Scy":"С","scy":"с","sdotb":"⊡","sdot":"⋅","sdote":"⩦","searhk":"⤥","searr":"↘","seArr":"⇘","searrow":"↘","sect":"§","semi":";","seswar":"⤩","setminus":"∖","setmn":"∖","sext":"✶","Sfr":"𝔖","sfr":"𝔰","sfrown":"⌢","sharp":"♯","SHCHcy":"Щ","shchcy":"щ","SHcy":"Ш","shcy":"ш","ShortDownArrow":"↓","ShortLeftArrow":"←","shortmid":"∣","shortparallel":"∥","ShortRightArrow":"→","ShortUpArrow":"↑","shy":"­","Sigma":"Σ","sigma":"σ","sigmaf":"ς","sigmav":"ς","sim":"∼","simdot":"⩪","sime":"≃","simeq":"≃","simg":"⪞","simgE":"⪠","siml":"⪝","simlE":"⪟","simne":"≆","simplus":"⨤","simrarr":"⥲","slarr":"←","SmallCircle":"∘","smallsetminus":"∖","smashp":"⨳","smeparsl":"⧤","smid":"∣","smile":"⌣","smt":"⪪","smte":"⪬","smtes":"⪬︀","SOFTcy":"Ь","softcy":"ь","solbar":"⌿","solb":"⧄","sol":"/","Sopf":"𝕊","sopf":"𝕤","spades":"♠","spadesuit":"♠","spar":"∥","sqcap":"⊓","sqcaps":"⊓︀","sqcup":"⊔","sqcups":"⊔︀","Sqrt":"√","sqsub":"⊏","sqsube":"⊑","sqsubset":"⊏","sqsubseteq":"⊑","sqsup":"⊐","sqsupe":"⊒","sqsupset":"⊐","sqsupseteq":"⊒","square":"□","Square":"□","SquareIntersection":"⊓","SquareSubset":"⊏","SquareSubsetEqual":"⊑","SquareSuperset":"⊐","SquareSupersetEqual":"⊒","SquareUnion":"⊔","squarf":"▪","squ":"□","squf":"▪","srarr":"→","Sscr":"𝒮","sscr":"𝓈","ssetmn":"∖","ssmile":"⌣","sstarf":"⋆","Star":"⋆","star":"☆","starf":"★","straightepsilon":"ϵ","straightphi":"ϕ","strns":"¯","sub":"⊂","Sub":"⋐","subdot":"⪽","subE":"⫅","sube":"⊆","subedot":"⫃","submult":"⫁","subnE":"⫋","subne":"⊊","subplus":"⪿","subrarr":"⥹","subset":"⊂","Subset":"⋐","subseteq":"⊆","subseteqq":"⫅","SubsetEqual":"⊆","subsetneq":"⊊","subsetneqq":"⫋","subsim":"⫇","subsub":"⫕","subsup":"⫓","succapprox":"⪸","succ":"≻","succcurlyeq":"≽","Succeeds":"≻","SucceedsEqual":"⪰","SucceedsSlantEqual":"≽","SucceedsTilde":"≿","succeq":"⪰","succnapprox":"⪺","succneqq":"⪶","succnsim":"⋩","succsim":"≿","SuchThat":"∋","sum":"∑","Sum":"∑","sung":"♪","sup1":"¹","sup2":"²","sup3":"³","sup":"⊃","Sup":"⋑","supdot":"⪾","supdsub":"⫘","supE":"⫆","supe":"⊇","supedot":"⫄","Superset":"⊃","SupersetEqual":"⊇","suphsol":"⟉","suphsub":"⫗","suplarr":"⥻","supmult":"⫂","supnE":"⫌","supne":"⊋","supplus":"⫀","supset":"⊃","Supset":"⋑","supseteq":"⊇","supseteqq":"⫆","supsetneq":"⊋","supsetneqq":"⫌","supsim":"⫈","supsub":"⫔","supsup":"⫖","swarhk":"⤦","swarr":"↙","swArr":"⇙","swarrow":"↙","swnwar":"⤪","szlig":"ß","Tab":"\\t","target":"⌖","Tau":"Τ","tau":"τ","tbrk":"⎴","Tcaron":"Ť","tcaron":"ť","Tcedil":"Ţ","tcedil":"ţ","Tcy":"Т","tcy":"т","tdot":"⃛","telrec":"⌕","Tfr":"𝔗","tfr":"𝔱","there4":"∴","therefore":"∴","Therefore":"∴","Theta":"Θ","theta":"θ","thetasym":"ϑ","thetav":"ϑ","thickapprox":"≈","thicksim":"∼","ThickSpace":"  ","ThinSpace":" ","thinsp":" ","thkap":"≈","thksim":"∼","THORN":"Þ","thorn":"þ","tilde":"˜","Tilde":"∼","TildeEqual":"≃","TildeFullEqual":"≅","TildeTilde":"≈","timesbar":"⨱","timesb":"⊠","times":"×","timesd":"⨰","tint":"∭","toea":"⤨","topbot":"⌶","topcir":"⫱","top":"⊤","Topf":"𝕋","topf":"𝕥","topfork":"⫚","tosa":"⤩","tprime":"‴","trade":"™","TRADE":"™","triangle":"▵","triangledown":"▿","triangleleft":"◃","trianglelefteq":"⊴","triangleq":"≜","triangleright":"▹","trianglerighteq":"⊵","tridot":"◬","trie":"≜","triminus":"⨺","TripleDot":"⃛","triplus":"⨹","trisb":"⧍","tritime":"⨻","trpezium":"⏢","Tscr":"𝒯","tscr":"𝓉","TScy":"Ц","tscy":"ц","TSHcy":"Ћ","tshcy":"ћ","Tstrok":"Ŧ","tstrok":"ŧ","twixt":"≬","twoheadleftarrow":"↞","twoheadrightarrow":"↠","Uacute":"Ú","uacute":"ú","uarr":"↑","Uarr":"↟","uArr":"⇑","Uarrocir":"⥉","Ubrcy":"Ў","ubrcy":"ў","Ubreve":"Ŭ","ubreve":"ŭ","Ucirc":"Û","ucirc":"û","Ucy":"У","ucy":"у","udarr":"⇅","Udblac":"Ű","udblac":"ű","udhar":"⥮","ufisht":"⥾","Ufr":"𝔘","ufr":"𝔲","Ugrave":"Ù","ugrave":"ù","uHar":"⥣","uharl":"↿","uharr":"↾","uhblk":"▀","ulcorn":"⌜","ulcorner":"⌜","ulcrop":"⌏","ultri":"◸","Umacr":"Ū","umacr":"ū","uml":"¨","UnderBar":"_","UnderBrace":"⏟","UnderBracket":"⎵","UnderParenthesis":"⏝","Union":"⋃","UnionPlus":"⊎","Uogon":"Ų","uogon":"ų","Uopf":"𝕌","uopf":"𝕦","UpArrowBar":"⤒","uparrow":"↑","UpArrow":"↑","Uparrow":"⇑","UpArrowDownArrow":"⇅","updownarrow":"↕","UpDownArrow":"↕","Updownarrow":"⇕","UpEquilibrium":"⥮","upharpoonleft":"↿","upharpoonright":"↾","uplus":"⊎","UpperLeftArrow":"↖","UpperRightArrow":"↗","upsi":"υ","Upsi":"ϒ","upsih":"ϒ","Upsilon":"Υ","upsilon":"υ","UpTeeArrow":"↥","UpTee":"⊥","upuparrows":"⇈","urcorn":"⌝","urcorner":"⌝","urcrop":"⌎","Uring":"Ů","uring":"ů","urtri":"◹","Uscr":"𝒰","uscr":"𝓊","utdot":"⋰","Utilde":"Ũ","utilde":"ũ","utri":"▵","utrif":"▴","uuarr":"⇈","Uuml":"Ü","uuml":"ü","uwangle":"⦧","vangrt":"⦜","varepsilon":"ϵ","varkappa":"ϰ","varnothing":"∅","varphi":"ϕ","varpi":"ϖ","varpropto":"∝","varr":"↕","vArr":"⇕","varrho":"ϱ","varsigma":"ς","varsubsetneq":"⊊︀","varsubsetneqq":"⫋︀","varsupsetneq":"⊋︀","varsupsetneqq":"⫌︀","vartheta":"ϑ","vartriangleleft":"⊲","vartriangleright":"⊳","vBar":"⫨","Vbar":"⫫","vBarv":"⫩","Vcy":"В","vcy":"в","vdash":"⊢","vDash":"⊨","Vdash":"⊩","VDash":"⊫","Vdashl":"⫦","veebar":"⊻","vee":"∨","Vee":"⋁","veeeq":"≚","vellip":"⋮","verbar":"|","Verbar":"‖","vert":"|","Vert":"‖","VerticalBar":"∣","VerticalLine":"|","VerticalSeparator":"❘","VerticalTilde":"≀","VeryThinSpace":" ","Vfr":"𝔙","vfr":"𝔳","vltri":"⊲","vnsub":"⊂⃒","vnsup":"⊃⃒","Vopf":"𝕍","vopf":"𝕧","vprop":"∝","vrtri":"⊳","Vscr":"𝒱","vscr":"𝓋","vsubnE":"⫋︀","vsubne":"⊊︀","vsupnE":"⫌︀","vsupne":"⊋︀","Vvdash":"⊪","vzigzag":"⦚","Wcirc":"Ŵ","wcirc":"ŵ","wedbar":"⩟","wedge":"∧","Wedge":"⋀","wedgeq":"≙","weierp":"℘","Wfr":"𝔚","wfr":"𝔴","Wopf":"𝕎","wopf":"𝕨","wp":"℘","wr":"≀","wreath":"≀","Wscr":"𝒲","wscr":"𝓌","xcap":"⋂","xcirc":"◯","xcup":"⋃","xdtri":"▽","Xfr":"𝔛","xfr":"𝔵","xharr":"⟷","xhArr":"⟺","Xi":"Ξ","xi":"ξ","xlarr":"⟵","xlArr":"⟸","xmap":"⟼","xnis":"⋻","xodot":"⨀","Xopf":"𝕏","xopf":"𝕩","xoplus":"⨁","xotime":"⨂","xrarr":"⟶","xrArr":"⟹","Xscr":"𝒳","xscr":"𝓍","xsqcup":"⨆","xuplus":"⨄","xutri":"△","xvee":"⋁","xwedge":"⋀","Yacute":"Ý","yacute":"ý","YAcy":"Я","yacy":"я","Ycirc":"Ŷ","ycirc":"ŷ","Ycy":"Ы","ycy":"ы","yen":"¥","Yfr":"𝔜","yfr":"𝔶","YIcy":"Ї","yicy":"ї","Yopf":"𝕐","yopf":"𝕪","Yscr":"𝒴","yscr":"𝓎","YUcy":"Ю","yucy":"ю","yuml":"ÿ","Yuml":"Ÿ","Zacute":"Ź","zacute":"ź","Zcaron":"Ž","zcaron":"ž","Zcy":"З","zcy":"з","Zdot":"Ż","zdot":"ż","zeetrf":"ℨ","ZeroWidthSpace":"​","Zeta":"Ζ","zeta":"ζ","zfr":"𝔷","Zfr":"ℨ","ZHcy":"Ж","zhcy":"ж","zigrarr":"⇝","zopf":"𝕫","Zopf":"ℤ","Zscr":"𝒵","zscr":"𝓏","zwj":"‍","zwnj":"‌"}')},function(e){e.exports=JSON.parse('{"amp":"&","apos":"\'","gt":">","lt":"<","quot":"\\""}')},function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var i=c(n(r(173)).default),a=u(i);t.encodeXML=p(i,a);var o=c(n(r(172)).default),s=u(o);function c(e){return Object.keys(e).sort().reduce(function(t,r){return t[e[r]]="&"+r+";",t},{})}function u(e){var t=[],r=[];return Object.keys(e).forEach(function(e){return 1===e.length?t.push("\\"+e):r.push(e)}),r.unshift("["+t.join("")+"]"),new RegExp(r.join("|"),"g")}t.encodeHTML=p(o,s);var l=/[^\0-\x7F]/g,f=/[\uD800-\uDBFF][\uDC00-\uDFFF]/g;function d(e){return"&#x"+e.charCodeAt(0).toString(16).toUpperCase()+";"}function h(e,t){return"&#x"+(1024*(e.charCodeAt(0)-55296)+e.charCodeAt(1)-56320+65536).toString(16).toUpperCase()+";"}function p(e,t){return function(r){return r.replace(t,function(t){return e[t]}).replace(f,h).replace(l,d)}}var y=u(i);t.escape=function(e){return e.replace(y,d).replace(f,h).replace(l,d)}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(55);function i(e,t,r,a){for(var o=[],s=0;s<t.length;s++){var c=t[s];if(e(c)&&(o.push(c),--a<=0))break;if(r&&n.hasChildren(c)&&c.children.length>0){var u=i(e,c.children,r,a);if(o=o.concat(u),(a-=u.length)<=0)break}}return o}t.filter=function(e,t,r,n){return void 0===r&&(r=!0),void 0===n&&(n=1/0),Array.isArray(t)||(t=[t]),i(e,t,r,n)},t.find=i,t.findOneChild=function(e,t){for(var r=0;r<t.length;r++)if(e(t[r]))return t[r];return null},t.findOne=function e(t,r,i){void 0===i&&(i=!0);for(var a=null,o=0;o<r.length&&!a;o++){var s=r[o];n.isTag(s)&&(t(s)?a=s:i&&s.children.length>0&&(a=e(t,s.children)))}return a},t.existsOne=function e(t,r){for(var i=0;i<r.length;i++){var a=r[i];if(n.isTag(a)&&(t(a)||a.children.length>0&&e(t,a.children)))return!0}return!1},t.findAll=function(e,t){for(var r=[],i=t.slice();i.length;){var a=i.shift();a&&n.isTag(a)&&(a.children&&a.children.length>0&&i.unshift.apply(i,a.children),e(a)&&r.push(a))}return r}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(65),i=r(92);class a{constructor(e,t){this.dataFactory=e||r(5),this.baseIRI=this.dataFactory.namedNode(t||""),this.baseIRIDocument=this.baseIRI}static parsePrefixes(e,t,r){const n={};if(r)for(const t in e)t.startsWith("xmlns")&&(n[t.substr(6)]=e[t]);if(e.prefix||Object.keys(n).length>0){const r=Object.assign({},t,n);if(e.prefix){let t;for(;t=a.PREFIX_REGEX.exec(e.prefix);)r[t[1]]=t[2]}return r}return t}static expandPrefixedTerm(e,t){const r=e.indexOf(":");let n,i;if(r>=0&&(n=e.substr(0,r),i=e.substr(r+1)),""===n)return"http://www.w3.org/1999/xhtml/vocab#"+i;if(n){const e=t.prefixesAll[n];if(e)return e+i}if(e){const r=t.prefixesAll[e.toLocaleLowerCase()];if(r)return r}return e}static isValidIri(e){return a.IRI_REGEX.test(e)}static contentTypeToProfile(e){return i.RDFA_CONTENTTYPES[e]||""}getBaseIRI(e){let t=e;const r=t.indexOf("#");return r>=0&&(t=t.substr(0,r)),this.dataFactory.namedNode(t)}getResourceOrBaseIri(e,t){return!0===e?this.getBaseIriTerm(t):e}getBaseIriTerm(e){return e.localBaseIRI||this.baseIRI}createVocabIris(e,t,r,n){return e.split(/\s+/).filter(e=>e&&(r||e.indexOf(":")>=0)).map(e=>this.createIri(e,t,!0,!0,n)).filter(e=>null!=e)}createLiteral(e,t){if(t.interpretObjectAsTime&&!t.datatype)for(const r of a.TIME_REGEXES)if(e.match(r.regex)){t.datatype=this.dataFactory.namedNode(a.XSD+r.type);break}return this.dataFactory.literal(e,t.datatype||t.language)}createBlankNode(){return this.blankNodeFactory?this.blankNodeFactory():this.dataFactory.blankNode()}createIri(e,t,r,i,o){if(e=e||"",!i)return r||(e=n.resolve(e,this.getBaseIriTerm(t).value)),a.isValidIri(e)?this.dataFactory.namedNode(e):null;if(e.length>0&&"["===e[0]&&"]"===e[e.length-1]&&(e=e.substr(1,e.length-2)).indexOf(":")<0)return null;if(e.startsWith("_:"))return o?this.dataFactory.blankNode(e.substr(2)||"b_identity"):null;if(r&&t.vocab&&e.indexOf(":")<0)return this.dataFactory.namedNode(t.vocab+e);let s=a.expandPrefixedTerm(e,t);return r?e!==s&&(s=n.resolve(s,this.baseIRIDocument.value)):s=n.resolve(s,this.getBaseIriTerm(t).value),a.isValidIri(s)?this.dataFactory.namedNode(s):null}}a.RDF="http://www.w3.org/1999/02/22-rdf-syntax-ns#",a.XSD="http://www.w3.org/2001/XMLSchema#",a.RDFA="http://www.w3.org/ns/rdfa#",a.PREFIX_REGEX=/\s*([^:\s]*)*:\s*([^\s]*)*\s*/g,a.TIME_REGEXES=[{regex:/^-?P([0-9]+Y)?([0-9]+M)?([0-9]+D)?(T([0-9]+H)?([0-9]+M)?([0-9]+(\.[0-9])?S)?)?$/,type:"duration"},{regex:/^[0-9]+-[0-9][0-9]-[0-9][0-9]T[0-9][0-9]:[0-9][0-9]:[0-9][0-9]((Z?)|([\+-][0-9][0-9]:[0-9][0-9]))$/,type:"dateTime"},{regex:/^[0-9]+-[0-9][0-9]-[0-9][0-9]Z?$/,type:"date"},{regex:/^[0-9][0-9]:[0-9][0-9]:[0-9][0-9]((Z?)|([\+-][0-9][0-9]:[0-9][0-9]))$/,type:"time"},{regex:/^[0-9]+-[0-9][0-9]$/,type:"gYearMonth"},{regex:/^[0-9]+$/,type:"gYear"}],a.IRI_REGEX=/^([A-Za-z][A-Za-z0-9+-.]*|_):[^ "<>{}|\\\[\]`]*$/,t.Util=a},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(407))},function(e,t,r){var n=r(179),i={input:!0,option:!0,optgroup:!0,select:!0,button:!0,datalist:!0,textarea:!0},a={tr:{tr:!0,th:!0,td:!0},th:{th:!0},td:{thead:!0,th:!0,td:!0},body:{head:!0,link:!0,script:!0},li:{li:!0},p:{p:!0},h1:{p:!0},h2:{p:!0},h3:{p:!0},h4:{p:!0},h5:{p:!0},h6:{p:!0},select:i,input:i,output:i,button:i,datalist:i,textarea:i,option:{option:!0},optgroup:{optgroup:!0}},o={__proto__:null,area:!0,base:!0,basefont:!0,br:!0,col:!0,command:!0,embed:!0,frame:!0,hr:!0,img:!0,input:!0,isindex:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0},s={__proto__:null,math:!0,svg:!0},c={__proto__:null,mi:!0,mo:!0,mn:!0,ms:!0,mtext:!0,"annotation-xml":!0,foreignObject:!0,desc:!0,title:!0},u=/\s|\//;function l(e,t){this._options=t||{},this._cbs=e||{},this._tagname="",this._attribname="",this._attribvalue="",this._attribs=null,this._stack=[],this._foreignContext=[],this.startIndex=0,this.endIndex=null,this._lowerCaseTagNames="lowerCaseTags"in this._options?!!this._options.lowerCaseTags:!this._options.xmlMode,this._lowerCaseAttributeNames="lowerCaseAttributeNames"in this._options?!!this._options.lowerCaseAttributeNames:!this._options.xmlMode,this._options.Tokenizer&&(n=this._options.Tokenizer),this._tokenizer=new n(this._options,this),this._cbs.onparserinit&&this._cbs.onparserinit(this)}r(1)(l,r(31).EventEmitter),l.prototype._updatePosition=function(e){null===this.endIndex?this._tokenizer._sectionStart<=e?this.startIndex=0:this.startIndex=this._tokenizer._sectionStart-e:this.startIndex=this.endIndex+1,this.endIndex=this._tokenizer.getAbsoluteIndex()},l.prototype.ontext=function(e){this._updatePosition(1),this.endIndex--,this._cbs.ontext&&this._cbs.ontext(e)},l.prototype.onopentagname=function(e){if(this._lowerCaseTagNames&&(e=e.toLowerCase()),this._tagname=e,!this._options.xmlMode&&e in a)for(var t;(t=this._stack[this._stack.length-1])in a[e];this.onclosetag(t));!this._options.xmlMode&&e in o||(this._stack.push(e),e in s?this._foreignContext.push(!0):e in c&&this._foreignContext.push(!1)),this._cbs.onopentagname&&this._cbs.onopentagname(e),this._cbs.onopentag&&(this._attribs={})},l.prototype.onopentagend=function(){this._updatePosition(1),this._attribs&&(this._cbs.onopentag&&this._cbs.onopentag(this._tagname,this._attribs),this._attribs=null),!this._options.xmlMode&&this._cbs.onclosetag&&this._tagname in o&&this._cbs.onclosetag(this._tagname),this._tagname=""},l.prototype.onclosetag=function(e){if(this._updatePosition(1),this._lowerCaseTagNames&&(e=e.toLowerCase()),(e in s||e in c)&&this._foreignContext.pop(),!this._stack.length||e in o&&!this._options.xmlMode)this._options.xmlMode||"br"!==e&&"p"!==e||(this.onopentagname(e),this._closeCurrentTag());else{var t=this._stack.lastIndexOf(e);if(-1!==t)if(this._cbs.onclosetag)for(t=this._stack.length-t;t--;)this._cbs.onclosetag(this._stack.pop());else this._stack.length=t;else"p"!==e||this._options.xmlMode||(this.onopentagname(e),this._closeCurrentTag())}},l.prototype.onselfclosingtag=function(){this._options.xmlMode||this._options.recognizeSelfClosing||this._foreignContext[this._foreignContext.length-1]?this._closeCurrentTag():this.onopentagend()},l.prototype._closeCurrentTag=function(){var e=this._tagname;this.onopentagend(),this._stack[this._stack.length-1]===e&&(this._cbs.onclosetag&&this._cbs.onclosetag(e),this._stack.pop())},l.prototype.onattribname=function(e){this._lowerCaseAttributeNames&&(e=e.toLowerCase()),this._attribname=e},l.prototype.onattribdata=function(e){this._attribvalue+=e},l.prototype.onattribend=function(){this._cbs.onattribute&&this._cbs.onattribute(this._attribname,this._attribvalue),this._attribs&&!Object.prototype.hasOwnProperty.call(this._attribs,this._attribname)&&(this._attribs[this._attribname]=this._attribvalue),this._attribname="",this._attribvalue=""},l.prototype._getInstructionName=function(e){var t=e.search(u),r=t<0?e:e.substr(0,t);return this._lowerCaseTagNames&&(r=r.toLowerCase()),r},l.prototype.ondeclaration=function(e){if(this._cbs.onprocessinginstruction){var t=this._getInstructionName(e);this._cbs.onprocessinginstruction("!"+t,"!"+e)}},l.prototype.onprocessinginstruction=function(e){if(this._cbs.onprocessinginstruction){var t=this._getInstructionName(e);this._cbs.onprocessinginstruction("?"+t,"?"+e)}},l.prototype.oncomment=function(e){this._updatePosition(4),this._cbs.oncomment&&this._cbs.oncomment(e),this._cbs.oncommentend&&this._cbs.oncommentend()},l.prototype.oncdata=function(e){this._updatePosition(1),this._options.xmlMode||this._options.recognizeCDATA?(this._cbs.oncdatastart&&this._cbs.oncdatastart(),this._cbs.ontext&&this._cbs.ontext(e),this._cbs.oncdataend&&this._cbs.oncdataend()):this.oncomment("[CDATA["+e+"]]")},l.prototype.onerror=function(e){this._cbs.onerror&&this._cbs.onerror(e)},l.prototype.onend=function(){if(this._cbs.onclosetag)for(var e=this._stack.length;e>0;this._cbs.onclosetag(this._stack[--e]));this._cbs.onend&&this._cbs.onend()},l.prototype.reset=function(){this._cbs.onreset&&this._cbs.onreset(),this._tokenizer.reset(),this._tagname="",this._attribname="",this._attribs=null,this._stack=[],this._cbs.onparserinit&&this._cbs.onparserinit(this)},l.prototype.parseComplete=function(e){this.reset(),this.end(e)},l.prototype.write=function(e){this._tokenizer.write(e)},l.prototype.end=function(e){this._tokenizer.end(e)},l.prototype.pause=function(){this._tokenizer.pause()},l.prototype.resume=function(){this._tokenizer.resume()},l.prototype.parseChunk=l.prototype.write,l.prototype.done=l.prototype.end,e.exports=l},function(e,t,r){e.exports=me;var n=r(408),i=r(410),a=r(411),o=r(412),s=0,c=s++,u=s++,l=s++,f=s++,d=s++,h=s++,p=s++,y=s++,m=s++,g=s++,b=s++,v=s++,_=s++,w=s++,S=s++,E=s++,x=s++,T=s++,O=s++,A=s++,I=s++,N=s++,R=s++,k=s++,P=s++,j=s++,D=s++,C=s++,M=s++,L=s++,q=s++,F=s++,B=s++,U=s++,V=s++,H=s++,z=s++,G=s++,Q=s++,X=s++,$=s++,J=s++,Y=s++,K=s++,W=s++,Z=s++,ee=s++,te=s++,re=s++,ne=s++,ie=s++,ae=s++,oe=s++,se=s++,ce=s++,ue=0,le=ue++,fe=ue++,de=ue++;function he(e){return" "===e||"\n"===e||"\t"===e||"\f"===e||"\r"===e}function pe(e,t,r){var n=e.toLowerCase();return e===n?function(e){e===n?this._state=t:(this._state=r,this._index--)}:function(i){i===n||i===e?this._state=t:(this._state=r,this._index--)}}function ye(e,t){var r=e.toLowerCase();return function(n){n===r||n===e?this._state=t:(this._state=l,this._index--)}}function me(e,t){this._state=c,this._buffer="",this._sectionStart=0,this._index=0,this._bufferOffset=0,this._baseState=c,this._special=le,this._cbs=t,this._running=!0,this._ended=!1,this._xmlMode=!(!e||!e.xmlMode),this._decodeEntities=!(!e||!e.decodeEntities)}me.prototype._stateText=function(e){"<"===e?(this._index>this._sectionStart&&this._cbs.ontext(this._getSection()),this._state=u,this._sectionStart=this._index):this._decodeEntities&&this._special===le&&"&"===e&&(this._index>this._sectionStart&&this._cbs.ontext(this._getSection()),this._baseState=c,this._state=ie,this._sectionStart=this._index)},me.prototype._stateBeforeTagName=function(e){"/"===e?this._state=d:"<"===e?(this._cbs.ontext(this._getSection()),this._sectionStart=this._index):">"===e||this._special!==le||he(e)?this._state=c:"!"===e?(this._state=S,this._sectionStart=this._index+1):"?"===e?(this._state=x,this._sectionStart=this._index+1):(this._state=this._xmlMode||"s"!==e&&"S"!==e?l:q,this._sectionStart=this._index)},me.prototype._stateInTagName=function(e){("/"===e||">"===e||he(e))&&(this._emitToken("onopentagname"),this._state=y,this._index--)},me.prototype._stateBeforeCloseingTagName=function(e){he(e)||(">"===e?this._state=c:this._special!==le?"s"===e||"S"===e?this._state=F:(this._state=c,this._index--):(this._state=h,this._sectionStart=this._index))},me.prototype._stateInCloseingTagName=function(e){(">"===e||he(e))&&(this._emitToken("onclosetag"),this._state=p,this._index--)},me.prototype._stateAfterCloseingTagName=function(e){">"===e&&(this._state=c,this._sectionStart=this._index+1)},me.prototype._stateBeforeAttributeName=function(e){">"===e?(this._cbs.onopentagend(),this._state=c,this._sectionStart=this._index+1):"/"===e?this._state=f:he(e)||(this._state=m,this._sectionStart=this._index)},me.prototype._stateInSelfClosingTag=function(e){">"===e?(this._cbs.onselfclosingtag(),this._state=c,this._sectionStart=this._index+1):he(e)||(this._state=y,this._index--)},me.prototype._stateInAttributeName=function(e){("="===e||"/"===e||">"===e||he(e))&&(this._cbs.onattribname(this._getSection()),this._sectionStart=-1,this._state=g,this._index--)},me.prototype._stateAfterAttributeName=function(e){"="===e?this._state=b:"/"===e||">"===e?(this._cbs.onattribend(),this._state=y,this._index--):he(e)||(this._cbs.onattribend(),this._state=m,this._sectionStart=this._index)},me.prototype._stateBeforeAttributeValue=function(e){'"'===e?(this._state=v,this._sectionStart=this._index+1):"'"===e?(this._state=_,this._sectionStart=this._index+1):he(e)||(this._state=w,this._sectionStart=this._index,this._index--)},me.prototype._stateInAttributeValueDoubleQuotes=function(e){'"'===e?(this._emitToken("onattribdata"),this._cbs.onattribend(),this._state=y):this._decodeEntities&&"&"===e&&(this._emitToken("onattribdata"),this._baseState=this._state,this._state=ie,this._sectionStart=this._index)},me.prototype._stateInAttributeValueSingleQuotes=function(e){"'"===e?(this._emitToken("onattribdata"),this._cbs.onattribend(),this._state=y):this._decodeEntities&&"&"===e&&(this._emitToken("onattribdata"),this._baseState=this._state,this._state=ie,this._sectionStart=this._index)},me.prototype._stateInAttributeValueNoQuotes=function(e){he(e)||">"===e?(this._emitToken("onattribdata"),this._cbs.onattribend(),this._state=y,this._index--):this._decodeEntities&&"&"===e&&(this._emitToken("onattribdata"),this._baseState=this._state,this._state=ie,this._sectionStart=this._index)},me.prototype._stateBeforeDeclaration=function(e){this._state="["===e?N:"-"===e?T:E},me.prototype._stateInDeclaration=function(e){">"===e&&(this._cbs.ondeclaration(this._getSection()),this._state=c,this._sectionStart=this._index+1)},me.prototype._stateInProcessingInstruction=function(e){">"===e&&(this._cbs.onprocessinginstruction(this._getSection()),this._state=c,this._sectionStart=this._index+1)},me.prototype._stateBeforeComment=function(e){"-"===e?(this._state=O,this._sectionStart=this._index+1):this._state=E},me.prototype._stateInComment=function(e){"-"===e&&(this._state=A)},me.prototype._stateAfterComment1=function(e){this._state="-"===e?I:O},me.prototype._stateAfterComment2=function(e){">"===e?(this._cbs.oncomment(this._buffer.substring(this._sectionStart,this._index-2)),this._state=c,this._sectionStart=this._index+1):"-"!==e&&(this._state=O)},me.prototype._stateBeforeCdata1=pe("C",R,E),me.prototype._stateBeforeCdata2=pe("D",k,E),me.prototype._stateBeforeCdata3=pe("A",P,E),me.prototype._stateBeforeCdata4=pe("T",j,E),me.prototype._stateBeforeCdata5=pe("A",D,E),me.prototype._stateBeforeCdata6=function(e){"["===e?(this._state=C,this._sectionStart=this._index+1):(this._state=E,this._index--)},me.prototype._stateInCdata=function(e){"]"===e&&(this._state=M)},me.prototype._stateAfterCdata1=function(e){this._state="]"===e?L:C},me.prototype._stateAfterCdata2=function(e){">"===e?(this._cbs.oncdata(this._buffer.substring(this._sectionStart,this._index-2)),this._state=c,this._sectionStart=this._index+1):"]"!==e&&(this._state=C)},me.prototype._stateBeforeSpecial=function(e){"c"===e||"C"===e?this._state=B:"t"===e||"T"===e?this._state=Y:(this._state=l,this._index--)},me.prototype._stateBeforeSpecialEnd=function(e){this._special!==fe||"c"!==e&&"C"!==e?this._special!==de||"t"!==e&&"T"!==e?this._state=c:this._state=ee:this._state=G},me.prototype._stateBeforeScript1=ye("R",U),me.prototype._stateBeforeScript2=ye("I",V),me.prototype._stateBeforeScript3=ye("P",H),me.prototype._stateBeforeScript4=ye("T",z),me.prototype._stateBeforeScript5=function(e){("/"===e||">"===e||he(e))&&(this._special=fe),this._state=l,this._index--},me.prototype._stateAfterScript1=pe("R",Q,c),me.prototype._stateAfterScript2=pe("I",X,c),me.prototype._stateAfterScript3=pe("P",$,c),me.prototype._stateAfterScript4=pe("T",J,c),me.prototype._stateAfterScript5=function(e){">"===e||he(e)?(this._special=le,this._state=h,this._sectionStart=this._index-6,this._index--):this._state=c},me.prototype._stateBeforeStyle1=ye("Y",K),me.prototype._stateBeforeStyle2=ye("L",W),me.prototype._stateBeforeStyle3=ye("E",Z),me.prototype._stateBeforeStyle4=function(e){("/"===e||">"===e||he(e))&&(this._special=de),this._state=l,this._index--},me.prototype._stateAfterStyle1=pe("Y",te,c),me.prototype._stateAfterStyle2=pe("L",re,c),me.prototype._stateAfterStyle3=pe("E",ne,c),me.prototype._stateAfterStyle4=function(e){">"===e||he(e)?(this._special=le,this._state=h,this._sectionStart=this._index-5,this._index--):this._state=c},me.prototype._stateBeforeEntity=pe("#",ae,oe),me.prototype._stateBeforeNumericEntity=pe("X",ce,se),me.prototype._parseNamedEntityStrict=function(){if(this._sectionStart+1<this._index){var e=this._buffer.substring(this._sectionStart+1,this._index),t=this._xmlMode?o:i;t.hasOwnProperty(e)&&(this._emitPartial(t[e]),this._sectionStart=this._index+1)}},me.prototype._parseLegacyEntity=function(){var e=this._sectionStart+1,t=this._index-e;for(t>6&&(t=6);t>=2;){var r=this._buffer.substr(e,t);if(a.hasOwnProperty(r))return this._emitPartial(a[r]),void(this._sectionStart+=t+1);t--}},me.prototype._stateInNamedEntity=function(e){";"===e?(this._parseNamedEntityStrict(),this._sectionStart+1<this._index&&!this._xmlMode&&this._parseLegacyEntity(),this._state=this._baseState):(e<"a"||e>"z")&&(e<"A"||e>"Z")&&(e<"0"||e>"9")&&(this._xmlMode||this._sectionStart+1===this._index||(this._baseState!==c?"="!==e&&this._parseNamedEntityStrict():this._parseLegacyEntity()),this._state=this._baseState,this._index--)},me.prototype._decodeNumericEntity=function(e,t){var r=this._sectionStart+e;if(r!==this._index){var i=this._buffer.substring(r,this._index),a=parseInt(i,t);this._emitPartial(n(a)),this._sectionStart=this._index}else this._sectionStart--;this._state=this._baseState},me.prototype._stateInNumericEntity=function(e){";"===e?(this._decodeNumericEntity(2,10),this._sectionStart++):(e<"0"||e>"9")&&(this._xmlMode?this._state=this._baseState:this._decodeNumericEntity(2,10),this._index--)},me.prototype._stateInHexEntity=function(e){";"===e?(this._decodeNumericEntity(3,16),this._sectionStart++):(e<"a"||e>"f")&&(e<"A"||e>"F")&&(e<"0"||e>"9")&&(this._xmlMode?this._state=this._baseState:this._decodeNumericEntity(3,16),this._index--)},me.prototype._cleanup=function(){this._sectionStart<0?(this._buffer="",this._bufferOffset+=this._index,this._index=0):this._running&&(this._state===c?(this._sectionStart!==this._index&&this._cbs.ontext(this._buffer.substr(this._sectionStart)),this._buffer="",this._bufferOffset+=this._index,this._index=0):this._sectionStart===this._index?(this._buffer="",this._bufferOffset+=this._index,this._index=0):(this._buffer=this._buffer.substr(this._sectionStart),this._index-=this._sectionStart,this._bufferOffset+=this._sectionStart),this._sectionStart=0)},me.prototype.write=function(e){this._ended&&this._cbs.onerror(Error(".write() after done!")),this._buffer+=e,this._parse()},me.prototype._parse=function(){for(;this._index<this._buffer.length&&this._running;){var e=this._buffer.charAt(this._index);this._state===c?this._stateText(e):this._state===u?this._stateBeforeTagName(e):this._state===l?this._stateInTagName(e):this._state===d?this._stateBeforeCloseingTagName(e):this._state===h?this._stateInCloseingTagName(e):this._state===p?this._stateAfterCloseingTagName(e):this._state===f?this._stateInSelfClosingTag(e):this._state===y?this._stateBeforeAttributeName(e):this._state===m?this._stateInAttributeName(e):this._state===g?this._stateAfterAttributeName(e):this._state===b?this._stateBeforeAttributeValue(e):this._state===v?this._stateInAttributeValueDoubleQuotes(e):this._state===_?this._stateInAttributeValueSingleQuotes(e):this._state===w?this._stateInAttributeValueNoQuotes(e):this._state===S?this._stateBeforeDeclaration(e):this._state===E?this._stateInDeclaration(e):this._state===x?this._stateInProcessingInstruction(e):this._state===T?this._stateBeforeComment(e):this._state===O?this._stateInComment(e):this._state===A?this._stateAfterComment1(e):this._state===I?this._stateAfterComment2(e):this._state===N?this._stateBeforeCdata1(e):this._state===R?this._stateBeforeCdata2(e):this._state===k?this._stateBeforeCdata3(e):this._state===P?this._stateBeforeCdata4(e):this._state===j?this._stateBeforeCdata5(e):this._state===D?this._stateBeforeCdata6(e):this._state===C?this._stateInCdata(e):this._state===M?this._stateAfterCdata1(e):this._state===L?this._stateAfterCdata2(e):this._state===q?this._stateBeforeSpecial(e):this._state===F?this._stateBeforeSpecialEnd(e):this._state===B?this._stateBeforeScript1(e):this._state===U?this._stateBeforeScript2(e):this._state===V?this._stateBeforeScript3(e):this._state===H?this._stateBeforeScript4(e):this._state===z?this._stateBeforeScript5(e):this._state===G?this._stateAfterScript1(e):this._state===Q?this._stateAfterScript2(e):this._state===X?this._stateAfterScript3(e):this._state===$?this._stateAfterScript4(e):this._state===J?this._stateAfterScript5(e):this._state===Y?this._stateBeforeStyle1(e):this._state===K?this._stateBeforeStyle2(e):this._state===W?this._stateBeforeStyle3(e):this._state===Z?this._stateBeforeStyle4(e):this._state===ee?this._stateAfterStyle1(e):this._state===te?this._stateAfterStyle2(e):this._state===re?this._stateAfterStyle3(e):this._state===ne?this._stateAfterStyle4(e):this._state===ie?this._stateBeforeEntity(e):this._state===ae?this._stateBeforeNumericEntity(e):this._state===oe?this._stateInNamedEntity(e):this._state===se?this._stateInNumericEntity(e):this._state===ce?this._stateInHexEntity(e):this._cbs.onerror(Error("unknown _state"),this._state),this._index++}this._cleanup()},me.prototype.pause=function(){this._running=!1},me.prototype.resume=function(){this._running=!0,this._index<this._buffer.length&&this._parse(),this._ended&&this._finish()},me.prototype.end=function(e){this._ended&&this._cbs.onerror(Error(".end() after done!")),e&&this.write(e),this._ended=!0,this._running&&this._finish()},me.prototype._finish=function(){this._sectionStart<this._index&&this._handleTrailingData(),this._cbs.onend()},me.prototype._handleTrailingData=function(){var e=this._buffer.substr(this._sectionStart);this._state===C||this._state===M||this._state===L?this._cbs.oncdata(e):this._state===O||this._state===A||this._state===I?this._cbs.oncomment(e):this._state!==oe||this._xmlMode?this._state!==se||this._xmlMode?this._state!==ce||this._xmlMode?this._state!==l&&this._state!==y&&this._state!==b&&this._state!==g&&this._state!==m&&this._state!==_&&this._state!==v&&this._state!==w&&this._state!==h&&this._cbs.ontext(e):(this._decodeNumericEntity(3,16),this._sectionStart<this._index&&(this._state=this._baseState,this._handleTrailingData())):(this._decodeNumericEntity(2,10),this._sectionStart<this._index&&(this._state=this._baseState,this._handleTrailingData())):(this._parseLegacyEntity(),this._sectionStart<this._index&&(this._state=this._baseState,this._handleTrailingData()))},me.prototype.reset=function(){me.call(this,{xmlMode:this._xmlMode,decodeEntities:this._decodeEntities},this._cbs)},me.prototype.getAbsoluteIndex=function(){return this._bufferOffset+this._index},me.prototype._getSection=function(){return this._buffer.substring(this._sectionStart,this._index)},me.prototype._emitToken=function(e){this._cbs[e](this._getSection()),this._sectionStart=-1},me.prototype._emitPartial=function(e){this._baseState!==c?this._cbs.onattribdata(e):this._cbs.ontext(e)}},function(e,t,r){var n=r(56),i=/\s+/g,a=r(181),o=r(413);function s(e,t,r){"object"==typeof e?(r=t,t=e,e=null):"function"==typeof t&&(r=t,t=c),this._callback=e,this._options=t||c,this._elementCB=r,this.dom=[],this._done=!1,this._tagStack=[],this._parser=this._parser||null}var c={normalizeWhitespace:!1,withStartIndices:!1,withEndIndices:!1};s.prototype.onparserinit=function(e){this._parser=e},s.prototype.onreset=function(){s.call(this,this._callback,this._options,this._elementCB)},s.prototype.onend=function(){this._done||(this._done=!0,this._parser=null,this._handleCallback(null))},s.prototype._handleCallback=s.prototype.onerror=function(e){if("function"==typeof this._callback)this._callback(e,this.dom);else if(e)throw e},s.prototype.onclosetag=function(){var e=this._tagStack.pop();this._options.withEndIndices&&e&&(e.endIndex=this._parser.endIndex),this._elementCB&&this._elementCB(e)},s.prototype._createDomElement=function(e){if(!this._options.withDomLvl1)return e;var t;for(var r in t="tag"===e.type?Object.create(o):Object.create(a),e)e.hasOwnProperty(r)&&(t[r]=e[r]);return t},s.prototype._addDomElement=function(e){var t=this._tagStack[this._tagStack.length-1],r=t?t.children:this.dom,n=r[r.length-1];e.next=null,this._options.withStartIndices&&(e.startIndex=this._parser.startIndex),this._options.withEndIndices&&(e.endIndex=this._parser.endIndex),n?(e.prev=n,n.next=e):e.prev=null,r.push(e),e.parent=t||null},s.prototype.onopentag=function(e,t){var r={type:"script"===e?n.Script:"style"===e?n.Style:n.Tag,name:e,attribs:t,children:[]},i=this._createDomElement(r);this._addDomElement(i),this._tagStack.push(i)},s.prototype.ontext=function(e){var t,r=this._options.normalizeWhitespace||this._options.ignoreWhitespace;if(!this._tagStack.length&&this.dom.length&&(t=this.dom[this.dom.length-1]).type===n.Text)r?t.data=(t.data+e).replace(i," "):t.data+=e;else if(this._tagStack.length&&(t=this._tagStack[this._tagStack.length-1])&&(t=t.children[t.children.length-1])&&t.type===n.Text)r?t.data=(t.data+e).replace(i," "):t.data+=e;else{r&&(e=e.replace(i," "));var a=this._createDomElement({data:e,type:n.Text});this._addDomElement(a)}},s.prototype.oncomment=function(e){var t=this._tagStack[this._tagStack.length-1];if(t&&t.type===n.Comment)t.data+=e;else{var r={data:e,type:n.Comment},i=this._createDomElement(r);this._addDomElement(i),this._tagStack.push(i)}},s.prototype.oncdatastart=function(){var e={children:[{data:"",type:n.Text}],type:n.CDATA},t=this._createDomElement(e);this._addDomElement(t),this._tagStack.push(t)},s.prototype.oncommentend=s.prototype.oncdataend=function(){this._tagStack.pop()},s.prototype.onprocessinginstruction=function(e,t){var r=this._createDomElement({name:e,data:t,type:n.Directive});this._addDomElement(r)},e.exports=s},function(e,t){var r=e.exports={get firstChild(){var e=this.children;return e&&e[0]||null},get lastChild(){var e=this.children;return e&&e[e.length-1]||null},get nodeType(){return i[this.type]||i.element}},n={tagName:"name",childNodes:"children",parentNode:"parent",previousSibling:"prev",nextSibling:"next",nodeValue:"data"},i={element:1,text:3,cdata:4,comment:8};Object.keys(n).forEach(function(e){var t=n[e];Object.defineProperty(r,e,{get:function(){return this[t]||null},set:function(e){return this[t]=e,e}})})},function(e,t,r){var n=e.exports;[r(415),r(416),r(417),r(418),r(419),r(420)].forEach(function(e){Object.keys(e).forEach(function(t){n[t]=e[t].bind(n)})})},function(e,t,r){e.exports=s;var n=r(178),i=r(422).Writable,a=r(51).StringDecoder,o=r(7).Buffer;function s(e,t){var r=this._parser=new n(e,t),o=this._decoder=new a;i.call(this,{decodeStrings:!1}),this.once("finish",function(){r.end(o.end())})}r(1)(s,i),s.prototype._write=function(e,t,r){e instanceof o&&(e=this._decoder.write(e)),this._parser.write(e),r()}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(425))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(426))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(427))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(0);function i(e){return"string"==typeof e?"":e.type}function a(e){return"string"==typeof e?e:e.value}t.ActorRdfResolveQuadPattern=class extends n.Actor{constructor(e){super(e)}getContextSources(e){return e?e.get(t.KEY_CONTEXT_SOURCES):null}getContextSource(e){return e?e.get(t.KEY_CONTEXT_SOURCE):null}getContextSourceUrl(e){if(e){let t=a(e);const r=t.indexOf("#");return r>=0&&(t=t.substr(0,r)),t}return null}hasContextSingleSource(e){const t=this.getContextSource(e);return!(!t||"string"!=typeof t&&!t.value)}hasContextSingleSourceOfType(e,t){const r=this.getContextSource(t);return!(!r||i(r)!==e||!a(r))}},t.getDataSourceType=i,t.getDataSourceValue=a,t.KEY_CONTEXT_SOURCES="@comunica/bus-rdf-resolve-quad-pattern:sources",t.KEY_CONTEXT_SOURCE="@comunica/bus-rdf-resolve-quad-pattern:source"},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(429))},function(e,t,r){"use strict";function n(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}Object.defineProperty(t,"__esModule",{value:!0}),n(r(190)),n(r(430))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(0);t.ActorRdfMetadata=class extends n.Actor{constructor(e){super(e)}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(431))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(432))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(0);t.ActorRdfMetadataExtract=class extends n.Actor{constructor(e){super(e)}}},function(e,t,r){"use strict";function n(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}Object.defineProperty(t,"__esModule",{value:!0}),n(r(195)),n(r(465)),n(r(57)),n(r(198))},function(e,t,r){"use strict";function n(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}Object.defineProperty(t,"__esModule",{value:!0}),n(r(196)),n(r(441)),n(r(71)),n(r(94)),n(r(451)),n(r(452)),n(r(453)),n(r(74)),n(r(462)),n(r(463)),n(r(464))},function(e,t,r){"use strict";function n(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}Object.defineProperty(t,"__esModule",{value:!0}),n(r(42)),n(r(436)),n(r(437)),n(r(438)),n(r(439)),n(r(440))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(72),i=r(73);class a{static inScopeVariables(e){const t=[];function r(e){t.find(t=>e.value===t.value)||t.push(e)}return a.recurseOperation(e,{[n.types.EXPRESSION]:e=>{let t=e;if("aggregate"===t.expressionType&&t.variable){r(t.variable)}return!0},[n.types.EXTEND]:e=>{return r(e.variable),!0},[n.types.GRAPH]:e=>{let t=e;return"Variable"===t.name.termType&&r(t.name),!0},[n.types.GROUP]:e=>{return e.variables.forEach(r),!0},[n.types.PATH]:e=>{let t=e;return"Variable"===t.subject.termType&&r(t.subject),"Variable"===t.object.termType&&r(t.object),"Variable"===t.graph.termType&&r(t.graph),!0},[n.types.PATTERN]:e=>{let t=e;return"Variable"===t.subject.termType&&r(t.subject),"Variable"===t.predicate.termType&&r(t.predicate),"Variable"===t.object.termType&&r(t.object),"Variable"===t.graph.termType&&r(t.graph),!0},[n.types.PROJECT]:e=>{return e.variables.forEach(r),!1},[n.types.SERVICE]:e=>{let t=e;return"Variable"===t.name.termType&&r(t.name),!0},[n.types.VALUES]:e=>{return e.variables.forEach(r),!0}}),t}static recurseOperation(e,t){let r=e,i=!0;if(t[e.type]&&(i=t[e.type](e)),!i)return;let o=e=>a.recurseOperation(e,t);switch(r.type){case n.types.ALT:const e=r;o(e.left),o(e.right);break;case n.types.ASK:o(r.input);break;case n.types.BGP:r.patterns.forEach(o);break;case n.types.CONSTRUCT:const t=r;o(t.input),t.template.map(o);break;case n.types.DESCRIBE:o(r.input);break;case n.types.DISTINCT:o(r.input);break;case n.types.EXPRESSION:const i=r;if(i.expressionType===n.expressionTypes.EXISTENCE){o(i.input)}break;case n.types.EXTEND:const a=r;o(a.input),o(a.expression);break;case n.types.FILTER:const s=r;o(s.input),o(s.expression);break;case n.types.FROM:o(r.input);break;case n.types.GRAPH:o(r.input);break;case n.types.GROUP:const c=r;o(c.input),c.aggregates.forEach(o);break;case n.types.INV:o(r.path);break;case n.types.JOIN:const u=r;o(u.left),o(u.right);break;case n.types.LEFT_JOIN:const l=r;o(l.left),o(l.right),l.expression&&o(l.expression);break;case n.types.LINK:break;case n.types.MINUS:const f=r;o(f.left),o(f.right);break;case n.types.NPS:break;case n.types.ONE_OR_MORE_PATH:o(r.path);break;case n.types.ORDER_BY:const d=r;o(d.input),d.expressions.forEach(o);break;case n.types.PATH:o(r.predicate);break;case n.types.PATTERN:break;case n.types.PROJECT:o(r.input);break;case n.types.REDUCED:o(r.input);break;case n.types.SEQ:const h=r;o(h.left),o(h.right);break;case n.types.SERVICE:o(r.input);break;case n.types.SLICE:o(r.input);break;case n.types.UNION:const p=r;o(p.left),o(p.right);break;case n.types.VALUES:break;case n.types.ZERO_OR_MORE_PATH:o(r.path);break;case n.types.ZERO_OR_ONE_PATH:o(r.path);break;default:throw new Error("Unknown Operation type "+r.type)}}static mapOperation(e,t,r){let o=e,s=!0;if(r=r||new i.default,t[e.type]&&({result:o,recurse:s}=t[e.type](e,r)),!s)return o;let c=e=>a.mapOperation(e,t,r);switch(o.type){case n.types.ALT:const e=o;return r.createAlt(c(e.left),c(e.right));case n.types.ASK:const i=o;return r.createAsk(c(i.input));case n.types.BGP:const s=o;return r.createBgp(s.patterns.map(c));case n.types.CONSTRUCT:const u=o;return r.createConstruct(c(u.input),u.template.map(c));case n.types.DESCRIBE:const l=o;return r.createDescribe(c(l.input),l.terms);case n.types.DISTINCT:const f=o;return r.createDistinct(c(f.input));case n.types.EXPRESSION:const d=o;return a.mapExpression(d,t,r);case n.types.EXTEND:const h=o;return r.createExtend(c(h.input),h.variable,c(h.expression));case n.types.FILTER:const p=o;return r.createFilter(c(p.input),c(p.expression));case n.types.FROM:const y=o;return r.createFrom(c(y.input),[].concat(y.default),[].concat(y.named));case n.types.GRAPH:const m=o;return r.createGraph(c(m.input),m.name);case n.types.GROUP:const g=o;return r.createGroup(c(g.input),[].concat(g.variables),g.aggregates.map(c));case n.types.INV:const b=o;return r.createInv(c(b.path));case n.types.JOIN:const v=o;return r.createJoin(c(v.left),c(v.right));case n.types.LEFT_JOIN:const _=o;return r.createLeftJoin(c(_.left),c(_.right),_.expression?c(_.expression):void 0);case n.types.LINK:const w=o;return r.createLink(w.iri);case n.types.MINUS:const S=o;return r.createMinus(c(S.left),c(S.right));case n.types.NPS:const E=o;return r.createNps([].concat(E.iris));case n.types.ONE_OR_MORE_PATH:const x=o;return r.createOneOrMorePath(c(x.path));case n.types.ORDER_BY:const T=o;return r.createOrderBy(c(T.input),T.expressions.map(c));case n.types.PATH:const O=o;return r.createPath(O.subject,c(O.predicate),O.object,O.graph);case n.types.PATTERN:const A=o;return r.createPattern(A.subject,A.predicate,A.object,A.graph);case n.types.PROJECT:const I=o;return r.createProject(c(I.input),[].concat(I.variables));case n.types.REDUCED:const N=o;return r.createReduced(c(N.input));case n.types.SEQ:const R=o;return r.createSeq(c(R.left),c(R.right));case n.types.SERVICE:const k=o;return r.createService(c(k.input),k.name,k.silent);case n.types.SLICE:const P=o;return r.createSlice(c(P.input),P.start,P.length);case n.types.UNION:const j=o;return r.createUnion(c(j.left),c(j.right));case n.types.VALUES:const D=o;return r.createValues([].concat(D.variables),D.bindings.map(e=>Object.assign({},e)));case n.types.ZERO_OR_MORE_PATH:const C=o;return r.createZeroOrMorePath(c(C.path));case n.types.ZERO_OR_ONE_PATH:const M=o;return r.createZeroOrOnePath(c(M.path));default:throw new Error("Unknown Operation type "+o.type)}}static mapExpression(e,t,r){let i=e=>a.mapOperation(e,t,r);switch(e.expressionType){case n.expressionTypes.AGGREGATE:if(e.variable){const t=e;return r.createBoundAggregate(t.variable,t.aggregator,i(t.expression),t.distinct,t.separator)}const t=e;return r.createAggregateExpression(t.aggregator,i(t.expression),t.distinct,t.separator);case n.expressionTypes.EXISTENCE:const a=e;return r.createExistenceExpression(a.not,i(a.input));case n.expressionTypes.NAMED:const o=e;return r.createNamedExpression(o.name,o.args.map(i));case n.expressionTypes.OPERATOR:const s=e;return r.createOperatorExpression(s.operator,s.args.map(i));case n.expressionTypes.TERM:const c=e;return r.createTermExpression(c.term);default:throw new Error("Unknown Expression type "+e.expressionType)}}static createUniqueVariable(e,t,r){let n=0,i=e;for(;t[i];)i=e+n++;return r.variable(i)}}t.default=a},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(5),i=r(23),a=r(10);t.Util=class{constructor(e){this.nodeHandlers={},this.nodeValueHandlers={},this.directiveNodeHandlers={},this.settings=e,this.dataFactory=e.dataFactory||n,this.operationFactory=new a.Factory(this.dataFactory),this.contextParser=new i.ContextParser}registerNodeHandler(e){this.nodeHandlers[e.targetKind]=e}registerNodeValueHandler(e){this.nodeValueHandlers[e.targetKind]=e}registerDirectiveNodeHandler(e){this.directiveNodeHandlers[e.targetKind]=e}handleNode(e,t){const r=this.nodeHandlers[e.kind];if(!r)throw new Error(`Unsupported GraphQL node '${e.kind}'`);return r.handle(e,t)}handleNodeValue(e,t,r){const n=this.nodeValueHandlers[e.kind];if(!n)throw new Error(`Unsupported GraphQL value node '${e.kind}'`);return n.handle(e,t,r)}handleDirectiveNode(e,t){const r=this.directiveNodeHandlers[e.directive.name.value];return r?r.handle(e,t):null}joinOperations(e){if(1===e.length)return e[0];const t=[],r=[];for(const n of e)"bgp"===n.type?t.push(n):r.push(n);return t.length===e.length?this.joinOperationsAsBgp(t):r.length===e.length?this.joinOperationsAsNestedJoin(r):this.joinOperationsAsNestedJoin([this.joinOperationsAsBgp(t),this.joinOperationsAsNestedJoin(r)])}joinOperationsAsBgp(e){return this.operationFactory.createBgp([].concat.apply([],e.map(e=>e.patterns)))}joinOperationsAsNestedJoin(e){return e.reverse().reduce((e,t)=>e?this.operationFactory.createJoin(t,e):t,null)}appendFieldToPath(e,t){return e.concat([t])}getFieldLabel(e){return(e.alias?e.alias:e.name).value}nameToVariable(e,t){return this.dataFactory.variable((t.path.length?t.path.join(this.settings.variableDelimiter)+this.settings.variableDelimiter:"")+e)}valueToNamedNode(e,t){let r=t[e];if(this.settings.requireContext&&!r)throw new Error("No context entry was found for "+e);return r&&"string"!=typeof r&&(r=r["@id"]),this.dataFactory.namedNode(r||e)}getArgument(e,t){if(e)for(const r of e)if(r.name.value===t)return r;return null}newTypePattern(e,t,r){return this.operationFactory.createPattern(e,this.dataFactory.namedNode("http://www.w3.org/1999/02/22-rdf-syntax-ns#type"),this.valueToNamedNode(t.name.value,r.context),r.graph)}createQuadPattern(e,t,r,n,i){const a=this.valueToNamedNode(t.value,i);return i&&i[t.value]&&i[t.value]["@reverse"]?this.operationFactory.createPattern(r,a,e,n):this.operationFactory.createPattern(e,a,r,n)}createQuadPath(e,t,r,n,i,a){const o=this.valueToNamedNode(t.value,a);let s=this.operationFactory.createLink(o);for(const e of r.values){if("EnumValue"!==e.kind)throw new Error("Invalid value type for 'alt' argument, must be EnumValue, but got "+e.kind);s=this.operationFactory.createAlt(s,this.operationFactory.createLink(this.valueToNamedNode(e.value,a)))}return a&&a[t.value]&&a[t.value]["@reverse"]?this.operationFactory.createPath(n,s,e,i):this.operationFactory.createPath(e,s,n,i)}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(466))},function(e,t,r){"use strict";function n(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}Object.defineProperty(t,"__esModule",{value:!0}),n(r(468)),n(r(469)),n(r(470)),n(r(471))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(3);t.SparqlJsonBindingsTransformer=class extends n.Transform{constructor(e){super({objectMode:!0}),this.parser=e}_transform(e,t,r){r(null,this.parser.parseJsonBindings(e))}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(68);t.storeStream=function(e){const t=new n.Store;return new Promise(r=>t.import(e).once("end",()=>r(t)))}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(474);t.GraphQlQueryEngine=class{constructor(e){this.comunicaEngine=e}async query(e,t){const{data:r}=await this.comunicaEngine.resultToString(await this.comunicaEngine.query(e,t),"application/sparql-results+json");return JSON.parse(await n(r))}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(477))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(478))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(479))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(482))},function(e,t,r){"use strict";function n(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}Object.defineProperty(t,"__esModule",{value:!0}),n(r(209)),n(r(485))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(0);t.ActorHttpInvalidate=class extends n.Actor{constructor(e){super(e)}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(486))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(487))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(491))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(492))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(493))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(0);class i extends n.Actor{constructor(e){super(e)}static getSafeBindings(e){return i.validateQueryOutput(e,"bindings"),e}static getSafeQuads(e){return i.validateQueryOutput(e,"quads"),e}static getSafeBoolean(e){return i.validateQueryOutput(e,"boolean"),e}static cachifyMetadata(e){let t=null;return()=>t||(t=e())}static validateQueryOutput(e,t){if(e.type!==t)throw new Error("Invalid query output type: Expected '"+t+"' but got '"+e.type+"'")}static getExpressionContext(e){if(e){return{now:e.get(t.KEY_CONTEXT_QUERY_TIMESTAMP),baseIRI:e.get(t.KEY_CONTEXT_BASEIRI)}}return{}}}t.ActorQueryOperation=i,t.KEY_CONTEXT_BGP_CURRENTMETADATA="@comunica/bus-query-operation:bgpCurrentMetadata",t.KEY_CONTEXT_BGP_PARENTMETADATA="@comunica/bus-query-operation:bgpParentMetadata",t.KEY_CONTEXT_BGP_PATTERNBINDINGS="@comunica/bus-query-operation:bgpPatternBindings",t.KEY_CONTEXT_PATTERN_PARENTMETADATA="@comunica/bus-query-operation:patternParentMetadata",t.KEY_CONTEXT_BASEIRI="@comunica/actor-init-sparql:baseIRI",t.KEY_CONTEXT_QUERY_TIMESTAMP="@comunica/actor-init-sparql:queryTimestamp"},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(215);t.ActorQueryOperationTyped=class extends n.ActorQueryOperation{constructor(e,t){if(super(Object.assign({},e,{operationName:t})),!this.operationName)throw new Error('A valid "operationName" argument must be provided.')}async test(e){if(!e.operation)throw new Error("Missing field 'operation' in the query operation action: "+r(66).inspect(e));if(e.operation.type!==this.operationName)throw new Error("Actor "+this.name+" only supports "+this.operationName+" operations, but got "+e.operation.type);const t=e.operation;return this.testOperation(t,e.context)}async run(e){const t=e.operation,r=await this.runOperation(t,e.context);return r.metadata&&(r.metadata=n.ActorQueryOperation.cachifyMetadata(r.metadata)),r}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(496))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(497))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(503))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(3);t.SparqlXmlBindingsTransformer=class extends n.Transform{constructor(e){super({objectMode:!0}),this.parser=e}_transform(e,t,r){let n;try{n=this.parser.parseXmlBindings(e)}catch(e){return r(e)}r(null,n)}}},function(e,t,r){"use strict";function n(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}Object.defineProperty(t,"__esModule",{value:!0}),n(r(222)),n(r(519))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(37),i=r(517),a=r(65);class o extends i.ActorRdfDereferenceMediaMappings{constructor(e){super(e)}async test(e){if(!e.url.startsWith("http:")&&!e.url.startsWith("https:"))throw new Error("This actor can only handle URLs that start with 'http' or 'https'.");return!0}async run(e){const t=(await this.mediatorRdfParseMediatypes.mediate({context:e.context,mediaTypes:!0})).mediaTypes,r=this.mediaTypesToAcceptString(t,this.getMaxAcceptHeaderLength()),i=new Headers;i.append("Accept",r);const s={context:e.context,input:e.url,init:{headers:i}},c=await this.mediatorHttp.mediate(s),u=a.resolve(c.url,e.url),l=n.ActorHttp.toNodeReadable(c.body);if(200!==c.status)throw new Error(`Could not retrieve ${e.url} (${c.status}: ${c.statusText||"unknown error"})`);let f=c.headers.has("content-type")?o.REGEX_MEDIATYPE.exec(c.headers.get("content-type"))[0]:null;f&&"text/plain"!==f||(f=this.getMediaTypeFromExtension(c.url));const d={baseIRI:u,headers:c.headers,input:l},h=(await this.mediatorRdfParseHandle.mediate({context:e.context,handle:d,handleMediaType:f})).handle;return{url:u,quads:h.quads,triples:h.triples}}mediaTypesToAcceptString(e,t){t-=10;const r=[],n=Object.keys(e).map(t=>({mediaType:t,priority:e[t]})).sort((e,t)=>t.priority-e.priority);let i=0;for(const e of n){const n=e.mediaType+(1!==e.priority?";q="+e.priority.toFixed(3).replace(/0*$/,""):"");if(i+n.length>t){r.push("*/*;q=0.1");break}r.push(n),i+=n.length}return r.length?r.join(","):"*/*"}}o.REGEX_MEDIATYPE=/^[^ ;]*/,t.ActorRdfDereferenceHttpParseBase=o},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(0);t.ActorRdfDereference=class extends n.Actor{constructor(e){super(e)}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(520))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(522))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(525))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(526))},function(e,t,r){"use strict";function n(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}Object.defineProperty(t,"__esModule",{value:!0}),n(r(528)),n(r(229))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(531);t.MediatedQuadSource=class{constructor(e,t,r,n,i){this.cacheSize=e,this.context=t,this.firstUrl=r,this.forceSourceType=n,this.mediators=i}matchLazy(e,t,r,i){if(e instanceof RegExp||t instanceof RegExp||r instanceof RegExp||i instanceof RegExp)throw new Error("MediatedQuadSource does not support matching by regular expressions.");const a=new n.MediatedLinkedRdfSourcesAsyncRdfIterator(this.cacheSize,this.context,this.forceSourceType,e,t,r,i,this.firstUrl,this.mediators);return this.sourcesState?a.setSourcesState(this.sourcesState):(a.setSourcesState(),this.sourcesState=a.sourcesState),a}match(e,t,r,n){return this.matchLazy(e,t,r,n)}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(533));var n=r(232);function i(){return r(539)}t.bindingsStreamToGraphQl=n.bindingsStreamToGraphQl,t.newEngine=i,t.evaluateQuery=function(e,t){return i().query(e,t)}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(536))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(233));const n=r(233).ActorSparqlSerializeTree.bindingsStreamToGraphQl;t.bindingsStreamToGraphQl=n},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(28),i=r(0),a=r(199),o=r(3);class s extends n.ActorSparqlSerializeFixedMediaTypes{constructor(e){super(e)}static bindingsStreamToGraphQl(e,t,r){const n=i.ensureActionContext(t);return new Promise((t,i)=>{const o=[],s=new a.Converter(r),c={singularizeVariables:n.get("@comunica/actor-init-sparql:singularizeVariables")||{}};e.on("error",i),e.on("data",e=>{const t=e.toJS(),r={};for(const e in t){const n=t[e];n&&(r[e.substr(1)]=n)}o.push(r)}),e.on("end",()=>{t(s.bindingsToTree(o,c))})})}async testHandleChecked(e){if("bindings"!==e.type)throw new Error("This actor can only handle bindings streams.");return!0}async runHandle(e,t){const r=new o.Readable;r._read=()=>{};const n=e.bindingsStream;return n.on("error",e=>r.emit("error",e)),s.bindingsStreamToGraphQl(n,e.context,{materializeRdfJsTerms:!0}).then(e=>{r.push(JSON.stringify(e,null," ")),r.push(null)}),{data:r}}}t.ActorSparqlSerializeTree=s},function(e,t,r){"use strict";var n=r(235),i=r(545),a=r(548);function o(e){return e&&e.rel}function s(e,t){return t.rel.split(/\s+/).forEach(function(r){e[r]=a(t,{rel:r})}),e}function c(e,t){var r=t.match(/\s*(.+)\s*=\s*"?([^"]+)"?/);return r&&(e[r[1]]=r[2]),e}function u(e){try{var t=e.match(/<?([^>]*)>(.*)/),r=t[1],o=t[2].split(";"),s=i.parse(r),u=n.parse(s.query);o.shift();var l=o.reduce(c,{});return(l=a(u,l)).url=r,l}catch(e){return null}}e.exports=function(e){return e?e.split(/,\s*</).map(u).filter(o).reduce(s,{}):null}},function(e,t,r){"use strict";t.decode=t.parse=r(543),t.encode=t.stringify=r(544)},function(e,t,r){"use strict";function n(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}Object.defineProperty(t,"__esModule",{value:!0}),n(r(551)),n(r(552))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(23);class i{static termToValue(e,t,r={compactIds:!1,useNativeTypes:!1}){switch(e.termType){case"NamedNode":const a=n.ContextParser.compactIri(e.value,t,r.vocab);return r.compactIds?a:{"@id":a};case"DefaultGraph":return r.compactIds?e.value:{"@id":e.value};case"BlankNode":const o=`_:${e.value}`;return r.compactIds?o:{"@id":o};case"Literal":const s=e.datatype.value===i.XSD_STRING,c={"@value":!s&&r.useNativeTypes?i.stringToNativeType(e.value,e.datatype.value):e.value};return e.language?Object.assign({},c,{"@language":e.language}):s||"string"!=typeof c["@value"]?c:Object.assign({},c,{"@type":e.datatype.value})}}static stringToNativeType(e,t){if(t.startsWith(i.XSD)){switch(t.substr(i.XSD.length)){case"boolean":if("true"===e)return!0;if("false"===e)return!1;throw new Error(`Invalid xsd:boolean value '${e}'`);case"integer":case"number":case"int":case"byte":case"long":const r=parseInt(e,10);if(isNaN(r))throw new Error(`Invalid xsd:integer value '${e}'`);return r;case"float":case"decimal":case"double":const n=parseFloat(e);if(isNaN(n))throw new Error(`Invalid xsd:float value '${e}'`);return n}}return e}}i.XSD="http://www.w3.org/2001/XMLSchema#",i.XSD_STRING=i.XSD+"string",i.RDF="http://www.w3.org/1999/02/22-rdf-syntax-ns#",i.RDF_TYPE=i.RDF+"type",t.Util=i},function(e,t,r){(function(n,i,a){var o;
10/*!
11 * @overview es6-promise - a tiny implementation of Promises/A+.
12 * @copyright Copyright (c) 2014 Yehuda Katz, Tom Dale, Stefan Penner and contributors (Conversion to ES6 API by Jake Archibald)
13 * @license Licensed under MIT license
14 * See https://raw.githubusercontent.com/jakearchibald/es6-promise/master/LICENSE
15 * @version 2.3.0
16 */
17(function(){"use strict";function s(e){return"function"==typeof e}var c,u,l=Array.isArray?Array.isArray:function(e){return"[object Array]"===Object.prototype.toString.call(e)},f=0,d=function(e,t){O[f]=e,O[f+1]=t,2===(f+=2)&&(u?u(A):v())};var h="undefined"!=typeof window?window:void 0,p=h||{},y=p.MutationObserver||p.WebKitMutationObserver,m=void 0!==n&&"[object process]"==={}.toString.call(n),g="undefined"!=typeof Uint8ClampedArray&&"undefined"!=typeof importScripts&&"undefined"!=typeof MessageChannel;function b(){return function(){setTimeout(A,1)}}var v,_,w,S,E,x,T,O=new Array(1e3);function A(){for(var e=0;e<f;e+=2){(0,O[e])(O[e+1]),O[e]=void 0,O[e+1]=void 0}f=0}function I(){}m?(x=n.nextTick,T=n.versions.node.match(/^(?:(\d+)\.)?(?:(\d+)\.)?(\*|\d+)$/),Array.isArray(T)&&"0"===T[1]&&"10"===T[2]&&(x=i),v=function(){x(A)}):y?(w=0,S=new y(A),E=document.createTextNode(""),S.observe(E,{characterData:!0}),v=function(){E.data=w=++w%2}):g?((_=new MessageChannel).port1.onmessage=A,v=function(){_.port2.postMessage(0)}):v=void 0===h?function(){try{var e=r(559);return c=e.runOnLoop||e.runOnContext,function(){c(A)}}catch(e){return b()}}():b();var N=void 0,R=1,k=2,P=new B;function j(e,t){if(t.constructor===e.constructor)!function(e,t){t._state===R?M(e,t._result):t._state===k?L(e,t._result):q(t,void 0,function(t){D(e,t)},function(t){L(e,t)})}(e,t);else{var r=function(e){try{return e.then}catch(e){return P.error=e,P}}(t);r===P?L(e,P.error):void 0===r?M(e,t):s(r)?function(e,t,r){d(function(e){var n=!1,i=function(e,t,r,n){try{e.call(t,r,n)}catch(e){return e}}(r,t,function(r){n||(n=!0,t!==r?D(e,r):M(e,r))},function(t){n||(n=!0,L(e,t))},e._label);!n&&i&&(n=!0,L(e,i))},e)}(e,t,r):M(e,t)}}function D(e,t){var r;e===t?L(e,new TypeError("You cannot resolve a promise with itself")):"function"==typeof(r=t)||"object"==typeof r&&null!==r?j(e,t):M(e,t)}function C(e){e._onerror&&e._onerror(e._result),F(e)}function M(e,t){e._state===N&&(e._result=t,e._state=R,0!==e._subscribers.length&&d(F,e))}function L(e,t){e._state===N&&(e._state=k,e._result=t,d(C,e))}function q(e,t,r,n){var i=e._subscribers,a=i.length;e._onerror=null,i[a]=t,i[a+R]=r,i[a+k]=n,0===a&&e._state&&d(F,e)}function F(e){var t=e._subscribers,r=e._state;if(0!==t.length){for(var n,i,a=e._result,o=0;o<t.length;o+=3)n=t[o],i=t[o+r],n?V(r,n,i,a):i(a);e._subscribers.length=0}}function B(){this.error=null}var U=new B;function V(e,t,r,n){var i,a,o,c,u=s(r);if(u){if((i=function(e,t){try{return e(t)}catch(e){return U.error=e,U}}(r,n))===U?(c=!0,a=i.error,i=null):o=!0,t===i)return void L(t,new TypeError("A promises callback cannot return that same promise."))}else i=n,o=!0;t._state!==N||(u&&o?D(t,i):c?L(t,a):e===R?M(t,i):e===k&&L(t,i))}function H(e,t){this._instanceConstructor=e,this.promise=new e(I),this._validateInput(t)?(this._input=t,this.length=t.length,this._remaining=t.length,this._init(),0===this.length?M(this.promise,this._result):(this.length=this.length||0,this._enumerate(),0===this._remaining&&M(this.promise,this._result))):L(this.promise,this._validationError())}H.prototype._validateInput=function(e){return l(e)},H.prototype._validationError=function(){return new Error("Array Methods must be provided an Array")},H.prototype._init=function(){this._result=new Array(this.length)};var z=H;H.prototype._enumerate=function(){for(var e=this.length,t=this.promise,r=this._input,n=0;t._state===N&&n<e;n++)this._eachEntry(r[n],n)},H.prototype._eachEntry=function(e,t){var r,n=this._instanceConstructor;"object"==typeof(r=e)&&null!==r?e.constructor===n&&e._state!==N?(e._onerror=null,this._settledAt(e._state,t,e._result)):this._willSettleAt(n.resolve(e),t):(this._remaining--,this._result[t]=e)},H.prototype._settledAt=function(e,t,r){var n=this.promise;n._state===N&&(this._remaining--,e===k?L(n,r):this._result[t]=r),0===this._remaining&&M(n,this._result)},H.prototype._willSettleAt=function(e,t){var r=this;q(e,void 0,function(e){r._settledAt(R,t,e)},function(e){r._settledAt(k,t,e)})};var G=function(e){return new z(this,e).promise};var Q=function(e){var t=new this(I);if(!l(e))return L(t,new TypeError("You must pass an array to race.")),t;var r=e.length;function n(e){D(t,e)}function i(e){L(t,e)}for(var a=0;t._state===N&&a<r;a++)q(this.resolve(e[a]),void 0,n,i);return t};var X=function(e){if(e&&"object"==typeof e&&e.constructor===this)return e;var t=new this(I);return D(t,e),t};var $=function(e){var t=new this(I);return L(t,e),t},J=0;var Y=K;function K(e){this._id=J++,this._state=void 0,this._result=void 0,this._subscribers=[],I!==e&&(s(e)||function(){throw new TypeError("You must pass a resolver function as the first argument to the promise constructor")}(),this instanceof K||function(){throw new TypeError("Failed to construct 'Promise': Please use the 'new' operator, this object constructor cannot be called as a function.")}(),function(e,t){try{t(function(t){D(e,t)},function(t){L(e,t)})}catch(t){L(e,t)}}(this,e))}K.all=G,K.race=Q,K.resolve=X,K.reject=$,K._setScheduler=function(e){u=e},K._setAsap=function(e){d=e},K._asap=d,K.prototype={constructor:K,then:function(e,t){var r=this,n=r._state;if(n===R&&!e||n===k&&!t)return this;var i=new this.constructor(I),a=r._result;if(n){var o=arguments[n-1];d(function(){V(n,i,o,a)})}else q(r,i,e,t);return i},catch:function(e){return this.then(null,e)}};var W=function(){var e;if(void 0!==a)e=a;else if("undefined"!=typeof self)e=self;else try{e=Function("return this")()}catch(e){throw new Error("polyfill failed because global object is unavailable in this environment")}var t=e.Promise;t&&"[object Promise]"===Object.prototype.toString.call(t.resolve())&&!t.cast||(e.Promise=Y)},Z={Promise:Y,polyfill:W};void 0===(o=function(){return Z}.call(t,r,t,e))||(e.exports=o),W()}).call(this)}).call(this,r(13),r(15).setImmediate,r(9))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(584))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(585))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(586))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(587))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(588))},function(e,t,r){(function(t){var r=200,n="__lodash_hash_undefined__",i="[object Function]",a="[object GeneratorFunction]",o=/^\[object .+?Constructor\]$/,s="object"==typeof t&&t&&t.Object===Object&&t,c="object"==typeof self&&self&&self.Object===Object&&self,u=s||c||Function("return this")();function l(e,t){return!!(e?e.length:0)&&function(e,t,r){if(t!=t)return function(e,t,r,n){var i=e.length,a=r+(n?1:-1);for(;n?a--:++a<i;)if(t(e[a],a,e))return a;return-1}(e,d,r);var n=r-1,i=e.length;for(;++n<i;)if(e[n]===t)return n;return-1}(e,t,0)>-1}function f(e,t,r){for(var n=-1,i=e?e.length:0;++n<i;)if(r(t,e[n]))return!0;return!1}function d(e){return e!=e}function h(e,t){return e.has(t)}function p(e){var t=-1,r=Array(e.size);return e.forEach(function(e){r[++t]=e}),r}var y,m=Array.prototype,g=Function.prototype,b=Object.prototype,v=u["__core-js_shared__"],_=(y=/[^.]+$/.exec(v&&v.keys&&v.keys.IE_PROTO||""))?"Symbol(src)_1."+y:"",w=g.toString,S=b.hasOwnProperty,E=b.toString,x=RegExp("^"+w.call(S).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),T=m.splice,O=L(u,"Map"),A=L(u,"Set"),I=L(Object,"create");function N(e){var t=-1,r=e?e.length:0;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}function R(e){var t=-1,r=e?e.length:0;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}function k(e){var t=-1,r=e?e.length:0;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}function P(e){var t=-1,r=e?e.length:0;for(this.__data__=new k;++t<r;)this.add(e[t])}function j(e,t){for(var r,n,i=e.length;i--;)if((r=e[i][0])===(n=t)||r!=r&&n!=n)return i;return-1}function D(e){return!(!q(e)||(t=e,_&&_ in t))&&(function(e){var t=q(e)?E.call(e):"";return t==i||t==a}(e)||function(e){var t=!1;if(null!=e&&"function"!=typeof e.toString)try{t=!!(e+"")}catch(e){}return t}(e)?x:o).test(function(e){if(null!=e){try{return w.call(e)}catch(e){}try{return e+""}catch(e){}}return""}(e));var t}N.prototype.clear=function(){this.__data__=I?I(null):{}},N.prototype.delete=function(e){return this.has(e)&&delete this.__data__[e]},N.prototype.get=function(e){var t=this.__data__;if(I){var r=t[e];return r===n?void 0:r}return S.call(t,e)?t[e]:void 0},N.prototype.has=function(e){var t=this.__data__;return I?void 0!==t[e]:S.call(t,e)},N.prototype.set=function(e,t){return this.__data__[e]=I&&void 0===t?n:t,this},R.prototype.clear=function(){this.__data__=[]},R.prototype.delete=function(e){var t=this.__data__,r=j(t,e);return!(r<0)&&(r==t.length-1?t.pop():T.call(t,r,1),!0)},R.prototype.get=function(e){var t=this.__data__,r=j(t,e);return r<0?void 0:t[r][1]},R.prototype.has=function(e){return j(this.__data__,e)>-1},R.prototype.set=function(e,t){var r=this.__data__,n=j(r,e);return n<0?r.push([e,t]):r[n][1]=t,this},k.prototype.clear=function(){this.__data__={hash:new N,map:new(O||R),string:new N}},k.prototype.delete=function(e){return M(this,e).delete(e)},k.prototype.get=function(e){return M(this,e).get(e)},k.prototype.has=function(e){return M(this,e).has(e)},k.prototype.set=function(e,t){return M(this,e).set(e,t),this},P.prototype.add=P.prototype.push=function(e){return this.__data__.set(e,n),this},P.prototype.has=function(e){return this.__data__.has(e)};var C=A&&1/p(new A([,-0]))[1]==1/0?function(e){return new A(e)}:function(){};function M(e,t){var r,n,i=e.__data__;return("string"==(n=typeof(r=t))||"number"==n||"symbol"==n||"boolean"==n?"__proto__"!==r:null===r)?i["string"==typeof t?"string":"hash"]:i.map}function L(e,t){var r=function(e,t){return null==e?void 0:e[t]}(e,t);return D(r)?r:void 0}function q(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}e.exports=function(e){return e&&e.length?function(e,t,n){var i=-1,a=l,o=e.length,s=!0,c=[],u=c;if(n)s=!1,a=f;else if(o>=r){var d=t?null:C(e);if(d)return p(d);s=!1,a=h,u=new P}else u=t?[]:c;e:for(;++i<o;){var y=e[i],m=t?t(y):y;if(y=n||0!==y?y:0,s&&m==m){for(var g=u.length;g--;)if(u[g]===m)continue e;t&&u.push(m),c.push(y)}else a(u,m,n)||(u!==c&&u.push(m),c.push(y))}return c}(e):[]}}).call(this,r(9))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(589))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(591))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(593))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(4),i=r(595),a=r(8);class o extends n.ActorQueryOperationTypedMediated{constructor(e,t){if(super(e,t),!o.doesHashAlgorithmExist(this.hashAlgorithm))throw new Error("The given hash algorithm is not present in this version of Node: "+this.hashAlgorithm);if(!o.doesDigestAlgorithmExist(this.digestAlgorithm))throw new Error("The given digest algorithm is not present in this version of Node: "+this.digestAlgorithm)}static doesHashAlgorithmExist(e){return i.getHashes().indexOf(e)>=0}static doesDigestAlgorithmExist(e){return["latin1","hex","base64"].indexOf(e)>=0}static hash(e,t,n){const o=i.createHash(e);return o.update(r(664)(n.map(a.termToString))),o.digest(t)}async testOperation(e,t){return!0}}t.AbstractFilterHash=o},function(e,t,r){"use strict";var n=r(2).Buffer,i=r(3).Transform;function a(e){i.call(this),this._block=n.allocUnsafe(e),this._blockSize=e,this._blockOffset=0,this._length=[0,0,0,0],this._finalized=!1}r(1)(a,i),a.prototype._transform=function(e,t,r){var n=null;try{this.update(e,t)}catch(e){n=e}r(n)},a.prototype._flush=function(e){var t=null;try{this.push(this.digest())}catch(e){t=e}e(t)},a.prototype.update=function(e,t){if(function(e,t){if(!n.isBuffer(e)&&"string"!=typeof e)throw new TypeError(t+" must be a string or a buffer")}(e,"Data"),this._finalized)throw new Error("Digest already called");n.isBuffer(e)||(e=n.from(e,t));for(var r=this._block,i=0;this._blockOffset+e.length-i>=this._blockSize;){for(var a=this._blockOffset;a<this._blockSize;)r[a++]=e[i++];this._update(),this._blockOffset=0}for(;i<e.length;)r[this._blockOffset++]=e[i++];for(var o=0,s=8*e.length;s>0;++o)this._length[o]+=s,(s=this._length[o]/4294967296|0)>0&&(this._length[o]-=4294967296*s);return this},a.prototype._update=function(){throw new Error("_update is not implemented")},a.prototype.digest=function(e){if(this._finalized)throw new Error("Digest already called");this._finalized=!0;var t=this._digest();void 0!==e&&(t=t.toString(e)),this._block.fill(0),this._blockOffset=0;for(var r=0;r<4;++r)this._length[r]=0;return t},a.prototype._digest=function(){throw new Error("_digest is not implemented")},e.exports=a},function(e,t,r){var n=r(1),i=r(45),a=r(2).Buffer,o=[1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298],s=new Array(64);function c(){this.init(),this._w=s,i.call(this,64,56)}function u(e,t,r){return r^e&(t^r)}function l(e,t,r){return e&t|r&(e|t)}function f(e){return(e>>>2|e<<30)^(e>>>13|e<<19)^(e>>>22|e<<10)}function d(e){return(e>>>6|e<<26)^(e>>>11|e<<21)^(e>>>25|e<<7)}function h(e){return(e>>>7|e<<25)^(e>>>18|e<<14)^e>>>3}n(c,i),c.prototype.init=function(){return this._a=1779033703,this._b=3144134277,this._c=1013904242,this._d=2773480762,this._e=1359893119,this._f=2600822924,this._g=528734635,this._h=1541459225,this},c.prototype._update=function(e){for(var t,r=this._w,n=0|this._a,i=0|this._b,a=0|this._c,s=0|this._d,c=0|this._e,p=0|this._f,y=0|this._g,m=0|this._h,g=0;g<16;++g)r[g]=e.readInt32BE(4*g);for(;g<64;++g)r[g]=0|(((t=r[g-2])>>>17|t<<15)^(t>>>19|t<<13)^t>>>10)+r[g-7]+h(r[g-15])+r[g-16];for(var b=0;b<64;++b){var v=m+d(c)+u(c,p,y)+o[b]+r[b]|0,_=f(n)+l(n,i,a)|0;m=y,y=p,p=c,c=s+v|0,s=a,a=i,i=n,n=v+_|0}this._a=n+this._a|0,this._b=i+this._b|0,this._c=a+this._c|0,this._d=s+this._d|0,this._e=c+this._e|0,this._f=p+this._f|0,this._g=y+this._g|0,this._h=m+this._h|0},c.prototype._hash=function(){var e=a.allocUnsafe(32);return e.writeInt32BE(this._a,0),e.writeInt32BE(this._b,4),e.writeInt32BE(this._c,8),e.writeInt32BE(this._d,12),e.writeInt32BE(this._e,16),e.writeInt32BE(this._f,20),e.writeInt32BE(this._g,24),e.writeInt32BE(this._h,28),e},e.exports=c},function(e,t,r){var n=r(1),i=r(45),a=r(2).Buffer,o=[1116352408,3609767458,1899447441,602891725,3049323471,3964484399,3921009573,2173295548,961987163,4081628472,1508970993,3053834265,2453635748,2937671579,2870763221,3664609560,3624381080,2734883394,310598401,1164996542,607225278,1323610764,1426881987,3590304994,1925078388,4068182383,2162078206,991336113,2614888103,633803317,3248222580,3479774868,3835390401,2666613458,4022224774,944711139,264347078,2341262773,604807628,2007800933,770255983,1495990901,1249150122,1856431235,1555081692,3175218132,1996064986,2198950837,2554220882,3999719339,2821834349,766784016,2952996808,2566594879,3210313671,3203337956,3336571891,1034457026,3584528711,2466948901,113926993,3758326383,338241895,168717936,666307205,1188179964,773529912,1546045734,1294757372,1522805485,1396182291,2643833823,1695183700,2343527390,1986661051,1014477480,2177026350,1206759142,2456956037,344077627,2730485921,1290863460,2820302411,3158454273,3259730800,3505952657,3345764771,106217008,3516065817,3606008344,3600352804,1432725776,4094571909,1467031594,275423344,851169720,430227734,3100823752,506948616,1363258195,659060556,3750685593,883997877,3785050280,958139571,3318307427,1322822218,3812723403,1537002063,2003034995,1747873779,3602036899,1955562222,1575990012,2024104815,1125592928,2227730452,2716904306,2361852424,442776044,2428436474,593698344,2756734187,3733110249,3204031479,2999351573,3329325298,3815920427,3391569614,3928383900,3515267271,566280711,3940187606,3454069534,4118630271,4000239992,116418474,1914138554,174292421,2731055270,289380356,3203993006,460393269,320620315,685471733,587496836,852142971,1086792851,1017036298,365543100,1126000580,2618297676,1288033470,3409855158,1501505948,4234509866,1607167915,987167468,1816402316,1246189591],s=new Array(160);function c(){this.init(),this._w=s,i.call(this,128,112)}function u(e,t,r){return r^e&(t^r)}function l(e,t,r){return e&t|r&(e|t)}function f(e,t){return(e>>>28|t<<4)^(t>>>2|e<<30)^(t>>>7|e<<25)}function d(e,t){return(e>>>14|t<<18)^(e>>>18|t<<14)^(t>>>9|e<<23)}function h(e,t){return(e>>>1|t<<31)^(e>>>8|t<<24)^e>>>7}function p(e,t){return(e>>>1|t<<31)^(e>>>8|t<<24)^(e>>>7|t<<25)}function y(e,t){return(e>>>19|t<<13)^(t>>>29|e<<3)^e>>>6}function m(e,t){return(e>>>19|t<<13)^(t>>>29|e<<3)^(e>>>6|t<<26)}function g(e,t){return e>>>0<t>>>0?1:0}n(c,i),c.prototype.init=function(){return this._ah=1779033703,this._bh=3144134277,this._ch=1013904242,this._dh=2773480762,this._eh=1359893119,this._fh=2600822924,this._gh=528734635,this._hh=1541459225,this._al=4089235720,this._bl=2227873595,this._cl=4271175723,this._dl=1595750129,this._el=2917565137,this._fl=725511199,this._gl=4215389547,this._hl=327033209,this},c.prototype._update=function(e){for(var t=this._w,r=0|this._ah,n=0|this._bh,i=0|this._ch,a=0|this._dh,s=0|this._eh,c=0|this._fh,b=0|this._gh,v=0|this._hh,_=0|this._al,w=0|this._bl,S=0|this._cl,E=0|this._dl,x=0|this._el,T=0|this._fl,O=0|this._gl,A=0|this._hl,I=0;I<32;I+=2)t[I]=e.readInt32BE(4*I),t[I+1]=e.readInt32BE(4*I+4);for(;I<160;I+=2){var N=t[I-30],R=t[I-30+1],k=h(N,R),P=p(R,N),j=y(N=t[I-4],R=t[I-4+1]),D=m(R,N),C=t[I-14],M=t[I-14+1],L=t[I-32],q=t[I-32+1],F=P+M|0,B=k+C+g(F,P)|0;B=(B=B+j+g(F=F+D|0,D)|0)+L+g(F=F+q|0,q)|0,t[I]=B,t[I+1]=F}for(var U=0;U<160;U+=2){B=t[U],F=t[U+1];var V=l(r,n,i),H=l(_,w,S),z=f(r,_),G=f(_,r),Q=d(s,x),X=d(x,s),$=o[U],J=o[U+1],Y=u(s,c,b),K=u(x,T,O),W=A+X|0,Z=v+Q+g(W,A)|0;Z=(Z=(Z=Z+Y+g(W=W+K|0,K)|0)+$+g(W=W+J|0,J)|0)+B+g(W=W+F|0,F)|0;var ee=G+H|0,te=z+V+g(ee,G)|0;v=b,A=O,b=c,O=T,c=s,T=x,s=a+Z+g(x=E+W|0,E)|0,a=i,E=S,i=n,S=w,n=r,w=_,r=Z+te+g(_=W+ee|0,W)|0}this._al=this._al+_|0,this._bl=this._bl+w|0,this._cl=this._cl+S|0,this._dl=this._dl+E|0,this._el=this._el+x|0,this._fl=this._fl+T|0,this._gl=this._gl+O|0,this._hl=this._hl+A|0,this._ah=this._ah+r+g(this._al,_)|0,this._bh=this._bh+n+g(this._bl,w)|0,this._ch=this._ch+i+g(this._cl,S)|0,this._dh=this._dh+a+g(this._dl,E)|0,this._eh=this._eh+s+g(this._el,x)|0,this._fh=this._fh+c+g(this._fl,T)|0,this._gh=this._gh+b+g(this._gl,O)|0,this._hh=this._hh+v+g(this._hl,A)|0},c.prototype._hash=function(){var e=a.allocUnsafe(64);function t(t,r,n){e.writeInt32BE(t,n),e.writeInt32BE(r,n+4)}return t(this._ah,this._al,0),t(this._bh,this._bl,8),t(this._ch,this._cl,16),t(this._dh,this._dl,24),t(this._eh,this._el,32),t(this._fh,this._fl,40),t(this._gh,this._gl,48),t(this._hh,this._hl,56),e},e.exports=c},function(e,t,r){"use strict";var n=r(1),i=r(600),a=r(29),o=r(2).Buffer,s=r(253),c=r(102),u=r(103),l=o.alloc(128);function f(e,t){a.call(this,"digest"),"string"==typeof t&&(t=o.from(t));var r="sha512"===e||"sha384"===e?128:64;(this._alg=e,this._key=t,t.length>r)?t=("rmd160"===e?new c:u(e)).update(t).digest():t.length<r&&(t=o.concat([t,l],r));for(var n=this._ipad=o.allocUnsafe(r),i=this._opad=o.allocUnsafe(r),s=0;s<r;s++)n[s]=54^t[s],i[s]=92^t[s];this._hash="rmd160"===e?new c:u(e),this._hash.update(n)}n(f,a),f.prototype._update=function(e){this._hash.update(e)},f.prototype._final=function(){var e=this._hash.digest();return("rmd160"===this._alg?new c:u(this._alg)).update(this._opad).update(e).digest()},e.exports=function(e,t){return"rmd160"===(e=e.toLowerCase())||"ripemd160"===e?new f("rmd160",t):"md5"===e?new i(s,t):new f(e,t)}},function(e,t,r){var n=r(101);e.exports=function(e){return(new n).update(e).digest()}},function(e){e.exports=JSON.parse('{"sha224WithRSAEncryption":{"sign":"rsa","hash":"sha224","id":"302d300d06096086480165030402040500041c"},"RSA-SHA224":{"sign":"ecdsa/rsa","hash":"sha224","id":"302d300d06096086480165030402040500041c"},"sha256WithRSAEncryption":{"sign":"rsa","hash":"sha256","id":"3031300d060960864801650304020105000420"},"RSA-SHA256":{"sign":"ecdsa/rsa","hash":"sha256","id":"3031300d060960864801650304020105000420"},"sha384WithRSAEncryption":{"sign":"rsa","hash":"sha384","id":"3041300d060960864801650304020205000430"},"RSA-SHA384":{"sign":"ecdsa/rsa","hash":"sha384","id":"3041300d060960864801650304020205000430"},"sha512WithRSAEncryption":{"sign":"rsa","hash":"sha512","id":"3051300d060960864801650304020305000440"},"RSA-SHA512":{"sign":"ecdsa/rsa","hash":"sha512","id":"3051300d060960864801650304020305000440"},"RSA-SHA1":{"sign":"rsa","hash":"sha1","id":"3021300906052b0e03021a05000414"},"ecdsa-with-SHA1":{"sign":"ecdsa","hash":"sha1","id":""},"sha256":{"sign":"ecdsa","hash":"sha256","id":""},"sha224":{"sign":"ecdsa","hash":"sha224","id":""},"sha384":{"sign":"ecdsa","hash":"sha384","id":""},"sha512":{"sign":"ecdsa","hash":"sha512","id":""},"DSA-SHA":{"sign":"dsa","hash":"sha1","id":""},"DSA-SHA1":{"sign":"dsa","hash":"sha1","id":""},"DSA":{"sign":"dsa","hash":"sha1","id":""},"DSA-WITH-SHA224":{"sign":"dsa","hash":"sha224","id":""},"DSA-SHA224":{"sign":"dsa","hash":"sha224","id":""},"DSA-WITH-SHA256":{"sign":"dsa","hash":"sha256","id":""},"DSA-SHA256":{"sign":"dsa","hash":"sha256","id":""},"DSA-WITH-SHA384":{"sign":"dsa","hash":"sha384","id":""},"DSA-SHA384":{"sign":"dsa","hash":"sha384","id":""},"DSA-WITH-SHA512":{"sign":"dsa","hash":"sha512","id":""},"DSA-SHA512":{"sign":"dsa","hash":"sha512","id":""},"DSA-RIPEMD160":{"sign":"dsa","hash":"rmd160","id":""},"ripemd160WithRSA":{"sign":"rsa","hash":"rmd160","id":"3021300906052b2403020105000414"},"RSA-RIPEMD160":{"sign":"rsa","hash":"rmd160","id":"3021300906052b2403020105000414"},"md5WithRSAEncryption":{"sign":"rsa","hash":"md5","id":"3020300c06082a864886f70d020505000410"},"RSA-MD5":{"sign":"rsa","hash":"md5","id":"3020300c06082a864886f70d020505000410"}}')},function(e,t,r){t.pbkdf2=r(602),t.pbkdf2Sync=r(258)},function(e,t,r){(function(t){var r=Math.pow(2,30)-1;function n(e,r){if("string"!=typeof e&&!t.isBuffer(e))throw new TypeError(r+" must be a buffer or string")}e.exports=function(e,t,i,a){if(n(e,"Password"),n(t,"Salt"),"number"!=typeof i)throw new TypeError("Iterations not a number");if(i<0)throw new TypeError("Bad iterations");if("number"!=typeof a)throw new TypeError("Key length not a number");if(a<0||a>r||a!=a)throw new TypeError("Bad key length")}}).call(this,r(7).Buffer)},function(e,t,r){(function(t){var r;t.browser?r="utf-8":r=parseInt(t.version.split(".")[0].slice(1),10)>=6?"utf-8":"binary";e.exports=r}).call(this,r(13))},function(e,t,r){var n=r(253),i=r(102),a=r(103),o=r(256),s=r(257),c=r(2).Buffer,u=c.alloc(128),l={md5:16,sha1:20,sha224:28,sha256:32,sha384:48,sha512:64,rmd160:20,ripemd160:20};function f(e,t,r){var o=function(e){return"rmd160"===e||"ripemd160"===e?function(e){return(new i).update(e).digest()}:"md5"===e?n:function(t){return a(e).update(t).digest()}}(e),s="sha512"===e||"sha384"===e?128:64;t.length>s?t=o(t):t.length<s&&(t=c.concat([t,u],s));for(var f=c.allocUnsafe(s+l[e]),d=c.allocUnsafe(s+l[e]),h=0;h<s;h++)f[h]=54^t[h],d[h]=92^t[h];var p=c.allocUnsafe(s+r+4);f.copy(p,0,0,s),this.ipad1=p,this.ipad2=f,this.opad=d,this.alg=e,this.blocksize=s,this.hash=o,this.size=l[e]}f.prototype.run=function(e,t){return e.copy(t,this.blocksize),this.hash(t).copy(this.opad,this.blocksize),this.hash(this.opad)},e.exports=function(e,t,r,n,i){o(e,t,r,n),c.isBuffer(e)||(e=c.from(e,s)),c.isBuffer(t)||(t=c.from(t,s));var a=new f(i=i||"sha1",e,t.length),u=c.allocUnsafe(n),d=c.allocUnsafe(t.length+4);t.copy(d,0,0,t.length);for(var h=0,p=l[i],y=Math.ceil(n/p),m=1;m<=y;m++){d.writeUInt32BE(m,t.length);for(var g=a.run(d,a.ipad1),b=g,v=1;v<r;v++){b=a.run(b,a.ipad2);for(var _=0;_<p;_++)g[_]^=b[_]}g.copy(u,h),h+=p}return u}},function(e,t,r){var n=r(59),i=r(2).Buffer,a=r(260);function o(e){var t=e._cipher.encryptBlockRaw(e._prev);return a(e._prev),t}t.encrypt=function(e,t){var r=Math.ceil(t.length/16),a=e._cache.length;e._cache=i.concat([e._cache,i.allocUnsafe(16*r)]);for(var s=0;s<r;s++){var c=o(e),u=a+16*s;e._cache.writeUInt32BE(c[0],u+0),e._cache.writeUInt32BE(c[1],u+4),e._cache.writeUInt32BE(c[2],u+8),e._cache.writeUInt32BE(c[3],u+12)}var l=e._cache.slice(0,t.length);return e._cache=e._cache.slice(t.length),n(t,l)}},function(e,t){e.exports=function(e){for(var t,r=e.length;r--;){if(255!==(t=e.readUInt8(r))){t++,e.writeUInt8(t,r);break}e.writeUInt8(0,r)}}},function(e){e.exports=JSON.parse('{"aes-128-ecb":{"cipher":"AES","key":128,"iv":0,"mode":"ECB","type":"block"},"aes-192-ecb":{"cipher":"AES","key":192,"iv":0,"mode":"ECB","type":"block"},"aes-256-ecb":{"cipher":"AES","key":256,"iv":0,"mode":"ECB","type":"block"},"aes-128-cbc":{"cipher":"AES","key":128,"iv":16,"mode":"CBC","type":"block"},"aes-192-cbc":{"cipher":"AES","key":192,"iv":16,"mode":"CBC","type":"block"},"aes-256-cbc":{"cipher":"AES","key":256,"iv":16,"mode":"CBC","type":"block"},"aes128":{"cipher":"AES","key":128,"iv":16,"mode":"CBC","type":"block"},"aes192":{"cipher":"AES","key":192,"iv":16,"mode":"CBC","type":"block"},"aes256":{"cipher":"AES","key":256,"iv":16,"mode":"CBC","type":"block"},"aes-128-cfb":{"cipher":"AES","key":128,"iv":16,"mode":"CFB","type":"stream"},"aes-192-cfb":{"cipher":"AES","key":192,"iv":16,"mode":"CFB","type":"stream"},"aes-256-cfb":{"cipher":"AES","key":256,"iv":16,"mode":"CFB","type":"stream"},"aes-128-cfb8":{"cipher":"AES","key":128,"iv":16,"mode":"CFB8","type":"stream"},"aes-192-cfb8":{"cipher":"AES","key":192,"iv":16,"mode":"CFB8","type":"stream"},"aes-256-cfb8":{"cipher":"AES","key":256,"iv":16,"mode":"CFB8","type":"stream"},"aes-128-cfb1":{"cipher":"AES","key":128,"iv":16,"mode":"CFB1","type":"stream"},"aes-192-cfb1":{"cipher":"AES","key":192,"iv":16,"mode":"CFB1","type":"stream"},"aes-256-cfb1":{"cipher":"AES","key":256,"iv":16,"mode":"CFB1","type":"stream"},"aes-128-ofb":{"cipher":"AES","key":128,"iv":16,"mode":"OFB","type":"stream"},"aes-192-ofb":{"cipher":"AES","key":192,"iv":16,"mode":"OFB","type":"stream"},"aes-256-ofb":{"cipher":"AES","key":256,"iv":16,"mode":"OFB","type":"stream"},"aes-128-ctr":{"cipher":"AES","key":128,"iv":16,"mode":"CTR","type":"stream"},"aes-192-ctr":{"cipher":"AES","key":192,"iv":16,"mode":"CTR","type":"stream"},"aes-256-ctr":{"cipher":"AES","key":256,"iv":16,"mode":"CTR","type":"stream"},"aes-128-gcm":{"cipher":"AES","key":128,"iv":12,"mode":"GCM","type":"auth"},"aes-192-gcm":{"cipher":"AES","key":192,"iv":12,"mode":"GCM","type":"auth"},"aes-256-gcm":{"cipher":"AES","key":256,"iv":12,"mode":"GCM","type":"auth"}}')},function(e,t,r){var n=r(78),i=r(2).Buffer,a=r(29),o=r(1),s=r(617),c=r(59),u=r(260);function l(e,t,r,o){a.call(this);var c=i.alloc(4,0);this._cipher=new n.AES(t);var l=this._cipher.encryptBlock(c);this._ghash=new s(l),r=function(e,t,r){if(12===t.length)return e._finID=i.concat([t,i.from([0,0,0,1])]),i.concat([t,i.from([0,0,0,2])]);var n=new s(r),a=t.length,o=a%16;n.update(t),o&&(o=16-o,n.update(i.alloc(o,0))),n.update(i.alloc(8,0));var c=8*a,l=i.alloc(8);l.writeUIntBE(c,0,8),n.update(l),e._finID=n.state;var f=i.from(e._finID);return u(f),f}(this,r,l),this._prev=i.from(r),this._cache=i.allocUnsafe(0),this._secCache=i.allocUnsafe(0),this._decrypt=o,this._alen=0,this._len=0,this._mode=e,this._authTag=null,this._called=!1}o(l,a),l.prototype._update=function(e){if(!this._called&&this._alen){var t=16-this._alen%16;t<16&&(t=i.alloc(t,0),this._ghash.update(t))}this._called=!0;var r=this._mode.encrypt(this,e);return this._decrypt?this._ghash.update(e):this._ghash.update(r),this._len+=e.length,r},l.prototype._final=function(){if(this._decrypt&&!this._authTag)throw new Error("Unsupported state or unable to authenticate data");var e=c(this._ghash.final(8*this._alen,8*this._len),this._cipher.encryptBlock(this._finID));if(this._decrypt&&function(e,t){var r=0;e.length!==t.length&&r++;for(var n=Math.min(e.length,t.length),i=0;i<n;++i)r+=e[i]^t[i];return r}(e,this._authTag))throw new Error("Unsupported state or unable to authenticate data");this._authTag=e,this._cipher.scrub()},l.prototype.getAuthTag=function(){if(this._decrypt||!i.isBuffer(this._authTag))throw new Error("Attempting to get auth tag in unsupported state");return this._authTag},l.prototype.setAuthTag=function(e){if(!this._decrypt)throw new Error("Attempting to set auth tag in unsupported state");this._authTag=e},l.prototype.setAAD=function(e){if(this._called)throw new Error("Attempting to set AAD in unsupported state");this._ghash.update(e),this._alen+=e.length},e.exports=l},function(e,t,r){var n=r(78),i=r(2).Buffer,a=r(29);function o(e,t,r,o){a.call(this),this._cipher=new n.AES(t),this._prev=i.from(r),this._cache=i.allocUnsafe(0),this._secCache=i.allocUnsafe(0),this._decrypt=o,this._mode=e}r(1)(o,a),o.prototype._update=function(e){return this._mode.encrypt(this,e,this._decrypt)},o.prototype._final=function(){this._cipher.scrub()},e.exports=o},function(e,t,r){var n=r(43);e.exports=b,b.simpleSieve=m,b.fermatTest=g;var i=r(11),a=new i(24),o=new(r(265)),s=new i(1),c=new i(2),u=new i(5),l=(new i(16),new i(8),new i(10)),f=new i(3),d=(new i(7),new i(11)),h=new i(4),p=(new i(12),null);function y(){if(null!==p)return p;var e=[];e[0]=2;for(var t=1,r=3;r<1048576;r+=2){for(var n=Math.ceil(Math.sqrt(r)),i=0;i<t&&e[i]<=n&&r%e[i]!=0;i++);t!==i&&e[i]<=n||(e[t++]=r)}return p=e,e}function m(e){for(var t=y(),r=0;r<t.length;r++)if(0===e.modn(t[r]))return 0===e.cmpn(t[r]);return!0}function g(e){var t=i.mont(e);return 0===c.toRed(t).redPow(e.subn(1)).fromRed().cmpn(1)}function b(e,t){if(e<16)return new i(2===t||5===t?[140,123]:[140,39]);var r,p;for(t=new i(t);;){for(r=new i(n(Math.ceil(e/8)));r.bitLength()>e;)r.ishrn(1);if(r.isEven()&&r.iadd(s),r.testn(1)||r.iadd(c),t.cmp(c)){if(!t.cmp(u))for(;r.mod(l).cmp(f);)r.iadd(h)}else for(;r.mod(a).cmp(d);)r.iadd(h);if(m(p=r.shrn(1))&&m(r)&&g(p)&&g(r)&&o.test(p)&&o.test(r))return r}}},function(e,t,r){var n=r(11),i=r(107);function a(e){this.rand=e||new i.Rand}e.exports=a,a.create=function(e){return new a(e)},a.prototype._randbelow=function(e){var t=e.bitLength(),r=Math.ceil(t/8);do{var i=new n(this.rand.generate(r))}while(i.cmp(e)>=0);return i},a.prototype._randrange=function(e,t){var r=t.sub(e);return e.add(this._randbelow(r))},a.prototype.test=function(e,t,r){var i=e.bitLength(),a=n.mont(e),o=new n(1).toRed(a);t||(t=Math.max(1,i/48|0));for(var s=e.subn(1),c=0;!s.testn(c);c++);for(var u=e.shrn(c),l=s.toRed(a);t>0;t--){var f=this._randrange(new n(2),s);r&&r(f);var d=f.toRed(a).redPow(u);if(0!==d.cmp(o)&&0!==d.cmp(l)){for(var h=1;h<c;h++){if(0===(d=d.redSqr()).cmp(o))return!1;if(0===d.cmp(l))break}if(h===c)return!1}}return!0},a.prototype.getDivisor=function(e,t){var r=e.bitLength(),i=n.mont(e),a=new n(1).toRed(i);t||(t=Math.max(1,r/48|0));for(var o=e.subn(1),s=0;!o.testn(s);s++);for(var c=e.shrn(s),u=o.toRed(i);t>0;t--){var l=this._randrange(new n(2),o),f=e.gcd(l);if(0!==f.cmpn(1))return f;var d=l.toRed(i).redPow(c);if(0!==d.cmp(a)&&0!==d.cmp(u)){for(var h=1;h<s;h++){if(0===(d=d.redSqr()).cmp(a))return d.fromRed().subn(1).gcd(e);if(0===d.cmp(u))break}if(h===s)return(d=d.redSqr()).fromRed().subn(1).gcd(e)}}return!1}},function(e,t,r){"use strict";var n=t;function i(e){return 1===e.length?"0"+e:e}function a(e){for(var t="",r=0;r<e.length;r++)t+=i(e[r].toString(16));return t}n.toArray=function(e,t){if(Array.isArray(e))return e.slice();if(!e)return[];var r=[];if("string"!=typeof e){for(var n=0;n<e.length;n++)r[n]=0|e[n];return r}if("hex"===t){(e=e.replace(/[^a-z0-9]+/gi,"")).length%2!=0&&(e="0"+e);for(n=0;n<e.length;n+=2)r.push(parseInt(e[n]+e[n+1],16))}else for(n=0;n<e.length;n++){var i=e.charCodeAt(n),a=i>>8,o=255&i;a?r.push(a,o):r.push(o)}return r},n.zero2=i,n.toHex=a,n.encode=function(e,t){return"hex"===t?a(e):e}},function(e,t,r){"use strict";var n=t;n.base=r(80),n.short=r(628),n.mont=r(629),n.edwards=r(630)},function(e,t,r){"use strict";var n=r(21).rotr32;function i(e,t,r){return e&t^~e&r}function a(e,t,r){return e&t^e&r^t&r}function o(e,t,r){return e^t^r}t.ft_1=function(e,t,r,n){return 0===e?i(t,r,n):1===e||3===e?o(t,r,n):2===e?a(t,r,n):void 0},t.ch32=i,t.maj32=a,t.p32=o,t.s0_256=function(e){return n(e,2)^n(e,13)^n(e,22)},t.s1_256=function(e){return n(e,6)^n(e,11)^n(e,25)},t.g0_256=function(e){return n(e,7)^n(e,18)^e>>>3},t.g1_256=function(e){return n(e,17)^n(e,19)^e>>>10}},function(e,t,r){"use strict";var n=r(21),i=r(60),a=r(268),o=r(16),s=n.sum32,c=n.sum32_4,u=n.sum32_5,l=a.ch32,f=a.maj32,d=a.s0_256,h=a.s1_256,p=a.g0_256,y=a.g1_256,m=i.BlockHash,g=[1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298];function b(){if(!(this instanceof b))return new b;m.call(this),this.h=[1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225],this.k=g,this.W=new Array(64)}n.inherits(b,m),e.exports=b,b.blockSize=512,b.outSize=256,b.hmacStrength=192,b.padLength=64,b.prototype._update=function(e,t){for(var r=this.W,n=0;n<16;n++)r[n]=e[t+n];for(;n<r.length;n++)r[n]=c(y(r[n-2]),r[n-7],p(r[n-15]),r[n-16]);var i=this.h[0],a=this.h[1],m=this.h[2],g=this.h[3],b=this.h[4],v=this.h[5],_=this.h[6],w=this.h[7];for(o(this.k.length===r.length),n=0;n<r.length;n++){var S=u(w,h(b),l(b,v,_),this.k[n],r[n]),E=s(d(i),f(i,a,m));w=_,_=v,v=b,b=s(g,S),g=m,m=a,a=i,i=s(S,E)}this.h[0]=s(this.h[0],i),this.h[1]=s(this.h[1],a),this.h[2]=s(this.h[2],m),this.h[3]=s(this.h[3],g),this.h[4]=s(this.h[4],b),this.h[5]=s(this.h[5],v),this.h[6]=s(this.h[6],_),this.h[7]=s(this.h[7],w)},b.prototype._digest=function(e){return"hex"===e?n.toHex32(this.h,"big"):n.split32(this.h,"big")}},function(e,t,r){"use strict";var n=r(21),i=r(60),a=r(16),o=n.rotr64_hi,s=n.rotr64_lo,c=n.shr64_hi,u=n.shr64_lo,l=n.sum64,f=n.sum64_hi,d=n.sum64_lo,h=n.sum64_4_hi,p=n.sum64_4_lo,y=n.sum64_5_hi,m=n.sum64_5_lo,g=i.BlockHash,b=[1116352408,3609767458,1899447441,602891725,3049323471,3964484399,3921009573,2173295548,961987163,4081628472,1508970993,3053834265,2453635748,2937671579,2870763221,3664609560,3624381080,2734883394,310598401,1164996542,607225278,1323610764,1426881987,3590304994,1925078388,4068182383,2162078206,991336113,2614888103,633803317,3248222580,3479774868,3835390401,2666613458,4022224774,944711139,264347078,2341262773,604807628,2007800933,770255983,1495990901,1249150122,1856431235,1555081692,3175218132,1996064986,2198950837,2554220882,3999719339,2821834349,766784016,2952996808,2566594879,3210313671,3203337956,3336571891,1034457026,3584528711,2466948901,113926993,3758326383,338241895,168717936,666307205,1188179964,773529912,1546045734,1294757372,1522805485,1396182291,2643833823,1695183700,2343527390,1986661051,1014477480,2177026350,1206759142,2456956037,344077627,2730485921,1290863460,2820302411,3158454273,3259730800,3505952657,3345764771,106217008,3516065817,3606008344,3600352804,1432725776,4094571909,1467031594,275423344,851169720,430227734,3100823752,506948616,1363258195,659060556,3750685593,883997877,3785050280,958139571,3318307427,1322822218,3812723403,1537002063,2003034995,1747873779,3602036899,1955562222,1575990012,2024104815,1125592928,2227730452,2716904306,2361852424,442776044,2428436474,593698344,2756734187,3733110249,3204031479,2999351573,3329325298,3815920427,3391569614,3928383900,3515267271,566280711,3940187606,3454069534,4118630271,4000239992,116418474,1914138554,174292421,2731055270,289380356,3203993006,460393269,320620315,685471733,587496836,852142971,1086792851,1017036298,365543100,1126000580,2618297676,1288033470,3409855158,1501505948,4234509866,1607167915,987167468,1816402316,1246189591];function v(){if(!(this instanceof v))return new v;g.call(this),this.h=[1779033703,4089235720,3144134277,2227873595,1013904242,4271175723,2773480762,1595750129,1359893119,2917565137,2600822924,725511199,528734635,4215389547,1541459225,327033209],this.k=b,this.W=new Array(160)}function _(e,t,r,n,i){var a=e&r^~e&i;return a<0&&(a+=4294967296),a}function w(e,t,r,n,i,a){var o=t&n^~t&a;return o<0&&(o+=4294967296),o}function S(e,t,r,n,i){var a=e&r^e&i^r&i;return a<0&&(a+=4294967296),a}function E(e,t,r,n,i,a){var o=t&n^t&a^n&a;return o<0&&(o+=4294967296),o}function x(e,t){var r=o(e,t,28)^o(t,e,2)^o(t,e,7);return r<0&&(r+=4294967296),r}function T(e,t){var r=s(e,t,28)^s(t,e,2)^s(t,e,7);return r<0&&(r+=4294967296),r}function O(e,t){var r=o(e,t,14)^o(e,t,18)^o(t,e,9);return r<0&&(r+=4294967296),r}function A(e,t){var r=s(e,t,14)^s(e,t,18)^s(t,e,9);return r<0&&(r+=4294967296),r}function I(e,t){var r=o(e,t,1)^o(e,t,8)^c(e,t,7);return r<0&&(r+=4294967296),r}function N(e,t){var r=s(e,t,1)^s(e,t,8)^u(e,t,7);return r<0&&(r+=4294967296),r}function R(e,t){var r=o(e,t,19)^o(t,e,29)^c(e,t,6);return r<0&&(r+=4294967296),r}function k(e,t){var r=s(e,t,19)^s(t,e,29)^u(e,t,6);return r<0&&(r+=4294967296),r}n.inherits(v,g),e.exports=v,v.blockSize=1024,v.outSize=512,v.hmacStrength=192,v.padLength=128,v.prototype._prepareBlock=function(e,t){for(var r=this.W,n=0;n<32;n++)r[n]=e[t+n];for(;n<r.length;n+=2){var i=R(r[n-4],r[n-3]),a=k(r[n-4],r[n-3]),o=r[n-14],s=r[n-13],c=I(r[n-30],r[n-29]),u=N(r[n-30],r[n-29]),l=r[n-32],f=r[n-31];r[n]=h(i,a,o,s,c,u,l,f),r[n+1]=p(i,a,o,s,c,u,l,f)}},v.prototype._update=function(e,t){this._prepareBlock(e,t);var r=this.W,n=this.h[0],i=this.h[1],o=this.h[2],s=this.h[3],c=this.h[4],u=this.h[5],h=this.h[6],p=this.h[7],g=this.h[8],b=this.h[9],v=this.h[10],I=this.h[11],N=this.h[12],R=this.h[13],k=this.h[14],P=this.h[15];a(this.k.length===r.length);for(var j=0;j<r.length;j+=2){var D=k,C=P,M=O(g,b),L=A(g,b),q=_(g,b,v,I,N),F=w(g,b,v,I,N,R),B=this.k[j],U=this.k[j+1],V=r[j],H=r[j+1],z=y(D,C,M,L,q,F,B,U,V,H),G=m(D,C,M,L,q,F,B,U,V,H);D=x(n,i),C=T(n,i),M=S(n,i,o,s,c),L=E(n,i,o,s,c,u);var Q=f(D,C,M,L),X=d(D,C,M,L);k=N,P=R,N=v,R=I,v=g,I=b,g=f(h,p,z,G),b=d(p,p,z,G),h=c,p=u,c=o,u=s,o=n,s=i,n=f(z,G,Q,X),i=d(z,G,Q,X)}l(this.h,0,n,i),l(this.h,2,o,s),l(this.h,4,c,u),l(this.h,6,h,p),l(this.h,8,g,b),l(this.h,10,v,I),l(this.h,12,N,R),l(this.h,14,k,P)},v.prototype._digest=function(e){return"hex"===e?n.toHex32(this.h,"big"):n.split32(this.h,"big")}},function(e,t,r){var n=r(1),i=r(62).Reporter,a=r(7).Buffer;function o(e,t){i.call(this,t),a.isBuffer(e)?(this.base=e,this.offset=0,this.length=e.length):this.error("Input not Buffer")}function s(e,t){if(Array.isArray(e))this.length=0,this.value=e.map(function(e){return e instanceof s||(e=new s(e,t)),this.length+=e.length,e},this);else if("number"==typeof e){if(!(0<=e&&e<=255))return t.error("non-byte EncoderBuffer value");this.value=e,this.length=1}else if("string"==typeof e)this.value=e,this.length=a.byteLength(e);else{if(!a.isBuffer(e))return t.error("Unsupported type: "+typeof e);this.value=e,this.length=e.length}}n(o,i),t.DecoderBuffer=o,o.prototype.save=function(){return{offset:this.offset,reporter:i.prototype.save.call(this)}},o.prototype.restore=function(e){var t=new o(this.base);return t.offset=e.offset,t.length=this.offset,this.offset=e.offset,i.prototype.restore.call(this,e.reporter),t},o.prototype.isEmpty=function(){return this.offset===this.length},o.prototype.readUInt8=function(e){return this.offset+1<=this.length?this.base.readUInt8(this.offset++,!0):this.error(e||"DecoderBuffer overrun")},o.prototype.skip=function(e,t){if(!(this.offset+e<=this.length))return this.error(t||"DecoderBuffer overrun");var r=new o(this.base);return r._reporterState=this._reporterState,r.offset=this.offset,r.length=this.offset+e,this.offset+=e,r},o.prototype.raw=function(e){return this.base.slice(e?e.offset:this.offset,this.length)},t.EncoderBuffer=s,s.prototype.join=function(e,t){return e||(e=new a(this.length)),t||(t=0),0===this.length?e:(Array.isArray(this.value)?this.value.forEach(function(r){r.join(e,t),t+=r.length}):("number"==typeof this.value?e[t]=this.value:"string"==typeof this.value?e.write(this.value,t):a.isBuffer(this.value)&&this.value.copy(e,t),t+=this.length),e)}},function(e,t,r){var n=t;n._reverse=function(e){var t={};return Object.keys(e).forEach(function(r){(0|r)==r&&(r|=0);var n=e[r];t[n]=r}),t},n.der=r(650)},function(e,t,r){var n=r(1),i=r(61),a=i.base,o=i.bignum,s=i.constants.der;function c(e){this.enc="der",this.name=e.name,this.entity=e,this.tree=new u,this.tree._init(e.body)}function u(e){a.Node.call(this,"der",e)}function l(e,t){var r=e.readUInt8(t);if(e.isError(r))return r;var n=s.tagClass[r>>6],i=0==(32&r);if(31==(31&r)){var a=r;for(r=0;128==(128&a);){if(a=e.readUInt8(t),e.isError(a))return a;r<<=7,r|=127&a}}else r&=31;return{cls:n,primitive:i,tag:r,tagStr:s.tag[r]}}function f(e,t,r){var n=e.readUInt8(r);if(e.isError(n))return n;if(!t&&128===n)return null;if(0==(128&n))return n;var i=127&n;if(i>4)return e.error("length octect is too long");n=0;for(var a=0;a<i;a++){n<<=8;var o=e.readUInt8(r);if(e.isError(o))return o;n|=o}return n}e.exports=c,c.prototype.decode=function(e,t){return e instanceof a.DecoderBuffer||(e=new a.DecoderBuffer(e,t)),this.tree._decode(e,t)},n(u,a.Node),u.prototype._peekTag=function(e,t,r){if(e.isEmpty())return!1;var n=e.save(),i=l(e,'Failed to peek tag: "'+t+'"');return e.isError(i)?i:(e.restore(n),i.tag===t||i.tagStr===t||i.tagStr+"of"===t||r)},u.prototype._decodeTag=function(e,t,r){var n=l(e,'Failed to decode tag of "'+t+'"');if(e.isError(n))return n;var i=f(e,n.primitive,'Failed to get length of "'+t+'"');if(e.isError(i))return i;if(!r&&n.tag!==t&&n.tagStr!==t&&n.tagStr+"of"!==t)return e.error('Failed to match tag: "'+t+'"');if(n.primitive||null!==i)return e.skip(i,'Failed to match body of: "'+t+'"');var a=e.save(),o=this._skipUntilEnd(e,'Failed to skip indefinite length body: "'+this.tag+'"');return e.isError(o)?o:(i=e.offset-a.offset,e.restore(a),e.skip(i,'Failed to match body of: "'+t+'"'))},u.prototype._skipUntilEnd=function(e,t){for(;;){var r=l(e,t);if(e.isError(r))return r;var n,i=f(e,r.primitive,t);if(e.isError(i))return i;if(n=r.primitive||null!==i?e.skip(i):this._skipUntilEnd(e,t),e.isError(n))return n;if("end"===r.tagStr)break}},u.prototype._decodeList=function(e,t,r,n){for(var i=[];!e.isEmpty();){var a=this._peekTag(e,"end");if(e.isError(a))return a;var o=r.decode(e,"der",n);if(e.isError(o)&&a)break;i.push(o)}return i},u.prototype._decodeStr=function(e,t){if("bitstr"===t){var r=e.readUInt8();return e.isError(r)?r:{unused:r,data:e.raw()}}if("bmpstr"===t){var n=e.raw();if(n.length%2==1)return e.error("Decoding of string type: bmpstr length mismatch");for(var i="",a=0;a<n.length/2;a++)i+=String.fromCharCode(n.readUInt16BE(2*a));return i}if("numstr"===t){var o=e.raw().toString("ascii");return this._isNumstr(o)?o:e.error("Decoding of string type: numstr unsupported characters")}if("octstr"===t)return e.raw();if("objDesc"===t)return e.raw();if("printstr"===t){var s=e.raw().toString("ascii");return this._isPrintstr(s)?s:e.error("Decoding of string type: printstr unsupported characters")}return/str$/.test(t)?e.raw().toString():e.error("Decoding of string type: "+t+" unsupported")},u.prototype._decodeObjid=function(e,t,r){for(var n,i=[],a=0;!e.isEmpty();){var o=e.readUInt8();a<<=7,a|=127&o,0==(128&o)&&(i.push(a),a=0)}128&o&&i.push(a);var s=i[0]/40|0,c=i[0]%40;if(n=r?i:[s,c].concat(i.slice(1)),t){var u=t[n.join(" ")];void 0===u&&(u=t[n.join(".")]),void 0!==u&&(n=u)}return n},u.prototype._decodeTime=function(e,t){var r=e.raw().toString();if("gentime"===t)var n=0|r.slice(0,4),i=0|r.slice(4,6),a=0|r.slice(6,8),o=0|r.slice(8,10),s=0|r.slice(10,12),c=0|r.slice(12,14);else{if("utctime"!==t)return e.error("Decoding "+t+" time is not supported yet");n=0|r.slice(0,2),i=0|r.slice(2,4),a=0|r.slice(4,6),o=0|r.slice(6,8),s=0|r.slice(8,10),c=0|r.slice(10,12);n=n<70?2e3+n:1900+n}return Date.UTC(n,i-1,a,o,s,c,0)},u.prototype._decodeNull=function(e){return null},u.prototype._decodeBool=function(e){var t=e.readUInt8();return e.isError(t)?t:0!==t},u.prototype._decodeInt=function(e,t){var r=e.raw(),n=new o(r);return t&&(n=t[n.toString(10)]||n),n},u.prototype._use=function(e,t){return"function"==typeof e&&(e=e(t)),e._getDecoder("der").tree}},function(e,t,r){var n=r(1),i=r(7).Buffer,a=r(61),o=a.base,s=a.constants.der;function c(e){this.enc="der",this.name=e.name,this.entity=e,this.tree=new u,this.tree._init(e.body)}function u(e){o.Node.call(this,"der",e)}function l(e){return e<10?"0"+e:e}e.exports=c,c.prototype.encode=function(e,t){return this.tree._encode(e,t).join()},n(u,o.Node),u.prototype._encodeComposite=function(e,t,r,n){var a,o=function(e,t,r,n){var i;"seqof"===e?e="seq":"setof"===e&&(e="set");if(s.tagByName.hasOwnProperty(e))i=s.tagByName[e];else{if("number"!=typeof e||(0|e)!==e)return n.error("Unknown tag: "+e);i=e}if(i>=31)return n.error("Multi-octet tag encoding unsupported");t||(i|=32);return i|=s.tagClassByName[r||"universal"]<<6}(e,t,r,this.reporter);if(n.length<128)return(a=new i(2))[0]=o,a[1]=n.length,this._createEncoderBuffer([a,n]);for(var c=1,u=n.length;u>=256;u>>=8)c++;(a=new i(2+c))[0]=o,a[1]=128|c;u=1+c;for(var l=n.length;l>0;u--,l>>=8)a[u]=255&l;return this._createEncoderBuffer([a,n])},u.prototype._encodeStr=function(e,t){if("bitstr"===t)return this._createEncoderBuffer([0|e.unused,e.data]);if("bmpstr"===t){for(var r=new i(2*e.length),n=0;n<e.length;n++)r.writeUInt16BE(e.charCodeAt(n),2*n);return this._createEncoderBuffer(r)}return"numstr"===t?this._isNumstr(e)?this._createEncoderBuffer(e):this.reporter.error("Encoding of string type: numstr supports only digits and space"):"printstr"===t?this._isPrintstr(e)?this._createEncoderBuffer(e):this.reporter.error("Encoding of string type: printstr supports only latin upper and lower case letters, digits, space, apostrophe, left and rigth parenthesis, plus sign, comma, hyphen, dot, slash, colon, equal sign, question mark"):/str$/.test(t)?this._createEncoderBuffer(e):"objDesc"===t?this._createEncoderBuffer(e):this.reporter.error("Encoding of string type: "+t+" unsupported")},u.prototype._encodeObjid=function(e,t,r){if("string"==typeof e){if(!t)return this.reporter.error("string objid given, but no values map found");if(!t.hasOwnProperty(e))return this.reporter.error("objid not found in values map");e=t[e].split(/[\s\.]+/g);for(var n=0;n<e.length;n++)e[n]|=0}else if(Array.isArray(e)){e=e.slice();for(n=0;n<e.length;n++)e[n]|=0}if(!Array.isArray(e))return this.reporter.error("objid() should be either array or string, got: "+JSON.stringify(e));if(!r){if(e[1]>=40)return this.reporter.error("Second objid identifier OOB");e.splice(0,2,40*e[0]+e[1])}var a=0;for(n=0;n<e.length;n++){var o=e[n];for(a++;o>=128;o>>=7)a++}var s=new i(a),c=s.length-1;for(n=e.length-1;n>=0;n--){o=e[n];for(s[c--]=127&o;(o>>=7)>0;)s[c--]=128|127&o}return this._createEncoderBuffer(s)},u.prototype._encodeTime=function(e,t){var r,n=new Date(e);return"gentime"===t?r=[l(n.getFullYear()),l(n.getUTCMonth()+1),l(n.getUTCDate()),l(n.getUTCHours()),l(n.getUTCMinutes()),l(n.getUTCSeconds()),"Z"].join(""):"utctime"===t?r=[l(n.getFullYear()%100),l(n.getUTCMonth()+1),l(n.getUTCDate()),l(n.getUTCHours()),l(n.getUTCMinutes()),l(n.getUTCSeconds()),"Z"].join(""):this.reporter.error("Encoding "+t+" time is not supported yet"),this._encodeStr(r,"octstr")},u.prototype._encodeNull=function(){return this._createEncoderBuffer("")},u.prototype._encodeInt=function(e,t){if("string"==typeof e){if(!t)return this.reporter.error("String int or enum given, but no values map");if(!t.hasOwnProperty(e))return this.reporter.error("Values map doesn't contain: "+JSON.stringify(e));e=t[e]}if("number"!=typeof e&&!i.isBuffer(e)){var r=e.toArray();!e.sign&&128&r[0]&&r.unshift(0),e=new i(r)}if(i.isBuffer(e)){var n=e.length;0===e.length&&n++;var a=new i(n);return e.copy(a),0===e.length&&(a[0]=0),this._createEncoderBuffer(a)}if(e<128)return this._createEncoderBuffer(e);if(e<256)return this._createEncoderBuffer([0,e]);n=1;for(var o=e;o>=256;o>>=8)n++;for(o=(a=new Array(n)).length-1;o>=0;o--)a[o]=255&e,e>>=8;return 128&a[0]&&a.unshift(0),this._createEncoderBuffer(new i(a))},u.prototype._encodeBool=function(e){return this._createEncoderBuffer(e?255:0)},u.prototype._use=function(e,t){return"function"==typeof e&&(e=e(t)),e._getEncoder("der").tree},u.prototype._skipDefault=function(e,t,r){var n,i=this._baseState;if(null===i.default)return!1;var a=e.join();if(void 0===i.defaultBuffer&&(i.defaultBuffer=this._encodeValue(i.default,t,r).join()),a.length!==i.defaultBuffer.length)return!1;for(n=0;n<a.length;n++)if(a[n]!==i.defaultBuffer[n])return!1;return!0}},function(e){e.exports=JSON.parse('{"1.3.132.0.10":"secp256k1","1.3.132.0.33":"p224","1.2.840.10045.3.1.1":"p192","1.2.840.10045.3.1.7":"p256","1.3.132.0.34":"p384","1.3.132.0.35":"p521"}')},function(e,t,r){var n=r(44),i=r(2).Buffer;function a(e){var t=i.allocUnsafe(4);return t.writeUInt32BE(e,0),t}e.exports=function(e,t){for(var r,o=i.alloc(0),s=0;o.length<t;)r=a(s++),o=i.concat([o,n("sha1").update(e).update(r).digest()]);return o.slice(0,t)}},function(e,t){e.exports=function(e,t){for(var r=e.length,n=-1;++n<r;)e[n]^=t[n];return e}},function(e,t,r){var n=r(11),i=r(2).Buffer;e.exports=function(e,t){return i.from(e.toRed(n.mont(t.modulus)).redPow(new n(t.publicExponent)).fromRed().toArray())}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(668))},function(e,t,r){var n=r(680),i=r(114),a=i;a.v1=n,a.v4=i,e.exports=a},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(47),i=r(22),a=r(82),o={term:(e,t)=>e,variable(e,t){const r=t.get(e.name);if(!r)throw new i.UnboundVariableError(e.name,t);return a.transformRDFTermUnsafe(r)}};t.AsyncRecursiveEvaluator=class{constructor(e){this.context=e,this.subEvaluators={[n.ExpressionType.Term]:o.term,[n.ExpressionType.Variable]:o.variable,[n.ExpressionType.Operator]:this.evalOperator,[n.ExpressionType.SpecialOperator]:this.evalSpecialOperator,[n.ExpressionType.Named]:this.evalNamed,[n.ExpressionType.Existence]:this.evalExistence,[n.ExpressionType.Aggregate]:this.evalAggregate}}async evaluate(e,t){const r=this.subEvaluators[e.expressionType];if(!r)throw new i.InvalidExpressionType(e);return r.bind(this)(e,t)}async evalOperator(e,t){const r=e.args.map(e=>this.evaluate(e,t)),n=await Promise.all(r);return e.apply(n)}async evalSpecialOperator(e,t){const r=this.evaluate.bind(this),n={args:e.args,mapping:t,evaluate:r,context:{now:this.context.now,baseIRI:this.context.baseIRI,bnode:this.context.bnode}};return e.applyAsync(n)}async evalNamed(e,t){const r=e.args.map(e=>this.evaluate(e,t)),n=await Promise.all(r);return e.apply(n)}async evalExistence(e,t){if(!this.context.exists)throw new i.NoExistenceHook;return new n.BooleanLiteral(await this.context.exists(e.expression,t))}async evalAggregate(e,t){if(!this.context.aggregate)throw new i.NoExistenceHook;return a.transformRDFTermUnsafe(await this.context.aggregate(e.expression))}};t.SyncRecursiveEvaluator=class{constructor(e){this.context=e,this.subEvaluators={[n.ExpressionType.Term]:o.term,[n.ExpressionType.Variable]:o.variable,[n.ExpressionType.Operator]:this.evalOperator,[n.ExpressionType.SpecialOperator]:this.evalSpecialOperator,[n.ExpressionType.Named]:this.evalNamed,[n.ExpressionType.Existence]:this.evalExistence,[n.ExpressionType.Aggregate]:this.evalAggregate}}evaluate(e,t){const r=this.subEvaluators[e.expressionType];if(!r)throw new i.InvalidExpressionType(e);return r.bind(this)(e,t)}evalOperator(e,t){const r=e.args.map(e=>this.evaluate(e,t));return e.apply(r)}evalSpecialOperator(e,t){const r=this.evaluate.bind(this),n={args:e.args,mapping:t,evaluate:r,context:{now:this.context.now,baseIRI:this.context.baseIRI,bnode:this.context.bnode}};return e.applySync(n)}evalNamed(e,t){const r=e.args.map(e=>this.evaluate(e,t));return e.apply(r)}evalExistence(e,t){if(!this.context.exists)throw new i.NoExistenceHook;return new n.BooleanLiteral(this.context.exists(e.expression,t))}evalAggregate(e,t){if(!this.context.aggregate)throw new i.NoAggregator;return a.transformRDFTermUnsafe(this.context.aggregate(e.expression))}};t.UnsupportedOperation=class extends Error{constructor(e){super(`Operation '${e}' is unsupported in SimpleEvaluator`)}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(82),i=r(281);function a(e){return e}t.SyncEvaluator=class{constructor(e,t={}){this.algExpr=e,this.config=t,this.expr=n.transformAlgebra(e);const r={now:t.now||new Date(Date.now()),baseIRI:t.baseIRI||void 0,exists:t.exists,aggregate:t.aggregate};this.evaluator=new i.SyncRecursiveEvaluator(r)}evaluate(e){return a(this.evaluator.evaluate(this.expr,e)).toRDF()}evaluateAsEBV(e){return a(this.evaluator.evaluate(this.expr,e)).coerceEBV()}evaluateAsInternal(e){return a(this.evaluator.evaluate(this.expr,e))}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(685))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(686))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(687))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(689))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(691))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(692))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(693))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(695))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(696))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(697))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(4),i=r(5),a=r(6),o=r(8),s=r(10);class c extends n.ActorQueryOperationTypedMediated{constructor(e,t){super(e,"path"),this.predicateType=t}async testOperation(e,t){if(e.predicate.type!==this.predicateType)throw new Error("This Actor only supports "+this.predicateType+" Path operations.");return!0}generateBlankNode(e,t){return t?!e||e.subject.value!==t&&e.object.value!==t?i.blankNode(t):this.generateBlankNode(e,t+"b"):this.generateBlankNode(e,"b")}async ALPeval(e,t,r){const n=new a.BufferedIterator;return await this.ALP(e,t,r,{},n,{count:0}),n}async ALP(e,t,r,i,a,s){const u=o.termToString(e);if(i[u])return;a._push(e),i[u]=e;const l=this.generateBlankNode(),f=o.termToString(l),d=c.FACTORY.createPath(e,t,l),h=n.ActorQueryOperation.getSafeBindings(await this.mediatorQueryOperation.mediate({operation:d,context:r}));s.count++,h.bindingsStream.on("data",async e=>{const n=e.get(f);await this.ALP(n,t,r,i,a,s)}),h.bindingsStream.on("end",()=>{0==--s.count&&a.close()})}}c.FACTORY=new s.Factory,t.ActorAbstractPath=c},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(698))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(699))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(700))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(701))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(702))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(703))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(704))},function(e,t,r){"use strict";var n;Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var i=((n=r(315))&&n.__esModule?n:{default:n}).default;t.default=i},function(e,t,r){var n=r(303),i=r(117),a=r(304),o=r(118),s=r(305),c=r(306);function u(){}u.namedNode=function(e){return new o(e)},u.blankNode=function(e){return new n(e)},u.literal=function(e,t){return"string"==typeof t?-1===t.indexOf(":")?new a(e,t):new a(e,null,u.namedNode(t)):new a(e,null,t)},u.defaultGraph=function(){return u.defaultGraphInstance},u.variable=function(e){return new c(e)},u.triple=function(e,t,r){return u.quad(e,t,r)},u.quad=function(e,t,r,n){return new s(e,t,r,n||u.defaultGraphInstance)},u.defaultGraphInstance=new i,e.exports=u},function(e,t){function r(e){this.value=e||"b"+ ++r.nextId}r.prototype.equals=function(e){return!!e&&e.termType===this.termType&&e.value===this.value},r.prototype.termType="BlankNode",r.nextId=0,e.exports=r},function(e,t,r){var n=r(118);function i(e,t,r){this.value=e,this.datatype=i.stringDatatype,this.language="",t?(this.language=t,this.datatype=i.langStringDatatype):r&&(this.datatype=r)}i.prototype.equals=function(e){return!!e&&e.termType===this.termType&&e.value===this.value&&e.language===this.language&&e.datatype.equals(this.datatype)},i.prototype.termType="Literal",i.langStringDatatype=new n("http://www.w3.org/1999/02/22-rdf-syntax-ns#langString"),i.stringDatatype=new n("http://www.w3.org/2001/XMLSchema#string"),e.exports=i},function(e,t,r){var n=r(117);function i(e,t,r,i){this.subject=e,this.predicate=t,this.object=r,this.graph=i||new n}i.prototype.equals=function(e){return!!e&&e.subject.equals(this.subject)&&e.predicate.equals(this.predicate)&&e.object.equals(this.object)&&e.graph.equals(this.graph)},e.exports=i},function(e,t){function r(e){this.value=e}r.prototype.equals=function(e){return!!e&&e.termType===this.termType&&e.value===this.value},r.prototype.termType="Variable",e.exports=r},function(e,t,r){var n=r(121);function i(e){var t,r;function i(t,r){try{var o=e[t](r),s=o.value,c=s instanceof n;Promise.resolve(c?s.wrapped:s).then(function(e){c?i("next",e):a(o.done?"return":"normal",e)},function(e){i("throw",e)})}catch(e){a("throw",e)}}function a(e,n){switch(e){case"return":t.resolve({value:n,done:!0});break;case"throw":t.reject(n);break;default:t.resolve({value:n,done:!1})}(t=t.next)?i(t.key,t.arg):r=null}this._invoke=function(e,n){return new Promise(function(a,o){var s={key:e,arg:n,resolve:a,reject:o,next:null};r?r=r.next=s:(t=r=s,i(e,n))})},"function"!=typeof e.return&&(this.return=void 0)}"function"==typeof Symbol&&Symbol.asyncIterator&&(i.prototype[Symbol.asyncIterator]=function(){return this}),i.prototype.next=function(e){return this._invoke("next",e)},i.prototype.throw=function(e){return this._invoke("throw",e)},i.prototype.return=function(e){return this._invoke("return",e)},e.exports=i},function(e,t,r){"use strict";var n=this&&this.__awaiter||function(e,t,r,n){return new(r||(r=Promise))(function(i,a){function o(e){try{c(n.next(e))}catch(e){a(e)}}function s(e){try{c(n.throw(e))}catch(e){a(e)}}function c(e){e.done?i(e.value):new r(function(t){t(e.value)}).then(o,s)}c((n=n.apply(e,t||[])).next())})};Object.defineProperty(t,"__esModule",{value:!0}),r(48);const i=r(65),a=r(125);class o{constructor(e){e=e||{},this.documentLoader=e.documentLoader||new a.FetchDocumentLoader,this.documentCache={},this.validate=!e.skipValidation,this.expandContentTypeToBase=e.expandContentTypeToBase}static getPrefix(e,t){const r=e.indexOf(":");if(r>=0){if(e.length>r+1&&"/"===e.charAt(r+1)&&"/"===e.charAt(r+2))return null;const n=e.substr(0,r);if("_"===n)return null;if(t[n])return n}return null}static getContextValueId(e){if(null===e||"string"==typeof e)return e;const t=e["@id"];return t||null}static expandTerm(e,t,r){const n=t[e];if(null===n||n&&null===n["@id"])return null;if(n&&r){const t=this.getContextValueId(n);if(t&&t!==e)return t}const a=o.getPrefix(e,t);if(a){const r=this.getContextValueId(t[a]);if(r)return r+e.substr(a.length+1)}else{if(r&&t["@vocab"]&&"@"!==e.charAt(0)&&e.indexOf(":")<0)return t["@vocab"]+e;if(!r&&t["@base"]&&"@"!==e.charAt(0)&&e.indexOf(":")<0)return i.resolve(e,t["@base"])}return e}static compactIri(e,t,r){if(r&&t["@vocab"]&&e.startsWith(t["@vocab"]))return e.substr(t["@vocab"].length);if(!r&&t["@base"]&&e.startsWith(t["@base"]))return e.substr(t["@base"].length);for(const n in t){const i=t[n];if(i&&!n.startsWith("@")){const t=this.getContextValueId(i);if(e.startsWith(t)){const i=e.substr(t.length);if(i)return n+":"+i;if(r)return n}}}return e}static isPrefixValue(e){return e&&("string"==typeof e||e["@id"]||e["@type"])}static isValidIri(e){return o.IRI_REGEX.test(e)}static idifyReverseTerms(e){for(const t of Object.keys(e)){const r=e[t];if(r&&"object"==typeof r&&r["@reverse"]&&!r["@id"]){if("string"!=typeof r["@reverse"])throw new Error(`Invalid @reverse value: '${r["@reverse"]}'`);r["@id"]=r["@reverse"],r["@reverse"]=!0}}return e}static expandPrefixedTerms(e,t){for(const r of Object.keys(e))if(o.EXPAND_KEYS_BLACKLIST.indexOf(r)<0){if("@"===r[0]&&o.ALIAS_KEYS_BLACKLIST.indexOf(r)>=0)throw new Error(`Keywords can not be aliased to something else.\nTried mapping ${r} to ${e[r]}`);for(;o.isPrefixValue(e[r]);){const n=e[r];let i=!1;if("string"==typeof n)e[r]=o.expandTerm(n,e,!0),i=i||n!==e[r];else{const a=n["@id"],s=n["@type"];a&&(e[r]["@id"]=o.expandTerm(a,e,!0),i=i||a!==e[r]["@id"]),s&&"@vocab"!==s&&(e[r]["@type"]=o.expandTerm(s,e,!0),t&&s===e[r]["@type"]&&(e[r]["@type"]=o.expandTerm(s,e,!1)),i=i||s!==e[r]["@type"])}if(!i)break}}return e}static validate(e){for(const t of Object.keys(e)){const r=e[t],n=typeof r;if("@"===t[0])switch(t.substr(1)){case"vocab":if(null!==r&&"string"!==n)throw new Error(`Found an invalid @vocab IRI: ${r}`);break;case"base":if(null!==r&&"string"!==n)throw new Error(`Found an invalid @base IRI: ${e[t]}`);break;case"language":if(null!==r&&"string"!==n)throw new Error(`Found an invalid @language string: ${r}`)}if(null!==r)switch(n){case"string":break;case"object":if(t.indexOf(":")<0&&!("@id"in r)&&("@id"===r["@type"]?!e["@base"]:!e["@vocab"]))throw new Error(`Missing @id in context entry: '${t}': '${JSON.stringify(r)}'`);for(const e of Object.keys(r)){const n=r[e];if(n)switch(e){case"@id":if("@"===n[0]&&"@type"!==n&&"@id"!==n)throw new Error(`Illegal keyword alias in term value, found: '${t}': '${JSON.stringify(r)}'`);break;case"@type":if("@id"!==n&&"@vocab"!==n&&("_"===n[0]||!o.isValidIri(n)))throw new Error(`A context @type must be an absolute IRI, found: '${t}': '${n}'`);break;case"@reverse":if("string"==typeof n&&r["@id"]&&r["@id"]!==n)throw new Error(`Found non-matching @id and @reverse term values in '${t}':'${n}' and '${r["@id"]}'`);break;case"@container":if("@list"===n&&r["@reverse"])throw new Error(`Term value can not be @container: @list and @reverse at the same time on '${t}'`);if(o.CONTAINERS.indexOf(n)<0)throw new Error(`Invalid term @container for '${t}' ('${n}'), must be one of ${o.CONTAINERS.join(", ")}`);break;case"@language":if(null!==n&&"string"!=typeof n)throw new Error(`Found an invalid term @language string in: '${t}': '${JSON.stringify(r)}'`)}}break;default:throw new Error(`Found an invalid term value: '${t}': '${r}'`)}}}parse(e,{baseIri:t,parentContext:r,external:a}={}){return n(this,void 0,void 0,function*(){if(null==e)return t?{"@base":t}:{};if("string"==typeof e){if(!o.isValidIri(e)&&(e=i.resolve(e,t),!o.isValidIri(e)))throw new Error(`Invalid context IRI: ${e}`);return this.parse(yield this.load(e),{baseIri:t,parentContext:r,external:!0})}if(Array.isArray(e)){return(yield Promise.all(e.map(e=>"string"==typeof e?this.load(e):e))).reduce((e,r)=>e.then(e=>this.parse(r,{baseIri:t,parentContext:e,external:a})),Promise.resolve(r))}if("object"==typeof e){if(e["@context"])return yield this.parse(e["@context"],{baseIri:t,parentContext:r,external:a});let n={};return a&&delete e["@base"],!t||"@base"in n||(n["@base"]=t),n=Object.assign({},n,r,e),o.idifyReverseTerms(n),o.expandPrefixedTerms(n,this.expandContentTypeToBase),this.validate&&o.validate(n),n}throw new Error(`Tried parsing a context that is not a string, array or object, but got ${e}`)})}load(e){return n(this,void 0,void 0,function*(){const t=this.documentCache[e];return t?Array.isArray(t)?t.slice():Object.assign({},t):this.documentCache[e]=(yield this.documentLoader.load(e))["@context"]})}}o.IRI_REGEX=/^([A-Za-z][A-Za-z0-9+-.]*|_):[^ "<>{}|\\\[\]`]*$/,o.EXPAND_KEYS_BLACKLIST=["@base","@vocab","@language"],o.ALIAS_KEYS_BLACKLIST=["@container","@graph","@id","@index","@list","@nest","@none","@prefix","@reverse","@set","@type","@value"],o.CONTAINERS=["@list","@set","@index","@language"],t.ContextParser=o},function(e,t,r){"use strict";r.r(t),r.d(t,"Headers",function(){return u}),r.d(t,"Request",function(){return m}),r.d(t,"Response",function(){return b}),r.d(t,"DOMException",function(){return _}),r.d(t,"fetch",function(){return w});var n={searchParams:"URLSearchParams"in self,iterable:"Symbol"in self&&"iterator"in Symbol,blob:"FileReader"in self&&"Blob"in self&&function(){try{return new Blob,!0}catch(e){return!1}}(),formData:"FormData"in self,arrayBuffer:"ArrayBuffer"in self};if(n.arrayBuffer)var i=["[object Int8Array]","[object Uint8Array]","[object Uint8ClampedArray]","[object Int16Array]","[object Uint16Array]","[object Int32Array]","[object Uint32Array]","[object Float32Array]","[object Float64Array]"],a=ArrayBuffer.isView||function(e){return e&&i.indexOf(Object.prototype.toString.call(e))>-1};function o(e){if("string"!=typeof e&&(e=String(e)),/[^a-z0-9\-#$%&'*+.^_`|~]/i.test(e))throw new TypeError("Invalid character in header field name");return e.toLowerCase()}function s(e){return"string"!=typeof e&&(e=String(e)),e}function c(e){var t={next:function(){var t=e.shift();return{done:void 0===t,value:t}}};return n.iterable&&(t[Symbol.iterator]=function(){return t}),t}function u(e){this.map={},e instanceof u?e.forEach(function(e,t){this.append(t,e)},this):Array.isArray(e)?e.forEach(function(e){this.append(e[0],e[1])},this):e&&Object.getOwnPropertyNames(e).forEach(function(t){this.append(t,e[t])},this)}function l(e){if(e.bodyUsed)return Promise.reject(new TypeError("Already read"));e.bodyUsed=!0}function f(e){return new Promise(function(t,r){e.onload=function(){t(e.result)},e.onerror=function(){r(e.error)}})}function d(e){var t=new FileReader,r=f(t);return t.readAsArrayBuffer(e),r}function h(e){if(e.slice)return e.slice(0);var t=new Uint8Array(e.byteLength);return t.set(new Uint8Array(e)),t.buffer}function p(){return this.bodyUsed=!1,this._initBody=function(e){var t;this._bodyInit=e,e?"string"==typeof e?this._bodyText=e:n.blob&&Blob.prototype.isPrototypeOf(e)?this._bodyBlob=e:n.formData&&FormData.prototype.isPrototypeOf(e)?this._bodyFormData=e:n.searchParams&&URLSearchParams.prototype.isPrototypeOf(e)?this._bodyText=e.toString():n.arrayBuffer&&n.blob&&((t=e)&&DataView.prototype.isPrototypeOf(t))?(this._bodyArrayBuffer=h(e.buffer),this._bodyInit=new Blob([this._bodyArrayBuffer])):n.arrayBuffer&&(ArrayBuffer.prototype.isPrototypeOf(e)||a(e))?this._bodyArrayBuffer=h(e):this._bodyText=e=Object.prototype.toString.call(e):this._bodyText="",this.headers.get("content-type")||("string"==typeof e?this.headers.set("content-type","text/plain;charset=UTF-8"):this._bodyBlob&&this._bodyBlob.type?this.headers.set("content-type",this._bodyBlob.type):n.searchParams&&URLSearchParams.prototype.isPrototypeOf(e)&&this.headers.set("content-type","application/x-www-form-urlencoded;charset=UTF-8"))},n.blob&&(this.blob=function(){var e=l(this);if(e)return e;if(this._bodyBlob)return Promise.resolve(this._bodyBlob);if(this._bodyArrayBuffer)return Promise.resolve(new Blob([this._bodyArrayBuffer]));if(this._bodyFormData)throw new Error("could not read FormData body as blob");return Promise.resolve(new Blob([this._bodyText]))},this.arrayBuffer=function(){return this._bodyArrayBuffer?l(this)||Promise.resolve(this._bodyArrayBuffer):this.blob().then(d)}),this.text=function(){var e,t,r,n=l(this);if(n)return n;if(this._bodyBlob)return e=this._bodyBlob,t=new FileReader,r=f(t),t.readAsText(e),r;if(this._bodyArrayBuffer)return Promise.resolve(function(e){for(var t=new Uint8Array(e),r=new Array(t.length),n=0;n<t.length;n++)r[n]=String.fromCharCode(t[n]);return r.join("")}(this._bodyArrayBuffer));if(this._bodyFormData)throw new Error("could not read FormData body as text");return Promise.resolve(this._bodyText)},n.formData&&(this.formData=function(){return this.text().then(g)}),this.json=function(){return this.text().then(JSON.parse)},this}u.prototype.append=function(e,t){e=o(e),t=s(t);var r=this.map[e];this.map[e]=r?r+", "+t:t},u.prototype.delete=function(e){delete this.map[o(e)]},u.prototype.get=function(e){return e=o(e),this.has(e)?this.map[e]:null},u.prototype.has=function(e){return this.map.hasOwnProperty(o(e))},u.prototype.set=function(e,t){this.map[o(e)]=s(t)},u.prototype.forEach=function(e,t){for(var r in this.map)this.map.hasOwnProperty(r)&&e.call(t,this.map[r],r,this)},u.prototype.keys=function(){var e=[];return this.forEach(function(t,r){e.push(r)}),c(e)},u.prototype.values=function(){var e=[];return this.forEach(function(t){e.push(t)}),c(e)},u.prototype.entries=function(){var e=[];return this.forEach(function(t,r){e.push([r,t])}),c(e)},n.iterable&&(u.prototype[Symbol.iterator]=u.prototype.entries);var y=["DELETE","GET","HEAD","OPTIONS","POST","PUT"];function m(e,t){var r,n,i=(t=t||{}).body;if(e instanceof m){if(e.bodyUsed)throw new TypeError("Already read");this.url=e.url,this.credentials=e.credentials,t.headers||(this.headers=new u(e.headers)),this.method=e.method,this.mode=e.mode,this.signal=e.signal,i||null==e._bodyInit||(i=e._bodyInit,e.bodyUsed=!0)}else this.url=String(e);if(this.credentials=t.credentials||this.credentials||"same-origin",!t.headers&&this.headers||(this.headers=new u(t.headers)),this.method=(r=t.method||this.method||"GET",n=r.toUpperCase(),y.indexOf(n)>-1?n:r),this.mode=t.mode||this.mode||null,this.signal=t.signal||this.signal,this.referrer=null,("GET"===this.method||"HEAD"===this.method)&&i)throw new TypeError("Body not allowed for GET or HEAD requests");this._initBody(i)}function g(e){var t=new FormData;return e.trim().split("&").forEach(function(e){if(e){var r=e.split("="),n=r.shift().replace(/\+/g," "),i=r.join("=").replace(/\+/g," ");t.append(decodeURIComponent(n),decodeURIComponent(i))}}),t}function b(e,t){t||(t={}),this.type="default",this.status=void 0===t.status?200:t.status,this.ok=this.status>=200&&this.status<300,this.statusText="statusText"in t?t.statusText:"OK",this.headers=new u(t.headers),this.url=t.url||"",this._initBody(e)}m.prototype.clone=function(){return new m(this,{body:this._bodyInit})},p.call(m.prototype),p.call(b.prototype),b.prototype.clone=function(){return new b(this._bodyInit,{status:this.status,statusText:this.statusText,headers:new u(this.headers),url:this.url})},b.error=function(){var e=new b(null,{status:0,statusText:""});return e.type="error",e};var v=[301,302,303,307,308];b.redirect=function(e,t){if(-1===v.indexOf(t))throw new RangeError("Invalid status code");return new b(null,{status:t,headers:{location:e}})};var _=self.DOMException;try{new _}catch(e){(_=function(e,t){this.message=e,this.name=t;var r=Error(e);this.stack=r.stack}).prototype=Object.create(Error.prototype),_.prototype.constructor=_}function w(e,t){return new Promise(function(r,i){var a=new m(e,t);if(a.signal&&a.signal.aborted)return i(new _("Aborted","AbortError"));var o=new XMLHttpRequest;function s(){o.abort()}o.onload=function(){var e,t,n={status:o.status,statusText:o.statusText,headers:(e=o.getAllResponseHeaders()||"",t=new u,e.replace(/\r?\n[\t ]+/g," ").split(/\r?\n/).forEach(function(e){var r=e.split(":"),n=r.shift().trim();if(n){var i=r.join(":").trim();t.append(n,i)}}),t)};n.url="responseURL"in o?o.responseURL:n.headers.get("X-Request-URL");var i="response"in o?o.response:o.responseText;r(new b(i,n))},o.onerror=function(){i(new TypeError("Network request failed"))},o.ontimeout=function(){i(new TypeError("Network request failed"))},o.onabort=function(){i(new _("Aborted","AbortError"))},o.open(a.method,a.url,!0),"include"===a.credentials?o.withCredentials=!0:"omit"===a.credentials&&(o.withCredentials=!1),"responseType"in o&&n.blob&&(o.responseType="blob"),a.headers.forEach(function(e,t){o.setRequestHeader(t,e)}),a.signal&&(a.signal.addEventListener("abort",s),o.onreadystatechange=function(){4===o.readyState&&a.signal.removeEventListener("abort",s)}),o.send(void 0===a._bodyInit?null:a._bodyInit)})}w.polyfill=!0,self.fetch||(self.fetch=w,self.Headers=u,self.Request=m,self.Response=b)},function(e,t,r){"use strict";function n(e){const t=[];let r=0;for(;r<e.length;)switch(e[r]){case"/":if("."===e[r+1])if("."===e[r+2]){if(!a(e[r+3])){t.push([]),r++;break}t.pop(),e[r+3]||t.push([]),r+=3}else{if(!a(e[r+2])){t.push([]),r++;break}e[r+2]||t.push([]),r+=2}else t.push([]),r++;break;case"#":case"?":t.length||t.push([]),t[t.length-1].push(e.substr(r)),r=e.length;break;default:t.length||t.push([]),t[t.length-1].push(e[r]),r++}return"/"+t.map(e=>e.join("")).join("/")}function i(e,t){let r=t+1;t>=0?"/"===e[t+1]&&"/"===e[t+2]&&(r=t+3):"/"===e[0]&&"/"===e[1]&&(r=2);const i=e.indexOf("/",r);return i<0?e:e.substr(0,i)+n(e.substr(i))}function a(e){return!e||"#"===e||"?"===e||"/"===e}Object.defineProperty(t,"__esModule",{value:!0}),t.resolve=function(e,t){const r=(t=t||"").indexOf("#");if(r>0&&(t=t.substr(0,r)),!e.length)return t;if(e.startsWith("?")){const r=t.indexOf("?");return r>0&&(t=t.substr(0,r)),t+e}if(e.startsWith("#"))return t+e;if(!t.length)return i(e,e.indexOf(":"));const a=e.indexOf(":");if(a>=0)return i(e,a);const o=t.indexOf(":");if(o<0)throw new Error(`Found invalid baseIRI '${t}' for value '${e}'`);const s=t.substr(0,o+1);if(0===e.indexOf("//"))return s+i(e,a);let c;if(t.indexOf("//",o)===o+1){if((c=t.indexOf("/",o+3))<0)return t.length>o+3?t+"/"+i(e,a):s+i(e,a)}else if((c=t.indexOf("/",o+1))<0)return s+i(e,a);if(0===e.indexOf("/"))return t.substr(0,c)+n(e);let u=t.substr(c);const l=u.lastIndexOf("/");return l>=0&&l<u.length-1&&(u=u.substr(0,l+1),"."===e[0]&&"."!==e[1]&&"/"!==e[1]&&e[2]&&(e=e.substr(1))),e=n(e=u+e),t.substr(0,c)+e},t.removeDotSegments=n,t.removeDotSegmentsOfPath=i},function(e,t,r){"use strict";var n=r(19);Object.defineProperty(t,"__esModule",{value:!0}),t.toHandler=d,t.toResolver=h,t.default=void 0;var i=n(r(88)),a=n(r(128)),o=n(r(124)),s=n(r(129)),c=r(23);function u(e,t){var r=Object.keys(e);return Object.getOwnPropertySymbols&&r.push.apply(r,Object.getOwnPropertySymbols(e)),t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r}function l(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?u(r,!0).forEach(function(t){(0,i.default)(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):u(r).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}class f{constructor(e,t){this._settings=e=l({},e),this._data=t=l({},t);const r=e.handlers||s.default;for(const e in r)r[e]=d(r[e]);for(const e of Object.getOwnPropertySymbols(r))r[e]=d(r[e]);const n=(e.resolvers||[]).map(h);e.context?(n.push(new o.default(e.context)),e.parsedContext=(new c.ContextParser).parse(e.context)):e.context=e.parsedContext={},this._pathProxy=new a.default({handlers:r,resolvers:n}),delete e.handlers,delete e.resolvers}create(e={},t){return t||([t,e]=[e,null]),this._pathProxy.createPath(Object.assign(Object.create(null),this._settings,e),Object.assign(Object.create(null),this._data,t))}}function d(e){return"function"==typeof e.handle?e:{handle:e}}function h(e){return"function"==typeof e.resolve?e:{supports:p,resolve:e}}function p(){return!0}t.default=f,f.defaultHandlers=s.default},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;t.default=class{handle(e){return e.extendPath({distinct:!0,select:"?predicate",finalClause:e=>`${e} ?predicate ?object.`,property:e.property})}}},function(e,t,r){"use strict";var n=r(19);Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var i=n(r(120)),a=n(r(122)),o=n(r(86)),s=r(23);t.default=class{handle(e,t){return(0,a.default)(function*(){const r=(yield(0,i.default)(e.settings.parsedContext))||{};var n,a=!0,c=!1;try{for(var u,l,f=(0,o.default)(t.predicates);a=(u=yield(0,i.default)(f.next())).done,l=yield(0,i.default)(u.value),!a;a=!0){const e=l;yield s.ContextParser.compactIri(`${yield(0,i.default)(e)}`,r,!0)}}catch(e){c=!0,n=e}finally{try{a||null==f.return||(yield(0,i.default)(f.return()))}finally{if(c)throw n}}})()}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;t.default=class{handle(e){return e.extendPath({distinct:!0,select:"?subject",finalClause:()=>"?subject ?predicate ?object.",property:e.property})}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;const n=r(316);t.default=class{constructor(e){this._engine=n,this._sources=this.toComunicaSources(e)}execute(e,t){if(e.startsWith("INSERT")||e.startsWith("DELETE"))return this.executeUpdate(e,t);let r;const n=[];return{next:async()=>{if(!r){const i=await(t?this.toComunicaSources(t):this._sources),a=await this._engine.query(e,{sources:i});(r=a.bindingsStream).on("error",e=>n.push(e))}return new Promise(i)},[Symbol.asyncIterator](){return this}};function i(e,t){if(n.length>0)return t(n.shift());const i=()=>e({done:!0});r.ended?i():(r.once("data",t=>{e({value:t}),r.removeListener("end",i)}),r.on("end",i))}}executeUpdate(e,t){throw new Error(`Comunica does not support SPARQL UPDATE queries, received: ${e}`)}async toComunicaSources(e){let t=await e;return t?(t instanceof URL?t=t.href:"NamedNode"===t.termType&&(t=t.value),(t="string"==typeof t?[t.replace(/#.*/,"")]:Array.isArray(t)?await Promise.all(t):[t]).map(e=>({value:e,type:"string"==typeof e?"file":"rdfjsSource"}))):null}}},function(e,t,r){const n=new(r(137).LoggerVoid)({}),i=new(r(0).Bus)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-init/Bus/Init"}),a=new(r(0).Bus)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-http/Bus/Http"}),o=new(r(0).Bus)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-rdf-join/Bus/RdfJoin"}),s=new(r(0).Bus)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-rdf-parse/Bus/RdfParse"}),c=new(r(0).Bus)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-rdf-dereference/Bus/RdfDereference"}),u=new(r(0).Bus)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-rdf-parse-html/Bus/RdfParseHtml"}),l=new(r(0).Bus)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-rdf-resolve-quad-pattern/Bus/RdfResolveQuadPattern"}),f=new(r(0).Bus)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-rdf-metadata/Bus/RdfMetadata"}),d=new(r(0).Bus)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-rdf-metadata-extract/Bus/RdfMetadataExtract"}),h=new(r(0).Bus)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-rdf-resolve-hypermedia/Bus/RdfResolveHypermedia"}),p=new(r(0).Bus)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-rdf-resolve-hypermedia-links/Bus/RdfResolveHypermediaLinks"}),y=new(r(0).Bus)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-http-invalidate/Bus/HttpInvalidate"}),m=new(r(0).Bus)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-optimize-query-operation/Bus/OptimizeQueryOperation"}),g=new(r(0).Bus)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-sparql-parse/Bus/SparqlParse"}),b=new(r(0).Bus)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-sparql-serialize/Bus/SparqlSerialize"}),v=new(r(0).Bus)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-context-preprocess/Bus/ContextPreprocess"}),_=new(r(0).BusIndexed)({actorIdentifierFields:["operationName"],actionIdentifierFields:["operation","type"],name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-query-operation/Bus/QueryOperation"}),w=new(r(324).ActorHttpSolidAuthFetch)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/http.json#myHttpFetcher",bus:a}),S=new(r(38).MediatorNumber)({field:"time",type:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/mediator-number/Mediator/Number/type/TypeMin",ignoreErrors:!0,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/http.json#mediatorHttp",bus:a}),E=new(r(148).ActorRdfJoinNestedLoop)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/join.json#myRdfJoinActor",bus:o}),x=new(r(12).MediatorRace)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperators.json#mediatorRdfJoin",bus:o}),T=new(r(24).MediatorCombineUnion)({field:"mediaTypes",name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/rdf-dereference.json#mediatorRdfParseMediatypes",bus:s}),O=new(r(12).MediatorRace)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/rdf-dereference.json#mediatorRdfParseHandle",bus:s}),A=new(r(151).ActorRdfParseN3)({mediaTypes:{"application/trig":"1.0","application/n-quads":"0.7","text/turtle":"0.6","application/n-triples":"0.3","text/n3":"0.1"},priorityScale:"1",name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/rdf-parsers.json#myRdfParserN3",bus:s}),I=new(r(156).ActorRdfParseJsonLd)({mediaTypes:{"application/ld+json":"1.0","application/json":"0.5"},priorityScale:"9.0E-1",name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/rdf-parsers.json#myRdfParserJsonLd",bus:s}),N=new(r(160).ActorRdfParseRdfXml)({mediaTypes:{"application/rdf+xml":"1.0"},priorityScale:"5.0E-1",name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/rdf-parsers.json#myRdfParserRdfXml",bus:s}),R=new(r(162).ActorRdfParseXmlRdfa)({mediaTypes:{"application/xml":"1.0","text/xml":"1.0","image/svg+xml":"1.0"},priorityScale:"5.0E-1",name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/rdf-parsers.json#myRdfParserXmlRdfa",bus:s}),k=new(r(24).MediatorCombineUnion)({field:"mediaTypes",name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/rdf-parsers.json#mediatorRdfParseMediatypes",bus:s}),P=new(r(12).MediatorRace)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/rdf-parsers.json#mediatorRdfParseHandle",bus:s}),j=new(r(12).MediatorRace)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/resolve-hypermedia.json#mediatorRdfDereference",bus:c}),D=new(r(177).ActorRdfParseHtml)({busRdfParseHtml:u,mediaTypes:{"text/html":"1.0","application/xhtml+xml":"0.9"},priorityScale:"8.0E-1",name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/rdf-parsers.json#myRdfParserHtml",bus:s}),C=new(r(184).ActorRdfParseHtmlRdfa)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/rdf-parsers.json#myRdfParserHtmlRdfa",bus:u}),M=new(r(12).MediatorRace)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperators.json#mediatorResolveQuadPattern",bus:l}),L=new(r(186).ActorRdfResolveQuadPatternRdfJsSource)({name:"config-sets:resolve-file.json#myRdfRdfJsSourceQuadPatternResolver",bus:l}),q=new(r(12).MediatorRace)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/resolve-hypermedia.json#mediatorMetadata",bus:f}),F=new(r(188).ActorRdfMetadataPrimaryTopic)({metadataToData:!1,dataToMetadataOnInvalidMetadataGraph:!0,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/resolve-hypermedia.json#myRdfMetadataPrimaryTopic",bus:f}),B=new(r(191).ActorRdfMetadataAll)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/resolve-hypermedia.json#myRdfMetadataAll",bus:f}),U=new(r(24).MediatorCombineUnion)({field:"metadata",name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/resolve-hypermedia.json#mediatorMetadataExtract",bus:d}),V=new(r(192).ActorRdfMetadataExtractHydraControls)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/resolve-hypermedia.json#myRdfMetadataExtractHydraControls",bus:d}),H=new(r(204).ActorRdfMetadataExtractHydraCount)({predicates:["http://www.w3.org/ns/hydra/core#totalItems","http://rdfs.org/ns/void#triples"],name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/resolve-hypermedia.json#myRdfMetadataExtractHydraCount",bus:d}),z=new(r(205).ActorRdfMetadataExtractSparqlService)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/resolve-sparql.json#myRdfMetadataExtractSparqlService",bus:d}),G=new(r(206).ActorRdfResolveHypermediaNone)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/resolve-hypermedia.json#myHypermediaNoneResolver",bus:h}),Q=new(r(38).MediatorNumber)({field:"filterFactor",type:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/mediator-number/Mediator/Number/type/TypeMax",ignoreErrors:!0,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/resolve-hypermedia.json#mediatorRdfResolveHypermedia",bus:h}),X=new(r(12).MediatorRace)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/resolve-hypermedia.json#mediatorRdfResolveHypermediaLinks",bus:p}),$=new(r(207).ActorRdfResolveHypermediaLinksNext)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/resolve-hypermedia.json#myHypermediaLinksNext",bus:p}),J=new(r(208).ActorHttpInvalidateListenable)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-rdf-resolve-quad-pattern-hypermedia/Actor/RdfResolveQuadPattern/Hypermedia/httpInvalidator#default",bus:y}),Y=new(r(210).MediatorAll)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-init.json#mediatorHttpInvalidate",bus:y}),K=new(r(211).ActorOptimizeQueryOperationJoinBgp)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-optimize.json#myJoinBgpOptimizer",bus:m}),W=new(r(75).MediatorCombinePipeline)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-init.json#mediatorOptimizeQueryOperation",bus:m}),Z=new(r(12).MediatorRace)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-init.json#mediatorSparqlParse",bus:g}),ee=new(r(212).ActorSparqlParseAlgebra)({prefixes:{rdf:"http://www.w3.org/1999/02/22-rdf-syntax-ns#",rdfs:"http://www.w3.org/2000/01/rdf-schema#",owl:"http://www.w3.org/2002/07/owl#",xsd:"http://www.w3.org/2001/XMLSchema#",dc:"http://purl.org/dc/terms/",dcterms:"http://purl.org/dc/terms/",dc11:"http://purl.org/dc/elements/1.1/",foaf:"http://xmlns.com/foaf/0.1/",geo:"http://www.w3.org/2003/01/geo/wgs84_pos#",dbpedia:"http://dbpedia.org/resource/","dbpedia-owl":"http://dbpedia.org/ontology/",dbpprop:"http://dbpedia.org/property/",schema:"http://schema.org/",skos:"http://www.w3.org/2008/05/skos#"},name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-parsers.json#mySparqlParser",bus:g}),te=new(r(12).MediatorRace)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-init.json#mediatorSparqlSerialize",bus:b}),re=new(r(24).MediatorCombineUnion)({field:"mediaTypes",name:"_:b0bnode246",bus:b}),ne=new(r(75).MediatorCombinePipeline)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-init.json#mediatorContextPreprocess",bus:v}),ie=new(r(38).MediatorNumber)({field:"httpRequests",type:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/mediator-number/Mediator/Number/type/TypeMin",ignoreErrors:!0,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperators.json#mediatorQueryOperation",bus:_}),ae=new(r(214).ActorQueryOperationBgpEmpty)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperators.json#myEmptyBgpQueryOperator",bus:_}),oe=new(r(217).ActorQueryOperationValues)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperators.json#myValuesQueryOperator",bus:_}),se=new(r(218).ActorRdfResolveHypermediaSparql)({mediatorHttp:S,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/resolve-sparql.json#mySparqlQuadPatternResolver",bus:h}),ce=new(r(219).ActorQueryOperationSparqlEndpoint)({mediatorHttp:S,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/resolve-sparql.json#mySparqlEndpointResolver",bus:_}),ue=new(r(221).ActorRdfDereferenceHttpParse)({mediatorHttp:S,mediatorRdfParseMediatypes:T,mediatorRdfParseHandle:O,maxAcceptHeaderLength:1024,maxAcceptHeaderLengthBrowser:128,mediaMappings:{ttl:"text/turtle",turtle:"text/turtle",nt:"application/n-triples",ntriples:"application/n-triples",nq:"application/n-quads",nquads:"application/n-quads",rdf:"application/rdf+xml",rdfxml:"application/rdf+xml",owl:"application/rdf+xml",n3:"text/n3",trig:"application/trig",jsonld:"application/ld+json",json:"application/json",html:"text/html",htm:"text/html",xhtml:"application/xhtml+xml",xht:"application/xhtml+xml",xml:"application/xml",svg:"image/svg+xml",svgz:"image/svg+xml"},name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/rdf-dereference.json#myRdfDereferencer",bus:c}),le=new(r(224).ActorRdfParseHtmlScript)({mediatorRdfParseMediatypes:k,mediatorRdfParseHandle:P,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/rdf-parsers.json#myRdfParserHtmlScript",bus:u}),fe=new(r(225).ActorRdfResolveQuadPatternFederated)({mediatorResolveQuadPattern:M,skipEmptyPatterns:!1,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/resolve-federated.json#myFederatedQuadPatternResolver",bus:l}),de=new(r(226).ActorQueryOperationQuadpattern)({mediatorResolveQuadPattern:M,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperators.json#myQuadPatternQueryOperator",bus:_}),he=new(r(227).ActorRdfResolveHypermediaQpf)({mediatorMetadata:q,mediatorMetadataExtract:U,mediatorRdfDereference:j,subjectUri:"http://www.w3.org/1999/02/22-rdf-syntax-ns#subject",predicateUri:"http://www.w3.org/1999/02/22-rdf-syntax-ns#predicate",objectUri:"http://www.w3.org/1999/02/22-rdf-syntax-ns#object",graphUri:"http://www.w3.org/ns/sparql-service-description#graph",name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/resolve-hypermedia.json#myHypermediaQpfResolver",bus:h}),pe=new(r(228).ActorRdfResolveQuadPatternHypermedia)({mediatorRdfDereference:j,mediatorMetadata:q,mediatorMetadataExtract:U,mediatorRdfResolveHypermedia:Q,mediatorRdfResolveHypermediaLinks:X,cacheSize:100,httpInvalidator:J,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/resolve-hypermedia.json#myQuadPatternHypermediaResolver",bus:l}),ye=new(r(230).ActorInitSparql)({mediatorOptimizeQueryOperation:W,mediatorQueryOperation:ie,mediatorSparqlParse:Z,mediatorSparqlSerialize:te,mediatorSparqlSerializeMediaTypeCombiner:re,mediatorContextPreprocess:ne,mediatorHttpInvalidate:Y,logger:n,contextKeyShortcuts:{source:"@comunica/bus-rdf-resolve-quad-pattern:source",sources:"@comunica/bus-rdf-resolve-quad-pattern:sources",initialBindings:"@comunica/actor-init-sparql:initialBindings",queryFormat:"@comunica/actor-init-sparql:queryFormat",baseIRI:"@comunica/actor-init-sparql:baseIRI",log:"@comunica/core:log",datetime:"@comunica/actor-http-memento:datetime",queryTimestamp:"@comunica/actor-init-sparql:queryTimestamp",httpProxyHandler:"@comunica/actor-http-proxy:httpProxyHandler"},name:"urn:comunica:sparqlinit",bus:i});new(r(239).ActorQueryOperationAsk)({mediatorQueryOperation:ie,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperators.json#myAskQueryOperator",bus:_}),new(r(240).ActorQueryOperationService)({forceSparqlEndpoint:!1,mediatorQueryOperation:ie,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperators.json#myServiceQueryOperator",bus:_}),new(r(241).ActorQueryOperationSlice)({mediatorQueryOperation:ie,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperators.json#mySliceQueryOperator",bus:_}),new(r(242).ActorQueryOperationBgpSingle)({mediatorQueryOperation:ie,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperators.json#mySingleBgpQueryOperator",bus:_}),new(r(243).ActorQueryOperationBgpLeftDeepSmallest)({mediatorQueryOperation:ie,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperators.json#myLeftDeepSmallestBgpQueryOperator",bus:_}),new(r(245).ActorQueryOperationConstruct)({mediatorQueryOperation:ie,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperators.json#myConstructQueryOperator",bus:_}),new(r(246).ActorQueryOperationDescribeSubject)({mediatorQueryOperation:ie,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperators.json#myDescribeQueryOperator",bus:_}),new(r(247).ActorQueryOperationDistinctHash)({hashAlgorithm:"sha1",digestAlgorithm:"base64",mediatorQueryOperation:ie,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperators.json#myDistinctQueryOperator",bus:_}),new(r(279).ActorQueryOperationExtend)({mediatorQueryOperation:ie,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperators.json#myExtendQueryOperator",bus:_}),new(r(283).ActorQueryOperationReducedHash)({hashAlgorithm:"sha1",digestAlgorithm:"base64",cacheSize:100,mediatorQueryOperation:ie,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperators.json#myReducedQueryOperator",bus:_}),new(r(284).ActorQueryOperationFilterSparqlee)({mediatorQueryOperation:ie,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperators.json#myFilterQueryOperator",bus:_}),new(r(285).ActorQueryOperationFromQuad)({mediatorQueryOperation:ie,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperators.json#myFromQueryOperator",bus:_}),new(r(286).ActorQueryOperationGroup)({mediatorQueryOperation:ie,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperators.json#myGroupQueryOperator",bus:_}),new(r(287).ActorQueryOperationJoin)({mediatorJoin:x,mediatorQueryOperation:ie,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperators.json#myJoinQueryOperator",bus:_}),new(r(288).ActorQueryOperationLeftJoinNestedLoop)({mediatorQueryOperation:ie,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperators.json#myLeftJoinQueryOperator",bus:_}),new(r(289).ActorQueryOperationOrderBySparqlee)({mediatorQueryOperation:ie,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperators.json#myOrderByQueryOperator",bus:_}),new(r(290).ActorQueryOperationProject)({mediatorQueryOperation:ie,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperators.json#myProjectQueryOperator",bus:_}),new(r(100).ActorQueryOperationUnion)({mediatorQueryOperation:ie,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperators.json#myUnionQueryOperator",bus:_}),new(r(291).ActorQueryOperationMinus)({hashAlgorithm:"sha1",digestAlgorithm:"base64",mediatorQueryOperation:ie,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperators.json#myMinusQueryOperator",bus:_}),new(r(292).ActorQueryOperationPathAlt)({mediatorQueryOperation:ie,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperator-path.json#myAltPathOperator",bus:_}),new(r(294).ActorQueryOperationPathInv)({mediatorQueryOperation:ie,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperator-path.json#myInvPathOperator",bus:_}),new(r(295).ActorQueryOperationPathLink)({mediatorQueryOperation:ie,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperator-path.json#myLinkPathOperator",bus:_}),new(r(296).ActorQueryOperationPathNps)({mediatorQueryOperation:ie,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperator-path.json#myNpsPathOperator",bus:_}),new(r(297).ActorQueryOperationPathOneOrMore)({mediatorQueryOperation:ie,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperator-path.json#myOneOrMorePathOperator",bus:_}),new(r(298).ActorQueryOperationPathSeq)({mediatorQueryOperation:ie,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperator-path.json#mySeqPathOperator",bus:_}),new(r(299).ActorQueryOperationPathZeroOrMore)({mediatorQueryOperation:ie,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperator-path.json#myZeroOrMorePathOperator",bus:_}),new(r(300).ActorQueryOperationPathZeroOrOne)({mediatorQueryOperation:ie,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperator-path.json#myZeroOrOnePathOperator",bus:_});e.exports=ye},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(0);t.LoggerVoid=class extends n.Logger{debug(e,t){}error(e,t){}fatal(e,t){}info(e,t){}trace(e,t){}warn(e,t){}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(138);t.BusIndexed=class extends n.Bus{constructor(e){super(e),this.actorsIndex={}}subscribe(e){const t=this.getActorIdentifier(e)||"_undefined_";let r=this.actorsIndex[t];r||(r=this.actorsIndex[t]=[]),r.push(e),super.subscribe(e)}unsubscribe(e){const t=this.getActorIdentifier(e)||"_undefined_",r=this.actorsIndex[t];if(r){const n=r.indexOf(e);n>=0&&r.splice(n,1),0===r.length&&delete this.actorsIndex[t]}return super.unsubscribe(e)}publish(e){const t=this.getActionIdentifier(e);if(t){return(this.actorsIndex[t]||[]).concat(this.actorsIndex._undefined_||[]).map(t=>({actor:t,reply:t.test(e)}))}return super.publish(e)}getActorIdentifier(e){return this.actorIdentifierFields.reduce((e,t)=>e[t],e)}getActionIdentifier(e){return this.actionIdentifierFields.reduce((e,t)=>e[t],e)}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});t.ActionObserver=class{constructor(e){r(49)(this,e)}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(25),i=r(139);class a{constructor(e){this.beforeActors=[],r(49)(this,e),this.bus.subscribe(this),this.beforeActors.length&&this.bus.addDependencies(this,this.beforeActors)}static getContextLogger(e){return e?e.get(i.KEY_CONTEXT_LOG):null}runObservable(e){const t=this.run(e);return this.bus.onRun(this,e,t),t}async initialize(){return!0}async deinitialize(){return!0}getDefaultLogData(e,t){return t||(t={}),t.actor=this.name,t}logTrace(e,t,r){const n=a.getContextLogger(e);n&&n.trace(t,this.getDefaultLogData(e,r))}logDebug(e,t,r){const n=a.getContextLogger(e);n&&n.debug(t,this.getDefaultLogData(e,r))}logInfo(e,t,r){const n=a.getContextLogger(e);n&&n.info(t,this.getDefaultLogData(e,r))}logWarn(e,t,r){const n=a.getContextLogger(e);n&&n.warn(t,this.getDefaultLogData(e,r))}logError(e,t,r){const n=a.getContextLogger(e);n&&n.error(t,this.getDefaultLogData(e,r))}logFatal(e,t,r){const n=a.getContextLogger(e);n&&n.fatal(t,this.getDefaultLogData(e,r))}}function o(e){return n.Map(e)}t.Actor=a,t.ActionContext=o,t.ensureActionContext=function(e){return n.Map.isMap(e)?e:o(e)}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(66);t.Mediator=class{constructor(e){r(49)(this,e)}publish(e){const t=this.bus.publish(e);if(!t.length)throw new Error("No actors are able to reply to the message in the bus "+this.bus.name+": "+n.inspect(e));return t}async mediateActor(e){return await this.mediateWith(e,this.publish(e))}async mediate(e){return(await this.mediateActor(e)).runObservable(e)}}},function(e,t){e.exports=function(e){return e&&"object"==typeof e&&"function"==typeof e.copy&&"function"==typeof e.fill&&"function"==typeof e.readUInt8}},function(e,t){"function"==typeof Object.create?e.exports=function(e,t){e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}})}:e.exports=function(e,t){e.super_=t;var r=function(){};r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(325))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(37),i=r(63);t.ActorHttpSolidAuthFetch=class extends n.ActorHttp{constructor(e){super(e)}async test(e){return{time:1/0}}run(e){return i.fetch(e.input,e.init)}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(0);t.ActorHttp=class extends n.Actor{constructor(e){super(e)}static toNodeReadable(e){return r(327)(e)?e:r(140).toNodeReadable(e)}}},function(e,t,r){"use strict";const n=e=>null!==e&&"object"==typeof e&&"function"==typeof e.pipe;n.writable=e=>n(e)&&!1!==e.writable&&"function"==typeof e._write&&"object"==typeof e._writableState,n.readable=e=>n(e)&&!1!==e.readable&&"function"==typeof e._read&&"object"==typeof e._readableState,n.duplex=e=>n.writable(e)&&n.readable(e),n.transform=e=>n.duplex(e)&&"function"==typeof e._transform&&"object"==typeof e._transformState,e.exports=n},function(e,t,r){"use strict";t.byteLength=function(e){var t=u(e),r=t[0],n=t[1];return 3*(r+n)/4-n},t.toByteArray=function(e){var t,r,n=u(e),o=n[0],s=n[1],c=new a(function(e,t,r){return 3*(t+r)/4-r}(0,o,s)),l=0,f=s>0?o-4:o;for(r=0;r<f;r+=4)t=i[e.charCodeAt(r)]<<18|i[e.charCodeAt(r+1)]<<12|i[e.charCodeAt(r+2)]<<6|i[e.charCodeAt(r+3)],c[l++]=t>>16&255,c[l++]=t>>8&255,c[l++]=255&t;2===s&&(t=i[e.charCodeAt(r)]<<2|i[e.charCodeAt(r+1)]>>4,c[l++]=255&t);1===s&&(t=i[e.charCodeAt(r)]<<10|i[e.charCodeAt(r+1)]<<4|i[e.charCodeAt(r+2)]>>2,c[l++]=t>>8&255,c[l++]=255&t);return c},t.fromByteArray=function(e){for(var t,r=e.length,i=r%3,a=[],o=0,s=r-i;o<s;o+=16383)a.push(l(e,o,o+16383>s?s:o+16383));1===i?(t=e[r-1],a.push(n[t>>2]+n[t<<4&63]+"==")):2===i&&(t=(e[r-2]<<8)+e[r-1],a.push(n[t>>10]+n[t>>4&63]+n[t<<2&63]+"="));return a.join("")};for(var n=[],i=[],a="undefined"!=typeof Uint8Array?Uint8Array:Array,o="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",s=0,c=o.length;s<c;++s)n[s]=o[s],i[o.charCodeAt(s)]=s;function u(e){var t=e.length;if(t%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var r=e.indexOf("=");return-1===r&&(r=t),[r,r===t?0:4-r%4]}function l(e,t,r){for(var i,a,o=[],s=t;s<r;s+=3)i=(e[s]<<16&16711680)+(e[s+1]<<8&65280)+(255&e[s+2]),o.push(n[(a=i)>>18&63]+n[a>>12&63]+n[a>>6&63]+n[63&a]);return o.join("")}i["-".charCodeAt(0)]=62,i["_".charCodeAt(0)]=63},function(e,t){t.read=function(e,t,r,n,i){var a,o,s=8*i-n-1,c=(1<<s)-1,u=c>>1,l=-7,f=r?i-1:0,d=r?-1:1,h=e[t+f];for(f+=d,a=h&(1<<-l)-1,h>>=-l,l+=s;l>0;a=256*a+e[t+f],f+=d,l-=8);for(o=a&(1<<-l)-1,a>>=-l,l+=n;l>0;o=256*o+e[t+f],f+=d,l-=8);if(0===a)a=1-u;else{if(a===c)return o?NaN:1/0*(h?-1:1);o+=Math.pow(2,n),a-=u}return(h?-1:1)*o*Math.pow(2,a-n)},t.write=function(e,t,r,n,i,a){var o,s,c,u=8*a-i-1,l=(1<<u)-1,f=l>>1,d=23===i?Math.pow(2,-24)-Math.pow(2,-77):0,h=n?0:a-1,p=n?1:-1,y=t<0||0===t&&1/t<0?1:0;for(t=Math.abs(t),isNaN(t)||t===1/0?(s=isNaN(t)?1:0,o=l):(o=Math.floor(Math.log(t)/Math.LN2),t*(c=Math.pow(2,-o))<1&&(o--,c*=2),(t+=o+f>=1?d/c:d*Math.pow(2,1-f))*c>=2&&(o++,c/=2),o+f>=l?(s=0,o=l):o+f>=1?(s=(t*c-1)*Math.pow(2,i),o+=f):(s=t*Math.pow(2,f-1)*Math.pow(2,i),o=0));i>=8;e[r+h]=255&s,h+=p,s/=256,i-=8);for(o=o<<i|s,u+=i;u>0;e[r+h]=255&o,h+=p,o/=256,u-=8);e[r+h-p]|=128*y}},function(e,t){},function(e,t,r){"use strict";var n=r(90).Buffer,i=r(332);e.exports=function(){function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.head=null,this.tail=null,this.length=0}return e.prototype.push=function(e){var t={data:e,next:null};this.length>0?this.tail.next=t:this.head=t,this.tail=t,++this.length},e.prototype.unshift=function(e){var t={data:e,next:this.head};0===this.length&&(this.tail=t),this.head=t,++this.length},e.prototype.shift=function(){if(0!==this.length){var e=this.head.data;return 1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,e}},e.prototype.clear=function(){this.head=this.tail=null,this.length=0},e.prototype.join=function(e){if(0===this.length)return"";for(var t=this.head,r=""+t.data;t=t.next;)r+=e+t.data;return r},e.prototype.concat=function(e){if(0===this.length)return n.alloc(0);if(1===this.length)return this.head.data;for(var t,r,i,a=n.allocUnsafe(e>>>0),o=this.head,s=0;o;)t=o.data,r=a,i=s,t.copy(r,i),s+=o.data.length,o=o.next;return a},e}(),i&&i.inspect&&i.inspect.custom&&(e.exports.prototype[i.inspect.custom]=function(){var e=i.inspect({length:this.length});return this.constructor.name+" "+e})},function(e,t){},function(e,t,r){(function(e,t){!function(e,r){"use strict";if(!e.setImmediate){var n,i,a,o,s,c=1,u={},l=!1,f=e.document,d=Object.getPrototypeOf&&Object.getPrototypeOf(e);d=d&&d.setTimeout?d:e,"[object process]"==={}.toString.call(e.process)?n=function(e){t.nextTick(function(){p(e)})}:!function(){if(e.postMessage&&!e.importScripts){var t=!0,r=e.onmessage;return e.onmessage=function(){t=!1},e.postMessage("","*"),e.onmessage=r,t}}()?e.MessageChannel?((a=new MessageChannel).port1.onmessage=function(e){p(e.data)},n=function(e){a.port2.postMessage(e)}):f&&"onreadystatechange"in f.createElement("script")?(i=f.documentElement,n=function(e){var t=f.createElement("script");t.onreadystatechange=function(){p(e),t.onreadystatechange=null,i.removeChild(t),t=null},i.appendChild(t)}):n=function(e){setTimeout(p,0,e)}:(o="setImmediate$"+Math.random()+"$",s=function(t){t.source===e&&"string"==typeof t.data&&0===t.data.indexOf(o)&&p(+t.data.slice(o.length))},e.addEventListener?e.addEventListener("message",s,!1):e.attachEvent("onmessage",s),n=function(t){e.postMessage(o+t,"*")}),d.setImmediate=function(e){"function"!=typeof e&&(e=new Function(""+e));for(var t=new Array(arguments.length-1),r=0;r<t.length;r++)t[r]=arguments[r+1];var i={callback:e,args:t};return u[c]=i,n(c),c++},d.clearImmediate=h}function h(e){delete u[e]}function p(e){if(l)setTimeout(p,0,e);else{var t=u[e];if(t){l=!0;try{!function(e){var t=e.callback,n=e.args;switch(n.length){case 0:t();break;case 1:t(n[0]);break;case 2:t(n[0],n[1]);break;case 3:t(n[0],n[1],n[2]);break;default:t.apply(r,n)}}(t)}finally{h(e),l=!1}}}}}("undefined"==typeof self?void 0===e?this:e:self)}).call(this,r(9),r(13))},function(e,t,r){(function(t){function r(e){try{if(!t.localStorage)return!1}catch(e){return!1}var r=t.localStorage[e];return null!=r&&"true"===String(r).toLowerCase()}e.exports=function(e,t){if(r("noDeprecation"))return e;var n=!1;return function(){if(!n){if(r("throwDeprecation"))throw new Error(t);r("traceDeprecation")?console.trace(t):console.warn(t),n=!0}return e.apply(this,arguments)}}}).call(this,r(9))},function(e,t,r){"use strict";e.exports=a;var n=r(145),i=r(50);function a(e){if(!(this instanceof a))return new a(e);n.call(this,e)}i.inherits=r(1),i.inherits(a,n),a.prototype._transform=function(e,t,r){r(null,e)}},function(e,t,r){e.exports=r(91)},function(e,t,r){e.exports=r(32)},function(e,t,r){e.exports=r(89).Transform},function(e,t,r){e.exports=r(89).PassThrough},function(e,t,r){"use strict";const n=r(3).Readable,i=r(147).ReadableStream;class a extends n{constructor(e,t){super(t),this._webStream=e,this._reader=e.getReader(),this._reading=!1}_read(e){if(this._reading)return;this._reading=!0;const t=()=>{this._reader.read().then(r=>{if(!r.done)return this.push(r.value)?t(e):void(this._reading=!1);this.push(null)})};t()}}e.exports={readable:{nodeToWeb:function(e){return new i({start(t){e.pause(),e.on("data",r=>{t.enqueue(r),e.pause()}),e.on("end",()=>t.close()),e.on("error",e=>t.error(e))},pull(t){e.resume()},cancel(t){e.pause()}})},arrayToWeb:function(e){return new i({start(t){for(var r=0;r<e.length;r++)t.enqueue(e[r]);t.close()}})},webToNode:function(e){return new a(e)}}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(0);class i extends n.Mediator{constructor(e){super(e),this.indexPicker=this.createIndexPicker()}createIndexPicker(){switch(this.type){case i.MIN:return e=>e.reduce((e,t,r)=>{const n=this.getOrDefault(t[this.field],1/0);return null!==n&&(isNaN(e[0])||e[0]>n)?[n,r]:e},[NaN,-1])[1];case i.MAX:return e=>e.reduce((e,t,r)=>{const n=this.getOrDefault(t[this.field],-1/0);return null!==n&&(isNaN(e[0])||e[0]<n)?[n,r]:e},[NaN,-1])[1]}throw new Error('No valid "type" value was given, must be either '+i.MIN+" or "+i.MAX+", but got: "+this.type)}getOrDefault(e,t){return void 0===e?t:e}async mediateWith(e,t){let r=t.map(({reply:e})=>e);const n=[];if(this.ignoreErrors){const e={};e[this.field]=null,r=r.map(t=>t.catch(t=>(n.push(t),e)))}const i=await Promise.all(r),a=this.indexPicker(i);if(a<0)throw new Error("All actors rejected their test in "+this.name+"\n"+n.map(e=>e.toString()).join("\n"));return t[a].actor}}i.MIN="https://linkedsoftwaredependencies.org/bundles/npm/@comunica/mediator-number/Mediator/Number/type/TypeMin",i.MAX="https://linkedsoftwaredependencies.org/bundles/npm/@comunica/mediator-number/Mediator/Number/type/TypeMax",t.MediatorNumber=i},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(149),i=r(345);t.ActorRdfJoinNestedLoop=class extends n.ActorRdfJoin{constructor(e){super(e,2)}async getOutput(e){return{type:"bindings",bindingsStream:new i.NestedLoopJoin(e.entries[0].bindingsStream,e.entries[1].bindingsStream,n.ActorRdfJoin.join),variables:n.ActorRdfJoin.joinVariables(e)}}async getIterations(e){return(await e.entries[0].metadata()).totalItems*(await e.entries[1].metadata()).totalItems}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(0),i=r(6);class a extends n.Actor{constructor(e,t){super(e),this.maxEntries=t}static overlappingVariables(e){return r(344).apply(this,e.entries.map(e=>e.variables))}static joinVariables(e){return r(150).apply(this,e.entries.map(e=>e.variables))}static join(...e){try{return e.reduce((e,t)=>e.mergeWith((e,t)=>{if(!e.equals(t))throw new Error;return e},t))}catch(e){return null}}static async iteratorsHaveMetadata(e,t){return Promise.all(e.entries.map(async e=>{if(!(await e.metadata()).hasOwnProperty(t))throw new Error})).then(()=>!0).catch(()=>!1)}async test(e){if(e.entries.length<=1)return{iterations:0};if(this.maxEntries&&e.entries.length>this.maxEntries)throw new Error(this.name+" supports "+this.maxEntries+" sources at most. The input contained "+e.entries.length+".");for(const t of e.entries)if("bindings"!==t.type)throw new Error("Invalid type of a join entry: Expected 'bindings' but got '"+t.type+"'");return await a.iteratorsHaveMetadata(e,"totalItems")?{iterations:await this.getIterations(e)}:{iterations:1/0}}async run(e){if(0===e.entries.length)return{bindingsStream:new i.EmptyIterator,metadata:()=>Promise.resolve({totalItems:0}),type:"bindings",variables:[]};if(1===e.entries.length)return e.entries[0];const t=this.getOutput(e);if(await a.iteratorsHaveMetadata(e,"totalItems")){const r=()=>Promise.all(e.entries.map(e=>e.metadata())).then(e=>e.reduce((e,t)=>e*t.totalItems,1)),n=await t;if(n.metadata){const e=n.metadata;n.metadata=()=>e().then(async e=>(e.hasOwnProperty("totalItems")||(e.totalItems=await r()),e))}else n.metadata=()=>r().then(e=>({totalItems:e}));return n}return t}}t.ActorRdfJoin=a},function(e,t,r){(function(t){var r="__lodash_hash_undefined__",n=9007199254740991,i="[object Function]",a="[object GeneratorFunction]",o=/^\[object .+?Constructor\]$/,s="object"==typeof t&&t&&t.Object===Object&&t,c="object"==typeof self&&self&&self.Object===Object&&self,u=s||c||Function("return this")();function l(e,t,r){switch(r.length){case 0:return e.call(t);case 1:return e.call(t,r[0]);case 2:return e.call(t,r[0],r[1]);case 3:return e.call(t,r[0],r[1],r[2])}return e.apply(t,r)}function f(e,t){return!!(e?e.length:0)&&function(e,t,r){if(t!=t)return function(e,t,r,n){var i=e.length,a=r+(n?1:-1);for(;n?a--:++a<i;)if(t(e[a],a,e))return a;return-1}(e,p,r);var n=r-1,i=e.length;for(;++n<i;)if(e[n]===t)return n;return-1}(e,t,0)>-1}function d(e,t,r){for(var n=-1,i=e?e.length:0;++n<i;)if(r(t,e[n]))return!0;return!1}function h(e,t){for(var r=-1,n=e?e.length:0,i=Array(n);++r<n;)i[r]=t(e[r],r,e);return i}function p(e){return e!=e}function y(e){return function(t){return e(t)}}function m(e,t){return e.has(t)}var g,b=Array.prototype,v=Function.prototype,_=Object.prototype,w=u["__core-js_shared__"],S=(g=/[^.]+$/.exec(w&&w.keys&&w.keys.IE_PROTO||""))?"Symbol(src)_1."+g:"",E=v.toString,x=_.hasOwnProperty,T=_.toString,O=RegExp("^"+E.call(x).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),A=b.splice,I=Math.max,N=Math.min,R=B(u,"Map"),k=B(Object,"create");function P(e){var t=-1,r=e?e.length:0;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}function j(e){var t=-1,r=e?e.length:0;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}function D(e){var t=-1,r=e?e.length:0;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}function C(e){var t=-1,r=e?e.length:0;for(this.__data__=new D;++t<r;)this.add(e[t])}function M(e,t){for(var r,n,i=e.length;i--;)if((r=e[i][0])===(n=t)||r!=r&&n!=n)return i;return-1}function L(e){return!(!G(e)||(t=e,S&&S in t))&&(z(e)||function(e){var t=!1;if(null!=e&&"function"!=typeof e.toString)try{t=!!(e+"")}catch(e){}return t}(e)?O:o).test(function(e){if(null!=e){try{return E.call(e)}catch(e){}try{return e+""}catch(e){}}return""}(e));var t}function q(e){return function(e){return function(e){return!!e&&"object"==typeof e}(e)&&function(e){return null!=e&&function(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=n}(e.length)&&!z(e)}(e)}(e)?e:[]}function F(e,t){var r,n,i=e.__data__;return("string"==(n=typeof(r=t))||"number"==n||"symbol"==n||"boolean"==n?"__proto__"!==r:null===r)?i["string"==typeof t?"string":"hash"]:i.map}function B(e,t){var r=function(e,t){return null==e?void 0:e[t]}(e,t);return L(r)?r:void 0}P.prototype.clear=function(){this.__data__=k?k(null):{}},P.prototype.delete=function(e){return this.has(e)&&delete this.__data__[e]},P.prototype.get=function(e){var t=this.__data__;if(k){var n=t[e];return n===r?void 0:n}return x.call(t,e)?t[e]:void 0},P.prototype.has=function(e){var t=this.__data__;return k?void 0!==t[e]:x.call(t,e)},P.prototype.set=function(e,t){return this.__data__[e]=k&&void 0===t?r:t,this},j.prototype.clear=function(){this.__data__=[]},j.prototype.delete=function(e){var t=this.__data__,r=M(t,e);return!(r<0)&&(r==t.length-1?t.pop():A.call(t,r,1),!0)},j.prototype.get=function(e){var t=this.__data__,r=M(t,e);return r<0?void 0:t[r][1]},j.prototype.has=function(e){return M(this.__data__,e)>-1},j.prototype.set=function(e,t){var r=this.__data__,n=M(r,e);return n<0?r.push([e,t]):r[n][1]=t,this},D.prototype.clear=function(){this.__data__={hash:new P,map:new(R||j),string:new P}},D.prototype.delete=function(e){return F(this,e).delete(e)},D.prototype.get=function(e){return F(this,e).get(e)},D.prototype.has=function(e){return F(this,e).has(e)},D.prototype.set=function(e,t){return F(this,e).set(e,t),this},C.prototype.add=C.prototype.push=function(e){return this.__data__.set(e,r),this},C.prototype.has=function(e){return this.__data__.has(e)};var U,V,H=(U=function(e){var t=h(e,q);return t.length&&t[0]===e[0]?function(e,t,r){for(var n=r?d:f,i=e[0].length,a=e.length,o=a,s=Array(a),c=1/0,u=[];o--;){var l=e[o];o&&t&&(l=h(l,y(t))),c=N(l.length,c),s[o]=!r&&(t||i>=120&&l.length>=120)?new C(o&&l):void 0}l=e[0];var p=-1,g=s[0];e:for(;++p<i&&u.length<c;){var b=l[p],v=t?t(b):b;if(b=r||0!==b?b:0,!(g?m(g,v):n(u,v,r))){for(o=a;--o;){var _=s[o];if(!(_?m(_,v):n(e[o],v,r)))continue e}g&&g.push(v),u.push(b)}}return u}(t):[]},V=I(void 0===V?U.length-1:V,0),function(){for(var e=arguments,t=-1,r=I(e.length-V,0),n=Array(r);++t<r;)n[t]=e[V+t];t=-1;for(var i=Array(V+1);++t<V;)i[t]=e[t];return i[V]=n,l(U,this,i)});function z(e){var t=G(e)?T.call(e):"";return t==i||t==a}function G(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}e.exports=H}).call(this,r(9))},function(e,t,r){const n=r(346),i=r(347),a=r(348),o=r(349),s=r(350);e.exports={DynamicNestedLoopJoin:n,HashJoin:i,NestedLoopJoin:a,SymmetricHashJoin:o,MergeStream:s}},function(e,t,r){let n=r(6),i=n.MultiTransformIterator,a=n.SimpleTransformIterator;e.exports=class extends i{constructor(e,t,r){super(e),this.funRight=t,this.funJoin=r}_createTransformer(e){return new a(this.funRight(e),{transform:(t,r)=>{let n=this.funJoin(e,t);null!==n&&this._push(n),r()}})}}},function(e,t,r){let n=r(6);e.exports=class extends n{constructor(e,t,r,n){super(t),this.left=e,this.right=t,this.funHash=r,this.funJoin=n,this.leftMap=new Map,this.match=null,this.matches=[],this.matchIdx=0,this.readable=!1,this.left.on("end",function(){if(this.leftMap.size<=0)return this.close();this.readable=!0,this.right.on("readable",()=>this.readable=!0),this.right.on("end",()=>{this.hasResults()||this._end()})}.bind(this)),this.left.on("data",function(e){let t=this.funHash(e);this.leftMap.has(t)||this.leftMap.set(t,[]);this.leftMap.get(t).push(e)}.bind(this))}hasResults(){return!this.right.ended||this.matchIdx<this.matches.length}close(){super.close(),this.left.close(),this.right.close()}read(){if(this.ended||!this.readable)return null;for(;this.matchIdx<this.matches.length;){let e=this.matches[this.matchIdx++],t=this.funJoin(e,this.match);if(null!==t)return t}if(this.hasResults()||this._end(),this.match=this.right.read(),null===this.match)return this.readable=!1,null;let e=this.funHash(this.match);return this.matches=this.leftMap.get(e)||[],this.matchIdx=0,this.read()}}},function(e,t,r){let n=r(6),i=n.MultiTransformIterator,a=n.SimpleTransformIterator;e.exports=class extends i{constructor(e,t,r){super(e),this.right=t,this.funJoin=r,this.on("end",()=>this.right.close())}close(){super.close(),this.right.close()}_createTransformer(e){return new a(this.right.clone(),{transform:(t,r)=>{let n=this.funJoin(e,t);null!==n&&this._push(n),r()}})}}},function(e,t,r){let n=r(6);e.exports=class extends n{constructor(e,t,r,n){super(),this.left=e,this.right=t,this.funHash=r,this.funJoin=n,this.usedLeft=!1,this.leftMap=new Map,this.rightMap=new Map,this.on("end",()=>this._cleanup()),this.match=null,this.matches=[],this.matchIdx=0,this.left.on("readable",()=>this.readable=!0),this.right.on("readable",()=>this.readable=!0),this.left.on("end",()=>{this.hasResults()||this._end()}),this.right.on("end",()=>{this.hasResults()||this._end()})}hasResults(){return!this.left.ended||!this.right.ended||this.matchIdx<this.matches.length}_cleanup(){this.leftMap=null,this.rightMap=null,this.matches=null}close(){super.close(),this.left.close(),this.right.close()}read(){if(this.ended)return null;for(;this.matchIdx<this.matches.length;){let e=this.matches[this.matchIdx++],t=this.usedLeft?this.funJoin(this.match,e):this.funJoin(e,this.match);if(null!==t)return t}this.hasResults()||this._end();let e=null;for(let t=0;t<2&&(e=this.usedLeft?this.right.read():this.left.read(),this.usedLeft=!this.usedLeft,null===e);++t);if(null===e)return this.readable=!1,null;let t=this.funHash(e),r=this.usedLeft?this.leftMap:this.rightMap;return r.has(t)||r.set(t,[]),r.get(t).push(e),this.match=e,this.matches=(this.usedLeft?this.rightMap:this.leftMap).get(t)||[],this.matchIdx=0,this.read()}}},function(e,t,r){let n=r(6);e.exports=class extends n{constructor(e){super(),Array.isArray(e)||(e=Array.prototype.slice.call(arguments)),this.streams=e;for(let t of e)t.on("readable",()=>this.emit("readable")),t.on("end",()=>this._removeStream(t));0===this.streams.length&&this.close(),this.idx=this.streams.length-1}_removeStream(e){let t=this.streams.indexOf(e);t<0||(this.streams.splice(t,1),this.idx>=this.streams.length&&--this.idx,0===this.streams.length&&this._end())}close(){super.close();for(let e of this.streams)e.close()}read(){for(let e=0;e<this.streams.length;++e){this.idx=(this.idx+1)%this.streams.length;let e=this.streams[this.idx].read();if(null!==e)return e}return null}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(0);t.MediatorRace=class extends n.Mediator{constructor(e){super(e)}mediateWith(e,t){return new Promise((e,r)=>{const n=[];for(const i of t)i.reply.then(()=>{e(i.actor)}).catch(e=>{n.push(e),n.length===t.length&&r(new Error(this.name+" mediated over all rejecting actors:\n"+n.map(e=>e.toString()).join("\n")))})})}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(0);t.MediatorCombineUnion=class extends n.Mediator{constructor(e){super(e),this.combiner=this.createCombiner()}async mediate(e){let t;try{t=this.publish(e)}catch(e){t=[]}await Promise.all(t.map(({reply:e})=>e));const r=await Promise.all(t.map(t=>t.actor.runObservable(e)));return this.combiner(r)}mediateWith(e,t){throw new Error("Method not supported.")}createCombiner(){return e=>{const t={};return t[this.field]=r(353).apply({},[{}].concat(e.map(e=>e[this.field]))),t}}}},function(e,t){var r=9007199254740991,n="[object Arguments]",i="[object Function]",a="[object GeneratorFunction]",o=/^(?:0|[1-9]\d*)$/;function s(e,t,r){switch(r.length){case 0:return e.call(t);case 1:return e.call(t,r[0]);case 2:return e.call(t,r[0],r[1]);case 3:return e.call(t,r[0],r[1],r[2])}return e.apply(t,r)}var c=Object.prototype,u=c.hasOwnProperty,l=c.toString,f=c.propertyIsEnumerable,d=Math.max;function h(e,t){var r=_(e)||function(e){return function(e){return function(e){return!!e&&"object"==typeof e}(e)&&w(e)}(e)&&u.call(e,"callee")&&(!f.call(e,"callee")||l.call(e)==n)}(e)?function(e,t){for(var r=-1,n=Array(e);++r<e;)n[r]=t(r);return n}(e.length,String):[],i=r.length,a=!!i;for(var o in e)!t&&!u.call(e,o)||a&&("length"==o||b(o,i))||r.push(o);return r}function p(e,t,r,n){return void 0===e||v(e,c[r])&&!u.call(n,r)?t:e}function y(e,t,r){var n=e[t];u.call(e,t)&&v(n,r)&&(void 0!==r||t in e)||(e[t]=r)}function m(e){if(!S(e))return function(e){var t=[];if(null!=e)for(var r in Object(e))t.push(r);return t}(e);var t,r,n,i=(r=(t=e)&&t.constructor,n="function"==typeof r&&r.prototype||c,t===n),a=[];for(var o in e)("constructor"!=o||!i&&u.call(e,o))&&a.push(o);return a}function g(e,t){return t=d(void 0===t?e.length-1:t,0),function(){for(var r=arguments,n=-1,i=d(r.length-t,0),a=Array(i);++n<i;)a[n]=r[t+n];n=-1;for(var o=Array(t+1);++n<t;)o[n]=r[n];return o[t]=a,s(e,this,o)}}function b(e,t){return!!(t=null==t?r:t)&&("number"==typeof e||o.test(e))&&e>-1&&e%1==0&&e<t}function v(e,t){return e===t||e!=e&&t!=t}var _=Array.isArray;function w(e){return null!=e&&function(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=r}(e.length)&&!function(e){var t=S(e)?l.call(e):"";return t==i||t==a}(e)}function S(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}var E,x=(E=function(e,t,r,n){!function(e,t,r,n){r||(r={});for(var i=-1,a=t.length;++i<a;){var o=t[i],s=n?n(r[o],e[o],o,r,e):void 0;y(r,o,void 0===s?e[o]:s)}}(t,function(e){return w(e)?h(e,!0):m(e)}(t),e,n)},g(function(e,t){var r=-1,n=t.length,i=n>1?t[n-1]:void 0,a=n>2?t[2]:void 0;for(i=E.length>3&&"function"==typeof i?(n--,i):void 0,a&&function(e,t,r){if(!S(r))return!1;var n=typeof t;return!!("number"==n?w(r)&&b(t,r.length):"string"==n&&t in r)&&v(r[t],e)}(t[0],t[1],a)&&(i=n<3?void 0:i,n=1),e=Object(e);++r<n;){var o=t[r];o&&E(e,o,r,i)}return e})),T=g(function(e){return e.push(void 0,p),s(x,void 0,e)});e.exports=T},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(52),i=r(68);t.ActorRdfParseN3=class extends n.ActorRdfParseFixedMediaTypes{constructor(e){super(e)}async runHandle(e,t,r){e.input.on("error",e=>n.emit("error",e));const n=e.input.pipe(new i.StreamParser({baseIRI:e.baseIRI}));return{quads:n,triples:"text/turtle"===t||"application/n-triples"===t||"text/n3"===t}}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(39);t.ActorRdfParse=class extends n.ActorAbstractMediaTyped{constructor(e){super(e)}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(152);t.ActorAbstractMediaTypedFixed=class extends n.ActorAbstractMediaTyped{constructor(e){super(e);const t=this.priorityScale||0===this.priorityScale?this.priorityScale:1;this.mediaTypes=r(357)(this.mediaTypes,e=>e*t),this.mediaTypes=Object.freeze(this.mediaTypes)}async testHandle(e,t,r){if(!(t in this.mediaTypes))throw new Error("Unrecognized media type: "+t);return await this.testHandleChecked(e,r)}async testMediaType(e){return!0}async getMediaTypes(e){return this.mediaTypes}}},function(e,t,r){(function(e,r){var n=200,i="Expected a function",a="__lodash_hash_undefined__",o=1,s=2,c=1/0,u=9007199254740991,l="[object Arguments]",f="[object Array]",d="[object Boolean]",h="[object Date]",p="[object Error]",y="[object Function]",m="[object GeneratorFunction]",g="[object Map]",b="[object Number]",v="[object Object]",_="[object RegExp]",w="[object Set]",S="[object String]",E="[object Symbol]",x="[object ArrayBuffer]",T="[object DataView]",O=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,A=/^\w*$/,I=/^\./,N=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,R=/\\(\\)?/g,k=/^\[object .+?Constructor\]$/,P=/^(?:0|[1-9]\d*)$/,j={};j["[object Float32Array]"]=j["[object Float64Array]"]=j["[object Int8Array]"]=j["[object Int16Array]"]=j["[object Int32Array]"]=j["[object Uint8Array]"]=j["[object Uint8ClampedArray]"]=j["[object Uint16Array]"]=j["[object Uint32Array]"]=!0,j[l]=j[f]=j[x]=j[d]=j[T]=j[h]=j[p]=j[y]=j[g]=j[b]=j[v]=j[_]=j[w]=j[S]=j["[object WeakMap]"]=!1;var D="object"==typeof e&&e&&e.Object===Object&&e,C="object"==typeof self&&self&&self.Object===Object&&self,M=D||C||Function("return this")(),L=t&&!t.nodeType&&t,q=L&&"object"==typeof r&&r&&!r.nodeType&&r,F=q&&q.exports===L&&D.process,B=function(){try{return F&&F.binding("util")}catch(e){}}(),U=B&&B.isTypedArray;function V(e,t){for(var r=-1,n=e?e.length:0;++r<n;)if(t(e[r],r,e))return!0;return!1}function H(e){var t=!1;if(null!=e&&"function"!=typeof e.toString)try{t=!!(e+"")}catch(e){}return t}function z(e){var t=-1,r=Array(e.size);return e.forEach(function(e,n){r[++t]=[n,e]}),r}function G(e){var t=-1,r=Array(e.size);return e.forEach(function(e){r[++t]=e}),r}var Q,X,$,J=Array.prototype,Y=Function.prototype,K=Object.prototype,W=M["__core-js_shared__"],Z=(Q=/[^.]+$/.exec(W&&W.keys&&W.keys.IE_PROTO||""))?"Symbol(src)_1."+Q:"",ee=Y.toString,te=K.hasOwnProperty,re=K.toString,ne=RegExp("^"+ee.call(te).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),ie=M.Symbol,ae=M.Uint8Array,oe=K.propertyIsEnumerable,se=J.splice,ce=(X=Object.keys,$=Object,function(e){return X($(e))}),ue=Ue(M,"DataView"),le=Ue(M,"Map"),fe=Ue(M,"Promise"),de=Ue(M,"Set"),he=Ue(M,"WeakMap"),pe=Ue(Object,"create"),ye=Je(ue),me=Je(le),ge=Je(fe),be=Je(de),ve=Je(he),_e=ie?ie.prototype:void 0,we=_e?_e.valueOf:void 0,Se=_e?_e.toString:void 0;function Ee(e){var t=-1,r=e?e.length:0;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}function xe(e){var t=-1,r=e?e.length:0;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}function Te(e){var t=-1,r=e?e.length:0;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}function Oe(e){var t=-1,r=e?e.length:0;for(this.__data__=new Te;++t<r;)this.add(e[t])}function Ae(e){this.__data__=new xe(e)}function Ie(e,t){var r=Ze(e)||We(e)?function(e,t){for(var r=-1,n=Array(e);++r<e;)n[r]=t(r);return n}(e.length,String):[],n=r.length,i=!!n;for(var a in e)!t&&!te.call(e,a)||i&&("length"==a||He(a,n))||r.push(a);return r}function Ne(e,t){for(var r=e.length;r--;)if(Ke(e[r][0],t))return r;return-1}Ee.prototype.clear=function(){this.__data__=pe?pe(null):{}},Ee.prototype.delete=function(e){return this.has(e)&&delete this.__data__[e]},Ee.prototype.get=function(e){var t=this.__data__;if(pe){var r=t[e];return r===a?void 0:r}return te.call(t,e)?t[e]:void 0},Ee.prototype.has=function(e){var t=this.__data__;return pe?void 0!==t[e]:te.call(t,e)},Ee.prototype.set=function(e,t){return this.__data__[e]=pe&&void 0===t?a:t,this},xe.prototype.clear=function(){this.__data__=[]},xe.prototype.delete=function(e){var t=this.__data__,r=Ne(t,e);return!(r<0)&&(r==t.length-1?t.pop():se.call(t,r,1),!0)},xe.prototype.get=function(e){var t=this.__data__,r=Ne(t,e);return r<0?void 0:t[r][1]},xe.prototype.has=function(e){return Ne(this.__data__,e)>-1},xe.prototype.set=function(e,t){var r=this.__data__,n=Ne(r,e);return n<0?r.push([e,t]):r[n][1]=t,this},Te.prototype.clear=function(){this.__data__={hash:new Ee,map:new(le||xe),string:new Ee}},Te.prototype.delete=function(e){return Be(this,e).delete(e)},Te.prototype.get=function(e){return Be(this,e).get(e)},Te.prototype.has=function(e){return Be(this,e).has(e)},Te.prototype.set=function(e,t){return Be(this,e).set(e,t),this},Oe.prototype.add=Oe.prototype.push=function(e){return this.__data__.set(e,a),this},Oe.prototype.has=function(e){return this.__data__.has(e)},Ae.prototype.clear=function(){this.__data__=new xe},Ae.prototype.delete=function(e){return this.__data__.delete(e)},Ae.prototype.get=function(e){return this.__data__.get(e)},Ae.prototype.has=function(e){return this.__data__.has(e)},Ae.prototype.set=function(e,t){var r=this.__data__;if(r instanceof xe){var i=r.__data__;if(!le||i.length<n-1)return i.push([e,t]),this;r=this.__data__=new Te(i)}return r.set(e,t),this};var Re,ke=function(e,t,r){for(var n=-1,i=Object(e),a=r(e),o=a.length;o--;){var s=a[Re?o:++n];if(!1===t(i[s],s,i))break}return e};function Pe(e,t){for(var r=0,n=(t=ze(t,e)?[t]:qe(t)).length;null!=e&&r<n;)e=e[$e(t[r++])];return r&&r==n?e:void 0}function je(e,t){return null!=e&&t in Object(e)}function De(e,t,r,n,i){return e===t||(null==e||null==t||!nt(e)&&!it(t)?e!=e&&t!=t:function(e,t,r,n,i,a){var c=Ze(e),u=Ze(t),y=f,m=f;c||(y=(y=Ve(e))==l?v:y);u||(m=(m=Ve(t))==l?v:m);var O=y==v&&!H(e),A=m==v&&!H(t),I=y==m;if(I&&!O)return a||(a=new Ae),c||ot(e)?Fe(e,t,r,n,i,a):function(e,t,r,n,i,a,c){switch(r){case T:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case x:return!(e.byteLength!=t.byteLength||!n(new ae(e),new ae(t)));case d:case h:case b:return Ke(+e,+t);case p:return e.name==t.name&&e.message==t.message;case _:case S:return e==t+"";case g:var u=z;case w:var l=a&s;if(u||(u=G),e.size!=t.size&&!l)return!1;var f=c.get(e);if(f)return f==t;a|=o,c.set(e,t);var y=Fe(u(e),u(t),n,i,a,c);return c.delete(e),y;case E:if(we)return we.call(e)==we.call(t)}return!1}(e,t,y,r,n,i,a);if(!(i&s)){var N=O&&te.call(e,"__wrapped__"),R=A&&te.call(t,"__wrapped__");if(N||R){var k=N?e.value():e,P=R?t.value():t;return a||(a=new Ae),r(k,P,n,i,a)}}if(!I)return!1;return a||(a=new Ae),function(e,t,r,n,i,a){var o=i&s,c=st(e),u=c.length,l=st(t).length;if(u!=l&&!o)return!1;var f=u;for(;f--;){var d=c[f];if(!(o?d in t:te.call(t,d)))return!1}var h=a.get(e);if(h&&a.get(t))return h==t;var p=!0;a.set(e,t),a.set(t,e);var y=o;for(;++f<u;){d=c[f];var m=e[d],g=t[d];if(n)var b=o?n(g,m,d,t,e,a):n(m,g,d,e,t,a);if(!(void 0===b?m===g||r(m,g,n,i,a):b)){p=!1;break}y||(y="constructor"==d)}if(p&&!y){var v=e.constructor,_=t.constructor;v!=_&&"constructor"in e&&"constructor"in t&&!("function"==typeof v&&v instanceof v&&"function"==typeof _&&_ instanceof _)&&(p=!1)}return a.delete(e),a.delete(t),p}(e,t,r,n,i,a)}(e,t,De,r,n,i))}function Ce(e){return!(!nt(e)||function(e){return!!Z&&Z in e}(e))&&(tt(e)||H(e)?ne:k).test(Je(e))}function Me(e){return"function"==typeof e?e:null==e?ct:"object"==typeof e?Ze(e)?function(e,t){if(ze(e)&&Ge(t))return Qe($e(e),t);return function(r){var n=function(e,t,r){var n=null==e?void 0:Pe(e,t);return void 0===n?r:n}(r,e);return void 0===n&&n===t?function(e,t){return null!=e&&function(e,t,r){t=ze(t,e)?[t]:qe(t);var n,i=-1,a=t.length;for(;++i<a;){var o=$e(t[i]);if(!(n=null!=e&&r(e,o)))break;e=e[o]}if(n)return n;return!!(a=e?e.length:0)&&rt(a)&&He(o,a)&&(Ze(e)||We(e))}(e,t,je)}(r,e):De(t,n,void 0,o|s)}}(e[0],e[1]):function(e){var t=function(e){var t=st(e),r=t.length;for(;r--;){var n=t[r],i=e[n];t[r]=[n,i,Ge(i)]}return t}(e);if(1==t.length&&t[0][2])return Qe(t[0][0],t[0][1]);return function(r){return r===e||function(e,t,r,n){var i=r.length,a=i,c=!n;if(null==e)return!a;for(e=Object(e);i--;){var u=r[i];if(c&&u[2]?u[1]!==e[u[0]]:!(u[0]in e))return!1}for(;++i<a;){var l=(u=r[i])[0],f=e[l],d=u[1];if(c&&u[2]){if(void 0===f&&!(l in e))return!1}else{var h=new Ae;if(n)var p=n(f,d,l,e,t,h);if(!(void 0===p?De(d,f,n,o|s,h):p))return!1}}return!0}(r,e,t)}}(e):ze(t=e)?(r=$e(t),function(e){return null==e?void 0:e[r]}):function(e){return function(t){return Pe(t,e)}}(t);var t,r}function Le(e){if(r=(t=e)&&t.constructor,n="function"==typeof r&&r.prototype||K,t!==n)return ce(e);var t,r,n,i=[];for(var a in Object(e))te.call(e,a)&&"constructor"!=a&&i.push(a);return i}function qe(e){return Ze(e)?e:Xe(e)}function Fe(e,t,r,n,i,a){var c=i&s,u=e.length,l=t.length;if(u!=l&&!(c&&l>u))return!1;var f=a.get(e);if(f&&a.get(t))return f==t;var d=-1,h=!0,p=i&o?new Oe:void 0;for(a.set(e,t),a.set(t,e);++d<u;){var y=e[d],m=t[d];if(n)var g=c?n(m,y,d,t,e,a):n(y,m,d,e,t,a);if(void 0!==g){if(g)continue;h=!1;break}if(p){if(!V(t,function(e,t){if(!p.has(t)&&(y===e||r(y,e,n,i,a)))return p.add(t)})){h=!1;break}}else if(y!==m&&!r(y,m,n,i,a)){h=!1;break}}return a.delete(e),a.delete(t),h}function Be(e,t){var r,n,i=e.__data__;return("string"==(n=typeof(r=t))||"number"==n||"symbol"==n||"boolean"==n?"__proto__"!==r:null===r)?i["string"==typeof t?"string":"hash"]:i.map}function Ue(e,t){var r=function(e,t){return null==e?void 0:e[t]}(e,t);return Ce(r)?r:void 0}var Ve=function(e){return re.call(e)};function He(e,t){return!!(t=null==t?u:t)&&("number"==typeof e||P.test(e))&&e>-1&&e%1==0&&e<t}function ze(e,t){if(Ze(e))return!1;var r=typeof e;return!("number"!=r&&"symbol"!=r&&"boolean"!=r&&null!=e&&!at(e))||(A.test(e)||!O.test(e)||null!=t&&e in Object(t))}function Ge(e){return e==e&&!nt(e)}function Qe(e,t){return function(r){return null!=r&&(r[e]===t&&(void 0!==t||e in Object(r)))}}(ue&&Ve(new ue(new ArrayBuffer(1)))!=T||le&&Ve(new le)!=g||fe&&"[object Promise]"!=Ve(fe.resolve())||de&&Ve(new de)!=w||he&&"[object WeakMap]"!=Ve(new he))&&(Ve=function(e){var t=re.call(e),r=t==v?e.constructor:void 0,n=r?Je(r):void 0;if(n)switch(n){case ye:return T;case me:return g;case ge:return"[object Promise]";case be:return w;case ve:return"[object WeakMap]"}return t});var Xe=Ye(function(e){var t;e=null==(t=e)?"":function(e){if("string"==typeof e)return e;if(at(e))return Se?Se.call(e):"";var t=e+"";return"0"==t&&1/e==-c?"-0":t}(t);var r=[];return I.test(e)&&r.push(""),e.replace(N,function(e,t,n,i){r.push(n?i.replace(R,"$1"):t||e)}),r});function $e(e){if("string"==typeof e||at(e))return e;var t=e+"";return"0"==t&&1/e==-c?"-0":t}function Je(e){if(null!=e){try{return ee.call(e)}catch(e){}try{return e+""}catch(e){}}return""}function Ye(e,t){if("function"!=typeof e||t&&"function"!=typeof t)throw new TypeError(i);var r=function(){var n=arguments,i=t?t.apply(this,n):n[0],a=r.cache;if(a.has(i))return a.get(i);var o=e.apply(this,n);return r.cache=a.set(i,o),o};return r.cache=new(Ye.Cache||Te),r}function Ke(e,t){return e===t||e!=e&&t!=t}function We(e){return function(e){return it(e)&&et(e)}(e)&&te.call(e,"callee")&&(!oe.call(e,"callee")||re.call(e)==l)}Ye.Cache=Te;var Ze=Array.isArray;function et(e){return null!=e&&rt(e.length)&&!tt(e)}function tt(e){var t=nt(e)?re.call(e):"";return t==y||t==m}function rt(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=u}function nt(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}function it(e){return!!e&&"object"==typeof e}function at(e){return"symbol"==typeof e||it(e)&&re.call(e)==E}var ot=U?function(e){return function(t){return e(t)}}(U):function(e){return it(e)&&rt(e.length)&&!!j[re.call(e)]};function st(e){return et(e)?Ie(e):Le(e)}function ct(e){return e}r.exports=function(e,t){var r={};return t=Me(t),function(e,t){e&&ke(e,t,st)}(e,function(e,n,i){r[n]=t(e,n,i)}),r}}).call(this,r(9),r(40)(e))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(39);t.ActorRdfParseFixedMediaTypes=class extends n.ActorAbstractMediaTypedFixed{constructor(e){super(e)}async testHandleChecked(e){return!0}}},function(e,t,r){var n=r(53),i=r(3).Readable,a=n.internal.toId,o=n.internal.fromId;function s(e){return"string"==typeof e||e instanceof String}e.exports=class{constructor(e,t){this._size=0,this._graphs=Object.create(null),this._id=0,this._ids=Object.create(null),this._ids["><"]=0,this._entities=Object.create(null),this._blankNodeIndex=0,t||!e||e[0]||(t=e,e=null),t=t||{},this._factory=t.factory||n,e&&this.addQuads(e)}get size(){var e=this._size;if(null!==e)return e;e=0;var t,r,n=this._graphs;for(var i in n)for(var a in t=n[i].subjects)for(var o in r=t[a])e+=Object.keys(r[o]).length;return this._size=e}_addToIndex(e,t,r,n){var i=e[t]||(e[t]={}),a=i[r]||(i[r]={}),o=n in a;return o||(a[n]=null),!o}_removeFromIndex(e,t,r,n){var i,a=e[t],o=a[r];for(i in delete o[n],o)return;for(i in delete a[r],a)return;delete e[t]}_findInIndex(e,t,r,n,i,a,s,c,u,l){var f,d,h,p=!t+!r+!n>1?Object.keys(this._ids):this._entities;for(var y in t&&((f=e,e={})[t]=f[t]),e){var m=p[y];if(d=e[y])for(var g in r&&((f=d,d={})[r]=f[r]),d){var b=p[g];if(h=d[g])for(var v=(n?n in h?[n]:[]:Object.keys(h)),_=0;_<v.length;_++){var w={subject:null,predicate:null,object:null};w[i]=o(m,this._factory),w[a]=o(b,this._factory),w[s]=o(p[v[_]],this._factory);var S=this._factory.quad(w.subject,w.predicate,w.object,o(c,this._factory));if(l)l.push(S);else if(u(S))return!0}}}return l}_loop(e,t){for(var r in e)t(r)}_loopByKey0(e,t,r){var n,i;if(n=e[t])for(i in n)r(i)}_loopByKey1(e,t,r){var n;for(n in e)e[n][t]&&r(n)}_loopBy2Keys(e,t,r,n){var i,a,o;if((i=e[t])&&(a=i[r]))for(o in a)n(o)}_countInIndex(e,t,r,n){var i,a,o,s=0;for(var c in t&&((i=e,e={})[t]=i[t]),e)if(a=e[c])for(var u in r&&((i=a,a={})[r]=i[r]),a)(o=a[u])&&(n?n in o&&s++:s+=Object.keys(o).length);return s}_getGraphs(e){if(!s(e))return this._graphs;var t={};return t[e]=this._graphs[e],t}_uniqueEntities(e){var t=Object.create(null),r=this._entities;return function(n){n in t||(t[n]=!0,e(o(r[n])))}}addQuad(e,t,r,n){t||(n=e.graph,r=e.object,t=e.predicate,e=e.subject),e=a(e),t=a(t),r=a(r),n=a(n);var i=this._graphs[n];i||(i=this._graphs[n]={subjects:{},predicates:{},objects:{}},Object.freeze(i));var o=this._ids,s=this._entities;e=o[e]||(o[s[++this._id]=e]=this._id),t=o[t]||(o[s[++this._id]=t]=this._id),r=o[r]||(o[s[++this._id]=r]=this._id);var c=this._addToIndex(i.subjects,e,t,r);return this._addToIndex(i.predicates,t,r,e),this._addToIndex(i.objects,r,e,t),this._size=null,c}addQuads(e){for(var t=0;t<e.length;t++)this.addQuad(e[t])}import(e){var t=this;return e.on("data",function(e){t.addQuad(e)}),e}removeQuad(e,t,r,n){t||(n=e.graph,r=e.object,t=e.predicate,e=e.subject),e=a(e),t=a(t),r=a(r),n=a(n);var i,o,s,c=this._ids,u=this._graphs;if(!((e=c[e])&&(t=c[t])&&(r=c[r])&&(i=u[n])&&(o=i.subjects[e])&&(s=o[t])&&r in s))return!1;for(e in this._removeFromIndex(i.subjects,e,t,r),this._removeFromIndex(i.predicates,t,r,e),this._removeFromIndex(i.objects,r,e,t),null!==this._size&&this._size--,i.subjects)return!0;return delete u[n],!0}removeQuads(e){for(var t=0;t<e.length;t++)this.removeQuad(e[t])}remove(e){var t=this;return e.on("data",function(e){t.removeQuad(e)}),e}removeMatches(e,t,r,n){return this.remove(this.match(e,t,r,n))}deleteGraph(e){return this.removeMatches(null,null,null,e)}getQuads(e,t,r,n){e=e&&a(e),t=t&&a(t),r=r&&a(r),n=n&&a(n);var i,o,c,u,l=[],f=this._getGraphs(n),d=this._ids;if(s(e)&&!(o=d[e])||s(t)&&!(c=d[t])||s(r)&&!(u=d[r]))return l;for(var h in f)(i=f[h])&&(o?u?this._findInIndex(i.objects,u,o,c,"object","subject","predicate",h,null,l):this._findInIndex(i.subjects,o,c,null,"subject","predicate","object",h,null,l):c?this._findInIndex(i.predicates,c,u,null,"predicate","object","subject",h,null,l):u?this._findInIndex(i.objects,u,null,null,"object","subject","predicate",h,null,l):this._findInIndex(i.subjects,null,null,null,"subject","predicate","object",h,null,l));return l}match(e,t,r,n){var a=this,o=new i({objectMode:!0});return o._read=function(){o._read=function(){};var i=a.getQuads(e,t,r,n);for(var s of i)o.push(s);o.push(null)},o}countQuads(e,t,r,n){e=e&&a(e),t=t&&a(t),r=r&&a(r),n=n&&a(n);var i,o,c,u,l=0,f=this._getGraphs(n),d=this._ids;if(s(e)&&!(o=d[e])||s(t)&&!(c=d[t])||s(r)&&!(u=d[r]))return 0;for(var h in f)(i=f[h])&&(l+=e?r?this._countInIndex(i.objects,u,o,c):this._countInIndex(i.subjects,o,c,u):t?this._countInIndex(i.predicates,c,u,o):this._countInIndex(i.objects,u,o,c));return l}forEach(e,t,r,n,i){this.some(function(t){return e(t),!1},t,r,n,i)}every(e,t,r,n,i){var a=!1,o=!this.some(function(t){return a=!0,!e(t)},t,r,n,i);return a&&o}some(e,t,r,n,i){t=t&&a(t),r=r&&a(r),n=n&&a(n),i=i&&a(i);var o,c,u,l,f=this._getGraphs(i),d=this._ids;if(s(t)&&!(c=d[t])||s(r)&&!(u=d[r])||s(n)&&!(l=d[n]))return!1;for(var h in f)if(o=f[h])if(c){if(l){if(this._findInIndex(o.objects,l,c,u,"object","subject","predicate",h,e,null))return!0}else if(this._findInIndex(o.subjects,c,u,null,"subject","predicate","object",h,e,null))return!0}else if(u){if(this._findInIndex(o.predicates,u,l,null,"predicate","object","subject",h,e,null))return!0}else if(l){if(this._findInIndex(o.objects,l,null,null,"object","subject","predicate",h,e,null))return!0}else if(this._findInIndex(o.subjects,null,null,null,"subject","predicate","object",h,e,null))return!0;return!1}getSubjects(e,t,r){var n=[];return this.forSubjects(function(e){n.push(e)},e,t,r),n}forSubjects(e,t,r,n){t=t&&a(t),r=r&&a(r),n=n&&a(n);var i,o,c,u=this._ids,l=this._getGraphs(n);if(e=this._uniqueEntities(e),!(s(t)&&!(o=u[t])||s(r)&&!(c=u[r])))for(n in l)(i=l[n])&&(o?c?this._loopBy2Keys(i.predicates,o,c,e):this._loopByKey1(i.subjects,o,e):c?this._loopByKey0(i.objects,c,e):this._loop(i.subjects,e))}getPredicates(e,t,r){var n=[];return this.forPredicates(function(e){n.push(e)},e,t,r),n}forPredicates(e,t,r,n){t=t&&a(t),r=r&&a(r),n=n&&a(n);var i,o,c,u=this._ids,l=this._getGraphs(n);if(e=this._uniqueEntities(e),!(s(t)&&!(o=u[t])||s(r)&&!(c=u[r])))for(n in l)(i=l[n])&&(o?c?this._loopBy2Keys(i.objects,c,o,e):this._loopByKey0(i.subjects,o,e):c?this._loopByKey1(i.predicates,c,e):this._loop(i.predicates,e))}getObjects(e,t,r){var n=[];return this.forObjects(function(e){n.push(e)},e,t,r),n}forObjects(e,t,r,n){t=t&&a(t),r=r&&a(r),n=n&&a(n);var i,o,c,u=this._ids,l=this._getGraphs(n);if(e=this._uniqueEntities(e),!(s(t)&&!(o=u[t])||s(r)&&!(c=u[r])))for(n in l)(i=l[n])&&(o?c?this._loopBy2Keys(i.subjects,o,c,e):this._loopByKey1(i.objects,o,e):c?this._loopByKey0(i.predicates,c,e):this._loop(i.objects,e))}getGraphs(e,t,r){var n=[];return this.forGraphs(function(e){n.push(e)},e,t,r),n}forGraphs(e,t,r,n){for(var i in this._graphs)this.some(function(t){return e(t.graph),!0},t,r,n,i)}createBlankNode(e){var t,r;if(e)for(t=e="_:"+e,r=1;this._ids[t];)t=e+r++;else do{t="_:b"+this._blankNodeIndex++}while(this._ids[t]);return this._ids[t]=++this._id,this._entities[this._id]=t,this._factory.blankNode(t.substr(2))}}},function(e,t,r){var n=r(3).Transform,i=r(154);e.exports=class extends n{constructor(e){super({decodeStrings:!0}),this._readableState.objectMode=!0;var t,r,n=this;new i(e).parse({on:function(e,n){switch(e){case"data":t=n;break;case"end":r=n}}},function(e,t){e&&n.emit("error",e)||t&&n.push(t)},function(e,t){n.emit("prefix",e,t)}),this._transform=function(e,r,n){t(e),n()},this._flush=function(e){r(),e()}}import(e){var t=this;return e.on("data",function(e){t.write(e)}),e.on("end",function(){t.end()}),e.on("error",function(e){t.emit("error",e)}),this}}},function(e,t,r){var n=r(3).Transform,i=r(155);e.exports=class extends n{constructor(e){super({encoding:"utf8"}),this._writableState.objectMode=!0;var t=this,r=this._writer=new i({write:function(e,r,n){t.push(e),n&&n()},end:function(e){t.push(null),e&&e()}},e);this._transform=function(e,t,n){r.addQuad(e,n)},this._flush=function(e){r.end(e)}}import(e){var t=this;return e.on("data",function(e){t.write(e)}),e.on("end",function(){t.end()}),e.on("error",function(e){t.emit("error",e)}),e.on("prefix",function(e,r){t._writer.addPrefix(e,r)}),this}}},function(e,t,r){var n=r(53),i={isNamedNode:function(e){return!!e&&"NamedNode"===e.termType},isBlankNode:function(e){return!!e&&"BlankNode"===e.termType},isLiteral:function(e){return!!e&&"Literal"===e.termType},isVariable:function(e){return!!e&&"Variable"===e.termType},isDefaultGraph:function(e){return!!e&&"DefaultGraph"===e.termType},inDefaultGraph:function(e){return i.isDefaultGraph(e.graph)},prefix:function(e,t){return i.prefixes({"":e},t)("")},prefixes:function(e,t){var r=Object.create(null);for(var i in e)a(i,e[i]);function a(e,n){if("string"==typeof n){var i=Object.create(null);r[e]=function(e){return i[e]||(i[e]=t.namedNode(n+e))}}else if(!(e in r))throw new Error("Unknown prefix: "+e);return r[e]}return t=t||n,a}};e.exports=i},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(52),i=r(364);t.ActorRdfParseJsonLd=class extends n.ActorRdfParseFixedMediaTypes{constructor(e){super(e)}async runHandle(e,t,r){return{quads:new i.JsonLdParser({baseIRI:e.baseIRI,allowOutOfOrderContext:!0}).import(e.input)}}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(157))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(41);t.EntryHandlerArrayValue=class{isPropertyHandler(){return!1}async validate(e,t,r,n,i){return this.test(e,t,null,r,n)}async test(e,t,r,n,i){return"number"==typeof n[i]}async handle(e,t,r,i,a,o){const s=await t.unaliasKeywordParent(i,o);if("@list"===s){let r,s=null;for(let e=o-2;e>0;e--){const t=i[e];if("string"==typeof t){r=e,s=t;break}}if("@list"===s||r!==o-2&&"number"==typeof i[o-2]&&"@list"===n.Util.getContextValueContainer(await e.getContext(i,r-o),s))throw new Error(`Lists of lists are not supported: '${s}'`);const c=await t.valueToTerm(await e.getContext(i),s,a,o,i);null!==s&&await this.handleListElement(e,t,c,o,i.slice(0,r),r,s,i)}else if("@set"===s)await e.newOnValueJob(i.slice(0,-2),a,o-2);else if(void 0!==s&&"@type"!==s){const r=await e.getContext(i.slice(0,-1));if("@list"===n.Util.getContextValueContainer(r,s)){const r=await t.valueToTerm(await e.getContext(i),s,a,o,i);await this.handleListElement(e,t,r,o,i.slice(0,-1),o-1,s,i)}else e.idStack[o+1]&&(e.idStack[o]=e.idStack[o+1],e.emittedStack[o]=!0),await e.newOnValueJob(i.slice(0,-1),a,o-1)}}async handleListElement(e,t,r,i,a,o,s,c){let u=e.listPointerStack[i];if(r){if(u&&u.term){const r=t.dataFactory.blankNode();e.emitQuad(i,t.dataFactory.quad(u.term,t.rdfRest,r,t.getDefaultGraph())),u.term=r}else{const r=t.dataFactory.blankNode(),i=await e.getContext(a),l=await t.predicateToTerm(i,s),f=n.Util.isPropertyReverse(i,s,c[o-1]);if(f&&!e.allowSubjectList)throw new Error(`Found illegal list value in subject position at ${s}`);e.getUnidentifiedValueBufferSafe(o).push({predicate:l,object:r,reverse:f}),u={term:r,initialPredicate:null,listRootDepth:o}}e.emitQuad(i,t.dataFactory.quad(u.term,t.rdfFirst,r,t.getDefaultGraph()))}else if(!u){u={term:null,initialPredicate:await t.predicateToTerm(await e.getContext(a),s),listRootDepth:o}}e.listPointerStack[i]=u}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(367),i=r(368),a=r(41);class o{isPropertyHandler(){return!1}async validate(e,t,r,n,i){return!!await this.test(e,t,null,r,n)}async test(e,t,r,n,i){return o.CONTAINER_HANDLERS[a.Util.getContextValueContainer(await e.getContext(n),n[i-1])]}async handle(e,t,r,n,i,a,o){return e.emittedStack[a]=!1,o.handle(e,n,i,a)}}o.CONTAINER_HANDLERS={"@index":new n.ContainerHandlerIndex,"@language":new i.ContainerHandlerLanguage},t.EntryHandlerContainer=o},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});t.ContainerHandlerIndex=class{async handle(e,t,r,n){await e.newOnValueJob(t,r,n-1)}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});t.ContainerHandlerLanguage=class{async handle(e,t,r,n){r=Array.isArray(r)?r.map(e=>({"@value":e,"@language":t[n]})):{"@value":r,"@language":t[n]},await e.newOnValueJob(t,r,n-1)}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});t.EntryHandlerInvalidFallback=class{isPropertyHandler(){return!1}async validate(e,t,r,n,i){return!1}async test(e,t,r,n,i){return!0}async handle(e,t,r,n,i,a){e.emittedStack[a]=!1}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(54);t.EntryHandlerKeywordContext=class extends n.EntryHandlerKeyword{constructor(){super("@context")}async handle(e,t,r,n,i,a){!e.allowOutOfOrderContext&&e.processingStack[a]&&e.emitError(new Error("Found an out-of-order context, while support is not enabled.(enable with `allowOutOfOrderContext`)"));const o=e.getContext(n.slice(0,-1)),s=e.contextParser.parse(i,{baseIri:e.baseIRI,parentContext:await o});e.contextTree.setContext(n.slice(0,-1),s),e.emitContext(i),await e.validateContext(await s)}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(54);t.EntryHandlerKeywordGraph=class extends n.EntryHandlerKeyword{constructor(){super("@graph")}async handle(e,t,r,n,i,a){e.graphStack[a+1]=!0}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(54);t.EntryHandlerKeywordId=class extends n.EntryHandlerKeyword{constructor(){super("@id")}async handle(e,t,r,n,i,a){void 0!==e.idStack[a]&&e.emitError(new Error(`Found duplicate @ids '${e.idStack[a].value}' and '${i}'`)),e.idStack[a]=await t.resourceToTerm(await e.getContext(n),i)}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(41),i=r(54),a=r(159);t.EntryHandlerKeywordType=class extends i.EntryHandlerKeyword{constructor(){super("@type")}async handle(e,t,r,i,o,s){const c=i[s],u=await t.unaliasKeywordParent(i,s),l=await e.getContext(i),f=t.rdfType,d=n.Util.isPropertyReverse(l,c,u);if(Array.isArray(o))for(const r of o){const n=t.createVocabOrBaseTerm(l,r);n&&await a.EntryHandlerPredicate.handlePredicateObject(e,t,i,s,u,f,n,d)}else{const r=t.createVocabOrBaseTerm(l,o);r&&await a.EntryHandlerPredicate.handlePredicateObject(e,t,i,s,u,f,r,d)}}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(41);class i{isPropertyHandler(){return!1}async validate(e,t,r,i,a){const o=await t.unaliasKeyword(r[i],r,i);return!!n.Util.isKeyword(o)&&!(!a&&"@list"===o)}async test(e,t,r,i,a){return n.Util.isKeyword(r)}async handle(e,t,r,n,a,o){const s=i.VALID_KEYWORDS_TYPES[r];void 0!==s?s&&typeof a!==s&&e.emitError(new Error(`Invalid value type for '${r}' with value '${a}'`)):e.errorOnInvalidProperties&&e.emitError(new Error(`Unknown keyword '${r}' with value '${a}'`)),e.emittedStack[o]=!1}}i.VALID_KEYWORDS_TYPES={"@index":"string","@list":null,"@reverse":"object","@set":null,"@value":null},t.EntryHandlerKeywordUnknownFallback=i},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(54);t.EntryHandlerKeywordValue=class extends n.EntryHandlerKeyword{constructor(){super("@value")}async handle(e,t,r,n,i,a){e.literalStack[a]=!0,delete e.unidentifiedValuesBuffer[a],delete e.unidentifiedGraphsBuffer[a],e.emittedStack[a]=!1}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(23),i=r(377),a=r(157);t.ParsingContext=class{constructor(e){this.contextParser=new n.ContextParser({documentLoader:e.documentLoader}),this.allowOutOfOrderContext=e.allowOutOfOrderContext,this.baseIRI=e.baseIRI,this.produceGeneralizedRdf=e.produceGeneralizedRdf,this.allowSubjectList=e.allowSubjectList,this.processingMode=e.processingMode||a.JsonLdParser.DEFAULT_PROCESSING_MODE,this.errorOnInvalidProperties=e.errorOnInvalidIris,this.validateValueIndexes=e.validateValueIndexes,this.defaultGraph=e.defaultGraph,this.processingStack=[],this.emittedStack=[],this.idStack=[],this.graphStack=[],this.listPointerStack=[],this.contextTree=new i.ContextTree,this.literalStack=[],this.validationStack=[],this.unaliasedKeywordCacheStack=[],this.unidentifiedValuesBuffer=[],this.unidentifiedGraphsBuffer=[],this.parser=e.parser,e.context?(this.rootContext=this.contextParser.parse(e.context,{baseIri:e.baseIRI}),this.rootContext.then(e=>this.validateContext(e))):this.rootContext=Promise.resolve(this.baseIRI?{"@base":this.baseIRI}:{}),this.topLevelProperties=!1}validateContext(e){const t=e["@version"];if(t&&parseFloat(t)>parseFloat(this.processingMode))throw new Error(`Unsupported JSON-LD processing mode: ${t}`)}getContext(e,t=1){return t&&(e=e.slice(0,-t)),this.contextTree.getContext(e)||this.rootContext}async newOnValueJob(e,t,r){await this.parser.newOnValueJob(e,t,r)}emitQuad(e,t){1===e&&(this.topLevelProperties=!0),this.parser.push(t)}emitError(e){this.parser.emit("error",e)}emitContext(e){this.parser.emit("context",e)}getUnidentifiedValueBufferSafe(e){let t=this.unidentifiedValuesBuffer[e];return t||(t=[],this.unidentifiedValuesBuffer[e]=t),t}getUnidentifiedGraphBufferSafe(e){let t=this.unidentifiedGraphsBuffer[e];return t||(t=[],this.unidentifiedGraphsBuffer[e]=t),t}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});class n{constructor(){this.subTrees={}}getContext([e,...t]){if(e||t.length){const r=this.subTrees[e];return r&&r.getContext(t)||this.context}return this.context}setContext([e,...t],r){if(e||t.length){let i=this.subTrees[e];i||(i=this.subTrees[e]=new n),i.setContext(t,r)}else this.context=r}}t.ContextTree=n},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(52),i=r(379);t.ActorRdfParseRdfXml=class extends n.ActorRdfParseFixedMediaTypes{constructor(e){super(e)}async runHandle(e,t,r){e.input.on("error",e=>n.emit("error",e));const n=e.input.pipe(new i.RdfXmlParser({baseIRI:e.baseIRI}));return{quads:n,triples:!0}}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(380))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(65),i=r(161),a=r(3),o=r(381);class s extends a.Transform{constructor(e){super({objectMode:!0}),this.activeTagStack=[],this.nodeIds={},e&&(Object.assign(this,e),this.options=e),this.dataFactory||(this.dataFactory=r(5)),this.baseIRI||(this.baseIRI=""),this.defaultGraph||(this.defaultGraph=this.dataFactory.defaultGraph()),this.saxStream=i.createStream(this.strict,{xmlns:!1,position:this.trackPosition}),this.strict||(this.saxStream._parser.looseCase="toString"),this.attachSaxListeners()}static parseNamespace(e,t){const r={};let n=!1;for(const t in e.attributes)t.startsWith("xmlns")&&(5===t.length?(n=!0,r[""]=e.attributes[t]):":"===t.charAt(5)&&(n=!0,r[t.substr(6)]=e.attributes[t]));const i=t&&t.ns?t.ns:[s.DEFAULT_NS];return n?i.concat([r]):i}static expandPrefixedTerm(e,t,r){const n=e.indexOf(":");let i,a;n>=0?(i=e.substr(0,n),a=e.substr(n+1)):(i="",a=e);let s=null,c=null;for(let e=t.length-1;e>=0;e--){const r=t[e][i];if(r){s=r;break}c||(c=t[e][""])}if(!s){if(i&&"xmlns"!==i)throw new o.ParseError(r,`The prefix '${i}' in term '${e}' was not bound.`);s=c||""}return{prefix:i,local:a,uri:s}}static isValidIri(e){return s.IRI_REGEX.test(e)}import(e){const t=new a.PassThrough({objectMode:!0});e.on("error",e=>r.emit("error",e)),e.on("data",e=>t.write(e)),e.on("end",()=>t.emit("end"));const r=t.pipe(new s(this.options));return r}_transform(e,t,r){try{this.saxStream.write(e,t)}catch(e){return r(e)}r()}newParseError(e){return new o.ParseError(this,e)}valueToUri(e,t){return this.uriToNamedNode(n.resolve(e,t.baseIRI))}uriToNamedNode(e){if(!s.isValidIri(e))throw this.newParseError(`Invalid URI: ${e}`);return this.dataFactory.namedNode(e)}validateNcname(e){if(!s.NCNAME_MATCHER.test(e))throw this.newParseError(`Not a valid NCName: ${e}`)}attachSaxListeners(){this.saxStream.on("error",e=>this.emit("error",e)),this.saxStream.on("opentag",this.onTag.bind(this)),this.saxStream.on("text",this.onText.bind(this)),this.saxStream.on("closetag",this.onCloseTag.bind(this)),this.saxStream.on("doctype",this.onDoctype.bind(this))}onTag(e){const t=this.activeTagStack.length?this.activeTagStack[this.activeTagStack.length-1]:null;let r=c.RESOURCE;if(t&&(t.hadChildren=!0,r=t.childrenParseType),t&&t.childrenStringTags){const r=e.name;let n="";for(const t in e.attributes)n+=` ${t}="${e.attributes[t]}"`;const i=`<${`${r}${n}`}>`;t.childrenStringTags.push(i);const a={childrenStringTags:t.childrenStringTags};return a.childrenStringEmitClosingTag=`</${r}>`,void this.activeTagStack.push(a)}const n={};t?(n.language=t.language,n.baseIRI=t.baseIRI):n.baseIRI=this.baseIRI,this.activeTagStack.push(n),n.ns=s.parseNamespace(e,t),r===c.RESOURCE?this.onTagResource(e,n,t,!t):this.onTagProperty(e,n,t)}onTagResource(e,t,r,n){const i=s.expandPrefixedTerm(e.name,t.ns,this);t.childrenParseType=c.PROPERTY;let a=!0;if(i.uri===s.RDF){if(!n&&s.FORBIDDEN_NODE_ELEMENTS.indexOf(i.local)>=0)throw this.newParseError(`Illegal node element name: ${i.local}`);switch(i.local){case"RDF":t.childrenParseType=c.RESOURCE;case"Description":a=!1}}const o=[],u=[];let l=null,f=!1,d=!1,h=null;for(const n in e.attributes){const i=e.attributes[n],a=s.expandPrefixedTerm(n,t.ns,this);if(r&&a.uri===s.RDF)switch(a.local){case"about":if(l)throw this.newParseError(`Only one of rdf:about, rdf:nodeID and rdf:ID can be present, while ${i} and ${l} where found.`);l=i;continue;case"ID":if(l)throw this.newParseError(`Only one of rdf:about, rdf:nodeID and rdf:ID can be present, while ${i} and ${l} where found.`);this.validateNcname(i),l="#"+i,f=!0;continue;case"nodeID":if(l)throw this.newParseError(`Only one of rdf:about, rdf:nodeID and rdf:ID can be present, while ${i} and ${l} where found.`);this.validateNcname(i),l=i,d=!0;continue;case"bagID":throw this.newParseError("rdf:bagID is not supported.");case"type":h=i;continue;case"aboutEach":throw this.newParseError("rdf:aboutEach is not supported.");case"aboutEachPrefix":throw this.newParseError("rdf:aboutEachPrefix is not supported.");case"li":throw this.newParseError("rdf:li on node elements are not supported.")}else if(a.uri===s.XML){if("lang"===a.local){t.language=""===i?null:i.toLowerCase();continue}if("base"===a.local){t.baseIRI=i;continue}}"xml"!==a.prefix&&a.uri&&(o.push(this.uriToNamedNode(a.uri+a.local)),u.push(i))}if(null!==l&&(t.subject=d?this.dataFactory.blankNode(l):this.valueToUri(l,t),f&&this.claimNodeId(t.subject)),t.subject||(t.subject=this.dataFactory.blankNode()),a){const e=this.uriToNamedNode(i.uri+i.local);this.emitTriple(t.subject,this.dataFactory.namedNode(s.RDF+"type"),e,r?r.reifiedStatementId:null)}if(r){if(r.predicate)if(r.childrenCollectionSubject){const e=this.dataFactory.blankNode();this.emitTriple(r.childrenCollectionSubject,r.childrenCollectionPredicate,e,r.reifiedStatementId),this.emitTriple(e,this.dataFactory.namedNode(s.RDF+"first"),t.subject,t.reifiedStatementId),r.childrenCollectionSubject=e,r.childrenCollectionPredicate=this.dataFactory.namedNode(s.RDF+"rest")}else{this.emitTriple(r.subject,r.predicate,t.subject,r.reifiedStatementId);for(let e=0;e<r.predicateSubPredicates.length;e++)this.emitTriple(t.subject,r.predicateSubPredicates[e],r.predicateSubObjects[e],null);r.predicateSubPredicates=[],r.predicateSubObjects=[],r.predicateEmitted=!0}for(let e=0;e<o.length;e++){const n=this.dataFactory.literal(u[e],t.datatype||t.language);this.emitTriple(t.subject,o[e],n,r.reifiedStatementId)}h&&this.emitTriple(t.subject,this.dataFactory.namedNode(s.RDF+"type"),this.uriToNamedNode(h),null)}}onTagProperty(e,t,r){const n=s.expandPrefixedTerm(e.name,t.ns,this);if(t.childrenParseType=c.RESOURCE,t.subject=r.subject,n.uri===s.RDF&&"li"===n.local?(r.listItemCounter||(r.listItemCounter=1),t.predicate=this.uriToNamedNode(n.uri+"_"+r.listItemCounter++)):t.predicate=this.uriToNamedNode(n.uri+n.local),n.uri===s.RDF&&s.FORBIDDEN_PROPERTY_ELEMENTS.indexOf(n.local)>=0)throw this.newParseError(`Illegal property element name: ${n.local}`);t.predicateSubPredicates=[],t.predicateSubObjects=[];let i=!1,a=!1,o=null,u=!0;const l=[],f=[];for(const r in e.attributes){const n=e.attributes[r],d=s.expandPrefixedTerm(r,t.ns,this);if(d.uri===s.RDF)switch(d.local){case"resource":if(o)throw this.newParseError(`Found both rdf:resource (${n}) and rdf:nodeID (${o}).`);if(i)throw this.newParseError(`rdf:parseType is not allowed on property elements with rdf:resource (${n})`);t.hadChildren=!0,o=n,u=!1;continue;case"datatype":if(a)throw this.newParseError(`Found both non-rdf:* property attributes and rdf:datatype (${n}).`);if(i)throw this.newParseError(`rdf:parseType is not allowed on property elements with rdf:datatype (${n})`);t.datatype=this.valueToUri(n,t);continue;case"nodeID":if(a)throw this.newParseError(`Found both non-rdf:* property attributes and rdf:nodeID (${n}).`);if(t.hadChildren)throw this.newParseError(`Found both rdf:resource and rdf:nodeID (${n}).`);if(i)throw this.newParseError(`rdf:parseType is not allowed on property elements with rdf:nodeID (${n})`);this.validateNcname(n),t.hadChildren=!0,o=n,u=!0;continue;case"bagID":throw this.newParseError("rdf:bagID is not supported.");case"parseType":if(a)throw this.newParseError("rdf:parseType is not allowed when non-rdf:* property attributes are present");if(t.datatype)throw this.newParseError(`rdf:parseType is not allowed on property elements with rdf:datatype (${t.datatype.value})`);if(o)throw this.newParseError(`rdf:parseType is not allowed on property elements with rdf:nodeID or rdf:resource (${o})`);if("Resource"===n){i=!0,t.childrenParseType=c.PROPERTY;const e=this.dataFactory.blankNode();this.emitTriple(t.subject,t.predicate,e,t.reifiedStatementId),t.subject=e,t.predicate=null}else"Collection"===n?(i=!0,t.hadChildren=!0,t.childrenCollectionSubject=t.subject,t.childrenCollectionPredicate=t.predicate,u=!1):"Literal"===n&&(i=!0,t.childrenTagsToString=!0,t.childrenStringTags=[]);continue;case"ID":this.validateNcname(n),t.reifiedStatementId=this.valueToUri("#"+n,t),this.claimNodeId(t.reifiedStatementId);continue}else if(d.uri===s.XML&&"lang"===d.local){t.language=""===n?null:n.toLowerCase();continue}if("xml"!==d.prefix&&d.uri){if(i||t.datatype)throw this.newParseError(`Found illegal rdf:* properties on property element with attribute: ${n}`);t.hadChildren=!0,a=!0,l.push(this.uriToNamedNode(d.uri+d.local)),f.push(this.dataFactory.literal(n,t.datatype||t.language))}}if(null!==o){const e=t.subject;t.subject=u?this.dataFactory.blankNode(o):this.valueToUri(o,t),this.emitTriple(e,t.predicate,t.subject,t.reifiedStatementId);for(let e=0;e<l.length;e++)this.emitTriple(t.subject,l[e],f[e],null);t.predicateEmitted=!0}else u&&(t.predicateSubPredicates=l,t.predicateSubObjects=f,t.predicateEmitted=!1)}emitTriple(e,t,r,n){this.push(this.dataFactory.quad(e,t,r,this.defaultGraph)),n&&(this.push(this.dataFactory.quad(n,this.dataFactory.namedNode(s.RDF+"type"),this.dataFactory.namedNode(s.RDF+"Statement"),this.defaultGraph)),this.push(this.dataFactory.quad(n,this.dataFactory.namedNode(s.RDF+"subject"),e,this.defaultGraph)),this.push(this.dataFactory.quad(n,this.dataFactory.namedNode(s.RDF+"predicate"),t,this.defaultGraph)),this.push(this.dataFactory.quad(n,this.dataFactory.namedNode(s.RDF+"object"),r,this.defaultGraph)))}claimNodeId(e){if(!this.allowDuplicateRdfIds){if(this.nodeIds[e.value])throw this.newParseError(`Found multiple occurrences of rdf:ID='${e.value}'.`);this.nodeIds[e.value]=!0}}onText(e){const t=this.activeTagStack.length?this.activeTagStack[this.activeTagStack.length-1]:null;t&&(t.childrenStringTags?t.childrenStringTags.push(e):t.predicate&&(t.text=e))}onCloseTag(){const e=this.activeTagStack.pop();if(e.childrenStringEmitClosingTag&&e.childrenStringTags.push(e.childrenStringEmitClosingTag),e.childrenTagsToString&&(e.datatype=this.dataFactory.namedNode(s.RDF+"XMLLiteral"),e.text=e.childrenStringTags.join(""),e.hadChildren=!1),e.childrenCollectionSubject)this.emitTriple(e.childrenCollectionSubject,e.childrenCollectionPredicate,this.dataFactory.namedNode(s.RDF+"nil"),e.reifiedStatementId);else if(e.predicate)if(e.hadChildren||e.childrenParseType===c.PROPERTY){if(!e.predicateEmitted){const t=this.dataFactory.blankNode();this.emitTriple(e.subject,e.predicate,t,e.reifiedStatementId);for(let r=0;r<e.predicateSubPredicates.length;r++)this.emitTriple(t,e.predicateSubPredicates[r],e.predicateSubObjects[r],null)}}else this.emitTriple(e.subject,e.predicate,this.dataFactory.literal(e.text||"",e.datatype||e.language),e.reifiedStatementId)}onDoctype(e){e.replace(/<!ENTITY\s+([^\s]+)\s+["']([^"']+)["']\s*>/g,(e,t,r)=>(this.saxStream._parser.ENTITIES[t]=r,""))}}var c;s.IRI_REGEX=/^([A-Za-z][A-Za-z0-9+-.]*):[^ "<>{}|\\\[\]`]*$/,s.MIME_TYPE="application/rdf+xml",s.RDF="http://www.w3.org/1999/02/22-rdf-syntax-ns#",s.XML="http://www.w3.org/XML/1998/namespace",s.XMLNS="http://www.w3.org/2000/xmlns/",s.DEFAULT_NS={xml:s.XML},s.FORBIDDEN_NODE_ELEMENTS=["RDF","ID","about","bagID","parseType","resource","nodeID","li","aboutEach","aboutEachPrefix"],s.FORBIDDEN_PROPERTY_ELEMENTS=["Description","RDF","ID","about","bagID","parseType","resource","nodeID","aboutEach","aboutEachPrefix"],s.NCNAME_MATCHER=/^([A-Za-z\xC0-\xD6\xD8-\xF6\u{F8}-\u{2FF}\u{370}-\u{37D}\u{37F}-\u{1FFF}\u{200C}-\u{200D}\u{2070}-\u{218F}\u{2C00}-\u{2FEF}\u{3001}-\u{D7FF}\u{F900}-\u{FDCF}\u{FDF0}-\u{FFFD}\u{10000}-\u{EFFFF}_])([A-Za-z\xC0-\xD6\xD8-\xF6\u{F8}-\u{2FF}\u{370}-\u{37D}\u{37F}-\u{1FFF}\u{200C}-\u{200D}\u{2070}-\u{218F}\u{2C00}-\u{2FEF}\u{3001}-\u{D7FF}\u{F900}-\u{FDCF}\u{FDF0}-\u{FFFD}\u{10000}-\u{EFFFF}_\-.0-9#xB7\u{0300}-\u{036F}\u{203F}-\u{2040}])*$/u,t.RdfXmlParser=s,function(e){e[e.RESOURCE=0]="RESOURCE",e[e.PROPERTY=1]="PROPERTY"}(c=t.ParseType||(t.ParseType={}))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});t.ParseError=class extends Error{constructor(e,t){const r=e.saxStream._parser;super(e.trackPosition?`Line ${r.line+1} column ${r.column+1}: ${t}`:t)}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(52),i=r(163);t.ActorRdfParseXmlRdfa=class extends n.ActorRdfParseFixedMediaTypes{constructor(e){super(e)}async runHandle(e,t,r){const n=e.headers?e.headers.get("content-language"):null;e.input.on("error",e=>a.emit("error",e));const a=e.input.pipe(new i.RdfaParser({baseIRI:e.baseIRI,profile:"xml",language:n}));return{quads:a,triples:!0}}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(384),i=r(3),a=r(405),o=r(406),s=r(92),c=r(176);class u extends i.Transform{constructor(e){super({objectMode:!0}),this.activeTagStack=[],e=e||{},this.options=e,this.util=new c.Util(e.dataFactory,e.baseIRI),this.defaultGraph=e.defaultGraph||this.util.dataFactory.defaultGraph();const t=e.contentType?c.Util.contentTypeToProfile(e.contentType):e.profile||"";this.features=e.features||s.RDFA_FEATURES[t],this.htmlParseListener=e.htmlParseListener,this.rdfaPatterns=this.features.copyRdfaPatterns?{}:null,this.pendingRdfaPatternCopies=this.features.copyRdfaPatterns?{}:null,this.parser=this.initializeParser("xml"===t),this.activeTagStack.push({incompleteTriples:[],inlist:!1,language:e.language,listMapping:{},listMappingLocal:{},name:"",prefixesAll:Object.assign({},o["@context"],this.features.xhtmlInitialContext?a["@context"]:{}),prefixesCustom:{},skipElement:!1,vocab:e.vocab})}import(e){const t=new i.PassThrough({objectMode:!0});e.on("error",e=>r.emit("error",e)),e.on("data",e=>t.write(e)),e.on("end",()=>t.emit("end"));const r=t.pipe(new u(this.options));return r}_transform(e,t,r){this.parser.write(e),r()}_flush(e){this.parser.end(),e()}onTagOpen(e,t){let r=this.activeTagStack.length-1;for(;r>0&&this.activeTagStack[r].skipElement;)r--;let n=this.activeTagStack[r];r!==this.activeTagStack.length-1&&(n=Object.assign({},n,{language:this.activeTagStack[this.activeTagStack.length-1].language,prefixesAll:this.activeTagStack[this.activeTagStack.length-1].prefixesAll,prefixesCustom:this.activeTagStack[this.activeTagStack.length-1].prefixesCustom,vocab:this.activeTagStack[this.activeTagStack.length-1].vocab}));const i={collectChildTags:n.collectChildTags,incompleteTriples:[],inlist:"inlist"in t,listMapping:[],listMappingLocal:n.listMapping,localBaseIRI:n.localBaseIRI,name:e,prefixesAll:null,prefixesCustom:null,skipElement:!1};if(this.activeTagStack.push(i),i.collectChildTags){for(const e of Object.keys(n.prefixesCustom).sort()){const r=n.prefixesCustom[e],i=""===e?"xmlns":"xmlns:"+e;i in t||(t[i]=r)}const r=Object.keys(t).map(e=>`${e}="${t[e]}"`).join(" ");if(i.text=[`<${e}${r?" "+r:""}>`],this.features.skipHandlingXmlLiteralChildren)return}let a,o,s,u=!0,l=!0;if(this.features.onlyAllowUriRelRevIfProperty&&("property"in t&&"rel"in t&&(u=!1,t.rel.indexOf(":")<0&&delete t.rel),"property"in t&&"rev"in t&&(l=!1,t.rev.indexOf(":")<0&&delete t.rev)),this.features.copyRdfaPatterns){if(n.collectedPatternTag){const r={attributes:t,children:[],name:e,referenced:!1,rootPattern:!1,text:[]};return n.collectedPatternTag.children.push(r),void(i.collectedPatternTag=r)}if("rdfa:Pattern"===t.typeof)return void(i.collectedPatternTag={attributes:t,children:[],name:e,parentTag:n,referenced:!1,rootPattern:!0,text:[]});if("rdfa:copy"===t.property){const e=t.resource||t.href||t.src;return void(this.rdfaPatterns[e]?this.emitPatternCopy(n,this.rdfaPatterns[e],e):(this.pendingRdfaPatternCopies[e]||(this.pendingRdfaPatternCopies[e]=[]),this.pendingRdfaPatternCopies[e].push(n)))}}if(this.features.baseTag&&"base"===e&&t.href&&(this.util.baseIRI=this.util.getBaseIRI(t.href)),this.features.xmlBase&&t["xml:base"]&&(i.localBaseIRI=this.util.getBaseIRI(t["xml:base"])),this.features.timeTag&&"time"===e&&!t.datatype&&(i.interpretObjectAsTime=!0),"vocab"in t?t.vocab?(i.vocab=t.vocab,this.emitTriple(this.util.getBaseIriTerm(i),this.util.dataFactory.namedNode(c.Util.RDFA+"usesVocabulary"),this.util.dataFactory.namedNode(i.vocab))):i.vocab=this.activeTagStack[0].vocab:i.vocab=n.vocab,i.prefixesCustom=c.Util.parsePrefixes(t,n.prefixesCustom,this.features.xmlnsPrefixMappings),i.prefixesAll=Object.keys(i.prefixesCustom).length>0?Object.assign({},n.prefixesAll,i.prefixesCustom):n.prefixesAll,this.features.roleAttribute&&t.role){const e=t.id?this.util.createIri("#"+t.id,i,!1,!1,!1):this.util.createBlankNode(),r=i.vocab;i.vocab="http://www.w3.org/1999/xhtml/vocab#";for(const r of this.util.createVocabIris(t.role,i,!0,!1))this.emitTriple(e,this.util.dataFactory.namedNode("http://www.w3.org/1999/xhtml/vocab#role"),r);i.vocab=r}"xml:lang"in t||this.features.langAttribute&&"lang"in t?i.language=t["xml:lang"]||t.lang:i.language=n.language;const f=2===this.activeTagStack.length;if("rel"in t||"rev"in t?("about"in t?(a=this.util.createIri(t.about,i,!1,!0,!0),i.explicitNewSubject=!!a,"typeof"in t&&(s=a)):f?a=!0:n.object&&(a=n.object),"resource"in t&&(o=this.util.createIri(t.resource,i,!1,!0,!0)),o||("href"in t||"src"in t?o=this.util.createIri(t.href||t.src,i,!1,!1,!0):!("typeof"in t)||"about"in t||this.isInheritSubjectInHeadBody(e)||(o=this.util.createBlankNode())),"typeof"in t&&!("about"in t)&&(s=this.isInheritSubjectInHeadBody(e)?a:o)):!("property"in t)||"content"in t||"datatype"in t?(("about"in t||"resource"in t)&&(a=this.util.createIri(t.about||t.resource,i,!1,!0,!0),i.explicitNewSubject=!!a),!a&&("href"in t||"src"in t)&&(a=this.util.createIri(t.href||t.src,i,!1,!1,!0),i.explicitNewSubject=!!a),a||(f?a=!0:this.isInheritSubjectInHeadBody(e)?a=n.object:"typeof"in t?(a=this.util.createBlankNode(),i.explicitNewSubject=!0):n.object&&(a=n.object,"property"in t||(i.skipElement=!0))),"typeof"in t&&(s=a)):("about"in t?(a=this.util.createIri(t.about,i,!1,!0,!0),i.explicitNewSubject=!!a):f?a=!0:n.object&&(a=n.object),"typeof"in t&&("about"in t&&(s=this.util.createIri(t.about,i,!1,!0,!0)),!s&&f&&(s=!0),!s&&"resource"in t&&(s=this.util.createIri(t.resource,i,!1,!0,!0)),!s&&("href"in t||"src"in t)&&(s=this.util.createIri(t.href||t.src,i,!1,!1,!0)),!s&&this.isInheritSubjectInHeadBody(e)&&(s=a),s||(s=this.util.createBlankNode()),o=s)),s)for(const e of this.util.createVocabIris(t.typeof,i,!0,!0))this.emitTriple(this.util.getResourceOrBaseIri(s,i),this.util.dataFactory.namedNode(c.Util.RDF+"type"),e);if(a&&(i.listMapping={}),o){if("rel"in t&&"inlist"in t)for(const e of this.util.createVocabIris(t.rel,i,u,!1))this.addListMapping(i,a,e,o);if(!("rel"in t&&"inlist"in t)){if("rel"in t)for(const e of this.util.createVocabIris(t.rel,i,u,!1))this.emitTriple(this.util.getResourceOrBaseIri(a,i),e,this.util.getResourceOrBaseIri(o,i));if("rev"in t)for(const e of this.util.createVocabIris(t.rev,i,l,!1))this.emitTriple(this.util.getResourceOrBaseIri(o,i),e,this.util.getResourceOrBaseIri(a,i))}}if(!o){if("rel"in t)if("inlist"in t)for(const e of this.util.createVocabIris(t.rel,i,u,!1))this.addListMapping(i,a,e,null),i.incompleteTriples.push({predicate:e,reverse:!1,list:!0});else for(const e of this.util.createVocabIris(t.rel,i,u,!1))i.incompleteTriples.push({predicate:e,reverse:!1});if("rev"in t)for(const e of this.util.createVocabIris(t.rev,i,l,!1))i.incompleteTriples.push({predicate:e,reverse:!0});i.incompleteTriples.length>0&&(o=this.util.createBlankNode())}if("property"in t){let e;if(i.predicates=this.util.createVocabIris(t.property,i,!0,!1),"datatype"in t?(i.datatype=this.util.createIri(t.datatype,i,!0,!0,!1),i.datatype&&(i.datatype.value===c.Util.RDF+"XMLLiteral"||this.features.htmlDatatype&&i.datatype.value===c.Util.RDF+"HTML")&&(i.collectChildTags=!0)):("rev"in t||"rel"in t||"content"in t||("resource"in t&&(e=this.util.createIri(t.resource,i,!1,!0,!0)),!e&&"href"in t&&(e=this.util.createIri(t.href,i,!1,!1,!0)),!e&&"src"in t&&(e=this.util.createIri(t.src,i,!1,!1,!0))),"typeof"in t&&!("about"in t)&&(e=s)),"content"in t){const e=this.util.createLiteral(t.content,i);if("inlist"in t)for(const t of i.predicates)this.addListMapping(i,a,t,e);else{const t=this.util.getResourceOrBaseIri(a,i);for(const r of i.predicates)this.emitTriple(t,r,e)}i.predicates=null}else if(this.features.datetimeAttribute&&"datetime"in t){i.interpretObjectAsTime=!0;const e=this.util.createLiteral(t.datetime,i);if("inlist"in t)for(const t of i.predicates)this.addListMapping(i,a,t,e);else{const t=this.util.getResourceOrBaseIri(a,i);for(const r of i.predicates)this.emitTriple(t,r,e)}i.predicates=null}else if(e){const r=this.util.getResourceOrBaseIri(e,i);if("inlist"in t)for(const e of i.predicates)this.addListMapping(i,a,e,r);else{const e=this.util.getResourceOrBaseIri(a,i);for(const t of i.predicates)this.emitTriple(e,t,r)}i.predicates=null}}let d=!1;if(!i.skipElement&&a&&n.incompleteTriples.length>0){d=!0;const e=this.util.getResourceOrBaseIri(n.subject,i),t=this.util.getResourceOrBaseIri(a,i);for(const r of n.incompleteTriples)if(r.reverse)this.emitTriple(t,r.predicate,e);else if(r.list){let e=null;for(let t=this.activeTagStack.length-1;t>=0;t--)if(this.activeTagStack[t].inlist){e=this.activeTagStack[t];break}this.addListMapping(e,a,r.predicate,t)}else this.emitTriple(e,r.predicate,t)}!d&&n.incompleteTriples.length>0&&(i.incompleteTriples=i.incompleteTriples.concat(n.incompleteTriples)),i.subject=a||n.subject,i.object=o||a}onText(e){const t=this.activeTagStack[this.activeTagStack.length-1];this.features.copyRdfaPatterns&&t.collectedPatternTag?t.collectedPatternTag.text.push(e):(t.text||(t.text=[]),t.text.push(e))}onTagClose(){const e=this.activeTagStack[this.activeTagStack.length-1],t=this.activeTagStack[this.activeTagStack.length-2];if(!(e.collectChildTags&&t.collectChildTags&&this.features.skipHandlingXmlLiteralChildren)){if(this.features.copyRdfaPatterns&&e.collectedPatternTag&&e.collectedPatternTag.rootPattern){const t=e.collectedPatternTag.attributes.resource;if(delete e.collectedPatternTag.attributes.resource,delete e.collectedPatternTag.attributes.typeof,this.rdfaPatterns[t]=e.collectedPatternTag,this.pendingRdfaPatternCopies[t]){for(const r of this.pendingRdfaPatternCopies[t])this.emitPatternCopy(r,e.collectedPatternTag,t);delete this.pendingRdfaPatternCopies[t]}return void this.activeTagStack.pop()}if(e.predicates){const r=this.util.getResourceOrBaseIri(e.subject,e);let n=e.text||[];e.collectChildTags&&t.collectChildTags&&(n=n.slice(1));const i=this.util.createLiteral(n.join(""),e);if(e.inlist)for(const t of e.predicates)this.addListMapping(e,r,t,i);else for(const t of e.predicates)this.emitTriple(r,t,i);t.predicates||(e.text=null)}if(e.object&&Object.keys(e.listMapping).length>0){const t=this.util.getResourceOrBaseIri(e.object,e);for(const r in e.listMapping){const n=this.util.dataFactory.namedNode(r),i=e.listMapping[r];if(i.length>0){const r=i.map(()=>this.util.createBlankNode());for(let t=0;t<i.length;t++){const n=this.util.getResourceOrBaseIri(i[t],e);this.emitTriple(r[t],this.util.dataFactory.namedNode(c.Util.RDF+"first"),n),this.emitTriple(r[t],this.util.dataFactory.namedNode(c.Util.RDF+"rest"),t<i.length-1?r[t+1]:this.util.dataFactory.namedNode(c.Util.RDF+"nil"))}this.emitTriple(t,n,r[0])}else this.emitTriple(t,n,this.util.dataFactory.namedNode(c.Util.RDF+"nil"))}}}this.activeTagStack.pop(),e.collectChildTags&&e.text&&e.text.push(`</${e.name}>`),e.text&&t&&(t.text?t.text=t.text.concat(e.text):t.text=e.text)}onEnd(){if(this.features.copyRdfaPatterns){this.features.copyRdfaPatterns=!1;for(const e in this.rdfaPatterns){const t=this.rdfaPatterns[e];t.referenced||(t.attributes.typeof="rdfa:Pattern",t.attributes.resource=e,this.emitPatternCopy(t.parentTag,t,e),t.referenced=!1,delete t.attributes.typeof,delete t.attributes.resource)}for(const e in this.pendingRdfaPatternCopies)for(const t of this.pendingRdfaPatternCopies[e])this.activeTagStack.push(t),this.onTagOpen("link",{property:"rdfa:copy",href:e}),this.onTagClose(),this.activeTagStack.pop();this.features.copyRdfaPatterns=!0}}isInheritSubjectInHeadBody(e){return this.features.inheritSubjectInHeadBody&&("head"===e||"body"===e)}addListMapping(e,t,r,n){if(e.explicitNewSubject){const i=this.util.createBlankNode();this.emitTriple(this.util.getResourceOrBaseIri(t,e),r,i),this.emitTriple(i,this.util.dataFactory.namedNode(c.Util.RDF+"first"),this.util.getResourceOrBaseIri(n,e)),this.emitTriple(i,this.util.dataFactory.namedNode(c.Util.RDF+"rest"),this.util.dataFactory.namedNode(c.Util.RDF+"nil"))}else{let t=e.listMappingLocal[r.value];t||(e.listMappingLocal[r.value]=t=[]),n&&t.push(n)}}emitTriple(e,t,r){"NamedNode"===e.termType&&e.value.indexOf(":")<0||"NamedNode"===t.termType&&t.value.indexOf(":")<0||"NamedNode"===r.termType&&r.value.indexOf(":")<0||this.push(this.util.dataFactory.quad(e,t,r,this.defaultGraph))}emitPatternCopy(e,t,r){if(this.activeTagStack.push(e),t.referenced=!0,t.constructedBlankNodes){let e=0;this.util.blankNodeFactory=()=>t.constructedBlankNodes[e++]}else t.constructedBlankNodes=[],this.util.blankNodeFactory=()=>{const e=this.util.dataFactory.blankNode();return t.constructedBlankNodes.push(e),e};this.emitPatternCopyAbsolute(t,!0,r),this.util.blankNodeFactory=null,this.activeTagStack.pop()}emitPatternCopyAbsolute(e,t,r){if(t||"rdfa:copy"!==e.attributes.property||e.attributes.href!==r){this.onTagOpen(e.name,e.attributes);for(const t of e.text)this.onText(t);for(const t of e.children)this.emitPatternCopyAbsolute(t,!1,r);this.onTagClose()}}initializeParser(e){return new n.Parser({onclosetag:()=>{try{this.onTagClose()}catch(e){this.emit("error",e)}this.htmlParseListener&&this.htmlParseListener.onTagClose()},onend:()=>{try{this.onEnd()}catch(e){this.emit("error",e)}this.htmlParseListener&&this.htmlParseListener.onEnd()},onopentag:(e,t)=>{try{this.onTagOpen(e,t)}catch(e){this.emit("error",e)}this.htmlParseListener&&this.htmlParseListener.onTagOpen(e,t)},ontext:e=>{try{this.onText(e)}catch(e){this.emit("error",e)}this.htmlParseListener&&this.htmlParseListener.onText(e)}},{decodeEntities:!0,recognizeSelfClosing:!0,xmlMode:e})}}t.RdfaParser=u},function(e,t,r){"use strict";function n(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}var i=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)Object.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t.default=e,t};Object.defineProperty(t,"__esModule",{value:!0});var a=r(164);t.Parser=a.Parser;var o=r(166);t.DomHandler=o.DomHandler,t.DefaultHandler=o.DomHandler,t.parseDOM=function(e,t){var r=new o.DomHandler(void 0,t);return new a.Parser(r,t).end(e),r.dom},t.createDomStream=function(e,t,r){var n=new o.DomHandler(e,t,r);return new a.Parser(n,t)};var s=r(165);t.Tokenizer=s.default;var c=i(r(167));t.ElementType=c,t.EVENTS={attribute:2,cdatastart:0,cdataend:0,text:1,processinginstruction:2,comment:1,commentend:0,closetag:1,opentag:2,opentagname:1,error:1,end:0},n(r(168)),n(r(402)),n(r(403));var u=i(r(169));t.DomUtils=u;var l=r(168);t.RssHandler=l.FeedHandler},function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var i=n(r(386));t.default=function(e){if(e>=55296&&e<=57343||e>1114111)return"�";e in i.default&&(e=i.default[e]);var t="";return e>65535&&(e-=65536,t+=String.fromCharCode(e>>>10&1023|55296),e=56320|1023&e),t+=String.fromCharCode(e)}},function(e){e.exports=JSON.parse('{"0":65533,"128":8364,"130":8218,"131":402,"132":8222,"133":8230,"134":8224,"135":8225,"136":710,"137":8240,"138":352,"139":8249,"140":338,"142":381,"145":8216,"146":8217,"147":8220,"148":8221,"149":8226,"150":8211,"151":8212,"152":732,"153":8482,"154":353,"155":8250,"156":339,"158":382,"159":376}')},function(e){e.exports=JSON.parse('{"Aacute":"Á","aacute":"á","Abreve":"Ă","abreve":"ă","ac":"∾","acd":"∿","acE":"∾̳","Acirc":"Â","acirc":"â","acute":"´","Acy":"А","acy":"а","AElig":"Æ","aelig":"æ","af":"⁡","Afr":"𝔄","afr":"𝔞","Agrave":"À","agrave":"à","alefsym":"ℵ","aleph":"ℵ","Alpha":"Α","alpha":"α","Amacr":"Ā","amacr":"ā","amalg":"⨿","amp":"&","AMP":"&","andand":"⩕","And":"⩓","and":"∧","andd":"⩜","andslope":"⩘","andv":"⩚","ang":"∠","ange":"⦤","angle":"∠","angmsdaa":"⦨","angmsdab":"⦩","angmsdac":"⦪","angmsdad":"⦫","angmsdae":"⦬","angmsdaf":"⦭","angmsdag":"⦮","angmsdah":"⦯","angmsd":"∡","angrt":"∟","angrtvb":"⊾","angrtvbd":"⦝","angsph":"∢","angst":"Å","angzarr":"⍼","Aogon":"Ą","aogon":"ą","Aopf":"𝔸","aopf":"𝕒","apacir":"⩯","ap":"≈","apE":"⩰","ape":"≊","apid":"≋","apos":"\'","ApplyFunction":"⁡","approx":"≈","approxeq":"≊","Aring":"Å","aring":"å","Ascr":"𝒜","ascr":"𝒶","Assign":"≔","ast":"*","asymp":"≈","asympeq":"≍","Atilde":"Ã","atilde":"ã","Auml":"Ä","auml":"ä","awconint":"∳","awint":"⨑","backcong":"≌","backepsilon":"϶","backprime":"‵","backsim":"∽","backsimeq":"⋍","Backslash":"∖","Barv":"⫧","barvee":"⊽","barwed":"⌅","Barwed":"⌆","barwedge":"⌅","bbrk":"⎵","bbrktbrk":"⎶","bcong":"≌","Bcy":"Б","bcy":"б","bdquo":"„","becaus":"∵","because":"∵","Because":"∵","bemptyv":"⦰","bepsi":"϶","bernou":"ℬ","Bernoullis":"ℬ","Beta":"Β","beta":"β","beth":"ℶ","between":"≬","Bfr":"𝔅","bfr":"𝔟","bigcap":"⋂","bigcirc":"◯","bigcup":"⋃","bigodot":"⨀","bigoplus":"⨁","bigotimes":"⨂","bigsqcup":"⨆","bigstar":"★","bigtriangledown":"▽","bigtriangleup":"△","biguplus":"⨄","bigvee":"⋁","bigwedge":"⋀","bkarow":"⤍","blacklozenge":"⧫","blacksquare":"▪","blacktriangle":"▴","blacktriangledown":"▾","blacktriangleleft":"◂","blacktriangleright":"▸","blank":"␣","blk12":"▒","blk14":"░","blk34":"▓","block":"█","bne":"=⃥","bnequiv":"≡⃥","bNot":"⫭","bnot":"⌐","Bopf":"𝔹","bopf":"𝕓","bot":"⊥","bottom":"⊥","bowtie":"⋈","boxbox":"⧉","boxdl":"┐","boxdL":"╕","boxDl":"╖","boxDL":"╗","boxdr":"┌","boxdR":"╒","boxDr":"╓","boxDR":"╔","boxh":"─","boxH":"═","boxhd":"┬","boxHd":"╤","boxhD":"╥","boxHD":"╦","boxhu":"┴","boxHu":"╧","boxhU":"╨","boxHU":"╩","boxminus":"⊟","boxplus":"⊞","boxtimes":"⊠","boxul":"┘","boxuL":"╛","boxUl":"╜","boxUL":"╝","boxur":"└","boxuR":"╘","boxUr":"╙","boxUR":"╚","boxv":"│","boxV":"║","boxvh":"┼","boxvH":"╪","boxVh":"╫","boxVH":"╬","boxvl":"┤","boxvL":"╡","boxVl":"╢","boxVL":"╣","boxvr":"├","boxvR":"╞","boxVr":"╟","boxVR":"╠","bprime":"‵","breve":"˘","Breve":"˘","brvbar":"¦","bscr":"𝒷","Bscr":"ℬ","bsemi":"⁏","bsim":"∽","bsime":"⋍","bsolb":"⧅","bsol":"\\\\","bsolhsub":"⟈","bull":"•","bullet":"•","bump":"≎","bumpE":"⪮","bumpe":"≏","Bumpeq":"≎","bumpeq":"≏","Cacute":"Ć","cacute":"ć","capand":"⩄","capbrcup":"⩉","capcap":"⩋","cap":"∩","Cap":"⋒","capcup":"⩇","capdot":"⩀","CapitalDifferentialD":"ⅅ","caps":"∩︀","caret":"⁁","caron":"ˇ","Cayleys":"ℭ","ccaps":"⩍","Ccaron":"Č","ccaron":"č","Ccedil":"Ç","ccedil":"ç","Ccirc":"Ĉ","ccirc":"ĉ","Cconint":"∰","ccups":"⩌","ccupssm":"⩐","Cdot":"Ċ","cdot":"ċ","cedil":"¸","Cedilla":"¸","cemptyv":"⦲","cent":"¢","centerdot":"·","CenterDot":"·","cfr":"𝔠","Cfr":"ℭ","CHcy":"Ч","chcy":"ч","check":"✓","checkmark":"✓","Chi":"Χ","chi":"χ","circ":"ˆ","circeq":"≗","circlearrowleft":"↺","circlearrowright":"↻","circledast":"⊛","circledcirc":"⊚","circleddash":"⊝","CircleDot":"⊙","circledR":"®","circledS":"Ⓢ","CircleMinus":"⊖","CirclePlus":"⊕","CircleTimes":"⊗","cir":"○","cirE":"⧃","cire":"≗","cirfnint":"⨐","cirmid":"⫯","cirscir":"⧂","ClockwiseContourIntegral":"∲","CloseCurlyDoubleQuote":"”","CloseCurlyQuote":"’","clubs":"♣","clubsuit":"♣","colon":":","Colon":"∷","Colone":"⩴","colone":"≔","coloneq":"≔","comma":",","commat":"@","comp":"∁","compfn":"∘","complement":"∁","complexes":"ℂ","cong":"≅","congdot":"⩭","Congruent":"≡","conint":"∮","Conint":"∯","ContourIntegral":"∮","copf":"𝕔","Copf":"ℂ","coprod":"∐","Coproduct":"∐","copy":"©","COPY":"©","copysr":"℗","CounterClockwiseContourIntegral":"∳","crarr":"↵","cross":"✗","Cross":"⨯","Cscr":"𝒞","cscr":"𝒸","csub":"⫏","csube":"⫑","csup":"⫐","csupe":"⫒","ctdot":"⋯","cudarrl":"⤸","cudarrr":"⤵","cuepr":"⋞","cuesc":"⋟","cularr":"↶","cularrp":"⤽","cupbrcap":"⩈","cupcap":"⩆","CupCap":"≍","cup":"∪","Cup":"⋓","cupcup":"⩊","cupdot":"⊍","cupor":"⩅","cups":"∪︀","curarr":"↷","curarrm":"⤼","curlyeqprec":"⋞","curlyeqsucc":"⋟","curlyvee":"⋎","curlywedge":"⋏","curren":"¤","curvearrowleft":"↶","curvearrowright":"↷","cuvee":"⋎","cuwed":"⋏","cwconint":"∲","cwint":"∱","cylcty":"⌭","dagger":"†","Dagger":"‡","daleth":"ℸ","darr":"↓","Darr":"↡","dArr":"⇓","dash":"‐","Dashv":"⫤","dashv":"⊣","dbkarow":"⤏","dblac":"˝","Dcaron":"Ď","dcaron":"ď","Dcy":"Д","dcy":"д","ddagger":"‡","ddarr":"⇊","DD":"ⅅ","dd":"ⅆ","DDotrahd":"⤑","ddotseq":"⩷","deg":"°","Del":"∇","Delta":"Δ","delta":"δ","demptyv":"⦱","dfisht":"⥿","Dfr":"𝔇","dfr":"𝔡","dHar":"⥥","dharl":"⇃","dharr":"⇂","DiacriticalAcute":"´","DiacriticalDot":"˙","DiacriticalDoubleAcute":"˝","DiacriticalGrave":"`","DiacriticalTilde":"˜","diam":"⋄","diamond":"⋄","Diamond":"⋄","diamondsuit":"♦","diams":"♦","die":"¨","DifferentialD":"ⅆ","digamma":"ϝ","disin":"⋲","div":"÷","divide":"÷","divideontimes":"⋇","divonx":"⋇","DJcy":"Ђ","djcy":"ђ","dlcorn":"⌞","dlcrop":"⌍","dollar":"$","Dopf":"𝔻","dopf":"𝕕","Dot":"¨","dot":"˙","DotDot":"⃜","doteq":"≐","doteqdot":"≑","DotEqual":"≐","dotminus":"∸","dotplus":"∔","dotsquare":"⊡","doublebarwedge":"⌆","DoubleContourIntegral":"∯","DoubleDot":"¨","DoubleDownArrow":"⇓","DoubleLeftArrow":"⇐","DoubleLeftRightArrow":"⇔","DoubleLeftTee":"⫤","DoubleLongLeftArrow":"⟸","DoubleLongLeftRightArrow":"⟺","DoubleLongRightArrow":"⟹","DoubleRightArrow":"⇒","DoubleRightTee":"⊨","DoubleUpArrow":"⇑","DoubleUpDownArrow":"⇕","DoubleVerticalBar":"∥","DownArrowBar":"⤓","downarrow":"↓","DownArrow":"↓","Downarrow":"⇓","DownArrowUpArrow":"⇵","DownBreve":"̑","downdownarrows":"⇊","downharpoonleft":"⇃","downharpoonright":"⇂","DownLeftRightVector":"⥐","DownLeftTeeVector":"⥞","DownLeftVectorBar":"⥖","DownLeftVector":"↽","DownRightTeeVector":"⥟","DownRightVectorBar":"⥗","DownRightVector":"⇁","DownTeeArrow":"↧","DownTee":"⊤","drbkarow":"⤐","drcorn":"⌟","drcrop":"⌌","Dscr":"𝒟","dscr":"𝒹","DScy":"Ѕ","dscy":"ѕ","dsol":"⧶","Dstrok":"Đ","dstrok":"đ","dtdot":"⋱","dtri":"▿","dtrif":"▾","duarr":"⇵","duhar":"⥯","dwangle":"⦦","DZcy":"Џ","dzcy":"џ","dzigrarr":"⟿","Eacute":"É","eacute":"é","easter":"⩮","Ecaron":"Ě","ecaron":"ě","Ecirc":"Ê","ecirc":"ê","ecir":"≖","ecolon":"≕","Ecy":"Э","ecy":"э","eDDot":"⩷","Edot":"Ė","edot":"ė","eDot":"≑","ee":"ⅇ","efDot":"≒","Efr":"𝔈","efr":"𝔢","eg":"⪚","Egrave":"È","egrave":"è","egs":"⪖","egsdot":"⪘","el":"⪙","Element":"∈","elinters":"⏧","ell":"ℓ","els":"⪕","elsdot":"⪗","Emacr":"Ē","emacr":"ē","empty":"∅","emptyset":"∅","EmptySmallSquare":"◻","emptyv":"∅","EmptyVerySmallSquare":"▫","emsp13":" ","emsp14":" ","emsp":" ","ENG":"Ŋ","eng":"ŋ","ensp":" ","Eogon":"Ę","eogon":"ę","Eopf":"𝔼","eopf":"𝕖","epar":"⋕","eparsl":"⧣","eplus":"⩱","epsi":"ε","Epsilon":"Ε","epsilon":"ε","epsiv":"ϵ","eqcirc":"≖","eqcolon":"≕","eqsim":"≂","eqslantgtr":"⪖","eqslantless":"⪕","Equal":"⩵","equals":"=","EqualTilde":"≂","equest":"≟","Equilibrium":"⇌","equiv":"≡","equivDD":"⩸","eqvparsl":"⧥","erarr":"⥱","erDot":"≓","escr":"ℯ","Escr":"ℰ","esdot":"≐","Esim":"⩳","esim":"≂","Eta":"Η","eta":"η","ETH":"Ð","eth":"ð","Euml":"Ë","euml":"ë","euro":"€","excl":"!","exist":"∃","Exists":"∃","expectation":"ℰ","exponentiale":"ⅇ","ExponentialE":"ⅇ","fallingdotseq":"≒","Fcy":"Ф","fcy":"ф","female":"♀","ffilig":"ffi","fflig":"ff","ffllig":"ffl","Ffr":"𝔉","ffr":"𝔣","filig":"fi","FilledSmallSquare":"◼","FilledVerySmallSquare":"▪","fjlig":"fj","flat":"♭","fllig":"fl","fltns":"▱","fnof":"ƒ","Fopf":"𝔽","fopf":"𝕗","forall":"∀","ForAll":"∀","fork":"⋔","forkv":"⫙","Fouriertrf":"ℱ","fpartint":"⨍","frac12":"½","frac13":"⅓","frac14":"¼","frac15":"⅕","frac16":"⅙","frac18":"⅛","frac23":"⅔","frac25":"⅖","frac34":"¾","frac35":"⅗","frac38":"⅜","frac45":"⅘","frac56":"⅚","frac58":"⅝","frac78":"⅞","frasl":"⁄","frown":"⌢","fscr":"𝒻","Fscr":"ℱ","gacute":"ǵ","Gamma":"Γ","gamma":"γ","Gammad":"Ϝ","gammad":"ϝ","gap":"⪆","Gbreve":"Ğ","gbreve":"ğ","Gcedil":"Ģ","Gcirc":"Ĝ","gcirc":"ĝ","Gcy":"Г","gcy":"г","Gdot":"Ġ","gdot":"ġ","ge":"≥","gE":"≧","gEl":"⪌","gel":"⋛","geq":"≥","geqq":"≧","geqslant":"⩾","gescc":"⪩","ges":"⩾","gesdot":"⪀","gesdoto":"⪂","gesdotol":"⪄","gesl":"⋛︀","gesles":"⪔","Gfr":"𝔊","gfr":"𝔤","gg":"≫","Gg":"⋙","ggg":"⋙","gimel":"ℷ","GJcy":"Ѓ","gjcy":"ѓ","gla":"⪥","gl":"≷","glE":"⪒","glj":"⪤","gnap":"⪊","gnapprox":"⪊","gne":"⪈","gnE":"≩","gneq":"⪈","gneqq":"≩","gnsim":"⋧","Gopf":"𝔾","gopf":"𝕘","grave":"`","GreaterEqual":"≥","GreaterEqualLess":"⋛","GreaterFullEqual":"≧","GreaterGreater":"⪢","GreaterLess":"≷","GreaterSlantEqual":"⩾","GreaterTilde":"≳","Gscr":"𝒢","gscr":"ℊ","gsim":"≳","gsime":"⪎","gsiml":"⪐","gtcc":"⪧","gtcir":"⩺","gt":">","GT":">","Gt":"≫","gtdot":"⋗","gtlPar":"⦕","gtquest":"⩼","gtrapprox":"⪆","gtrarr":"⥸","gtrdot":"⋗","gtreqless":"⋛","gtreqqless":"⪌","gtrless":"≷","gtrsim":"≳","gvertneqq":"≩︀","gvnE":"≩︀","Hacek":"ˇ","hairsp":" ","half":"½","hamilt":"ℋ","HARDcy":"Ъ","hardcy":"ъ","harrcir":"⥈","harr":"↔","hArr":"⇔","harrw":"↭","Hat":"^","hbar":"ℏ","Hcirc":"Ĥ","hcirc":"ĥ","hearts":"♥","heartsuit":"♥","hellip":"…","hercon":"⊹","hfr":"𝔥","Hfr":"ℌ","HilbertSpace":"ℋ","hksearow":"⤥","hkswarow":"⤦","hoarr":"⇿","homtht":"∻","hookleftarrow":"↩","hookrightarrow":"↪","hopf":"𝕙","Hopf":"ℍ","horbar":"―","HorizontalLine":"─","hscr":"𝒽","Hscr":"ℋ","hslash":"ℏ","Hstrok":"Ħ","hstrok":"ħ","HumpDownHump":"≎","HumpEqual":"≏","hybull":"⁃","hyphen":"‐","Iacute":"Í","iacute":"í","ic":"⁣","Icirc":"Î","icirc":"î","Icy":"И","icy":"и","Idot":"İ","IEcy":"Е","iecy":"е","iexcl":"¡","iff":"⇔","ifr":"𝔦","Ifr":"ℑ","Igrave":"Ì","igrave":"ì","ii":"ⅈ","iiiint":"⨌","iiint":"∭","iinfin":"⧜","iiota":"℩","IJlig":"IJ","ijlig":"ij","Imacr":"Ī","imacr":"ī","image":"ℑ","ImaginaryI":"ⅈ","imagline":"ℐ","imagpart":"ℑ","imath":"ı","Im":"ℑ","imof":"⊷","imped":"Ƶ","Implies":"⇒","incare":"℅","in":"∈","infin":"∞","infintie":"⧝","inodot":"ı","intcal":"⊺","int":"∫","Int":"∬","integers":"ℤ","Integral":"∫","intercal":"⊺","Intersection":"⋂","intlarhk":"⨗","intprod":"⨼","InvisibleComma":"⁣","InvisibleTimes":"⁢","IOcy":"Ё","iocy":"ё","Iogon":"Į","iogon":"į","Iopf":"𝕀","iopf":"𝕚","Iota":"Ι","iota":"ι","iprod":"⨼","iquest":"¿","iscr":"𝒾","Iscr":"ℐ","isin":"∈","isindot":"⋵","isinE":"⋹","isins":"⋴","isinsv":"⋳","isinv":"∈","it":"⁢","Itilde":"Ĩ","itilde":"ĩ","Iukcy":"І","iukcy":"і","Iuml":"Ï","iuml":"ï","Jcirc":"Ĵ","jcirc":"ĵ","Jcy":"Й","jcy":"й","Jfr":"𝔍","jfr":"𝔧","jmath":"ȷ","Jopf":"𝕁","jopf":"𝕛","Jscr":"𝒥","jscr":"𝒿","Jsercy":"Ј","jsercy":"ј","Jukcy":"Є","jukcy":"є","Kappa":"Κ","kappa":"κ","kappav":"ϰ","Kcedil":"Ķ","kcedil":"ķ","Kcy":"К","kcy":"к","Kfr":"𝔎","kfr":"𝔨","kgreen":"ĸ","KHcy":"Х","khcy":"х","KJcy":"Ќ","kjcy":"ќ","Kopf":"𝕂","kopf":"𝕜","Kscr":"𝒦","kscr":"𝓀","lAarr":"⇚","Lacute":"Ĺ","lacute":"ĺ","laemptyv":"⦴","lagran":"ℒ","Lambda":"Λ","lambda":"λ","lang":"⟨","Lang":"⟪","langd":"⦑","langle":"⟨","lap":"⪅","Laplacetrf":"ℒ","laquo":"«","larrb":"⇤","larrbfs":"⤟","larr":"←","Larr":"↞","lArr":"⇐","larrfs":"⤝","larrhk":"↩","larrlp":"↫","larrpl":"⤹","larrsim":"⥳","larrtl":"↢","latail":"⤙","lAtail":"⤛","lat":"⪫","late":"⪭","lates":"⪭︀","lbarr":"⤌","lBarr":"⤎","lbbrk":"❲","lbrace":"{","lbrack":"[","lbrke":"⦋","lbrksld":"⦏","lbrkslu":"⦍","Lcaron":"Ľ","lcaron":"ľ","Lcedil":"Ļ","lcedil":"ļ","lceil":"⌈","lcub":"{","Lcy":"Л","lcy":"л","ldca":"⤶","ldquo":"“","ldquor":"„","ldrdhar":"⥧","ldrushar":"⥋","ldsh":"↲","le":"≤","lE":"≦","LeftAngleBracket":"⟨","LeftArrowBar":"⇤","leftarrow":"←","LeftArrow":"←","Leftarrow":"⇐","LeftArrowRightArrow":"⇆","leftarrowtail":"↢","LeftCeiling":"⌈","LeftDoubleBracket":"⟦","LeftDownTeeVector":"⥡","LeftDownVectorBar":"⥙","LeftDownVector":"⇃","LeftFloor":"⌊","leftharpoondown":"↽","leftharpoonup":"↼","leftleftarrows":"⇇","leftrightarrow":"↔","LeftRightArrow":"↔","Leftrightarrow":"⇔","leftrightarrows":"⇆","leftrightharpoons":"⇋","leftrightsquigarrow":"↭","LeftRightVector":"⥎","LeftTeeArrow":"↤","LeftTee":"⊣","LeftTeeVector":"⥚","leftthreetimes":"⋋","LeftTriangleBar":"⧏","LeftTriangle":"⊲","LeftTriangleEqual":"⊴","LeftUpDownVector":"⥑","LeftUpTeeVector":"⥠","LeftUpVectorBar":"⥘","LeftUpVector":"↿","LeftVectorBar":"⥒","LeftVector":"↼","lEg":"⪋","leg":"⋚","leq":"≤","leqq":"≦","leqslant":"⩽","lescc":"⪨","les":"⩽","lesdot":"⩿","lesdoto":"⪁","lesdotor":"⪃","lesg":"⋚︀","lesges":"⪓","lessapprox":"⪅","lessdot":"⋖","lesseqgtr":"⋚","lesseqqgtr":"⪋","LessEqualGreater":"⋚","LessFullEqual":"≦","LessGreater":"≶","lessgtr":"≶","LessLess":"⪡","lesssim":"≲","LessSlantEqual":"⩽","LessTilde":"≲","lfisht":"⥼","lfloor":"⌊","Lfr":"𝔏","lfr":"𝔩","lg":"≶","lgE":"⪑","lHar":"⥢","lhard":"↽","lharu":"↼","lharul":"⥪","lhblk":"▄","LJcy":"Љ","ljcy":"љ","llarr":"⇇","ll":"≪","Ll":"⋘","llcorner":"⌞","Lleftarrow":"⇚","llhard":"⥫","lltri":"◺","Lmidot":"Ŀ","lmidot":"ŀ","lmoustache":"⎰","lmoust":"⎰","lnap":"⪉","lnapprox":"⪉","lne":"⪇","lnE":"≨","lneq":"⪇","lneqq":"≨","lnsim":"⋦","loang":"⟬","loarr":"⇽","lobrk":"⟦","longleftarrow":"⟵","LongLeftArrow":"⟵","Longleftarrow":"⟸","longleftrightarrow":"⟷","LongLeftRightArrow":"⟷","Longleftrightarrow":"⟺","longmapsto":"⟼","longrightarrow":"⟶","LongRightArrow":"⟶","Longrightarrow":"⟹","looparrowleft":"↫","looparrowright":"↬","lopar":"⦅","Lopf":"𝕃","lopf":"𝕝","loplus":"⨭","lotimes":"⨴","lowast":"∗","lowbar":"_","LowerLeftArrow":"↙","LowerRightArrow":"↘","loz":"◊","lozenge":"◊","lozf":"⧫","lpar":"(","lparlt":"⦓","lrarr":"⇆","lrcorner":"⌟","lrhar":"⇋","lrhard":"⥭","lrm":"‎","lrtri":"⊿","lsaquo":"‹","lscr":"𝓁","Lscr":"ℒ","lsh":"↰","Lsh":"↰","lsim":"≲","lsime":"⪍","lsimg":"⪏","lsqb":"[","lsquo":"‘","lsquor":"‚","Lstrok":"Ł","lstrok":"ł","ltcc":"⪦","ltcir":"⩹","lt":"<","LT":"<","Lt":"≪","ltdot":"⋖","lthree":"⋋","ltimes":"⋉","ltlarr":"⥶","ltquest":"⩻","ltri":"◃","ltrie":"⊴","ltrif":"◂","ltrPar":"⦖","lurdshar":"⥊","luruhar":"⥦","lvertneqq":"≨︀","lvnE":"≨︀","macr":"¯","male":"♂","malt":"✠","maltese":"✠","Map":"⤅","map":"↦","mapsto":"↦","mapstodown":"↧","mapstoleft":"↤","mapstoup":"↥","marker":"▮","mcomma":"⨩","Mcy":"М","mcy":"м","mdash":"—","mDDot":"∺","measuredangle":"∡","MediumSpace":" ","Mellintrf":"ℳ","Mfr":"𝔐","mfr":"𝔪","mho":"℧","micro":"µ","midast":"*","midcir":"⫰","mid":"∣","middot":"·","minusb":"⊟","minus":"−","minusd":"∸","minusdu":"⨪","MinusPlus":"∓","mlcp":"⫛","mldr":"…","mnplus":"∓","models":"⊧","Mopf":"𝕄","mopf":"𝕞","mp":"∓","mscr":"𝓂","Mscr":"ℳ","mstpos":"∾","Mu":"Μ","mu":"μ","multimap":"⊸","mumap":"⊸","nabla":"∇","Nacute":"Ń","nacute":"ń","nang":"∠⃒","nap":"≉","napE":"⩰̸","napid":"≋̸","napos":"ʼn","napprox":"≉","natural":"♮","naturals":"ℕ","natur":"♮","nbsp":" ","nbump":"≎̸","nbumpe":"≏̸","ncap":"⩃","Ncaron":"Ň","ncaron":"ň","Ncedil":"Ņ","ncedil":"ņ","ncong":"≇","ncongdot":"⩭̸","ncup":"⩂","Ncy":"Н","ncy":"н","ndash":"–","nearhk":"⤤","nearr":"↗","neArr":"⇗","nearrow":"↗","ne":"≠","nedot":"≐̸","NegativeMediumSpace":"​","NegativeThickSpace":"​","NegativeThinSpace":"​","NegativeVeryThinSpace":"​","nequiv":"≢","nesear":"⤨","nesim":"≂̸","NestedGreaterGreater":"≫","NestedLessLess":"≪","NewLine":"\\n","nexist":"∄","nexists":"∄","Nfr":"𝔑","nfr":"𝔫","ngE":"≧̸","nge":"≱","ngeq":"≱","ngeqq":"≧̸","ngeqslant":"⩾̸","nges":"⩾̸","nGg":"⋙̸","ngsim":"≵","nGt":"≫⃒","ngt":"≯","ngtr":"≯","nGtv":"≫̸","nharr":"↮","nhArr":"⇎","nhpar":"⫲","ni":"∋","nis":"⋼","nisd":"⋺","niv":"∋","NJcy":"Њ","njcy":"њ","nlarr":"↚","nlArr":"⇍","nldr":"‥","nlE":"≦̸","nle":"≰","nleftarrow":"↚","nLeftarrow":"⇍","nleftrightarrow":"↮","nLeftrightarrow":"⇎","nleq":"≰","nleqq":"≦̸","nleqslant":"⩽̸","nles":"⩽̸","nless":"≮","nLl":"⋘̸","nlsim":"≴","nLt":"≪⃒","nlt":"≮","nltri":"⋪","nltrie":"⋬","nLtv":"≪̸","nmid":"∤","NoBreak":"⁠","NonBreakingSpace":" ","nopf":"𝕟","Nopf":"ℕ","Not":"⫬","not":"¬","NotCongruent":"≢","NotCupCap":"≭","NotDoubleVerticalBar":"∦","NotElement":"∉","NotEqual":"≠","NotEqualTilde":"≂̸","NotExists":"∄","NotGreater":"≯","NotGreaterEqual":"≱","NotGreaterFullEqual":"≧̸","NotGreaterGreater":"≫̸","NotGreaterLess":"≹","NotGreaterSlantEqual":"⩾̸","NotGreaterTilde":"≵","NotHumpDownHump":"≎̸","NotHumpEqual":"≏̸","notin":"∉","notindot":"⋵̸","notinE":"⋹̸","notinva":"∉","notinvb":"⋷","notinvc":"⋶","NotLeftTriangleBar":"⧏̸","NotLeftTriangle":"⋪","NotLeftTriangleEqual":"⋬","NotLess":"≮","NotLessEqual":"≰","NotLessGreater":"≸","NotLessLess":"≪̸","NotLessSlantEqual":"⩽̸","NotLessTilde":"≴","NotNestedGreaterGreater":"⪢̸","NotNestedLessLess":"⪡̸","notni":"∌","notniva":"∌","notnivb":"⋾","notnivc":"⋽","NotPrecedes":"⊀","NotPrecedesEqual":"⪯̸","NotPrecedesSlantEqual":"⋠","NotReverseElement":"∌","NotRightTriangleBar":"⧐̸","NotRightTriangle":"⋫","NotRightTriangleEqual":"⋭","NotSquareSubset":"⊏̸","NotSquareSubsetEqual":"⋢","NotSquareSuperset":"⊐̸","NotSquareSupersetEqual":"⋣","NotSubset":"⊂⃒","NotSubsetEqual":"⊈","NotSucceeds":"⊁","NotSucceedsEqual":"⪰̸","NotSucceedsSlantEqual":"⋡","NotSucceedsTilde":"≿̸","NotSuperset":"⊃⃒","NotSupersetEqual":"⊉","NotTilde":"≁","NotTildeEqual":"≄","NotTildeFullEqual":"≇","NotTildeTilde":"≉","NotVerticalBar":"∤","nparallel":"∦","npar":"∦","nparsl":"⫽⃥","npart":"∂̸","npolint":"⨔","npr":"⊀","nprcue":"⋠","nprec":"⊀","npreceq":"⪯̸","npre":"⪯̸","nrarrc":"⤳̸","nrarr":"↛","nrArr":"⇏","nrarrw":"↝̸","nrightarrow":"↛","nRightarrow":"⇏","nrtri":"⋫","nrtrie":"⋭","nsc":"⊁","nsccue":"⋡","nsce":"⪰̸","Nscr":"𝒩","nscr":"𝓃","nshortmid":"∤","nshortparallel":"∦","nsim":"≁","nsime":"≄","nsimeq":"≄","nsmid":"∤","nspar":"∦","nsqsube":"⋢","nsqsupe":"⋣","nsub":"⊄","nsubE":"⫅̸","nsube":"⊈","nsubset":"⊂⃒","nsubseteq":"⊈","nsubseteqq":"⫅̸","nsucc":"⊁","nsucceq":"⪰̸","nsup":"⊅","nsupE":"⫆̸","nsupe":"⊉","nsupset":"⊃⃒","nsupseteq":"⊉","nsupseteqq":"⫆̸","ntgl":"≹","Ntilde":"Ñ","ntilde":"ñ","ntlg":"≸","ntriangleleft":"⋪","ntrianglelefteq":"⋬","ntriangleright":"⋫","ntrianglerighteq":"⋭","Nu":"Ν","nu":"ν","num":"#","numero":"№","numsp":" ","nvap":"≍⃒","nvdash":"⊬","nvDash":"⊭","nVdash":"⊮","nVDash":"⊯","nvge":"≥⃒","nvgt":">⃒","nvHarr":"⤄","nvinfin":"⧞","nvlArr":"⤂","nvle":"≤⃒","nvlt":"<⃒","nvltrie":"⊴⃒","nvrArr":"⤃","nvrtrie":"⊵⃒","nvsim":"∼⃒","nwarhk":"⤣","nwarr":"↖","nwArr":"⇖","nwarrow":"↖","nwnear":"⤧","Oacute":"Ó","oacute":"ó","oast":"⊛","Ocirc":"Ô","ocirc":"ô","ocir":"⊚","Ocy":"О","ocy":"о","odash":"⊝","Odblac":"Ő","odblac":"ő","odiv":"⨸","odot":"⊙","odsold":"⦼","OElig":"Œ","oelig":"œ","ofcir":"⦿","Ofr":"𝔒","ofr":"𝔬","ogon":"˛","Ograve":"Ò","ograve":"ò","ogt":"⧁","ohbar":"⦵","ohm":"Ω","oint":"∮","olarr":"↺","olcir":"⦾","olcross":"⦻","oline":"‾","olt":"⧀","Omacr":"Ō","omacr":"ō","Omega":"Ω","omega":"ω","Omicron":"Ο","omicron":"ο","omid":"⦶","ominus":"⊖","Oopf":"𝕆","oopf":"𝕠","opar":"⦷","OpenCurlyDoubleQuote":"“","OpenCurlyQuote":"‘","operp":"⦹","oplus":"⊕","orarr":"↻","Or":"⩔","or":"∨","ord":"⩝","order":"ℴ","orderof":"ℴ","ordf":"ª","ordm":"º","origof":"⊶","oror":"⩖","orslope":"⩗","orv":"⩛","oS":"Ⓢ","Oscr":"𝒪","oscr":"ℴ","Oslash":"Ø","oslash":"ø","osol":"⊘","Otilde":"Õ","otilde":"õ","otimesas":"⨶","Otimes":"⨷","otimes":"⊗","Ouml":"Ö","ouml":"ö","ovbar":"⌽","OverBar":"‾","OverBrace":"⏞","OverBracket":"⎴","OverParenthesis":"⏜","para":"¶","parallel":"∥","par":"∥","parsim":"⫳","parsl":"⫽","part":"∂","PartialD":"∂","Pcy":"П","pcy":"п","percnt":"%","period":".","permil":"‰","perp":"⊥","pertenk":"‱","Pfr":"𝔓","pfr":"𝔭","Phi":"Φ","phi":"φ","phiv":"ϕ","phmmat":"ℳ","phone":"☎","Pi":"Π","pi":"π","pitchfork":"⋔","piv":"ϖ","planck":"ℏ","planckh":"ℎ","plankv":"ℏ","plusacir":"⨣","plusb":"⊞","pluscir":"⨢","plus":"+","plusdo":"∔","plusdu":"⨥","pluse":"⩲","PlusMinus":"±","plusmn":"±","plussim":"⨦","plustwo":"⨧","pm":"±","Poincareplane":"ℌ","pointint":"⨕","popf":"𝕡","Popf":"ℙ","pound":"£","prap":"⪷","Pr":"⪻","pr":"≺","prcue":"≼","precapprox":"⪷","prec":"≺","preccurlyeq":"≼","Precedes":"≺","PrecedesEqual":"⪯","PrecedesSlantEqual":"≼","PrecedesTilde":"≾","preceq":"⪯","precnapprox":"⪹","precneqq":"⪵","precnsim":"⋨","pre":"⪯","prE":"⪳","precsim":"≾","prime":"′","Prime":"″","primes":"ℙ","prnap":"⪹","prnE":"⪵","prnsim":"⋨","prod":"∏","Product":"∏","profalar":"⌮","profline":"⌒","profsurf":"⌓","prop":"∝","Proportional":"∝","Proportion":"∷","propto":"∝","prsim":"≾","prurel":"⊰","Pscr":"𝒫","pscr":"𝓅","Psi":"Ψ","psi":"ψ","puncsp":" ","Qfr":"𝔔","qfr":"𝔮","qint":"⨌","qopf":"𝕢","Qopf":"ℚ","qprime":"⁗","Qscr":"𝒬","qscr":"𝓆","quaternions":"ℍ","quatint":"⨖","quest":"?","questeq":"≟","quot":"\\"","QUOT":"\\"","rAarr":"⇛","race":"∽̱","Racute":"Ŕ","racute":"ŕ","radic":"√","raemptyv":"⦳","rang":"⟩","Rang":"⟫","rangd":"⦒","range":"⦥","rangle":"⟩","raquo":"»","rarrap":"⥵","rarrb":"⇥","rarrbfs":"⤠","rarrc":"⤳","rarr":"→","Rarr":"↠","rArr":"⇒","rarrfs":"⤞","rarrhk":"↪","rarrlp":"↬","rarrpl":"⥅","rarrsim":"⥴","Rarrtl":"⤖","rarrtl":"↣","rarrw":"↝","ratail":"⤚","rAtail":"⤜","ratio":"∶","rationals":"ℚ","rbarr":"⤍","rBarr":"⤏","RBarr":"⤐","rbbrk":"❳","rbrace":"}","rbrack":"]","rbrke":"⦌","rbrksld":"⦎","rbrkslu":"⦐","Rcaron":"Ř","rcaron":"ř","Rcedil":"Ŗ","rcedil":"ŗ","rceil":"⌉","rcub":"}","Rcy":"Р","rcy":"р","rdca":"⤷","rdldhar":"⥩","rdquo":"”","rdquor":"”","rdsh":"↳","real":"ℜ","realine":"ℛ","realpart":"ℜ","reals":"ℝ","Re":"ℜ","rect":"▭","reg":"®","REG":"®","ReverseElement":"∋","ReverseEquilibrium":"⇋","ReverseUpEquilibrium":"⥯","rfisht":"⥽","rfloor":"⌋","rfr":"𝔯","Rfr":"ℜ","rHar":"⥤","rhard":"⇁","rharu":"⇀","rharul":"⥬","Rho":"Ρ","rho":"ρ","rhov":"ϱ","RightAngleBracket":"⟩","RightArrowBar":"⇥","rightarrow":"→","RightArrow":"→","Rightarrow":"⇒","RightArrowLeftArrow":"⇄","rightarrowtail":"↣","RightCeiling":"⌉","RightDoubleBracket":"⟧","RightDownTeeVector":"⥝","RightDownVectorBar":"⥕","RightDownVector":"⇂","RightFloor":"⌋","rightharpoondown":"⇁","rightharpoonup":"⇀","rightleftarrows":"⇄","rightleftharpoons":"⇌","rightrightarrows":"⇉","rightsquigarrow":"↝","RightTeeArrow":"↦","RightTee":"⊢","RightTeeVector":"⥛","rightthreetimes":"⋌","RightTriangleBar":"⧐","RightTriangle":"⊳","RightTriangleEqual":"⊵","RightUpDownVector":"⥏","RightUpTeeVector":"⥜","RightUpVectorBar":"⥔","RightUpVector":"↾","RightVectorBar":"⥓","RightVector":"⇀","ring":"˚","risingdotseq":"≓","rlarr":"⇄","rlhar":"⇌","rlm":"‏","rmoustache":"⎱","rmoust":"⎱","rnmid":"⫮","roang":"⟭","roarr":"⇾","robrk":"⟧","ropar":"⦆","ropf":"𝕣","Ropf":"ℝ","roplus":"⨮","rotimes":"⨵","RoundImplies":"⥰","rpar":")","rpargt":"⦔","rppolint":"⨒","rrarr":"⇉","Rrightarrow":"⇛","rsaquo":"›","rscr":"𝓇","Rscr":"ℛ","rsh":"↱","Rsh":"↱","rsqb":"]","rsquo":"’","rsquor":"’","rthree":"⋌","rtimes":"⋊","rtri":"▹","rtrie":"⊵","rtrif":"▸","rtriltri":"⧎","RuleDelayed":"⧴","ruluhar":"⥨","rx":"℞","Sacute":"Ś","sacute":"ś","sbquo":"‚","scap":"⪸","Scaron":"Š","scaron":"š","Sc":"⪼","sc":"≻","sccue":"≽","sce":"⪰","scE":"⪴","Scedil":"Ş","scedil":"ş","Scirc":"Ŝ","scirc":"ŝ","scnap":"⪺","scnE":"⪶","scnsim":"⋩","scpolint":"⨓","scsim":"≿","Scy":"С","scy":"с","sdotb":"⊡","sdot":"⋅","sdote":"⩦","searhk":"⤥","searr":"↘","seArr":"⇘","searrow":"↘","sect":"§","semi":";","seswar":"⤩","setminus":"∖","setmn":"∖","sext":"✶","Sfr":"𝔖","sfr":"𝔰","sfrown":"⌢","sharp":"♯","SHCHcy":"Щ","shchcy":"щ","SHcy":"Ш","shcy":"ш","ShortDownArrow":"↓","ShortLeftArrow":"←","shortmid":"∣","shortparallel":"∥","ShortRightArrow":"→","ShortUpArrow":"↑","shy":"­","Sigma":"Σ","sigma":"σ","sigmaf":"ς","sigmav":"ς","sim":"∼","simdot":"⩪","sime":"≃","simeq":"≃","simg":"⪞","simgE":"⪠","siml":"⪝","simlE":"⪟","simne":"≆","simplus":"⨤","simrarr":"⥲","slarr":"←","SmallCircle":"∘","smallsetminus":"∖","smashp":"⨳","smeparsl":"⧤","smid":"∣","smile":"⌣","smt":"⪪","smte":"⪬","smtes":"⪬︀","SOFTcy":"Ь","softcy":"ь","solbar":"⌿","solb":"⧄","sol":"/","Sopf":"𝕊","sopf":"𝕤","spades":"♠","spadesuit":"♠","spar":"∥","sqcap":"⊓","sqcaps":"⊓︀","sqcup":"⊔","sqcups":"⊔︀","Sqrt":"√","sqsub":"⊏","sqsube":"⊑","sqsubset":"⊏","sqsubseteq":"⊑","sqsup":"⊐","sqsupe":"⊒","sqsupset":"⊐","sqsupseteq":"⊒","square":"□","Square":"□","SquareIntersection":"⊓","SquareSubset":"⊏","SquareSubsetEqual":"⊑","SquareSuperset":"⊐","SquareSupersetEqual":"⊒","SquareUnion":"⊔","squarf":"▪","squ":"□","squf":"▪","srarr":"→","Sscr":"𝒮","sscr":"𝓈","ssetmn":"∖","ssmile":"⌣","sstarf":"⋆","Star":"⋆","star":"☆","starf":"★","straightepsilon":"ϵ","straightphi":"ϕ","strns":"¯","sub":"⊂","Sub":"⋐","subdot":"⪽","subE":"⫅","sube":"⊆","subedot":"⫃","submult":"⫁","subnE":"⫋","subne":"⊊","subplus":"⪿","subrarr":"⥹","subset":"⊂","Subset":"⋐","subseteq":"⊆","subseteqq":"⫅","SubsetEqual":"⊆","subsetneq":"⊊","subsetneqq":"⫋","subsim":"⫇","subsub":"⫕","subsup":"⫓","succapprox":"⪸","succ":"≻","succcurlyeq":"≽","Succeeds":"≻","SucceedsEqual":"⪰","SucceedsSlantEqual":"≽","SucceedsTilde":"≿","succeq":"⪰","succnapprox":"⪺","succneqq":"⪶","succnsim":"⋩","succsim":"≿","SuchThat":"∋","sum":"∑","Sum":"∑","sung":"♪","sup1":"¹","sup2":"²","sup3":"³","sup":"⊃","Sup":"⋑","supdot":"⪾","supdsub":"⫘","supE":"⫆","supe":"⊇","supedot":"⫄","Superset":"⊃","SupersetEqual":"⊇","suphsol":"⟉","suphsub":"⫗","suplarr":"⥻","supmult":"⫂","supnE":"⫌","supne":"⊋","supplus":"⫀","supset":"⊃","Supset":"⋑","supseteq":"⊇","supseteqq":"⫆","supsetneq":"⊋","supsetneqq":"⫌","supsim":"⫈","supsub":"⫔","supsup":"⫖","swarhk":"⤦","swarr":"↙","swArr":"⇙","swarrow":"↙","swnwar":"⤪","szlig":"ß","Tab":"\\t","target":"⌖","Tau":"Τ","tau":"τ","tbrk":"⎴","Tcaron":"Ť","tcaron":"ť","Tcedil":"Ţ","tcedil":"ţ","Tcy":"Т","tcy":"т","tdot":"⃛","telrec":"⌕","Tfr":"𝔗","tfr":"𝔱","there4":"∴","therefore":"∴","Therefore":"∴","Theta":"Θ","theta":"θ","thetasym":"ϑ","thetav":"ϑ","thickapprox":"≈","thicksim":"∼","ThickSpace":"  ","ThinSpace":" ","thinsp":" ","thkap":"≈","thksim":"∼","THORN":"Þ","thorn":"þ","tilde":"˜","Tilde":"∼","TildeEqual":"≃","TildeFullEqual":"≅","TildeTilde":"≈","timesbar":"⨱","timesb":"⊠","times":"×","timesd":"⨰","tint":"∭","toea":"⤨","topbot":"⌶","topcir":"⫱","top":"⊤","Topf":"𝕋","topf":"𝕥","topfork":"⫚","tosa":"⤩","tprime":"‴","trade":"™","TRADE":"™","triangle":"▵","triangledown":"▿","triangleleft":"◃","trianglelefteq":"⊴","triangleq":"≜","triangleright":"▹","trianglerighteq":"⊵","tridot":"◬","trie":"≜","triminus":"⨺","TripleDot":"⃛","triplus":"⨹","trisb":"⧍","tritime":"⨻","trpezium":"⏢","Tscr":"𝒯","tscr":"𝓉","TScy":"Ц","tscy":"ц","TSHcy":"Ћ","tshcy":"ћ","Tstrok":"Ŧ","tstrok":"ŧ","twixt":"≬","twoheadleftarrow":"↞","twoheadrightarrow":"↠","Uacute":"Ú","uacute":"ú","uarr":"↑","Uarr":"↟","uArr":"⇑","Uarrocir":"⥉","Ubrcy":"Ў","ubrcy":"ў","Ubreve":"Ŭ","ubreve":"ŭ","Ucirc":"Û","ucirc":"û","Ucy":"У","ucy":"у","udarr":"⇅","Udblac":"Ű","udblac":"ű","udhar":"⥮","ufisht":"⥾","Ufr":"𝔘","ufr":"𝔲","Ugrave":"Ù","ugrave":"ù","uHar":"⥣","uharl":"↿","uharr":"↾","uhblk":"▀","ulcorn":"⌜","ulcorner":"⌜","ulcrop":"⌏","ultri":"◸","Umacr":"Ū","umacr":"ū","uml":"¨","UnderBar":"_","UnderBrace":"⏟","UnderBracket":"⎵","UnderParenthesis":"⏝","Union":"⋃","UnionPlus":"⊎","Uogon":"Ų","uogon":"ų","Uopf":"𝕌","uopf":"𝕦","UpArrowBar":"⤒","uparrow":"↑","UpArrow":"↑","Uparrow":"⇑","UpArrowDownArrow":"⇅","updownarrow":"↕","UpDownArrow":"↕","Updownarrow":"⇕","UpEquilibrium":"⥮","upharpoonleft":"↿","upharpoonright":"↾","uplus":"⊎","UpperLeftArrow":"↖","UpperRightArrow":"↗","upsi":"υ","Upsi":"ϒ","upsih":"ϒ","Upsilon":"Υ","upsilon":"υ","UpTeeArrow":"↥","UpTee":"⊥","upuparrows":"⇈","urcorn":"⌝","urcorner":"⌝","urcrop":"⌎","Uring":"Ů","uring":"ů","urtri":"◹","Uscr":"𝒰","uscr":"𝓊","utdot":"⋰","Utilde":"Ũ","utilde":"ũ","utri":"▵","utrif":"▴","uuarr":"⇈","Uuml":"Ü","uuml":"ü","uwangle":"⦧","vangrt":"⦜","varepsilon":"ϵ","varkappa":"ϰ","varnothing":"∅","varphi":"ϕ","varpi":"ϖ","varpropto":"∝","varr":"↕","vArr":"⇕","varrho":"ϱ","varsigma":"ς","varsubsetneq":"⊊︀","varsubsetneqq":"⫋︀","varsupsetneq":"⊋︀","varsupsetneqq":"⫌︀","vartheta":"ϑ","vartriangleleft":"⊲","vartriangleright":"⊳","vBar":"⫨","Vbar":"⫫","vBarv":"⫩","Vcy":"В","vcy":"в","vdash":"⊢","vDash":"⊨","Vdash":"⊩","VDash":"⊫","Vdashl":"⫦","veebar":"⊻","vee":"∨","Vee":"⋁","veeeq":"≚","vellip":"⋮","verbar":"|","Verbar":"‖","vert":"|","Vert":"‖","VerticalBar":"∣","VerticalLine":"|","VerticalSeparator":"❘","VerticalTilde":"≀","VeryThinSpace":" ","Vfr":"𝔙","vfr":"𝔳","vltri":"⊲","vnsub":"⊂⃒","vnsup":"⊃⃒","Vopf":"𝕍","vopf":"𝕧","vprop":"∝","vrtri":"⊳","Vscr":"𝒱","vscr":"𝓋","vsubnE":"⫋︀","vsubne":"⊊︀","vsupnE":"⫌︀","vsupne":"⊋︀","Vvdash":"⊪","vzigzag":"⦚","Wcirc":"Ŵ","wcirc":"ŵ","wedbar":"⩟","wedge":"∧","Wedge":"⋀","wedgeq":"≙","weierp":"℘","Wfr":"𝔚","wfr":"𝔴","Wopf":"𝕎","wopf":"𝕨","wp":"℘","wr":"≀","wreath":"≀","Wscr":"𝒲","wscr":"𝓌","xcap":"⋂","xcirc":"◯","xcup":"⋃","xdtri":"▽","Xfr":"𝔛","xfr":"𝔵","xharr":"⟷","xhArr":"⟺","Xi":"Ξ","xi":"ξ","xlarr":"⟵","xlArr":"⟸","xmap":"⟼","xnis":"⋻","xodot":"⨀","Xopf":"𝕏","xopf":"𝕩","xoplus":"⨁","xotime":"⨂","xrarr":"⟶","xrArr":"⟹","Xscr":"𝒳","xscr":"𝓍","xsqcup":"⨆","xuplus":"⨄","xutri":"△","xvee":"⋁","xwedge":"⋀","Yacute":"Ý","yacute":"ý","YAcy":"Я","yacy":"я","Ycirc":"Ŷ","ycirc":"ŷ","Ycy":"Ы","ycy":"ы","yen":"¥","Yfr":"𝔜","yfr":"𝔶","YIcy":"Ї","yicy":"ї","Yopf":"𝕐","yopf":"𝕪","Yscr":"𝒴","yscr":"𝓎","YUcy":"Ю","yucy":"ю","yuml":"ÿ","Yuml":"Ÿ","Zacute":"Ź","zacute":"ź","Zcaron":"Ž","zcaron":"ž","Zcy":"З","zcy":"з","Zdot":"Ż","zdot":"ż","zeetrf":"ℨ","ZeroWidthSpace":"​","Zeta":"Ζ","zeta":"ζ","zfr":"𝔷","Zfr":"ℨ","ZHcy":"Ж","zhcy":"ж","zigrarr":"⇝","zopf":"𝕫","Zopf":"ℤ","Zscr":"𝒵","zscr":"𝓏","zwj":"‍","zwnj":"‌"}')},function(e){e.exports=JSON.parse('{"Aacute":"Á","aacute":"á","Acirc":"Â","acirc":"â","acute":"´","AElig":"Æ","aelig":"æ","Agrave":"À","agrave":"à","amp":"&","AMP":"&","Aring":"Å","aring":"å","Atilde":"Ã","atilde":"ã","Auml":"Ä","auml":"ä","brvbar":"¦","Ccedil":"Ç","ccedil":"ç","cedil":"¸","cent":"¢","copy":"©","COPY":"©","curren":"¤","deg":"°","divide":"÷","Eacute":"É","eacute":"é","Ecirc":"Ê","ecirc":"ê","Egrave":"È","egrave":"è","ETH":"Ð","eth":"ð","Euml":"Ë","euml":"ë","frac12":"½","frac14":"¼","frac34":"¾","gt":">","GT":">","Iacute":"Í","iacute":"í","Icirc":"Î","icirc":"î","iexcl":"¡","Igrave":"Ì","igrave":"ì","iquest":"¿","Iuml":"Ï","iuml":"ï","laquo":"«","lt":"<","LT":"<","macr":"¯","micro":"µ","middot":"·","nbsp":" ","not":"¬","Ntilde":"Ñ","ntilde":"ñ","Oacute":"Ó","oacute":"ó","Ocirc":"Ô","ocirc":"ô","Ograve":"Ò","ograve":"ò","ordf":"ª","ordm":"º","Oslash":"Ø","oslash":"ø","Otilde":"Õ","otilde":"õ","Ouml":"Ö","ouml":"ö","para":"¶","plusmn":"±","pound":"£","quot":"\\"","QUOT":"\\"","raquo":"»","reg":"®","REG":"®","sect":"§","shy":"­","sup1":"¹","sup2":"²","sup3":"³","szlig":"ß","THORN":"Þ","thorn":"þ","times":"×","Uacute":"Ú","uacute":"ú","Ucirc":"Û","ucirc":"û","Ugrave":"Ù","ugrave":"ù","uml":"¨","Uuml":"Ü","uuml":"ü","Yacute":"Ý","yacute":"ý","yen":"¥","yuml":"ÿ"}')},function(e){e.exports=JSON.parse('{"amp":"&","apos":"\'","gt":">","lt":"<","quot":"\\""}')},function(e,t,r){"use strict";var n,i=this&&this.__extends||(n=function(e,t){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var a=new Map([["tag",1],["script",1],["style",1],["directive",1],["text",3],["cdata",4],["comment",8]]),o=function(){function e(e){this.type=e,this.parent=null,this.prev=null,this.next=null,this.startIndex=null,this.endIndex=null}return Object.defineProperty(e.prototype,"nodeType",{get:function(){return a.get(this.type)||1},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"parentNode",{get:function(){return this.parent||null},set:function(e){this.parent=e},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"previousSibling",{get:function(){return this.prev||null},set:function(e){this.prev=e},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"nextSibling",{get:function(){return this.next||null},set:function(e){this.next=e},enumerable:!0,configurable:!0}),e}();t.Node=o;var s=function(e){function t(t,r){var n=e.call(this,t)||this;return n.data=r,n}return i(t,e),Object.defineProperty(t.prototype,"nodeValue",{get:function(){return this.data},set:function(e){this.data=e},enumerable:!0,configurable:!0}),t}(o);t.DataNode=s;var c=function(e){function t(t,r){var n=e.call(this,"directive",r)||this;return n.name=t,n}return i(t,e),t}(s);t.ProcessingInstruction=c;var u=function(e){function t(t,r){var n=e.call(this,t)||this;return n.children=r,n}return i(t,e),Object.defineProperty(t.prototype,"firstChild",{get:function(){return this.children[0]||null},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"lastChild",{get:function(){return this.children[this.children.length-1]||null},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"childNodes",{get:function(){return this.children},set:function(e){this.children=e},enumerable:!0,configurable:!0}),t}(o);t.NodeWithChildren=u;var l=function(e){function t(t,r){var n=e.call(this,"script"===t?"script":"style"===t?"style":"tag",[])||this;return n.name=t,n.attribs=r,n.attribs=r,n}return i(t,e),Object.defineProperty(t.prototype,"tagName",{get:function(){return this.name},set:function(e){this.name=e},enumerable:!0,configurable:!0}),t}(u);t.Element=l},function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var i=r(55),a=n(r(170));t.getOuterHTML=a.default,t.getInnerHTML=function(e,r){return i.hasChildren(e)?e.children.map(function(e){return t.getOuterHTML(e,r)}).join(""):""},t.getText=function e(t){return Array.isArray(t)?t.map(e).join(""):i.isTag(t)?"br"===t.name?"\n":e(t.children):i.isCDATA(t)?e(t.children):i.isText(t)?t.data:""}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isTag=function(e){return"tag"===e.type||"script"===e.type||"style"===e.type},t.Text="text",t.Directive="directive",t.Comment="comment",t.Script="script",t.Style="style",t.Tag="tag",t.CDATA="cdata",t.Doctype="doctype"},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(171),i=r(174);t.decode=function(e,t){return(!t||t<=0?n.decodeXML:n.decodeHTML)(e)},t.decodeStrict=function(e,t){return(!t||t<=0?n.decodeXML:n.decodeHTMLStrict)(e)},t.encode=function(e,t){return(!t||t<=0?i.encodeXML:i.encodeHTML)(e)};var a=r(174);t.encodeXML=a.encodeXML,t.encodeHTML=a.encodeHTML,t.escape=a.escape,t.encodeHTML4=a.encodeHTML,t.encodeHTML5=a.encodeHTML;var o=r(171);t.decodeXML=o.decodeXML,t.decodeHTML=o.decodeHTML,t.decodeHTMLStrict=o.decodeHTMLStrict,t.decodeHTML4=o.decodeHTML,t.decodeHTML5=o.decodeHTML,t.decodeHTML4Strict=o.decodeHTMLStrict,t.decodeHTML5Strict=o.decodeHTMLStrict,t.decodeXMLStrict=o.decodeXML},function(e){e.exports=JSON.parse('{"Aacute":"Á","aacute":"á","Acirc":"Â","acirc":"â","acute":"´","AElig":"Æ","aelig":"æ","Agrave":"À","agrave":"à","amp":"&","AMP":"&","Aring":"Å","aring":"å","Atilde":"Ã","atilde":"ã","Auml":"Ä","auml":"ä","brvbar":"¦","Ccedil":"Ç","ccedil":"ç","cedil":"¸","cent":"¢","copy":"©","COPY":"©","curren":"¤","deg":"°","divide":"÷","Eacute":"É","eacute":"é","Ecirc":"Ê","ecirc":"ê","Egrave":"È","egrave":"è","ETH":"Ð","eth":"ð","Euml":"Ë","euml":"ë","frac12":"½","frac14":"¼","frac34":"¾","gt":">","GT":">","Iacute":"Í","iacute":"í","Icirc":"Î","icirc":"î","iexcl":"¡","Igrave":"Ì","igrave":"ì","iquest":"¿","Iuml":"Ï","iuml":"ï","laquo":"«","lt":"<","LT":"<","macr":"¯","micro":"µ","middot":"·","nbsp":" ","not":"¬","Ntilde":"Ñ","ntilde":"ñ","Oacute":"Ó","oacute":"ó","Ocirc":"Ô","ocirc":"ô","Ograve":"Ò","ograve":"ò","ordf":"ª","ordm":"º","Oslash":"Ø","oslash":"ø","Otilde":"Õ","otilde":"õ","Ouml":"Ö","ouml":"ö","para":"","plusmn":"±","pound":"£","quot":"\\"","QUOT":"\\"","raquo":"»","reg":"®","REG":"®","sect":"§","shy":"­","sup1":"¹","sup2":"²","sup3":"³","szlig":"ß","THORN":"Þ","thorn":"þ","times":"×","Uacute":"Ú","uacute":"ú","Ucirc":"Û","ucirc":"û","Ugrave":"Ù","ugrave":"ù","uml":"¨","Uuml":"Ü","uuml":"ü","Yacute":"Ý","yacute":"ý","yen":"¥","yuml":"ÿ"}')},function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var i=n(r(396));t.default=function(e){if(e>=55296&&e<=57343||e>1114111)return"";e in i.default&&(e=i.default[e]);var t="";return e>65535&&(e-=65536,t+=String.fromCharCode(e>>>10&1023|55296),e=56320|1023&e),t+=String.fromCharCode(e)}},function(e){e.exports=JSON.parse('{"0":65533,"128":8364,"130":8218,"131":402,"132":8222,"133":8230,"134":8224,"135":8225,"136":710,"137":8240,"138":352,"139":8249,"140":338,"142":381,"145":8216,"146":8217,"147":8220,"148":8221,"149":8226,"150":8211,"151":8212,"152":732,"153":8482,"154":353,"155":8250,"156":339,"158":382,"159":376}')},function(e){e.exports=JSON.parse('{"elementNames":{"altglyph":"altGlyph","altglyphdef":"altGlyphDef","altglyphitem":"altGlyphItem","animatecolor":"animateColor","animatemotion":"animateMotion","animatetransform":"animateTransform","clippath":"clipPath","feblend":"feBlend","fecolormatrix":"feColorMatrix","fecomponenttransfer":"feComponentTransfer","fecomposite":"feComposite","feconvolvematrix":"feConvolveMatrix","fediffuselighting":"feDiffuseLighting","fedisplacementmap":"feDisplacementMap","fedistantlight":"feDistantLight","fedropshadow":"feDropShadow","feflood":"feFlood","fefunca":"feFuncA","fefuncb":"feFuncB","fefuncg":"feFuncG","fefuncr":"feFuncR","fegaussianblur":"feGaussianBlur","feimage":"feImage","femerge":"feMerge","femergenode":"feMergeNode","femorphology":"feMorphology","feoffset":"feOffset","fepointlight":"fePointLight","fespecularlighting":"feSpecularLighting","fespotlight":"feSpotLight","fetile":"feTile","feturbulence":"feTurbulence","foreignobject":"foreignObject","glyphref":"glyphRef","lineargradient":"linearGradient","radialgradient":"radialGradient","textpath":"textPath"},"attributeNames":{"definitionurl":"definitionURL","attributename":"attributeName","attributetype":"attributeType","basefrequency":"baseFrequency","baseprofile":"baseProfile","calcmode":"calcMode","clippathunits":"clipPathUnits","diffuseconstant":"diffuseConstant","edgemode":"edgeMode","filterunits":"filterUnits","glyphref":"glyphRef","gradienttransform":"gradientTransform","gradientunits":"gradientUnits","kernelmatrix":"kernelMatrix","kernelunitlength":"kernelUnitLength","keypoints":"keyPoints","keysplines":"keySplines","keytimes":"keyTimes","lengthadjust":"lengthAdjust","limitingconeangle":"limitingConeAngle","markerheight":"markerHeight","markerunits":"markerUnits","markerwidth":"markerWidth","maskcontentunits":"maskContentUnits","maskunits":"maskUnits","numoctaves":"numOctaves","pathlength":"pathLength","patterncontentunits":"patternContentUnits","patterntransform":"patternTransform","patternunits":"patternUnits","pointsatx":"pointsAtX","pointsaty":"pointsAtY","pointsatz":"pointsAtZ","preservealpha":"preserveAlpha","preserveaspectratio":"preserveAspectRatio","primitiveunits":"primitiveUnits","refx":"refX","refy":"refY","repeatcount":"repeatCount","repeatdur":"repeatDur","requiredextensions":"requiredExtensions","requiredfeatures":"requiredFeatures","specularconstant":"specularConstant","specularexponent":"specularExponent","spreadmethod":"spreadMethod","startoffset":"startOffset","stddeviation":"stdDeviation","stitchtiles":"stitchTiles","surfacescale":"surfaceScale","systemlanguage":"systemLanguage","tablevalues":"tableValues","targetx":"targetX","targety":"targetY","textlength":"textLength","viewbox":"viewBox","viewtarget":"viewTarget","xchannelselector":"xChannelSelector","ychannelselector":"yChannelSelector","zoomandpan":"zoomAndPan"}}')},function(e,t,r){"use strict";function n(e){return e.children||null}function i(e){return e.parent||null}function a(e,t){return e.attribs&&e.attribs[t]}Object.defineProperty(t,"__esModule",{value:!0}),t.getChildren=n,t.getParent=i,t.getSiblings=function(e){var t=i(e);return t?n(t):[e]},t.getAttributeValue=a,t.hasAttrib=function(e,t){return!!a(e,t)},t.getName=function(e){return e.name}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.removeElement=function(e){if(e.prev&&(e.prev.next=e.next),e.next&&(e.next.prev=e.prev),e.parent){var t=e.parent.children;t.splice(t.lastIndexOf(e),1)}},t.replaceElement=function(e,t){var r=t.prev=e.prev;r&&(r.next=t);var n=t.next=e.next;n&&(n.prev=t);var i=t.parent=e.parent;if(i){var a=i.children;a[a.lastIndexOf(e)]=t}},t.appendChild=function(e,t){if(t.parent=e,1!==e.children.push(t)){var r=e.children[e.children.length-2];r.next=t,t.prev=r,t.next=null}},t.append=function(e,t){var r=e.parent,n=e.next;if(t.next=n,t.prev=e,e.next=t,t.parent=r,n){if(n.prev=t,r){var i=r.children;i.splice(i.lastIndexOf(n),0,t)}}else r&&r.children.push(t)},t.prepend=function(e,t){var r=e.parent;if(r){var n=r.children;n.splice(n.lastIndexOf(e),0,t)}e.prev&&(e.prev.next=t),t.parent=r,t.prev=e.prev,t.next=e,e.prev=t}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(175),i=r(55);function a(e){return"text"===e.type}var o={tag_name:function(e){return"function"==typeof e?function(t){return i.isTag(t)&&e(t.name)}:"*"===e?i.isTag:function(t){return i.isTag(t)&&t.name===e}},tag_type:function(e){return"function"==typeof e?function(t){return e(t.type)}:function(t){return t.type===e}},tag_contains:function(e){return"function"==typeof e?function(t){return a(t)&&e(t.data)}:function(t){return a(t)&&t.data===e}}};function s(e,t){return"function"==typeof t?function(r){return i.isTag(r)&&t(r.attribs[e])}:function(r){return i.isTag(r)&&r.attribs[e]===t}}function c(e,t){return function(r){return e(r)||t(r)}}function u(e){var t=Object.keys(e).map(function(t){var r=e[t];return t in o?o[t](r):s(t,r)});return 0===t.length?null:t.reduce(c)}t.testElement=function(e,t){var r=u(e);return!r||r(t)},t.getElements=function(e,t,r,i){void 0===i&&(i=1/0);var a=u(e);return a?n.filter(a,t,r,i):[]},t.getElementById=function(e,t,r){return void 0===r&&(r=!0),Array.isArray(t)||(t=[t]),n.findOne(s("id",e),t,r)},t.getElementsByTagName=function(e,t,r,i){return void 0===i&&(i=1/0),n.filter(o.tag_name(e),t,r,i)},t.getElementsByTagType=function(e,t,r,i){return void 0===r&&(r=!0),void 0===i&&(i=1/0),n.filter(o.tag_type(e),t,r,i)}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(55);function i(e,t){var r=[],i=[];if(e===t)return 0;for(var a=n.hasChildren(e)?e:e.parent;a;)r.unshift(a),a=a.parent;for(a=n.hasChildren(t)?t:t.parent;a;)i.unshift(a),a=a.parent;for(var o=0;r[o]===i[o];)o++;if(0===o)return 1;var s=r[o-1],c=s.children,u=r[o],l=i[o];return c.indexOf(u)>c.indexOf(l)?s===t?20:4:s===e?10:2}t.removeSubsets=function(e){for(var t=e.length;--t>=0;){var r=e[t];if(t>0&&e.lastIndexOf(r,t-1)>=0)e.splice(t,1);else for(var n=r.parent;n;n=n.parent)if(e.indexOf(n)>-1){e.splice(t,1);break}}return e},t.compareDocumentPosition=i,t.uniqueSort=function(e){return(e=e.filter(function(e,t,r){return!r.includes(e,t+1)})).sort(function(e,t){var r=i(e,t);return 2&r?-1:4&r?1:0}),e}},function(e,t){},function(e,t,r){"use strict";var n,i=this&&this.__extends||(n=function(e,t){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)}),a=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var o=function(e){function t(t){void 0===t&&(t={});var r=e.call(this,function(e){for(var t,n=[],i=1;i<arguments.length;i++)n[i-1]=arguments[i];r.events.push([e].concat(n)),r._cbs[e]&&(t=r._cbs)[e].apply(t,n)})||this;return r._cbs=t,r.events=[],r}return i(t,e),t.prototype.onreset=function(){this.events=[],this._cbs.onreset&&this._cbs.onreset()},t.prototype.restart=function(){var e;this._cbs.onreset&&this._cbs.onreset();for(var t=0;t<this.events.length;t++){var r=this.events[t],n=r[0],i=r.slice(1);this._cbs[n]&&(e=this._cbs)[n].apply(e,i)}},t}(a(r(404)).default);t.CollectingHandler=o},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=function(){function e(e){this._func=e}return e.prototype.onattribute=function(e,t){this._func("onattribute",e,t)},e.prototype.oncdatastart=function(){this._func("oncdatastart")},e.prototype.oncdataend=function(){this._func("oncdataend")},e.prototype.ontext=function(e){this._func("ontext",e)},e.prototype.onprocessinginstruction=function(e,t){this._func("onprocessinginstruction",e,t)},e.prototype.oncomment=function(e){this._func("oncomment",e)},e.prototype.oncommentend=function(){this._func("oncommentend")},e.prototype.onclosetag=function(e){this._func("onclosetag",e)},e.prototype.onopentag=function(e,t){this._func("onopentag",e,t)},e.prototype.onopentagname=function(e){this._func("onopentagname",e)},e.prototype.onerror=function(e){this._func("onerror",e)},e.prototype.onend=function(){this._func("onend")},e.prototype.onparserinit=function(e){this._func("onparserinit",e)},e.prototype.onreset=function(){this._func("onreset")},e}();t.default=n},function(e){e.exports=JSON.parse('{"@context":{"alternate":"http://www.w3.org/1999/xhtml/vocab#alternate","appendix":"http://www.w3.org/1999/xhtml/vocab#appendix","cite":"http://www.w3.org/1999/xhtml/vocab#cite","bookmark":"http://www.w3.org/1999/xhtml/vocab#bookmark","contents":"http://www.w3.org/1999/xhtml/vocab#contents","chapter":"http://www.w3.org/1999/xhtml/vocab#chapter","copyright":"http://www.w3.org/1999/xhtml/vocab#copyright","first":"http://www.w3.org/1999/xhtml/vocab#first","glossary":"http://www.w3.org/1999/xhtml/vocab#glossary","help":"http://www.w3.org/1999/xhtml/vocab#help","icon":"http://www.w3.org/1999/xhtml/vocab#icon","index":"http://www.w3.org/1999/xhtml/vocab#index","last":"http://www.w3.org/1999/xhtml/vocab#last","license":"http://www.w3.org/1999/xhtml/vocab#license","meta":"http://www.w3.org/1999/xhtml/vocab#meta","next":"http://www.w3.org/1999/xhtml/vocab#next","prev":"http://www.w3.org/1999/xhtml/vocab#prev","previous":"http://www.w3.org/1999/xhtml/vocab#previous","section":"http://www.w3.org/1999/xhtml/vocab#section","start":"http://www.w3.org/1999/xhtml/vocab#start","stylesheet":"http://www.w3.org/1999/xhtml/vocab#stylesheet","subsection":"http://www.w3.org/1999/xhtml/vocab#subsection","top":"http://www.w3.org/1999/xhtml/vocab#top","up":"http://www.w3.org/1999/xhtml/vocab#up","p3pv1":"http://www.w3.org/1999/xhtml/vocab#p3pv1"}}')},function(e){e.exports=JSON.parse('{"@context":{"as":"https://www.w3.org/ns/activitystreams#","cat":"http://www.w3.org/ns/dcat#","cc":"http://creativecommons.org/ns#","cnt":"http://www.w3.org/2008/content#","csvw":"http://www.w3.org/ns/csvw#","ctag":"http://commontag.org/ns#","dc":"http://purl.org/dc/terms/","dc11":"http://purl.org/dc/elements/1.1/","dcat":"http://www.w3.org/ns/dcat#","dcterms":"http://purl.org/dc/terms/","dqv":"http://www.w3.org/ns/dqv#","duv":"https://www.w3.org/TR/vocab-duv#","earl":"http://www.w3.org/ns/earl#","foaf":"http://xmlns.com/foaf/0.1/","gldp":"http://www.w3.org/ns/people#","gr":"http://purl.org/goodrelations/v1#","grddl":"http://www.w3.org/2003/g/data-view#","ht":"http://www.w3.org/2006/http#","ical":"http://www.w3.org/2002/12/cal/icaltzd#","ldp":"http://www.w3.org/ns/ldp#","ma":"http://www.w3.org/ns/ma-ont#","oa":"http://www.w3.org/ns/oa#","odrl":"http://www.w3.org/ns/odrl/2/","og":"http://ogp.me/ns#","org":"http://www.w3.org/ns/org#","owl":"http://www.w3.org/2002/07/owl#","prov":"http://www.w3.org/ns/prov#","ptr":"http://www.w3.org/2009/pointers#","qb":"http://purl.org/linked-data/cube#","rev":"http://purl.org/stuff/rev#","rdf":"http://www.w3.org/1999/02/22-rdf-syntax-ns#","rdfa":"http://www.w3.org/ns/rdfa#","rdfs":"http://www.w3.org/2000/01/rdf-schema#","rif":"http://www.w3.org/2007/rif#","rr":"http://www.w3.org/ns/r2rml#","schema":"http://schema.org/","sd":"http://www.w3.org/ns/sparql-service-description#","sioc":"http://rdfs.org/sioc/ns#","skos":"http://www.w3.org/2004/02/skos/core#","skosxl":"http://www.w3.org/2008/05/skos-xl#","ssn":"http://www.w3.org/ns/ssn/","sosa":"http://www.w3.org/ns/sosa/","time":"http://www.w3.org/2006/time#","v":"http://rdf.data-vocabulary.org/#","vcard":"http://www.w3.org/2006/vcard/ns#","void":"http://rdfs.org/ns/void#","wdr":"http://www.w3.org/2007/05/powder#","wdrs":"http://www.w3.org/2007/05/powder-s#","xhv":"http://www.w3.org/1999/xhtml/vocab#","xml":"http://www.w3.org/XML/1998/namespace","xsd":"http://www.w3.org/2001/XMLSchema#","describedby":"http://www.w3.org/2007/05/powder-s#describedby","license":"http://www.w3.org/1999/xhtml/vocab#license","role":"http://www.w3.org/1999/xhtml/vocab#role"}}')},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(52),i=r(70),a=r(3);t.ActorRdfParseHtml=class extends n.ActorRdfParseFixedMediaTypes{constructor(e){super(e)}async runHandle(e,t,r){const n=new a.Readable({objectMode:!0});return n._read=async()=>{n._read=null;let t=1;const a=e=>n.emit("error",e),o=()=>{0==--t&&n.push(null)},s={baseIRI:e.baseIRI,context:r,emit:e=>n.emit("data",e),end:o,error:a,headers:e.headers};Promise.all(this.busRdfParseHtml.publish(s)).then(async r=>{t+=r.length;const n=[];for(const e of r){const{htmlParseListener:t}=await e.actor.run(s);n.push(t)}const c=new i.Parser({onclosetag:()=>{for(const e of n)e.onTagClose()},onend:()=>{for(const e of n)e.onEnd();o()},onopentag:(e,t)=>{for(const r of n)r.onTagOpen(e,t)},ontext:e=>{for(const t of n)t.onText(e)}},{decodeEntities:!0,recognizeSelfClosing:!0,xmlMode:!1});e.input.on("error",a),e.input.pipe(c)})},{quads:n}}}},function(e,t,r){var n=r(409);e.exports=function(e){if(e>=55296&&e<=57343||e>1114111)return"";e in n&&(e=n[e]);var t="";e>65535&&(e-=65536,t+=String.fromCharCode(e>>>10&1023|55296),e=56320|1023&e);return t+=String.fromCharCode(e)}},function(e){e.exports=JSON.parse('{"0":65533,"128":8364,"130":8218,"131":402,"132":8222,"133":8230,"134":8224,"135":8225,"136":710,"137":8240,"138":352,"139":8249,"140":338,"142":381,"145":8216,"146":8217,"147":8220,"148":8221,"149":8226,"150":8211,"151":8212,"152":732,"153":8482,"154":353,"155":8250,"156":339,"158":382,"159":376}')},function(e){e.exports=JSON.parse('{"Aacute":"Á","aacute":"á","Abreve":"Ă","abreve":"ă","ac":"","acd":"","acE":"∾̳","Acirc":"Â","acirc":"â","acute":"´","Acy":"А","acy":"а","AElig":"Æ","aelig":"æ","af":"","Afr":"𝔄","afr":"𝔞","Agrave":"À","agrave":"à","alefsym":"","aleph":"","Alpha":"Α","alpha":"α","Amacr":"Ā","amacr":"ā","amalg":"⨿","amp":"&","AMP":"&","andand":"","And":"","and":"","andd":"","andslope":"","andv":"","ang":"","ange":"","angle":"","angmsdaa":"","angmsdab":"","angmsdac":"","angmsdad":"","angmsdae":"","angmsdaf":"","angmsdag":"","angmsdah":"","angmsd":"","angrt":"","angrtvb":"","angrtvbd":"","angsph":"","angst":"Å","angzarr":"","Aogon":"Ą","aogon":"ą","Aopf":"𝔸","aopf":"𝕒","apacir":"","ap":"","apE":"","ape":"","apid":"","apos":"\'","ApplyFunction":"⁡","approx":"≈","approxeq":"≊","Aring":"Å","aring":"å","Ascr":"𝒜","ascr":"𝒶","Assign":"≔","ast":"*","asymp":"≈","asympeq":"≍","Atilde":"Ã","atilde":"ã","Auml":"Ä","auml":"ä","awconint":"∳","awint":"⨑","backcong":"≌","backepsilon":"϶","backprime":"‵","backsim":"∽","backsimeq":"⋍","Backslash":"∖","Barv":"⫧","barvee":"⊽","barwed":"⌅","Barwed":"⌆","barwedge":"⌅","bbrk":"⎵","bbrktbrk":"⎶","bcong":"≌","Bcy":"Б","bcy":"б","bdquo":"„","becaus":"∵","because":"∵","Because":"∵","bemptyv":"⦰","bepsi":"϶","bernou":"ℬ","Bernoullis":"ℬ","Beta":"Β","beta":"β","beth":"ℶ","between":"≬","Bfr":"𝔅","bfr":"𝔟","bigcap":"⋂","bigcirc":"◯","bigcup":"⋃","bigodot":"⨀","bigoplus":"⨁","bigotimes":"⨂","bigsqcup":"⨆","bigstar":"★","bigtriangledown":"▽","bigtriangleup":"△","biguplus":"⨄","bigvee":"⋁","bigwedge":"⋀","bkarow":"⤍","blacklozenge":"⧫","blacksquare":"▪","blacktriangle":"▴","blacktriangledown":"▾","blacktriangleleft":"◂","blacktriangleright":"▸","blank":"␣","blk12":"▒","blk14":"░","blk34":"▓","block":"█","bne":"=⃥","bnequiv":"≡⃥","bNot":"⫭","bnot":"⌐","Bopf":"𝔹","bopf":"𝕓","bot":"⊥","bottom":"⊥","bowtie":"⋈","boxbox":"⧉","boxdl":"┐","boxdL":"╕","boxDl":"╖","boxDL":"╗","boxdr":"┌","boxdR":"╒","boxDr":"╓","boxDR":"╔","boxh":"─","boxH":"═","boxhd":"┬","boxHd":"╤","boxhD":"╥","boxHD":"╦","boxhu":"┴","boxHu":"╧","boxhU":"╨","boxHU":"╩","boxminus":"⊟","boxplus":"⊞","boxtimes":"⊠","boxul":"┘","boxuL":"╛","boxUl":"╜","boxUL":"╝","boxur":"└","boxuR":"╘","boxUr":"╙","boxUR":"╚","boxv":"│","boxV":"║","boxvh":"┼","boxvH":"╪","boxVh":"╫","boxVH":"╬","boxvl":"┤","boxvL":"╡","boxVl":"╢","boxVL":"╣","boxvr":"├","boxvR":"╞","boxVr":"╟","boxVR":"╠","bprime":"‵","breve":"˘","Breve":"˘","brvbar":"¦","bscr":"𝒷","Bscr":"ℬ","bsemi":"⁏","bsim":"∽","bsime":"⋍","bsolb":"⧅","bsol":"\\\\","bsolhsub":"⟈","bull":"•","bullet":"•","bump":"≎","bumpE":"⪮","bumpe":"≏","Bumpeq":"≎","bumpeq":"≏","Cacute":"Ć","cacute":"ć","capand":"⩄","capbrcup":"⩉","capcap":"⩋","cap":"∩","Cap":"⋒","capcup":"⩇","capdot":"⩀","CapitalDifferentialD":"ⅅ","caps":"∩︀","caret":"⁁","caron":"ˇ","Cayleys":"ℭ","ccaps":"⩍","Ccaron":"Č","ccaron":"č","Ccedil":"Ç","ccedil":"ç","Ccirc":"Ĉ","ccirc":"ĉ","Cconint":"∰","ccups":"⩌","ccupssm":"⩐","Cdot":"Ċ","cdot":"ċ","cedil":"¸","Cedilla":"¸","cemptyv":"⦲","cent":"¢","centerdot":"·","CenterDot":"·","cfr":"𝔠","Cfr":"ℭ","CHcy":"Ч","chcy":"ч","check":"✓","checkmark":"✓","Chi":"Χ","chi":"χ","circ":"ˆ","circeq":"≗","circlearrowleft":"↺","circlearrowright":"↻","circledast":"⊛","circledcirc":"⊚","circleddash":"⊝","CircleDot":"⊙","circledR":"®","circledS":"Ⓢ","CircleMinus":"⊖","CirclePlus":"⊕","CircleTimes":"⊗","cir":"○","cirE":"⧃","cire":"≗","cirfnint":"⨐","cirmid":"⫯","cirscir":"⧂","ClockwiseContourIntegral":"∲","CloseCurlyDoubleQuote":"”","CloseCurlyQuote":"’","clubs":"♣","clubsuit":"♣","colon":":","Colon":"∷","Colone":"⩴","colone":"≔","coloneq":"≔","comma":",","commat":"@","comp":"∁","compfn":"∘","complement":"∁","complexes":"ℂ","cong":"≅","congdot":"⩭","Congruent":"≡","conint":"∮","Conint":"∯","ContourIntegral":"∮","copf":"𝕔","Copf":"ℂ","coprod":"∐","Coproduct":"∐","copy":"©","COPY":"©","copysr":"℗","CounterClockwiseContourIntegral":"∳","crarr":"↵","cross":"✗","Cross":"⨯","Cscr":"𝒞","cscr":"𝒸","csub":"⫏","csube":"⫑","csup":"⫐","csupe":"⫒","ctdot":"⋯","cudarrl":"⤸","cudarrr":"⤵","cuepr":"⋞","cuesc":"⋟","cularr":"↶","cularrp":"⤽","cupbrcap":"⩈","cupcap":"⩆","CupCap":"≍","cup":"∪","Cup":"⋓","cupcup":"⩊","cupdot":"⊍","cupor":"⩅","cups":"∪︀","curarr":"↷","curarrm":"⤼","curlyeqprec":"⋞","curlyeqsucc":"⋟","curlyvee":"⋎","curlywedge":"⋏","curren":"¤","curvearrowleft":"↶","curvearrowright":"↷","cuvee":"⋎","cuwed":"⋏","cwconint":"∲","cwint":"∱","cylcty":"⌭","dagger":"†","Dagger":"‡","daleth":"ℸ","darr":"↓","Darr":"↡","dArr":"⇓","dash":"‐","Dashv":"⫤","dashv":"⊣","dbkarow":"⤏","dblac":"˝","Dcaron":"Ď","dcaron":"ď","Dcy":"Д","dcy":"д","ddagger":"‡","ddarr":"⇊","DD":"ⅅ","dd":"ⅆ","DDotrahd":"⤑","ddotseq":"⩷","deg":"°","Del":"∇","Delta":"Δ","delta":"δ","demptyv":"⦱","dfisht":"⥿","Dfr":"𝔇","dfr":"𝔡","dHar":"⥥","dharl":"⇃","dharr":"⇂","DiacriticalAcute":"´","DiacriticalDot":"˙","DiacriticalDoubleAcute":"˝","DiacriticalGrave":"`","DiacriticalTilde":"˜","diam":"⋄","diamond":"⋄","Diamond":"⋄","diamondsuit":"♦","diams":"♦","die":"¨","DifferentialD":"ⅆ","digamma":"ϝ","disin":"⋲","div":"÷","divide":"÷","divideontimes":"⋇","divonx":"⋇","DJcy":"Ђ","djcy":"ђ","dlcorn":"⌞","dlcrop":"⌍","dollar":"$","Dopf":"𝔻","dopf":"𝕕","Dot":"¨","dot":"˙","DotDot":"⃜","doteq":"≐","doteqdot":"≑","DotEqual":"≐","dotminus":"∸","dotplus":"∔","dotsquare":"⊡","doublebarwedge":"⌆","DoubleContourIntegral":"∯","DoubleDot":"¨","DoubleDownArrow":"⇓","DoubleLeftArrow":"⇐","DoubleLeftRightArrow":"⇔","DoubleLeftTee":"⫤","DoubleLongLeftArrow":"⟸","DoubleLongLeftRightArrow":"⟺","DoubleLongRightArrow":"⟹","DoubleRightArrow":"⇒","DoubleRightTee":"⊨","DoubleUpArrow":"⇑","DoubleUpDownArrow":"⇕","DoubleVerticalBar":"∥","DownArrowBar":"⤓","downarrow":"↓","DownArrow":"↓","Downarrow":"⇓","DownArrowUpArrow":"⇵","DownBreve":"̑","downdownarrows":"⇊","downharpoonleft":"⇃","downharpoonright":"⇂","DownLeftRightVector":"⥐","DownLeftTeeVector":"⥞","DownLeftVectorBar":"⥖","DownLeftVector":"↽","DownRightTeeVector":"⥟","DownRightVectorBar":"⥗","DownRightVector":"⇁","DownTeeArrow":"↧","DownTee":"⊤","drbkarow":"⤐","drcorn":"⌟","drcrop":"⌌","Dscr":"𝒟","dscr":"𝒹","DScy":"Ѕ","dscy":"ѕ","dsol":"⧶","Dstrok":"Đ","dstrok":"đ","dtdot":"⋱","dtri":"▿","dtrif":"▾","duarr":"⇵","duhar":"⥯","dwangle":"⦦","DZcy":"Џ","dzcy":"џ","dzigrarr":"⟿","Eacute":"É","eacute":"é","easter":"⩮","Ecaron":"Ě","ecaron":"ě","Ecirc":"Ê","ecirc":"ê","ecir":"≖","ecolon":"≕","Ecy":"Э","ecy":"э","eDDot":"⩷","Edot":"Ė","edot":"ė","eDot":"≑","ee":"ⅇ","efDot":"≒","Efr":"𝔈","efr":"𝔢","eg":"⪚","Egrave":"È","egrave":"è","egs":"⪖","egsdot":"⪘","el":"⪙","Element":"∈","elinters":"⏧","ell":"ℓ","els":"⪕","elsdot":"⪗","Emacr":"Ē","emacr":"ē","empty":"∅","emptyset":"∅","EmptySmallSquare":"◻","emptyv":"∅","EmptyVerySmallSquare":"▫","emsp13":" ","emsp14":" ","emsp":" ","ENG":"Ŋ","eng":"ŋ","ensp":" ","Eogon":"Ę","eogon":"ę","Eopf":"𝔼","eopf":"𝕖","epar":"⋕","eparsl":"⧣","eplus":"⩱","epsi":"ε","Epsilon":"Ε","epsilon":"ε","epsiv":"ϵ","eqcirc":"≖","eqcolon":"≕","eqsim":"≂","eqslantgtr":"⪖","eqslantless":"⪕","Equal":"⩵","equals":"=","EqualTilde":"≂","equest":"≟","Equilibrium":"⇌","equiv":"≡","equivDD":"⩸","eqvparsl":"⧥","erarr":"⥱","erDot":"≓","escr":"ℯ","Escr":"ℰ","esdot":"≐","Esim":"⩳","esim":"≂","Eta":"Η","eta":"η","ETH":"Ð","eth":"ð","Euml":"Ë","euml":"ë","euro":"€","excl":"!","exist":"∃","Exists":"∃","expectation":"ℰ","exponentiale":"ⅇ","ExponentialE":"ⅇ","fallingdotseq":"≒","Fcy":"Ф","fcy":"ф","female":"♀","ffilig":"ffi","fflig":"ff","ffllig":"ffl","Ffr":"𝔉","ffr":"𝔣","filig":"fi","FilledSmallSquare":"◼","FilledVerySmallSquare":"▪","fjlig":"fj","flat":"♭","fllig":"fl","fltns":"▱","fnof":"ƒ","Fopf":"𝔽","fopf":"𝕗","forall":"∀","ForAll":"∀","fork":"⋔","forkv":"⫙","Fouriertrf":"ℱ","fpartint":"⨍","frac12":"½","frac13":"⅓","frac14":"¼","frac15":"⅕","frac16":"⅙","frac18":"⅛","frac23":"⅔","frac25":"⅖","frac34":"¾","frac35":"⅗","frac38":"⅜","frac45":"⅘","frac56":"⅚","frac58":"⅝","frac78":"⅞","frasl":"⁄","frown":"⌢","fscr":"𝒻","Fscr":"ℱ","gacute":"ǵ","Gamma":"Γ","gamma":"γ","Gammad":"Ϝ","gammad":"ϝ","gap":"⪆","Gbreve":"Ğ","gbreve":"ğ","Gcedil":"Ģ","Gcirc":"Ĝ","gcirc":"ĝ","Gcy":"Г","gcy":"г","Gdot":"Ġ","gdot":"ġ","ge":"≥","gE":"≧","gEl":"⪌","gel":"⋛","geq":"≥","geqq":"≧","geqslant":"⩾","gescc":"⪩","ges":"⩾","gesdot":"⪀","gesdoto":"⪂","gesdotol":"⪄","gesl":"⋛︀","gesles":"⪔","Gfr":"𝔊","gfr":"𝔤","gg":"≫","Gg":"⋙","ggg":"⋙","gimel":"ℷ","GJcy":"Ѓ","gjcy":"ѓ","gla":"⪥","gl":"≷","glE":"⪒","glj":"⪤","gnap":"⪊","gnapprox":"⪊","gne":"⪈","gnE":"≩","gneq":"⪈","gneqq":"≩","gnsim":"⋧","Gopf":"𝔾","gopf":"𝕘","grave":"`","GreaterEqual":"≥","GreaterEqualLess":"⋛","GreaterFullEqual":"≧","GreaterGreater":"⪢","GreaterLess":"≷","GreaterSlantEqual":"⩾","GreaterTilde":"≳","Gscr":"𝒢","gscr":"ℊ","gsim":"≳","gsime":"⪎","gsiml":"⪐","gtcc":"⪧","gtcir":"⩺","gt":">","GT":">","Gt":"≫","gtdot":"⋗","gtlPar":"⦕","gtquest":"⩼","gtrapprox":"⪆","gtrarr":"⥸","gtrdot":"⋗","gtreqless":"⋛","gtreqqless":"⪌","gtrless":"≷","gtrsim":"≳","gvertneqq":"≩︀","gvnE":"≩︀","Hacek":"ˇ","hairsp":" ","half":"½","hamilt":"ℋ","HARDcy":"Ъ","hardcy":"ъ","harrcir":"⥈","harr":"↔","hArr":"⇔","harrw":"↭","Hat":"^","hbar":"ℏ","Hcirc":"Ĥ","hcirc":"ĥ","hearts":"♥","heartsuit":"♥","hellip":"…","hercon":"⊹","hfr":"𝔥","Hfr":"ℌ","HilbertSpace":"ℋ","hksearow":"⤥","hkswarow":"⤦","hoarr":"⇿","homtht":"∻","hookleftarrow":"↩","hookrightarrow":"↪","hopf":"𝕙","Hopf":"ℍ","horbar":"―","HorizontalLine":"─","hscr":"𝒽","Hscr":"ℋ","hslash":"ℏ","Hstrok":"Ħ","hstrok":"ħ","HumpDownHump":"≎","HumpEqual":"≏","hybull":"⁃","hyphen":"‐","Iacute":"Í","iacute":"í","ic":"⁣","Icirc":"Î","icirc":"î","Icy":"И","icy":"и","Idot":"İ","IEcy":"Е","iecy":"е","iexcl":"¡","iff":"⇔","ifr":"𝔦","Ifr":"ℑ","Igrave":"Ì","igrave":"ì","ii":"ⅈ","iiiint":"⨌","iiint":"∭","iinfin":"⧜","iiota":"℩","IJlig":"IJ","ijlig":"ij","Imacr":"Ī","imacr":"ī","image":"ℑ","ImaginaryI":"ⅈ","imagline":"ℐ","imagpart":"ℑ","imath":"ı","Im":"ℑ","imof":"⊷","imped":"Ƶ","Implies":"⇒","incare":"℅","in":"∈","infin":"∞","infintie":"⧝","inodot":"ı","intcal":"⊺","int":"∫","Int":"∬","integers":"ℤ","Integral":"∫","intercal":"⊺","Intersection":"⋂","intlarhk":"⨗","intprod":"⨼","InvisibleComma":"⁣","InvisibleTimes":"⁢","IOcy":"Ё","iocy":"ё","Iogon":"Į","iogon":"į","Iopf":"𝕀","iopf":"𝕚","Iota":"Ι","iota":"ι","iprod":"⨼","iquest":"¿","iscr":"𝒾","Iscr":"ℐ","isin":"∈","isindot":"⋵","isinE":"⋹","isins":"⋴","isinsv":"⋳","isinv":"∈","it":"⁢","Itilde":"Ĩ","itilde":"ĩ","Iukcy":"І","iukcy":"і","Iuml":"Ï","iuml":"ï","Jcirc":"Ĵ","jcirc":"ĵ","Jcy":"Й","jcy":"й","Jfr":"𝔍","jfr":"𝔧","jmath":"ȷ","Jopf":"𝕁","jopf":"𝕛","Jscr":"𝒥","jscr":"𝒿","Jsercy":"Ј","jsercy":"ј","Jukcy":"Є","jukcy":"є","Kappa":"Κ","kappa":"κ","kappav":"ϰ","Kcedil":"Ķ","kcedil":"ķ","Kcy":"К","kcy":"к","Kfr":"𝔎","kfr":"𝔨","kgreen":"ĸ","KHcy":"Х","khcy":"х","KJcy":"Ќ","kjcy":"ќ","Kopf":"𝕂","kopf":"𝕜","Kscr":"𝒦","kscr":"𝓀","lAarr":"⇚","Lacute":"Ĺ","lacute":"ĺ","laemptyv":"⦴","lagran":"ℒ","Lambda":"Λ","lambda":"λ","lang":"⟨","Lang":"⟪","langd":"⦑","langle":"⟨","lap":"⪅","Laplacetrf":"ℒ","laquo":"«","larrb":"⇤","larrbfs":"⤟","larr":"←","Larr":"↞","lArr":"⇐","larrfs":"⤝","larrhk":"↩","larrlp":"↫","larrpl":"⤹","larrsim":"⥳","larrtl":"↢","latail":"⤙","lAtail":"⤛","lat":"⪫","late":"⪭","lates":"⪭︀","lbarr":"⤌","lBarr":"⤎","lbbrk":"❲","lbrace":"{","lbrack":"[","lbrke":"⦋","lbrksld":"⦏","lbrkslu":"⦍","Lcaron":"Ľ","lcaron":"ľ","Lcedil":"Ļ","lcedil":"ļ","lceil":"⌈","lcub":"{","Lcy":"Л","lcy":"л","ldca":"⤶","ldquo":"“","ldquor":"„","ldrdhar":"⥧","ldrushar":"⥋","ldsh":"↲","le":"≤","lE":"≦","LeftAngleBracket":"⟨","LeftArrowBar":"⇤","leftarrow":"←","LeftArrow":"←","Leftarrow":"⇐","LeftArrowRightArrow":"⇆","leftarrowtail":"↢","LeftCeiling":"⌈","LeftDoubleBracket":"⟦","LeftDownTeeVector":"⥡","LeftDownVectorBar":"⥙","LeftDownVector":"⇃","LeftFloor":"⌊","leftharpoondown":"↽","leftharpoonup":"↼","leftleftarrows":"⇇","leftrightarrow":"↔","LeftRightArrow":"↔","Leftrightarrow":"⇔","leftrightarrows":"⇆","leftrightharpoons":"⇋","leftrightsquigarrow":"↭","LeftRightVector":"⥎","LeftTeeArrow":"↤","LeftTee":"⊣","LeftTeeVector":"⥚","leftthreetimes":"⋋","LeftTriangleBar":"⧏","LeftTriangle":"⊲","LeftTriangleEqual":"⊴","LeftUpDownVector":"⥑","LeftUpTeeVector":"⥠","LeftUpVectorBar":"⥘","LeftUpVector":"↿","LeftVectorBar":"⥒","LeftVector":"↼","lEg":"⪋","leg":"⋚","leq":"≤","leqq":"≦","leqslant":"⩽","lescc":"⪨","les":"⩽","lesdot":"⩿","lesdoto":"⪁","lesdotor":"⪃","lesg":"⋚︀","lesges":"⪓","lessapprox":"⪅","lessdot":"⋖","lesseqgtr":"⋚","lesseqqgtr":"⪋","LessEqualGreater":"⋚","LessFullEqual":"≦","LessGreater":"≶","lessgtr":"≶","LessLess":"⪡","lesssim":"≲","LessSlantEqual":"⩽","LessTilde":"≲","lfisht":"⥼","lfloor":"⌊","Lfr":"𝔏","lfr":"𝔩","lg":"≶","lgE":"⪑","lHar":"⥢","lhard":"↽","lharu":"↼","lharul":"⥪","lhblk":"▄","LJcy":"Љ","ljcy":"љ","llarr":"⇇","ll":"≪","Ll":"⋘","llcorner":"⌞","Lleftarrow":"⇚","llhard":"⥫","lltri":"◺","Lmidot":"Ŀ","lmidot":"ŀ","lmoustache":"⎰","lmoust":"⎰","lnap":"⪉","lnapprox":"⪉","lne":"⪇","lnE":"≨","lneq":"⪇","lneqq":"≨","lnsim":"⋦","loang":"⟬","loarr":"⇽","lobrk":"⟦","longleftarrow":"⟵","LongLeftArrow":"⟵","Longleftarrow":"⟸","longleftrightarrow":"⟷","LongLeftRightArrow":"⟷","Longleftrightarrow":"⟺","longmapsto":"⟼","longrightarrow":"⟶","LongRightArrow":"⟶","Longrightarrow":"⟹","looparrowleft":"↫","looparrowright":"↬","lopar":"⦅","Lopf":"𝕃","lopf":"𝕝","loplus":"⨭","lotimes":"⨴","lowast":"∗","lowbar":"_","LowerLeftArrow":"↙","LowerRightArrow":"↘","loz":"◊","lozenge":"◊","lozf":"⧫","lpar":"(","lparlt":"⦓","lrarr":"⇆","lrcorner":"⌟","lrhar":"⇋","lrhard":"⥭","lrm":"‎","lrtri":"⊿","lsaquo":"‹","lscr":"𝓁","Lscr":"ℒ","lsh":"↰","Lsh":"↰","lsim":"≲","lsime":"⪍","lsimg":"⪏","lsqb":"[","lsquo":"‘","lsquor":"‚","Lstrok":"Ł","lstrok":"ł","ltcc":"⪦","ltcir":"⩹","lt":"<","LT":"<","Lt":"≪","ltdot":"⋖","lthree":"⋋","ltimes":"⋉","ltlarr":"⥶","ltquest":"⩻","ltri":"◃","ltrie":"⊴","ltrif":"◂","ltrPar":"⦖","lurdshar":"⥊","luruhar":"⥦","lvertneqq":"≨︀","lvnE":"≨︀","macr":"¯","male":"♂","malt":"✠","maltese":"✠","Map":"⤅","map":"↦","mapsto":"↦","mapstodown":"↧","mapstoleft":"↤","mapstoup":"↥","marker":"▮","mcomma":"⨩","Mcy":"М","mcy":"м","mdash":"—","mDDot":"∺","measuredangle":"∡","MediumSpace":" ","Mellintrf":"ℳ","Mfr":"𝔐","mfr":"𝔪","mho":"℧","micro":"µ","midast":"*","midcir":"⫰","mid":"∣","middot":"·","minusb":"⊟","minus":"−","minusd":"∸","minusdu":"⨪","MinusPlus":"∓","mlcp":"⫛","mldr":"…","mnplus":"∓","models":"⊧","Mopf":"𝕄","mopf":"𝕞","mp":"∓","mscr":"𝓂","Mscr":"ℳ","mstpos":"∾","Mu":"Μ","mu":"μ","multimap":"⊸","mumap":"⊸","nabla":"∇","Nacute":"Ń","nacute":"ń","nang":"∠⃒","nap":"≉","napE":"⩰̸","napid":"≋̸","napos":"ʼn","napprox":"≉","natural":"♮","naturals":"ℕ","natur":"♮","nbsp":" ","nbump":"≎̸","nbumpe":"≏̸","ncap":"⩃","Ncaron":"Ň","ncaron":"ň","Ncedil":"Ņ","ncedil":"ņ","ncong":"≇","ncongdot":"⩭̸","ncup":"⩂","Ncy":"Н","ncy":"н","ndash":"–","nearhk":"⤤","nearr":"↗","neArr":"⇗","nearrow":"↗","ne":"≠","nedot":"≐̸","NegativeMediumSpace":"​","NegativeThickSpace":"​","NegativeThinSpace":"​","NegativeVeryThinSpace":"​","nequiv":"≢","nesear":"⤨","nesim":"≂̸","NestedGreaterGreater":"≫","NestedLessLess":"≪","NewLine":"\\n","nexist":"∄","nexists":"∄","Nfr":"𝔑","nfr":"𝔫","ngE":"≧̸","nge":"≱","ngeq":"≱","ngeqq":"≧̸","ngeqslant":"⩾̸","nges":"⩾̸","nGg":"⋙̸","ngsim":"≵","nGt":"≫⃒","ngt":"≯","ngtr":"≯","nGtv":"≫̸","nharr":"↮","nhArr":"⇎","nhpar":"⫲","ni":"∋","nis":"⋼","nisd":"⋺","niv":"∋","NJcy":"Њ","njcy":"њ","nlarr":"↚","nlArr":"⇍","nldr":"‥","nlE":"≦̸","nle":"≰","nleftarrow":"↚","nLeftarrow":"⇍","nleftrightarrow":"↮","nLeftrightarrow":"⇎","nleq":"≰","nleqq":"≦̸","nleqslant":"⩽̸","nles":"⩽̸","nless":"≮","nLl":"⋘̸","nlsim":"≴","nLt":"≪⃒","nlt":"≮","nltri":"⋪","nltrie":"⋬","nLtv":"≪̸","nmid":"∤","NoBreak":"⁠","NonBreakingSpace":" ","nopf":"𝕟","Nopf":"ℕ","Not":"⫬","not":"¬","NotCongruent":"≢","NotCupCap":"≭","NotDoubleVerticalBar":"∦","NotElement":"∉","NotEqual":"≠","NotEqualTilde":"≂̸","NotExists":"∄","NotGreater":"≯","NotGreaterEqual":"≱","NotGreaterFullEqual":"≧̸","NotGreaterGreater":"≫̸","NotGreaterLess":"≹","NotGreaterSlantEqual":"⩾̸","NotGreaterTilde":"≵","NotHumpDownHump":"≎̸","NotHumpEqual":"≏̸","notin":"∉","notindot":"⋵̸","notinE":"⋹̸","notinva":"∉","notinvb":"⋷","notinvc":"⋶","NotLeftTriangleBar":"⧏̸","NotLeftTriangle":"⋪","NotLeftTriangleEqual":"⋬","NotLess":"≮","NotLessEqual":"≰","NotLessGreater":"≸","NotLessLess":"≪̸","NotLessSlantEqual":"⩽̸","NotLessTilde":"≴","NotNestedGreaterGreater":"⪢̸","NotNestedLessLess":"⪡̸","notni":"∌","notniva":"∌","notnivb":"⋾","notnivc":"⋽","NotPrecedes":"⊀","NotPrecedesEqual":"⪯̸","NotPrecedesSlantEqual":"⋠","NotReverseElement":"∌","NotRightTriangleBar":"⧐̸","NotRightTriangle":"⋫","NotRightTriangleEqual":"⋭","NotSquareSubset":"⊏̸","NotSquareSubsetEqual":"⋢","NotSquareSuperset":"⊐̸","NotSquareSupersetEqual":"⋣","NotSubset":"⊂⃒","NotSubsetEqual":"⊈","NotSucceeds":"⊁","NotSucceedsEqual":"⪰̸","NotSucceedsSlantEqual":"⋡","NotSucceedsTilde":"≿̸","NotSuperset":"⊃⃒","NotSupersetEqual":"⊉","NotTilde":"≁","NotTildeEqual":"≄","NotTildeFullEqual":"≇","NotTildeTilde":"≉","NotVerticalBar":"∤","nparallel":"∦","npar":"∦","nparsl":"⫽⃥","npart":"∂̸","npolint":"⨔","npr":"⊀","nprcue":"⋠","nprec":"⊀","npreceq":"⪯̸","npre":"⪯̸","nrarrc":"⤳̸","nrarr":"↛","nrArr":"⇏","nrarrw":"↝̸","nrightarrow":"↛","nRightarrow":"⇏","nrtri":"⋫","nrtrie":"⋭","nsc":"⊁","nsccue":"⋡","nsce":"⪰̸","Nscr":"𝒩","nscr":"𝓃","nshortmid":"∤","nshortparallel":"∦","nsim":"≁","nsime":"≄","nsimeq":"≄","nsmid":"∤","nspar":"∦","nsqsube":"⋢","nsqsupe":"⋣","nsub":"⊄","nsubE":"⫅̸","nsube":"⊈","nsubset":"⊂⃒","nsubseteq":"⊈","nsubseteqq":"⫅̸","nsucc":"⊁","nsucceq":"⪰̸","nsup":"⊅","nsupE":"⫆̸","nsupe":"⊉","nsupset":"⊃⃒","nsupseteq":"⊉","nsupseteqq":"⫆̸","ntgl":"≹","Ntilde":"Ñ","ntilde":"ñ","ntlg":"≸","ntriangleleft":"⋪","ntrianglelefteq":"⋬","ntriangleright":"⋫","ntrianglerighteq":"⋭","Nu":"Ν","nu":"ν","num":"#","numero":"№","numsp":" ","nvap":"≍⃒","nvdash":"⊬","nvDash":"⊭","nVdash":"⊮","nVDash":"⊯","nvge":"≥⃒","nvgt":">⃒","nvHarr":"⤄","nvinfin":"⧞","nvlArr":"⤂","nvle":"≤⃒","nvlt":"<⃒","nvltrie":"⊴⃒","nvrArr":"⤃","nvrtrie":"⊵⃒","nvsim":"∼⃒","nwarhk":"⤣","nwarr":"↖","nwArr":"⇖","nwarrow":"↖","nwnear":"⤧","Oacute":"Ó","oacute":"ó","oast":"⊛","Ocirc":"Ô","ocirc":"ô","ocir":"⊚","Ocy":"О","ocy":"о","odash":"⊝","Odblac":"Ő","odblac":"ő","odiv":"⨸","odot":"⊙","odsold":"⦼","OElig":"Œ","oelig":"œ","ofcir":"⦿","Ofr":"𝔒","ofr":"𝔬","ogon":"˛","Ograve":"Ò","ograve":"ò","ogt":"⧁","ohbar":"⦵","ohm":"Ω","oint":"∮","olarr":"↺","olcir":"⦾","olcross":"⦻","oline":"‾","olt":"⧀","Omacr":"Ō","omacr":"ō","Omega":"Ω","omega":"ω","Omicron":"Ο","omicron":"ο","omid":"⦶","ominus":"⊖","Oopf":"𝕆","oopf":"𝕠","opar":"⦷","OpenCurlyDoubleQuote":"“","OpenCurlyQuote":"‘","operp":"⦹","oplus":"⊕","orarr":"↻","Or":"⩔","or":"∨","ord":"⩝","order":"ℴ","orderof":"ℴ","ordf":"ª","ordm":"º","origof":"⊶","oror":"⩖","orslope":"⩗","orv":"⩛","oS":"Ⓢ","Oscr":"𝒪","oscr":"ℴ","Oslash":"Ø","oslash":"ø","osol":"⊘","Otilde":"Õ","otilde":"õ","otimesas":"⨶","Otimes":"⨷","otimes":"⊗","Ouml":"Ö","ouml":"ö","ovbar":"⌽","OverBar":"‾","OverBrace":"⏞","OverBracket":"⎴","OverParenthesis":"⏜","para":"¶","parallel":"∥","par":"∥","parsim":"⫳","parsl":"⫽","part":"∂","PartialD":"∂","Pcy":"П","pcy":"п","percnt":"%","period":".","permil":"‰","perp":"⊥","pertenk":"‱","Pfr":"𝔓","pfr":"𝔭","Phi":"Φ","phi":"φ","phiv":"ϕ","phmmat":"ℳ","phone":"☎","Pi":"Π","pi":"π","pitchfork":"⋔","piv":"ϖ","planck":"ℏ","planckh":"ℎ","plankv":"ℏ","plusacir":"⨣","plusb":"⊞","pluscir":"⨢","plus":"+","plusdo":"∔","plusdu":"⨥","pluse":"⩲","PlusMinus":"±","plusmn":"±","plussim":"⨦","plustwo":"⨧","pm":"±","Poincareplane":"ℌ","pointint":"⨕","popf":"𝕡","Popf":"ℙ","pound":"£","prap":"⪷","Pr":"⪻","pr":"≺","prcue":"≼","precapprox":"⪷","prec":"≺","preccurlyeq":"≼","Precedes":"≺","PrecedesEqual":"⪯","PrecedesSlantEqual":"≼","PrecedesTilde":"≾","preceq":"⪯","precnapprox":"⪹","precneqq":"⪵","precnsim":"⋨","pre":"⪯","prE":"⪳","precsim":"≾","prime":"′","Prime":"″","primes":"ℙ","prnap":"⪹","prnE":"⪵","prnsim":"⋨","prod":"∏","Product":"∏","profalar":"⌮","profline":"⌒","profsurf":"⌓","prop":"∝","Proportional":"∝","Proportion":"∷","propto":"∝","prsim":"≾","prurel":"⊰","Pscr":"𝒫","pscr":"𝓅","Psi":"Ψ","psi":"ψ","puncsp":" ","Qfr":"𝔔","qfr":"𝔮","qint":"⨌","qopf":"𝕢","Qopf":"ℚ","qprime":"⁗","Qscr":"𝒬","qscr":"𝓆","quaternions":"ℍ","quatint":"⨖","quest":"?","questeq":"≟","quot":"\\"","QUOT":"\\"","rAarr":"⇛","race":"∽̱","Racute":"Ŕ","racute":"ŕ","radic":"√","raemptyv":"⦳","rang":"⟩","Rang":"⟫","rangd":"⦒","range":"⦥","rangle":"⟩","raquo":"»","rarrap":"⥵","rarrb":"⇥","rarrbfs":"⤠","rarrc":"⤳","rarr":"→","Rarr":"↠","rArr":"⇒","rarrfs":"⤞","rarrhk":"↪","rarrlp":"↬","rarrpl":"⥅","rarrsim":"⥴","Rarrtl":"⤖","rarrtl":"↣","rarrw":"↝","ratail":"⤚","rAtail":"⤜","ratio":"∶","rationals":"ℚ","rbarr":"⤍","rBarr":"⤏","RBarr":"⤐","rbbrk":"❳","rbrace":"}","rbrack":"]","rbrke":"⦌","rbrksld":"⦎","rbrkslu":"⦐","Rcaron":"Ř","rcaron":"ř","Rcedil":"Ŗ","rcedil":"ŗ","rceil":"⌉","rcub":"}","Rcy":"Р","rcy":"р","rdca":"⤷","rdldhar":"⥩","rdquo":"”","rdquor":"”","rdsh":"↳","real":"ℜ","realine":"ℛ","realpart":"ℜ","reals":"ℝ","Re":"ℜ","rect":"▭","reg":"®","REG":"®","ReverseElement":"∋","ReverseEquilibrium":"⇋","ReverseUpEquilibrium":"⥯","rfisht":"⥽","rfloor":"⌋","rfr":"𝔯","Rfr":"ℜ","rHar":"⥤","rhard":"⇁","rharu":"⇀","rharul":"⥬","Rho":"Ρ","rho":"ρ","rhov":"ϱ","RightAngleBracket":"⟩","RightArrowBar":"⇥","rightarrow":"→","RightArrow":"→","Rightarrow":"⇒","RightArrowLeftArrow":"⇄","rightarrowtail":"↣","RightCeiling":"⌉","RightDoubleBracket":"⟧","RightDownTeeVector":"⥝","RightDownVectorBar":"⥕","RightDownVector":"⇂","RightFloor":"⌋","rightharpoondown":"⇁","rightharpoonup":"⇀","rightleftarrows":"⇄","rightleftharpoons":"⇌","rightrightarrows":"⇉","rightsquigarrow":"↝","RightTeeArrow":"↦","RightTee":"⊢","RightTeeVector":"⥛","rightthreetimes":"⋌","RightTriangleBar":"⧐","RightTriangle":"⊳","RightTriangleEqual":"⊵","RightUpDownVector":"⥏","RightUpTeeVector":"⥜","RightUpVectorBar":"⥔","RightUpVector":"↾","RightVectorBar":"⥓","RightVector":"⇀","ring":"˚","risingdotseq":"≓","rlarr":"⇄","rlhar":"⇌","rlm":"‏","rmoustache":"⎱","rmoust":"⎱","rnmid":"⫮","roang":"⟭","roarr":"⇾","robrk":"⟧","ropar":"⦆","ropf":"𝕣","Ropf":"ℝ","roplus":"⨮","rotimes":"⨵","RoundImplies":"⥰","rpar":")","rpargt":"⦔","rppolint":"⨒","rrarr":"⇉","Rrightarrow":"⇛","rsaquo":"›","rscr":"𝓇","Rscr":"ℛ","rsh":"↱","Rsh":"↱","rsqb":"]","rsquo":"’","rsquor":"’","rthree":"⋌","rtimes":"⋊","rtri":"▹","rtrie":"⊵","rtrif":"▸","rtriltri":"⧎","RuleDelayed":"⧴","ruluhar":"⥨","rx":"℞","Sacute":"Ś","sacute":"ś","sbquo":"‚","scap":"⪸","Scaron":"Š","scaron":"š","Sc":"⪼","sc":"≻","sccue":"≽","sce":"⪰","scE":"⪴","Scedil":"Ş","scedil":"ş","Scirc":"Ŝ","scirc":"ŝ","scnap":"⪺","scnE":"⪶","scnsim":"⋩","scpolint":"⨓","scsim":"≿","Scy":"С","scy":"с","sdotb":"⊡","sdot":"⋅","sdote":"⩦","searhk":"⤥","searr":"↘","seArr":"⇘","searrow":"↘","sect":"§","semi":";","seswar":"⤩","setminus":"∖","setmn":"∖","sext":"✶","Sfr":"𝔖","sfr":"𝔰","sfrown":"⌢","sharp":"♯","SHCHcy":"Щ","shchcy":"щ","SHcy":"Ш","shcy":"ш","ShortDownArrow":"↓","ShortLeftArrow":"←","shortmid":"∣","shortparallel":"∥","ShortRightArrow":"→","ShortUpArrow":"↑","shy":"­","Sigma":"Σ","sigma":"σ","sigmaf":"ς","sigmav":"ς","sim":"∼","simdot":"⩪","sime":"≃","simeq":"≃","simg":"⪞","simgE":"⪠","siml":"⪝","simlE":"⪟","simne":"≆","simplus":"⨤","simrarr":"⥲","slarr":"←","SmallCircle":"∘","smallsetminus":"∖","smashp":"⨳","smeparsl":"⧤","smid":"∣","smile":"⌣","smt":"⪪","smte":"⪬","smtes":"⪬︀","SOFTcy":"Ь","softcy":"ь","solbar":"⌿","solb":"⧄","sol":"/","Sopf":"𝕊","sopf":"𝕤","spades":"♠","spadesuit":"♠","spar":"∥","sqcap":"⊓","sqcaps":"⊓︀","sqcup":"⊔","sqcups":"⊔︀","Sqrt":"√","sqsub":"⊏","sqsube":"⊑","sqsubset":"⊏","sqsubseteq":"⊑","sqsup":"⊐","sqsupe":"⊒","sqsupset":"⊐","sqsupseteq":"⊒","square":"□","Square":"□","SquareIntersection":"⊓","SquareSubset":"⊏","SquareSubsetEqual":"⊑","SquareSuperset":"⊐","SquareSupersetEqual":"⊒","SquareUnion":"⊔","squarf":"▪","squ":"□","squf":"▪","srarr":"→","Sscr":"𝒮","sscr":"𝓈","ssetmn":"∖","ssmile":"⌣","sstarf":"⋆","Star":"⋆","star":"☆","starf":"★","straightepsilon":"ϵ","straightphi":"ϕ","strns":"¯","sub":"⊂","Sub":"⋐","subdot":"⪽","subE":"⫅","sube":"⊆","subedot":"⫃","submult":"⫁","subnE":"⫋","subne":"⊊","subplus":"⪿","subrarr":"⥹","subset":"⊂","Subset":"⋐","subseteq":"⊆","subseteqq":"⫅","SubsetEqual":"⊆","subsetneq":"⊊","subsetneqq":"⫋","subsim":"⫇","subsub":"⫕","subsup":"⫓","succapprox":"⪸","succ":"≻","succcurlyeq":"≽","Succeeds":"≻","SucceedsEqual":"⪰","SucceedsSlantEqual":"≽","SucceedsTilde":"≿","succeq":"⪰","succnapprox":"⪺","succneqq":"⪶","succnsim":"⋩","succsim":"≿","SuchThat":"∋","sum":"∑","Sum":"∑","sung":"♪","sup1":"¹","sup2":"²","sup3":"³","sup":"⊃","Sup":"⋑","supdot":"⪾","supdsub":"⫘","supE":"⫆","supe":"⊇","supedot":"⫄","Superset":"⊃","SupersetEqual":"⊇","suphsol":"⟉","suphsub":"⫗","suplarr":"⥻","supmult":"⫂","supnE":"⫌","supne":"⊋","supplus":"⫀","supset":"⊃","Supset":"⋑","supseteq":"⊇","supseteqq":"⫆","supsetneq":"⊋","supsetneqq":"⫌","supsim":"⫈","supsub":"⫔","supsup":"⫖","swarhk":"⤦","swarr":"↙","swArr":"⇙","swarrow":"↙","swnwar":"⤪","szlig":"ß","Tab":"\\t","target":"⌖","Tau":"Τ","tau":"τ","tbrk":"⎴","Tcaron":"Ť","tcaron":"ť","Tcedil":"Ţ","tcedil":"ţ","Tcy":"Т","tcy":"т","tdot":"⃛","telrec":"⌕","Tfr":"𝔗","tfr":"𝔱","there4":"∴","therefore":"∴","Therefore":"∴","Theta":"Θ","theta":"θ","thetasym":"ϑ","thetav":"ϑ","thickapprox":"≈","thicksim":"∼","ThickSpace":"  ","ThinSpace":" ","thinsp":" ","thkap":"≈","thksim":"∼","THORN":"Þ","thorn":"þ","tilde":"˜","Tilde":"∼","TildeEqual":"≃","TildeFullEqual":"≅","TildeTilde":"≈","timesbar":"⨱","timesb":"⊠","times":"×","timesd":"⨰","tint":"∭","toea":"⤨","topbot":"⌶","topcir":"⫱","top":"⊤","Topf":"𝕋","topf":"𝕥","topfork":"⫚","tosa":"⤩","tprime":"‴","trade":"™","TRADE":"™","triangle":"▵","triangledown":"▿","triangleleft":"◃","trianglelefteq":"⊴","triangleq":"≜","triangleright":"▹","trianglerighteq":"⊵","tridot":"◬","trie":"≜","triminus":"⨺","TripleDot":"⃛","triplus":"⨹","trisb":"⧍","tritime":"⨻","trpezium":"⏢","Tscr":"𝒯","tscr":"𝓉","TScy":"Ц","tscy":"ц","TSHcy":"Ћ","tshcy":"ћ","Tstrok":"Ŧ","tstrok":"ŧ","twixt":"≬","twoheadleftarrow":"↞","twoheadrightarrow":"↠","Uacute":"Ú","uacute":"ú","uarr":"↑","Uarr":"↟","uArr":"⇑","Uarrocir":"⥉","Ubrcy":"Ў","ubrcy":"ў","Ubreve":"Ŭ","ubreve":"ŭ","Ucirc":"Û","ucirc":"û","Ucy":"У","ucy":"у","udarr":"⇅","Udblac":"Ű","udblac":"ű","udhar":"⥮","ufisht":"⥾","Ufr":"𝔘","ufr":"𝔲","Ugrave":"Ù","ugrave":"ù","uHar":"⥣","uharl":"↿","uharr":"↾","uhblk":"▀","ulcorn":"⌜","ulcorner":"⌜","ulcrop":"⌏","ultri":"◸","Umacr":"Ū","umacr":"ū","uml":"¨","UnderBar":"_","UnderBrace":"⏟","UnderBracket":"⎵","UnderParenthesis":"⏝","Union":"⋃","UnionPlus":"⊎","Uogon":"Ų","uogon":"ų","Uopf":"𝕌","uopf":"𝕦","UpArrowBar":"⤒","uparrow":"↑","UpArrow":"↑","Uparrow":"⇑","UpArrowDownArrow":"⇅","updownarrow":"↕","UpDownArrow":"↕","Updownarrow":"⇕","UpEquilibrium":"⥮","upharpoonleft":"↿","upharpoonright":"↾","uplus":"⊎","UpperLeftArrow":"↖","UpperRightArrow":"↗","upsi":"υ","Upsi":"ϒ","upsih":"ϒ","Upsilon":"Υ","upsilon":"υ","UpTeeArrow":"↥","UpTee":"⊥","upuparrows":"⇈","urcorn":"⌝","urcorner":"⌝","urcrop":"⌎","Uring":"Ů","uring":"ů","urtri":"◹","Uscr":"𝒰","uscr":"𝓊","utdot":"⋰","Utilde":"Ũ","utilde":"ũ","utri":"▵","utrif":"▴","uuarr":"⇈","Uuml":"Ü","uuml":"ü","uwangle":"⦧","vangrt":"⦜","varepsilon":"ϵ","varkappa":"ϰ","varnothing":"∅","varphi":"ϕ","varpi":"ϖ","varpropto":"∝","varr":"↕","vArr":"⇕","varrho":"ϱ","varsigma":"ς","varsubsetneq":"⊊︀","varsubsetneqq":"⫋︀","varsupsetneq":"⊋︀","varsupsetneqq":"⫌︀","vartheta":"ϑ","vartriangleleft":"⊲","vartriangleright":"⊳","vBar":"⫨","Vbar":"⫫","vBarv":"⫩","Vcy":"В","vcy":"в","vdash":"⊢","vDash":"⊨","Vdash":"⊩","VDash":"⊫","Vdashl":"⫦","veebar":"⊻","vee":"∨","Vee":"⋁","veeeq":"≚","vellip":"⋮","verbar":"|","Verbar":"‖","vert":"|","Vert":"‖","VerticalBar":"∣","VerticalLine":"|","VerticalSeparator":"❘","VerticalTilde":"≀","VeryThinSpace":" ","Vfr":"𝔙","vfr":"𝔳","vltri":"⊲","vnsub":"⊂⃒","vnsup":"⊃⃒","Vopf":"𝕍","vopf":"𝕧","vprop":"∝","vrtri":"⊳","Vscr":"𝒱","vscr":"𝓋","vsubnE":"⫋︀","vsubne":"⊊︀","vsupnE":"⫌︀","vsupne":"⊋︀","Vvdash":"⊪","vzigzag":"⦚","Wcirc":"Ŵ","wcirc":"ŵ","wedbar":"⩟","wedge":"∧","Wedge":"⋀","wedgeq":"≙","weierp":"℘","Wfr":"𝔚","wfr":"𝔴","Wopf":"𝕎","wopf":"𝕨","wp":"℘","wr":"≀","wreath":"≀","Wscr":"𝒲","wscr":"𝓌","xcap":"⋂","xcirc":"◯","xcup":"⋃","xdtri":"▽","Xfr":"𝔛","xfr":"𝔵","xharr":"⟷","xhArr":"⟺","Xi":"Ξ","xi":"ξ","xlarr":"⟵","xlArr":"⟸","xmap":"⟼","xnis":"⋻","xodot":"⨀","Xopf":"𝕏","xopf":"𝕩","xoplus":"⨁","xotime":"⨂","xrarr":"⟶","xrArr":"⟹","Xscr":"𝒳","xscr":"𝓍","xsqcup":"⨆","xuplus":"⨄","xutri":"△","xvee":"⋁","xwedge":"⋀","Yacute":"Ý","yacute":"ý","YAcy":"Я","yacy":"я","Ycirc":"Ŷ","ycirc":"ŷ","Ycy":"Ы","ycy":"ы","yen":"¥","Yfr":"𝔜","yfr":"𝔶","YIcy":"Ї","yicy":"ї","Yopf":"𝕐","yopf":"𝕪","Yscr":"𝒴","yscr":"𝓎","YUcy":"Ю","yucy":"ю","yuml":"ÿ","Yuml":"Ÿ","Zacute":"Ź","zacute":"ź","Zcaron":"Ž","zcaron":"ž","Zcy":"З","zcy":"з","Zdot":"Ż","zdot":"ż","zeetrf":"ℨ","ZeroWidthSpace":"​","Zeta":"Ζ","zeta":"ζ","zfr":"𝔷","Zfr":"ℨ","ZHcy":"Ж","zhcy":"ж","zigrarr":"⇝","zopf":"𝕫","Zopf":"ℤ","Zscr":"𝒵","zscr":"𝓏","zwj":"‍","zwnj":"‌"}')},function(e){e.exports=JSON.parse('{"Aacute":"Á","aacute":"á","Acirc":"Â","acirc":"â","acute":"´","AElig":"Æ","aelig":"æ","Agrave":"À","agrave":"à","amp":"&","AMP":"&","Aring":"Å","aring":"å","Atilde":"Ã","atilde":"ã","Auml":"Ä","auml":"ä","brvbar":"¦","Ccedil":"Ç","ccedil":"ç","cedil":"¸","cent":"¢","copy":"©","COPY":"©","curren":"¤","deg":"°","divide":"÷","Eacute":"É","eacute":"é","Ecirc":"Ê","ecirc":"ê","Egrave":"È","egrave":"è","ETH":"Ð","eth":"ð","Euml":"Ë","euml":"ë","frac12":"½","frac14":"¼","frac34":"¾","gt":">","GT":">","Iacute":"Í","iacute":"í","Icirc":"Î","icirc":"î","iexcl":"¡","Igrave":"Ì","igrave":"ì","iquest":"¿","Iuml":"Ï","iuml":"ï","laquo":"«","lt":"<","LT":"<","macr":"¯","micro":"µ","middot":"·","nbsp":" ","not":"¬","Ntilde":"Ñ","ntilde":"ñ","Oacute":"Ó","oacute":"ó","Ocirc":"Ô","ocirc":"ô","Ograve":"Ò","ograve":"ò","ordf":"ª","ordm":"º","Oslash":"Ø","oslash":"ø","Otilde":"Õ","otilde":"õ","Ouml":"Ö","ouml":"ö","para":"¶","plusmn":"±","pound":"£","quot":"\\"","QUOT":"\\"","raquo":"»","reg":"®","REG":"®","sect":"§","shy":"­","sup1":"¹","sup2":"²","sup3":"³","szlig":"ß","THORN":"Þ","thorn":"þ","times":"×","Uacute":"Ú","uacute":"ú","Ucirc":"Û","ucirc":"û","Ugrave":"Ù","ugrave":"ù","uml":"¨","Uuml":"Ü","uuml":"ü","Yacute":"Ý","yacute":"ý","yen":"¥","yuml":"ÿ"}')},function(e){e.exports=JSON.parse('{"amp":"&","apos":"\'","gt":">","lt":"<","quot":"\\""}')},function(e,t,r){var n=r(181),i=e.exports=Object.create(n),a={tagName:"name"};Object.keys(a).forEach(function(e){var t=a[e];Object.defineProperty(i,e,{get:function(){return this[t]||null},set:function(e){return this[t]=e,e}})})},function(e,t,r){var n=r(180),i=r(182);function a(e,t){this.init(e,t)}function o(e,t){return i.getElementsByTagName(e,t,!0)}function s(e,t){return i.getElementsByTagName(e,t,!0,1)[0]}function c(e,t,r){return i.getText(i.getElementsByTagName(e,t,r,1)).trim()}function u(e,t,r,n,i){var a=c(r,n,i);a&&(e[t]=a)}r(1)(a,n),a.prototype.init=n;var l=function(e){return"rss"===e||"feed"===e||"rdf:RDF"===e};a.prototype.onend=function(){var e,t,r={},i=s(l,this.dom);i&&("feed"===i.name?(t=i.children,r.type="atom",u(r,"id","id",t),u(r,"title","title",t),(e=s("link",t))&&(e=e.attribs)&&(e=e.href)&&(r.link=e),u(r,"description","subtitle",t),(e=c("updated",t))&&(r.updated=new Date(e)),u(r,"author","email",t,!0),r.items=o("entry",t).map(function(e){var t,r={};return u(r,"id","id",e=e.children),u(r,"title","title",e),(t=s("link",e))&&(t=t.attribs)&&(t=t.href)&&(r.link=t),(t=c("summary",e)||c("content",e))&&(r.description=t),(t=c("updated",e))&&(r.pubDate=new Date(t)),r})):(t=s("channel",i.children).children,r.type=i.name.substr(0,3),r.id="",u(r,"title","title",t),u(r,"link","link",t),u(r,"description","description",t),(e=c("lastBuildDate",t))&&(r.updated=new Date(e)),u(r,"author","managingEditor",t,!0),r.items=o("item",i.children).map(function(e){var t,r={};return u(r,"id","guid",e=e.children),u(r,"title","title",e),u(r,"link","link",e),u(r,"description","description",e),(t=c("pubDate",e))&&(r.pubDate=new Date(t)),r}))),this.dom=r,n.prototype._handleCallback.call(this,i?null:Error("couldn't find root of feed"))},e.exports=a},function(e,t,r){var n=r(56),i=r(170),a=n.isTag;e.exports={getInnerHTML:function(e,t){return e.children?e.children.map(function(e){return i(e,t)}).join(""):""},getOuterHTML:i,getText:function e(t){if(Array.isArray(t))return t.map(e).join("");if(a(t))return"br"===t.name?"\n":e(t.children);if(t.type===n.CDATA)return e(t.children);if(t.type===n.Text)return t.data;return""}}},function(e,t){var r=t.getChildren=function(e){return e.children},n=t.getParent=function(e){return e.parent};t.getSiblings=function(e){var t=n(e);return t?r(t):[e]},t.getAttributeValue=function(e,t){return e.attribs&&e.attribs[t]},t.hasAttrib=function(e,t){return!!e.attribs&&hasOwnProperty.call(e.attribs,t)},t.getName=function(e){return e.name}},function(e,t){t.removeElement=function(e){if(e.prev&&(e.prev.next=e.next),e.next&&(e.next.prev=e.prev),e.parent){var t=e.parent.children;t.splice(t.lastIndexOf(e),1)}},t.replaceElement=function(e,t){var r=t.prev=e.prev;r&&(r.next=t);var n=t.next=e.next;n&&(n.prev=t);var i=t.parent=e.parent;if(i){var a=i.children;a[a.lastIndexOf(e)]=t}},t.appendChild=function(e,t){if(t.parent=e,1!==e.children.push(t)){var r=e.children[e.children.length-2];r.next=t,t.prev=r,t.next=null}},t.append=function(e,t){var r=e.parent,n=e.next;if(t.next=n,t.prev=e,e.next=t,t.parent=r,n){if(n.prev=t,r){var i=r.children;i.splice(i.lastIndexOf(n),0,t)}}else r&&r.children.push(t)},t.prepend=function(e,t){var r=e.parent;if(r){var n=r.children;n.splice(n.lastIndexOf(e),0,t)}e.prev&&(e.prev.next=t),t.parent=r,t.prev=e.prev,t.next=e,e.prev=t}},function(e,t,r){var n=r(56).isTag;function i(e,t,r,n){for(var a,o=[],s=0,c=t.length;s<c&&!(e(t[s])&&(o.push(t[s]),--n<=0))&&(a=t[s].children,!(r&&a&&a.length>0&&(a=i(e,a,r,n),o=o.concat(a),(n-=a.length)<=0)));s++);return o}e.exports={filter:function(e,t,r,n){Array.isArray(t)||(t=[t]);"number"==typeof n&&isFinite(n)||(n=1/0);return i(e,t,!1!==r,n)},find:i,findOneChild:function(e,t){for(var r=0,n=t.length;r<n;r++)if(e(t[r]))return t[r];return null},findOne:function e(t,r){var i=null;for(var a=0,o=r.length;a<o&&!i;a++)n(r[a])&&(t(r[a])?i=r[a]:r[a].children.length>0&&(i=e(t,r[a].children)));return i},existsOne:function e(t,r){for(var i=0,a=r.length;i<a;i++)if(n(r[i])&&(t(r[i])||r[i].children.length>0&&e(t,r[i].children)))return!0;return!1},findAll:function(e,t){var r=[],i=t.slice();for(;i.length;){var a=i.shift();n(a)&&(a.children&&a.children.length>0&&i.unshift.apply(i,a.children),e(a)&&r.push(a))}return r}}},function(e,t,r){var n=r(56),i=t.isTag=n.isTag;t.testElement=function(e,t){for(var r in e)if(e.hasOwnProperty(r)){if("tag_name"===r){if(!i(t)||!e.tag_name(t.name))return!1}else if("tag_type"===r){if(!e.tag_type(t.type))return!1}else if("tag_contains"===r){if(i(t)||!e.tag_contains(t.data))return!1}else if(!t.attribs||!e[r](t.attribs[r]))return!1}else;return!0};var a={tag_name:function(e){return"function"==typeof e?function(t){return i(t)&&e(t.name)}:"*"===e?i:function(t){return i(t)&&t.name===e}},tag_type:function(e){return"function"==typeof e?function(t){return e(t.type)}:function(t){return t.type===e}},tag_contains:function(e){return"function"==typeof e?function(t){return!i(t)&&e(t.data)}:function(t){return!i(t)&&t.data===e}}};function o(e,t){return"function"==typeof t?function(r){return r.attribs&&t(r.attribs[e])}:function(r){return r.attribs&&r.attribs[e]===t}}function s(e,t){return function(r){return e(r)||t(r)}}t.getElements=function(e,t,r,n){var i=Object.keys(e).map(function(t){var r=e[t];return t in a?a[t](r):o(t,r)});return 0===i.length?[]:this.filter(i.reduce(s),t,r,n)},t.getElementById=function(e,t,r){return Array.isArray(t)||(t=[t]),this.findOne(o("id",e),t,!1!==r)},t.getElementsByTagName=function(e,t,r,n){return this.filter(a.tag_name(e),t,r,n)},t.getElementsByTagType=function(e,t,r,n){return this.filter(a.tag_type(e),t,r,n)}},function(e,t){t.removeSubsets=function(e){for(var t,r,n,i=e.length;--i>-1;){for(t=r=e[i],e[i]=null,n=!0;r;){if(e.indexOf(r)>-1){n=!1,e.splice(i,1);break}r=r.parent}n&&(e[i]=t)}return e};var r=1,n=2,i=4,a=8,o=16,s=t.compareDocumentPosition=function(e,t){var s,c,u,l,f,d,h=[],p=[];if(e===t)return 0;for(s=e;s;)h.unshift(s),s=s.parent;for(s=t;s;)p.unshift(s),s=s.parent;for(d=0;h[d]===p[d];)d++;return 0===d?r:(u=(c=h[d-1]).children,l=h[d],f=p[d],u.indexOf(l)>u.indexOf(f)?c===t?i|o:i:c===e?n|a:n)};t.uniqueSort=function(e){var t,r,a=e.length;for(e=e.slice();--a>-1;)t=e[a],(r=e.indexOf(t))>-1&&r<a&&e.splice(a,1);return e.sort(function(e,t){var r=s(e,t);return r&n?-1:r&i?1:0}),e}},function(e,t,r){e.exports=i;var n=r(183);function i(e){n.call(this,new a(this),e)}function a(e){this.scope=e}r(1)(i,n),i.prototype.readable=!0;var o=r(70).EVENTS;Object.keys(o).forEach(function(e){if(0===o[e])a.prototype["on"+e]=function(){this.scope.emit(e)};else if(1===o[e])a.prototype["on"+e]=function(t){this.scope.emit(e,t)};else{if(2!==o[e])throw Error("wrong number of arguments!");a.prototype["on"+e]=function(t,r){this.scope.emit(e,t,r)}}})},function(e,t){},function(e,t,r){function n(e){this._cbs=e||{}}e.exports=n;var i=r(70).EVENTS;Object.keys(i).forEach(function(e){if(0===i[e])e="on"+e,n.prototype[e]=function(){this._cbs[e]&&this._cbs[e]()};else if(1===i[e])e="on"+e,n.prototype[e]=function(t){this._cbs[e]&&this._cbs[e](t)};else{if(2!==i[e])throw Error("wrong number of arguments");e="on"+e,n.prototype[e]=function(t,r){this._cbs[e]&&this._cbs[e](t,r)}}})},function(e,t,r){function n(e){this._cbs=e||{},this.events=[]}e.exports=n;var i=r(70).EVENTS;Object.keys(i).forEach(function(e){if(0===i[e])e="on"+e,n.prototype[e]=function(){this.events.push([e]),this._cbs[e]&&this._cbs[e]()};else if(1===i[e])e="on"+e,n.prototype[e]=function(t){this.events.push([e,t]),this._cbs[e]&&this._cbs[e](t)};else{if(2!==i[e])throw Error("wrong number of arguments");e="on"+e,n.prototype[e]=function(t,r){this.events.push([e,t,r]),this._cbs[e]&&this._cbs[e](t,r)}}}),n.prototype.onreset=function(){this.events=[],this._cbs.onreset&&this._cbs.onreset()},n.prototype.restart=function(){this._cbs.onreset&&this._cbs.onreset();for(var e=0,t=this.events.length;e<t;e++)if(this._cbs[this.events[e][0]]){var r=this.events[e].length;1===r?this._cbs[this.events[e][0]]():2===r?this._cbs[this.events[e][0]](this.events[e][1]):this._cbs[this.events[e][0]](this.events[e][1],this.events[e][2])}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(185),i=r(163);t.ActorRdfParseHtmlRdfa=class extends n.ActorRdfParseHtml{constructor(e){super(e)}async test(e){return!0}async run(e){const t=e.headers?e.headers.get("content-type"):null,r=e.headers?e.headers.get("content-language"):null,n=t&&t.indexOf("xml")>=0?"xhtml":"html",a=new i.RdfaParser({baseIRI:e.baseIRI,profile:n,language:r});a.on("error",e.error),a.on("data",e.emit);const o=a.onEnd;return a.onEnd=()=>{o.call(a),e.end()},{htmlParseListener:a}}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(0);t.ActorRdfParseHtml=class extends n.Actor{constructor(e){super(e)}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(26);t.ActorRdfResolveQuadPatternRdfJsSource=class extends n.ActorRdfResolveQuadPatternSource{constructor(e){super(e)}async test(e){if(!this.hasContextSingleSourceOfType("rdfjsSource",e.context))throw new Error(this.name+" requires a single source with an rdfjsSource to be present in the context.");const t=this.getContextSource(e.context);if("string"==typeof t||!t.value.match)throw new Error(this.name+" received an invalid rdfjsSource.");return!0}getMetadata(e,t,r,n){return()=>Promise.resolve({})}async getSource(e){return this.getContextSource(e).value}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(6),i=r(187);class a extends i.ActorRdfResolveQuadPattern{constructor(e){super(e)}static variableToNull(e){return e&&"Variable"===e.termType?null:e}static cachifyMetadata(e){let t=null;return()=>t||(t=e())}async test(e){return!0}async run(e){const t=await this.getSource(e.context,e.pattern);return await this.getOutput(t,e.pattern,e.context)}getMetadata(e,t,r,n){return()=>new Promise((e,t)=>{n.on("error",t),n.on("end",()=>e({})),n.on("metadata",t=>{e(t)})})}async getOutput(e,t,r){let i;return{data:i=e.matchLazy?e.matchLazy(a.variableToNull(t.subject),a.variableToNull(t.predicate),a.variableToNull(t.object),a.variableToNull(t.graph)):n.AsyncIterator.wrap(e.match(a.variableToNull(t.subject),a.variableToNull(t.predicate),a.variableToNull(t.object),a.variableToNull(t.graph))),metadata:a.cachifyMetadata(this.getMetadata(e,t,r,i))}}}t.ActorRdfResolveQuadPatternSource=a},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(189),i=r(3);t.ActorRdfMetadataPrimaryTopic=class extends n.ActorRdfMetadata{constructor(e){super(e)}async test(e){if(e.triples)throw new Error("This actor only supports non-triple quad streams.");return!0}async run(e){const t=new i.Readable({objectMode:!0}),r=new i.Readable({objectMode:!0}),n=()=>{t._read=r._read=()=>{},e.quads.on("error",e=>{t.emit("error",e),r.emit("error",e)});const n={};let i=null;const a={};e.quads.on("data",t=>{"http://rdfs.org/ns/void#subset"===t.predicate.value&&t.object.value===e.url?i=t.subject.value:"http://xmlns.com/foaf/0.1/primaryTopic"===t.predicate.value&&(a[t.object.value]=t.subject.value);let r=n[t.graph.value];r||(r=n[t.graph.value]=[]),r.push(t)}),e.quads.on("end",()=>{const e=i?a[i]:null;for(const i in n)if(i===e){for(const e of n[i])r.push(e);if(this.metadataToData)for(const e of n[i])t.push(e)}else{for(const e of n[i])t.push(e);if(!e&&this.dataToMetadataOnInvalidMetadataGraph)for(const e of n[i])r.push(e)}t.push(null),r.push(null)})};return t._read=r._read=()=>{n()},{data:t,metadata:r}}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(3),i=r(190);t.ActorRdfMetadataQuadPredicate=class extends i.ActorRdfMetadata{constructor(e){super(e)}async run(e){const t=new n.Readable({objectMode:!0}),r=new n.Readable({objectMode:!0}),i=()=>{t._read=r._read=()=>{},e.quads.on("error",e=>{t.emit("error",e),r.emit("error",e)});const n={};e.quads.on("data",i=>{this.isMetadata(i,e.url,n)?r.push(i):t.push(i)}),e.quads.on("end",()=>{t.push(null),r.push(null)})};return t._read=r._read=()=>{i()},{data:t,metadata:r}}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(189),i=r(3);t.ActorRdfMetadataAll=class extends n.ActorRdfMetadata{constructor(e){super(e)}async test(e){return!0}async run(e){const t=new i.Readable({objectMode:!0}),r=new i.Readable({objectMode:!0});return t._read=r._read=()=>{t._read=r._read=()=>{},e.quads.on("error",e=>{t.emit("error",e),r.emit("error",e)}),e.quads.on("data",e=>{t.push(e),r.push(e)}),e.quads.on("end",()=>{t.push(null),r.push(null)})},{data:t,metadata:r}}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(93),i=r(476);class a extends n.ActorRdfMetadataExtract{constructor(e){super(e),this.parsedUriTemplateCache={}}async test(e){return!0}getLinks(e,t){return a.LINK_TYPES.reduce((r,n)=>{const i=t[n]||t[n+"Page"],a=i&&i[e];return a&&a.length>0&&(r[n]=a[0]),r},{})}parseUriTemplateCached(e){const t=this.parsedUriTemplateCache[e];return t||(this.parsedUriTemplateCache[e]=i.parse(e))}getSearchForms(e){const t=e.search,r=[];if(t)for(const n in t)for(const i of t[n]){const t=(e.template||{})[i]||[];if(1!==t.length)throw new Error("Expected 1 hydra:template for "+i);const a=t[0],o=this.parseUriTemplateCached(a),s=((e.mapping||{})[i]||[]).reduce((t,r)=>{const n=((e.variable||{})[r]||[])[0],i=((e.property||{})[r]||[])[0];if(!n)throw new Error("Expected a hydra:variable for "+r);if(!i)throw new Error("Expected a hydra:property for "+r);return t[i]=n,t},{}),c=e=>o.expand(Object.keys(e).reduce((t,r)=>(t[s[r]]=e[r],t),{}));r.push({dataset:n,template:a,mappings:s,getUri:c})}return{values:r}}getHydraProperties(e){return new Promise((t,r)=>{e.on("error",r);const n={};e.on("data",e=>{if(e.predicate.value.startsWith(a.HYDRA)){const t=e.predicate.value.substr(a.HYDRA.length),r=n[t]||(n[t]={});(r[e.subject.value]||(r[e.subject.value]=[])).push(e.object.value)}}),e.on("end",()=>t(n))})}async run(e){const t={},n=await this.getHydraProperties(e.metadata);return r(49)(t,this.getLinks(e.url,n)),t.searchForms=this.getSearchForms(n),{metadata:t}}}a.HYDRA="http://www.w3.org/ns/hydra/core#",a.LINK_TYPES=["first","next","previous","last"],t.ActorRdfMetadataExtractHydraControls=a},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(434),i=r(202),a=r(193),o=r(203);t.ActorRdfMetadataExtractQuery=class extends a.ActorRdfMetadataExtract{constructor(e,t,r){super(r),this.graphqlClient=new n.Client({context:e,queryEngine:new o.GraphQlQueryEngine(this.queryEngine)}),this.sparqlOperation=this.graphqlClient.graphQlToSparql({query:t})}async queryData(e,t){const r=await i.storeStream(e),{data:n}=await this.graphqlClient.query(Object.assign({},await this.sparqlOperation,{queryEngineOptions:{source:{type:"rdfjsSource",value:r},initialBindings:t}}));return n}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(435))},function(e,t,r){"use strict";var n=this&&this.__awaiter||function(e,t,r,n){return new(r||(r=Promise))(function(i,a){function o(e){try{c(n.next(e))}catch(e){a(e)}}function s(e){try{c(n.throw(e))}catch(e){a(e)}}function c(e){e.done?i(e.value):new r(function(t){t(e.value)}).then(o,s)}c((n=n.apply(e,t||[])).next())})};Object.defineProperty(t,"__esModule",{value:!0});const i=r(194),a=r(23),o=r(199);t.Client=class{constructor(e){this.context=(e.contextParser||new a.ContextParser).parse(e.context,{baseIri:e.baseIri}),this.queryEngine=e.queryEngine,this.graphqlToSparqlConverter=e.graphqlToSparqlConverter||new i.Converter({dataFactory:e.dataFactory,requireContext:!0}),this.sparqlJsonToTreeConverter=e.sparqlJsonToTreeConverter||new o.Converter({dataFactory:e.dataFactory,materializeRdfJsTerms:!0})}query(e){return n(this,void 0,void 0,function*(){const{sparqlAlgebra:t,singularizeVariables:r}="query"in e?yield this.graphQlToSparql({query:e.query,variables:e.variables}):e,n=yield this.queryEngine.query(t,e.queryEngineOptions);return{data:this.sparqlJsonToTreeConverter.sparqlJsonResultsToTree(n,{singularizeVariables:r})}})}graphQlToSparql({query:e,variables:t}){return n(this,void 0,void 0,function*(){const t={},r={singularizeVariables:t,variablesDict:{}};return{sparqlAlgebra:yield this.graphqlToSparqlConverter.graphqlToSparqlAlgebra(e,yield this.context,r),singularizeVariables:t}})}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(42);t.DirectiveNodeHandlerInclude=class extends n.DirectiveNodeHandlerAdapter{constructor(e,t){super("include",e,t)}handle(e,t){const r=this.getDirectiveConditionalValue(e.directive,t);return"Literal"===r.termType&&"false"===r.value?{ignore:!0}:{}}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(42);t.DirectiveNodeHandlerOptional=class extends n.DirectiveNodeHandlerAdapter{constructor(e,t){super("optional",e,t)}handle(e,t){return{operationOverrider:e=>this.util.operationFactory.createLeftJoin(this.util.operationFactory.createBgp([]),e)}}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(57),i=r(42);t.DirectiveNodeHandlerPlural=class extends i.DirectiveNodeHandlerAdapter{constructor(e,t){super("plural",e,t)}handle(e,t){return this.isDirectiveScopeAll(e.directive)&&(t.singularizeState=n.SingularizeState.PLURAL),delete t.singularizeVariables[this.util.nameToVariable(e.fieldLabel,t).value],{}}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(57),i=r(42);t.DirectiveNodeHandlerSingle=class extends i.DirectiveNodeHandlerAdapter{constructor(e,t){super("single",e,t)}handle(e,t){return this.isDirectiveScopeAll(e.directive)&&(t.singularizeState=n.SingularizeState.SINGLE),t.singularizeVariables[this.util.nameToVariable(e.fieldLabel,t).value]=!0,{}}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(42);t.DirectiveNodeHandlerSkip=class extends n.DirectiveNodeHandlerAdapter{constructor(e,t){super("skip",e,t)}handle(e,t){const r=this.getDirectiveConditionalValue(e.directive,t);return"Literal"===r.termType&&"true"===r.value?{ignore:!0}:{}}}},function(e,t,r){"use strict";function n(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}Object.defineProperty(t,"__esModule",{value:!0}),n(r(20)),n(r(442)),n(r(443)),n(r(444)),n(r(445)),n(r(446)),n(r(447)),n(r(448)),n(r(449)),n(r(450))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(20);t.NodeValueHandlerBoolean=class extends n.NodeValueHandlerAdapter{constructor(e,t){super("BooleanValue",e,t),this.datatype=this.util.dataFactory.namedNode("http://www.w3.org/2001/XMLSchema#boolean")}handle(e,t,r){return{terms:[this.util.dataFactory.literal(e.value?"true":"false",this.datatype)]}}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(20);t.NodeValueHandlerEnum=class extends n.NodeValueHandlerAdapter{constructor(e,t){super("EnumValue",e,t)}handle(e,t,r){return{terms:[this.util.valueToNamedNode(e.value,r.context)]}}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(20);t.NodeValueHandlerFloat=class extends n.NodeValueHandlerAdapter{constructor(e,t){super("FloatValue",e,t),this.datatype=this.util.dataFactory.namedNode("http://www.w3.org/2001/XMLSchema#float")}handle(e,t,r){return{terms:[this.util.dataFactory.literal(e.value,this.datatype)]}}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(20);t.NodeValueHandlerInt=class extends n.NodeValueHandlerAdapter{constructor(e,t){super("IntValue",e,t),this.datatype=this.util.dataFactory.namedNode("http://www.w3.org/2001/XMLSchema#integer")}handle(e,t,r){return{terms:[this.util.dataFactory.literal(e.value,this.datatype)]}}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(20);t.NodeValueHandlerList=class extends n.NodeValueHandlerAdapter{constructor(e,t){super("ListValue",e,t),this.nodeFirst=this.util.dataFactory.namedNode("http://www.w3.org/1999/02/22-rdf-syntax-ns#first"),this.nodeRest=this.util.dataFactory.namedNode("http://www.w3.org/1999/02/22-rdf-syntax-ns#rest"),this.nodeNil=this.util.dataFactory.namedNode("http://www.w3.org/1999/02/22-rdf-syntax-ns#nil")}handle(e,t,r){const n=[];let i=[];for(const a of e.values){const e=this.util.handleNodeValue(a,t,r);for(const t of e.terms)n.push(t);e.auxiliaryPatterns&&(i=i.concat(e.auxiliaryPatterns))}if(this.settings.arraysToRdfLists){const e=this.util.dataFactory.blankNode();let t=e,a=n.length;for(const e of n){i.push(this.util.operationFactory.createPattern(t,this.nodeFirst,e,r.graph));const n=0==--a?this.nodeNil:this.util.dataFactory.blankNode();i.push(this.util.operationFactory.createPattern(t,this.nodeRest,n,r.graph)),t=n}return{terms:[e],auxiliaryPatterns:i}}return{terms:n,auxiliaryPatterns:i}}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(20);t.NodeValueHandlerNull=class extends n.NodeValueHandlerAdapter{constructor(e,t){super("NullValue",e,t),this.nil=this.util.dataFactory.namedNode("http://www.w3.org/1999/02/22-rdf-syntax-ns#nil")}handle(e,t,r){return{terms:[this.nil]}}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(20);t.NodeValueHandlerObject=class extends n.NodeValueHandlerAdapter{constructor(e,t){super("ObjectValue",e,t)}handle(e,t,r){const n=this.util.dataFactory.blankNode();let i=[];for(const a of e.fields){const e=this.util.handleNodeValue(a.value,t,r);for(const t of e.terms)i.push(this.util.createQuadPattern(n,a.name,t,r.graph,r.context));e.auxiliaryPatterns&&(i=i.concat(e.auxiliaryPatterns))}return{terms:[n],auxiliaryPatterns:i}}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(20);t.NodeValueHandlerString=class extends n.NodeValueHandlerAdapter{constructor(e,t){super("StringValue",e,t)}handle(e,t,r){const n=r.context[t];let i=null,a=null;return n&&"string"!=typeof n&&(n["@language"]?i=n["@language"]:n["@type"]&&(a=this.util.dataFactory.namedNode(n["@type"]))),{terms:[this.util.dataFactory.literal(e.value,i||a)]}}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(20);t.NodeValueHandlerVariable=class extends n.NodeValueHandlerAdapter{constructor(e,t){super("Variable",e,t)}handle(e,t,r){const n=e.name.value,i=r.variablesDict[n],a=r.variablesMetaDict[n];if(!i){if(r.ignoreUnknownVariables||a&&!a.mandatory){const e=this.util.dataFactory.variable(n);return r.terminalVariables.map(e=>e.value).indexOf(n)<0&&r.terminalVariables.push(e),{terms:[e]}}throw new Error(`Undefined variable: ${n}`)}if("Variable"===i.kind)throw new Error(`Variable refers to another variable: ${n}`);if(a)if(a.list){if("ListValue"!==i.kind)throw new Error(`Expected a list, but got ${i.kind} for ${n}`);if(a.type){const e=i;for(const t of e.values)if(t.kind!==a.type)throw new Error(`Expected ${a.type}, but got ${t.kind} for ${n}`)}}else a.type;return this.util.handleNodeValue(i,t,r)}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(94);t.NodeHandlerDefinitionFragment=class extends n.NodeHandlerDefinitionAdapter{constructor(e,t){super("FragmentDefinition",e,t)}handle(e,t){throw new Error("Illegal state: fragment definitions must be indexed and removed before processing")}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(94);t.NodeHandlerDefinitionOperation=class extends n.NodeHandlerDefinitionAdapter{constructor(e,t){super("OperationDefinition",e,t)}handle(e,t){if("query"!==e.operation)throw new Error("Unsupported definition operation: "+e.operation);if(e.variableDefinitions)for(const r of e.variableDefinitions){const e=r.variable.name.value;r.defaultValue&&(t.variablesDict[e]||(t.variablesDict[e]=r.defaultValue));let n=r.type;const i="NonNullType"===n.kind;i&&(n=n.type);const a="ListType"===n.kind;a&&(n=n.type);const o=n.name.value;t.variablesMetaDict[e]={mandatory:i,list:a,type:o}}const r=this.getDirectiveOutputs(e.directives,e.name?e.name.value:"",t);if(!r)return this.util.operationFactory.createBgp([]);const n=this.util.joinOperations(e.selectionSet.selections.map(e=>this.util.handleNode(e,t)));return this.handleDirectiveOutputs(r,n)}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(10),i=r(71);t.NodeHandlerDocument=class extends i.NodeHandlerAdapter{constructor(e,t){super("Document",e,t)}handle(e,t){const r=this.util.operationFactory.createProject(e.definitions.map(e=>{const r=this.getNodeQuadContextDefinitionNode(e,Object.assign({},t,{ignoreUnknownVariables:!0})),n=Object.assign({},t,{graph:r.graph||t.graph,subject:r.subject||this.util.dataFactory.blankNode()});let i=this.util.handleNode(e,n);return r&&r.auxiliaryPatterns&&(i=this.util.joinOperations([i,this.util.operationFactory.createBgp(r.auxiliaryPatterns)])),i}).reduce((e,t)=>t?e?this.util.operationFactory.createUnion(e,t):t:e,null),t.terminalVariables);return this.translateBlankNodesToVariables(r)}getNodeQuadContextDefinitionNode(e,t){return"OperationDefinition"===e.kind?this.getNodeQuadContextSelectionSet(e.selectionSet,e.name?e.name.value:"",t):null}translateBlankNodesToVariables(e){const t=this,r={},i=Array.from(e.variables).reduce((e,t)=>(e[t.value]=!0,e),{});return n.Util.mapOperation(e,{path:(e,t)=>({recurse:!1,result:t.createPath(a(e.subject),e.predicate,a(e.object),a(e.graph))}),pattern:(e,t)=>({recurse:!1,result:t.createPattern(a(e.subject),a(e.predicate),a(e.object),a(e.graph))})});function a(e){if("BlankNode"===e.termType){let a=r[e.value];return a||(a=n.Util.createUniqueVariable(e.value,i,t.util.dataFactory),i[a.value]=!0,r[e.value]=a),a}return e}}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(72),i=r(73),a=r(197),o=r(95).Parser,s=r(460),c=n.types;let u,l=new Set,f=0,d=!1;function h(e,t,r){if(l=new Set,f=0,d=t,"query"!==e.type)throw new Error("Translate only works on complete query objects.");let n={type:"group",patterns:e.where||[]},i=new Set(Object.keys(function e(t){let r={};if(y(t))r[t]=!0,l.add(t);else if(n=t,null!==n&&"object"==typeof n)if("bind"===t.type)e(t.expression),Object.assign(r,e(t.variable));else if("SELECT"===t.queryType){let n=e(t.where);for(let i of t.variables)"*"===i?Object.assign(r,n):i.variable?Object.assign(r,e(i.variable)):Object.assign(r,e(i));if(t.group)for(let n of t.group)Object.assign(r,e(n))}else for(let n of Object.keys(t))Object.assign(r,e(t[n]));var n;return r}(n)).map(u.createTerm.bind(u))),o=m(n);return o=function(e,t,r){let n=[],i={};if(e.variables=O(e.variables,i),e.having=O(e.having,i),e.order=O(e.order,i),e.group||Object.keys(i).length>0){let r=Object.keys(i).map(e=>(function(e,t){if("aggregate"!==e.type||!e.aggregation)throw new Error("Unexpected input: "+JSON.stringify(e));let r=g(e);return r.variable=t,r})(i[e],u.createTerm(e))),n=[];if(e.group)for(let r of e.group)if(r.expression.type){const e=r.variable?u.createTerm(r.variable):_();t=u.createExtend(t,e,g(r.expression)),n.push(e)}else n.push(u.createTerm(r.expression));t=u.createGroup(t,n,r)}if(e.having)for(let r of e.having)t=u.createFilter(t,g(r));e.values&&(t=u.createJoin(t,T(e)));let a=new Set;if("SELECT"===e.queryType||"DESCRIBE"===e.queryType)if(e.variables.indexOf("*")>=0)a=r;else for(let t of e.variables)y(t)||!t.variable?a.add(u.createTerm(t)):t.variable&&(a.add(u.createTerm(t.variable)),n.push(t));for(let e of n)t=u.createExtend(t,u.createTerm(e.variable),g(e.expression));e.order&&(t=u.createOrderBy(t,e.order.map(e=>{let t=g(e.expression);return e.descending&&(t=u.createOperatorExpression(c.DESC,[t])),t})));"SELECT"===e.queryType&&(t=u.createProject(t,Array.from(a)));e.distinct&&(t=u.createDistinct(t));e.reduced&&(t=u.createReduced(t));(e.offset||e.limit)&&(t=u.createSlice(t,e.offset,e.limit));"CONSTRUCT"===e.queryType?t=u.createConstruct(t,e.template.map(w)):"ASK"===e.queryType?t=u.createAsk(t):"DESCRIBE"===e.queryType&&(t=u.createDescribe(t,Array.from(a)));e.from&&(t=u.createFrom(t,e.from.default.map(u.createTerm.bind(u)),e.from.named.map(u.createTerm.bind(u))));return t}(e,o,i),r&&(o=function e(t,r){const n={};const i=Array.from(r).reduce((e,t)=>(e[t.value]=!0,e),{});return a.default.mapOperation(t,{path:(e,t)=>({result:t.createPath(o(e.subject),e.predicate,o(e.object),o(e.graph)),recurse:!1}),pattern:(e,t)=>({result:t.createPattern(o(e.subject),o(e.predicate),o(e.object),o(e.graph)),recurse:!1}),construct:t=>({result:u.createConstruct(e(t.input,r),t.template),recurse:!1})});function o(e){if("BlankNode"===e.termType){let t=n[e.value];return t||(t=a.default.createUniqueVariable(e.value,i,u.dataFactory),i[t.value]=!0,n[e.value]=t),t}return e}}(o,i)),o}function p(e){return"string"==typeof e}function y(e){return p(e)&&"?"===e[0]&&e.length>1}function m(e){let t,r=[],n=[];if(e.patterns)for(let t of e.patterns)("filter"===t.type?r:n).push(t);if("bgp"===e.type)return function(e){let t=[],r=[];for(let n of e.triples)if("path"===n.predicate.type){let e=b(n);for(let n of e)n.type===c.PATH?(t.length>0&&r.push(u.createBgp(t)),t=[],r.push(n)):t.push(n)}else t.push(w(n));t.length>0&&r.push(u.createBgp(t));return 1===r.length?r[0]:r.reduce((e,t)=>u.createJoin(e,t))}(e);if("union"===e.type)t=n.map(e=>("group"!==e.type&&(e={type:"group",patterns:[e]}),m(e))).reduce((e,t)=>u.createUnion(e,t));else{if("graph"===e.type)return function(e){let t=u.createTerm(e.name);e.type="group";let r=m(e);r=d?function e(t,r){if(t.type===c.BGP)t.patterns=t.patterns.map(e=>(e.graph=r,e));else if(t.type===c.PATH)t.graph=r;else for(let n of Object.keys(t))Array.isArray(t[n])?t[n]=t[n].map(t=>e(t,r)):S.indexOf(t[n].type)>=0&&(t[n]=e(t[n],r));return t}(r,t):u.createGraph(r,t);return r}(e);if("group"===e.type)t=n.reduce(E,u.createBgp([]));else if("values"===e.type)t=T(e);else{if("query"!==e.type)throw new Error("Unexpected type: "+e.type);t=h(e,d,!1)}}if(r.length>0){let e=r.map(e=>g(e.expression));e.length>0&&(t=u.createFilter(t,e.reduce((e,t)=>u.createOperatorExpression("&&",[e,t]))))}return t}function g(e){if(p(e))return u.createTermExpression(u.createTerm(e));if(e.aggregation)return u.createAggregateExpression(e.aggregation,g(e.expression),e.distinct,e.separator);if(e.function)return u.createNamedExpression(u.createTerm(e.function),e.args.map(g));if(e.operator)return"exists"===e.operator||"notexists"===e.operator?u.createExistenceExpression("notexists"===e.operator,m(e.args[0])):("in"!==e.operator&&"notin"!==e.operator||(e.args=[e.args[0]].concat(e.args[1])),u.createOperatorExpression(e.operator,e.args.map(g)));throw new Error("Unknown expression: "+JSON.stringify(e))}function b(e){return function e(t,r,n){if(r.type===c.LINK)return[u.createPattern(t,r.iri,n)];if(r.type===c.INV)return e(n,r.path,t);if(r.type===c.SEQ){let i=_(),a=e(t,r.left,i),o=e(i,r.right,n);return a.concat(o)}return[u.createPath(t,r,n)]}(u.createTerm(e.subject),v(e.predicate),u.createTerm(e.object))}function v(e){if(p(e))return u.createLink(u.createTerm(e));if("^"===e.pathType)return u.createInv(v(e.items[0]));if("!"===e.pathType){let t,r=[],n=[];t="path"===e.items[0].type&&"|"===e.items[0].pathType?e.items[0].items:e.items;for(let e of t)if(p(e))r.push(e);else{if("^"!==e.pathType)throw new Error("Unexpected item: "+JSON.stringify(e));n.push(e.items[0])}let i=u.createNps(r.map(u.createTerm.bind(u))),a=u.createInv(u.createNps(n.map(u.createTerm.bind(u))));return 0===n.length?i:0===r.length?a:u.createAlt(i,a)}if("/"===e.pathType)return e.items.map(v).reduce((e,t)=>u.createSeq(e,t));if("|"===e.pathType)return e.items.map(v).reduce((e,t)=>u.createAlt(e,t));if("*"===e.pathType)return u.createZeroOrMorePath(v(e.items[0]));if("+"===e.pathType)return u.createOneOrMorePath(v(e.items[0]));if("?"===e.pathType)return u.createZeroOrOnePath(v(e.items[0]));throw new Error("Unable to translate path expression "+e)}function _(){let e="?var"+f++;return l.has(e)?_():(l.add(e),u.createTerm(e))}function w(e){return u.createPattern(u.createTerm(e.subject),u.createTerm(e.predicate),u.createTerm(e.object))}t.default=function(e,t){if(t=t||{},u=new i.default(t.dataFactory),p(e)){let r=new o(t.prefixes,t.baseIRI);r._resetBlanks(),e=r.parse(e)}return h(e,t.quads,t.blankToVariable)};let S=Object.keys(c).map(e=>c[e]);function E(e,t){if("optional"===t.type){let r=m({type:"group",patterns:t.patterns});if(r.type===c.FILTER){let t=r;e=u.createLeftJoin(e,t.input,t.expression)}else e=u.createLeftJoin(e,r)}else if("minus"===t.type){let r=m({type:"group",patterns:t.patterns});e=u.createMinus(e,r)}else if("bind"===t.type)e=u.createExtend(e,u.createTerm(t.variable),g(t.expression));else if("service"===t.type){t.type="group",e=x(e,u.createService(m(t),u.createTerm(t.name),t.silent))}else{e=x(e,m(t))}return e}function x(e,t){return e.type===c.BGP&&t.type===c.BGP?e=u.createBgp([].concat(e.patterns,t.patterns)):e.type===c.BGP&&0===e.patterns.length?e=t:t.type===c.BGP&&0===t.patterns.length||(e=u.createJoin(e,t)),e}function T(e){let t=(0===e.values.length?[]:Object.keys(e.values[0])).map(u.createTerm.bind(u)),r=e.values.map(e=>{let t=Object.keys(e);t=t.filter(t=>void 0!==e[t]);let r={};for(let n of t)r[n]=u.createTerm(e[n]);return r});return u.createValues(t,r)}function O(e,t){if(!e)return e;if("aggregate"===e.type){let r,n=!1;for(let i of Object.keys(t))if(s(t[i],e)){r=i,n=!0;break}return n||(r="?"+_().value,t[r]=e),r}return e.expression?e.expression=O(e.expression,t):e.args?O(e.args,t):Array.isArray(e)&&e.forEach((r,n)=>e[n]=O(r,t)),e}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(5);function i(e){if(!e)return null;switch(e.termType){case"NamedNode":return e.value;case"BlankNode":return"_:"+e.value;case"Literal":const t=e;return'"'+t.value+'"'+(t.datatype&&"http://www.w3.org/2001/XMLSchema#string"!==t.datatype.value&&"http://www.w3.org/1999/02/22-rdf-syntax-ns#langString"!==t.datatype.value?"^^"+t.datatype.value:"")+(t.language?"@"+t.language:"");case"Variable":return"?"+e.value;case"DefaultGraph":return e.value}}function a(e){const t=/^"([^]*)"/.exec(e);if(!t)throw new Error(e+" is not a literal");return t[1]}function o(e){const t=/^"[^]*"(?:\^\^([^"]+)|(@)[^@"]+)?$/.exec(e);if(!t)throw new Error(e+" is not a literal");return t[1]||(t[2]?"http://www.w3.org/1999/02/22-rdf-syntax-ns#langString":"http://www.w3.org/2001/XMLSchema#string")}function s(e){const t=/^"[^]*"(?:@([^@"]+)|\^\^[^"]+)?$/.exec(e);if(!t)throw new Error(e+" is not a literal");return t[1]?t[1].toLowerCase():""}function c(e,t){if(t=t||n,!e||!e.length)return t.defaultGraph();switch(e[0]){case"_":return t.blankNode(e.substr(2));case"?":return t.variable(e.substr(1));case'"':const r=s(e),n=t.namedNode(o(e));return t.literal(a(e),r||n);default:return t.namedNode(e)}}t.termToString=i,t.getLiteralValue=a,t.getLiteralType=o,t.getLiteralLanguage=s,t.stringToTerm=c,t.quadToStringQuad=function(e){return{subject:i(e.subject),predicate:i(e.predicate),object:i(e.object),graph:i(e.graph)}},t.stringQuadToQuad=function(e,t){return(t=t||n).quad(c(e.subject,t),c(e.predicate,t),c(e.object,t),c(e.graph,t))}},function(e,t,r){(function(e,n){var i=function(){var e=function(e,t,r,n){for(r=r||{},n=e.length;n--;r[e[n]]=t);return r},t=[6,12,15,24,34,43,48,99,109,112,114,115,124,125,130,298,299,300,301,302],r=[2,196],n=[99,109,112,114,115,124,125,130,298,299,300,301,302],i=[1,18],a=[1,27],o=[6,83],s=[38,39,51],c=[38,51],u=[1,55],l=[1,57],f=[1,53],d=[1,56],h=[28,29,293],p=[13,16,286],y=[111,133,296,303],m=[13,16,111,133,286],g=[1,80],b=[1,84],v=[1,86],_=[111,133,296,297,303],w=[13,16,111,133,286,297],S=[1,92],E=[2,236],x=[1,91],T=[13,16,28,29,80,86,215,218,219,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286],O=[6,38,39,51,61,68,71,79,81,83],A=[6,13,16,28,38,39,51,61,68,71,79,81,83,286],I=[6,13,16,28,29,31,32,38,39,41,51,61,68,71,79,80,81,83,86,92,108,111,124,125,127,132,159,160,162,165,166,183,187,208,213,215,216,218,219,223,227,231,246,251,268,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,293,304,306,307,309,310,311,312,313,314,315,316],N=[1,107],R=[1,108],k=[6,13,16,28,29,39,41,80,83,86,111,159,160,162,165,166,215,218,219,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,304],P=[2,295],j=[1,125],D=[1,123],C=[6,183],M=[2,312],L=[2,300],q=[38,127],F=[6,41,68,71,79,81,83],B=[2,238],U=[1,139],V=[1,141],H=[1,151],z=[1,157],G=[1,160],Q=[1,156],X=[1,158],$=[1,154],J=[1,155],Y=[1,161],K=[1,162],W=[1,165],Z=[1,166],ee=[1,167],te=[1,168],re=[1,169],ne=[1,170],ie=[1,171],ae=[1,172],oe=[1,173],se=[1,174],ce=[1,175],ue=[1,176],le=[6,61,68,71,79,81,83],fe=[28,29,38,39,51],de=[13,16,28,29,80,248,249,250,252,254,255,257,258,261,263,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,316,317,318,319,320,321],he=[2,409],pe=[1,189],ye=[1,190],me=[1,191],ge=[13,16,41,80,92,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286],be=[41,86],ve=[28,32],_e=[6,108,183],we=[41,111],Se=[6,41,71,79,81,83],Ee=[2,324],xe=[2,316],Te=[1,226],Oe=[1,228],Ae=[41,111,304],Ie=[13,16,28,29,32,39,41,80,83,86,111,159,160,162,165,166,183,187,208,213,215,216,218,219,251,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,304],Ne=[13,16,28,29,31,32,39,41,80,83,86,92,111,159,160,162,165,166,183,187,208,213,215,216,218,219,223,227,231,246,251,268,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,293,304,307,310,311,312,313,314,315,316],Re=[13,16,28,29,31,32,39,41,80,83,86,92,111,159,160,162,165,166,183,187,208,213,215,216,218,219,223,227,231,246,251,268,270,271,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,293,304,307,310,311,312,313,314,315,316],ke=[31,32,183,223,251],Pe=[31,32,183,223,227,251],je=[31,32,183,223,227,231,246,251,268,280,281,282,283,284,285,310,311,312,313,314,315,316],De=[31,32,183,223,227,231,246,251,268,280,281,282,283,284,285,293,307,310,311,312,313,314,315,316],Ce=[1,260],Me=[1,261],Le=[1,263],qe=[1,264],Fe=[1,265],Be=[1,266],Ue=[1,268],Ve=[1,269],He=[2,416],ze=[1,271],Ge=[1,272],Qe=[1,273],Xe=[1,279],$e=[1,274],Je=[1,275],Ye=[1,276],Ke=[1,277],We=[1,278],Ze=[1,286],et=[1,299],tt=[6,41,79,81,83],rt=[1,316],nt=[1,315],it=[39,41,83,111,159,160,162,165,166],at=[1,324],ot=[1,325],st=[41,111,183,216,304],ct=[2,354],ut=[13,16,28,29,32,80,86,215,218,219,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286],lt=[13,16,28,29,32,39,41,80,83,86,111,159,160,162,165,166,183,215,216,218,219,251,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,304],ft=[13,16,28,29,80,208,246,248,249,250,252,254,255,257,258,261,263,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,310,316,317,318,319,320,321],dt=[1,349],ht=[1,350],pt=[1,352],yt=[1,351],mt=[6,13,16,28,29,31,32,39,41,68,71,74,76,79,80,81,83,86,111,159,160,162,165,166,183,215,218,219,223,227,231,246,248,249,250,251,252,254,255,257,258,261,263,268,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,293,304,307,310,311,312,313,314,315,316,317,318,319,320,321],gt=[1,360],bt=[1,359],vt=[29,86],_t=[13,16,32,41,80,92,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286],wt=[29,41],St=[2,315],Et=[6,41,83],xt=[6,13,16,29,41,71,79,81,83,248,249,250,252,254,255,257,258,261,263,286,316,317,318,319,320,321],Tt=[6,13,16,28,29,39,41,71,74,76,79,80,81,83,86,111,159,160,162,165,166,215,218,219,248,249,250,252,254,255,257,258,261,263,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,304,316,317,318,319,320,321],Ot=[6,13,16,28,29,41,68,71,79,81,83,248,249,250,252,254,255,257,258,261,263,286,316,317,318,319,320,321],At=[6,13,16,28,29,31,32,39,41,61,68,71,74,76,79,80,81,83,86,111,159,160,162,165,166,183,215,218,219,223,227,231,246,248,249,250,251,252,254,255,257,258,261,263,268,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,293,304,305,307,310,311,312,313,314,315,316,317,318,319,320,321],It=[13,16,29,187,208,213,286],Nt=[2,366],Rt=[1,401],kt=[39,41,83,111,159,160,162,165,166,304],Pt=[13,16,28,29,32,39,41,80,83,86,111,159,160,162,165,166,183,187,215,216,218,219,251,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,304],jt=[13,16,28,29,80,208,246,248,249,250,252,254,255,257,258,261,263,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,293,310,316,317,318,319,320,321],Dt=[1,450],Ct=[1,447],Mt=[1,448],Lt=[13,16,28,29,39,41,80,83,86,111,159,160,162,165,166,215,218,219,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286],qt=[13,16,28,286],Ft=[13,16,28,29,39,41,80,83,86,111,159,160,162,165,166,215,218,219,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,304],Bt=[2,327],Ut=[39,41,83,111,159,160,162,165,166,183,216,304],Vt=[6,13,16,28,29,41,74,76,79,81,83,248,249,250,252,254,255,257,258,261,263,286,316,317,318,319,320,321],Ht=[2,322],zt=[13,16,29,187,208,286],Gt=[13,16,32,80,92,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286],Qt=[13,16,28,29,41,80,86,111,215,218,219,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286],Xt=[13,16,28,29,32,80,86,215,218,219,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,306,307],$t=[13,16,28,29,32,80,86,215,218,219,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,293,306,307,309,310],Jt=[1,561],Yt=[1,562],Kt=[2,310],Wt=[13,16,32,187,213,286],Zt={trace:function(){},yy:{},symbols_:{error:2,QueryOrUpdate:3,Prologue:4,QueryOrUpdate_group0:5,EOF:6,Prologue_repetition0:7,Query:8,Query_group0:9,Query_option0:10,BaseDecl:11,BASE:12,IRIREF:13,PrefixDecl:14,PREFIX:15,PNAME_NS:16,SelectQuery:17,SelectClause:18,SelectQuery_repetition0:19,WhereClause:20,SolutionModifier:21,SubSelect:22,SubSelect_option0:23,SELECT:24,SelectClause_option0:25,SelectClause_group0:26,SelectClauseItem:27,VAR:28,"(":29,Expression:30,AS:31,")":32,ConstructQuery:33,CONSTRUCT:34,ConstructTemplate:35,ConstructQuery_repetition0:36,ConstructQuery_repetition1:37,WHERE:38,"{":39,ConstructQuery_option0:40,"}":41,DescribeQuery:42,DESCRIBE:43,DescribeQuery_group0:44,DescribeQuery_repetition0:45,DescribeQuery_option0:46,AskQuery:47,ASK:48,AskQuery_repetition0:49,DatasetClause:50,FROM:51,DatasetClause_option0:52,iri:53,WhereClause_option0:54,GroupGraphPattern:55,SolutionModifier_option0:56,SolutionModifier_option1:57,SolutionModifier_option2:58,SolutionModifier_option3:59,GroupClause:60,GROUP:61,BY:62,GroupClause_repetition_plus0:63,GroupCondition:64,BuiltInCall:65,FunctionCall:66,HavingClause:67,HAVING:68,HavingClause_repetition_plus0:69,OrderClause:70,ORDER:71,OrderClause_repetition_plus0:72,OrderCondition:73,ASC:74,BrackettedExpression:75,DESC:76,Constraint:77,LimitOffsetClauses:78,LIMIT:79,INTEGER:80,OFFSET:81,ValuesClause:82,VALUES:83,InlineData:84,InlineData_repetition0:85,NIL:86,InlineData_repetition1:87,InlineData_repetition_plus2:88,InlineData_repetition3:89,DataBlockValue:90,Literal:91,UNDEF:92,DataBlockValueList:93,DataBlockValueList_repetition_plus0:94,Update:95,Update_repetition0:96,Update1:97,Update_option0:98,LOAD:99,Update1_option0:100,Update1_option1:101,Update1_group0:102,Update1_option2:103,GraphRefAll:104,Update1_group1:105,Update1_option3:106,GraphOrDefault:107,TO:108,CREATE:109,Update1_option4:110,GRAPH:111,INSERTDATA:112,QuadPattern:113,DELETEDATA:114,DELETEWHERE:115,Update1_option5:116,InsertClause:117,Update1_option6:118,Update1_repetition0:119,Update1_option7:120,DeleteClause:121,Update1_option8:122,Update1_repetition1:123,DELETE:124,INSERT:125,UsingClause:126,USING:127,UsingClause_option0:128,WithClause:129,WITH:130,IntoGraphClause:131,INTO:132,DEFAULT:133,GraphOrDefault_option0:134,GraphRefAll_group0:135,QuadPattern_option0:136,QuadPattern_repetition0:137,QuadsNotTriples:138,QuadsNotTriples_group0:139,QuadsNotTriples_option0:140,QuadsNotTriples_option1:141,QuadsNotTriples_option2:142,TriplesTemplate:143,TriplesTemplate_repetition0:144,TriplesSameSubject:145,TriplesTemplate_option0:146,GroupGraphPatternSub:147,GroupGraphPatternSub_option0:148,GroupGraphPatternSub_repetition0:149,GroupGraphPatternSubTail:150,GraphPatternNotTriples:151,GroupGraphPatternSubTail_option0:152,GroupGraphPatternSubTail_option1:153,TriplesBlock:154,TriplesBlock_repetition0:155,TriplesSameSubjectPath:156,TriplesBlock_option0:157,GraphPatternNotTriples_repetition0:158,OPTIONAL:159,MINUS:160,GraphPatternNotTriples_group0:161,SERVICE:162,GraphPatternNotTriples_option0:163,GraphPatternNotTriples_group1:164,FILTER:165,BIND:166,FunctionCall_option0:167,FunctionCall_repetition0:168,ExpressionList:169,ExpressionList_repetition0:170,ConstructTemplate_option0:171,ConstructTriples:172,ConstructTriples_repetition0:173,ConstructTriples_option0:174,VarOrTerm:175,PropertyListNotEmpty:176,TriplesNode:177,PropertyList:178,PropertyList_option0:179,VerbObjectList:180,PropertyListNotEmpty_repetition0:181,SemiOptionalVerbObjectList:182,";":183,SemiOptionalVerbObjectList_option0:184,Verb:185,ObjectList:186,a:187,ObjectList_repetition0:188,GraphNode:189,PropertyListPathNotEmpty:190,TriplesNodePath:191,TriplesSameSubjectPath_option0:192,PropertyListPathNotEmpty_group0:193,PropertyListPathNotEmpty_repetition0:194,GraphNodePath:195,PropertyListPathNotEmpty_repetition1:196,PropertyListPathNotEmptyTail:197,PropertyListPathNotEmptyTail_group0:198,Path:199,Path_repetition0:200,PathSequence:201,PathSequence_repetition0:202,PathEltOrInverse:203,PathElt:204,PathPrimary:205,PathElt_option0:206,PathEltOrInverse_option0:207,"!":208,PathNegatedPropertySet:209,PathOneInPropertySet:210,PathNegatedPropertySet_repetition0:211,PathNegatedPropertySet_option0:212,"^":213,TriplesNode_repetition_plus0:214,"[":215,"]":216,TriplesNodePath_repetition_plus0:217,BLANK_NODE_LABEL:218,ANON:219,ConditionalAndExpression:220,Expression_repetition0:221,ExpressionTail:222,"||":223,RelationalExpression:224,ConditionalAndExpression_repetition0:225,ConditionalAndExpressionTail:226,"&&":227,AdditiveExpression:228,RelationalExpression_group0:229,RelationalExpression_option0:230,IN:231,MultiplicativeExpression:232,AdditiveExpression_repetition0:233,AdditiveExpressionTail:234,AdditiveExpressionTail_group0:235,NumericLiteralPositive:236,AdditiveExpressionTail_repetition0:237,NumericLiteralNegative:238,AdditiveExpressionTail_repetition1:239,UnaryExpression:240,MultiplicativeExpression_repetition0:241,MultiplicativeExpressionTail:242,MultiplicativeExpressionTail_group0:243,UnaryExpression_option0:244,PrimaryExpression:245,"-":246,Aggregate:247,FUNC_ARITY0:248,FUNC_ARITY1:249,FUNC_ARITY2:250,",":251,IF:252,BuiltInCall_group0:253,BOUND:254,BNODE:255,BuiltInCall_option0:256,EXISTS:257,COUNT:258,Aggregate_option0:259,Aggregate_group0:260,FUNC_AGGREGATE:261,Aggregate_option1:262,GROUP_CONCAT:263,Aggregate_option2:264,Aggregate_option3:265,GroupConcatSeparator:266,SEPARATOR:267,"=":268,String:269,LANGTAG:270,"^^":271,DECIMAL:272,DOUBLE:273,true:274,false:275,STRING_LITERAL1:276,STRING_LITERAL2:277,STRING_LITERAL_LONG1:278,STRING_LITERAL_LONG2:279,INTEGER_POSITIVE:280,DECIMAL_POSITIVE:281,DOUBLE_POSITIVE:282,INTEGER_NEGATIVE:283,DECIMAL_NEGATIVE:284,DOUBLE_NEGATIVE:285,PNAME_LN:286,QueryOrUpdate_group0_option0:287,Prologue_repetition0_group0:288,SelectClause_option0_group0:289,DISTINCT:290,REDUCED:291,SelectClause_group0_repetition_plus0:292,"*":293,DescribeQuery_group0_repetition_plus0_group0:294,DescribeQuery_group0_repetition_plus0:295,NAMED:296,SILENT:297,CLEAR:298,DROP:299,ADD:300,MOVE:301,COPY:302,ALL:303,".":304,UNION:305,"|":306,"/":307,PathElt_option0_group0:308,"?":309,"+":310,"!=":311,"<":312,">":313,"<=":314,">=":315,NOT:316,CONCAT:317,COALESCE:318,SUBSTR:319,REGEX:320,REPLACE:321,$accept:0,$end:1},terminals_:{2:"error",6:"EOF",12:"BASE",13:"IRIREF",15:"PREFIX",16:"PNAME_NS",24:"SELECT",28:"VAR",29:"(",31:"AS",32:")",34:"CONSTRUCT",38:"WHERE",39:"{",41:"}",43:"DESCRIBE",48:"ASK",51:"FROM",61:"GROUP",62:"BY",68:"HAVING",71:"ORDER",74:"ASC",76:"DESC",79:"LIMIT",80:"INTEGER",81:"OFFSET",83:"VALUES",86:"NIL",92:"UNDEF",99:"LOAD",108:"TO",109:"CREATE",111:"GRAPH",112:"INSERTDATA",114:"DELETEDATA",115:"DELETEWHERE",124:"DELETE",125:"INSERT",127:"USING",130:"WITH",132:"INTO",133:"DEFAULT",159:"OPTIONAL",160:"MINUS",162:"SERVICE",165:"FILTER",166:"BIND",183:";",187:"a",208:"!",213:"^",215:"[",216:"]",218:"BLANK_NODE_LABEL",219:"ANON",223:"||",227:"&&",231:"IN",246:"-",248:"FUNC_ARITY0",249:"FUNC_ARITY1",250:"FUNC_ARITY2",251:",",252:"IF",254:"BOUND",255:"BNODE",257:"EXISTS",258:"COUNT",261:"FUNC_AGGREGATE",263:"GROUP_CONCAT",267:"SEPARATOR",268:"=",270:"LANGTAG",271:"^^",272:"DECIMAL",273:"DOUBLE",274:"true",275:"false",276:"STRING_LITERAL1",277:"STRING_LITERAL2",278:"STRING_LITERAL_LONG1",279:"STRING_LITERAL_LONG2",280:"INTEGER_POSITIVE",281:"DECIMAL_POSITIVE",282:"DOUBLE_POSITIVE",283:"INTEGER_NEGATIVE",284:"DECIMAL_NEGATIVE",285:"DOUBLE_NEGATIVE",286:"PNAME_LN",290:"DISTINCT",291:"REDUCED",293:"*",296:"NAMED",297:"SILENT",298:"CLEAR",299:"DROP",300:"ADD",301:"MOVE",302:"COPY",303:"ALL",304:".",305:"UNION",306:"|",307:"/",309:"?",310:"+",311:"!=",312:"<",313:">",314:"<=",315:">=",316:"NOT",317:"CONCAT",318:"COALESCE",319:"SUBSTR",320:"REGEX",321:"REPLACE"},productions_:[0,[3,3],[4,1],[8,2],[11,2],[14,3],[17,4],[22,4],[18,3],[27,1],[27,5],[33,5],[33,7],[42,5],[47,4],[50,3],[20,2],[21,4],[60,3],[64,1],[64,1],[64,3],[64,5],[64,1],[67,2],[70,3],[73,2],[73,2],[73,1],[73,1],[78,2],[78,2],[78,4],[78,4],[82,2],[84,4],[84,4],[84,6],[90,1],[90,1],[90,1],[93,3],[95,3],[97,4],[97,3],[97,5],[97,4],[97,2],[97,2],[97,2],[97,6],[97,6],[121,2],[117,2],[126,3],[129,2],[131,3],[107,1],[107,2],[104,2],[104,1],[113,4],[138,7],[143,3],[55,3],[55,3],[147,2],[150,3],[154,3],[151,2],[151,2],[151,2],[151,3],[151,4],[151,2],[151,6],[151,1],[77,1],[77,1],[77,1],[66,2],[66,6],[169,1],[169,4],[35,3],[172,3],[145,2],[145,2],[178,1],[176,2],[182,2],[180,2],[185,1],[185,1],[185,1],[186,2],[156,2],[156,2],[190,4],[197,1],[197,3],[199,2],[201,2],[204,2],[203,2],[205,1],[205,1],[205,2],[205,3],[209,1],[209,1],[209,4],[210,1],[210,1],[210,2],[210,2],[177,3],[177,3],[191,3],[191,3],[189,1],[189,1],[195,1],[195,1],[175,1],[175,1],[175,1],[175,1],[175,1],[175,1],[30,2],[222,2],[220,2],[226,2],[224,1],[224,3],[224,4],[228,2],[234,2],[234,2],[234,2],[232,2],[242,2],[240,2],[240,2],[240,2],[245,1],[245,1],[245,1],[245,1],[245,1],[245,1],[75,3],[65,1],[65,2],[65,4],[65,6],[65,8],[65,2],[65,4],[65,2],[65,4],[65,3],[247,5],[247,5],[247,6],[266,4],[91,1],[91,2],[91,3],[91,1],[91,1],[91,1],[91,1],[91,1],[91,1],[91,1],[269,1],[269,1],[269,1],[269,1],[236,1],[236,1],[236,1],[238,1],[238,1],[238,1],[53,1],[53,1],[53,1],[287,0],[287,1],[5,1],[5,1],[288,1],[288,1],[7,0],[7,2],[9,1],[9,1],[9,1],[9,1],[10,0],[10,1],[19,0],[19,2],[23,0],[23,1],[289,1],[289,1],[25,0],[25,1],[292,1],[292,2],[26,1],[26,1],[36,0],[36,2],[37,0],[37,2],[40,0],[40,1],[294,1],[294,1],[295,1],[295,2],[44,1],[44,1],[45,0],[45,2],[46,0],[46,1],[49,0],[49,2],[52,0],[52,1],[54,0],[54,1],[56,0],[56,1],[57,0],[57,1],[58,0],[58,1],[59,0],[59,1],[63,1],[63,2],[69,1],[69,2],[72,1],[72,2],[85,0],[85,2],[87,0],[87,2],[88,1],[88,2],[89,0],[89,2],[94,1],[94,2],[96,0],[96,4],[98,0],[98,2],[100,0],[100,1],[101,0],[101,1],[102,1],[102,1],[103,0],[103,1],[105,1],[105,1],[105,1],[106,0],[106,1],[110,0],[110,1],[116,0],[116,1],[118,0],[118,1],[119,0],[119,2],[120,0],[120,1],[122,0],[122,1],[123,0],[123,2],[128,0],[128,1],[134,0],[134,1],[135,1],[135,1],[135,1],[136,0],[136,1],[137,0],[137,2],[139,1],[139,1],[140,0],[140,1],[141,0],[141,1],[142,0],[142,1],[144,0],[144,3],[146,0],[146,1],[148,0],[148,1],[149,0],[149,2],[152,0],[152,1],[153,0],[153,1],[155,0],[155,3],[157,0],[157,1],[158,0],[158,3],[161,1],[161,1],[163,0],[163,1],[164,1],[164,1],[167,0],[167,1],[168,0],[168,3],[170,0],[170,3],[171,0],[171,1],[173,0],[173,3],[174,0],[174,1],[179,0],[179,1],[181,0],[181,2],[184,0],[184,1],[188,0],[188,3],[192,0],[192,1],[193,1],[193,1],[194,0],[194,3],[196,0],[196,2],[198,1],[198,1],[200,0],[200,3],[202,0],[202,3],[308,1],[308,1],[308,1],[206,0],[206,1],[207,0],[207,1],[211,0],[211,3],[212,0],[212,1],[214,1],[214,2],[217,1],[217,2],[221,0],[221,2],[225,0],[225,2],[229,1],[229,1],[229,1],[229,1],[229,1],[229,1],[230,0],[230,1],[233,0],[233,2],[235,1],[235,1],[237,0],[237,2],[239,0],[239,2],[241,0],[241,2],[243,1],[243,1],[244,0],[244,1],[253,1],[253,1],[253,1],[253,1],[253,1],[256,0],[256,1],[259,0],[259,1],[260,1],[260,1],[262,0],[262,1],[264,0],[264,1],[265,0],[265,1]],performAction:function(e,t,r,n,i,a,o){var s,c,u=a.length-1;switch(i){case 1:return a[u-1]=a[u-1]||{},Fr.base&&(a[u-1].base=Fr.base),Fr.base=dr=hr=pr="",a[u-1].prefixes=Fr.prefixes,Fr.prefixes=null,a[u-1];case 3:this.$=br(a[u-1],a[u],{type:"query"});break;case 4:Fr.base=_r(a[u]),dr=hr=pr="";break;case 5:Fr.prefixes||(Fr.prefixes={}),a[u-1]=a[u-1].substr(0,a[u-1].length-1),a[u]=_r(a[u]),Fr.prefixes[a[u-1]]=a[u];break;case 6:this.$=br(a[u-3],Or(a[u-2]),a[u-1],a[u]);break;case 7:this.$=br(a[u-3],a[u-2],a[u-1],a[u],{type:"query"});break;case 8:this.$=br({queryType:"SELECT",variables:"*"===a[u]?["*"]:a[u]},a[u-1]&&(a[u-2]=yr(a[u-1]),a[u-1]={},a[u-1][a[u-2]]=!0,a[u-1]));break;case 9:case 92:case 124:case 151:this.$=wr(a[u]);break;case 10:case 22:this.$=Er(a[u-3],{variable:wr(a[u-1])});break;case 11:this.$=br({queryType:"CONSTRUCT",template:a[u-3]},Or(a[u-2]),a[u-1],a[u]);break;case 12:this.$=br({queryType:"CONSTRUCT",template:a[u-2]=a[u-2]?a[u-2].triples:[]},Or(a[u-5]),{where:[{type:"bgp",triples:gr([],a[u-2])}]},a[u]);break;case 13:this.$=br({queryType:"DESCRIBE",variables:"*"===a[u-3]?["*"]:a[u-3].map(wr)},Or(a[u-2]),a[u-1],a[u]);break;case 14:this.$=br({queryType:"ASK"},Or(a[u-2]),a[u-1],a[u]);break;case 15:case 54:this.$={iri:a[u],named:!!a[u-1]};break;case 16:this.$={where:a[u].patterns};break;case 17:this.$=br(a[u-3],a[u-2],a[u-1],a[u]);break;case 18:this.$={group:a[u]};break;case 19:case 20:case 26:case 28:this.$=Er(a[u]);break;case 21:this.$=Er(a[u-1]);break;case 23:case 29:this.$=Er(wr(a[u]));break;case 24:this.$={having:a[u]};break;case 25:this.$={order:a[u]};break;case 27:this.$=Er(a[u],{descending:!0});break;case 30:this.$={limit:Ar(a[u])};break;case 31:this.$={offset:Ar(a[u])};break;case 32:this.$={limit:Ar(a[u-2]),offset:Ar(a[u])};break;case 33:this.$={limit:Ar(a[u]),offset:Ar(a[u-2])};break;case 34:this.$={type:"values",values:a[u]};break;case 35:a[u-3]=wr(a[u-3]),this.$=a[u-1].map(function(e){var t={};return t[a[u-3]]=e,t});break;case 36:this.$=a[u-1].map(function(){return{}});break;case 37:var l=a[u-4].length;a[u-4]=a[u-4].map(wr),this.$=a[u-1].map(function(e){if(e.length!==l)throw Error("Inconsistent VALUES length");for(var t={},r=0;r<l;r++)t[a[u-4][r]]=e[r];return t});break;case 40:this.$=void 0;break;case 41:case 84:case 108:case 152:this.$=a[u-1];break;case 42:this.$={type:"update",updates:mr(a[u-2],a[u-1])};break;case 43:this.$=br({type:"load",silent:!!a[u-2],source:a[u-1]},a[u]&&{destination:a[u]});break;case 44:this.$={type:yr(a[u-2]),silent:!!a[u-1],graph:a[u]};break;case 45:this.$={type:yr(a[u-4]),silent:!!a[u-3],source:a[u-2],destination:a[u]};break;case 46:this.$={type:"create",silent:!!a[u-2],graph:{type:"graph",name:a[u]}};break;case 47:this.$={updateType:"insert",insert:a[u]};break;case 48:this.$={updateType:"delete",delete:a[u]};break;case 49:this.$={updateType:"deletewhere",delete:a[u]};break;case 50:this.$=br({updateType:"insertdelete"},a[u-5],{insert:a[u-4]||[]},{delete:a[u-3]||[]},Or(a[u-2]),{where:a[u].patterns});break;case 51:this.$=br({updateType:"insertdelete"},a[u-5],{delete:a[u-4]||[]},{insert:a[u-3]||[]},Or(a[u-2]),{where:a[u].patterns});break;case 52:case 53:case 56:case 143:this.$=a[u];break;case 55:this.$={graph:a[u]};break;case 57:this.$={type:"graph",default:!0};break;case 58:case 59:this.$={type:"graph",name:a[u]};break;case 60:this.$={},this.$[yr(a[u])]=!0;break;case 61:this.$=a[u-2]?vr(a[u-1],[a[u-2]]):vr(a[u-1]);break;case 62:var f=br(a[u-3]||{triples:[]},{type:"graph",name:wr(a[u-5])});this.$=a[u]?[f,a[u]]:[f];break;case 63:case 68:this.$={type:"bgp",triples:vr(a[u-2],[a[u-1]])};break;case 64:this.$={type:"group",patterns:[a[u-1]]};break;case 65:this.$={type:"group",patterns:a[u-1]};break;case 66:this.$=a[u-1]?vr([a[u-1]],a[u]):vr(a[u]);break;case 67:this.$=a[u]?[a[u-2],a[u]]:a[u-2];break;case 69:a[u-1].length?this.$={type:"union",patterns:vr(a[u-1].map(Ir),[Ir(a[u])])}:this.$=a[u];break;case 70:this.$=br(a[u],{type:"optional"});break;case 71:this.$=br(a[u],{type:"minus"});break;case 72:this.$=br(a[u],{type:"graph",name:wr(a[u-1])});break;case 73:this.$=br(a[u],{type:"service",name:wr(a[u-1]),silent:!!a[u-2]});break;case 74:this.$={type:"filter",expression:a[u]};break;case 75:this.$={type:"bind",variable:wr(a[u-1]),expression:a[u-3]};break;case 80:this.$={type:"functionCall",function:a[u-1],args:[]};break;case 81:this.$={type:"functionCall",function:a[u-5],args:mr(a[u-2],a[u-1]),distinct:!!a[u-3]};break;case 82:case 99:case 110:case 196:case 204:case 216:case 218:case 228:case 232:case 252:case 254:case 258:case 262:case 285:case 291:case 302:case 312:case 318:case 324:case 328:case 338:case 340:case 344:case 350:case 354:case 360:case 362:case 366:case 368:case 377:case 385:case 387:case 397:case 401:case 403:case 405:this.$=[];break;case 83:this.$=mr(a[u-2],a[u-1]);break;case 85:this.$=vr(a[u-2],[a[u-1]]);break;case 86:case 96:this.$=a[u].map(function(e){return br(Rr(a[u-1]),e)});break;case 87:this.$=gr(a[u].map(function(e){return br(Rr(a[u-1].entity),e)}),a[u-1].triples);break;case 89:this.$=vr([a[u-1]],a[u]);break;case 90:this.$=vr(a[u]);break;case 91:this.$=Lr(a[u-1],a[u]);break;case 94:case 106:case 113:this.$=tr;break;case 95:this.$=mr(a[u-1],a[u]);break;case 97:this.$=a[u]?gr(a[u].map(function(e){return br(Rr(a[u-1].entity),e)}),a[u-1].triples):a[u-1].triples;break;case 98:this.$=Lr(wr(a[u-3]),mr(a[u-2],a[u-1]),a[u]);break;case 100:this.$=Lr(wr(a[u-1]),a[u]);break;case 101:this.$=a[u-1].length?xr("|",mr(a[u-1],a[u])):a[u];break;case 102:this.$=a[u-1].length?xr("/",mr(a[u-1],a[u])):a[u];break;case 103:this.$=a[u]?xr(a[u],[a[u-1]]):a[u-1];break;case 104:this.$=a[u-1]?xr(a[u-1],[a[u]]):a[u];break;case 107:case 114:this.$=xr(a[u-1],[a[u]]);break;case 111:this.$=xr("|",mr(a[u-2],a[u-1]));break;case 115:this.$=xr(a[u-1],[tr]);break;case 116:case 118:this.$=function(e){var t=kr(),r=t,n=[],i=[];e.forEach(function(e){n.push(e.entity),gr(i,e.triples)});for(var a=0,o=0,s=n.length,c=Array(2*s);a<s;)c[o++]=Rr(r,rr,n[a]),c[o++]=Rr(r,nr,r=++a<s?kr():ir);return{entity:t,triples:gr(c,i)}}(a[u-1]);break;case 117:case 119:this.$=(s=a[u-1],{entity:c=kr(),triples:s.map(function(e){return br(Rr(c),e)})});break;case 120:case 122:this.$={entity:a[u],triples:[]};break;case 128:this.$=kr();break;case 129:this.$=ir;break;case 130:case 132:case 137:case 141:this.$=Tr(a[u-1],a[u]);break;case 131:this.$=["||",a[u]];break;case 133:this.$=["&&",a[u]];break;case 135:this.$=Sr(a[u-1],[a[u-2],a[u]]);break;case 136:this.$=Sr(a[u-2]?"notin":"in",[a[u-3],a[u]]);break;case 138:case 142:this.$=[a[u-1],a[u]];break;case 139:this.$=["+",Tr(a[u-1],a[u])];break;case 140:this.$=["-",Tr(a[u-1].replace("-",""),a[u])];break;case 144:this.$=Sr(a[u-1],[a[u]]);break;case 145:this.$=Sr("UMINUS",[a[u]]);break;case 154:this.$=Sr(yr(a[u-1]));break;case 155:this.$=Sr(yr(a[u-3]),[a[u-1]]);break;case 156:this.$=Sr(yr(a[u-5]),[a[u-3],a[u-1]]);break;case 157:this.$=Sr(yr(a[u-7]),[a[u-5],a[u-3],a[u-1]]);break;case 158:this.$=Sr(yr(a[u-1]),a[u]);break;case 159:this.$=Sr("bound",[wr(a[u-1])]);break;case 160:this.$=Sr(a[u-1],[]);break;case 161:this.$=Sr(a[u-3],[a[u-1]]);break;case 162:this.$=Sr(a[u-2]?"notexists":"exists",[Ir(a[u])]);break;case 163:case 164:this.$=Er(a[u-1],{type:"aggregate",aggregation:yr(a[u-4]),distinct:!!a[u-2]});break;case 165:this.$=Er(a[u-2],{type:"aggregate",aggregation:yr(a[u-5]),distinct:!!a[u-3],separator:a[u-1]||" "});break;case 166:this.$=a[u].substr(1,a[u].length-2);break;case 168:this.$=a[u-1]+yr(a[u]);break;case 169:this.$=a[u-2]+"^^"+a[u];break;case 170:case 184:this.$=Nr(a[u],or);break;case 171:case 185:this.$=Nr(a[u],sr);break;case 172:case 186:this.$=Nr(yr(a[u]),cr);break;case 175:this.$=lr;break;case 176:this.$=fr;break;case 177:case 178:this.$=Mr(a[u],1);break;case 179:case 180:this.$=Mr(a[u],3);break;case 181:this.$=Nr(a[u].substr(1),or);break;case 182:this.$=Nr(a[u].substr(1),sr);break;case 183:this.$=Nr(a[u].substr(1).toLowerCase(),cr);break;case 187:this.$=_r(a[u]);break;case 188:var d=a[u].indexOf(":"),h=a[u].substr(0,d),p=Fr.prefixes[h];if(!p)throw new Error("Unknown prefix: "+h);this.$=_r(p+a[u].substr(d+1));break;case 189:if(a[u]=a[u].substr(0,a[u].length-1),!(a[u]in Fr.prefixes))throw new Error("Unknown prefix: "+a[u]);this.$=_r(Fr.prefixes[a[u]]);break;case 197:case 205:case 213:case 217:case 219:case 225:case 229:case 233:case 247:case 249:case 251:case 253:case 255:case 257:case 259:case 261:case 286:case 292:case 303:case 319:case 351:case 363:case 382:case 384:case 386:case 388:case 398:case 402:case 404:case 406:a[u-1].push(a[u]);break;case 212:case 224:case 246:case 248:case 250:case 256:case 260:case 381:case 383:this.$=[a[u]];break;case 263:a[u-3].push(a[u-2]);break;case 313:case 325:case 329:case 339:case 341:case 345:case 355:case 361:case 367:case 369:case 378:a[u-2].push(a[u-1])}},table:[e(t,r,{3:1,4:2,7:3}),{1:[3]},e(n,[2,262],{5:4,8:5,287:6,9:7,95:8,17:9,33:10,42:11,47:12,96:13,18:14,6:[2,190],24:i,34:[1,15],43:[1,16],48:[1,17]}),e([6,24,34,43,48,99,109,112,114,115,124,125,130,298,299,300,301,302],[2,2],{288:19,11:20,14:21,12:[1,22],15:[1,23]}),{6:[1,24]},{6:[2,192]},{6:[2,193]},{6:[2,202],10:25,82:26,83:a},{6:[2,191]},e(o,[2,198]),e(o,[2,199]),e(o,[2,200]),e(o,[2,201]),{97:28,99:[1,29],102:30,105:31,109:[1,32],112:[1,33],114:[1,34],115:[1,35],116:36,120:37,124:[2,287],125:[2,281],129:43,130:[1,44],298:[1,38],299:[1,39],300:[1,40],301:[1,41],302:[1,42]},e(s,[2,204],{19:45}),e(c,[2,218],{35:46,37:47,39:[1,48]}),{13:u,16:l,28:f,44:49,53:54,286:d,293:[1,51],294:52,295:50},e(s,[2,232],{49:58}),e(h,[2,210],{25:59,289:60,290:[1,61],291:[1,62]}),e(t,[2,197]),e(t,[2,194]),e(t,[2,195]),{13:[1,63]},{16:[1,64]},{1:[2,1]},{6:[2,3]},{6:[2,203]},{28:[1,66],29:[1,68],84:65,86:[1,67]},{6:[2,264],98:69,183:[1,70]},e(p,[2,266],{100:71,297:[1,72]}),e(y,[2,272],{103:73,297:[1,74]}),e(m,[2,277],{106:75,297:[1,76]}),{110:77,111:[2,279],297:[1,78]},{39:g,113:79},{39:g,113:81},{39:g,113:82},{117:83,125:b},{121:85,124:v},e(_,[2,270]),e(_,[2,271]),e(w,[2,274]),e(w,[2,275]),e(w,[2,276]),{124:[2,288],125:[2,282]},{13:u,16:l,53:87,286:d},{20:88,38:S,39:E,50:89,51:x,54:90},e(s,[2,216],{36:93}),{38:[1,94],50:95,51:x},e(T,[2,344],{171:96,172:97,173:98,41:[2,342]}),e(O,[2,228],{45:99}),e(O,[2,226],{53:54,294:100,13:u,16:l,28:f,286:d}),e(O,[2,227]),e(A,[2,224]),e(A,[2,222]),e(A,[2,223]),e(I,[2,187]),e(I,[2,188]),e(I,[2,189]),{20:101,38:S,39:E,50:102,51:x,54:90},{26:103,27:106,28:N,29:R,292:104,293:[1,105]},e(h,[2,211]),e(h,[2,208]),e(h,[2,209]),e(t,[2,4]),{13:[1,109]},e(k,[2,34]),{39:[1,110]},{39:[1,111]},{28:[1,113],88:112},{6:[2,42]},e(t,r,{7:3,4:114}),{13:u,16:l,53:115,286:d},e(p,[2,267]),{104:116,111:[1,117],133:[1,119],135:118,296:[1,120],303:[1,121]},e(y,[2,273]),e(p,P,{107:122,134:124,111:j,133:D}),e(m,[2,278]),{111:[1,126]},{111:[2,280]},e(C,[2,47]),e(T,M,{136:127,143:128,144:129,41:L,111:L}),e(C,[2,48]),e(C,[2,49]),e(q,[2,283],{118:130,121:131,124:v}),{39:g,113:132},e(q,[2,289],{122:133,117:134,125:b}),{39:g,113:135},e([124,125],[2,55]),e(F,B,{21:136,56:137,60:138,61:U}),e(s,[2,205]),{39:V,55:140},e(p,[2,234],{52:142,296:[1,143]}),{39:[2,237]},{20:144,38:S,39:E,50:145,51:x,54:90},{39:[1,146]},e(c,[2,219]),{41:[1,147]},{41:[2,343]},{13:u,16:l,28:H,29:z,53:152,80:G,86:Q,91:153,145:148,175:149,177:150,215:X,218:$,219:J,236:163,238:164,269:159,272:Y,273:K,274:W,275:Z,276:ee,277:te,278:re,279:ne,280:ie,281:ae,282:oe,283:se,284:ce,285:ue,286:d},e(le,[2,230],{54:90,46:177,50:178,20:179,38:S,39:E,51:x}),e(A,[2,225]),e(F,B,{56:137,60:138,21:180,61:U}),e(s,[2,233]),e(s,[2,8]),e(s,[2,214],{27:181,28:N,29:R}),e(s,[2,215]),e(fe,[2,212]),e(fe,[2,9]),e(de,he,{30:182,220:183,224:184,228:185,232:186,240:187,244:188,208:pe,246:ye,310:me}),e(t,[2,5]),e(ge,[2,252],{85:192}),e(be,[2,254],{87:193}),{28:[1,195],32:[1,194]},e(ve,[2,256]),e(n,[2,263],{6:[2,265]}),e(C,[2,268],{101:196,131:197,132:[1,198]}),e(C,[2,44]),{13:u,16:l,53:199,286:d},e(C,[2,60]),e(C,[2,297]),e(C,[2,298]),e(C,[2,299]),{108:[1,200]},e(_e,[2,57]),{13:u,16:l,53:201,286:d},e(p,[2,296]),{13:u,16:l,53:202,286:d},e(we,[2,302],{137:203}),e(we,[2,301]),{13:u,16:l,28:H,29:z,53:152,80:G,86:Q,91:153,145:204,175:149,177:150,215:X,218:$,219:J,236:163,238:164,269:159,272:Y,273:K,274:W,275:Z,276:ee,277:te,278:re,279:ne,280:ie,281:ae,282:oe,283:se,284:ce,285:ue,286:d},e(q,[2,285],{119:205}),e(q,[2,284]),e([38,124,127],[2,53]),e(q,[2,291],{123:206}),e(q,[2,290]),e([38,125,127],[2,52]),e(o,[2,6]),e(Se,[2,240],{57:207,67:208,68:[1,209]}),e(F,[2,239]),{62:[1,210]},e([6,41,61,68,71,79,81,83],[2,16]),e(T,Ee,{22:211,147:212,18:213,148:214,154:215,155:216,24:i,39:xe,41:xe,83:xe,111:xe,159:xe,160:xe,162:xe,165:xe,166:xe}),{13:u,16:l,53:217,286:d},e(p,[2,235]),e(F,B,{56:137,60:138,21:218,61:U}),e(s,[2,217]),e(T,M,{144:129,40:219,143:220,41:[2,220]}),e(s,[2,84]),{41:[2,346],174:221,304:[1,222]},{13:u,16:l,28:Te,53:227,176:223,180:224,185:225,187:Oe,286:d},e(Ae,[2,348],{180:224,185:225,53:227,178:229,179:230,176:231,13:u,16:l,28:Te,187:Oe,286:d}),e(Ie,[2,124]),e(Ie,[2,125]),e(Ie,[2,126]),e(Ie,[2,127]),e(Ie,[2,128]),e(Ie,[2,129]),{13:u,16:l,28:H,29:z,53:152,80:G,86:Q,91:153,175:234,177:235,189:233,214:232,215:X,218:$,219:J,236:163,238:164,269:159,272:Y,273:K,274:W,275:Z,276:ee,277:te,278:re,279:ne,280:ie,281:ae,282:oe,283:se,284:ce,285:ue,286:d},{13:u,16:l,28:Te,53:227,176:236,180:224,185:225,187:Oe,286:d},e(Ne,[2,167],{270:[1,237],271:[1,238]}),e(Ne,[2,170]),e(Ne,[2,171]),e(Ne,[2,172]),e(Ne,[2,173]),e(Ne,[2,174]),e(Ne,[2,175]),e(Ne,[2,176]),e(Re,[2,177]),e(Re,[2,178]),e(Re,[2,179]),e(Re,[2,180]),e(Ne,[2,181]),e(Ne,[2,182]),e(Ne,[2,183]),e(Ne,[2,184]),e(Ne,[2,185]),e(Ne,[2,186]),e(F,B,{56:137,60:138,21:239,61:U}),e(O,[2,229]),e(le,[2,231]),e(o,[2,14]),e(fe,[2,213]),{31:[1,240]},e(ke,[2,385],{221:241}),e(Pe,[2,387],{225:242}),e(Pe,[2,134],{229:243,230:244,231:[2,395],268:[1,245],311:[1,246],312:[1,247],313:[1,248],314:[1,249],315:[1,250],316:[1,251]}),e(je,[2,397],{233:252}),e(De,[2,405],{241:253}),{13:u,16:l,28:Ce,29:Me,53:257,65:256,66:258,75:255,80:G,91:259,236:163,238:164,245:254,247:262,248:Le,249:qe,250:Fe,252:Be,253:267,254:Ue,255:Ve,256:270,257:He,258:ze,261:Ge,263:Qe,269:159,272:Y,273:K,274:W,275:Z,276:ee,277:te,278:re,279:ne,280:ie,281:ae,282:oe,283:se,284:ce,285:ue,286:d,316:Xe,317:$e,318:Je,319:Ye,320:Ke,321:We},{13:u,16:l,28:Ce,29:Me,53:257,65:256,66:258,75:255,80:G,91:259,236:163,238:164,245:280,247:262,248:Le,249:qe,250:Fe,252:Be,253:267,254:Ue,255:Ve,256:270,257:He,258:ze,261:Ge,263:Qe,269:159,272:Y,273:K,274:W,275:Z,276:ee,277:te,278:re,279:ne,280:ie,281:ae,282:oe,283:se,284:ce,285:ue,286:d,316:Xe,317:$e,318:Je,319:Ye,320:Ke,321:We},{13:u,16:l,28:Ce,29:Me,53:257,65:256,66:258,75:255,80:G,91:259,236:163,238:164,245:281,247:262,248:Le,249:qe,250:Fe,252:Be,253:267,254:Ue,255:Ve,256:270,257:He,258:ze,261:Ge,263:Qe,269:159,272:Y,273:K,274:W,275:Z,276:ee,277:te,278:re,279:ne,280:ie,281:ae,282:oe,283:se,284:ce,285:ue,286:d,316:Xe,317:$e,318:Je,319:Ye,320:Ke,321:We},e(de,[2,410]),{13:u,16:l,41:[1,282],53:284,80:G,90:283,91:285,92:Ze,236:163,238:164,269:159,272:Y,273:K,274:W,275:Z,276:ee,277:te,278:re,279:ne,280:ie,281:ae,282:oe,283:se,284:ce,285:ue,286:d},{41:[1,287],86:[1,288]},{39:[1,289]},e(ve,[2,257]),e(C,[2,43]),e(C,[2,269]),{111:[1,290]},e(C,[2,59]),e(p,P,{134:124,107:291,111:j,133:D}),e(_e,[2,58]),e(C,[2,46]),{41:[1,292],111:[1,294],138:293},e(we,[2,314],{146:295,304:[1,296]}),{38:[1,297],126:298,127:et},{38:[1,300],126:301,127:et},e(tt,[2,242],{58:302,70:303,71:[1,304]}),e(Se,[2,241]),{13:u,16:l,29:Me,53:310,65:308,66:309,69:305,75:307,77:306,247:262,248:Le,249:qe,250:Fe,252:Be,253:267,254:Ue,255:Ve,256:270,257:He,258:ze,261:Ge,263:Qe,286:d,316:Xe,317:$e,318:Je,319:Ye,320:Ke,321:We},{13:u,16:l,28:rt,29:nt,53:310,63:311,64:312,65:313,66:314,247:262,248:Le,249:qe,250:Fe,252:Be,253:267,254:Ue,255:Ve,256:270,257:He,258:ze,261:Ge,263:Qe,286:d,316:Xe,317:$e,318:Je,319:Ye,320:Ke,321:We},{41:[1,317]},{41:[1,318]},{20:319,38:S,39:E,54:90},e(it,[2,318],{149:320}),e(it,[2,317]),{13:u,16:l,28:H,29:at,53:152,80:G,86:Q,91:153,156:321,175:322,191:323,215:ot,218:$,219:J,236:163,238:164,269:159,272:Y,273:K,274:W,275:Z,276:ee,277:te,278:re,279:ne,280:ie,281:ae,282:oe,283:se,284:ce,285:ue,286:d},e(O,[2,15]),e(o,[2,11]),{41:[1,326]},{41:[2,221]},{41:[2,85]},e(T,[2,345],{41:[2,347]}),e(Ae,[2,86]),e(st,[2,350],{181:327}),e(T,ct,{186:328,188:329}),e(T,[2,92]),e(T,[2,93]),e(T,[2,94]),e(Ae,[2,87]),e(Ae,[2,88]),e(Ae,[2,349]),{13:u,16:l,28:H,29:z,32:[1,330],53:152,80:G,86:Q,91:153,175:234,177:235,189:331,215:X,218:$,219:J,236:163,238:164,269:159,272:Y,273:K,274:W,275:Z,276:ee,277:te,278:re,279:ne,280:ie,281:ae,282:oe,283:se,284:ce,285:ue,286:d},e(ut,[2,381]),e(lt,[2,120]),e(lt,[2,121]),{216:[1,332]},e(Ne,[2,168]),{13:u,16:l,53:333,286:d},e(o,[2,13]),{28:[1,334]},e([31,32,183,251],[2,130],{222:335,223:[1,336]}),e(ke,[2,132],{226:337,227:[1,338]}),e(de,he,{232:186,240:187,244:188,228:339,208:pe,246:ye,310:me}),{231:[1,340]},e(ft,[2,389]),e(ft,[2,390]),e(ft,[2,391]),e(ft,[2,392]),e(ft,[2,393]),e(ft,[2,394]),{231:[2,396]},e([31,32,183,223,227,231,251,268,311,312,313,314,315,316],[2,137],{234:341,235:342,236:343,238:344,246:[1,346],280:ie,281:ae,282:oe,283:se,284:ce,285:ue,310:[1,345]}),e(je,[2,141],{242:347,243:348,293:dt,307:ht}),e(De,[2,143]),e(De,[2,146]),e(De,[2,147]),e(De,[2,148],{29:pt,86:yt}),e(De,[2,149]),e(De,[2,150]),e(De,[2,151]),e(de,he,{220:183,224:184,228:185,232:186,240:187,244:188,30:353,208:pe,246:ye,310:me}),e(mt,[2,153]),{86:[1,354]},{29:[1,355]},{29:[1,356]},{29:[1,357]},{29:gt,86:bt,169:358},{29:[1,361]},{29:[1,363],86:[1,362]},{257:[1,364]},{29:[1,365]},{29:[1,366]},{29:[1,367]},e(vt,[2,411]),e(vt,[2,412]),e(vt,[2,413]),e(vt,[2,414]),e(vt,[2,415]),{257:[2,417]},e(De,[2,144]),e(De,[2,145]),e(k,[2,35]),e(ge,[2,253]),e(_t,[2,38]),e(_t,[2,39]),e(_t,[2,40]),e(k,[2,36]),e(be,[2,255]),e(wt,[2,258],{89:368}),{13:u,16:l,53:369,286:d},e(C,[2,45]),e([6,38,124,125,127,183],[2,61]),e(we,[2,303]),{13:u,16:l,28:[1,371],53:372,139:370,286:d},e(we,[2,63]),e(T,[2,313],{41:St,111:St}),{39:V,55:373},e(q,[2,286]),e(p,[2,293],{128:374,296:[1,375]}),{39:V,55:376},e(q,[2,292]),e(Et,[2,244],{59:377,78:378,79:[1,379],81:[1,380]}),e(tt,[2,243]),{62:[1,381]},e(Se,[2,24],{247:262,253:267,256:270,75:307,65:308,66:309,53:310,77:382,13:u,16:l,29:Me,248:Le,249:qe,250:Fe,252:Be,254:Ue,255:Ve,257:He,258:ze,261:Ge,263:Qe,286:d,316:Xe,317:$e,318:Je,319:Ye,320:Ke,321:We}),e(xt,[2,248]),e(Tt,[2,77]),e(Tt,[2,78]),e(Tt,[2,79]),{29:pt,86:yt},e(F,[2,18],{247:262,253:267,256:270,53:310,65:313,66:314,64:383,13:u,16:l,28:rt,29:nt,248:Le,249:qe,250:Fe,252:Be,254:Ue,255:Ve,257:He,258:ze,261:Ge,263:Qe,286:d,316:Xe,317:$e,318:Je,319:Ye,320:Ke,321:We}),e(Ot,[2,246]),e(Ot,[2,19]),e(Ot,[2,20]),e(de,he,{220:183,224:184,228:185,232:186,240:187,244:188,30:384,208:pe,246:ye,310:me}),e(Ot,[2,23]),e(At,[2,64]),e(At,[2,65]),e(F,B,{56:137,60:138,21:385,61:U}),{39:[2,328],41:[2,66],82:395,83:a,111:[1,391],150:386,151:387,158:388,159:[1,389],160:[1,390],162:[1,392],165:[1,393],166:[1,394]},e(it,[2,326],{157:396,304:[1,397]}),e(It,Nt,{190:398,193:399,199:400,200:402,28:Rt}),e(kt,[2,356],{193:399,199:400,200:402,192:403,190:404,13:Nt,16:Nt,29:Nt,187:Nt,208:Nt,213:Nt,286:Nt,28:Rt}),{13:u,16:l,28:H,29:at,53:152,80:G,86:Q,91:153,175:407,191:408,195:406,215:ot,217:405,218:$,219:J,236:163,238:164,269:159,272:Y,273:K,274:W,275:Z,276:ee,277:te,278:re,279:ne,280:ie,281:ae,282:oe,283:se,284:ce,285:ue,286:d},e(It,Nt,{193:399,199:400,200:402,190:409,28:Rt}),e(F,B,{56:137,60:138,21:410,61:U}),e([41,111,216,304],[2,89],{182:411,183:[1,412]}),e(st,[2,91]),{13:u,16:l,28:H,29:z,53:152,80:G,86:Q,91:153,175:234,177:235,189:413,215:X,218:$,219:J,236:163,238:164,269:159,272:Y,273:K,274:W,275:Z,276:ee,277:te,278:re,279:ne,280:ie,281:ae,282:oe,283:se,284:ce,285:ue,286:d},e(Pt,[2,116]),e(ut,[2,382]),e(Pt,[2,117]),e(Ne,[2,169]),{32:[1,414]},e(ke,[2,386]),e(de,he,{224:184,228:185,232:186,240:187,244:188,220:415,208:pe,246:ye,310:me}),e(Pe,[2,388]),e(de,he,{228:185,232:186,240:187,244:188,224:416,208:pe,246:ye,310:me}),e(Pe,[2,135]),{29:gt,86:bt,169:417},e(je,[2,398]),e(de,he,{240:187,244:188,232:418,208:pe,246:ye,310:me}),e(De,[2,401],{237:419}),e(De,[2,403],{239:420}),e(ft,[2,399]),e(ft,[2,400]),e(De,[2,406]),e(de,he,{244:188,240:421,208:pe,246:ye,310:me}),e(ft,[2,407]),e(ft,[2,408]),e(mt,[2,80]),e(ft,[2,336],{167:422,290:[1,423]}),{32:[1,424]},e(mt,[2,154]),e(de,he,{220:183,224:184,228:185,232:186,240:187,244:188,30:425,208:pe,246:ye,310:me}),e(de,he,{220:183,224:184,228:185,232:186,240:187,244:188,30:426,208:pe,246:ye,310:me}),e(de,he,{220:183,224:184,228:185,232:186,240:187,244:188,30:427,208:pe,246:ye,310:me}),e(mt,[2,158]),e(mt,[2,82]),e(ft,[2,340],{170:428}),{28:[1,429]},e(mt,[2,160]),e(de,he,{220:183,224:184,228:185,232:186,240:187,244:188,30:430,208:pe,246:ye,310:me}),{39:V,55:431},e(jt,[2,418],{259:432,290:[1,433]}),e(ft,[2,422],{262:434,290:[1,435]}),e(ft,[2,424],{264:436,290:[1,437]}),{29:[1,440],41:[1,438],93:439},e(C,[2,56]),{39:[1,441]},{39:[2,304]},{39:[2,305]},e(C,[2,50]),{13:u,16:l,53:442,286:d},e(p,[2,294]),e(C,[2,51]),e(Et,[2,17]),e(Et,[2,245]),{80:[1,443]},{80:[1,444]},{13:u,16:l,28:Dt,29:Me,53:310,65:308,66:309,72:445,73:446,74:Ct,75:307,76:Mt,77:449,247:262,248:Le,249:qe,250:Fe,252:Be,253:267,254:Ue,255:Ve,256:270,257:He,258:ze,261:Ge,263:Qe,286:d,316:Xe,317:$e,318:Je,319:Ye,320:Ke,321:We},e(xt,[2,249]),e(Ot,[2,247]),{31:[1,452],32:[1,451]},{23:453,41:[2,206],82:454,83:a},e(it,[2,319]),e(Lt,[2,320],{152:455,304:[1,456]}),{39:V,55:457},{39:V,55:458},{39:V,55:459},{13:u,16:l,28:[1,461],53:462,161:460,286:d},e(qt,[2,332],{163:463,297:[1,464]}),{13:u,16:l,29:Me,53:310,65:308,66:309,75:307,77:465,247:262,248:Le,249:qe,250:Fe,252:Be,253:267,254:Ue,255:Ve,256:270,257:He,258:ze,261:Ge,263:Qe,286:d,316:Xe,317:$e,318:Je,319:Ye,320:Ke,321:We},{29:[1,466]},e(Ft,[2,76]),e(it,[2,68]),e(T,[2,325],{39:Bt,41:Bt,83:Bt,111:Bt,159:Bt,160:Bt,162:Bt,165:Bt,166:Bt}),e(kt,[2,96]),e(T,[2,360],{194:467}),e(T,[2,358]),e(T,[2,359]),e(It,[2,368],{201:468,202:469}),e(kt,[2,97]),e(kt,[2,357]),{13:u,16:l,28:H,29:at,32:[1,470],53:152,80:G,86:Q,91:153,175:407,191:408,195:471,215:ot,218:$,219:J,236:163,238:164,269:159,272:Y,273:K,274:W,275:Z,276:ee,277:te,278:re,279:ne,280:ie,281:ae,282:oe,283:se,284:ce,285:ue,286:d},e(ut,[2,383]),e(lt,[2,122]),e(lt,[2,123]),{216:[1,472]},e(o,[2,12]),e(st,[2,351]),e(st,[2,352],{185:225,53:227,184:473,180:474,13:u,16:l,28:Te,187:Oe,286:d}),e(Ut,[2,95],{251:[1,475]}),e(fe,[2,10]),e(ke,[2,131]),e(Pe,[2,133]),e(Pe,[2,136]),e(je,[2,138]),e(je,[2,139],{243:348,242:476,293:dt,307:ht}),e(je,[2,140],{243:348,242:477,293:dt,307:ht}),e(De,[2,142]),e(ft,[2,338],{168:478}),e(ft,[2,337]),e([6,13,16,28,29,31,32,39,41,71,74,76,79,80,81,83,86,111,159,160,162,165,166,183,215,218,219,223,227,231,246,248,249,250,251,252,254,255,257,258,261,263,268,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,293,304,307,310,311,312,313,314,315,316,317,318,319,320,321],[2,152]),{32:[1,479]},{251:[1,480]},{251:[1,481]},e(de,he,{220:183,224:184,228:185,232:186,240:187,244:188,30:482,208:pe,246:ye,310:me}),{32:[1,483]},{32:[1,484]},e(mt,[2,162]),e(de,he,{220:183,224:184,228:185,232:186,240:187,244:188,260:485,30:487,208:pe,246:ye,293:[1,486],310:me}),e(jt,[2,419]),e(de,he,{220:183,224:184,228:185,232:186,240:187,244:188,30:488,208:pe,246:ye,310:me}),e(ft,[2,423]),e(de,he,{220:183,224:184,228:185,232:186,240:187,244:188,30:489,208:pe,246:ye,310:me}),e(ft,[2,425]),e(k,[2,37]),e(wt,[2,259]),{13:u,16:l,53:284,80:G,90:491,91:285,92:Ze,94:490,236:163,238:164,269:159,272:Y,273:K,274:W,275:Z,276:ee,277:te,278:re,279:ne,280:ie,281:ae,282:oe,283:se,284:ce,285:ue,286:d},e(T,M,{144:129,140:492,143:493,41:[2,306]}),e(q,[2,54]),e(Et,[2,30],{81:[1,494]}),e(Et,[2,31],{79:[1,495]}),e(tt,[2,25],{247:262,253:267,256:270,75:307,65:308,66:309,53:310,77:449,73:496,13:u,16:l,28:Dt,29:Me,74:Ct,76:Mt,248:Le,249:qe,250:Fe,252:Be,254:Ue,255:Ve,257:He,258:ze,261:Ge,263:Qe,286:d,316:Xe,317:$e,318:Je,319:Ye,320:Ke,321:We}),e(Vt,[2,250]),{29:Me,75:497},{29:Me,75:498},e(Vt,[2,28]),e(Vt,[2,29]),e(Ot,[2,21]),{28:[1,499]},{41:[2,7]},{41:[2,207]},e(T,Ee,{155:216,153:500,154:501,39:Ht,41:Ht,83:Ht,111:Ht,159:Ht,160:Ht,162:Ht,165:Ht,166:Ht}),e(Lt,[2,321]),e(Ft,[2,69],{305:[1,502]}),e(Ft,[2,70]),e(Ft,[2,71]),{39:V,55:503},{39:[2,330]},{39:[2,331]},{13:u,16:l,28:[1,505],53:506,164:504,286:d},e(qt,[2,333]),e(Ft,[2,74]),e(de,he,{220:183,224:184,228:185,232:186,240:187,244:188,30:507,208:pe,246:ye,310:me}),{13:u,16:l,28:H,29:at,53:152,80:G,86:Q,91:153,175:407,191:408,195:508,215:ot,218:$,219:J,236:163,238:164,269:159,272:Y,273:K,274:W,275:Z,276:ee,277:te,278:re,279:ne,280:ie,281:ae,282:oe,283:se,284:ce,285:ue,286:d},e(ut,[2,101],{306:[1,509]}),e(zt,[2,375],{203:510,207:511,213:[1,512]}),e(Ie,[2,118]),e(ut,[2,384]),e(Ie,[2,119]),e(st,[2,90]),e(st,[2,353]),e(T,[2,355]),e(De,[2,402]),e(De,[2,404]),e(de,he,{220:183,224:184,228:185,232:186,240:187,244:188,30:513,208:pe,246:ye,310:me}),e(mt,[2,155]),e(de,he,{220:183,224:184,228:185,232:186,240:187,244:188,30:514,208:pe,246:ye,310:me}),e(de,he,{220:183,224:184,228:185,232:186,240:187,244:188,30:515,208:pe,246:ye,310:me}),{32:[1,516],251:[1,517]},e(mt,[2,159]),e(mt,[2,161]),{32:[1,518]},{32:[2,420]},{32:[2,421]},{32:[1,519]},{32:[2,426],183:[1,522],265:520,266:521},{13:u,16:l,32:[1,523],53:284,80:G,90:524,91:285,92:Ze,236:163,238:164,269:159,272:Y,273:K,274:W,275:Z,276:ee,277:te,278:re,279:ne,280:ie,281:ae,282:oe,283:se,284:ce,285:ue,286:d},e(Gt,[2,260]),{41:[1,525]},{41:[2,307]},{80:[1,526]},{80:[1,527]},e(Vt,[2,251]),e(Vt,[2,26]),e(Vt,[2,27]),{32:[1,528]},e(it,[2,67]),e(it,[2,323]),{39:[2,329]},e(Ft,[2,72]),{39:V,55:529},{39:[2,334]},{39:[2,335]},{31:[1,530]},e(Ut,[2,362],{196:531,251:[1,532]}),e(It,[2,367]),e([13,16,28,29,32,80,86,215,218,219,272,273,274,275,276,277,278,279,280,281,282,283,284,285,286,306],[2,102],{307:[1,533]}),{13:u,16:l,29:[1,539],53:536,187:[1,537],204:534,205:535,208:[1,538],286:d},e(zt,[2,376]),{32:[1,540],251:[1,541]},{32:[1,542]},{251:[1,543]},e(mt,[2,83]),e(ft,[2,341]),e(mt,[2,163]),e(mt,[2,164]),{32:[1,544]},{32:[2,427]},{267:[1,545]},e(wt,[2,41]),e(Gt,[2,261]),e(Qt,[2,308],{141:546,304:[1,547]}),e(Et,[2,32]),e(Et,[2,33]),e(Ot,[2,22]),e(Ft,[2,73]),{28:[1,548]},e([39,41,83,111,159,160,162,165,166,216,304],[2,98],{197:549,183:[1,550]}),e(T,[2,361]),e(It,[2,369]),e(Xt,[2,104]),e(Xt,[2,373],{206:551,308:552,293:[1,554],309:[1,553],310:[1,555]}),e($t,[2,105]),e($t,[2,106]),{13:u,16:l,29:[1,559],53:560,86:[1,558],187:Jt,209:556,210:557,213:Yt,286:d},e(It,Nt,{200:402,199:563}),e(mt,[2,81]),e(ft,[2,339]),e(mt,[2,156]),e(de,he,{220:183,224:184,228:185,232:186,240:187,244:188,30:564,208:pe,246:ye,310:me}),e(mt,[2,165]),{268:[1,565]},e(T,M,{144:129,142:566,143:567,41:Kt,111:Kt}),e(Qt,[2,309]),{32:[1,568]},e(Ut,[2,363]),e(Ut,[2,99],{200:402,198:569,199:570,13:Nt,16:Nt,29:Nt,187:Nt,208:Nt,213:Nt,286:Nt,28:[1,571]}),e(Xt,[2,103]),e(Xt,[2,374]),e(Xt,[2,370]),e(Xt,[2,371]),e(Xt,[2,372]),e($t,[2,107]),e($t,[2,109]),e($t,[2,110]),e(Wt,[2,377],{211:572}),e($t,[2,112]),e($t,[2,113]),{13:u,16:l,53:573,187:[1,574],286:d},{32:[1,575]},{32:[1,576]},{269:577,276:ee,277:te,278:re,279:ne},e(we,[2,62]),e(we,[2,311]),e(Ft,[2,75]),e(T,ct,{188:329,186:578}),e(T,[2,364]),e(T,[2,365]),{13:u,16:l,32:[2,379],53:560,187:Jt,210:580,212:579,213:Yt,286:d},e($t,[2,114]),e($t,[2,115]),e($t,[2,108]),e(mt,[2,157]),{32:[2,166]},e(Ut,[2,100]),{32:[1,581]},{32:[2,380],306:[1,582]},e($t,[2,111]),e(Wt,[2,378])],defaultActions:{5:[2,192],6:[2,193],8:[2,191],24:[2,1],25:[2,3],26:[2,203],69:[2,42],78:[2,280],92:[2,237],97:[2,343],220:[2,221],221:[2,85],251:[2,396],279:[2,417],371:[2,304],372:[2,305],453:[2,7],454:[2,207],461:[2,330],462:[2,331],486:[2,420],487:[2,421],493:[2,307],502:[2,329],505:[2,334],506:[2,335],521:[2,427],577:[2,166]},parseError:function(e,t){if(!t.recoverable){var r=new Error(e);throw r.hash=t,r}this.trace(e)},parse:function(e){var t=this,r=[0],n=[null],i=[],a=this.table,o="",s=0,c=0,u=0,l=2,f=1,d=i.slice.call(arguments,1),h=Object.create(this.lexer),p={yy:{}};for(var y in this.yy)Object.prototype.hasOwnProperty.call(this.yy,y)&&(p.yy[y]=this.yy[y]);h.setInput(e,p.yy),p.yy.lexer=h,p.yy.parser=this,void 0===h.yylloc&&(h.yylloc={});var m=h.yylloc;i.push(m);var g=h.options&&h.options.ranges;"function"==typeof p.yy.parseError?this.parseError=p.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;for(var b,v,_,w,S,E,x,T,O,A=function(){var e;return"number"!=typeof(e=h.lex()||f)&&(e=t.symbols_[e]||e),e},I={};;){if(_=r[r.length-1],this.defaultActions[_]?w=this.defaultActions[_]:(null==b&&(b=A()),w=a[_]&&a[_][b]),void 0===w||!w.length||!w[0]){var N="";for(E in O=[],a[_])this.terminals_[E]&&E>l&&O.push("'"+this.terminals_[E]+"'");N=h.showPosition?"Parse error on line "+(s+1)+":\n"+h.showPosition()+"\nExpecting "+O.join(", ")+", got '"+(this.terminals_[b]||b)+"'":"Parse error on line "+(s+1)+": Unexpected "+(b==f?"end of input":"'"+(this.terminals_[b]||b)+"'"),this.parseError(N,{text:h.match,token:this.terminals_[b]||b,line:h.yylineno,loc:m,expected:O})}if(w[0]instanceof Array&&w.length>1)throw new Error("Parse Error: multiple actions possible at state: "+_+", token: "+b);switch(w[0]){case 1:r.push(b),n.push(h.yytext),i.push(h.yylloc),r.push(w[1]),b=null,v?(b=v,v=null):(c=h.yyleng,o=h.yytext,s=h.yylineno,m=h.yylloc,u>0&&u--);break;case 2:if(x=this.productions_[w[1]][1],I.$=n[n.length-x],I._$={first_line:i[i.length-(x||1)].first_line,last_line:i[i.length-1].last_line,first_column:i[i.length-(x||1)].first_column,last_column:i[i.length-1].last_column},g&&(I._$.range=[i[i.length-(x||1)].range[0],i[i.length-1].range[1]]),void 0!==(S=this.performAction.apply(I,[o,c,s,p.yy,w[1],n,i].concat(d))))return S;x&&(r=r.slice(0,-1*x*2),n=n.slice(0,-1*x),i=i.slice(0,-1*x)),r.push(this.productions_[w[1]][0]),n.push(I.$),i.push(I._$),T=a[r[r.length-2]][r[r.length-1]],r.push(T);break;case 3:return!0}}return!0}},er="http://www.w3.org/1999/02/22-rdf-syntax-ns#",tr=er+"type",rr=er+"first",nr=er+"rest",ir=er+"nil",ar="http://www.w3.org/2001/XMLSchema#",or=ar+"integer",sr=ar+"decimal",cr=ar+"double",ur=ar+"boolean",lr='"true"^^'+ur,fr='"false"^^'+ur,dr="",hr="",pr="";function yr(e){return e.toLowerCase()}function mr(e,t){return e.push(t),e}function gr(e,t){return e.push.apply(e,t),e}function br(e){e||(e={});for(var t,r=1,n=arguments.length;r<n&&(t=arguments[r]||{});r++)for(var i in t)e[i]=t[i];return e}function vr(){for(var e=[],t=0,r=arguments.length;t<r;t++)e=e.concat.apply(e,arguments[t]);return e}function _r(e){if("<"===e[0]&&(e=e.substring(1,e.length-1)),/^[a-z]+:/.test(e))return e;if(!Fr.base)throw new Error("Cannot resolve relative IRI "+e+" because no base IRI was set.");switch(dr||(dr=Fr.base,hr=dr.replace(/[^\/:]*$/,""),pr=dr.match(/^(?:[a-z]+:\/*)?[^\/]*/)[0]),e[0]){case void 0:return dr;case"#":return dr+e;case"?":return dr.replace(/(?:\?.*)?$/,e);case"/":return pr+e;default:return hr+e}}function wr(e){if(e){var t=e[0];if("?"===t)return e;if("$"===t)return"?"+e.substr(1)}return e}function Sr(e,t){return{type:"operation",operator:e,args:t||[]}}function Er(e,t){var r={expression:e};if(t)for(var n in t)r[n]=t[n];return r}function xr(e,t){return{type:"path",pathType:e,items:t}}function Tr(e,t){for(var r,n=0,i=t.length;n<i&&(r=t[n]);n++)e=Sr(r[0],[e,r[1]]);return e}function Or(e){for(var t,r=[],n=[],i=e.length,a=0;a<i&&(t=e[a]);a++)(t.named?n:r).push(t.iri);return i?{from:{default:r,named:n}}:null}function Ar(e){return parseInt(e,10)}function Ir(e){return"group"===e.type&&1===e.patterns.length?e.patterns[0]:e}function Nr(e,t){return'"'+e+'"^^'+t}function Rr(e,t,r){var n={};return null!=e&&(n.subject=e),null!=t&&(n.predicate=t),null!=r&&(n.object=r),n}function kr(){return"_:b"+Pr++}var Pr=0;Fr._resetBlanks=function(){Pr=0};var jr=/\\u([a-fA-F0-9]{4})|\\U([a-fA-F0-9]{8})|\\(.)/g,Dr={"\\":"\\","'":"'",'"':'"',t:"\t",b:"\b",n:"\n",r:"\r",f:"\f"},Cr=String.fromCharCode;function Mr(e,t){e=e.substring(t,e.length-t);try{e=e.replace(jr,function(e,t,r,n){var i;if(t){if(i=parseInt(t,16),isNaN(i))throw new Error;return Cr(i)}if(r){if(i=parseInt(r,16),isNaN(i))throw new Error;return i<65535?Cr(i):Cr(55296+((i-=65536)>>10),56320+(1023&i))}var a=Dr[n];if(!a)throw new Error;return a})}catch(e){return""}return'"'+e+'"'}function Lr(e,t,r){var n=[],i=[];return t.forEach(function(t){n.push(Rr(null,e,t.entity)),gr(i,t.triples)}),vr(n,r||[],i)}var qr={EOF:1,parseError:function(e,t){if(!this.yy.parser)throw new Error(e);this.yy.parser.parseError(e,t)},setInput:function(e,t){return this.yy=t||this.yy||{},this._input=e,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},input:function(){var e=this._input[0];return this.yytext+=e,this.yyleng++,this.offset++,this.match+=e,this.matched+=e,e.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),e},unput:function(e){var t=e.length,r=e.split(/(?:\r\n?|\n)/g);this._input=e+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-t),this.offset-=t;var n=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),r.length-1&&(this.yylineno-=r.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:r?(r.length===n.length?this.yylloc.first_column:0)+n[n.length-r.length].length-r[0].length:this.yylloc.first_column-t},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-t]),this.yyleng=this.yytext.length,this},more:function(){return this._more=!0,this},reject:function(){return this.options.backtrack_lexer?(this._backtrack=!0,this):this.parseError("Lexical error on line "+(this.yylineno+1)+". You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},less:function(e){this.unput(this.match.slice(e))},pastInput:function(){var e=this.matched.substr(0,this.matched.length-this.match.length);return(e.length>20?"...":"")+e.substr(-20).replace(/\n/g,"")},upcomingInput:function(){var e=this.match;return e.length<20&&(e+=this._input.substr(0,20-e.length)),(e.substr(0,20)+(e.length>20?"...":"")).replace(/\n/g,"")},showPosition:function(){var e=this.pastInput(),t=new Array(e.length+1).join("-");return e+this.upcomingInput()+"\n"+t+"^"},test_match:function(e,t){var r,n,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),(n=e[0].match(/(?:\r\n?|\n).*/g))&&(this.yylineno+=n.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:n?n[n.length-1].length-n[n.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+e[0].length},this.yytext+=e[0],this.match+=e[0],this.matches=e,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(e[0].length),this.matched+=e[0],r=this.performAction.call(this,this.yy,this,t,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),r)return r;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},next:function(){if(this.done)return this.EOF;var e,t,r,n;this._input||(this.done=!0),this._more||(this.yytext="",this.match="");for(var i=this._currentRules(),a=0;a<i.length;a++)if((r=this._input.match(this.rules[i[a]]))&&(!t||r[0].length>t[0].length)){if(t=r,n=a,this.options.backtrack_lexer){if(!1!==(e=this.test_match(r,i[a])))return e;if(this._backtrack){t=!1;continue}return!1}if(!this.options.flex)break}return t?!1!==(e=this.test_match(t,i[n]))&&e:""===this._input?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},lex:function(){var e=this.next();return e||this.lex()},begin:function(e){this.conditionStack.push(e)},popState:function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},_currentRules:function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},topState:function(e){return(e=this.conditionStack.length-1-Math.abs(e||0))>=0?this.conditionStack[e]:"INITIAL"},pushState:function(e){this.begin(e)},stateStackSize:function(){return this.conditionStack.length},options:{flex:!0,"case-insensitive":!0},performAction:function(e,t,r,n){switch(r){case 0:break;case 1:return 12;case 2:return 15;case 3:return 24;case 4:return 290;case 5:return 291;case 6:return 29;case 7:return 31;case 8:return 32;case 9:return 293;case 10:return 34;case 11:return 38;case 12:return 39;case 13:return 41;case 14:return 43;case 15:return 48;case 16:return 51;case 17:return 296;case 18:return 61;case 19:return 62;case 20:return 68;case 21:return 71;case 22:return 74;case 23:return 76;case 24:return 79;case 25:return 81;case 26:return 83;case 27:return 183;case 28:return 99;case 29:return 297;case 30:return 132;case 31:return 298;case 32:return 299;case 33:return 109;case 34:return 300;case 35:return 108;case 36:return 301;case 37:return 302;case 38:return 112;case 39:return 114;case 40:return 115;case 41:return 130;case 42:return 124;case 43:return 125;case 44:return 127;case 45:return 133;case 46:return 111;case 47:return 303;case 48:return 304;case 49:return 159;case 50:return 162;case 51:return 166;case 52:return 92;case 53:return 160;case 54:return 305;case 55:return 165;case 56:return 251;case 57:return 187;case 58:return 306;case 59:return 307;case 60:return 213;case 61:return 309;case 62:return 310;case 63:return 208;case 64:return 215;case 65:return 216;case 66:return 223;case 67:return 227;case 68:return 268;case 69:return 311;case 70:return 312;case 71:return 313;case 72:return 314;case 73:return 315;case 74:return 231;case 75:return 316;case 76:return 246;case 77:return 254;case 78:return 255;case 79:return 248;case 80:return 249;case 81:return 250;case 82:return 317;case 83:return 318;case 84:return 252;case 85:return 320;case 86:return 319;case 87:return 321;case 88:return 257;case 89:return 258;case 90:return 261;case 91:return 263;case 92:return 267;case 93:return 271;case 94:return 274;case 95:return 275;case 96:return 13;case 97:return 16;case 98:return 286;case 99:return 218;case 100:return 28;case 101:return 270;case 102:return 80;case 103:return 272;case 104:return 273;case 105:return 280;case 106:return 281;case 107:return 282;case 108:return 283;case 109:return 284;case 110:return 285;case 111:return"EXPONENT";case 112:return 276;case 113:return 277;case 114:return 278;case 115:return 279;case 116:return 86;case 117:return 219;case 118:return 6;case 119:return"INVALID";case 120:console.log(t.yytext)}},rules:[/^(?:\s+|#[^\n\r]*)/i,/^(?:BASE)/i,/^(?:PREFIX)/i,/^(?:SELECT)/i,/^(?:DISTINCT)/i,/^(?:REDUCED)/i,/^(?:\()/i,/^(?:AS)/i,/^(?:\))/i,/^(?:\*)/i,/^(?:CONSTRUCT)/i,/^(?:WHERE)/i,/^(?:\{)/i,/^(?:\})/i,/^(?:DESCRIBE)/i,/^(?:ASK)/i,/^(?:FROM)/i,/^(?:NAMED)/i,/^(?:GROUP)/i,/^(?:BY)/i,/^(?:HAVING)/i,/^(?:ORDER)/i,/^(?:ASC)/i,/^(?:DESC)/i,/^(?:LIMIT)/i,/^(?:OFFSET)/i,/^(?:VALUES)/i,/^(?:;)/i,/^(?:LOAD)/i,/^(?:SILENT)/i,/^(?:INTO)/i,/^(?:CLEAR)/i,/^(?:DROP)/i,/^(?:CREATE)/i,/^(?:ADD)/i,/^(?:TO)/i,/^(?:MOVE)/i,/^(?:COPY)/i,/^(?:INSERT\s+DATA)/i,/^(?:DELETE\s+DATA)/i,/^(?:DELETE\s+WHERE)/i,/^(?:WITH)/i,/^(?:DELETE)/i,/^(?:INSERT)/i,/^(?:USING)/i,/^(?:DEFAULT)/i,/^(?:GRAPH)/i,/^(?:ALL)/i,/^(?:\.)/i,/^(?:OPTIONAL)/i,/^(?:SERVICE)/i,/^(?:BIND)/i,/^(?:UNDEF)/i,/^(?:MINUS)/i,/^(?:UNION)/i,/^(?:FILTER)/i,/^(?:,)/i,/^(?:a)/i,/^(?:\|)/i,/^(?:\/)/i,/^(?:\^)/i,/^(?:\?)/i,/^(?:\+)/i,/^(?:!)/i,/^(?:\[)/i,/^(?:\])/i,/^(?:\|\|)/i,/^(?:&&)/i,/^(?:=)/i,/^(?:!=)/i,/^(?:<)/i,/^(?:>)/i,/^(?:<=)/i,/^(?:>=)/i,/^(?:IN)/i,/^(?:NOT)/i,/^(?:-)/i,/^(?:BOUND)/i,/^(?:BNODE)/i,/^(?:(RAND|NOW|UUID|STRUUID))/i,/^(?:(LANG|DATATYPE|IRI|URI|ABS|CEIL|FLOOR|ROUND|STRLEN|STR|UCASE|LCASE|ENCODE_FOR_URI|YEAR|MONTH|DAY|HOURS|MINUTES|SECONDS|TIMEZONE|TZ|MD5|SHA1|SHA256|SHA384|SHA512|isIRI|isURI|isBLANK|isLITERAL|isNUMERIC))/i,/^(?:(LANGMATCHES|CONTAINS|STRSTARTS|STRENDS|STRBEFORE|STRAFTER|STRLANG|STRDT|sameTerm))/i,/^(?:CONCAT)/i,/^(?:COALESCE)/i,/^(?:IF)/i,/^(?:REGEX)/i,/^(?:SUBSTR)/i,/^(?:REPLACE)/i,/^(?:EXISTS)/i,/^(?:COUNT)/i,/^(?:SUM|MIN|MAX|AVG|SAMPLE)/i,/^(?:GROUP_CONCAT)/i,/^(?:SEPARATOR)/i,/^(?:\^\^)/i,/^(?:true)/i,/^(?:false)/i,/^(?:(<([^<>\"\{\}\|\^`\\\u0000-\u0020])*>))/i,/^(?:((([A-Z]|[a-z]|[\u00C0-\u00D6]|[\u00D8-\u00F6]|[\u00F8-\u02FF]|[\u0370-\u037D]|[\u037F-\u1FFF]|[\u200C-\u200D]|[\u2070-\u218F]|[\u2C00-\u2FEF]|[\u3001-\uD7FF]|[\uF900-\uFDCF]|[\uFDF0-\uFFFD]|[\uD800-\uDB7F][\uDC00-\uDFFF])(((((?:([A-Z]|[a-z]|[\u00C0-\u00D6]|[\u00D8-\u00F6]|[\u00F8-\u02FF]|[\u0370-\u037D]|[\u037F-\u1FFF]|[\u200C-\u200D]|[\u2070-\u218F]|[\u2C00-\u2FEF]|[\u3001-\uD7FF]|[\uF900-\uFDCF]|[\uFDF0-\uFFFD]|[\uD800-\uDB7F][\uDC00-\uDFFF])|_))|-|[0-9]|\u00B7|[\u0300-\u036F]|[\u203F-\u2040])|\.)*(((?:([A-Z]|[a-z]|[\u00C0-\u00D6]|[\u00D8-\u00F6]|[\u00F8-\u02FF]|[\u0370-\u037D]|[\u037F-\u1FFF]|[\u200C-\u200D]|[\u2070-\u218F]|[\u2C00-\u2FEF]|[\u3001-\uD7FF]|[\uF900-\uFDCF]|[\uFDF0-\uFFFD]|[\uD800-\uDB7F][\uDC00-\uDFFF])|_))|-|[0-9]|\u00B7|[\u0300-\u036F]|[\u203F-\u2040]))?)?:))/i,/^(?:(((([A-Z]|[a-z]|[\u00C0-\u00D6]|[\u00D8-\u00F6]|[\u00F8-\u02FF]|[\u0370-\u037D]|[\u037F-\u1FFF]|[\u200C-\u200D]|[\u2070-\u218F]|[\u2C00-\u2FEF]|[\u3001-\uD7FF]|[\uF900-\uFDCF]|[\uFDF0-\uFFFD]|[\uD800-\uDB7F][\uDC00-\uDFFF])(((((?:([A-Z]|[a-z]|[\u00C0-\u00D6]|[\u00D8-\u00F6]|[\u00F8-\u02FF]|[\u0370-\u037D]|[\u037F-\u1FFF]|[\u200C-\u200D]|[\u2070-\u218F]|[\u2C00-\u2FEF]|[\u3001-\uD7FF]|[\uF900-\uFDCF]|[\uFDF0-\uFFFD]|[\uD800-\uDB7F][\uDC00-\uDFFF])|_))|-|[0-9]|\u00B7|[\u0300-\u036F]|[\u203F-\u2040])|\.)*(((?:([A-Z]|[a-z]|[\u00C0-\u00D6]|[\u00D8-\u00F6]|[\u00F8-\u02FF]|[\u0370-\u037D]|[\u037F-\u1FFF]|[\u200C-\u200D]|[\u2070-\u218F]|[\u2C00-\u2FEF]|[\u3001-\uD7FF]|[\uF900-\uFDCF]|[\uFDF0-\uFFFD]|[\uD800-\uDB7F][\uDC00-\uDFFF])|_))|-|[0-9]|\u00B7|[\u0300-\u036F]|[\u203F-\u2040]))?)?:)((((?:([A-Z]|[a-z]|[\u00C0-\u00D6]|[\u00D8-\u00F6]|[\u00F8-\u02FF]|[\u0370-\u037D]|[\u037F-\u1FFF]|[\u200C-\u200D]|[\u2070-\u218F]|[\u2C00-\u2FEF]|[\u3001-\uD7FF]|[\uF900-\uFDCF]|[\uFDF0-\uFFFD]|[\uD800-\uDB7F][\uDC00-\uDFFF])|_))|:|[0-9]|((%([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f]))|(\\(_|~|\.|-|!|\$|&|'|\(|\)|\*|\+|,|;|=|\/|\?|#|@|%))))(((((?:([A-Z]|[a-z]|[\u00C0-\u00D6]|[\u00D8-\u00F6]|[\u00F8-\u02FF]|[\u0370-\u037D]|[\u037F-\u1FFF]|[\u200C-\u200D]|[\u2070-\u218F]|[\u2C00-\u2FEF]|[\u3001-\uD7FF]|[\uF900-\uFDCF]|[\uFDF0-\uFFFD]|[\uD800-\uDB7F][\uDC00-\uDFFF])|_))|-|[0-9]|\u00B7|[\u0300-\u036F]|[\u203F-\u2040])|\.|:|((%([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f]))|(\\(_|~|\.|-|!|\$|&|'|\(|\)|\*|\+|,|;|=|\/|\?|#|@|%))))*((((?:([A-Z]|[a-z]|[\u00C0-\u00D6]|[\u00D8-\u00F6]|[\u00F8-\u02FF]|[\u0370-\u037D]|[\u037F-\u1FFF]|[\u200C-\u200D]|[\u2070-\u218F]|[\u2C00-\u2FEF]|[\u3001-\uD7FF]|[\uF900-\uFDCF]|[\uFDF0-\uFFFD]|[\uD800-\uDB7F][\uDC00-\uDFFF])|_))|-|[0-9]|\u00B7|[\u0300-\u036F]|[\u203F-\u2040])|:|((%([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f]))|(\\(_|~|\.|-|!|\$|&|'|\(|\)|\*|\+|,|;|=|\/|\?|#|@|%)))))?)))/i,/^(?:(_:(((?:([A-Z]|[a-z]|[\u00C0-\u00D6]|[\u00D8-\u00F6]|[\u00F8-\u02FF]|[\u0370-\u037D]|[\u037F-\u1FFF]|[\u200C-\u200D]|[\u2070-\u218F]|[\u2C00-\u2FEF]|[\u3001-\uD7FF]|[\uF900-\uFDCF]|[\uFDF0-\uFFFD]|[\uD800-\uDB7F][\uDC00-\uDFFF])|_))|[0-9])(((((?:([A-Z]|[a-z]|[\u00C0-\u00D6]|[\u00D8-\u00F6]|[\u00F8-\u02FF]|[\u0370-\u037D]|[\u037F-\u1FFF]|[\u200C-\u200D]|[\u2070-\u218F]|[\u2C00-\u2FEF]|[\u3001-\uD7FF]|[\uF900-\uFDCF]|[\uFDF0-\uFFFD]|[\uD800-\uDB7F][\uDC00-\uDFFF])|_))|-|[0-9]|\u00B7|[\u0300-\u036F]|[\u203F-\u2040])|\.)*(((?:([A-Z]|[a-z]|[\u00C0-\u00D6]|[\u00D8-\u00F6]|[\u00F8-\u02FF]|[\u0370-\u037D]|[\u037F-\u1FFF]|[\u200C-\u200D]|[\u2070-\u218F]|[\u2C00-\u2FEF]|[\u3001-\uD7FF]|[\uF900-\uFDCF]|[\uFDF0-\uFFFD]|[\uD800-\uDB7F][\uDC00-\uDFFF])|_))|-|[0-9]|\u00B7|[\u0300-\u036F]|[\u203F-\u2040]))?))/i,/^(?:([\?\$]((((?:([A-Z]|[a-z]|[\u00C0-\u00D6]|[\u00D8-\u00F6]|[\u00F8-\u02FF]|[\u0370-\u037D]|[\u037F-\u1FFF]|[\u200C-\u200D]|[\u2070-\u218F]|[\u2C00-\u2FEF]|[\u3001-\uD7FF]|[\uF900-\uFDCF]|[\uFDF0-\uFFFD]|[\uD800-\uDB7F][\uDC00-\uDFFF])|_))|[0-9])(((?:([A-Z]|[a-z]|[\u00C0-\u00D6]|[\u00D8-\u00F6]|[\u00F8-\u02FF]|[\u0370-\u037D]|[\u037F-\u1FFF]|[\u200C-\u200D]|[\u2070-\u218F]|[\u2C00-\u2FEF]|[\u3001-\uD7FF]|[\uF900-\uFDCF]|[\uFDF0-\uFFFD]|[\uD800-\uDB7F][\uDC00-\uDFFF])|_))|[0-9]|\u00B7|[\u0300-\u036F]|[\u203F-\u2040])*)))/i,/^(?:(@[a-zA-Z]+(-[a-zA-Z0-9]+)*))/i,/^(?:([0-9]+))/i,/^(?:([0-9]*\.[0-9]+))/i,/^(?:([0-9]+\.[0-9]*([eE][+-]?[0-9]+)|\.([0-9])+([eE][+-]?[0-9]+)|([0-9])+([eE][+-]?[0-9]+)))/i,/^(?:(\+([0-9]+)))/i,/^(?:(\+([0-9]*\.[0-9]+)))/i,/^(?:(\+([0-9]+\.[0-9]*([eE][+-]?[0-9]+)|\.([0-9])+([eE][+-]?[0-9]+)|([0-9])+([eE][+-]?[0-9]+))))/i,/^(?:(-([0-9]+)))/i,/^(?:(-([0-9]*\.[0-9]+)))/i,/^(?:(-([0-9]+\.[0-9]*([eE][+-]?[0-9]+)|\.([0-9])+([eE][+-]?[0-9]+)|([0-9])+([eE][+-]?[0-9]+))))/i,/^(?:([eE][+-]?[0-9]+))/i,/^(?:('(([^\u0027\u005C\u000A\u000D])|(\\[tbnrf\\\"']|\\u([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f])|\\U([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f])))*'))/i,/^(?:("(([^\u0022\u005C\u000A\u000D])|(\\[tbnrf\\\"']|\\u([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f])|\\U([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f])))*"))/i,/^(?:('''(('|'')?([^'\\]|(\\[tbnrf\\\"']|\\u([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f])|\\U([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f]))))*'''))/i,/^(?:("""(("|"")?([^\"\\]|(\\[tbnrf\\\"']|\\u([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f])|\\U([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f])([0-9]|[A-F]|[a-f]))))*"""))/i,/^(?:(\((\u0020|\u0009|\u000D|\u000A)*\)))/i,/^(?:(\[(\u0020|\u0009|\u000D|\u000A)*\]))/i,/^(?:$)/i,/^(?:.)/i,/^(?:.)/i],conditions:{INITIAL:{rules:[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120],inclusive:!0}}};function Fr(){this.yy={}}return Zt.lexer=qr,Fr.prototype=Zt,Zt.Parser=Fr,new Fr}();t.parser=i,t.Parser=i.Parser,t.parse=function(){return i.parse.apply(i,arguments)},t.main=function(n){n[1]||(console.log("Usage: "+n[0]+" FILE"),e.exit(1));var i=r(457).readFileSync(r(458).normalize(n[1]),"utf8");return t.parser.parse(i)},r.c[r.s]===n&&t.main(e.argv.slice(1))}).call(this,r(13),r(40)(e))},function(e,t){},function(e,t){},function(e,t){function r(e,t){this._options=e=e||{},t=t||{},this._prefixByIri={};var r=[];for(var n in t){var i=t[n];o(i)&&(this._prefixByIri[i]=n,r.push(i))}var a=r.join("|").replace(/[\]\/\(\)\*\+\?\.\\\$]/g,"\\$&");this._prefixRegex=new RegExp("^("+a+")([a-zA-Z][\\-_a-zA-Z0-9]*)$"),this._usedPrefixes={},this._indent=o(e.indent)?e.indent:" ",this._newline=o(e.newline)?e.newline:"\n"}r.prototype.toQuery=function(e){var t="";return e.queryType&&(t+=e.queryType.toUpperCase()+" "),e.reduced&&(t+="REDUCED "),e.distinct&&(t+="DISTINCT "),e.variables?t+=s(e.variables,void 0,function(e){return o(e)?this.toEntity(e):"("+this.toExpression(e.expression)+" AS "+e.variable+")"},this)+" ":e.template&&(t+=this.group(e.template,!0)+this._newline),e.from&&(t+=s(e.from.default||[],"",function(e){return"FROM "+this.toEntity(e)+this._newline},this)+s(e.from.named||[],"",function(e){return"FROM NAMED "+this.toEntity(e)+this._newline},this)),e.where&&(t+="WHERE "+this.group(e.where,!0)+this._newline),e.updates&&(t+=s(e.updates,";"+this._newline,this.toUpdate,this)),e.group&&(t+="GROUP BY "+s(e.group,void 0,function(e){var t=o(e.expression)?e.expression:"("+this.toExpression(e.expression)+")";return e.variable?"("+t+" AS "+e.variable+")":t},this)+this._newline),e.having&&(t+="HAVING ("+s(e.having,void 0,this.toExpression,this)+")"+this._newline),e.order&&(t+="ORDER BY "+s(e.order,void 0,function(e){var t="("+this.toExpression(e.expression)+")";return e.descending?"DESC "+t:t},this)+this._newline),e.offset&&(t+="OFFSET "+e.offset+this._newline),e.limit&&(t+="LIMIT "+e.limit+this._newline),e.values&&(t+=this.values(e)),(t=this.baseAndPrefixes(e)+t).trim()},r.prototype.baseAndPrefixes=function(e){var t=e.base?"BASE <"+e.base+">"+this._newline:"",r="";for(var n in e.prefixes)(this._options.allPrefixes||this._usedPrefixes[n])&&(r+="PREFIX "+n+": <"+e.prefixes[n]+">"+this._newline);return t+r},r.prototype.toPattern=function(e){var t=e.type||e instanceof Array&&"array"||(e.subject&&e.predicate&&e.object?"triple":"");if(!(t in this))throw new Error("Unknown entry type: "+t);return this[t](e)},r.prototype.triple=function(e){return this.toEntity(e.subject)+" "+this.toEntity(e.predicate)+" "+this.toEntity(e.object)+"."},r.prototype.array=function(e){return s(e,this._newline,this.toPattern,this)},r.prototype.bgp=function(e){return this.encodeTriples(e.triples)},r.prototype.encodeTriples=function(e){if(!e.length)return"";for(var t=[],r="",n="",i=0;i<e.length;i++){var a=e[i];a.subject!==r?(r&&t.push("."+this._newline),r=a.subject,n=a.predicate,t.push(this.toEntity(r)," ",this.toEntity(n))):a.predicate!==n?(n=a.predicate,t.push(";"+this._newline,this._indent,this.toEntity(n))):t.push(","),t.push(" ",this.toEntity(a.object))}return t.push("."),t.join("")},r.prototype.graph=function(e){return"GRAPH "+this.toEntity(e.name)+" "+this.group(e)},r.prototype.group=function(e,t){return-1===(e=!0!==t?this.array(e.patterns||e.triples):this.toPattern("group"!==e.type?e:e.patterns)).indexOf(this._newline)?"{ "+e+" }":"{"+this._newline+this.indent(e)+this._newline+"}"},r.prototype.query=function(e){return this.toQuery(e)},r.prototype.filter=function(e){return"FILTER("+this.toExpression(e.expression)+")"},r.prototype.bind=function(e){return"BIND("+this.toExpression(e.expression)+" AS "+e.variable+")"},r.prototype.optional=function(e){return"OPTIONAL "+this.group(e)},r.prototype.union=function(e){return s(e.patterns,this._newline+"UNION"+this._newline,function(e){return this.group(e,!0)},this)},r.prototype.minus=function(e){return"MINUS "+this.group(e)},r.prototype.values=function(e){var t,r,n=Object.keys(e.values.reduce(function(e,t){for(var r in t)e[r]=!0;return e},{}));return 1===n.length?t=r="":(t="(",r=")"),"VALUES "+t+n.join(" ")+r+" {"+this._newline+s(e.values,this._newline,function(e){return" "+t+s(n,void 0,function(t){return void 0!==e[t]?this.toEntity(e[t]):"UNDEF"},this)+r},this)+this._newline+"}"},r.prototype.service=function(e){return"SERVICE "+(e.silent?"SILENT ":"")+this.toEntity(e.name)+" "+this.group(e)},r.prototype.toExpression=function(e){if(o(e))return this.toEntity(e);switch(e.type.toLowerCase()){case"aggregate":return e.aggregation.toUpperCase()+"("+(e.distinct?"DISTINCT ":"")+this.toExpression(e.expression)+(e.separator?"; SEPARATOR = "+this.toEntity('"'+e.separator+'"'):"")+")";case"functioncall":return this.toEntity(e.function)+"("+s(e.args,", ",this.toExpression,this)+")";case"operation":var t=e.operator.toUpperCase(),r=e.args||[];switch(e.operator.toLowerCase()){case"<":case">":case">=":case"<=":case"&&":case"||":case"=":case"!=":case"+":case"-":case"*":case"/":return(o(r[0])?this.toEntity(r[0]):"("+this.toExpression(r[0])+")")+" "+t+" "+(o(r[1])?this.toEntity(r[1]):"("+this.toExpression(r[1])+")");case"!":return"!("+this.toExpression(r[0])+")";case"notin":t="NOT IN";case"in":return this.toExpression(r[0])+" "+t+"("+(o(r[1])?r[1]:s(r[1],", ",this.toExpression,this))+")";case"notexists":t="NOT EXISTS";case"exists":return t+" "+this.group(r[0],!0);default:return t+"("+s(r,", ",this.toExpression,this)+")"}default:throw new Error("Unknown expression type: "+e.type)}},r.prototype.toEntity=function(e){if(o(e))switch(e[0]){case"?":case"$":case"*":case"_":return e;case'"':var t=e.match(/^"([^]*)"(?:(@.+)|\^\^(.+))?$/)||{},r=t[1]||"",a=t[2]||"",s=t[3];if(e='"'+r.replace(n,i)+'"'+a,s){if("http://www.w3.org/2001/XMLSchema#integer"===s&&/^\d+$/.test(r))return r+" ";e+="^^"+this.encodeIRI(s)}return e;default:return this.encodeIRI(e)}else{var c=e.items.map(this.toEntity,this),u=e.pathType;switch(u){case"^":case"!":return u+c[0];case"*":case"+":case"?":return"("+c[0]+u+")";default:return"("+c.join(u)+")"}}};var n=/["\\\t\n\r\b\f]/g,i=function(e){return a[e]},a={"\\":"\\\\",'"':'\\"',"\t":"\\t","\n":"\\n","\r":"\\r","\b":"\\b","\f":"\\f"};function o(e){return"string"==typeof e}function s(e,t,r,n){return e.map(r,n).join(o(t)?t:" ")}r.prototype.encodeIRI=function(e){var t=this._prefixRegex.exec(e);if(t){var r=this._prefixByIri[t[1]];return this._usedPrefixes[r]=!0,r+":"+t[2]}return"<"+e+">"},r.prototype.toUpdate=function(e){switch(e.type||e.updateType){case"load":return"LOAD"+(e.source?" "+this.toEntity(e.source):"")+(e.destination?" INTO GRAPH "+this.toEntity(e.destination):"");case"insert":return"INSERT DATA "+this.group(e.insert,!0);case"delete":return"DELETE DATA "+this.group(e.delete,!0);case"deletewhere":return"DELETE WHERE "+this.group(e.delete,!0);case"insertdelete":return(e.graph?"WITH "+this.toEntity(e.graph)+this._newline:"")+(e.delete.length?"DELETE "+this.group(e.delete,!0)+this._newline:"")+(e.insert.length?"INSERT "+this.group(e.insert,!0)+this._newline:"")+"WHERE "+this.group(e.where,!0);case"add":case"copy":case"move":return e.type.toUpperCase()+(e.source.default?" DEFAULT ":" ")+"TO "+this.toEntity(e.destination.name);case"create":case"clear":case"drop":return e.type.toUpperCase()+(e.silent?" SILENT ":" ")+(e.graph.default?"DEFAULT":e.graph.named?"NAMED":e.graph.all?"ALL":"GRAPH "+this.toEntity(e.graph.name));default:throw new Error("Unknown update query type: "+e.type)}},r.prototype.indent=function(e){return e.replace(/^/gm,this._indent)},e.exports=function(e){return{stringify:function(t){return new r(e,t.prefixes).toQuery(t)}}}},function(e,t,r){(function(e,r){var n=200,i="__lodash_hash_undefined__",a=1,o=2,s=9007199254740991,c="[object Arguments]",u="[object Array]",l="[object AsyncFunction]",f="[object Boolean]",d="[object Date]",h="[object Error]",p="[object Function]",y="[object GeneratorFunction]",m="[object Map]",g="[object Number]",b="[object Null]",v="[object Object]",_="[object Proxy]",w="[object RegExp]",S="[object Set]",E="[object String]",x="[object Symbol]",T="[object Undefined]",O="[object ArrayBuffer]",A="[object DataView]",I=/^\[object .+?Constructor\]$/,N=/^(?:0|[1-9]\d*)$/,R={};R["[object Float32Array]"]=R["[object Float64Array]"]=R["[object Int8Array]"]=R["[object Int16Array]"]=R["[object Int32Array]"]=R["[object Uint8Array]"]=R["[object Uint8ClampedArray]"]=R["[object Uint16Array]"]=R["[object Uint32Array]"]=!0,R[c]=R[u]=R[O]=R[f]=R[A]=R[d]=R[h]=R[p]=R[m]=R[g]=R[v]=R[w]=R[S]=R[E]=R["[object WeakMap]"]=!1;var k="object"==typeof e&&e&&e.Object===Object&&e,P="object"==typeof self&&self&&self.Object===Object&&self,j=k||P||Function("return this")(),D=t&&!t.nodeType&&t,C=D&&"object"==typeof r&&r&&!r.nodeType&&r,M=C&&C.exports===D,L=M&&k.process,q=function(){try{return L&&L.binding&&L.binding("util")}catch(e){}}(),F=q&&q.isTypedArray;function B(e,t){for(var r=-1,n=null==e?0:e.length;++r<n;)if(t(e[r],r,e))return!0;return!1}function U(e){var t=-1,r=Array(e.size);return e.forEach(function(e,n){r[++t]=[n,e]}),r}function V(e){var t=-1,r=Array(e.size);return e.forEach(function(e){r[++t]=e}),r}var H,z,G,Q=Array.prototype,X=Function.prototype,$=Object.prototype,J=j["__core-js_shared__"],Y=X.toString,K=$.hasOwnProperty,W=(H=/[^.]+$/.exec(J&&J.keys&&J.keys.IE_PROTO||""))?"Symbol(src)_1."+H:"",Z=$.toString,ee=RegExp("^"+Y.call(K).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),te=M?j.Buffer:void 0,re=j.Symbol,ne=j.Uint8Array,ie=$.propertyIsEnumerable,ae=Q.splice,oe=re?re.toStringTag:void 0,se=Object.getOwnPropertySymbols,ce=te?te.isBuffer:void 0,ue=(z=Object.keys,G=Object,function(e){return z(G(e))}),le=qe(j,"DataView"),fe=qe(j,"Map"),de=qe(j,"Promise"),he=qe(j,"Set"),pe=qe(j,"WeakMap"),ye=qe(Object,"create"),me=Ve(le),ge=Ve(fe),be=Ve(de),ve=Ve(he),_e=Ve(pe),we=re?re.prototype:void 0,Se=we?we.valueOf:void 0;function Ee(e){var t=-1,r=null==e?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}function xe(e){var t=-1,r=null==e?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}function Te(e){var t=-1,r=null==e?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}function Oe(e){var t=-1,r=null==e?0:e.length;for(this.__data__=new Te;++t<r;)this.add(e[t])}function Ae(e){var t=this.__data__=new xe(e);this.size=t.size}function Ie(e,t){var r=Ge(e),n=!r&&ze(e),i=!r&&!n&&Qe(e),a=!r&&!n&&!i&&Ke(e),o=r||n||i||a,s=o?function(e,t){for(var r=-1,n=Array(e);++r<e;)n[r]=t(r);return n}(e.length,String):[],c=s.length;for(var u in e)!t&&!K.call(e,u)||o&&("length"==u||i&&("offset"==u||"parent"==u)||a&&("buffer"==u||"byteLength"==u||"byteOffset"==u)||Ue(u,c))||s.push(u);return s}function Ne(e,t){for(var r=e.length;r--;)if(He(e[r][0],t))return r;return-1}function Re(e){return null==e?void 0===e?T:b:oe&&oe in Object(e)?function(e){var t=K.call(e,oe),r=e[oe];try{e[oe]=void 0;var n=!0}catch(e){}var i=Z.call(e);n&&(t?e[oe]=r:delete e[oe]);return i}(e):function(e){return Z.call(e)}(e)}function ke(e){return Ye(e)&&Re(e)==c}function Pe(e,t,r,n,i){return e===t||(null==e||null==t||!Ye(e)&&!Ye(t)?e!=e&&t!=t:function(e,t,r,n,i,s){var l=Ge(e),p=Ge(t),y=l?u:Be(e),b=p?u:Be(t),_=(y=y==c?v:y)==v,T=(b=b==c?v:b)==v,I=y==b;if(I&&Qe(e)){if(!Qe(t))return!1;l=!0,_=!1}if(I&&!_)return s||(s=new Ae),l||Ke(e)?Ce(e,t,r,n,i,s):function(e,t,r,n,i,s,c){switch(r){case A:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case O:return!(e.byteLength!=t.byteLength||!s(new ne(e),new ne(t)));case f:case d:case g:return He(+e,+t);case h:return e.name==t.name&&e.message==t.message;case w:case E:return e==t+"";case m:var u=U;case S:var l=n&a;if(u||(u=V),e.size!=t.size&&!l)return!1;var p=c.get(e);if(p)return p==t;n|=o,c.set(e,t);var y=Ce(u(e),u(t),n,i,s,c);return c.delete(e),y;case x:if(Se)return Se.call(e)==Se.call(t)}return!1}(e,t,y,r,n,i,s);if(!(r&a)){var N=_&&K.call(e,"__wrapped__"),R=T&&K.call(t,"__wrapped__");if(N||R){var k=N?e.value():e,P=R?t.value():t;return s||(s=new Ae),i(k,P,r,n,s)}}if(!I)return!1;return s||(s=new Ae),function(e,t,r,n,i,o){var s=r&a,c=Me(e),u=c.length,l=Me(t).length;if(u!=l&&!s)return!1;var f=u;for(;f--;){var d=c[f];if(!(s?d in t:K.call(t,d)))return!1}var h=o.get(e);if(h&&o.get(t))return h==t;var p=!0;o.set(e,t),o.set(t,e);var y=s;for(;++f<u;){d=c[f];var m=e[d],g=t[d];if(n)var b=s?n(g,m,d,t,e,o):n(m,g,d,e,t,o);if(!(void 0===b?m===g||i(m,g,r,n,o):b)){p=!1;break}y||(y="constructor"==d)}if(p&&!y){var v=e.constructor,_=t.constructor;v!=_&&"constructor"in e&&"constructor"in t&&!("function"==typeof v&&v instanceof v&&"function"==typeof _&&_ instanceof _)&&(p=!1)}return o.delete(e),o.delete(t),p}(e,t,r,n,i,s)}(e,t,r,n,Pe,i))}function je(e){return!(!Je(e)||function(e){return!!W&&W in e}(e))&&(Xe(e)?ee:I).test(Ve(e))}function De(e){if(r=(t=e)&&t.constructor,n="function"==typeof r&&r.prototype||$,t!==n)return ue(e);var t,r,n,i=[];for(var a in Object(e))K.call(e,a)&&"constructor"!=a&&i.push(a);return i}function Ce(e,t,r,n,i,s){var c=r&a,u=e.length,l=t.length;if(u!=l&&!(c&&l>u))return!1;var f=s.get(e);if(f&&s.get(t))return f==t;var d=-1,h=!0,p=r&o?new Oe:void 0;for(s.set(e,t),s.set(t,e);++d<u;){var y=e[d],m=t[d];if(n)var g=c?n(m,y,d,t,e,s):n(y,m,d,e,t,s);if(void 0!==g){if(g)continue;h=!1;break}if(p){if(!B(t,function(e,t){if(a=t,!p.has(a)&&(y===e||i(y,e,r,n,s)))return p.push(t);var a})){h=!1;break}}else if(y!==m&&!i(y,m,r,n,s)){h=!1;break}}return s.delete(e),s.delete(t),h}function Me(e){return function(e,t,r){var n=t(e);return Ge(e)?n:function(e,t){for(var r=-1,n=t.length,i=e.length;++r<n;)e[i+r]=t[r];return e}(n,r(e))}(e,We,Fe)}function Le(e,t){var r,n,i=e.__data__;return("string"==(n=typeof(r=t))||"number"==n||"symbol"==n||"boolean"==n?"__proto__"!==r:null===r)?i["string"==typeof t?"string":"hash"]:i.map}function qe(e,t){var r=function(e,t){return null==e?void 0:e[t]}(e,t);return je(r)?r:void 0}Ee.prototype.clear=function(){this.__data__=ye?ye(null):{},this.size=0},Ee.prototype.delete=function(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t},Ee.prototype.get=function(e){var t=this.__data__;if(ye){var r=t[e];return r===i?void 0:r}return K.call(t,e)?t[e]:void 0},Ee.prototype.has=function(e){var t=this.__data__;return ye?void 0!==t[e]:K.call(t,e)},Ee.prototype.set=function(e,t){var r=this.__data__;return this.size+=this.has(e)?0:1,r[e]=ye&&void 0===t?i:t,this},xe.prototype.clear=function(){this.__data__=[],this.size=0},xe.prototype.delete=function(e){var t=this.__data__,r=Ne(t,e);return!(r<0)&&(r==t.length-1?t.pop():ae.call(t,r,1),--this.size,!0)},xe.prototype.get=function(e){var t=this.__data__,r=Ne(t,e);return r<0?void 0:t[r][1]},xe.prototype.has=function(e){return Ne(this.__data__,e)>-1},xe.prototype.set=function(e,t){var r=this.__data__,n=Ne(r,e);return n<0?(++this.size,r.push([e,t])):r[n][1]=t,this},Te.prototype.clear=function(){this.size=0,this.__data__={hash:new Ee,map:new(fe||xe),string:new Ee}},Te.prototype.delete=function(e){var t=Le(this,e).delete(e);return this.size-=t?1:0,t},Te.prototype.get=function(e){return Le(this,e).get(e)},Te.prototype.has=function(e){return Le(this,e).has(e)},Te.prototype.set=function(e,t){var r=Le(this,e),n=r.size;return r.set(e,t),this.size+=r.size==n?0:1,this},Oe.prototype.add=Oe.prototype.push=function(e){return this.__data__.set(e,i),this},Oe.prototype.has=function(e){return this.__data__.has(e)},Ae.prototype.clear=function(){this.__data__=new xe,this.size=0},Ae.prototype.delete=function(e){var t=this.__data__,r=t.delete(e);return this.size=t.size,r},Ae.prototype.get=function(e){return this.__data__.get(e)},Ae.prototype.has=function(e){return this.__data__.has(e)},Ae.prototype.set=function(e,t){var r=this.__data__;if(r instanceof xe){var i=r.__data__;if(!fe||i.length<n-1)return i.push([e,t]),this.size=++r.size,this;r=this.__data__=new Te(i)}return r.set(e,t),this.size=r.size,this};var Fe=se?function(e){return null==e?[]:(e=Object(e),function(e,t){for(var r=-1,n=null==e?0:e.length,i=0,a=[];++r<n;){var o=e[r];t(o,r,e)&&(a[i++]=o)}return a}(se(e),function(t){return ie.call(e,t)}))}:function(){return[]},Be=Re;function Ue(e,t){return!!(t=null==t?s:t)&&("number"==typeof e||N.test(e))&&e>-1&&e%1==0&&e<t}function Ve(e){if(null!=e){try{return Y.call(e)}catch(e){}try{return e+""}catch(e){}}return""}function He(e,t){return e===t||e!=e&&t!=t}(le&&Be(new le(new ArrayBuffer(1)))!=A||fe&&Be(new fe)!=m||de&&"[object Promise]"!=Be(de.resolve())||he&&Be(new he)!=S||pe&&"[object WeakMap]"!=Be(new pe))&&(Be=function(e){var t=Re(e),r=t==v?e.constructor:void 0,n=r?Ve(r):"";if(n)switch(n){case me:return A;case ge:return m;case be:return"[object Promise]";case ve:return S;case _e:return"[object WeakMap]"}return t});var ze=ke(function(){return arguments}())?ke:function(e){return Ye(e)&&K.call(e,"callee")&&!ie.call(e,"callee")},Ge=Array.isArray;var Qe=ce||function(){return!1};function Xe(e){if(!Je(e))return!1;var t=Re(e);return t==p||t==y||t==l||t==_}function $e(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=s}function Je(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)}function Ye(e){return null!=e&&"object"==typeof e}var Ke=F?function(e){return function(t){return e(t)}}(F):function(e){return Ye(e)&&$e(e.length)&&!!R[Re(e)]};function We(e){return null!=(t=e)&&$e(t.length)&&!Xe(t)?Ie(e):De(e);var t}r.exports=function(e,t){return Pe(e,t)}}).call(this,r(9),r(40)(e))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(72),i=r(73),a=r(95).Generator,o=n.types,s=n.expressionTypes;let c;const u=new i.default;function l(e){d();let t=h(e=function(e){return function e(t,r){if(Array.isArray(t))return t.map(t=>e(t,r));if(!t.type)return t;if((t.type===o.PATTERN||t.type===o.PATH)&&t.graph)return r[t.graph.value]||(r[t.graph.value]={graph:t.graph,values:[]}),r[t.graph.value].values.push(t),t;const n={};const i={};const a={};for(let r of Object.keys(t)){const o={};n[r]=e(t[r],o);const s=Object.keys(o);if(s.length>1){let e=w(o[s[0]].values);for(let t=1;t<s.length;++t){const r=w(o[s[t]].values);e=u.createJoin(e,r)}return s.map(e=>delete o[e]),e}if(1===s.length){const e=o[s[0]].graph;i[r]=e,a[e.value]=e}}const s=Object.keys(a);if(s.length>0)if(1===s.length&&t.type!==o.PROJECT)r[s[0]]={graph:a[s[0]],values:[n]};else for(let e of Object.keys(i))i[e].value.length>0&&(n[e]=u.createGraph(n[e],i[e]));return n}(e,{})}(e));return"group"===t.type?t.patterns[0]:t}function f(e){return Array.prototype.concat(...e).filter(e=>e)}function d(){c={project:!1,extend:[],group:[],aggregates:[],order:[]}}function h(e){switch(e.type!==o.EXTEND&&e.type!==o.ORDER_BY&&(c.project=!1),e.type){case o.EXPRESSION:return p(e);case o.ASK:return _(e,o.ASK);case o.BGP:return function(e){let t=e.patterns.map(b);return 0===t.length?null:{type:"bgp",triples:t}}(e);case o.CONSTRUCT:return function(e){return{type:"query",prefixes:{},queryType:"CONSTRUCT",template:e.template.map(b),where:f([h(e.input)])}}(e);case o.DESCRIBE:return _(e,o.DESCRIBE);case o.DISTINCT:return function(e){let t=h(e.input);return t.patterns[0].distinct=!0,t}(e);case o.EXTEND:return function(e){if(c.project)return c.extend.push(e),h(e.input);return f([h(e.input),{type:"bind",variable:m(e.variable),expression:p(e.expression)}])}(e);case o.FROM:return function(e){let t=h(e.input);return t.patterns[0].from={default:e.default.map(m),named:e.named.map(m)},t}(e);case o.FILTER:return function(e){return{type:"group",patterns:f([h(e.input),{type:"filter",expression:p(e.expression)}])}}(e);case o.GRAPH:return function(e){return{type:"graph",patterns:f([h(e.input)]),name:m(e.name)}}(e);case o.GROUP:return function(e){let t=h(e.input),r=e.aggregates.map(g);return c.aggregates.push(...r),c.group.push(...e.variables),t}(e);case o.JOIN:return function(e){return f([h(e.left),h(e.right)])}(e);case o.LEFT_JOIN:return function(e){let t={type:"optional",patterns:[h(e.right)]};e.expression&&t.patterns.push({type:"filter",expression:p(e.expression)});return t.patterns=f(t.patterns),f([h(e.left),t])}(e);case o.MINUS:return function(e){let t=h(e.right);"group"===t.type&&(t=t.patterns);return f([h(e.left),{type:"minus",patterns:t}])}(e);case o.ORDER_BY:return function(e){return c.order.push(...e.expressions),h(e.input)}(e);case o.PATH:return function(e){return{type:"bgp",triples:[{subject:m(e.subject),predicate:y(e.predicate),object:m(e.object)}]}}(e);case o.PATTERN:return b(e);case o.PROJECT:return _(e,o.PROJECT);case o.REDUCED:return function(e){let t=h(e.input);return t.patterns[0].reduced=!0,t}(e);case o.SERVICE:return function(e){let t=h(e.input);"group"===t.type&&(t=t.patterns);Array.isArray(t)||(t=[t]);return{type:"service",name:m(e.name),silent:e.silent,patterns:t}}(e);case o.SLICE:return function(e){let t=h(e.input),r=t.patterns[0];0!==e.start&&(r.offset=e.start);void 0!==e.length&&(r.limit=e.length);return t}(e);case o.UNION:return function(e){return{type:"union",patterns:f([h(e.left),h(e.right)])}}(e);case o.VALUES:return function(e){return{type:"values",values:e.bindings.map(t=>{let r={};for(let n of e.variables){let e="?"+n.value;t[e]?r[e]=m(t[e]):r[e]=void 0}return r})}}(e)}throw new Error("Unknown Operation type "+e.type)}function p(e){switch(e.expressionType){case s.AGGREGATE:return function(e){let t={expression:p(e.expression),type:"aggregate",aggregation:e.aggregator,distinct:e.distinct};e.separator&&(t.separator=e.separator);return t}(e);case s.EXISTENCE:return function(e){return{type:"operation",operator:e.not?"notexists":"exists",args:f([h(e.input)])}}(e);case s.NAMED:return function(e){return{type:"functionCall",function:m(e.name),args:e.args.map(p)}}(e);case s.OPERATOR:return function(e){if("desc"===e.operator){let t={expression:p(e.args[0]),descending:!0};return t}let t={type:"operation",operator:e.operator,args:e.args.map(p)};"in"!==t.operator&&"notin"!==t.operator||(t.args=[t.args[0]].concat([t.args.slice(1)]));return t}(e);case s.TERM:return function(e){return m(e.term)}(e)}throw new Error("Unknown Expression Operation type "+e.expressionType)}function y(e){switch(e.type){case o.ALT:return function(e){let t=y(e.left),r=y(e.right);if("!"===t.pathType&&"!"===r.pathType)return{type:"path",pathType:"!",items:[{type:"path",pathType:"|",items:[].concat(t.items,r.items)}]};return{type:"path",pathType:"|",items:[t,r]}}(e);case o.INV:return function(e){if(e.path.type===o.NPS){let t=e.path.iris.map(e=>({type:"path",pathType:"^",items:[m(e)]}));return t.length<=1?{type:"path",pathType:"!",items:t}:{type:"path",pathType:"!",items:[{type:"path",pathType:"|",items:t}]}}return{type:"path",pathType:"^",items:[y(e.path)]}}(e);case o.LINK:return function(e){return m(e.iri)}(e);case o.NPS:return function(e){return e.iris.length<=1?{type:"path",pathType:"!",items:e.iris.map(m)}:{type:"path",pathType:"!",items:[{type:"path",pathType:"|",items:e.iris.map(m)}]}}(e);case o.ONE_OR_MORE_PATH:return function(e){return{type:"path",pathType:"+",items:[y(e.path)]}}(e);case o.SEQ:return function(e){return{type:"path",pathType:"/",items:[y(e.left),y(e.right)]}}(e);case o.ZERO_OR_MORE_PATH:return function(e){return{type:"path",pathType:"*",items:[y(e.path)]}}(e);case o.ZERO_OR_ONE_PATH:return function(e){return{type:"path",pathType:"?",items:[y(e.path)]}}(e)}throw new Error("Unknown Path type "+e.type)}function m(e){if("BlankNode"===e.termType)return"_:"+e.value;if("Literal"===e.termType){let t=e,r=`"${e.value}"`;return t.language?r+="@"+t.language:t.datatype&&"http://www.w3.org/2001/XMLSchema#string"!==t.datatype.value&&(r+="^^"+t.datatype.value),r}if("NamedNode"===e.termType)return e.value;if("Variable"===e.termType)return"?"+e.value;throw new Error("Unknown Term type "+e.termType)}function g(e){return e}function b(e){return{subject:m(e.subject),predicate:m(e.predicate),object:m(e.object)}}function v(e,t){if("string"==typeof e){if(t[e])return t[e]}else if(Array.isArray(e))e=e.map(e=>v(e,t));else for(let r of Object.keys(e))e[r]=v(e[r],t);return e}function _(e,t){let r={type:"query",prefixes:{}};t===o.PROJECT?(r.queryType="SELECT",r.variables=e.variables.map(m)):t===o.ASK?r.queryType="ASK":t===o.DESCRIBE&&(r.queryType="DESCRIBE",r.variables=e.terms.map(m));let n=c.extend,i=c.group,a=c.aggregates,s=c.order;d(),c.project=!0;let u=f([h(e.input)]);1===u.length&&"group"===u[0].type&&(u=u[0].patterns),r.where=u;let l={};for(let e of c.aggregates)l[m(e.variable)]=p(e);let y={};for(let e=c.extend.length-1;e>=0;--e){let t=c.extend[e];y[m(t.variable)]=v(p(t.expression),l)}if(c.group.length>0&&(r.group=c.group.map(m).map(e=>{if(y[e]){let t=y[e];return delete y[e],{variable:e,expression:t}}return{expression:e}})),c.order.length>0&&(r.order=c.order.map(h).map(e=>e.descending?e:{expression:e})),r.variables&&(r.variables=r.variables.map(e=>y[e]?{variable:e,expression:y[e]}:e),0===r.variables.length&&(r.variables=["*"])),r.where.length>0&&"filter"===r.where[r.where.length-1].type){let e=r.where[r.where.length-1];(function e(t,r){if(Array.isArray(t))return t.some(t=>e(t,r));if(t===Object(t))return Object.keys(t).some(n=>e(t[n],r));return r.indexOf(t)>=0})(e,Object.keys(l))&&(r.having=f([v(e.expression,l)]),r.where.splice(-1))}return c.extend=n,c.group=i,c.aggregates=a,c.order=s,r={type:"group",patterns:[r]}}function w(e){const t=u.createBgp(e),r=e[0].graph;return 0===r.value.length?t:u.createGraph(t,r)}t.toSparql=function(e){return(new a).stringify(l(e))},t.toSparqlJs=l},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(74);t.NodeHandlerSelectionField=class extends n.NodeHandlerSelectionAdapter{constructor(e,t){super("Field",e,t)}handle(e,t){return this.fieldToOperation(t,e,!0)}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(74);t.NodeHandlerSelectionFragmentSpread=class extends n.NodeHandlerSelectionAdapter{constructor(e,t){super("FragmentSpread",e,t)}handle(e,t){const r=t.fragmentDefinitions[e.name.value];if(!r)throw new Error("Undefined fragment definition: "+e.name.value);const n={alias:null,arguments:null,directives:r.directives,kind:"Field",name:e.name,selectionSet:r.selectionSet},i=[this.util.newTypePattern(t.subject,r.typeCondition,t)];return this.util.operationFactory.createLeftJoin(this.util.operationFactory.createBgp([]),this.fieldToOperation(t,n,!1,i))}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(74);t.NodeHandlerSelectionInlineFragment=class extends n.NodeHandlerSelectionAdapter{constructor(e,t){super("InlineFragment",e,t)}handle(e,t){const r={alias:null,arguments:null,directives:e.directives,kind:"Field",name:{kind:"Name",value:t.subject.value},selectionSet:e.selectionSet},n=e.typeCondition?[this.util.newTypePattern(t.subject,e.typeCondition,t)]:[];return this.util.operationFactory.createLeftJoin(this.util.operationFactory.createBgp([]),this.fieldToOperation(t,r,!1,n))}}},function(e,t,r){"use strict";var n=this&&this.__awaiter||function(e,t,r,n){return new(r||(r=Promise))(function(i,a){function o(e){try{c(n.next(e))}catch(e){a(e)}}function s(e){try{c(n.throw(e))}catch(e){a(e)}}function c(e){e.done?i(e.value):new r(function(t){t(e.value)}).then(o,s)}c((n=n.apply(e,t||[])).next())})};Object.defineProperty(t,"__esModule",{value:!0});const i=r(705),a=r(195),o=r(196),s=r(57),c=r(198);class u{constructor(e){(e=e||{}).variableDelimiter=e.variableDelimiter||"_",e.expressionVariableCounter=e.expressionVariableCounter||0,this.util=new c.Util(e),this.initializeNodeHandlers(e)}static registerNodeHandlers(e,t){e.registerNodeHandler(new a.NodeHandlerDocument(e,t)),e.registerNodeHandler(new a.NodeHandlerDefinitionOperation(e,t)),e.registerNodeHandler(new a.NodeHandlerDefinitionFragment(e,t)),e.registerNodeHandler(new a.NodeHandlerSelectionFragmentSpread(e,t)),e.registerNodeHandler(new a.NodeHandlerSelectionInlineFragment(e,t)),e.registerNodeHandler(new a.NodeHandlerSelectionField(e,t))}static registerNodeValueHandlers(e,t){e.registerNodeValueHandler(new a.NodeValueHandlerVariable(e,t)),e.registerNodeValueHandler(new a.NodeValueHandlerInt(e,t)),e.registerNodeValueHandler(new a.NodeValueHandlerFloat(e,t)),e.registerNodeValueHandler(new a.NodeValueHandlerString(e,t)),e.registerNodeValueHandler(new a.NodeValueHandlerBoolean(e,t)),e.registerNodeValueHandler(new a.NodeValueHandlerNull(e,t)),e.registerNodeValueHandler(new a.NodeValueHandlerEnum(e,t)),e.registerNodeValueHandler(new a.NodeValueHandlerList(e,t)),e.registerNodeValueHandler(new a.NodeValueHandlerObject(e,t))}static registerDirectiveNodeHandlers(e,t){e.registerDirectiveNodeHandler(new o.DirectiveNodeHandlerInclude(e,t)),e.registerDirectiveNodeHandler(new o.DirectiveNodeHandlerOptional(e,t)),e.registerDirectiveNodeHandler(new o.DirectiveNodeHandlerPlural(e,t)),e.registerDirectiveNodeHandler(new o.DirectiveNodeHandlerSingle(e,t)),e.registerDirectiveNodeHandler(new o.DirectiveNodeHandlerSkip(e,t))}graphqlToSparqlAlgebra(e,t,r){return n(this,void 0,void 0,function*(){return this.graphqlToSparqlAlgebraRawContext(e,yield this.util.contextParser.parse(t),r)})}graphqlToSparqlAlgebraRawContext(e,t,r){r=r||{};const n="string"==typeof e?i.parse(e):e,a={context:t,fragmentDefinitions:this.indexFragments(n),graph:this.util.dataFactory.defaultGraph(),path:[],singularizeState:s.SingularizeState.PLURAL,singularizeVariables:r.singularizeVariables||{},subject:null,terminalVariables:[],variablesDict:r.variablesDict||{},variablesMetaDict:{}};return this.util.handleNode(n,a)}indexFragments(e){const t={},r=[];for(const n of e.definitions)"FragmentDefinition"===n.kind?t[n.name.value]=n:r.push(n);return e.definitions=r,t}initializeNodeHandlers(e){u.registerNodeHandlers(this.util,e),u.registerNodeValueHandlers(this.util,e),u.registerDirectiveNodeHandlers(this.util,e)}}t.Converter=u},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(467),i=r(96);class a{constructor(e){(e=e||{delimiter:"_"}).prefixVariableQuestionMark=!1,this.delimiter=e.delimiter||"_",this.parser=new i.SparqlJsonParser(e),this.materializeRdfJsTerms=e.materializeRdfJsTerms}static addValueToTree(e,t,r,n,i,o){const s=t[0],c=n?n+o+s:s,u=i.singularizeVariables[c];if(1===t.length)u?e[s]||(e[s]=r):(e[s]||(e[s]=[]),e[s].push(r));else{let n;u?(e[s]||(e[s]={}),n=e[s]):(e[s]||(e[s]=[{}]),n=e[s][0]),a.addValueToTree(n,t.slice(1),r,c,i,o)}}static mergeTrees(e,t){if(typeof e!=typeof t)throw new Error(`Two incompatible tree nodes were found: ${typeof e} and ${typeof t}`);if(Array.isArray(e)!==Array.isArray(t))throw new Error(`Two incompatible tree nodes were found: Array?${Array.isArray(e)} and Array?${Array.isArray(t)}`);if("object"==typeof e&&"object"==typeof t){if(e.termType&&t.termType)return e.equals(t)?{valid:!0,result:e}:{valid:!1,result:e};if(Array.isArray(e)&&Array.isArray(t)){if(e.length>0){const r=[];let n=!1;for(let i=0;i<e.length;i++){const o=a.mergeTrees(e[i],t[0]);o.valid?(n=!0,r.push(o.result)):r.push(e[i])}if(n)return{valid:!0,result:r}}return{valid:!0,result:e.concat(t)}}{const r={};for(const e in t)r[e]=t[e];for(const t in e)if(r[t]){const n=a.mergeTrees(e[t],r[t]);if(!n.valid)return{valid:!1,result:e};r[t]=n.result}else r[t]=e[t];return{valid:!0,result:r}}}throw new Error(`Unmergable tree types: ${typeof e} and ${typeof t}`)}static materializeTree(e){if(e.termType)return n.getTermRaw(e);if(Array.isArray(e))return e.map(a.materializeTree);{const t={};for(const r in e)t[r]=a.materializeTree(e[r]);return t}}sparqlJsonResultsToTree(e,t){return this.bindingsToTree(this.parser.parseJsonResults(e),t||{singularizeVariables:{}})}bindingsToTree(e,t){const r=t&&t.singularizeVariables[""];let n=r?{}:[];for(const i of e){const e=r?{}:[{}];for(const n in i){const o=n.split(this.delimiter),s=i[n];a.addValueToTree(r?e:e[0],o,s,"",t,this.delimiter)}n=a.mergeTrees(n,e).result}return this.materializeRdfJsTerms&&(n=a.materializeTree(n)),n}}t.Converter=a},function(e,t,r){"use strict";function n(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}Object.defineProperty(t,"__esModule",{value:!0});const i=r(5),a=r(200),o=r(58);n(r(200)),n(r(58));const s=new o.Translator;function c(e,t){return s.fromRdf(e,t)}s.registerHandler(new a.TypeHandlerString,a.TypeHandlerString.TYPES.map(i.namedNode),["string"]),s.registerHandler(new a.TypeHandlerBoolean,[a.TypeHandlerBoolean.TYPE].map(i.namedNode),["boolean"]),s.registerHandler(new a.TypeHandlerNumberDouble,a.TypeHandlerNumberDouble.TYPES.map(i.namedNode),["number"]),s.registerHandler(new a.TypeHandlerNumberInteger,a.TypeHandlerNumberInteger.TYPES.map(i.namedNode),["number"]),t.fromRdf=c,t.toRdf=function(e,t){return s.toRdf(e,t||i)},t.getTermRaw=function(e,t){return"Literal"===e.termType?c(e,t):e.value},t.getSupportedRdfDatatypes=function(){return s.getSupportedRdfDatatypes()},t.getSupportedJavaScriptPrimitives=function(){return s.getSupportedJavaScriptPrimitives()}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(58);class i{fromRdf(e,t){switch(e.value){case"true":return!0;case"false":return!1;case"1":return!0;case"0":return!1}return t&&n.Translator.incorrectRdfDataType(e),!1}toRdf(e,t){return t.literal(e?"true":"false",t.namedNode(i.TYPE))}}i.TYPE="http://www.w3.org/2001/XMLSchema#boolean",t.TypeHandlerBoolean=i},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(58);class i{fromRdf(e,t){const r=parseFloat(e.value);return t&&isNaN(r)&&n.Translator.incorrectRdfDataType(e),r}toRdf(e,t){return isNaN(e)?t.literal("NaN",t.namedNode(i.TYPES[0])):isFinite(e)?e%1==0?null:t.literal(e.toExponential(15).replace(/(\d)0*e\+?/,"$1E"),t.namedNode(i.TYPES[0])):t.literal(e>0?"INF":"-INF",t.namedNode(i.TYPES[0]))}}i.TYPES=["http://www.w3.org/2001/XMLSchema#double","http://www.w3.org/2001/XMLSchema#decimal","http://www.w3.org/2001/XMLSchema#float"],t.TypeHandlerNumberDouble=i},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(58);class i{fromRdf(e,t){const r=parseInt(e.value,10);return t&&(isNaN(r)||e.value.indexOf(".")>=0)&&n.Translator.incorrectRdfDataType(e),r}toRdf(e,t){return t.literal(String(e),e<=i.MAX_INT&&e>=i.MIN_INT?t.namedNode(i.TYPES[0]):t.namedNode(i.TYPES[1]))}}i.TYPES=["http://www.w3.org/2001/XMLSchema#integer","http://www.w3.org/2001/XMLSchema#long","http://www.w3.org/2001/XMLSchema#int","http://www.w3.org/2001/XMLSchema#byte","http://www.w3.org/2001/XMLSchema#short","http://www.w3.org/2001/XMLSchema#negativeInteger","http://www.w3.org/2001/XMLSchema#nonNegativeInteger","http://www.w3.org/2001/XMLSchema#nonPositiveInteger","http://www.w3.org/2001/XMLSchema#positiveInteger","http://www.w3.org/2001/XMLSchema#unsignedByte","http://www.w3.org/2001/XMLSchema#unsignedInt","http://www.w3.org/2001/XMLSchema#unsignedLong","http://www.w3.org/2001/XMLSchema#unsignedShort"],i.MAX_INT=2147483647,i.MIN_INT=-2147483648,t.TypeHandlerNumberInteger=i},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});class n{fromRdf(e){return e.value}toRdf(e,t){return t.literal(e)}}n.TYPES=["http://www.w3.org/2001/XMLSchema#string","http://www.w3.org/2001/XMLSchema#normalizedString","http://www.w3.org/2001/XMLSchema#anyURI","http://www.w3.org/2001/XMLSchema#base64Binary","http://www.w3.org/2001/XMLSchema#language","http://www.w3.org/2001/XMLSchema#Name","http://www.w3.org/2001/XMLSchema#NCName","http://www.w3.org/2001/XMLSchema#NMTOKEN","http://www.w3.org/2001/XMLSchema#token","http://www.w3.org/2001/XMLSchema#hexBinary","http://www.w3.org/1999/02/22-rdf-syntax-ns#langString"],t.TypeHandlerString=n},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(5),i=r(201);t.SparqlJsonParser=class{constructor(e){e=e||{},this.dataFactory=e.dataFactory||n,this.prefixVariableQuestionMark=!!e.prefixVariableQuestionMark}parseJsonResults(e){return e.results.bindings.map(e=>this.parseJsonBindings(e))}parseJsonResultsStream(e){e.on("error",e=>n.emit("error",e));const t=[];e.pipe(r(97).parse("head.vars.*")).on("data",e=>t.push(this.dataFactory.variable(e))).on("end",()=>n.emit("variables",t));const n=e.pipe(r(97).parse("results.bindings.*")).pipe(new i.SparqlJsonBindingsTransformer(this));return n}parseJsonBindings(e){const t={};for(const r in e){const n=e[r];let i=null;switch(n.type){case"bnode":i=this.dataFactory.blankNode(n.value);break;case"literal":i=n["xml:lang"]?this.dataFactory.literal(n.value,n["xml:lang"]):n.datatype?this.dataFactory.literal(n.value,this.dataFactory.namedNode(n.datatype)):this.dataFactory.literal(n.value);break;case"typed-literal":i=this.dataFactory.literal(n.value,this.dataFactory.namedNode(n.datatype));break;default:i=this.dataFactory.namedNode(n.value)}t[this.prefixVariableQuestionMark?"?"+r:r]=i}return t}parseJsonBoolean(e){if("boolean"in e)return e.boolean;throw new Error("No valid ASK response was found.")}parseJsonBooleanStream(e){return new Promise((t,n)=>{e.on("error",n),e.pipe(r(97).parse("boolean")).on("data",t).on("end",()=>n(new Error("No valid ASK response was found.")))})}}},function(e,t,r){(function(t){var n=r(3);function i(e,r,i){e=e||function(e){this.queue(e)},r=r||function(){this.queue(null)};var a=!1,o=!1,s=[],c=!1,u=new n;function l(){for(;s.length&&!u.paused;){var e=s.shift();if(null===e)return u.emit("end");u.emit("data",e)}}function f(){u.writable=!1,r.call(u),!u.readable&&u.autoDestroy&&u.destroy()}return u.readable=u.writable=!0,u.paused=!1,u.autoDestroy=!(i&&!1===i.autoDestroy),u.write=function(t){return e.call(this,t),!u.paused},u.queue=u.push=function(e){return c?u:(null===e&&(c=!0),s.push(e),l(),u)},u.on("end",function(){u.readable=!1,!u.writable&&u.autoDestroy&&t.nextTick(function(){u.destroy()})}),u.end=function(e){if(!a)return a=!0,arguments.length&&u.write(e),f(),u},u.destroy=function(){if(!o)return o=!0,a=!0,s.length=0,u.writable=u.readable=!1,u.emit("close"),u},u.pause=function(){if(!u.paused)return u.paused=!0,u},u.resume=function(){return u.paused&&(u.paused=!1,u.emit("resume")),l(),u.paused||u.emit("drain"),u},u}e.exports=i,i.through=i}).call(this,r(13))},function(e,t,r){var n=r(475);e.exports=function(e,t,r){"function"==typeof t&&(r=t,t=null),r=r||function(){};var i="";return new n(function(n,a){e.on("data",function(e){i+="string"==typeof t?e.toString(t):e.toString()}),e.on("end",function(){n(i),r(null,i)}),e.on("error",function(e){a(e),r(e)})})}},function(e,t,r){(function(t){!function(){var r;r="object"==typeof window&&window?window:t,e.exports?e.exports=r.Promise?r.Promise:o:r.Promise||(r.Promise=o);var n=r.setImmediate||function(e){setTimeout(e,1)};function i(e,t){return function(){e.apply(t,arguments)}}var a=Array.isArray||function(e){return"[object Array]"===Object.prototype.toString.call(e)};function o(e){if("object"!=typeof this)throw new TypeError("Promises must be constructed via new");if("function"!=typeof e)throw new TypeError("not a function");this._state=null,this._value=null,this._deferreds=[],d(e,i(c,this),i(u,this))}function s(e){var t=this;null!==this._state?n(function(){var r=t._state?e.onFulfilled:e.onRejected;if(null!==r){var n;try{n=r(t._value)}catch(t){return void e.reject(t)}e.resolve(n)}else(t._state?e.resolve:e.reject)(t._value)}):this._deferreds.push(e)}function c(e){try{if(e===this)throw new TypeError("A promise cannot be resolved with itself.");if(e&&("object"==typeof e||"function"==typeof e)){var t=e.then;if("function"==typeof t)return void d(i(t,e),i(c,this),i(u,this))}this._state=!0,this._value=e,l.call(this)}catch(e){u.call(this,e)}}function u(e){this._state=!1,this._value=e,l.call(this)}function l(){for(var e=0,t=this._deferreds.length;e<t;e++)s.call(this,this._deferreds[e]);this._deferreds=null}function f(e,t,r,n){this.onFulfilled="function"==typeof e?e:null,this.onRejected="function"==typeof t?t:null,this.resolve=r,this.reject=n}function d(e,t,r){var n=!1;try{e(function(e){n||(n=!0,t(e))},function(e){n||(n=!0,r(e))})}catch(e){if(n)return;n=!0,r(e)}}o.prototype.catch=function(e){return this.then(null,e)},o.prototype.then=function(e,t){var r=this;return new o(function(n,i){s.call(r,new f(e,t,n,i))})},o.all=function(){var e=Array.prototype.slice.call(1===arguments.length&&a(arguments[0])?arguments[0]:arguments);return new o(function(t,r){if(0===e.length)return t([]);var n=e.length;function i(a,o){try{if(o&&("object"==typeof o||"function"==typeof o)){var s=o.then;if("function"==typeof s)return void s.call(o,function(e){i(a,e)},r)}e[a]=o,0==--n&&t(e)}catch(e){r(e)}}for(var a=0;a<e.length;a++)i(a,e[a])})},o.resolve=function(e){return e&&"object"==typeof e&&e.constructor===o?e:new o(function(t){t(e)})},o.reject=function(e){return new o(function(t,r){r(e)})},o.race=function(e){return new o(function(t,r){for(var n=0,i=e.length;n<i;n++)e[n].then(t,r)})}}()}).call(this,r(9))},function(e,t,r){!function(t){"use strict";var r=function(){function e(e){this.options=e}return e.prototype.toString=function(){return JSON&&JSON.stringify?JSON.stringify(this.options):this.options},e}(),n=function(){function e(t){return"function"==typeof Object.freeze?function(t){if("object"!=typeof t||null===t)return t;var r,n;for(n in Object.freeze(t),t)t.hasOwnProperty(n)&&"object"==typeof(r=t[n])&&e(r);return t}(t):t}return{isArray:function(e){return"[object Array]"===Object.prototype.toString.apply(e)},isString:function(e){return"[object String]"===Object.prototype.toString.apply(e)},isNumber:function(e){return"[object Number]"===Object.prototype.toString.apply(e)},isBoolean:function(e){return"[object Boolean]"===Object.prototype.toString.apply(e)},join:function(e,t){var r,n="",i=!0;for(r=0;r<e.length;r+=1)i?i=!1:n+=t,n+=e[r];return n},map:function(e,t){for(var r=[],n=0;n<e.length;n+=1)r.push(t(e[n]));return r},filter:function(e,t){for(var r=[],n=0;n<e.length;n+=1)t(e[n])&&r.push(e[n]);return r},deepFreeze:e}}(),i=function(){function e(e){return e>="0"&&e<="9"}return{isAlpha:function(e){return e>="a"&&e<="z"||e>="A"&&e<="Z"},isDigit:e,isHexDigit:function(t){return e(t)||t>="a"&&t<="f"||t>="A"&&t<="F"}}}(),a=function(){var e={encode:function(e){return unescape(encodeURIComponent(e))},numBytes:function(e){return e<=127?1:194<=e&&e<=223?2:224<=e&&e<=239?3:240<=e&&e<=244?4:0},isValidFollowingCharCode:function(e){return 128<=e&&e<=191}};function t(e,t){return"%"===e.charAt(t)&&i.isHexDigit(e.charAt(t+1))&&i.isHexDigit(e.charAt(t+2))}function r(e,t){return parseInt(e.substr(t,2),16)}return{encodeCharacter:function(t){var r,n,i="",a=e.encode(t);for(n=0;n<a.length;n+=1)i+="%"+((r=a.charCodeAt(n))<16?"0":"")+r.toString(16).toUpperCase();return i},isPctEncoded:function(n){if(!t(n,0))return!1;var i=r(n,1),a=e.numBytes(i);if(0===a)return!1;for(var o=1;o<a;o+=1)if(!t(n,3*o)||!e.isValidFollowingCharCode(r(n,3*o+1)))return!1;return!0},pctCharAt:function(n,i){var a=n.charAt(i);if(!t(n,i))return a;var o=r(n,i+1),s=e.numBytes(o);if(0===s)return a;for(var c=1;c<s;c+=1)if(!t(n,i+3*c)||!e.isValidFollowingCharCode(r(n,i+3*c+1)))return a;return n.substr(i,3*s)}}}(),o={isVarchar:function(e){return i.isAlpha(e)||i.isDigit(e)||"_"===e||a.isPctEncoded(e)},isUnreserved:function(e){return i.isAlpha(e)||i.isDigit(e)||"-"===e||"."===e||"_"===e||"~"===e},isReserved:function(e){return":"===e||"/"===e||"?"===e||"#"===e||"["===e||"]"===e||"@"===e||"!"===e||"$"===e||"&"===e||"("===e||")"===e||"*"===e||"+"===e||","===e||";"===e||"="===e||"'"===e}},s=function(){function e(e,t){var r,n="",i="";for("number"!=typeof e&&"boolean"!=typeof e||(e=e.toString()),r=0;r<e.length;r+=i.length)i=e.charAt(r),n+=o.isUnreserved(i)||t&&o.isReserved(i)?i:a.encodeCharacter(i);return n}return{encode:e,encodePassReserved:function(t){return e(t,!0)},encodeLiteral:function(e){var t,r="",n="";for(t=0;t<e.length;t+=n.length)(n=a.pctCharAt(e,t)).length>1?r+=n:r+=o.isReserved(n)||o.isUnreserved(n)?n:a.encodeCharacter(n);return r},encodeLiteralCharacter:function(e,t){var r=a.pctCharAt(e,t);return r.length>1?r:o.isReserved(r)||o.isUnreserved(r)?r:a.encodeCharacter(r)}}}(),c=function(){var e={};function t(t){e[t]={symbol:t,separator:"?"===t?"&":""===t||"+"===t||"#"===t?",":t,named:";"===t||"&"===t||"?"===t,ifEmpty:"&"===t||"?"===t?"=":"",first:"+"===t?"":t,encode:"+"===t||"#"===t?s.encodePassReserved:s.encode,toString:function(){return this.symbol}}}return t(""),t("+"),t("#"),t("."),t("/"),t(";"),t("?"),t("&"),{valueOf:function(t){return e[t]?e[t]:"=,!@|".indexOf(t)>=0?null:e[""]}}}();function u(e){var t;if(null==e)return!1;if(n.isArray(e))return e.length>0;if("string"==typeof e||"number"==typeof e||"boolean"==typeof e)return!0;for(t in e)if(e.hasOwnProperty(t)&&u(e[t]))return!0;return!1}var l=function(){function e(e){this.literal=s.encodeLiteral(e)}return e.prototype.expand=function(){return this.literal},e.prototype.toString=e.prototype.expand,e}(),f=function(){function e(e){var t,n,s=[],u=null,l=null,f=null,h="";function p(){var t=e.substring(l,n);if(0===t.length)throw new r({expressionText:e,message:"a varname must be specified",position:n});u={varname:t,exploded:!1,maxLength:null},l=null}function y(){if(f===n)throw new r({expressionText:e,message:"after a ':' you have to specify the length",position:n});u.maxLength=parseInt(e.substring(f,n),10),f=null}for(t=function(t){var i=c.valueOf(t);if(null===i)throw new r({expressionText:e,message:"illegal use of reserved operator",position:n,operator:t});return i}(e.charAt(0)),n=t.symbol.length,l=n;n<e.length;n+=h.length){if(h=a.pctCharAt(e,n),null!==l){if("."===h){if(l===n)throw new r({expressionText:e,message:"a varname MUST NOT start with a dot",position:n});continue}if(o.isVarchar(h))continue;p()}if(null!==f){if(n===f&&"0"===h)throw new r({expressionText:e,message:"A :prefix must not start with digit 0",position:n});if(i.isDigit(h)){if(n-f>=4)throw new r({expressionText:e,message:"A :prefix must have max 4 digits",position:n});continue}y()}if(":"!==h)if("*"!==h){if(","!==h)throw new r({expressionText:e,message:"illegal character",character:h,position:n});s.push(u),u=null,l=n+1}else{if(null===u)throw new r({expressionText:e,message:"exploded without varspec",position:n});if(u.exploded)throw new r({expressionText:e,message:"exploded twice",position:n});if(u.maxLength)throw new r({expressionText:e,message:"an explode (*) MUST NOT follow to a prefix",position:n});u.exploded=!0}else{if(null!==u.maxLength)throw new r({expressionText:e,message:"only one :maxLength is allowed per varspec",position:n});if(u.exploded)throw new r({expressionText:e,message:"an exploeded varspec MUST NOT be varspeced",position:n});f=n+1}}return null!==l&&p(),null!==f&&y(),s.push(u),new d(e,t,s)}return function(t){var n,i,a=[],o=null,s=0;for(n=0;n<t.length;n+=1)if(i=t.charAt(n),null===s){if(null===o)throw new Error("reached unreachable code");if("{"===i)throw new r({templateText:t,message:"brace already opened",position:n});if("}"===i){if(o+1===n)throw new r({templateText:t,message:"empty braces",position:o});try{a.push(e(t.substring(o+1,n)))}catch(e){if(e.prototype===r.prototype)throw new r({templateText:t,message:e.options.message,position:o+e.options.position,details:e.options});throw e}o=null,s=n+1}}else{if("}"===i)throw new r({templateText:t,message:"unopened brace closed",position:n});"{"===i&&(s<n&&a.push(new l(t.substring(s,n))),s=null,o=n)}if(null!==o)throw new r({templateText:t,message:"unclosed brace",position:o});return s<t.length&&a.push(new l(t.substr(s))),new h(t,a)}}(),d=function(){function e(e){return JSON&&JSON.stringify?JSON.stringify(e):e}function t(e){if(!u(e))return!0;if(n.isString(e))return""===e;if(n.isNumber(e)||n.isBoolean(e))return!1;if(n.isArray(e))return 0===e.length;for(var t in e)if(e.hasOwnProperty(t))return!1;return!0}function r(e){var t,r=[];for(t in e)e.hasOwnProperty(t)&&r.push({name:t,value:e[t]});return r}function i(e,t,r){this.templateText=e,this.operator=t,this.varspecs=r}function a(e,t,r){var n="";if(r=r.toString(),t.named){if(n+=s.encodeLiteral(e.varname),""===r)return n+=t.ifEmpty;n+="="}return null!==e.maxLength&&(r=r.substr(0,e.maxLength)),n+=t.encode(r)}function o(e){return u(e.value)}function c(e,i,a){var c=[],l="";if(i.named){if(l+=s.encodeLiteral(e.varname),t(a))return l+=i.ifEmpty;l+="="}return n.isArray(a)?(c=a,c=n.filter(c,u),c=n.map(c,i.encode),l+=n.join(c,",")):(c=r(a),c=n.filter(c,o),c=n.map(c,function(e){return i.encode(e.name)+","+i.encode(e.value)}),l+=n.join(c,",")),l}function l(e,i,a){var c=[];return n.isArray(a)?(c=a,c=n.filter(c,u),c=n.map(c,function(r){var n=s.encodeLiteral(e.varname);return t(r)?n+=i.ifEmpty:n+="="+i.encode(r),n})):(c=r(a),c=n.filter(c,o),c=n.map(c,function(e){var r=s.encodeLiteral(e.name);return t(e.value)?r+=i.ifEmpty:r+="="+i.encode(e.value),r})),n.join(c,i.separator)}function f(e,t){var i=[],a="";return n.isArray(t)?(i=t,i=n.filter(i,u),i=n.map(i,e.encode),a+=n.join(i,e.separator)):(i=r(t),i=n.filter(i,function(e){return u(e.value)}),i=n.map(i,function(t){return e.encode(t.name)+"="+e.encode(t.value)}),a+=n.join(i,e.separator)),a}return i.prototype.toString=function(){return this.templateText},i.prototype.expand=function(r){var i,o,s,d=[],h=this.operator;for(i=0;i<this.varspecs.length;i+=1)if(null!=(s=r[(o=this.varspecs[i]).varname]))if(o.exploded&&!0,n.isArray(s),"string"==typeof s||"number"==typeof s||"boolean"==typeof s)d.push(a(o,h,s));else{if(o.maxLength&&u(s))throw new Error("Prefix modifiers are not applicable to variables that have composite values. You tried to expand "+this+" with "+e(s));o.exploded?u(s)&&(h.named?d.push(l(o,h,s)):d.push(f(h,s))):!h.named&&t(s)||d.push(c(o,h,s))}return 0===d.length?"":h.first+n.join(d,h.separator)},i}(),h=function(){function e(e,t){this.templateText=e,this.expressions=t,n.deepFreeze(this)}return e.prototype.toString=function(){return this.templateText},e.prototype.expand=function(e){var t,r="";for(t=0;t<this.expressions.length;t+=1)r+=this.expressions[t].expand(e);return r},e.parse=f,e.UriTemplateError=r,e}();!function(t){e.exports=t}(h)}()},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(93);t.ActorRdfMetadataExtractHydraCount=class extends n.ActorRdfMetadataExtract{constructor(e){super(e)}async test(e){return!0}run(e){return new Promise((t,r)=>{e.metadata.on("error",r),e.metadata.on("data",e=>{this.predicates.indexOf(e.predicate.value)>=0&&t({metadata:{totalItems:parseInt(e.object.value,10)}})}),e.metadata.on("end",()=>{t({metadata:{totalItems:1/0}})})})}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(93);t.ActorRdfMetadataExtractSparqlService=class extends n.ActorRdfMetadataExtract{constructor(e){super(e)}async test(e){return!0}async run(e){return new Promise((t,r)=>{e.metadata.on("error",r),e.metadata.on("data",r=>{"http://www.w3.org/ns/sparql-service-description#endpoint"===r.predicate.value&&r.subject.value===e.url&&t({metadata:{sparqlService:r.object.value}})}),e.metadata.on("end",()=>{t({metadata:{}})})})}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(98),i=r(202),a=r(481);t.ActorRdfResolveHypermediaNone=class extends n.ActorRdfResolveHypermedia{constructor(e){super(e,"file")}async testMetadata(e){return{filterFactor:0}}async run(e){return this.logInfo(e.context,`Identified as file source: ${e.url}`),{source:new a.RdfSourceMetadata(await i.storeStream(e.quads))}}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(0);t.ActorRdfResolveHypermedia=class extends n.Actor{constructor(e,t){super(e),this.sourceType=t}async test(e){if(e.forceSourceType&&this.sourceType!==e.forceSourceType)throw new Error(`Actor ${this.name} is not able to handle source type ${e.forceSourceType}.`);return this.testMetadata(e)}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(3);t.RdfSourceMetadata=class{constructor(e){this.source=e}match(e,t,r,i){const a=new n.Readable({objectMode:!0});return a._read=()=>{a._read=()=>{};const n=this.source.match(e,t,r,i);let o=0;n.on("error",e=>{a.emit("error",e)}),n.on("data",e=>{o++,a.push(e)}),n.on("end",()=>{a.emit("metadata",{totalItems:o}),a.push(null)})},a}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(483);t.ActorRdfResolveHypermediaLinksNext=class extends n.ActorRdfResolveHypermediaLinks{constructor(e){super(e)}async test(e){if(!e.metadata.next)throw new Error(`Actor ${this.name} requires a 'next' metadata entry.`);return!0}async run(e){return{urls:[e.metadata.next]}}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(484))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(0);t.ActorRdfResolveHypermediaLinks=class extends n.Actor{constructor(e){super(e)}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(209);t.ActorHttpInvalidateListenable=class extends n.ActorHttpInvalidate{constructor(e){super(e),this.invalidateListeners=[]}addInvalidateListener(e){this.invalidateListeners.push(e)}async test(e){return!0}async run(e){for(const t of this.invalidateListeners)t(e);return!0}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(0);t.MediatorAll=class extends n.Mediator{constructor(e){super(e)}async mediate(e){const t=[];let r;try{r=this.publish(e)}catch(e){r=[]}for(const e of r)try{await e.reply,t.push(e.actor)}catch(e){}return await Promise.all(t.map(t=>t.runObservable(e))),null}async mediateWith(e,t){return null}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(488),i=r(10);t.ActorOptimizeQueryOperationJoinBgp=class extends n.ActorOptimizeQueryOperation{constructor(e){super(e)}async test(e){return!0}async run(e){return{operation:i.Util.mapOperation(e.operation,{join:(e,t)=>"bgp"===e.left.type&&"bgp"===e.right.type?{recurse:!1,result:t.createBgp(e.left.patterns.concat(e.right.patterns))}:{recurse:!1,result:e}})}}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(489))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(0);t.ActorOptimizeQueryOperation=class extends n.Actor{constructor(e){super(e)}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(0);t.MediatorCombinePipeline=class extends n.Mediator{constructor(e){super(e)}async mediate(e){let t;try{t=this.publish(e)}catch(t){return e}await Promise.all(t.map(({reply:e})=>e));let r=e;for(const e of t.map(e=>e.actor))r=await e.runObservable(r);return r}mediateWith(e,t){throw new Error("Method not supported.")}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(213),i=r(10);t.ActorSparqlParseAlgebra=class extends n.ActorSparqlParse{constructor(e){super(e),this.prefixes=Object.freeze(this.prefixes)}async test(e){if(e.queryFormat&&"sparql"!==e.queryFormat)throw new Error("This actor can only parse SPARQL queries");return!0}async run(e){return{operation:i.translate(e.query,{quads:!0,prefixes:this.prefixes,blankToVariable:!0,baseIRI:e.baseIRI})}}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(0);t.ActorSparqlParse=class extends n.Actor{constructor(e){super(e)}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(4),i=r(6);t.ActorQueryOperationBgpEmpty=class extends n.ActorQueryOperationTyped{constructor(e){super(e,"bgp")}async testOperation(e,t){if(0!==e.patterns.length)throw new Error("Actor "+this.name+" can only operate on empty BGPs.");return!0}async runOperation(e,t){return{bindingsStream:new i.SingletonIterator(n.Bindings({})),metadata:()=>Promise.resolve({totalItems:1}),type:"bindings",variables:[]}}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(216);t.ActorQueryOperationTypedMediated=class extends n.ActorQueryOperationTyped{constructor(e,t){super(e,t)}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(25);function i(e){return n.Map(e)}function a(e){return n.Map.isMap(e)}t.Bindings=i,t.isBindings=a,t.ensureBindings=function(e){return a(e)?e:i(e)}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(4),i=r(6),a=r(8);t.ActorQueryOperationValues=class extends n.ActorQueryOperationTyped{constructor(e){super(e,"values")}async testOperation(e,t){return!0}async runOperation(e,t){return{type:"bindings",bindingsStream:new i.ArrayIterator(e.bindings.map(n.Bindings)),metadata:()=>Promise.resolve({totalItems:e.bindings.length}),variables:e.variables.map(a.termToString)}}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(98),i=r(498);t.ActorRdfResolveHypermediaSparql=class extends n.ActorRdfResolveHypermedia{constructor(e){super(e,"sparql")}async testMetadata(e){if(!e.forceSourceType&&!e.metadata.sparqlService)throw new Error(`Actor ${this.name} could not detect a SPARQL service description.`);return{filterFactor:1}}async run(e){return this.logInfo(e.context,`Identified as sparql source: ${e.url}`),{source:new i.RdfSourceSparql(e.metadata.sparqlService||e.url,e.context,this.mediatorHttp)}}}},function(e,t,r){"use strict";(function(e){Object.defineProperty(t,"__esModule",{value:!0});const n=r(37),i=r(4),a=r(5),o=r(6),s=r(33),c=r(27),u=r(10),l=r(96);class f{constructor(e,t,r){this.url=e,this.context=t,this.mediatorHttp=r}static replaceBlankNodes(e){const t=c.getVariables(c.getTerms(e)).map(e=>e.value),r={};let n=!1;const i=c.mapTerms(e,e=>{if("BlankNode"===e.termType){let i=e.value;if(r[i])i=r[i];else{if(t.indexOf(i)>=0){let e=0;for(;t.indexOf(i+e)>=0;)++e;i+=e}r[e.value]=i,t.push(i)}return n=!0,a.variable(i)}return e});return n?i:e}static patternToBgp(e){return f.FACTORY.createBgp([f.FACTORY.createPattern(e.subject,e.predicate,e.object,e.graph)])}static patternToSelectQuery(e){const t=c.getVariables(c.getTerms(e));return u.toSparql(f.FACTORY.createProject(f.patternToBgp(e),t))}static patternToCountQuery(e){return u.toSparql(f.FACTORY.createProject(f.FACTORY.createExtend(f.FACTORY.createGroup(f.patternToBgp(e),[],[f.FACTORY.createBoundAggregate(a.variable("var0"),"count",f.FACTORY.createTermExpression(a.namedNode("*")),!1)]),a.variable("count"),f.FACTORY.createTermExpression(a.variable("var0"))),[a.variable("count")]))}static materializeOptionalTerm(e,t){return e||a.variable(t)}async fetchBindingsStream(t,r,i){const a=t+"?query="+encodeURIComponent(r),o=new Headers;o.append("Accept","application/sparql-results+json");const s={context:i,input:a,init:{headers:o}},c=await this.mediatorHttp.mediate(s),u=n.ActorHttp.toNodeReadable(c.body);return c.ok||e(()=>u.emit("error",new Error(`Invalid SPARQL endpoint (${t}) response: ${c.statusText} (${c.status})`))),u}async queryBindings(e,t,r){const n=new o.BufferedIterator({autoStart:!1,maxBufferSize:1/0});let a=!1;const s=n._read;return n._read=(o,c)=>{a?s(o,c):(a=!0,this.fetchBindingsStream(e,t,r).then(e=>{const t=new l.SparqlJsonParser({prefixVariableQuestionMark:!0}).parseJsonResultsStream(e);e.on("error",e=>t.emit("error",e)),t.on("error",e=>n.emit("error",e)),t.on("data",e=>n._push(i.Bindings(e))),t.on("end",()=>{n.close()}),s(o,c)}))},n}match(e,t,r,n){if(e instanceof RegExp||t instanceof RegExp||r instanceof RegExp||n instanceof RegExp)throw new Error("RdfSourceSparql does not support matching by regular expressions.");const i=f.replaceBlankNodes(f.FACTORY.createPattern(f.materializeOptionalTerm(e,"s"),f.materializeOptionalTerm(t,"p"),f.materializeOptionalTerm(r,"o"),f.materializeOptionalTerm(n,"g"))),a=f.patternToCountQuery(i),o=f.patternToSelectQuery(i);this.queryBindings(this.url,a,this.context).then(e=>new Promise(t=>{e.on("data",e=>{const r=e.get("?count");if(r){const e=parseInt(r.value,10);return isNaN(e)?t({totalItems:1/0}):t({totalItems:e})}return t({totalItems:1/0})}),e.on("error",()=>t({totalItems:1/0})),e.on("end",()=>t({totalItems:1/0}))})).then(e=>u.emit("metadata",e));const u=new s.PromiseProxyIterator(async()=>(await this.queryBindings(this.url,o,this.context)).map(e=>c.mapTerms(i,t=>{if("Variable"===t.termType){const r=e.get("?"+t.value);return r||u.emit("error",new Error(`The endpoint ${this.url} failed to provide a binding for ${t.value}.`)),r}return t})));return u}}f.FACTORY=new u.Factory,t.RdfSourceSparql=f}).call(this,r(15).setImmediate)},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(6);t.PromiseProxyIterator=class extends n.TransformIterator{constructor(e,t){super(t||{autoStart:!1}),this.sourceGetter=e}_read(e,t){this.source?super._read(e,t):this.sourceGetter().then(r=>{this.source=r,super._read(e,t)}).catch(e=>this.emit("error",e))}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(5);function i(e,t,r,n,i){return(!t||"Variable"===t.termType||e.subject.equals(t))&&(!r||"Variable"===r.termType||e.predicate.equals(r))&&(!n||"Variable"===n.termType||e.object.equals(n))&&(!i||"Variable"===i.termType||e.graph.equals(i))}t.QUAD_TERM_NAMES=["subject","predicate","object","graph"],t.TRIPLE_TERM_NAMES=["subject","predicate","object"],t.getTerms=function(e,t){return t&&"DefaultGraph"===e.graph.termType?[e.subject,e.predicate,e.object]:[e.subject,e.predicate,e.object,e.graph]},t.getNamedTerms=function(e){return[{key:"subject",value:e.subject},{key:"predicate",value:e.predicate},{key:"object",value:e.object},{key:"graph",value:e.graph}]},t.collectNamedTerms=function(e,t,r){const i={};return e.forEach(e=>i[e.key]=e.value),t&&(i.subject=i.subject||t("subject"),i.predicate=i.predicate||t("predicate"),i.object=i.object||t("object"),i.graph=i.graph||t("graph")),(r||n).quad(i.subject,i.predicate,i.object,i.graph)},t.forEachTerms=function(e,t){t(e.subject,"subject"),t(e.predicate,"predicate"),t(e.object,"object"),t(e.graph,"graph")},t.filterTerms=function(e,t){const r=[];return t(e.subject,"subject")&&r.push(e.subject),t(e.predicate,"predicate")&&r.push(e.predicate),t(e.object,"object")&&r.push(e.object),t(e.graph,"graph")&&r.push(e.graph),r},t.filterQuadTermNames=function(e,t){const r=[];return t(e.subject,"subject")&&r.push("subject"),t(e.predicate,"predicate")&&r.push("predicate"),t(e.object,"object")&&r.push("object"),t(e.graph,"graph")&&r.push("graph"),r},t.mapTerms=function(e,t,r){return(r||n).quad(t(e.subject,"subject"),t(e.predicate,"predicate"),t(e.object,"object"),t(e.graph,"graph"))},t.reduceTerms=function(e,t,r){let n=r;return n=t(n,e.subject,"subject"),n=t(n,e.predicate,"predicate"),n=t(n,e.object,"object"),t(n,e.graph,"graph")},t.everyTerms=function(e,t){return t(e.subject,"subject")&&t(e.predicate,"predicate")&&t(e.object,"object")&&t(e.graph,"graph")},t.someTerms=function(e,t){return t(e.subject,"subject")||t(e.predicate,"predicate")||t(e.object,"object")||t(e.graph,"graph")},t.matchPattern=i,t.matchPatternComplete=function(e,t){return i(e,t.subject,t.predicate,t.object,t.graph)}},function(e,t,r){"use strict";function n(e,t){return e.filter(e=>e.termType===t)}Object.defineProperty(t,"__esModule",{value:!0}),t.TERM_TYPES=["NamedNode","BlankNode","Literal","Variable","DefaultGraph"],t.uniqTerms=function(e){return r(502)(e,(e,t)=>e.equals(t))},t.getTermsOfType=n,t.getNamedNodes=function(e){return n(e,"NamedNode")},t.getBlankNodes=function(e){return n(e,"BlankNode")},t.getLiterals=function(e){return n(e,"Literal")},t.getVariables=function(e){return n(e,"Variable")},t.getDefaultGraphs=function(e){return n(e,"DefaultGraph")}},function(e,t,r){(function(t){var r=200,n="__lodash_hash_undefined__",i="[object Function]",a="[object GeneratorFunction]",o=/^\[object .+?Constructor\]$/,s="object"==typeof t&&t&&t.Object===Object&&t,c="object"==typeof self&&self&&self.Object===Object&&self,u=s||c||Function("return this")();function l(e,t){return!!(e?e.length:0)&&function(e,t,r){if(t!=t)return function(e,t,r,n){var i=e.length,a=r+(n?1:-1);for(;n?a--:++a<i;)if(t(e[a],a,e))return a;return-1}(e,d,r);var n=r-1,i=e.length;for(;++n<i;)if(e[n]===t)return n;return-1}(e,t,0)>-1}function f(e,t,r){for(var n=-1,i=e?e.length:0;++n<i;)if(r(t,e[n]))return!0;return!1}function d(e){return e!=e}function h(e,t){return e.has(t)}function p(e){var t=-1,r=Array(e.size);return e.forEach(function(e){r[++t]=e}),r}var y,m=Array.prototype,g=Function.prototype,b=Object.prototype,v=u["__core-js_shared__"],_=(y=/[^.]+$/.exec(v&&v.keys&&v.keys.IE_PROTO||""))?"Symbol(src)_1."+y:"",w=g.toString,S=b.hasOwnProperty,E=b.toString,x=RegExp("^"+w.call(S).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),T=m.splice,O=L(u,"Map"),A=L(u,"Set"),I=L(Object,"create");function N(e){var t=-1,r=e?e.length:0;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}function R(e){var t=-1,r=e?e.length:0;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}function k(e){var t=-1,r=e?e.length:0;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}function P(e){var t=-1,r=e?e.length:0;for(this.__data__=new k;++t<r;)this.add(e[t])}function j(e,t){for(var r,n,i=e.length;i--;)if((r=e[i][0])===(n=t)||r!=r&&n!=n)return i;return-1}function D(e){return!(!q(e)||(t=e,_&&_ in t))&&(function(e){var t=q(e)?E.call(e):"";return t==i||t==a}(e)||function(e){var t=!1;if(null!=e&&"function"!=typeof e.toString)try{t=!!(e+"")}catch(e){}return t}(e)?x:o).test(function(e){if(null!=e){try{return w.call(e)}catch(e){}try{return e+""}catch(e){}}return""}(e));var t}N.prototype.clear=function(){this.__data__=I?I(null):{}},N.prototype.delete=function(e){return this.has(e)&&delete this.__data__[e]},N.prototype.get=function(e){var t=this.__data__;if(I){var r=t[e];return r===n?void 0:r}return S.call(t,e)?t[e]:void 0},N.prototype.has=function(e){var t=this.__data__;return I?void 0!==t[e]:S.call(t,e)},N.prototype.set=function(e,t){return this.__data__[e]=I&&void 0===t?n:t,this},R.prototype.clear=function(){this.__data__=[]},R.prototype.delete=function(e){var t=this.__data__,r=j(t,e);return!(r<0)&&(r==t.length-1?t.pop():T.call(t,r,1),!0)},R.prototype.get=function(e){var t=this.__data__,r=j(t,e);return r<0?void 0:t[r][1]},R.prototype.has=function(e){return j(this.__data__,e)>-1},R.prototype.set=function(e,t){var r=this.__data__,n=j(r,e);return n<0?r.push([e,t]):r[n][1]=t,this},k.prototype.clear=function(){this.__data__={hash:new N,map:new(O||R),string:new N}},k.prototype.delete=function(e){return M(this,e).delete(e)},k.prototype.get=function(e){return M(this,e).get(e)},k.prototype.has=function(e){return M(this,e).has(e)},k.prototype.set=function(e,t){return M(this,e).set(e,t),this},P.prototype.add=P.prototype.push=function(e){return this.__data__.set(e,n),this},P.prototype.has=function(e){return this.__data__.has(e)};var C=A&&1/p(new A([,-0]))[1]==1/0?function(e){return new A(e)}:function(){};function M(e,t){var r,n,i=e.__data__;return("string"==(n=typeof(r=t))||"number"==n||"symbol"==n||"boolean"==n?"__proto__"!==r:null===r)?i["string"==typeof t?"string":"hash"]:i.map}function L(e,t){var r=function(e,t){return null==e?void 0:e[t]}(e,t);return D(r)?r:void 0}function q(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}e.exports=function(e,t){return e&&e.length?function(e,t,n){var i=-1,a=l,o=e.length,s=!0,c=[],u=c;if(n)s=!1,a=f;else if(o>=r){var d=t?null:C(e);if(d)return p(d);s=!1,a=h,u=new P}else u=t?[]:c;e:for(;++i<o;){var y=e[i],m=t?t(y):y;if(y=n||0!==y?y:0,s&&m==m){for(var g=u.length;g--;)if(u[g]===m)continue e;t&&u.push(m),c.push(y)}else a(u,m,n)||(u!==c&&u.push(m),c.push(y))}return c}(e,void 0,t):[]}}).call(this,r(9))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(4),i=r(26),a=r(504),o=r(6),s=r(507),c=r(8),u=r(10);class l extends n.ActorQueryOperation{constructor(e){super(e),this.endpointFetcher=new s.SparqlEndpointFetcher({fetch:(e,t)=>this.mediatorHttp.mediate({input:e,init:t,context:this.lastContext}),prefixVariableQuestionMark:!0})}static patternToSelectQuery(e){if("project"===e.type)return e;const t=u.Util.inScopeVariables(e);return l.FACTORY.createProject(e,t)}async test(e){if(!e.operation)throw new Error("Missing field 'operation' in the query operation action: "+r(66).inspect(e));const t=await a.DataSourceUtils.getSingleSource(e.context);if(t&&"sparql"===i.getDataSourceType(t))return{httpRequests:1};throw new Error(this.name+" requires a single source with a 'sparql' endpoint to be present in the context.")}async run(e){const t=i.getDataSourceValue(await a.DataSourceUtils.getSingleSource(e.context)),r=l.patternToSelectQuery(e.operation),s=u.toSparql(r),f=new o.BufferedIterator({autoStart:!1,maxBufferSize:1/0});return this.lastContext=e.context,this.endpointFetcher.fetchBindings(t,s).then(e=>{let t=0;e.on("error",e=>f.emit("error",e)),e.on("data",e=>{t++,f._push(n.Bindings(e))}),e.on("end",()=>{f.emit("metadata",{totalItems:t}),f.close()})}),{type:"bindings",metadata:l.cachifyMetadata(()=>new Promise((e,t)=>{f._fillBuffer(),f.on("error",t),f.on("end",()=>t(new Error("No metadata was found"))),f.on("metadata",e)})),bindingsStream:f,variables:r.variables.map(c.termToString)}}}l.FACTORY=new u.Factory,t.ActorQueryOperationSparqlEndpoint=l},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(505))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(26);t.DataSourceUtils=class{static async getSingleSource(e){if(e&&e.has(n.KEY_CONTEXT_SOURCE))return e.get(n.KEY_CONTEXT_SOURCE);if(e&&e.has(n.KEY_CONTEXT_SOURCES)){const t=e.get(n.KEY_CONTEXT_SOURCES);if(t.isEnded()){const e=await r(506)(t.iterator());if(1===e.length)return e[0]}}return null}static async getSingleSourceType(e){const t=await this.getSingleSource(e);return t?n.getDataSourceType(t):null}static async singleSourceHasType(e,t){const r=await this.getSingleSourceType(e);return!!r&&r===t}}},function(e,t){e.exports=function(e){return new Promise(function(t,r){var n=[];e.on("data",function(e){n.push(e)}),e.on("error",r),e.on("end",function(){t(n)})})}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(508))},function(e,t,r){"use strict";(function(e){var n=this&&this.__awaiter||function(e,t,r,n){return new(r||(r=Promise))(function(i,a){function o(e){try{c(n.next(e))}catch(e){a(e)}}function s(e){try{c(n.throw(e))}catch(e){a(e)}}function c(e){e.done?i(e.value):new r(function(t){t(e.value)}).then(o,s)}c((n=n.apply(e,t||[])).next())})};Object.defineProperty(t,"__esModule",{value:!0}),r(48);const i=r(95),a=r(96),o=r(509),s=r(68);class c{constructor(e){e=e||{},this.fetchCb=e.fetch||fetch,this.sparqlJsonParser=new a.SparqlJsonParser(e),this.sparqlXmlParser=new o.SparqlXmlParser(e),this.sparqlParsers={[c.CONTENTTYPE_SPARQL_JSON]:{parseBooleanStream:e=>this.sparqlJsonParser.parseJsonBooleanStream(e),parseResultsStream:e=>this.sparqlJsonParser.parseJsonResultsStream(e)},[c.CONTENTTYPE_SPARQL_XML]:{parseBooleanStream:e=>this.sparqlXmlParser.parseXmlBooleanStream(e),parseResultsStream:e=>this.sparqlXmlParser.parseXmlResultsStream(e)}}}getQueryType(e){const t=(new i.Parser).parse(e);return"query"===t.type?"DESCRIBE"===t.queryType?"CONSTRUCT":t.queryType:"UNKNOWN"}fetchBindings(e,t){return n(this,void 0,void 0,function*(){const[r,n]=yield this.fetchRawStream(e,t,c.CONTENTTYPE_SPARQL),i=this.sparqlParsers[r];if(!i)throw new Error("Unknown SPARQL results content type: "+r);return i.parseResultsStream(n)})}fetchAsk(e,t){return n(this,void 0,void 0,function*(){const[r,n]=yield this.fetchRawStream(e,t,c.CONTENTTYPE_SPARQL),i=this.sparqlParsers[r];if(!i)throw new Error("Unknown SPARQL results content type: "+r);return i.parseBooleanStream(n)})}fetchTriples(e,t){return n(this,void 0,void 0,function*(){return(yield this.fetchRawStream(e,t,c.CONTENTTYPE_TURTLE))[1].pipe(new s.StreamParser({format:c.CONTENTTYPE_TURTLE}))})}fetchRawStream(t,i,a){return n(this,void 0,void 0,function*(){const n=t+"?query="+encodeURIComponent(i),o=new Headers;o.append("Accept",a);const s=yield this.fetchCb(n,{headers:o}),c=r(146)(s.body)?s.body:r(140).toNodeReadable(s.body);let u=s.headers.get("Content-Type")||"";return u.indexOf(";")>0&&(u=u.substr(0,u.indexOf(";"))),s.ok||e(()=>c.emit("error",new Error("Invalid SPARQL endpoint ("+t+") response: "+s.statusText))),[u,c]})}}c.CONTENTTYPE_SPARQL_JSON="application/sparql-results+json",c.CONTENTTYPE_SPARQL_XML="application/sparql-results+xml",c.CONTENTTYPE_SPARQL=`${c.CONTENTTYPE_SPARQL_JSON};q=1.0,${c.CONTENTTYPE_SPARQL_XML};q=0.7`,c.CONTENTTYPE_TURTLE="text/turtle",t.SparqlEndpointFetcher=c}).call(this,r(15).setImmediate)},function(e,t,r){"use strict";function n(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}Object.defineProperty(t,"__esModule",{value:!0}),n(r(510)),n(r(220))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(5),i=r(220),a=r(511);t.SparqlXmlParser=class{constructor(e){e=e||{},this.dataFactory=e.dataFactory||n,this.prefixVariableQuestionMark=!!e.prefixVariableQuestionMark}parseXmlResultsStream(e){const t=[];e.pipe(a({strict:!0,tag:"variable"})).on("data",e=>t.push(this.dataFactory.variable(e.attribs.name))).on("error",()=>{}).on("finish",()=>r.emit("variables",t));const r=e.pipe(a({strict:!0,tag:"result"})).on("error",e=>r.emit("error",e)).pipe(new i.SparqlXmlBindingsTransformer(this));return e.on("error",e=>r.emit("error",e)),r}parseXmlBindings(e){const t={};if(e.children){const r=Array.isArray(e.children.binding)?e.children.binding:[e.children.binding];for(const e of r)if(e.attribs&&e.children){const r=e.attribs.name;let n=null;if(e.children.bnode)n=this.dataFactory.blankNode(e.children.bnode.value);else if(e.children.literal){const t=e.children.literal.value||"",r=e.children.literal.attribs;n=r&&r["xml:lang"]?this.dataFactory.literal(t,r["xml:lang"]):r&&r.datatype?this.dataFactory.literal(t,this.dataFactory.namedNode(r.datatype)):this.dataFactory.literal(t)}else n=this.dataFactory.namedNode(e.children.uri.value);t[this.prefixVariableQuestionMark?"?"+r:r]=n}}return t}parseXmlBooleanStream(e){return new Promise((t,r)=>{e.on("error",r),e.pipe(a({strict:!0,tag:"boolean"})).on("error",r).on("data",e=>t("true"===e.value)).on("end",()=>r(new Error("No valid ASK response was found.")))})}}},function(e,t,r){e.exports=r(512)},function(e,t,r){var n=r(3).Transform,i=r(66),a=r(161),o=r(513),s=r(514)("sax-stream");function c(e){if(!(this instanceof c))return new c(e);n.call(this,{highWaterMark:e.highWaterMark||350,objectMode:!0}),this.records=[],this.error=null,this.parser=this.createSaxParser(e)}e.exports=c,i.inherits(c,n),c.prototype.createSaxParser=function(e){var t,r=this,n=a.parser(e.strict||!1,function(e){return["trim","normalize","lowercase","xmlns","position","strictEntities","noscript"].reduce(function(t,r){return r in e&&(t[r]=e[r]),t},{position:!1})}(e)),i=function(t){return t===e.tag},c=function(e,t){r.records.push(t)};return Array.isArray(e.tag)&&(i=function(t){return-1!==e.tag.indexOf(t)},c=function(e,t){r.records.push({tag:e,record:t})}),n.onopentag=function(e){s('Open "%s"',e.name),t?t=o.addChild(t,e.name):i(e.name)&&(t={}),t&&Object.keys(e.attributes).length&&(t.attribs=e.attributes)},n.onclosetag=function(e){s('Closed "%s"',e),i(e)&&!t.parent?(s("Emitting record",t),c(e,t),t=void 0):t&&(t=t.parent)},n.ontext=function(e){t&&o.addText(t,e)},n.oncdata=function(e){t&&o.concatText(t,e)},n.onerror=function(e){r.error=e},n.onend=function(){s("onend - flushing remaining items"),r.pushAll(r.callback),r.callback=null},n},c.prototype.pushAll=function(e){if(this.error)return e(this.error),void(this.error=null);s("pushing %d",this.records.length),this.records.forEach(this.push.bind(this)),this.records.length=0,e()},c.prototype._transform=function(e,t,r){this.parser.write(e.toString()),this.pushAll(r)},c.prototype._flush=function(e){this.callback=e,this.parser.close()}},function(e,t){function r(e,t){var n;if(e&&(Array.isArray(e)&&(e=e[0]),Array.isArray(t)||(t=t.split("/")),n=t.shift(),e.children))return e=e.children[n],t.length?r(e,t):e}t.child=r,t.value=function(e,t){return(e=r(e,t))&&e.value},t.attr=function(e,t,n){return(e=r(e,t))&&e.attribs&&e.attribs[n]},t.addChild=function(e,t){var r={parent:e};return e.children=e.children||{},e.children[t]?(Array.isArray(e.children[t])||(e.children[t]=[e.children[t]]),e.children[t].push(r)):e.children[t]=r,r},t.addText=function(e,t){return e.value=t,e},t.concatText=function(e,t){return e.value=(e.value||"")+t,e}},function(e,t,r){(function(n){function i(){var e;try{e=t.storage.debug}catch(e){}return!e&&void 0!==n&&"env"in n&&(e=n.env.DEBUG),e}(t=e.exports=r(515)).log=function(){return"object"==typeof console&&console.log&&Function.prototype.apply.call(console.log,console,arguments)},t.formatArgs=function(e){var r=this.useColors;if(e[0]=(r?"%c":"")+this.namespace+(r?" %c":" ")+e[0]+(r?"%c ":" ")+"+"+t.humanize(this.diff),!r)return;var n="color: "+this.color;e.splice(1,0,n,"color: inherit");var i=0,a=0;e[0].replace(/%[a-zA-Z%]/g,function(e){"%%"!==e&&(i++,"%c"===e&&(a=i))}),e.splice(a,0,n)},t.save=function(e){try{null==e?t.storage.removeItem("debug"):t.storage.debug=e}catch(e){}},t.load=i,t.useColors=function(){if("undefined"!=typeof window&&window.process&&"renderer"===window.process.type)return!0;return"undefined"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"undefined"!=typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)},t.storage="undefined"!=typeof chrome&&void 0!==chrome.storage?chrome.storage.local:function(){try{return window.localStorage}catch(e){}}(),t.colors=["lightseagreen","forestgreen","goldenrod","dodgerblue","darkorchid","crimson"],t.formatters.j=function(e){try{return JSON.stringify(e)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}},t.enable(i())}).call(this,r(13))},function(e,t,r){var n;function i(e){function r(){if(r.enabled){var e=r,i=+new Date,a=i-(n||i);e.diff=a,e.prev=n,e.curr=i,n=i;for(var o=new Array(arguments.length),s=0;s<o.length;s++)o[s]=arguments[s];o[0]=t.coerce(o[0]),"string"!=typeof o[0]&&o.unshift("%O");var c=0;o[0]=o[0].replace(/%([a-zA-Z%])/g,function(r,n){if("%%"===r)return r;c++;var i=t.formatters[n];if("function"==typeof i){var a=o[c];r=i.call(e,a),o.splice(c,1),c--}return r}),t.formatArgs.call(e,o),(r.log||t.log||console.log.bind(console)).apply(e,o)}}return r.namespace=e,r.enabled=t.enabled(e),r.useColors=t.useColors(),r.color=function(e){var r,n=0;for(r in e)n=(n<<5)-n+e.charCodeAt(r),n|=0;return t.colors[Math.abs(n)%t.colors.length]}(e),"function"==typeof t.init&&t.init(r),r}(t=e.exports=i.debug=i.default=i).coerce=function(e){return e instanceof Error?e.stack||e.message:e},t.disable=function(){t.enable("")},t.enable=function(e){t.save(e),t.names=[],t.skips=[];for(var r=("string"==typeof e?e:"").split(/[\s,]+/),n=r.length,i=0;i<n;i++)r[i]&&("-"===(e=r[i].replace(/\*/g,".*?"))[0]?t.skips.push(new RegExp("^"+e.substr(1)+"$")):t.names.push(new RegExp("^"+e+"$")))},t.enabled=function(e){var r,n;for(r=0,n=t.skips.length;r<n;r++)if(t.skips[r].test(e))return!1;for(r=0,n=t.names.length;r<n;r++)if(t.names[r].test(e))return!0;return!1},t.humanize=r(516),t.names=[],t.skips=[],t.formatters={}},function(e,t){var r=1e3,n=60*r,i=60*n,a=24*i,o=365.25*a;function s(e,t,r){if(!(e<t))return e<1.5*t?Math.floor(e/t)+" "+r:Math.ceil(e/t)+" "+r+"s"}e.exports=function(e,t){t=t||{};var c,u=typeof e;if("string"===u&&e.length>0)return function(e){if((e=String(e)).length>100)return;var t=/^((?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|years?|yrs?|y)?$/i.exec(e);if(!t)return;var s=parseFloat(t[1]);switch((t[2]||"ms").toLowerCase()){case"years":case"year":case"yrs":case"yr":case"y":return s*o;case"days":case"day":case"d":return s*a;case"hours":case"hour":case"hrs":case"hr":case"h":return s*i;case"minutes":case"minute":case"mins":case"min":case"m":return s*n;case"seconds":case"second":case"secs":case"sec":case"s":return s*r;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return s;default:return}}(e);if("number"===u&&!1===isNaN(e))return t.long?s(c=e,a,"day")||s(c,i,"hour")||s(c,n,"minute")||s(c,r,"second")||c+" ms":function(e){if(e>=a)return Math.round(e/a)+"d";if(e>=i)return Math.round(e/i)+"h";if(e>=n)return Math.round(e/n)+"m";if(e>=r)return Math.round(e/r)+"s";return e+"ms"}(e);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(e))}},function(e,t,r){"use strict";function n(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}Object.defineProperty(t,"__esModule",{value:!0}),n(r(223)),n(r(518))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(223);t.ActorRdfDereferenceMediaMappings=class extends n.ActorRdfDereference{constructor(e){super(e)}getMediaTypeFromExtension(e){const t=e.lastIndexOf(".");if(t>=0){const r=e.substr(t);return this.mediaMappings[r.substring(1)]||""}return""}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(222);t.ActorRdfDereferenceHttpParse=class extends n.ActorRdfDereferenceHttpParseBase{constructor(e){super(e)}getMaxAcceptHeaderLength(){return this.maxAcceptHeaderLengthBrowser}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(185),i=r(521);t.ActorRdfParseHtmlScript=class extends n.ActorRdfParseHtml{constructor(e){super(e)}async test(e){return!0}async run(e){const t=(await this.mediatorRdfParseMediatypes.mediate({context:e.context,mediaTypes:!0})).mediaTypes;return{htmlParseListener:new i.HtmlScriptListener(this.mediatorRdfParseHandle,e.emit,e.error,e.end,t,e.context,e.baseIRI)}}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(3);t.HtmlScriptListener=class{constructor(e,t,r,n,i,a,o){this.handleMediaType=null,this.textChunks=null,this.endBarrier=1,this.mediatorRdfParseHandle=e,this.cbQuad=t,this.cbError=r,this.cbEnd=n,this.supportedTypes=i,this.context=a,this.baseIRI=o}onEnd(){0==--this.endBarrier&&this.cbEnd()}onTagClose(){if(this.handleMediaType){const e=new n.Readable({objectMode:!0});e._read=()=>{};const t=this.textChunks,r={context:this.context,handle:{baseIRI:this.baseIRI,input:e},handleMediaType:this.handleMediaType};this.mediatorRdfParseHandle.mediate(r).then(({handle:r})=>{r.quads.on("error",this.cbError).on("data",this.cbQuad).on("end",()=>this.onEnd());for(const r of t)e.push(r);e.push(null)}),this.handleMediaType=null,this.textChunks=null}}onTagOpen(e,t){"script"===e&&this.supportedTypes[t.type]?(this.handleMediaType=t.type,this.textChunks=[],this.endBarrier++):this.handleMediaType=null}onText(e){this.handleMediaType&&this.textChunks.push(e)}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(26),i=r(523);t.ActorRdfResolveQuadPatternFederated=class extends n.ActorRdfResolveQuadPatternSource{constructor(e){super(e),this.emptyPatterns=new Map}async test(e){if(!this.getContextSources(e.context))throw new Error("Actor "+this.name+" can only resolve quad pattern queries against a sources array.");return!0}async getSource(e){return new i.FederatedQuadSource(this.mediatorResolveQuadPattern,e,this.emptyPatterns,this.skipEmptyPatterns)}}},function(e,t,r){"use strict";(function(e){Object.defineProperty(t,"__esModule",{value:!0});const n=r(26),i=r(5),a=r(6),o=r(33),s=r(76),c=r(10);class u{constructor(e,t,r,i){this.mediatorResolveQuadPattern=e,this.sources=t.get(n.KEY_CONTEXT_SOURCES),this.contextDefault=t.delete(n.KEY_CONTEXT_SOURCES),this.emptyPatterns=r,this.skipEmptyPatterns=i,this.algebraFactory=new c.Factory,this.skipEmptyPatterns&&this.sources.iterator().on("data",e=>{this.emptyPatterns.has(e)||this.emptyPatterns.set(e,[])})}static isTermBound(e){return"Variable"!==e.termType}static isSubPatternOf(e,t){return(!u.isTermBound(t.subject)||t.subject.equals(e.subject))&&(!u.isTermBound(t.predicate)||t.predicate.equals(e.predicate))&&(!u.isTermBound(t.object)||t.object.equals(e.object))&&(!u.isTermBound(t.graph)||t.graph.equals(e.graph))}static nullToVariable(e,t){return e||i.variable("v"+t)}isSourceEmpty(e,t){if(!this.skipEmptyPatterns)return!1;const r=this.emptyPatterns.get(e);if(r)for(const e of r)if(u.isSubPatternOf(t,e))return!0;return!1}matchLazy(t,r,i,c){if(t instanceof RegExp||r instanceof RegExp||i instanceof RegExp||c instanceof RegExp)throw new Error("FederatedQuadSource does not support matching by regular expressions.");const l={totalItems:0};let f=1,d=0;const h=(e,t,r,n)=>{this.skipEmptyPatterns&&!e&&(this.isSourceEmpty(t,r)||this.emptyPatterns.get(t).push(r)),f||(n&&1===d?y.emit("metadata",n):y.emit("metadata",l))},p=this.sources.iterator(),y=new s.RoundRobinUnionIterator(p.map(e=>{f++,d++;const s=this.algebraFactory.createPattern(u.nullToVariable(t,"s"),u.nullToVariable(r,"p"),u.nullToVariable(i,"o"),u.nullToVariable(c,"g")),p=this.contextDefault.set(n.KEY_CONTEXT_SOURCE,{type:n.getDataSourceType(e),value:n.getDataSourceValue(e)});return new o.PromiseProxyIterator(async()=>{let t;return(t=this.isSourceEmpty(e,s)?{data:new a.EmptyIterator,metadata:()=>Promise.resolve({totalItems:0})}:await this.mediatorResolveQuadPattern.mediate({pattern:s,context:p})).metadata?t.metadata().then(t=>{!t.totalItems&&0!==t.totalItems||!isFinite(t.totalItems)?(l.totalItems=1/0,f=0,h(1/0,e,s,t)):(l.totalItems+=t.totalItems,f--,h(t.totalItems,e,s,t))}):(l.totalItems=1/0,f=0,h(1/0,e,s)),t.data})}));return y.on("newListener",t=>{"metadata"===t&&e(()=>y._fillBuffer())}),p.on("end",()=>{--f||y.emit("metadata",l)}),y}match(e,t,r,n){return this.matchLazy(e,t,r,n)}}t.FederatedQuadSource=u}).call(this,r(15).setImmediate)},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(6);t.RoundRobinUnionIterator=class extends n.BufferedIterator{constructor(e,t){super(t||{autoStart:!1}),this.sourcedEnded=!1,this.currentSource=0,this.listenersAttached=!1,this.sources=[],this.sourceIterator=Array.isArray(e)?new n.ArrayIterator(e):e,this.sourceIterator.on("error",e=>this.emit("error",e))}_read(e,t){if(!this.sourcedEnded){let e;for(this.listenersAttached||(this.listenersAttached=!0,this.sourceIterator.on("readable",()=>this._fillBuffer()));e=this.sourceIterator.read();)e.on("error",e=>this.emit("error",e)),e.on("readable",()=>this._fillBuffer()),e.on("end",()=>this._fillBuffer()),this.sources.push(e);this.sourceIterator.ended&&(this.sourcedEnded=!0)}let r=null,n=this.sources.length;for(;this.sources.length&&null===r&&n--;){const e=this.sources[this.currentSource];r=e.read(),e.ended?this.sources.splice(this.currentSource,1):this.currentSource++,this.currentSource=this.sources.length?this.currentSource%this.sources.length:0}null!==r&&this._push(r),!this.sources.length&&this.sourcedEnded&&this.close(),t()}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(4),i=r(33),a=r(8),o=r(27);class s extends n.ActorQueryOperationTyped{constructor(e){super(e,"pattern")}static isTermVariable(e){return"Variable"===e.termType}getVariables(e){return o.uniqTerms(o.getTerms(e).filter(s.isTermVariable)).map(a.termToString)}async testOperation(e,t){return!0}async runOperation(e,t){const r=await this.mediatorResolveQuadPattern.mediate({pattern:e,context:t}),c=this.getVariables(e),u=o.reduceTerms(e,(e,t,r)=>(s.isTermVariable(t)&&(e[r]=a.termToString(t)),e),{}),l=(e,t,r)=>{const n=u[r];return n&&(e[n]=t),e};return{type:"bindings",bindingsStream:new i.PromiseProxyIterator(async()=>r.data.map(e=>n.Bindings(o.reduceTerms(e,l,{})),{autoStart:!0,maxBufferSize:128})),variables:c,metadata:r.metadata}}}t.ActorQueryOperationQuadpattern=s},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(98),i=r(527);t.ActorRdfResolveHypermediaQpf=class extends n.ActorRdfResolveHypermedia{constructor(e){super(e,"qpf")}async testMetadata(e){const t=this.createSource(e.metadata,e.context,null).searchForm;if(!t)throw new Error(`Actor ${this.name} could not detect a TPF/QPF search form.`);if(e.handledDatasets&&e.handledDatasets[t.dataset])throw new Error(`Actor ${this.name} can only be applied for the first page of a QPF dataset.`);return{filterFactor:1}}async run(e){this.logInfo(e.context,`Identified as qpf source: ${e.url}`);const t=this.createSource(e.metadata,e.context,e.quads);return{source:t,dataset:t.searchForm.dataset}}createSource(e,t,r){return new i.RdfSourceQpf(this.mediatorMetadata,this.mediatorMetadataExtract,this.mediatorRdfDereference,this.subjectUri,this.predicateUri,this.objectUri,this.graphUri,e,t,r)}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(6),i=r(33),a=r(8),o=r(27);t.RdfSourceQpf=class{constructor(e,t,r,i,a,o,s,c,u,l){if(this.mediatorMetadata=e,this.mediatorMetadataExtract=t,this.mediatorRdfDereference=r,this.subjectUri=i,this.predicateUri=a,this.objectUri=o,this.graphUri=s,this.context=u,this.cachedQuads={},this.searchForm=this.getSearchForm(c),l){const e=n.AsyncIterator.wrap(l);e.setProperty("metadata",c),this.cacheQuads(e)}}getSearchForm(e){if(!e.searchForms||!e.searchForms.values)return null;const t=e.searchForms;for(const e of t.values){if(this.graphUri&&this.subjectUri in e.mappings&&this.predicateUri in e.mappings&&this.objectUri in e.mappings&&this.graphUri in e.mappings&&4===Object.keys(e.mappings).length)return e;if(this.subjectUri in e.mappings&&this.predicateUri in e.mappings&&this.objectUri in e.mappings&&3===Object.keys(e.mappings).length)return e}return null}createFragmentUri(e,t,r,n,i){const o={},s=[{uri:this.subjectUri,term:t},{uri:this.predicateUri,term:r},{uri:this.objectUri,term:n},{uri:this.graphUri,term:i}];for(const e of s)e.uri&&e.term&&(o[e.uri]=a.termToString(e.term));return e.getUri(o)}getDuplicateElementLinks(e,t,r,n){const i={};let o=!1;const s={subject:e,predicate:t,object:r,graph:n};for(const e in s)if(s[e]&&"Variable"===s[e].termType){const t=a.termToString(s[e]),r=(i[t]||(i[t]=[])).push(e);o=o||r>1}if(!o)return null;const c={};for(const e in i){const t=i[e],r=t.slice(1);r.length&&(c[t[0]]=r)}return c}match(e,t,r,a){if(e instanceof RegExp||t instanceof RegExp||r instanceof RegExp||a instanceof RegExp)throw new Error("RdfSourceQpf does not support matching by regular expressions.");const s=this.getCachedQuads(e,t,r,a);if(s)return s;const c=new i.PromiseProxyIterator(async()=>{let i=await this.createFragmentUri(this.searchForm,e,t,r,a);const s=await this.mediatorRdfDereference.mediate({context:this.context,url:i});i=s.url;const u=await this.mediatorMetadata.mediate({context:this.context,url:i,quads:s.quads,triples:s.triples});this.mediatorMetadataExtract.mediate({context:this.context,url:i,metadata:u.metadata}).then(({metadata:e})=>{c.setProperty("metadata",e),c.emit("metadata",e)});let l=n.AsyncIterator.wrap(u.data).filter(n=>o.matchPattern(n,e,t,r,a));const f=this.getDuplicateElementLinks(e,t,r,a);return f&&(l=l.filter(e=>{for(const t of o.TRIPLE_TERM_NAMES)for(const r of f[t]||[])if(!e[t].equals(e[r]))return!1;return!0})),l});return this.cacheQuads(c,e,t,r,a),this.getCachedQuads(e,t,r,a)}getPatternId(e,t,r,n){return JSON.stringify({s:a.termToString(e),p:a.termToString(t),o:a.termToString(r),g:a.termToString(n)})}cacheQuads(e,t,r,n,i){const a=this.getPatternId(t,r,n,i);this.cachedQuads[a]=e.clone()}getCachedQuads(e,t,r,n){const a=this.getPatternId(e,t,r,n);let o=this.cachedQuads[a];if(o){const e=o;return o=new i.PromiseProxyIterator(async()=>e.clone()),e.getProperty("metadata",e=>o.emit("metadata",e)),o}return null}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(26),i=r(99),a=r(229);t.ActorRdfResolveQuadPatternHypermedia=class extends n.ActorRdfResolveQuadPatternSource{constructor(e){super(e),this.cache=this.cacheSize?new i({max:this.cacheSize}):null,this.cache&&this.httpInvalidator.addInvalidateListener(({url:e})=>e?this.cache.del(e):this.cache.reset())}async test(e){if(!this.hasContextSingleSource(e.context))throw new Error("Actor "+this.name+" can only resolve quad pattern queries against a single source.");return!0}getSource(e,t){const r=this.getContextSource(e),i=this.getContextSourceUrl(r);let o;return this.cacheSize&&this.cache.has(i)?o=this.cache.get(i):(o=new a.MediatedQuadSource(this.cacheSize,e,i,n.getDataSourceType(r),{mediatorMetadata:this.mediatorMetadata,mediatorMetadataExtract:this.mediatorMetadataExtract,mediatorRdfDereference:this.mediatorRdfDereference,mediatorRdfResolveHypermedia:this.mediatorRdfResolveHypermedia,mediatorRdfResolveHypermediaLinks:this.mediatorRdfResolveHypermediaLinks}),this.cacheSize&&this.cache.set(i,o)),Promise.resolve(o)}}},function(e,t,r){"use strict";function n(e){var t=this;if(t instanceof n||(t=new n),t.tail=null,t.head=null,t.length=0,e&&"function"==typeof e.forEach)e.forEach(function(e){t.push(e)});else if(arguments.length>0)for(var r=0,i=arguments.length;r<i;r++)t.push(arguments[r]);return t}function i(e,t){e.tail=new o(t,e.tail,null,e),e.head||(e.head=e.tail),e.length++}function a(e,t){e.head=new o(t,null,e.head,e),e.tail||(e.tail=e.head),e.length++}function o(e,t,r,n){if(!(this instanceof o))return new o(e,t,r,n);this.list=n,this.value=e,t?(t.next=this,this.prev=t):this.prev=null,r?(r.prev=this,this.next=r):this.next=null}e.exports=n,n.Node=o,n.create=n,n.prototype.removeNode=function(e){if(e.list!==this)throw new Error("removing node which does not belong to this list");var t=e.next,r=e.prev;t&&(t.prev=r),r&&(r.next=t),e===this.head&&(this.head=t),e===this.tail&&(this.tail=r),e.list.length--,e.next=null,e.prev=null,e.list=null},n.prototype.unshiftNode=function(e){if(e!==this.head){e.list&&e.list.removeNode(e);var t=this.head;e.list=this,e.next=t,t&&(t.prev=e),this.head=e,this.tail||(this.tail=e),this.length++}},n.prototype.pushNode=function(e){if(e!==this.tail){e.list&&e.list.removeNode(e);var t=this.tail;e.list=this,e.prev=t,t&&(t.next=e),this.tail=e,this.head||(this.head=e),this.length++}},n.prototype.push=function(){for(var e=0,t=arguments.length;e<t;e++)i(this,arguments[e]);return this.length},n.prototype.unshift=function(){for(var e=0,t=arguments.length;e<t;e++)a(this,arguments[e]);return this.length},n.prototype.pop=function(){if(this.tail){var e=this.tail.value;return this.tail=this.tail.prev,this.tail?this.tail.next=null:this.head=null,this.length--,e}},n.prototype.shift=function(){if(this.head){var e=this.head.value;return this.head=this.head.next,this.head?this.head.prev=null:this.tail=null,this.length--,e}},n.prototype.forEach=function(e,t){t=t||this;for(var r=this.head,n=0;null!==r;n++)e.call(t,r.value,n,this),r=r.next},n.prototype.forEachReverse=function(e,t){t=t||this;for(var r=this.tail,n=this.length-1;null!==r;n--)e.call(t,r.value,n,this),r=r.prev},n.prototype.get=function(e){for(var t=0,r=this.head;null!==r&&t<e;t++)r=r.next;if(t===e&&null!==r)return r.value},n.prototype.getReverse=function(e){for(var t=0,r=this.tail;null!==r&&t<e;t++)r=r.prev;if(t===e&&null!==r)return r.value},n.prototype.map=function(e,t){t=t||this;for(var r=new n,i=this.head;null!==i;)r.push(e.call(t,i.value,this)),i=i.next;return r},n.prototype.mapReverse=function(e,t){t=t||this;for(var r=new n,i=this.tail;null!==i;)r.push(e.call(t,i.value,this)),i=i.prev;return r},n.prototype.reduce=function(e,t){var r,n=this.head;if(arguments.length>1)r=t;else{if(!this.head)throw new TypeError("Reduce of empty list with no initial value");n=this.head.next,r=this.head.value}for(var i=0;null!==n;i++)r=e(r,n.value,i),n=n.next;return r},n.prototype.reduceReverse=function(e,t){var r,n=this.tail;if(arguments.length>1)r=t;else{if(!this.tail)throw new TypeError("Reduce of empty list with no initial value");n=this.tail.prev,r=this.tail.value}for(var i=this.length-1;null!==n;i--)r=e(r,n.value,i),n=n.prev;return r},n.prototype.toArray=function(){for(var e=new Array(this.length),t=0,r=this.head;null!==r;t++)e[t]=r.value,r=r.next;return e},n.prototype.toArrayReverse=function(){for(var e=new Array(this.length),t=0,r=this.tail;null!==r;t++)e[t]=r.value,r=r.prev;return e},n.prototype.slice=function(e,t){(t=t||this.length)<0&&(t+=this.length),(e=e||0)<0&&(e+=this.length);var r=new n;if(t<e||t<0)return r;e<0&&(e=0),t>this.length&&(t=this.length);for(var i=0,a=this.head;null!==a&&i<e;i++)a=a.next;for(;null!==a&&i<t;i++,a=a.next)r.push(a.value);return r},n.prototype.sliceReverse=function(e,t){(t=t||this.length)<0&&(t+=this.length),(e=e||0)<0&&(e+=this.length);var r=new n;if(t<e||t<0)return r;e<0&&(e=0),t>this.length&&(t=this.length);for(var i=this.length,a=this.tail;null!==a&&i>t;i--)a=a.prev;for(;null!==a&&i>e;i--,a=a.prev)r.push(a.value);return r},n.prototype.reverse=function(){for(var e=this.head,t=this.tail,r=e;null!==r;r=r.prev){var n=r.prev;r.prev=r.next,r.next=n}return this.head=t,this.tail=e,this};try{r(530)(n)}catch(e){}},function(e,t,r){"use strict";e.exports=function(e){e.prototype[Symbol.iterator]=function*(){for(let e=this.head;e;e=e.next)yield e.value}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(532);t.MediatedLinkedRdfSourcesAsyncRdfIterator=class extends n.LinkedRdfSourcesAsyncRdfIterator{constructor(e,t,r,n,i,a,o,s,c){super(e,n,i,a,o,s,{autoStart:!1}),this.context=t,this.forceSourceType=r,this.mediatorRdfDereference=c.mediatorRdfDereference,this.mediatorMetadata=c.mediatorMetadata,this.mediatorMetadataExtract=c.mediatorMetadataExtract,this.mediatorRdfResolveHypermedia=c.mediatorRdfResolveHypermedia,this.mediatorRdfResolveHypermediaLinks=c.mediatorRdfResolveHypermediaLinks,this.handledUrls={}}async getNextUrls(e){try{const{urls:t}=await this.mediatorRdfResolveHypermediaLinks.mediate({context:this.context,metadata:e});return t.filter(e=>!this.handledUrls[e]&&(this.handledUrls[e]=!0,!0))}catch(e){return[]}}async getNextSource(e,t){const r=this.context,n=await this.mediatorRdfDereference.mediate({context:r,url:e});e=n.url;const i=await this.mediatorMetadata.mediate({context:r,url:e,quads:n.quads,triples:n.triples}),{metadata:a}=await this.mediatorMetadataExtract.mediate({context:r,url:e,metadata:i.metadata}),{source:o,dataset:s}=await this.mediatorRdfResolveHypermedia.mediate({context:r,forceSourceType:this.forceSourceType,handledDatasets:t,metadata:a,quads:i.data,url:e});return s&&(t[s]=!0),{source:o,metadata:a,handledDatasets:t}}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(6),i=r(99);t.LinkedRdfSourcesAsyncRdfIterator=class extends n.BufferedIterator{constructor(e,t,r,n,i,a,o){super(o),this.cacheSize=e,this.subject=t,this.predicate=r,this.object=n,this.graph=i,this.sourceStates=[],this.firstUrl=a,this.started=!1,this.iterating=!1}setSourcesState(e){e?this.sourcesState=e:(this.sourcesState={sources:new i({max:this.cacheSize})},this.getNextSourceCached(this.firstUrl,{}))}_read(e,t){if(this.started)if(!this.iterating&&this.nextSource){const e=this.nextSource;this.nextSource=null,this.getNextUrls(e.metadata).then(t=>Promise.all(t.map(t=>this.getNextSourceCached(t,e.handledDatasets)))).then(e=>{if(0===e.length&&0===this.sourceStates.length)this.close();else{for(const t of e)this.sourceStates.push(t);this.startIterator(this.sourceStates[0],!1),this.sourceStates.splice(0,1)}t()}).catch(e=>this.emit("error",e))}else t();else this.started=!0,this.sourcesState||this.setSourcesState(),this.sourcesState.sources.get(this.firstUrl).then(e=>{this.startIterator(e,!0),t()}).catch(e=>this.emit("error",e))}getNextSourceCached(e,t){let r=this.sourcesState.sources.get(e);return r||(r=this.getNextSource(e,t),this.sourcesState.sources.set(e,r),r)}startIterator(e,t){this.iterating=!0;const r=e.source.match(this.subject,this.predicate,this.object,this.graph);let n=e.metadata,i=!1;r.on("metadata",e=>{i&&this.destroy(new Error("Received metadata AFTER the source iterator was ended.")),n=e}),r.on("data",e=>{this._push(e),this.readable=!0}),r.on("error",e=>this.destroy(e)),r.on("end",()=>{i=!0,t&&this.emit("metadata",n),this.nextSource={handledDatasets:Object.assign({},e.handledDatasets),metadata:n,source:null},this.iterating=!1,this.readable=!0})}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(534),i=r(4),a=r(26),o=r(0),s=r(231),c=r(8),u=r(27),l=r(10);class f extends n.ActorInit{constructor(e){super(e)}static applyInitialBindings(e,t){const r={};for(const n of Object.keys(e))if(Array.isArray(e[n])?r[n]="variables"===n?e[n].filter(e=>!t.has(c.termToString(e))):e[n].map(e=>f.applyInitialBindings(e,t)):e[n]&&f.ALGEBRA_TYPES[e[n].type]?r[n]=f.applyInitialBindings(e[n],t):r[n]=e[n],e.type===l.Algebra.types.PATTERN||e.type===l.Algebra.types.PATH)for(const n of u.QUAD_TERM_NAMES)if(e.type!==l.Algebra.types.PATH||"predicate"!==n){const i=e[n];if("Variable"===i.termType){const e=c.termToString(i),a=t.get(e);a&&(r[n]=a)}}return r}async test(e){return!0}async query(e,r){r=r||{};for(const e in r)if(this.contextKeyShortcuts[e]){const t=r[e];r[this.contextKeyShortcuts[e]]=t,delete r[e]}r[o.KEY_CONTEXT_LOG]||(r[o.KEY_CONTEXT_LOG]=this.logger),r[i.KEY_CONTEXT_QUERY_TIMESTAMP]||(r[i.KEY_CONTEXT_QUERY_TIMESTAMP]=new Date),Array.isArray(r[a.KEY_CONTEXT_SOURCES])&&(r[a.KEY_CONTEXT_SOURCES].map(e=>{"string"==typeof e||"auto"!==e.type&&"hypermedia"!==e.type||delete e.type}),r[a.KEY_CONTEXT_SOURCES]=s.AsyncReiterableArray.fromFixedData(r[a.KEY_CONTEXT_SOURCES]));let n,c="sparql";(r=o.ActionContext(r))&&r.has(t.KEY_CONTEXT_QUERYFORMAT)&&(c=r.get(t.KEY_CONTEXT_QUERYFORMAT),r=r.delete(t.KEY_CONTEXT_QUERYFORMAT),"graphql"!==c||r.has(t.KEY_CONTEXT_GRAPHQL_SINGULARIZEVARIABLES)||(r=r.set(t.KEY_CONTEXT_GRAPHQL_SINGULARIZEVARIABLES,{}))),r&&r.has(i.KEY_CONTEXT_BASEIRI)&&(n=r.get(i.KEY_CONTEXT_BASEIRI));const u=this.mediatorContextPreprocess.mediate({context:r});let l;if(l="string"==typeof e?(await this.mediatorSparqlParse.mediate({context:r,query:e,queryFormat:c,baseIRI:n})).operation:e,(r=(await u).context).has(t.KEY_CONTEXT_INITIALBINDINGS)){const e=r.get(t.KEY_CONTEXT_INITIALBINDINGS);l=f.applyInitialBindings(l,i.ensureBindings(e))}const d={context:r,operation:l=(await this.mediatorOptimizeQueryOperation.mediate({context:r,operation:l})).operation},h=await this.mediatorQueryOperation.mediate(d);return h.context=r,h}async getResultMediaTypes(e){return(await this.mediatorSparqlSerializeMediaTypeCombiner.mediate({context:e,mediaTypes:!0})).mediaTypes}async resultToString(e,t,r){if(r=o.ActionContext(r),!t)switch(e.type){case"bindings":t="application/json";break;case"quads":t="application/trig";break;default:t="simple"}const n=e;return n.context=r,(await this.mediatorSparqlSerialize.mediate({context:r,handle:n,handleMediaType:t})).handle}invalidateHttpCache(e){return this.mediatorHttpInvalidate.mediate({url:e})}async run(e){throw new Error("ActorInitSparql#run is not supported in the browser.")}}f.ALGEBRA_TYPES=Object.keys(l.Algebra.types).reduce((e,t)=>(e[l.Algebra.types[t]]=!0,e),{}),t.ActorInitSparql=f,t.KEY_CONTEXT_INITIALBINDINGS="@comunica/actor-init-sparql:initialBindings",t.KEY_CONTEXT_QUERYFORMAT="@comunica/actor-init-sparql:queryFormat",t.KEY_CONTEXT_GRAPHQL_SINGULARIZEVARIABLES="@comunica/actor-init-sparql:singularizeVariables"},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(535))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(0);t.ActorInit=class extends n.Actor{constructor(e){super(e)}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(6);class i{constructor(e,t){this.array=e.slice(),this.iterators=[],t&&this.array.push(null)}static fromFixedData(e){return new i(e,!0)}static fromInitialData(e){return new i(e,!1)}static fromInitialEmpty(){return i.fromInitialData([])}static pushToIterator(e,t){null===t?e.close():e._push(t)}iterator(){if(this.isEnded())return new n.ArrayIterator(this.array.slice(0,this.array.length-1));const e=new n.BufferedIterator;for(const t of this.array)i.pushToIterator(e,t);return this.iterators.push(e),e}push(e){if(this.isEnded())throw new Error("Can not push data anymore into an AsyncReiterableArray after it has been terminated.");this.array.push(e);for(const t of this.iterators)i.pushToIterator(t,e)}isEnded(){return this.array.length>0&&null===this.array[this.array.length-1]}}t.AsyncReiterableArray=i},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(39);t.ActorSparqlSerialize=class extends n.ActorAbstractMediaTyped{constructor(e){super(e)}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(39);t.ActorSparqlSerializeFixedMediaTypes=class extends n.ActorAbstractMediaTypedFixed{constructor(e){super(e)}async testHandleChecked(e,t){return!0}}},function(e,t,r){const n=new(r(137).LoggerVoid)({}),i=new(r(0).Bus)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-init/Bus/Init"}),a=new(r(0).Bus)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-http/Bus/Http"}),o=new(r(0).Bus)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-rdf-join/Bus/RdfJoin"}),s=new(r(0).Bus)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-rdf-parse/Bus/RdfParse"}),c=new(r(0).Bus)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-rdf-dereference/Bus/RdfDereference"}),u=new(r(0).Bus)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-rdf-parse-html/Bus/RdfParseHtml"}),l=new(r(0).Bus)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-rdf-serialize/Bus/RdfSerialize"}),f=new(r(0).Bus)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-rdf-resolve-quad-pattern/Bus/RdfResolveQuadPattern"}),d=new(r(0).Bus)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-rdf-metadata/Bus/RdfMetadata"}),h=new(r(0).Bus)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-rdf-metadata-extract/Bus/RdfMetadataExtract"}),p=new(r(0).Bus)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-rdf-resolve-hypermedia/Bus/RdfResolveHypermedia"}),y=new(r(0).Bus)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-rdf-resolve-hypermedia-links/Bus/RdfResolveHypermediaLinks"}),m=new(r(0).Bus)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-http-invalidate/Bus/HttpInvalidate"}),g=new(r(0).Bus)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-optimize-query-operation/Bus/OptimizeQueryOperation"}),b=new(r(0).Bus)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-sparql-parse/Bus/SparqlParse"}),v=new(r(0).Bus)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-sparql-serialize/Bus/SparqlSerialize"}),_=new(r(0).Bus)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-context-preprocess/Bus/ContextPreprocess"}),w=new(r(0).BusIndexed)({actorIdentifierFields:["operationName"],actionIdentifierFields:["operation","type"],name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-query-operation/Bus/QueryOperation"}),S=new(r(38).MediatorNumber)({field:"time",type:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/mediator-number/Mediator/Number/type/TypeMin",ignoreErrors:!0,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/http.json#mediatorHttp",bus:a}),E=new(r(540).ActorHttpNative)({agentOptions:'{ "keepAlive": true, "maxSockets": 5 }',name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/http.json#myHttpFetcher",bus:a}),x=new(r(148).ActorRdfJoinNestedLoop)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/join.json#myRdfJoinActor",bus:o}),T=new(r(12).MediatorRace)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperators.json#mediatorRdfJoin",bus:o}),O=new(r(24).MediatorCombineUnion)({field:"mediaTypes",name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/rdf-dereference.json#mediatorRdfParseMediatypes",bus:s}),A=new(r(12).MediatorRace)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/rdf-dereference.json#mediatorRdfParseHandle",bus:s}),I=new(r(151).ActorRdfParseN3)({mediaTypes:{"application/trig":"1.0","application/n-quads":"0.7","text/turtle":"0.6","application/n-triples":"0.3","text/n3":"0.1"},priorityScale:"1",name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/rdf-parsers.json#myRdfParserN3",bus:s}),N=new(r(156).ActorRdfParseJsonLd)({mediaTypes:{"application/ld+json":"1.0","application/json":"0.5"},priorityScale:"9.0E-1",name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/rdf-parsers.json#myRdfParserJsonLd",bus:s}),R=new(r(160).ActorRdfParseRdfXml)({mediaTypes:{"application/rdf+xml":"1.0"},priorityScale:"5.0E-1",name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/rdf-parsers.json#myRdfParserRdfXml",bus:s}),k=new(r(162).ActorRdfParseXmlRdfa)({mediaTypes:{"application/xml":"1.0","text/xml":"1.0","image/svg+xml":"1.0"},priorityScale:"5.0E-1",name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/rdf-parsers.json#myRdfParserXmlRdfa",bus:s}),P=new(r(24).MediatorCombineUnion)({field:"mediaTypes",name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/rdf-parsers.json#mediatorRdfParseMediatypes",bus:s}),j=new(r(12).MediatorRace)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/rdf-parsers.json#mediatorRdfParseHandle",bus:s}),D=new(r(12).MediatorRace)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/resolve-hypermedia.json#mediatorRdfDereference",bus:c}),C=new(r(177).ActorRdfParseHtml)({busRdfParseHtml:u,mediaTypes:{"text/html":"1.0","application/xhtml+xml":"0.9"},priorityScale:"8.0E-1",name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/rdf-parsers.json#myRdfParserHtml",bus:s}),M=new(r(184).ActorRdfParseHtmlRdfa)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/rdf-parsers.json#myRdfParserHtmlRdfa",bus:u}),L=new(r(549).ActorRdfSerializeN3)({mediaTypes:{"application/trig":"1.0","application/n-quads":"0.7","text/turtle":"0.6","application/n-triples":"0.3","text/n3":"0.2"},name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/rdf-serializers.json#myRdfSerializerN3",bus:l}),q=new(r(553).ActorRdfSerializeJsonLd)({jsonStringifyIndentSpaces:2,mediaTypes:{"application/ld+json":"1.0"},priorityScale:"9.0E-1",name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/rdf-serializers.json#myRdfSerializeJsonLd",bus:l}),F=new(r(12).MediatorRace)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-serializers.json#mediatorRdfSerialize",bus:l}),B=new(r(24).MediatorCombineUnion)({field:"mediaTypes",name:"_:b0bnode309",bus:l}),U=new(r(12).MediatorRace)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperators.json#mediatorResolveQuadPattern",bus:f}),V=new(r(186).ActorRdfResolveQuadPatternRdfJsSource)({name:"config-sets:resolve-file.json#myRdfRdfJsSourceQuadPatternResolver",bus:f}),H=new(r(12).MediatorRace)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/resolve-hypermedia.json#mediatorMetadata",bus:d}),z=new(r(188).ActorRdfMetadataPrimaryTopic)({metadataToData:!1,dataToMetadataOnInvalidMetadataGraph:!0,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/resolve-hypermedia.json#myRdfMetadataPrimaryTopic",bus:d}),G=new(r(191).ActorRdfMetadataAll)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/resolve-hypermedia.json#myRdfMetadataAll",bus:d}),Q=new(r(24).MediatorCombineUnion)({field:"metadata",name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/resolve-hypermedia.json#mediatorMetadataExtract",bus:h}),X=new(r(192).ActorRdfMetadataExtractHydraControls)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/resolve-hypermedia.json#myRdfMetadataExtractHydraControls",bus:h}),$=new(r(204).ActorRdfMetadataExtractHydraCount)({predicates:["http://www.w3.org/ns/hydra/core#totalItems","http://rdfs.org/ns/void#triples"],name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/resolve-hypermedia.json#myRdfMetadataExtractHydraCount",bus:h}),J=new(r(205).ActorRdfMetadataExtractSparqlService)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/resolve-sparql.json#myRdfMetadataExtractSparqlService",bus:h}),Y=new(r(206).ActorRdfResolveHypermediaNone)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/resolve-hypermedia.json#myHypermediaNoneResolver",bus:p}),K=new(r(38).MediatorNumber)({field:"filterFactor",type:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/mediator-number/Mediator/Number/type/TypeMax",ignoreErrors:!0,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/resolve-hypermedia.json#mediatorRdfResolveHypermedia",bus:p}),W=new(r(12).MediatorRace)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/resolve-hypermedia.json#mediatorRdfResolveHypermediaLinks",bus:y}),Z=new(r(207).ActorRdfResolveHypermediaLinksNext)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/resolve-hypermedia.json#myHypermediaLinksNext",bus:y}),ee=new(r(208).ActorHttpInvalidateListenable)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-rdf-resolve-quad-pattern-hypermedia/Actor/RdfResolveQuadPattern/Hypermedia/httpInvalidator#default",bus:m}),te=new(r(210).MediatorAll)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-init.json#mediatorHttpInvalidate",bus:m}),re=new(r(75).MediatorCombinePipeline)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-init.json#mediatorOptimizeQueryOperation",bus:g}),ne=new(r(211).ActorOptimizeQueryOperationJoinBgp)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-optimize.json#myJoinBgpOptimizer",bus:g}),ie=new(r(12).MediatorRace)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-init.json#mediatorSparqlParse",bus:b}),ae=new(r(561).ActorSparqlParseGraphql)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/graphql-parsers.json#myGraphqlParser",bus:b}),oe=new(r(212).ActorSparqlParseAlgebra)({prefixes:{rdf:"http://www.w3.org/1999/02/22-rdf-syntax-ns#",rdfs:"http://www.w3.org/2000/01/rdf-schema#",owl:"http://www.w3.org/2002/07/owl#",xsd:"http://www.w3.org/2001/XMLSchema#",dc:"http://purl.org/dc/terms/",dcterms:"http://purl.org/dc/terms/",dc11:"http://purl.org/dc/elements/1.1/",foaf:"http://xmlns.com/foaf/0.1/",geo:"http://www.w3.org/2003/01/geo/wgs84_pos#",dbpedia:"http://dbpedia.org/resource/","dbpedia-owl":"http://dbpedia.org/ontology/",dbpprop:"http://dbpedia.org/property/",schema:"http://schema.org/",skos:"http://www.w3.org/2008/05/skos#"},name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-parsers.json#mySparqlParser",bus:b}),se=new(r(12).MediatorRace)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-init.json#mediatorSparqlSerialize",bus:v}),ce=new(r(24).MediatorCombineUnion)({field:"mediaTypes",name:"_:b0bnode303",bus:v}),ue=new(r(563).ActorSparqlSerializeJson)({mediaTypes:{"application/json":"1.0"},name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-serializers.json#myJsonSparqlSerializer",bus:v}),le=new(r(565).ActorSparqlSerializeSimple)({mediaTypes:{simple:"1.0"},name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-serializers.json#mySimpleSparqlSerializer",bus:v}),fe=new(r(567).ActorSparqlSerializeSparqlJson)({mediaTypes:{"application/sparql-results+json":"1.0"},name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-serializers.json#mySparqlJsonSparqlSerializer",bus:v}),de=new(r(569).ActorSparqlSerializeSparqlXml)({mediaTypes:{"application/sparql-results+xml":"1.0"},name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-serializers.json#mySparqlXmlSparqlSerializer",bus:v}),he=new(r(573).ActorSparqlSerializeStats)({mediaTypes:{stats:"1.0"},name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-serializers.json#myStatsSparqlSerializer",bus:v}),pe=new(r(575).ActorSparqlSerializeTable)({columnWidth:50,mediaTypes:{table:"1.0"},name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-serializers.json#myTableSparqlSerializer",bus:v}),ye=new(r(232).ActorSparqlSerializeTree)({mediaTypes:{tree:"0.9"},name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-serializers.json#myTreeSparqlSerializer",bus:v}),me=new(r(75).MediatorCombinePipeline)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-init.json#mediatorContextPreprocess",bus:_}),ge=new(r(38).MediatorNumber)({field:"httpRequests",type:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/mediator-number/Mediator/Number/type/TypeMin",ignoreErrors:!0,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperators.json#mediatorQueryOperation",bus:w}),be=new(r(214).ActorQueryOperationBgpEmpty)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperators.json#myEmptyBgpQueryOperator",bus:w}),ve=new(r(217).ActorQueryOperationValues)({name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperators.json#myValuesQueryOperator",bus:w}),_e=new(r(577).ActorHttpMemento)({mediatorHttp:S,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/http-memento.json#myHttpFetcher",bus:a}),we=new(r(218).ActorRdfResolveHypermediaSparql)({mediatorHttp:S,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/resolve-sparql.json#mySparqlQuadPatternResolver",bus:p}),Se=new(r(219).ActorQueryOperationSparqlEndpoint)({mediatorHttp:S,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/resolve-sparql.json#mySparqlEndpointResolver",bus:w}),Ee=new(r(221).ActorRdfDereferenceHttpParse)({mediatorHttp:S,mediatorRdfParseMediatypes:O,mediatorRdfParseHandle:A,maxAcceptHeaderLength:1024,maxAcceptHeaderLengthBrowser:128,mediaMappings:{ttl:"text/turtle",turtle:"text/turtle",nt:"application/n-triples",ntriples:"application/n-triples",nq:"application/n-quads",nquads:"application/n-quads",rdf:"application/rdf+xml",rdfxml:"application/rdf+xml",owl:"application/rdf+xml",n3:"text/n3",trig:"application/trig",jsonld:"application/ld+json",json:"application/json",html:"text/html",htm:"text/html",xhtml:"application/xhtml+xml",xht:"application/xhtml+xml",xml:"application/xml",svg:"image/svg+xml",svgz:"image/svg+xml"},name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/rdf-dereference.json#myRdfDereferencer",bus:c}),xe=new(r(224).ActorRdfParseHtmlScript)({mediatorRdfParseMediatypes:P,mediatorRdfParseHandle:j,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/rdf-parsers.json#myRdfParserHtmlScript",bus:u}),Te=new(r(579).ActorSparqlSerializeRdf)({mediatorRdfSerialize:F,mediatorMediaTypeCombiner:B,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-serializers.json#myRdfSparqlSerializer",bus:v}),Oe=new(r(225).ActorRdfResolveQuadPatternFederated)({mediatorResolveQuadPattern:U,skipEmptyPatterns:!1,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/resolve-federated.json#myFederatedQuadPatternResolver",bus:f}),Ae=new(r(226).ActorQueryOperationQuadpattern)({mediatorResolveQuadPattern:U,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperators.json#myQuadPatternQueryOperator",bus:w}),Ie=new(r(227).ActorRdfResolveHypermediaQpf)({mediatorMetadata:H,mediatorMetadataExtract:Q,mediatorRdfDereference:D,subjectUri:"http://www.w3.org/1999/02/22-rdf-syntax-ns#subject",predicateUri:"http://www.w3.org/1999/02/22-rdf-syntax-ns#predicate",objectUri:"http://www.w3.org/1999/02/22-rdf-syntax-ns#object",graphUri:"http://www.w3.org/ns/sparql-service-description#graph",name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/resolve-hypermedia.json#myHypermediaQpfResolver",bus:p}),Ne=new(r(228).ActorRdfResolveQuadPatternHypermedia)({mediatorRdfDereference:D,mediatorMetadata:H,mediatorMetadataExtract:Q,mediatorRdfResolveHypermedia:K,mediatorRdfResolveHypermediaLinks:W,cacheSize:100,httpInvalidator:ee,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/resolve-hypermedia.json#myQuadPatternHypermediaResolver",bus:f}),Re=new(r(581).ActorHttpProxy)({mediatorHttp:S,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/http.json#myHttpProxy",bus:a,beforeActors:[E]}),ke=new(r(230).ActorInitSparql)({mediatorOptimizeQueryOperation:re,mediatorQueryOperation:ge,mediatorSparqlParse:ie,mediatorSparqlSerialize:se,mediatorSparqlSerializeMediaTypeCombiner:ce,mediatorContextPreprocess:me,mediatorHttpInvalidate:te,logger:n,contextKeyShortcuts:{source:"@comunica/bus-rdf-resolve-quad-pattern:source",sources:"@comunica/bus-rdf-resolve-quad-pattern:sources",initialBindings:"@comunica/actor-init-sparql:initialBindings",queryFormat:"@comunica/actor-init-sparql:queryFormat",baseIRI:"@comunica/actor-init-sparql:baseIRI",log:"@comunica/core:log",datetime:"@comunica/actor-http-memento:datetime",queryTimestamp:"@comunica/actor-init-sparql:queryTimestamp",httpProxyHandler:"@comunica/actor-http-proxy:httpProxyHandler"},name:"urn:comunica:sparqlinit",bus:i});new(r(239).ActorQueryOperationAsk)({mediatorQueryOperation:ge,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperators.json#myAskQueryOperator",bus:w}),new(r(240).ActorQueryOperationService)({forceSparqlEndpoint:!1,mediatorQueryOperation:ge,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperators.json#myServiceQueryOperator",bus:w}),new(r(241).ActorQueryOperationSlice)({mediatorQueryOperation:ge,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperators.json#mySliceQueryOperator",bus:w}),new(r(242).ActorQueryOperationBgpSingle)({mediatorQueryOperation:ge,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperators.json#mySingleBgpQueryOperator",bus:w}),new(r(243).ActorQueryOperationBgpLeftDeepSmallest)({mediatorQueryOperation:ge,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperators.json#myLeftDeepSmallestBgpQueryOperator",bus:w}),new(r(245).ActorQueryOperationConstruct)({mediatorQueryOperation:ge,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperators.json#myConstructQueryOperator",bus:w}),new(r(246).ActorQueryOperationDescribeSubject)({mediatorQueryOperation:ge,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperators.json#myDescribeQueryOperator",bus:w}),new(r(247).ActorQueryOperationDistinctHash)({hashAlgorithm:"sha1",digestAlgorithm:"base64",mediatorQueryOperation:ge,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperators.json#myDistinctQueryOperator",bus:w}),new(r(279).ActorQueryOperationExtend)({mediatorQueryOperation:ge,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperators.json#myExtendQueryOperator",bus:w}),new(r(283).ActorQueryOperationReducedHash)({hashAlgorithm:"sha1",digestAlgorithm:"base64",cacheSize:100,mediatorQueryOperation:ge,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperators.json#myReducedQueryOperator",bus:w}),new(r(284).ActorQueryOperationFilterSparqlee)({mediatorQueryOperation:ge,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperators.json#myFilterQueryOperator",bus:w}),new(r(285).ActorQueryOperationFromQuad)({mediatorQueryOperation:ge,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperators.json#myFromQueryOperator",bus:w}),new(r(286).ActorQueryOperationGroup)({mediatorQueryOperation:ge,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperators.json#myGroupQueryOperator",bus:w}),new(r(287).ActorQueryOperationJoin)({mediatorJoin:T,mediatorQueryOperation:ge,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperators.json#myJoinQueryOperator",bus:w}),new(r(288).ActorQueryOperationLeftJoinNestedLoop)({mediatorQueryOperation:ge,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperators.json#myLeftJoinQueryOperator",bus:w}),new(r(289).ActorQueryOperationOrderBySparqlee)({mediatorQueryOperation:ge,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperators.json#myOrderByQueryOperator",bus:w}),new(r(290).ActorQueryOperationProject)({mediatorQueryOperation:ge,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperators.json#myProjectQueryOperator",bus:w}),new(r(100).ActorQueryOperationUnion)({mediatorQueryOperation:ge,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperators.json#myUnionQueryOperator",bus:w}),new(r(291).ActorQueryOperationMinus)({hashAlgorithm:"sha1",digestAlgorithm:"base64",mediatorQueryOperation:ge,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperators.json#myMinusQueryOperator",bus:w}),new(r(292).ActorQueryOperationPathAlt)({mediatorQueryOperation:ge,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperator-path.json#myAltPathOperator",bus:w}),new(r(294).ActorQueryOperationPathInv)({mediatorQueryOperation:ge,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperator-path.json#myInvPathOperator",bus:w}),new(r(295).ActorQueryOperationPathLink)({mediatorQueryOperation:ge,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperator-path.json#myLinkPathOperator",bus:w}),new(r(296).ActorQueryOperationPathNps)({mediatorQueryOperation:ge,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperator-path.json#myNpsPathOperator",bus:w}),new(r(297).ActorQueryOperationPathOneOrMore)({mediatorQueryOperation:ge,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperator-path.json#myOneOrMorePathOperator",bus:w}),new(r(298).ActorQueryOperationPathSeq)({mediatorQueryOperation:ge,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperator-path.json#mySeqPathOperator",bus:w}),new(r(299).ActorQueryOperationPathZeroOrMore)({mediatorQueryOperation:ge,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperator-path.json#myZeroOrMorePathOperator",bus:w}),new(r(300).ActorQueryOperationPathZeroOrOne)({mediatorQueryOperation:ge,name:"https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-init-sparql/^1.0.0/config/sets/sparql-queryoperator-path.json#myZeroOrOnePathOperator",bus:w});e.exports=ke},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(541))},function(e,t,r){"use strict";(function(e,n){Object.defineProperty(t,"__esModule",{value:!0});const i=r(37);r(48);const a=r(542);class o extends i.ActorHttp{constructor(e){super(e),this.userAgent=o.createUserAgent(),this.requester=new a.default(e.agentOptions?JSON.parse(e.agentOptions):void 0)}static createUserAgent(){return`Comunica/actor-http-native (${"undefined"==typeof window?"Node.js "+e.version+"; "+e.platform:"Browser-"+window.navigator.userAgent})`}async test(e){return{time:1/0}}async run(e){const t={};if(e.input.url?(t.url=e.input.url,Object.assign(t,e.input)):t.url=e.input,e.init&&Object.assign(t,e.init),t.headers){const e={};t.headers.forEach((t,r)=>{e[r]=t}),t.headers=e}else t.headers={};return t.headers["user-agent"]||(t.headers["user-agent"]=this.userAgent),t.method=t.method||"GET",this.logInfo(e.context,`Requesting ${t.url}`),new Promise((e,r)=>{const i=this.requester.createRequest(t);i.on("error",r),i.on("response",i=>{i.on("error",e=>{i=null,r(e)}),"HEAD"===t.method&&i.destroy(),n(()=>{if(i){i.cancel=()=>Promise.resolve(i.destroy());const r=new Headers(i.headers),n={body:i,headers:r,ok:i.statusCode<300,redirected:t.url!==i.responseUrl,status:i.statusCode,url:r.has("content-location")?r.get("content-location"):i.responseUrl};e(n)}})})})}}t.ActorHttpNative=o}).call(this,r(13),r(15).setImmediate)},function(e,t,r){"use strict";
18/*! @license MIT ©2013-2016 Ruben Verborgh, Ghent University - imec */Object.defineProperty(t,"__esModule",{value:!0});const n=r(31),i=r(234),a=r(3),o={"accept-encoding":!0,"user-agent":!0,referer:!0};t.default=class{constructor(){this.negotiatedResources={}}createRequest(e){this.negotiatedResources[this.removeQuery(e.url)]&&delete e.headers["accept-datetime"];const t=new XMLHttpRequest,r=e.headers;t.open(e.method,e.url,!0),t.timeout=e.timeout;for(const e in r)e in o||!r[e]||t.setRequestHeader(e,r[e]);const s=new n.EventEmitter;return s.abort=()=>{t.abort()},t.onload=()=>{const n=new a.Readable;n.push(t.responseText||""),n.push(null),n.statusCode=t.status,n.responseUrl=t.responseURL,n.headers={};const o=n.headers,c=t.getAllResponseHeaders()||"",u=/^([^:\n\r]+):[ \t]*([^\r\n]*)$/gm;let l=u.exec(c);for(;l;)o[l[1].toLowerCase()]=l[2],l=u.exec(c);if(s.emit("response",n),r["accept-datetime"]&&o["memento-datetime"]){const t=this.removeQuery(o["content-location"]||e.url);if(!this.negotiatedResources[t]){const e=o.link&&i(o.link);t!==this.removeQuery(e&&e.timegate&&e.timegate.url)&&(this.negotiatedResources[t]=!0)}}},t.onerror=()=>{s.emit("error",new Error("Error requesting "+e.url))},t.ontimeout=()=>{s.emit("error",new Error("Timeout requesting "+e.url))},t.send(),s}removeQuery(e){return e?e.replace(/\?.*$/,""):""}}},function(e,t,r){"use strict";function n(e,t){return Object.prototype.hasOwnProperty.call(e,t)}e.exports=function(e,t,r,a){t=t||"&",r=r||"=";var o={};if("string"!=typeof e||0===e.length)return o;var s=/\+/g;e=e.split(t);var c=1e3;a&&"number"==typeof a.maxKeys&&(c=a.maxKeys);var u=e.length;c>0&&u>c&&(u=c);for(var l=0;l<u;++l){var f,d,h,p,y=e[l].replace(s,"%20"),m=y.indexOf(r);m>=0?(f=y.substr(0,m),d=y.substr(m+1)):(f=y,d=""),h=decodeURIComponent(f),p=decodeURIComponent(d),n(o,h)?i(o[h])?o[h].push(p):o[h]=[o[h],p]:o[h]=p}return o};var i=Array.isArray||function(e){return"[object Array]"===Object.prototype.toString.call(e)}},function(e,t,r){"use strict";var n=function(e){switch(typeof e){case"string":return e;case"boolean":return e?"true":"false";case"number":return isFinite(e)?e:"";default:return""}};e.exports=function(e,t,r,s){return t=t||"&",r=r||"=",null===e&&(e=void 0),"object"==typeof e?a(o(e),function(o){var s=encodeURIComponent(n(o))+r;return i(e[o])?a(e[o],function(e){return s+encodeURIComponent(n(e))}).join(t):s+encodeURIComponent(n(e[o]))}).join(t):s?encodeURIComponent(n(s))+r+encodeURIComponent(n(e)):""};var i=Array.isArray||function(e){return"[object Array]"===Object.prototype.toString.call(e)};function a(e,t){if(e.map)return e.map(t);for(var r=[],n=0;n<e.length;n++)r.push(t(e[n],n));return r}var o=Object.keys||function(e){var t=[];for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.push(r);return t}},function(e,t,r){"use strict";var n=r(546),i=r(547);function a(){this.protocol=null,this.slashes=null,this.auth=null,this.host=null,this.port=null,this.hostname=null,this.hash=null,this.search=null,this.query=null,this.pathname=null,this.path=null,this.href=null}t.parse=v,t.resolve=function(e,t){return v(e,!1,!0).resolve(t)},t.resolveObject=function(e,t){return e?v(e,!1,!0).resolveObject(t):t},t.format=function(e){i.isString(e)&&(e=v(e));return e instanceof a?e.format():a.prototype.format.call(e)},t.Url=a;var o=/^([a-z0-9.+-]+:)/i,s=/:[0-9]*$/,c=/^(\/\/?(?!\/)[^\?\s]*)(\?[^\s]*)?$/,u=["{","}","|","\\","^","`"].concat(["<",">",'"',"`"," ","\r","\n","\t"]),l=["'"].concat(u),f=["%","/","?",";","#"].concat(l),d=["/","?","#"],h=/^[+a-z0-9A-Z_-]{0,63}$/,p=/^([+a-z0-9A-Z_-]{0,63})(.*)$/,y={javascript:!0,"javascript:":!0},m={javascript:!0,"javascript:":!0},g={http:!0,https:!0,ftp:!0,gopher:!0,file:!0,"http:":!0,"https:":!0,"ftp:":!0,"gopher:":!0,"file:":!0},b=r(235);function v(e,t,r){if(e&&i.isObject(e)&&e instanceof a)return e;var n=new a;return n.parse(e,t,r),n}a.prototype.parse=function(e,t,r){if(!i.isString(e))throw new TypeError("Parameter 'url' must be a string, not "+typeof e);var a=e.indexOf("?"),s=-1!==a&&a<e.indexOf("#")?"?":"#",u=e.split(s);u[0]=u[0].replace(/\\/g,"/");var v=e=u.join(s);if(v=v.trim(),!r&&1===e.split("#").length){var _=c.exec(v);if(_)return this.path=v,this.href=v,this.pathname=_[1],_[2]?(this.search=_[2],this.query=t?b.parse(this.search.substr(1)):this.search.substr(1)):t&&(this.search="",this.query={}),this}var w=o.exec(v);if(w){var S=(w=w[0]).toLowerCase();this.protocol=S,v=v.substr(w.length)}if(r||w||v.match(/^\/\/[^@\/]+@[^@\/]+/)){var E="//"===v.substr(0,2);!E||w&&m[w]||(v=v.substr(2),this.slashes=!0)}if(!m[w]&&(E||w&&!g[w])){for(var x,T,O=-1,A=0;A<d.length;A++){-1!==(I=v.indexOf(d[A]))&&(-1===O||I<O)&&(O=I)}-1!==(T=-1===O?v.lastIndexOf("@"):v.lastIndexOf("@",O))&&(x=v.slice(0,T),v=v.slice(T+1),this.auth=decodeURIComponent(x)),O=-1;for(A=0;A<f.length;A++){var I;-1!==(I=v.indexOf(f[A]))&&(-1===O||I<O)&&(O=I)}-1===O&&(O=v.length),this.host=v.slice(0,O),v=v.slice(O),this.parseHost(),this.hostname=this.hostname||"";var N="["===this.hostname[0]&&"]"===this.hostname[this.hostname.length-1];if(!N)for(var R=this.hostname.split(/\./),k=(A=0,R.length);A<k;A++){var P=R[A];if(P&&!P.match(h)){for(var j="",D=0,C=P.length;D<C;D++)P.charCodeAt(D)>127?j+="x":j+=P[D];if(!j.match(h)){var M=R.slice(0,A),L=R.slice(A+1),q=P.match(p);q&&(M.push(q[1]),L.unshift(q[2])),L.length&&(v="/"+L.join(".")+v),this.hostname=M.join(".");break}}}this.hostname.length>255?this.hostname="":this.hostname=this.hostname.toLowerCase(),N||(this.hostname=n.toASCII(this.hostname));var F=this.port?":"+this.port:"",B=this.hostname||"";this.host=B+F,this.href+=this.host,N&&(this.hostname=this.hostname.substr(1,this.hostname.length-2),"/"!==v[0]&&(v="/"+v))}if(!y[S])for(A=0,k=l.length;A<k;A++){var U=l[A];if(-1!==v.indexOf(U)){var V=encodeURIComponent(U);V===U&&(V=escape(U)),v=v.split(U).join(V)}}var H=v.indexOf("#");-1!==H&&(this.hash=v.substr(H),v=v.slice(0,H));var z=v.indexOf("?");if(-1!==z?(this.search=v.substr(z),this.query=v.substr(z+1),t&&(this.query=b.parse(this.query)),v=v.slice(0,z)):t&&(this.search="",this.query={}),v&&(this.pathname=v),g[S]&&this.hostname&&!this.pathname&&(this.pathname="/"),this.pathname||this.search){F=this.pathname||"";var G=this.search||"";this.path=F+G}return this.href=this.format(),this},a.prototype.format=function(){var e=this.auth||"";e&&(e=(e=encodeURIComponent(e)).replace(/%3A/i,":"),e+="@");var t=this.protocol||"",r=this.pathname||"",n=this.hash||"",a=!1,o="";this.host?a=e+this.host:this.hostname&&(a=e+(-1===this.hostname.indexOf(":")?this.hostname:"["+this.hostname+"]"),this.port&&(a+=":"+this.port)),this.query&&i.isObject(this.query)&&Object.keys(this.query).length&&(o=b.stringify(this.query));var s=this.search||o&&"?"+o||"";return t&&":"!==t.substr(-1)&&(t+=":"),this.slashes||(!t||g[t])&&!1!==a?(a="//"+(a||""),r&&"/"!==r.charAt(0)&&(r="/"+r)):a||(a=""),n&&"#"!==n.charAt(0)&&(n="#"+n),s&&"?"!==s.charAt(0)&&(s="?"+s),t+a+(r=r.replace(/[?#]/g,function(e){return encodeURIComponent(e)}))+(s=s.replace("#","%23"))+n},a.prototype.resolve=function(e){return this.resolveObject(v(e,!1,!0)).format()},a.prototype.resolveObject=function(e){if(i.isString(e)){var t=new a;t.parse(e,!1,!0),e=t}for(var r=new a,n=Object.keys(this),o=0;o<n.length;o++){var s=n[o];r[s]=this[s]}if(r.hash=e.hash,""===e.href)return r.href=r.format(),r;if(e.slashes&&!e.protocol){for(var c=Object.keys(e),u=0;u<c.length;u++){var l=c[u];"protocol"!==l&&(r[l]=e[l])}return g[r.protocol]&&r.hostname&&!r.pathname&&(r.path=r.pathname="/"),r.href=r.format(),r}if(e.protocol&&e.protocol!==r.protocol){if(!g[e.protocol]){for(var f=Object.keys(e),d=0;d<f.length;d++){var h=f[d];r[h]=e[h]}return r.href=r.format(),r}if(r.protocol=e.protocol,e.host||m[e.protocol])r.pathname=e.pathname;else{for(var p=(e.pathname||"").split("/");p.length&&!(e.host=p.shift()););e.host||(e.host=""),e.hostname||(e.hostname=""),""!==p[0]&&p.unshift(""),p.length<2&&p.unshift(""),r.pathname=p.join("/")}if(r.search=e.search,r.query=e.query,r.host=e.host||"",r.auth=e.auth,r.hostname=e.hostname||e.host,r.port=e.port,r.pathname||r.search){var y=r.pathname||"",b=r.search||"";r.path=y+b}return r.slashes=r.slashes||e.slashes,r.href=r.format(),r}var v=r.pathname&&"/"===r.pathname.charAt(0),_=e.host||e.pathname&&"/"===e.pathname.charAt(0),w=_||v||r.host&&e.pathname,S=w,E=r.pathname&&r.pathname.split("/")||[],x=(p=e.pathname&&e.pathname.split("/")||[],r.protocol&&!g[r.protocol]);if(x&&(r.hostname="",r.port=null,r.host&&(""===E[0]?E[0]=r.host:E.unshift(r.host)),r.host="",e.protocol&&(e.hostname=null,e.port=null,e.host&&(""===p[0]?p[0]=e.host:p.unshift(e.host)),e.host=null),w=w&&(""===p[0]||""===E[0])),_)r.host=e.host||""===e.host?e.host:r.host,r.hostname=e.hostname||""===e.hostname?e.hostname:r.hostname,r.search=e.search,r.query=e.query,E=p;else if(p.length)E||(E=[]),E.pop(),E=E.concat(p),r.search=e.search,r.query=e.query;else if(!i.isNullOrUndefined(e.search)){if(x)r.hostname=r.host=E.shift(),(N=!!(r.host&&r.host.indexOf("@")>0)&&r.host.split("@"))&&(r.auth=N.shift(),r.host=r.hostname=N.shift());return r.search=e.search,r.query=e.query,i.isNull(r.pathname)&&i.isNull(r.search)||(r.path=(r.pathname?r.pathname:"")+(r.search?r.search:"")),r.href=r.format(),r}if(!E.length)return r.pathname=null,r.search?r.path="/"+r.search:r.path=null,r.href=r.format(),r;for(var T=E.slice(-1)[0],O=(r.host||e.host||E.length>1)&&("."===T||".."===T)||""===T,A=0,I=E.length;I>=0;I--)"."===(T=E[I])?E.splice(I,1):".."===T?(E.splice(I,1),A++):A&&(E.splice(I,1),A--);if(!w&&!S)for(;A--;A)E.unshift("..");!w||""===E[0]||E[0]&&"/"===E[0].charAt(0)||E.unshift(""),O&&"/"!==E.join("/").substr(-1)&&E.push("");var N,R=""===E[0]||E[0]&&"/"===E[0].charAt(0);x&&(r.hostname=r.host=R?"":E.length?E.shift():"",(N=!!(r.host&&r.host.indexOf("@")>0)&&r.host.split("@"))&&(r.auth=N.shift(),r.host=r.hostname=N.shift()));return(w=w||r.host&&E.length)&&!R&&E.unshift(""),E.length?r.pathname=E.join("/"):(r.pathname=null,r.path=null),i.isNull(r.pathname)&&i.isNull(r.search)||(r.path=(r.pathname?r.pathname:"")+(r.search?r.search:"")),r.auth=e.auth||r.auth,r.slashes=r.slashes||e.slashes,r.href=r.format(),r},a.prototype.parseHost=function(){var e=this.host,t=s.exec(e);t&&(":"!==(t=t[0])&&(this.port=t.substr(1)),e=e.substr(0,e.length-t.length)),e&&(this.hostname=e)}},function(e,t,r){(function(e,n){var i;/*! https://mths.be/punycode v1.4.1 by @mathias */!function(a){t&&t.nodeType,e&&e.nodeType;var o="object"==typeof n&&n;o.global!==o&&o.window!==o&&o.self;var s,c=2147483647,u=36,l=1,f=26,d=38,h=700,p=72,y=128,m="-",g=/^xn--/,b=/[^\x20-\x7E]/,v=/[\x2E\u3002\uFF0E\uFF61]/g,_={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},w=u-l,S=Math.floor,E=String.fromCharCode;function x(e){throw new RangeError(_[e])}function T(e,t){for(var r=e.length,n=[];r--;)n[r]=t(e[r]);return n}function O(e,t){var r=e.split("@"),n="";return r.length>1&&(n=r[0]+"@",e=r[1]),n+T((e=e.replace(v,".")).split("."),t).join(".")}function A(e){for(var t,r,n=[],i=0,a=e.length;i<a;)(t=e.charCodeAt(i++))>=55296&&t<=56319&&i<a?56320==(64512&(r=e.charCodeAt(i++)))?n.push(((1023&t)<<10)+(1023&r)+65536):(n.push(t),i--):n.push(t);return n}function I(e){return T(e,function(e){var t="";return e>65535&&(t+=E((e-=65536)>>>10&1023|55296),e=56320|1023&e),t+=E(e)}).join("")}function N(e,t){return e+22+75*(e<26)-((0!=t)<<5)}function R(e,t,r){var n=0;for(e=r?S(e/h):e>>1,e+=S(e/t);e>w*f>>1;n+=u)e=S(e/w);return S(n+(w+1)*e/(e+d))}function k(e){var t,r,n,i,a,o,s,d,h,g,b,v=[],_=e.length,w=0,E=y,T=p;for((r=e.lastIndexOf(m))<0&&(r=0),n=0;n<r;++n)e.charCodeAt(n)>=128&&x("not-basic"),v.push(e.charCodeAt(n));for(i=r>0?r+1:0;i<_;){for(a=w,o=1,s=u;i>=_&&x("invalid-input"),((d=(b=e.charCodeAt(i++))-48<10?b-22:b-65<26?b-65:b-97<26?b-97:u)>=u||d>S((c-w)/o))&&x("overflow"),w+=d*o,!(d<(h=s<=T?l:s>=T+f?f:s-T));s+=u)o>S(c/(g=u-h))&&x("overflow"),o*=g;T=R(w-a,t=v.length+1,0==a),S(w/t)>c-E&&x("overflow"),E+=S(w/t),w%=t,v.splice(w++,0,E)}return I(v)}function P(e){var t,r,n,i,a,o,s,d,h,g,b,v,_,w,T,O=[];for(v=(e=A(e)).length,t=y,r=0,a=p,o=0;o<v;++o)(b=e[o])<128&&O.push(E(b));for(n=i=O.length,i&&O.push(m);n<v;){for(s=c,o=0;o<v;++o)(b=e[o])>=t&&b<s&&(s=b);for(s-t>S((c-r)/(_=n+1))&&x("overflow"),r+=(s-t)*_,t=s,o=0;o<v;++o)if((b=e[o])<t&&++r>c&&x("overflow"),b==t){for(d=r,h=u;!(d<(g=h<=a?l:h>=a+f?f:h-a));h+=u)T=d-g,w=u-g,O.push(E(N(g+T%w,0))),d=S(T/w);O.push(E(N(d,0))),a=R(r,_,n==i),r=0,++n}++r,++t}return O.join("")}s={version:"1.4.1",ucs2:{decode:A,encode:I},decode:k,encode:P,toASCII:function(e){return O(e,function(e){return b.test(e)?"xn--"+P(e):e})},toUnicode:function(e){return O(e,function(e){return g.test(e)?k(e.slice(4).toLowerCase()):e})}},void 0===(i=function(){return s}.call(t,r,t,e))||(e.exports=i)}()}).call(this,r(40)(e),r(9))},function(e,t,r){"use strict";e.exports={isString:function(e){return"string"==typeof e},isObject:function(e){return"object"==typeof e&&null!==e},isNull:function(e){return null===e},isNullOrUndefined:function(e){return null==e}}},function(e,t){e.exports=function(){for(var e={},t=0;t<arguments.length;t++){var n=arguments[t];for(var i in n)r.call(n,i)&&(e[i]=n[i])}return e};var r=Object.prototype.hasOwnProperty},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(550))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(236),i=r(68),a=r(3);t.ActorRdfSerializeN3=class extends n.ActorRdfSerializeFixedMediaTypes{constructor(e){super(e)}async runHandle(e,t,r){const n=new a.Readable({objectMode:!0});n._read=()=>{},e.quads.on("error",e=>o.emit("error",e)),e.quads.on("data",e=>n.push(e)),e.quads.on("end",()=>n.emit("end"));const o=n.pipe(new i.StreamWriter({format:t}));return{data:o,triples:"text/turtle"===t||"application/n-triples"===t||"text/n3"===t}}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(39);t.ActorRdfSerialize=class extends n.ActorAbstractMediaTyped{constructor(e){super(e)}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(39);t.ActorRdfSerializeFixedMediaTypes=class extends n.ActorAbstractMediaTypedFixed{constructor(e){super(e)}async testHandleChecked(e){return!0}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(554))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(236),i=r(555);t.ActorRdfSerializeJsonLd=class extends n.ActorRdfSerializeFixedMediaTypes{constructor(e){super(e),this.jsonLd=r(558)()}async runHandle(e,t,r){return{data:new i.JsonLdSerializer({space:" ".repeat(this.jsonStringifyIndentSpaces)}).import(e.quads)}}}},function(e,t,r){"use strict";function n(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}Object.defineProperty(t,"__esModule",{value:!0}),n(r(556)),n(r(237))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(23),i=r(3),a=r(557),o=r(237);class s extends i.Transform{constructor(e={}){super({objectMode:!0}),this.indentation=0,this.options=e,this.options.baseIRI&&!this.options.context&&(this.options.context={"@base":this.options.baseIRI}),this.options.context?(this.originalContext=this.options.context,this.context=(new n.ContextParser).parse(this.options.context,{baseIri:this.options.baseIRI})):this.context=Promise.resolve({})}import(e){const t=new i.PassThrough({objectMode:!0});e.on("error",e=>r.emit("error",e)),e.on("data",e=>t.write(e)),e.on("end",()=>t.emit("end"));const r=t.pipe(new s(this.options));return r}_transform(e,t,r){this.context.then(t=>{this.transformQuad(e,t),r()}).catch(r)}list(e){return{"@list":e.map(e=>o.Util.termToValue(e,this.options))}}_flush(e){return this.opened||this.pushDocumentStart(),this.lastPredicate&&this.endPredicate(),this.lastSubject&&this.endSubject(),this.lastGraph&&"DefaultGraph"!==this.lastGraph.termType&&this.endGraph(),this.endDocument(),e(null,null)}transformQuad(e,t){this.opened||this.pushDocumentStart();const r=this.lastGraph&&"DefaultGraph"!==this.lastGraph.termType&&this.lastGraph.equals(e.subject);if(!(r||this.lastGraph&&e.graph.equals(this.lastGraph))){let r="DefaultGraph"!==e.graph.termType&&this.lastSubject&&this.lastSubject.equals(e.graph);this.lastGraph&&("DefaultGraph"!==this.lastGraph.termType?(this.endPredicate(),this.endSubject(),this.endGraph(!0),r=!1):r?(this.endPredicate(!0),this.lastSubject=null):(this.endPredicate(),this.endSubject(!0))),"DefaultGraph"!==e.graph.termType&&(r||this.pushId(e.graph,t),this.pushSeparator(this.options.space?a.SeparatorType.GRAPH_FIELD_NONCOMPACT:a.SeparatorType.GRAPH_FIELD_COMPACT),this.indentation++),this.lastGraph=e.graph}this.lastSubject&&e.subject.equals(this.lastSubject)||(r?(this.endPredicate(),this.endSubject(),this.indentation--,this.pushSeparator(a.SeparatorType.ARRAY_END_COMMA),this.lastGraph=e.graph):(this.lastSubject&&(this.endPredicate(),this.endSubject(!0)),this.pushId(e.subject,t)),this.lastSubject=e.subject),this.lastPredicate&&e.predicate.equals(this.lastPredicate)||(this.lastPredicate&&this.endPredicate(!0),this.pushPredicate(e.predicate,t)),this.pushObject(e.object,t)}pushDocumentStart(){this.opened=!0,this.originalContext&&!this.options.excludeContext?(this.pushSeparator(a.SeparatorType.OBJECT_START),this.indentation++,this.pushSeparator(a.SeparatorType.CONTEXT_FIELD),this.pushIndented(JSON.stringify(this.originalContext,null,this.options.space)+","),this.pushSeparator(this.options.space?a.SeparatorType.GRAPH_FIELD_NONCOMPACT:a.SeparatorType.GRAPH_FIELD_COMPACT),this.indentation++):(this.pushSeparator(a.SeparatorType.ARRAY_START),this.indentation++)}pushId(e,t){const r="BlankNode"===e.termType?"_:"+e.value:n.ContextParser.compactIri(e.value,t,!1);this.pushSeparator(a.SeparatorType.OBJECT_START),this.indentation++,this.pushIndented(this.options.space?`"@id": "${r}",`:`"@id":"${r}",`)}pushPredicate(e,t){let r=e.value;this.options.useRdfType||r!==o.Util.RDF_TYPE||(r="@type",this.objectOptions=Object.assign({},this.options,{compactIds:!0,vocab:!0}));const i=n.ContextParser.compactIri(r,t,!0);this.pushIndented(this.options.space?`"${i}": [`:`"${i}":[`),this.indentation++,this.lastPredicate=e}pushObject(e,t){let r;this.hadObjectForPredicate?this.pushSeparator(a.SeparatorType.COMMA):this.hadObjectForPredicate=!0;try{r=e["@list"]?e:o.Util.termToValue(e,t,this.objectOptions||this.options)}catch(e){return this.emit("error",e)}this.pushIndented(JSON.stringify(r,null,this.options.space))}endDocument(){this.opened=!1,this.originalContext&&!this.options.excludeContext?(this.indentation--,this.pushSeparator(a.SeparatorType.ARRAY_END),this.indentation--,this.pushSeparator(a.SeparatorType.OBJECT_END)):(this.indentation--,this.pushSeparator(a.SeparatorType.ARRAY_END))}endPredicate(e){this.indentation--,this.pushSeparator(e?a.SeparatorType.ARRAY_END_COMMA:a.SeparatorType.ARRAY_END),this.hadObjectForPredicate=!1,this.objectOptions=null,this.lastPredicate=null}endSubject(e){this.indentation--,this.pushSeparator(e?a.SeparatorType.OBJECT_END_COMMA:a.SeparatorType.OBJECT_END),this.lastSubject=null}endGraph(e){this.indentation--,this.pushSeparator(a.SeparatorType.ARRAY_END),this.indentation--,this.pushSeparator(e?a.SeparatorType.OBJECT_END_COMMA:a.SeparatorType.OBJECT_END),this.lastGraph=null}pushSeparator(e){this.pushIndented(e.label)}pushIndented(e){const t=this.getIndentPrefix(),r=e.split("\n").map(e=>t+e).join("\n");this.push(r),this.options.space&&this.push("\n")}getIndentPrefix(){return this.options.space?this.options.space.repeat(this.indentation):""}}t.JsonLdSerializer=s},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});class n{constructor(e){this.label=e}}n.COMMA=new n(","),n.OBJECT_START=new n("{"),n.OBJECT_END=new n("}"),n.OBJECT_END_COMMA=new n("},"),n.ARRAY_START=new n("["),n.ARRAY_END=new n("]"),n.ARRAY_END_COMMA=new n("],"),n.GRAPH_FIELD_NONCOMPACT=new n('"@graph": ['),n.GRAPH_FIELD_COMPACT=new n('"@graph":['),n.CONTEXT_FIELD=new n('"@context":'),t.SeparatorType=n},function(e,t,r){(function(n,i,a,o){var s;
19/**
20 * A JavaScript implementation of the JSON-LD API.
21 *
22 * @author Dave Longley
23 *
24 * @license BSD 3-Clause License
25 * Copyright (c) 2011-2015 Digital Bazaar, Inc.
26 * All rights reserved.
27 *
28 * Redistribution and use in source and binary forms, with or without
29 * modification, are permitted provided that the following conditions are met:
30 *
31 * Redistributions of source code must retain the above copyright notice,
32 * this list of conditions and the following disclaimer.
33 *
34 * Redistributions in binary form must reproduce the above copyright
35 * notice, this list of conditions and the following disclaimer in the
36 * documentation and/or other materials provided with the distribution.
37 *
38 * Neither the name of the Digital Bazaar, Inc. nor the names of its
39 * contributors may be used to endorse or promote products derived from
40 * this software without specific prior written permission.
41 *
42 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS
43 * IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
44 * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
45 * PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
46 * HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
47 * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED
48 * TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
49 * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
50 * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
51 * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
52 * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
53 */
54/**
55 * A JavaScript implementation of the JSON-LD API.
56 *
57 * @author Dave Longley
58 *
59 * @license BSD 3-Clause License
60 * Copyright (c) 2011-2015 Digital Bazaar, Inc.
61 * All rights reserved.
62 *
63 * Redistribution and use in source and binary forms, with or without
64 * modification, are permitted provided that the following conditions are met:
65 *
66 * Redistributions of source code must retain the above copyright notice,
67 * this list of conditions and the following disclaimer.
68 *
69 * Redistributions in binary form must reproduce the above copyright
70 * notice, this list of conditions and the following disclaimer in the
71 * documentation and/or other materials provided with the distribution.
72 *
73 * Neither the name of the Digital Bazaar, Inc. nor the names of its
74 * contributors may be used to endorse or promote products derived from
75 * this software without specific prior written permission.
76 *
77 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS
78 * IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
79 * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
80 * PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
81 * HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
82 * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED
83 * TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
84 * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
85 * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
86 * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
87 * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
88 */
89!function(){var c=void 0!==n&&n.versions&&n.versions.node,u=!c&&("undefined"!=typeof window||"undefined"!=typeof self);u&&void 0===i&&("undefined"!=typeof window?i=window:"undefined"!=typeof self?i=self:"undefined"!=typeof $&&(i=$));var l=function(e){function t(){}e.compact=function(t,r,n,i){if(arguments.length<2)return e.nextTick(function(){i(new TypeError("Could not compact, too few arguments."))});if("function"==typeof n&&(i=n,n={}),n=n||{},null===r)return e.nextTick(function(){i(new R("The compaction context must not be null.","jsonld.CompactError",{code:"invalid local context"}))});if(null===t)return e.nextTick(function(){i(null,null)});"base"in n||(n.base="string"==typeof t?t:""),"compactArrays"in n||(n.compactArrays=!0),"graph"in n||(n.graph=!1),"skipExpansion"in n||(n.skipExpansion=!1),"documentLoader"in n||(n.documentLoader=e.loadDocument),"link"in n||(n.link=!1),n.link&&(n.skipExpansion=!0);var a=function(t,r,n){if(r.skipExpansion)return e.nextTick(function(){n(null,t)});e.expand(t,r,n)};function o(e,t,n,a){if(e)return i(e);a.compactArrays&&!a.graph&&ie(t)?1===t.length?t=t[0]:0===t.length&&(t={}):a.graph&&ne(t)&&(t=[t]),ne(r)&&"@context"in r&&(r=r["@context"]),ie(r=me(r))||(r=[r]);var o=r;r=[];for(var s=0;s<o.length;++s)(!ne(o[s])||Object.keys(o[s]).length>0)&&r.push(o[s]);var c=r.length>0;if(1===r.length&&(r=r[0]),ie(t)){var u=W(n,"@graph"),l=t;t={},c&&(t["@context"]=r),t[u]=l}else if(ne(t)&&c){l=t;for(var f in t={"@context":r},l)t[f]=l[f]}i(null,t,n)}a(t,n,function(t,a){if(t)return i(new R("Could not expand input before compaction.","jsonld.CompactError",{cause:t}));var s=te(n);e.processContext(s,r,n,function(e,t){if(e)return i(new R("Could not process context before compaction.","jsonld.CompactError",{cause:e}));var r;try{r=(new k).compact(t,null,a,n)}catch(e){return i(e)}o(null,r,t,n)})})},e.expand=function(t,r,n){if(arguments.length<1)return e.nextTick(function(){n(new TypeError("Could not expand, too few arguments."))});function i(e){"base"in r||(r.base=e.documentUrl||"");var t={document:me(e.document),remoteContext:{"@context":e.contextUrl}};if("expandContext"in r){var i=me(r.expandContext);t.expandContext="object"==typeof i&&"@context"in i?i:{"@context":i}}be(t,r,function(e,t){if(e)return n(e);var i;try{var a=new k,o=te(r),s=t.document,c=t.remoteContext["@context"];t.expandContext&&(o=a.processContext(o,t.expandContext["@context"],r)),c&&(o=a.processContext(o,c,r)),ne(i=a.expand(o,null,s,r,!1))&&"@graph"in i&&1===Object.keys(i).length?i=i["@graph"]:null===i&&(i=[]),ie(i)||(i=[i])}catch(e){return n(e)}n(null,i)})}"function"==typeof r&&(n=r,r={}),"documentLoader"in(r=r||{})||(r.documentLoader=e.loadDocument),"keepFreeFloatingNodes"in r||(r.keepFreeFloatingNodes=!1),e.nextTick(function(){if("string"!=typeof t)i({contextUrl:null,documentUrl:null,document:t});else{var e=function(e,t){if(e)return n(e);try{if(!t.document)throw new R("No remote document found at the given URL.","jsonld.NullRemoteDocument");"string"==typeof t.document&&(t.document=JSON.parse(t.document))}catch(e){return n(new R("Could not retrieve a JSON-LD document from the URL. URL dereferencing not implemented.","jsonld.LoadDocumentError",{code:"loading document failed",cause:e,remoteDoc:t}))}i(t)},a=r.documentLoader(t,e);a&&"then"in a&&a.then(e.bind(null,null),e)}})},e.flatten=function(t,r,n,i){if(arguments.length<1)return e.nextTick(function(){i(new TypeError("Could not flatten, too few arguments."))});"function"==typeof n?(i=n,n={}):"function"==typeof r&&(i=r,r=null,n={}),"base"in(n=n||{})||(n.base="string"==typeof t?t:""),"documentLoader"in n||(n.documentLoader=e.loadDocument),e.expand(t,n,function(t,a){if(t)return i(new R("Could not expand input before flattening.","jsonld.FlattenError",{cause:t}));var o;try{o=(new k).flatten(a)}catch(e){return i(e)}if(null===r)return i(null,o);n.graph=!0,n.skipExpansion=!0,e.compact(o,r,n,function(e,t){if(e)return i(new R("Could not compact flattened output.","jsonld.FlattenError",{cause:e}));i(null,t)})})},e.frame=function(t,r,n,i){if(arguments.length<2)return e.nextTick(function(){i(new TypeError("Could not frame, too few arguments."))});function a(r){var a,o=r.document;o?(a=o["@context"],r.contextUrl?(a?ie(a)?a.push(r.contextUrl):a=[a,r.contextUrl]:a=r.contextUrl,o["@context"]=a):a=a||{}):a={},e.expand(t,n,function(t,r){if(t)return i(new R("Could not expand input before framing.","jsonld.FrameError",{cause:t}));var s=me(n);s.isFrame=!0,s.keepFreeFloatingNodes=!0,e.expand(o,s,function(t,n){if(t)return i(new R("Could not expand frame before framing.","jsonld.FrameError",{cause:t}));var o;try{o=(new k).frame(r,n,s)}catch(e){return i(e)}s.graph=!0,s.skipExpansion=!0,s.link={},e.compact(o,a,s,function(e,t,r){if(e)return i(new R("Could not compact framed output.","jsonld.FrameError",{cause:e}));var n=W(r,"@graph");
90// remove @preserve from results
91s.link={},t[n]=Y(r,t[n],s),i(null,t)})})})}"function"==typeof n&&(i=n,n={}),"base"in(n=n||{})||(n.base="string"==typeof t?t:""),"documentLoader"in n||(n.documentLoader=e.loadDocument),"embed"in n||(n.embed="@last"),n.explicit=n.explicit||!1,"requireAll"in n||(n.requireAll=!0),n.omitDefault=n.omitDefault||!1,e.nextTick(function(){if("string"!=typeof r)a({contextUrl:null,documentUrl:null,document:r});else{var e=function(e,t){if(e)return i(e);try{if(!t.document)throw new R("No remote document found at the given URL.","jsonld.NullRemoteDocument");"string"==typeof t.document&&(t.document=JSON.parse(t.document))}catch(e){return i(new R("Could not retrieve a JSON-LD document from the URL. URL dereferencing not implemented.","jsonld.LoadDocumentError",{code:"loading document failed",cause:e,remoteDoc:t}))}a(t)},t=n.documentLoader(r,e);t&&"then"in t&&t.then(e.bind(null,null),e)}})},e.link=function(t,r,n,i){var a={};r&&(a["@context"]=r),a["@embed"]="@link",e.frame(t,a,n,i)},e.objectify=function(t,r,n,i){"function"==typeof n&&(i=n,n={}),"base"in(n=n||{})||(n.base="string"==typeof t?t:""),"documentLoader"in n||(n.documentLoader=e.loadDocument),e.expand(t,n,function(t,a){if(t)return i(new R("Could not expand input before linking.","jsonld.LinkError",{cause:t}));var o;try{o=(new k).flatten(a)}catch(e){return i(e)}n.graph=!0,n.skipExpansion=!0,e.compact(o,r,n,function(t,r,n){if(t)return i(new R("Could not compact flattened output before linking.","jsonld.LinkError",{cause:t}));var a=r[W(n,"@graph")][0],o=function(t){if(ne(t)||ie(t)){if(ne(t)){if(o.visited[t["@id"]])return;o.visited[t["@id"]]=!0}for(var r in t){var i=t[r],s="@id"===e.getContextValue(n,r,"@type");if(ie(i)||ne(i)||s)if(oe(i)&&s)t[r]=i=a[i],o(i);else if(ie(i))for(var c=0;c<i.length;++c)oe(i[c])&&s?i[c]=a[i[c]]:ne(i[c])&&"@id"in i[c]&&(i[c]=a[i[c]["@id"]]),o(i[c]);else if(ne(i)){var u=i["@id"];t[r]=i=a[u],o(i)}}}};for(var s in o.visited={},o(a),r.of_type={},a)if("@type"in a[s]){var c=a[s]["@type"];ie(c)||(c=[c]);for(var u=0;u<c.length;++u)c[u]in r.of_type||(r.of_type[c[u]]=[]),r.of_type[c[u]].push(a[s])}i(null,r)})})},e.normalize=function(t,r,n){if(arguments.length<1)return e.nextTick(function(){n(new TypeError("Could not normalize, too few arguments."))});if("function"==typeof r&&(n=r,r={}),"algorithm"in(r=r||{})||(r.algorithm="URGNA2012"),"base"in r||(r.base="string"==typeof t?t:""),"documentLoader"in r||(r.documentLoader=e.loadDocument),"inputFormat"in r){if("application/nquads"!==r.inputFormat)return n(new R("Unknown normalization input format.","jsonld.NormalizeError"));var i=ve(t);(new k).normalize(i,r,n)}else{var a=me(r);delete a.format,a.produceGeneralizedRdf=!1,e.toRDF(t,a,function(e,t){if(e)return n(new R("Could not convert input to RDF dataset before normalization.","jsonld.NormalizeError",{cause:e}));(new k).normalize(t,r,n)})}},e.fromRDF=function(t,r,n){if(arguments.length<1)return e.nextTick(function(){n(new TypeError("Could not convert from RDF, too few arguments."))});"function"==typeof r&&(n=r,r={}),"useRdfType"in(r=r||{})||(r.useRdfType=!1),"useNativeTypes"in r||(r.useNativeTypes=!1),"format"in r||!oe(t)||"format"in r||(r.format="application/nquads"),e.nextTick(function(){var e;if(r.format){if(!(e=r.rdfParser||d[r.format]))return n(new R("Unknown input format.","jsonld.UnknownFormat",{format:r.format}))}else e=function(){return t};var i=!1;try{t=e(t,function(e,t){if(i=!0,e)return n(e);a(t,r,n)})}catch(e){if(!i)return n(e);throw e}if(t){if("then"in t)return t.then(function(e){a(e,r,n)},n);a(t,r,n)}function a(e,t,r){(new k).fromRDF(e,t,r)}})},e.toRDF=function(t,r,n){if(arguments.length<1)return e.nextTick(function(){n(new TypeError("Could not convert to RDF, too few arguments."))});"function"==typeof r&&(n=r,r={}),"base"in(r=r||{})||(r.base="string"==typeof t?t:""),"documentLoader"in r||(r.documentLoader=e.loadDocument),e.expand(t,r,function(e,t){if(e)return n(new R("Could not expand input before serialization to RDF.","jsonld.RdfError",{cause:e}));var i;try{if(i=k.prototype.toRDF(t,r),r.format){if("application/nquads"===r.format)return n(null,_e(i));throw new R("Unknown output format.","jsonld.UnknownFormat",{format:r.format})}}catch(e){return n(e)}n(null,i)})},e.createNodeMap=function(t,r,n){if(arguments.length<1)return e.nextTick(function(){n(new TypeError("Could not create node map, too few arguments."))});"function"==typeof r&&(n=r,r={}),"base"in(r=r||{})||(r.base="string"==typeof t?t:""),"documentLoader"in r||(r.documentLoader=e.loadDocument),e.expand(t,r,function(e,t){if(e)return n(new R("Could not expand input before creating node map.","jsonld.CreateNodeMapError",{cause:e}));var i;try{i=(new k).createNodeMap(t,r)}catch(e){return n(e)}n(null,i)})},e.merge=function(t,r,n,i){if(arguments.length<1)return e.nextTick(function(){i(new TypeError("Could not merge, too few arguments."))});if(!ie(t))return e.nextTick(function(){i(new TypeError('Could not merge, "docs" must be an array.'))});"function"==typeof n?(i=n,n={}):"function"==typeof r&&(i=r,r=null,n={}),n=n||{};for(var a=[],o=null,s=t.length,c=0;c<t.length;++c){var u={};for(var l in n)u[l]=n[l];e.expand(t[c],u,f)}function f(e,t){if(!o){if(e)return o=e,i(new R("Could not expand input before flattening.","jsonld.FlattenError",{cause:e}));a.push(t),0==--s&&d(a)}}function d(t){var a=!0;"mergeNodes"in n&&(a=n.mergeNodes);var o,s=n.namer||n.issuer||new Se("_:b"),c={"@default":{}};try{for(var u=0;u<t.length;++u){var l=t[u];l=e.relabelBlankNodes(l,{issuer:new Se("_:b"+u+"-")});var f=a||0===u?c:{"@default":{}};if(V(l,f,"@default",s),f!==c)for(var d in f){var h=f[d];if(d in c){var p=c[d];for(var y in h)y in p||(p[y]=h[y])}else c[d]=h}}o=H(c)}catch(e){return i(e)}for(var m=[],g=Object.keys(o).sort(),b=0;b<g.length;++b){var v=o[g[b]];fe(v)||m.push(v)}if(null===r)return i(null,m);n.graph=!0,n.skipExpansion=!0,e.compact(m,r,n,function(e,t){if(e)return i(new R("Could not compact merged output.","jsonld.MergeError",{cause:e}));i(null,t)})}},e.relabelBlankNodes=function(e,t){return function e(t,r){if(ie(r))for(var n=0;n<r.length;++n)r[n]=e(t,r[n]);else if(he(r))r["@list"]=e(t,r["@list"]);else if(ne(r)){pe(r)&&(r["@id"]=t.getId(r["@id"]));for(var i=Object.keys(r).sort(),a=0;a<i.length;++a){var o=i[a];"@id"!==o&&(r[o]=e(t,r[o]))}}return r}((t=t||{}).namer||t.issuer||new Se("_:b"),e)},e.prependBase=function(t,r){return function(t,r){if(null===t)return r;if(-1!==r.indexOf(":"))return r;oe(t)&&(t=e.url.parse(t||""));var n=e.url.parse(r),i={protocol:t.protocol||""};if(null!==n.authority)i.authority=n.authority,i.path=n.path,i.query=n.query;else if(i.authority=t.authority,""===n.path)i.path=t.path,null!==n.query?i.query=n.query:i.query=t.query;else{if(0===n.path.indexOf("/"))i.path=n.path;else{var a=t.path;""!==n.path&&((a=a.substr(0,a.lastIndexOf("/")+1)).length>0&&"/"!==a.substr(-1)&&(a+="/"),a+=n.path),i.path=a}i.query=n.query}i.path=Oe(i.path,!!i.authority);var o=i.protocol;null!==i.authority&&(o+="//"+i.authority);o+=i.path,null!==i.query&&(o+="?"+i.query);null!==n.fragment&&(o+="#"+n.fragment);""===o&&(o="./");return o}(t,r)},e.documentLoader=function(t,r){var n=new R("Could not retrieve a JSON-LD document from the URL. URL dereferencing not implemented.","jsonld.LoadDocumentError",{code:"loading document failed"});return c?r(n,{contextUrl:null,documentUrl:t,document:null}):e.promisify(function(e){e(n)})},e.loadDocument=function(t,r){var n=e.documentLoader(t,r);n&&"then"in n&&n.then(r.bind(null,null),r)},e.promises=function(t){t=t||{};var n=Array.prototype.slice,a=e.promisify,o=t.api||{},s=t.version||"jsonld.js";"string"==typeof t.api&&(t.version||(s=t.api),o={}),o.expand=function(t){if(arguments.length<1)throw new TypeError("Could not expand, too few arguments.");return a.apply(null,[e.expand].concat(n.call(arguments)))},o.compact=function(t,r){if(arguments.length<2)throw new TypeError("Could not compact, too few arguments.");var i=function(t,r,n,i){"function"==typeof n&&(i=n,n={}),n=n||{},e.compact(t,r,n,function(e,t){i(e,t)})};return a.apply(null,[i].concat(n.call(arguments)))},o.flatten=function(t){if(arguments.length<1)throw new TypeError("Could not flatten, too few arguments.");return a.apply(null,[e.flatten].concat(n.call(arguments)))},o.frame=function(t,r){if(arguments.length<2)throw new TypeError("Could not frame, too few arguments.");return a.apply(null,[e.frame].concat(n.call(arguments)))},o.fromRDF=function(t){if(arguments.length<1)throw new TypeError("Could not convert from RDF, too few arguments.");return a.apply(null,[e.fromRDF].concat(n.call(arguments)))},o.toRDF=function(t){if(arguments.length<1)throw new TypeError("Could not convert to RDF, too few arguments.");return a.apply(null,[e.toRDF].concat(n.call(arguments)))},o.normalize=function(t){if(arguments.length<1)throw new TypeError("Could not normalize, too few arguments.");return a.apply(null,[e.normalize].concat(n.call(arguments)))},"jsonld.js"===s&&(o.link=function(t,r){if(arguments.length<2)throw new TypeError("Could not link, too few arguments.");return a.apply(null,[e.link].concat(n.call(arguments)))},o.objectify=function(t){return a.apply(null,[e.objectify].concat(n.call(arguments)))},o.createNodeMap=function(t){return a.apply(null,[e.createNodeMap].concat(n.call(arguments)))},o.merge=function(t){return a.apply(null,[e.merge].concat(n.call(arguments)))});try{e.Promise=i.Promise||r(238).Promise}catch(e){var c=function(){throw new Error("Unable to find a Promise implementation.")};for(var u in o)o[u]=c}return o},e.promisify=function(t){if(!e.Promise)try{e.Promise=i.Promise||r(238).Promise}catch(e){throw new Error("Unable to find a Promise implementation.")}var n=Array.prototype.slice.call(arguments,1);return new e.Promise(function(e,r){t.apply(null,n.concat(function(t,n){t?r(t):e(n)}))})},e.promises({api:e.promises}),t.prototype=e.promises({version:"json-ld-1.0"}),t.prototype.toString=function(){return this instanceof t?"[object JsonLdProcessor]":"[object JsonLdProcessorPrototype]"},e.JsonLdProcessor=t;var s=!!Object.defineProperty;if(s)try{Object.defineProperty({},"x",{})}catch(e){s=!1}s&&(Object.defineProperty(t,"prototype",{writable:!1,enumerable:!1}),Object.defineProperty(t.prototype,"constructor",{writable:!0,enumerable:!1,configurable:!0,value:t})),u&&void 0===i.JsonLdProcessor&&(s?Object.defineProperty(i,"JsonLdProcessor",{writable:!0,enumerable:!1,configurable:!0,value:t}):i.JsonLdProcessor=t);var l="function"==typeof a&&a,f=l?function(e){l(e)}:function(e){setTimeout(e,0)};"object"==typeof n&&"function"==typeof n.nextTick?e.nextTick=n.nextTick:e.nextTick=f,e.setImmediate=l?f:e.nextTick,e.parseLinkHeader=function(e){for(var t={},r=e.match(/(?:<[^>]*?>|"[^"]*?"|[^,])+/g),n=/\s*<([^>]*?)>\s*(?:;\s*(.*))?/,i=0;i<r.length;++i){var a=r[i].match(n);if(a){for(var o={target:a[1]},s=a[2],c=/(.*?)=(?:(?:"([^"]*?)")|([^"]*?))\s*(?:(?:;\s*)|$)/g;a=c.exec(s);)o[a[1]]=void 0===a[2]?a[3]:a[2];var u=o.rel||"";ie(t[u])?t[u].push(o):t[u]=u in t?[t[u],o]:o}}return t},e.RequestQueue=function(){this._requests={}},e.RequestQueue.prototype.wrapLoader=function(e){return this._loader=e,this._usePromise=1===e.length,this.add.bind(this)},e.RequestQueue.prototype.add=function(t,r){var n=this;if(!r&&!n._usePromise)throw new Error("callback must be specified.");if(n._usePromise)return new e.Promise(function(e,r){var i=n._requests[t];i||(i=n._requests[t]=n._loader(t).then(function(e){return delete n._requests[t],e}).catch(function(e){throw delete n._requests[t],e})),i.then(function(t){e(t)}).catch(function(e){r(e)})});t in n._requests?n._requests[t].push(r):(n._requests[t]=[r],n._loader(t,function(e,r){var i=n._requests[t];delete n._requests[t];for(var a=0;a<i.length;++a)i[a](e,r)}))},e.DocumentCache=function(e){this.order=[],this.cache={},this.size=e||50,this.expires=3e4},e.DocumentCache.prototype.get=function(e){if(e in this.cache){var t=this.cache[e];if(t.expires>=+new Date)return t.ctx;delete this.cache[e],this.order.splice(this.order.indexOf(e),1)}return null},e.DocumentCache.prototype.set=function(e,t){this.order.length===this.size&&delete this.cache[this.order.shift()],this.order.push(e),this.cache[e]={ctx:t,expires:+new Date+this.expires}},e.ActiveContextCache=function(e){this.order=[],this.cache={},this.size=e||100},e.ActiveContextCache.prototype.get=function(e,t){var r=JSON.stringify(e),n=JSON.stringify(t),i=this.cache[r];return i&&n in i?i[n]:null},e.ActiveContextCache.prototype.set=function(e,t,r){if(this.order.length===this.size){var n=this.order.shift();delete this.cache[n.activeCtx][n.localCtx]}var i=JSON.stringify(e),a=JSON.stringify(t);this.order.push({activeCtx:i,localCtx:a}),i in this.cache||(this.cache[i]={}),this.cache[i][a]=me(r)},e.cache={activeCtx:new e.ActiveContextCache},e.documentLoaders={},e.documentLoaders.jquery=function(t,r){r=r||{};var n=new e.RequestQueue;return("usePromise"in r?r.usePromise:"undefined"!=typeof Promise)?n.wrapLoader(function(t){return e.promisify(i,t)}):n.wrapLoader(i);function i(n,i){return 0!==n.indexOf("http:")&&0!==n.indexOf("https:")?i(new R('URL could not be dereferenced; only "http" and "https" URLs are supported.',"jsonld.InvalidUrl",{code:"loading document failed",url:n}),{contextUrl:null,documentUrl:n,document:null}):r.secure&&0!==n.indexOf("https")?i(new R('URL could not be dereferenced; secure mode is enabled and the URL\'s scheme is not "https".',"jsonld.InvalidUrl",{code:"loading document failed",url:n}),{contextUrl:null,documentUrl:n,document:null}):void t.ajax({url:n,accepts:{json:"application/ld+json, application/json"},headers:{Accept:"application/ld+json, application/json"},dataType:"json",crossDomain:!0,success:function(t,r,a){var o={contextUrl:null,documentUrl:n,document:t},s=a.getResponseHeader("Content-Type"),c=a.getResponseHeader("Link");if(c&&"application/ld+json"!==s){if(ie(c=e.parseLinkHeader(c)[I]))return i(new R("URL could not be dereferenced, it has more than one associated HTTP Link Header.","jsonld.InvalidUrl",{code:"multiple context link headers",url:n}),o);c&&(o.contextUrl=c.target)}i(null,o)},error:function(e,t,r){i(new R("URL could not be dereferenced, an error occurred.","jsonld.LoadDocumentError",{code:"loading document failed",url:n,cause:r}),{contextUrl:null,documentUrl:n,document:null})}})}},e.documentLoaders.node=function(t){var n=!("strictSSL"in(t=t||{}))||t.strictSSL,i="maxRedirects"in t?t.maxRedirects:-1,a="request"in t?t.request:r(34),o="application/ld+json, application/json",s=r(34),c=new e.RequestQueue;if(t.usePromise)return c.wrapLoader(function(t){return e.promisify(l,t,[])});var u=t.headers||{};if("Accept"in u||"accept"in u)throw new RangeError('Accept header may not be specified as an option; only "'+o+'" is supported.');return c.wrapLoader(function(e,t){l(e,[],t)});function l(r,c,u){if(0!==r.indexOf("http:")&&0!==r.indexOf("https:"))return u(new R('URL could not be dereferenced; only "http" and "https" URLs are supported.',"jsonld.InvalidUrl",{code:"loading document failed",url:r}),{contextUrl:null,documentUrl:r,document:null});if(t.secure&&0!==r.indexOf("https"))return u(new R('URL could not be dereferenced; secure mode is enabled and the URL\'s scheme is not "https".',"jsonld.InvalidUrl",{code:"loading document failed",url:r}),{contextUrl:null,documentUrl:r,document:null});var f=null;if(null!==f)return u(null,f);var d={Accept:o};for(var h in t.headers)d[h]=t.headers[h];a({url:r,headers:d,strictSSL:n,followRedirect:!1},function(t,n,a){if(f={contextUrl:null,documentUrl:r,document:a||null},t)return u(new R("URL could not be dereferenced, an error occurred.","jsonld.LoadDocumentError",{code:"loading document failed",url:r,cause:t}),f);var o=s.STATUS_CODES[n.statusCode];if(n.statusCode>=400)return u(new R("URL could not be dereferenced: "+o,"jsonld.InvalidUrl",{code:"loading document failed",url:r,httpStatusCode:n.statusCode}),f);if(n.headers.link&&"application/ld+json"!==n.headers["content-type"]){var d=e.parseLinkHeader(n.headers.link)[I];if(ie(d))return u(new R("URL could not be dereferenced, it has more than one associated HTTP Link Header.","jsonld.InvalidUrl",{code:"multiple context link headers",url:r}),f);d&&(f.contextUrl=d.target)}if(n.statusCode>=300&&n.statusCode<400&&n.headers.location)return c.length===i?u(new R("URL could not be dereferenced; there were too many redirects.","jsonld.TooManyRedirects",{code:"loading document failed",url:r,httpStatusCode:n.statusCode,redirects:c}),f):-1!==c.indexOf(r)?u(new R("URL could not be dereferenced; infinite redirection was detected.","jsonld.InfiniteRedirectDetected",{code:"recursive context inclusion",url:r,httpStatusCode:n.statusCode,redirects:c}),f):(c.push(r),l(n.headers.location,c,u));c.push(r),u(t,f)})}},e.documentLoaders.xhr=function(t){t=t||{};var r=/(^|(\r\n))link:/i,n=new e.RequestQueue;return("usePromise"in t?t.usePromise:"undefined"!=typeof Promise)?n.wrapLoader(function(t){return e.promisify(i,t)}):n.wrapLoader(i);function i(n,i){if(0!==n.indexOf("http:")&&0!==n.indexOf("https:"))return i(new R('URL could not be dereferenced; only "http" and "https" URLs are supported.',"jsonld.InvalidUrl",{code:"loading document failed",url:n}),{contextUrl:null,documentUrl:n,document:null});if(t.secure&&0!==n.indexOf("https"))return i(new R('URL could not be dereferenced; secure mode is enabled and the URL\'s scheme is not "https".',"jsonld.InvalidUrl",{code:"loading document failed",url:n}),{contextUrl:null,documentUrl:n,document:null});var a=new(t.xhr||XMLHttpRequest);a.onload=function(){if(a.status>=400)return i(new R("URL could not be dereferenced: "+a.statusText,"jsonld.LoadDocumentError",{code:"loading document failed",url:n,httpStatusCode:a.status}),{contextUrl:null,documentUrl:n,document:null});var t,o={contextUrl:null,documentUrl:n,document:a.response},s=a.getResponseHeader("Content-Type");if(r.test(a.getAllResponseHeaders())&&(t=a.getResponseHeader("Link")),t&&"application/ld+json"!==s){if(ie(t=e.parseLinkHeader(t)[I]))return i(new R("URL could not be dereferenced, it has more than one associated HTTP Link Header.","jsonld.InvalidUrl",{code:"multiple context link headers",url:n}),o);t&&(o.contextUrl=t.target)}i(null,o)},a.onerror=function(){i(new R("URL could not be dereferenced, an error occurred.","jsonld.LoadDocumentError",{code:"loading document failed",url:n}),{contextUrl:null,documentUrl:n,document:null})},a.open("GET",n,!0),a.setRequestHeader("Accept","application/ld+json, application/json"),a.send()}},e.useDocumentLoader=function(t){if(!(t in e.documentLoaders))throw new R('Unknown document loader type: "'+t+'"',"jsonld.UnknownDocumentLoader",{type:t});e.documentLoader=e.documentLoaders[t].apply(e,Array.prototype.slice.call(arguments,1))},e.processContext=function(t,r){var n={},i=2;arguments.length>3&&(n=arguments[2]||{},i+=1);var a=arguments[i];if("base"in n||(n.base=""),"documentLoader"in n||(n.documentLoader=e.loadDocument),null===r)return a(null,te(n));ne(r=me(r))&&"@context"in r||(r={"@context":r}),be(r,n,function(e,r){if(e)return a(e);try{r=(new k).processContext(t,r,n)}catch(e){return a(e)}a(null,r)})},e.hasProperty=function(e,t){var r=!1;if(t in e){var n=e[t];r=!ie(n)||n.length>0}return r},e.hasValue=function(t,r,n){var i=!1;if(e.hasProperty(t,r)){var a=t[r],o=he(a);if(ie(a)||o){o&&(a=a["@list"]);for(var s=0;s<a.length;++s)if(e.compareValues(n,a[s])){i=!0;break}}else ie(n)||(i=e.compareValues(n,a))}return i},e.addValue=function(t,r,n,i){if("propertyIsArray"in(i=i||{})||(i.propertyIsArray=!1),"allowDuplicate"in i||(i.allowDuplicate=!0),ie(n)){0!==n.length||!i.propertyIsArray||r in t||(t[r]=[]);for(var a=0;a<n.length;++a)e.addValue(t,r,n[a],i)}else if(r in t){var o=!i.allowDuplicate&&e.hasValue(t,r,n);ie(t[r])||o&&!i.propertyIsArray||(t[r]=[t[r]]),o||t[r].push(n)}else t[r]=i.propertyIsArray?[n]:n},e.getValues=function(e,t){var r=e[t]||[];return ie(r)||(r=[r]),r},e.removeProperty=function(e,t){delete e[t]},e.removeValue=function(t,r,n,i){"propertyIsArray"in(i=i||{})||(i.propertyIsArray=!1);var a=e.getValues(t,r).filter(function(t){return!e.compareValues(t,n)});0===a.length?e.removeProperty(t,r):1!==a.length||i.propertyIsArray?t[r]=a:t[r]=a[0]},e.compareValues=function(e,t){return e===t||(!(!de(e)||!de(t)||e["@value"]!==t["@value"]||e["@type"]!==t["@type"]||e["@language"]!==t["@language"]||e["@index"]!==t["@index"])||!!(ne(e)&&"@id"in e&&ne(t)&&"@id"in t)&&e["@id"]===t["@id"])},e.getContextValue=function(e,t,r){var n=null;if(null===t)return n;if("@language"===r&&r in e&&(n=e[r]),e.mappings[t]){var i=e.mappings[t];ue(r)?n=i:r in i&&(n=i[r])}return n};var d={};if(e.registerRDFParser=function(e,t){d[e]=t},e.unregisterRDFParser=function(e){delete d[e]},c){if(void 0===h)var h=null;if(void 0===p)var p={ELEMENT_NODE:1,ATTRIBUTE_NODE:2,TEXT_NODE:3,CDATA_SECTION_NODE:4,ENTITY_REFERENCE_NODE:5,ENTITY_NODE:6,PROCESSING_INSTRUCTION_NODE:7,COMMENT_NODE:8,DOCUMENT_NODE:9,DOCUMENT_TYPE_NODE:10,DOCUMENT_FRAGMENT_NODE:11,NOTATION_NODE:12}}var y="http://www.w3.org/2001/XMLSchema#boolean",m="http://www.w3.org/2001/XMLSchema#double",g="http://www.w3.org/2001/XMLSchema#integer",b="http://www.w3.org/2001/XMLSchema#string",v="http://www.w3.org/1999/02/22-rdf-syntax-ns#",_=v+"first",w=v+"rest",S=v+"nil",E=v+"type",x=v+"PlainLiteral",T=v+"XMLLiteral",O=v+"object",A=v+"langString",I="http://www.w3.org/ns/json-ld#context",N=10,R=function(e,t,r){c?(Error.call(this),Error.captureStackTrace(this,this.constructor)):"undefined"!=typeof Error&&(this.stack=(new Error).stack),this.name=t||"jsonld.Error",this.message=e||"An unspecified JSON-LD error occurred.",this.details=r||{}};c?r(34).inherits(R,Error):"undefined"!=typeof Error&&(R.prototype=new Error);var k=function(){};function P(e){for(var t=[],r=Object.keys(e).sort(),n=0;n<r.length;++n){var i=r[n],a=e[i];ie(a)||(a=[a]);for(var o=0;o<a.length;++o){var s=a[o];if(null!==s){if(!oe(s))throw new R("Invalid JSON-LD syntax; language map values must be strings.","jsonld.SyntaxError",{code:"invalid language map value",languageMap:e});t.push({"@value":s,"@language":i.toLowerCase()})}}}return t}function j(e,t,r){for(var n=[],i=Object.keys(e).sort(),a=0;a<i.length;++a)for(var o=i[a],s=e[o],c=Object.keys(s).sort(),u=0;u<c.length;++u){var l=c[u],f=s[l];if("@type"===l)l=E;else if(re(l))continue;for(var d=0;d<f.length;++d){var h=f[d],p={};if(p.type=0===o.indexOf("_:")?"blank node":"IRI",p.value=o,ye(o)){var y={};if(y.type=0===l.indexOf("_:")?"blank node":"IRI",y.value=l,ye(l)&&("blank node"!==y.type||r.produceGeneralizedRdf))if(he(h))D(h["@list"],t,p,y,n);else{var m=C(h);m&&n.push({subject:p,predicate:y,object:m})}}}}return n}function D(e,t,r,n,i){for(var a={type:"IRI",value:_},o={type:"IRI",value:w},s={type:"IRI",value:S},c=0;c<e.length;++c){var u=e[c],l={type:"blank node",value:t.getId()};i.push({subject:r,predicate:n,object:l}),r=l,n=a;var f=C(u);f&&i.push({subject:r,predicate:n,object:f}),n=o}i.push({subject:r,predicate:n,object:s})}function C(e){var t,r={};if(de(e)){r.type="literal";var n=e["@value"],i=e["@type"]||null;"boolean"==typeof(t=n)||"[object Boolean]"===Object.prototype.toString.call(t)?(r.value=n.toString(),r.datatype=i||y):ce(n)||i===m?(ce(n)||(n=parseFloat(n)),r.value=n.toExponential(15).replace(/(\d)0*e\+?/,"$1E"),r.datatype=i||m):se(n)?(r.value=n.toFixed(0),r.datatype=i||g):"@language"in e?(r.value=n,r.datatype=i||A,r.language=e["@language"]):(r.value=n,r.datatype=i||b)}else{var a=ne(e)?e["@id"]:e;r.type=0===a.indexOf("_:")?"blank node":"IRI",r.value=a}return"IRI"!==r.type||ye(r.value)?r:null}function M(e,t){if("IRI"===e.type||"blank node"===e.type)return{"@id":e.value};var r,n={"@value":e.value};if(e.language)n["@language"]=e.language;else{var i=e.datatype;if(i||(i=b),t){if(i===y)"true"===n["@value"]?n["@value"]=!0:"false"===n["@value"]&&(n["@value"]=!1);else if(r=n["@value"],!isNaN(parseFloat(r))&&isFinite(r))if(i===g){var a=parseInt(n["@value"],10);a.toFixed(0)===n["@value"]&&(n["@value"]=a)}else i===m&&(n["@value"]=parseFloat(n["@value"]));-1===[y,g,m,b].indexOf(i)&&(n["@type"]=i)}else i!==b&&(n["@type"]=i)}return n}function L(e,t){for(var r=["subject","predicate","object"],n=0;n<r.length;++n){var i=r[n];if(e[i].type!==t[i].type||e[i].value!==t[i].value)return!1}return e.object.language===t.object.language&&e.object.datatype===t.object.datatype}k.prototype.compact=function(t,r,n,i){if(ie(n)){for(var a=[],o=0;o<n.length;++o){var s=this.compact(t,r,n[o],i);null!==s&&a.push(s)}if(i.compactArrays&&1===a.length)null===(S=e.getContextValue(t,r,"@container"))&&(a=a[0]);return a}if(ne(n)){if(i.link&&"@id"in n&&n["@id"]in i.link){var c=i.link[n["@id"]];for(o=0;o<c.length;++o)if(c[o].expanded===n)return c[o].compacted}if(de(n)||fe(n)){a=function(t,r,n){if(de(n)){var i=e.getContextValue(t,r,"@type"),a=e.getContextValue(t,r,"@language"),o=e.getContextValue(t,r,"@container"),s="@index"in n&&"@index"!==o;if(!s&&(n["@type"]===i||n["@language"]===a))return n["@value"];var c=Object.keys(n).length,u=1===c||2===c&&"@index"in n&&!s,l="@language"in t,f=oe(n["@value"]),d=t.mappings[r]&&null===t.mappings[r]["@language"];if(u&&(!l||!f||d))return n["@value"];var h={};return s&&(h[W(t,"@index")]=n["@index"]),"@type"in n?h[W(t,"@type")]=W(t,n["@type"],null,{vocab:!0}):"@language"in n&&(h[W(t,"@language")]=n["@language"]),h[W(t,"@value")]=n["@value"],h}var p=ee(t,r,{vocab:!0}),y=(i=e.getContextValue(t,r,"@type"),W(t,n["@id"],null,{vocab:"@vocab"===i}));if("@id"===i||"@vocab"===i||"@graph"===p)return y;return(h={})[W(t,"@id")]=y,h}(t,r,n);return i.link&&fe(n)&&(n["@id"]in i.link||(i.link[n["@id"]]=[]),i.link[n["@id"]].push({expanded:n,compacted:a})),a}var u="@reverse"===r;a={};i.link&&"@id"in n&&(n["@id"]in i.link||(i.link[n["@id"]]=[]),i.link[n["@id"]].push({expanded:n,compacted:a}));for(var l=Object.keys(n).sort(),f=0;f<l.length;++f){var d=l[f],h=n[d];if("@id"!==d&&"@type"!==d)if("@reverse"!==d)if("@index"!==d)if("@graph"!==d&&"@list"!==d&&re(d)){T=W(t,d);e.addValue(a,T,h)}else{if(0===h.length){var p=W(t,d,h,{vocab:!0},u);e.addValue(a,p,h,{propertyIsArray:!0})}for(A=0;A<h.length;++A){var y=h[A],m=(p=W(t,d,y,{vocab:!0},u),S=e.getContextValue(t,p,"@container"),he(y)),g=null;m&&(g=y["@list"]);var b=this.compact(t,p,m?g:y,i);if(m)if(ie(b)||(b=[b]),"@list"!==S){var v={};v[W(t,"@list")]=b,b=v,"@index"in y&&(b[W(t,"@index")]=y["@index"])}else if(p in a)throw new R('JSON-LD compact error; property has a "@list" @container rule but there is more than a single @list that matches the compacted term in the document. Compaction might mix unwanted items into the list.',"jsonld.SyntaxError",{code:"compaction to list of lists"});if("@language"===S||"@index"===S){var _;p in a?_=a[p]:a[p]=_={},"@language"===S&&de(b)&&(b=b["@value"]),e.addValue(_,y[S],b)}else{I=!i.compactArrays||"@set"===S||"@list"===S||ie(b)&&0===b.length||"@list"===d||"@graph"===d;e.addValue(a,p,b,{propertyIsArray:I})}}}else{if("@index"===(S=e.getContextValue(t,r,"@container")))continue;T=W(t,d);e.addValue(a,T,h)}else{O=this.compact(t,"@reverse",h,i);for(var w in O)if(t.mappings[w]&&t.mappings[w].reverse){var S,E=O[w],x="@set"===(S=e.getContextValue(t,w,"@container"))||!i.compactArrays;e.addValue(a,w,E,{propertyIsArray:x}),delete O[w]}if(Object.keys(O).length>0){var T=W(t,d);e.addValue(a,T,O)}}else{var O;if(oe(h))O=W(t,h,null,{vocab:"@type"===d});else{O=[];for(var A=0;A<h.length;++A)O.push(W(t,h[A],null,{vocab:!0}))}var T=W(t,d),I=ie(O)&&0===h.length;e.addValue(a,T,O,{propertyIsArray:I})}}return a}return n},k.prototype.expand=function(t,r,n,i,a){var o=this;if(null==n)return null;if(!ie(n)&&!ne(n))return a||null!==r&&"@graph"!==ee(t,r,{vocab:!0})?function(t,r,n){if(null==n)return null;var i=ee(t,r,{vocab:!0});if("@id"===i)return ee(t,n,{base:!0});if("@type"===i)return ee(t,n,{vocab:!0,base:!0});var a=e.getContextValue(t,r,"@type");if("@id"===a||"@graph"===i&&oe(n))return{"@id":ee(t,n,{base:!0})};if("@vocab"===a)return{"@id":ee(t,n,{vocab:!0,base:!0})};if(re(i))return n;var o={};if(null!==a)o["@type"]=a;else if(oe(n)){var s=e.getContextValue(t,r,"@language");null!==s&&(o["@language"]=s)}-1===["boolean","number","string"].indexOf(typeof n)&&(n=n.toString());return o["@value"]=n,o}(t,r,n):null;if(ie(n)){var s=[],c=e.getContextValue(t,r,"@container");a=a||"@list"===c;for(var u=0;u<n.length;++u){var l=o.expand(t,r,n[u],i);if(a&&(ie(l)||he(l)))throw new R("Invalid JSON-LD syntax; lists of lists are not permitted.","jsonld.SyntaxError",{code:"list of lists"});null!==l&&(ie(l)?s=s.concat(l):s.push(l))}return s}"@context"in n&&(t=o.processContext(t,n["@context"],i));for(var f=ee(t,r,{vocab:!0}),d=(s={},Object.keys(n).sort()),h=0;h<d.length;++h){var p,y=d[h],m=n[y];if("@context"!==y){var g=ee(t,y,{vocab:!0});if(null!==g&&(ye(g)||re(g))){if(re(g)){if("@reverse"===f)throw new R("Invalid JSON-LD syntax; a keyword cannot be used as a @reverse property.","jsonld.SyntaxError",{code:"invalid reverse property map",value:m});if(g in s)throw new R("Invalid JSON-LD syntax; colliding keywords detected.","jsonld.SyntaxError",{code:"colliding keywords",keyword:g})}if("@id"===g&&!oe(m)){if(!i.isFrame)throw new R('Invalid JSON-LD syntax; "@id" value must a string.',"jsonld.SyntaxError",{code:"invalid @id value",value:m});if(!ne(m))throw new R('Invalid JSON-LD syntax; "@id" value must be a string or an object.',"jsonld.SyntaxError",{code:"invalid @id value",value:m})}if("@type"===g&&ae(m),"@graph"===g&&!ne(m)&&!ie(m))throw new R('Invalid JSON-LD syntax; "@graph" value must not be an object or an array.',"jsonld.SyntaxError",{code:"invalid @graph value",value:m});if("@value"===g&&(ne(m)||ie(m)))throw new R('Invalid JSON-LD syntax; "@value" value must not be an object or an array.',"jsonld.SyntaxError",{code:"invalid value object value",value:m});if("@language"===g){if(null===m)continue;if(!oe(m))throw new R('Invalid JSON-LD syntax; "@language" value must be a string.',"jsonld.SyntaxError",{code:"invalid language-tagged string",value:m});m=m.toLowerCase()}if("@index"===g&&!oe(m))throw new R('Invalid JSON-LD syntax; "@index" value must be a string.',"jsonld.SyntaxError",{code:"invalid @index value",value:m});if("@reverse"!==g){if("@language"===(c=e.getContextValue(t,y,"@container"))&&ne(m))p=P(m);else if("@index"===c&&ne(m))p=function(e){for(var r=[],n=Object.keys(m).sort(),a=0;a<n.length;++a){var s=n[a],c=m[s];ie(c)||(c=[c]),c=o.expand(t,e,c,i,!1);for(var u=0;u<c.length;++u){var l=c[u];"@index"in l||(l["@index"]=s),r.push(l)}}return r}(y);else{var b="@list"===g;if(b||"@set"===g){var v=r;if(b&&"@graph"===f&&(v=null),p=o.expand(t,v,m,i,b),b&&he(p))throw new R("Invalid JSON-LD syntax; lists of lists are not permitted.","jsonld.SyntaxError",{code:"list of lists"})}else p=o.expand(t,y,m,i,!1)}if(null!==p||"@value"===g)if("@list"===g||he(p)||"@list"!==c||(p={"@list":p=ie(p)?p:[p]}),t.mappings[y]&&t.mappings[y].reverse){S=s["@reverse"]=s["@reverse"]||{};ie(p)||(p=[p]);for(x=0;x<p.length;++x){if(de(T=p[x])||he(T))throw new R('Invalid JSON-LD syntax; "@reverse" value must not be a @value or an @list.',"jsonld.SyntaxError",{code:"invalid reverse property value",value:p});e.addValue(S,g,T,{propertyIsArray:!0})}}else{var _=-1===["@index","@id","@type","@value","@language"].indexOf(g);e.addValue(s,g,p,{propertyIsArray:_})}}else{if(!ne(m))throw new R('Invalid JSON-LD syntax; "@reverse" value must be an object.',"jsonld.SyntaxError",{code:"invalid @reverse value",value:m});if("@reverse"in(p=o.expand(t,"@reverse",m,i)))for(var w in p["@reverse"])e.addValue(s,w,p["@reverse"][w],{propertyIsArray:!0});var S=s["@reverse"]||null;for(var w in p)if("@reverse"!==w){null===S&&(S=s["@reverse"]={}),e.addValue(S,w,[],{propertyIsArray:!0});for(var E=p[w],x=0;x<E.length;++x){var T;if(de(T=E[x])||he(T))throw new R('Invalid JSON-LD syntax; "@reverse" value must not be a @value or an @list.',"jsonld.SyntaxError",{code:"invalid reverse property value",value:p});e.addValue(S,w,T,{propertyIsArray:!0})}}}}}}var O=(d=Object.keys(s)).length;if("@value"in s){if("@type"in s&&"@language"in s)throw new R('Invalid JSON-LD syntax; an element containing "@value" may not contain both "@type" and "@language".',"jsonld.SyntaxError",{code:"invalid value object",element:s});var A=O-1;if("@type"in s&&(A-=1),"@index"in s&&(A-=1),"@language"in s&&(A-=1),0!==A)throw new R('Invalid JSON-LD syntax; an element containing "@value" may only have an "@index" property and at most one other property which can be "@type" or "@language".',"jsonld.SyntaxError",{code:"invalid value object",element:s});if(null===s["@value"])s=null;else{if("@language"in s&&!oe(s["@value"]))throw new R("Invalid JSON-LD syntax; only strings may be language-tagged.","jsonld.SyntaxError",{code:"invalid language-tagged value",element:s});if("@type"in s&&(!ye(s["@type"])||0===s["@type"].indexOf("_:")))throw new R('Invalid JSON-LD syntax; an element containing "@value" and "@type" must have an absolute IRI for the value of "@type".',"jsonld.SyntaxError",{code:"invalid typed value",element:s})}}else if("@type"in s&&!ie(s["@type"]))s["@type"]=[s["@type"]];else if("@set"in s||"@list"in s){if(O>1&&!(2===O&&"@index"in s))throw new R('Invalid JSON-LD syntax; if an element has the property "@set" or "@list", then it can have at most one other property that is "@index".',"jsonld.SyntaxError",{code:"invalid set or list object",element:s});"@set"in s&&(s=s["@set"],O=(d=Object.keys(s)).length)}else 1===O&&"@language"in s&&(s=null);return!ne(s)||i.keepFreeFloatingNodes||a||null!==r&&"@graph"!==f||(0===O||"@value"in s||"@list"in s||1===O&&"@id"in s)&&(s=null),s},k.prototype.createNodeMap=function(e,t){var r={"@default":{}};return V(e,r,"@default",(t=t||{}).namer||t.issuer||new Se("_:b")),H(r)},k.prototype.flatten=function(e){for(var t=this.createNodeMap(e),r=[],n=Object.keys(t).sort(),i=0;i<n.length;++i){var a=t[n[i]];fe(a)||r.push(a)}return r},k.prototype.frame=function(e,t,r){var n={options:r,graphs:{"@default":{},"@merged":{}},subjectStack:[],link:{}},i=new Se("_:b");V(e,n.graphs,"@merged",i),n.subjects=n.graphs["@merged"];var a=[];return function e(t,r,n,i,a){!function(e){if(!ie(e)||1!==e.length||!ne(e[0]))throw new R("Invalid JSON-LD syntax; a JSON-LD frame must be a single object.","jsonld.SyntaxError",{frame:e})}(n);n=n[0];var o=t.options;var s={embed:Q(n,o,"embed"),explicit:Q(n,o,"explicit"),requireAll:Q(n,o,"requireAll")};var c=function(e,t,r,n){for(var i={},a=0;a<t.length;++a){var o=t[a],s=e.subjects[o];X(s,r,n)&&(i[o]=s)}return i}(t,r,n,s);var u=Object.keys(c).sort();for(var l=0;l<u.length;++l){var f=u[l],d=c[f];if("@link"===s.embed&&f in t.link)J(i,a,t.link[f]);else{null===a&&(t.uniqueEmbeds={});var h={};if(h["@id"]=f,t.link[f]=h,"@never"===s.embed||G(d,t.subjectStack))J(i,a,h);else{"@last"===s.embed&&(f in t.uniqueEmbeds&&$(t,f),t.uniqueEmbeds[f]={parent:i,property:a}),t.subjectStack.push(d);for(var p=Object.keys(d).sort(),y=0;y<p.length;y++){var m=p[y];if(re(m))h[m]=me(d[m]);else if(!s.explicit||m in n)for(var g=d[m],b=0;b<g.length;++b){var v=g[b];if(he(v)){var _={"@list":[]};J(h,m,_);var w=v["@list"];for(var S in w)if(fe(v=w[S])){var E=m in n?n[m][0]["@list"]:z(s);e(t,[v["@id"]],E,_,"@list")}else J(_,"@list",me(v))}else if(fe(v)){var E=m in n?n[m]:z(s);e(t,[v["@id"]],E,h,m)}else J(h,m,me(v))}}for(var p=Object.keys(n).sort(),y=0;y<p.length;++y){var m=p[y];if(!re(m)){var x=n[m][0],T=Q(x,o,"omitDefault");if(!(T||m in h)){var O="@null";"@default"in x&&(O=me(x["@default"])),ie(O)||(O=[O]),h[m]=[{"@preserve":O}]}}}J(i,a,h),t.subjectStack.pop()}}}}(n,Object.keys(n.subjects).sort(),t,a,null),a},k.prototype.normalize=function(e,t,r){return"URDNA2015"===t.algorithm?new B(t).main(e,r):"URGNA2012"===t.algorithm?new U(t).main(e,r):void r(new Error("Invalid RDF Dataset Normalization algorithm: "+t.algorithm))},k.prototype.fromRDF=function(t,r,n){var i={},a={"@default":i},o={};for(var s in t){var c=t[s];s in a||(a[s]={}),"@default"===s||s in i||(i[s]={"@id":s});for(var u=a[s],l=0;l<c.length;++l){var f=c[l],d=f.subject.value,h=f.predicate.value,p=f.object;d in u||(u[d]={"@id":d});var y=u[d],m="IRI"===p.type||"blank node"===p.type;if(!m||p.value in u||(u[p.value]={"@id":p.value}),h!==E||r.useRdfType||!m){var g=M(p,r.useNativeTypes);if(e.addValue(y,h,g,{propertyIsArray:!0}),m)if(p.value===S){var b=u[p.value];"usages"in b||(b.usages=[]),b.usages.push({node:y,property:h,value:g})}else p.value in o?o[p.value]=!1:o[p.value]={node:y,property:h,value:g}}else e.addValue(y,"@type",p.value,{propertyIsArray:!0})}}for(var s in a){var v=a[s];if(S in v){for(var x=v[S],T=0;T<x.usages.length;++T){for(var O=x.usages[T],A=(y=O.node,O.property),I=O.value,N=[],R=[],k=Object.keys(y).length;A===w&&ne(o[y["@id"]])&&ie(y[_])&&1===y[_].length&&ie(y[w])&&1===y[w].length&&(3===k||4===k&&ie(y["@type"])&&1===y["@type"].length&&"http://www.w3.org/1999/02/22-rdf-syntax-ns#List"===y["@type"][0])&&(N.push(y[_][0]),R.push(y["@id"]),y=(O=o[y["@id"]]).node,A=O.property,I=O.value,k=Object.keys(y).length,0===y["@id"].indexOf("_:")););if(A===_){if(y["@id"]===S)continue;I=v[I["@id"]][w][0],N.pop(),R.pop()}delete I["@id"],I["@list"]=N.reverse();for(var P=0;P<R.length;++P)delete v[R[P]]}delete x.usages}}var j=[],D=Object.keys(i).sort();for(T=0;T<D.length;++T){var C=D[T];y=i[C];if(C in a){c=y["@graph"]=[],v=a[C];for(var L=Object.keys(v).sort(),q=0;q<L.length;++q){var F=v[L[q]];fe(F)||c.push(F)}}fe(y)||j.push(y)}n(null,j)},k.prototype.toRDF=function(e,t){var r=new Se("_:b"),n={"@default":{}};V(e,n,"@default",r);for(var i={},a=Object.keys(n).sort(),o=0;o<a.length;++o){var s=a[o];("@default"===s||ye(s))&&(i[s]=j(n[s],r,t))}return i},k.prototype.processContext=function(t,r,n){ne(r)&&"@context"in r&&ie(r["@context"])&&(r=r["@context"]);var i=ie(r)?r:[r];if(0===i.length)return t.clone();for(var a=t,o=0;o<i.length;++o){var s=i[o];if(null!==s){if(ne(s)&&"@context"in s&&(s=s["@context"]),!ne(s))throw new R("Invalid JSON-LD syntax; @context must be an object.","jsonld.SyntaxError",{code:"invalid local context",context:s});if(e.cache.activeCtx){var c=e.cache.activeCtx.get(t,s);if(c){a=t=c;continue}}t=a,a=a.clone();var u={};if("@base"in s){var l=s["@base"];if(null===l)l=null;else{if(!oe(l))throw new R('Invalid JSON-LD syntax; the value of "@base" in a @context must be a string or null.',"jsonld.SyntaxError",{code:"invalid base IRI",context:s});if(""!==l&&!ye(l))throw new R('Invalid JSON-LD syntax; the value of "@base" in a @context must be an absolute IRI or the empty string.',"jsonld.SyntaxError",{code:"invalid base IRI",context:s})}null!==l&&(l=e.url.parse(l||"")),a["@base"]=l,u["@base"]=!0}if("@vocab"in s){if(null===(f=s["@vocab"]))delete a["@vocab"];else{if(!oe(f))throw new R('Invalid JSON-LD syntax; the value of "@vocab" in a @context must be a string or null.',"jsonld.SyntaxError",{code:"invalid vocab mapping",context:s});if(!ye(f))throw new R('Invalid JSON-LD syntax; the value of "@vocab" in a @context must be an absolute IRI.',"jsonld.SyntaxError",{code:"invalid vocab mapping",context:s});a["@vocab"]=f}u["@vocab"]=!0}if("@language"in s){var f;if(null===(f=s["@language"]))delete a["@language"];else{if(!oe(f))throw new R('Invalid JSON-LD syntax; the value of "@language" in a @context must be a string or null.',"jsonld.SyntaxError",{code:"invalid default language",context:s});a["@language"]=f.toLowerCase()}u["@language"]=!0}for(var d in s)Z(a,s,d,u);e.cache.activeCtx&&e.cache.activeCtx.set(t,s,a)}else a=t=te(n)}return a};var q,F,B=(q={subject:"s",object:"o",name:"g"},(F=function(e){e=e||{},this.name="URDNA2015",this.options=e,this.blankNodeInfo={},this.hashToBlankNodes={},this.canonicalIssuer=new Se("_:c14n"),this.quads=[],this.schedule={},this.schedule.MAX_DEPTH="maxCallStackDepth"in e?e.maxCallStackDepth:500,this.schedule.MAX_TOTAL_DEPTH="maxTotalCallStackDepth"in e?e.maxCallStackDepth:4294967295,this.schedule.depth=0,this.schedule.totalDepth=0,this.schedule.timeSlice="timeSlice"in e?e.timeSlice:10}).prototype.doWork=function(t,r){var n=this.schedule;if(n.totalDepth>=n.MAX_TOTAL_DEPTH)return r(new Error("Maximum total call stack depth exceeded; normalization aborting."));!function i(){if(n.depth===n.MAX_DEPTH)return n.depth=0,n.running=!1,e.nextTick(i);var a=(new Date).getTime();if(n.running||(n.start=(new Date).getTime(),n.deadline=n.start+n.timeSlice),a<n.deadline)return n.running=!0,n.depth++,n.totalDepth++,t(function(e,t){n.depth--,n.totalDepth--,r(e,t)});n.depth=0,n.running=!1,e.setImmediate(i)}()},F.prototype.forEach=function(e,t,r){var n,i,a=this,o=0;if(ie(e))i=e.length,n=function(){return o!==i&&(n.value=e[o++],n.key=o,!0)};else{var s=Object.keys(e);i=s.length,n=function(){return o!==i&&(n.key=s[o++],n.value=e[n.key],!0)}}!function e(i,o){return i?r(i):n()?a.doWork(function(){t(n.value,n.key,e)}):void r()}()},F.prototype.waterfall=function(e,t){var r=this;r.forEach(e,function(e,t,n){r.doWork(e,n)},t)},F.prototype.whilst=function(e,t,r){var n=this;!function i(a){return a?r(a):e()?void n.doWork(t,i):r()}()},F.prototype.main=function(e,t){var r,n=this;if(n.schedule.start=(new Date).getTime(),n.options.format&&"application/nquads"!==n.options.format)return t(new R("Unknown output format.","jsonld.UnknownFormat",{format:n.options.format}));var i={};n.waterfall([function(t){n.forEach(e,function(e,t,r){"@default"===t&&(t=null),n.forEach(e,function(e,r,a){null!==t&&(0===t.indexOf("_:")?e.name={type:"blank node",value:t}:e.name={type:"IRI",value:t}),n.quads.push(e),n.forEachComponent(e,function(t){if("blank node"===t.type){var r=t.value;r in n.blankNodeInfo?n.blankNodeInfo[r].quads.push(e):(i[r]=!0,n.blankNodeInfo[r]={quads:[e]})}}),a()},r)},t)},function(e){var t=!0;n.whilst(function(){return t},function(e){t=!1,n.hashToBlankNodes={},n.waterfall([function(e){n.forEach(i,function(e,t,r){n.hashFirstDegreeQuads(t,function(e,i){if(e)return r(e);i in n.hashToBlankNodes?n.hashToBlankNodes[i].push(t):n.hashToBlankNodes[i]=[t],r()})},e)},function(e){var r=Object.keys(n.hashToBlankNodes).sort();n.forEach(r,function(e,r,a){var o=n.hashToBlankNodes[e];if(o.length>1)return a();var s=o[0];n.canonicalIssuer.getId(s),delete i[s],delete n.hashToBlankNodes[e],t=!0,a()},e)}],e)},e)},function(e){var t=Object.keys(n.hashToBlankNodes).sort();n.forEach(t,function(e,t,r){var i=[],a=n.hashToBlankNodes[e];n.waterfall([function(e){n.forEach(a,function(e,t,r){if(n.canonicalIssuer.hasId(e))return r();var a=new Se("_:b");a.getId(e),n.hashNDegreeQuads(e,a,function(e,t){if(e)return r(e);i.push(t),r()})},e)},function(e){i.sort(function(e,t){return e.hash<t.hash?-1:e.hash>t.hash?1:0}),n.forEach(i,function(e,t,r){for(var i in e.issuer.existing)n.canonicalIssuer.getId(i);r()},e)}],r)},e)},function(e){var t=[];n.waterfall([function(e){n.forEach(n.quads,function(e,r,i){n.forEachComponent(e,function(e){"blank node"===e.type&&0!==e.value.indexOf(n.canonicalIssuer.prefix)&&(e.value=n.canonicalIssuer.getId(e.value))}),t.push(we(e)),i()},e)},function(e){if(t.sort(),"application/nquads"===n.options.format)return r=t.join(""),e();r=ve(t.join("")),e()}],e)}],function(e){t(e,r)})},F.prototype.hashFirstDegreeQuads=function(e,t){var r=this,n=r.blankNodeInfo[e];if("hash"in n)return t(null,n.hash);var i=[],a=n.quads;r.forEach(a,function(t,n,a){var o={predicate:t.predicate};r.forEachComponent(t,function(t,n){o[n]=r.modifyFirstDegreeComponent(e,t,n)}),i.push(we(o)),a()},function(e){if(e)return t(e);i.sort(),n.hash=xe.hashNQuads(r.name,i),t(null,n.hash)})},F.prototype.modifyFirstDegreeComponent=function(e,t){return"blank node"!==t.type?t:((t=me(t)).value=t.value===e?"_:a":"_:z",t)},F.prototype.hashRelatedBlankNode=function(e,t,r,n,i){var a,o=this;o.waterfall([function(t){return o.canonicalIssuer.hasId(e)?(a=o.canonicalIssuer.getId(e),t()):r.hasId(e)?(a=r.getId(e),t()):void o.hashFirstDegreeQuads(e,function(e,r){if(e)return t(e);a=r,t()})}],function(e){if(e)return i(e);var r=new xe(o.name);return r.update(n),"g"!==n&&r.update(o.getRelatedPredicate(t)),r.update(a),i(null,r.digest())})},F.prototype.getRelatedPredicate=function(e){return"<"+e.predicate.value+">"},F.prototype.hashNDegreeQuads=function(e,t,r){var n,i=this,a=new xe(i.name);i.waterfall([function(r){i.createHashToRelated(e,t,function(e,t){if(e)return r(e);n=t,r()})},function(e){var r=Object.keys(n).sort();i.forEach(r,function(e,r,o){a.update(e);var s,c="",u=new Ee(n[e]);i.whilst(function(){return u.hasNext()},function(e){var r=u.next(),n=t.clone(),a="",o=[];i.waterfall([function(t){i.forEach(r,function(t,r,s){if(i.canonicalIssuer.hasId(t)?a+=i.canonicalIssuer.getId(t):(n.hasId(t)||o.push(t),a+=n.getId(t)),0!==c.length&&a.length>=c.length&&a>c)return e();s()},t)},function(t){i.forEach(o,function(t,r,o){i.hashNDegreeQuads(t,n,function(r,i){return r?o(r):(a+=n.getId(t),a+="<"+i.hash+">",n=i.issuer,0!==c.length&&a.length>=c.length&&a>c?e():void o())})},t)},function(e){(0===c.length||a<c)&&(c=a,s=n),e()}],e)},function(e){if(e)return o(e);a.update(c),t=s,o()})},e)}],function(e){r(e,{hash:a.digest(),issuer:t})})},F.prototype.createHashToRelated=function(e,t,r){var n=this,i={},a=n.blankNodeInfo[e].quads;n.forEach(a,function(r,a,o){n.forEach(r,function(a,o,s){if("predicate"===o||"blank node"!==a.type||a.value===e)return s();var c=a.value,u=q[o];n.hashRelatedBlankNode(c,r,t,u,function(e,t){if(e)return s(e);t in i?i[t].push(c):i[t]=[c],s()})},o)},function(e){r(e,i)})},F.prototype.forEachComponent=function(e,t){for(var r in e)"predicate"!==r&&t(e[r],r,e)},F),U=function(){var e=function(e){B.call(this,e),this.name="URGNA2012"};return(e.prototype=new B).modifyFirstDegreeComponent=function(e,t,r){return"blank node"!==t.type?t:((t=me(t)).value="name"===r?"_:g":t.value===e?"_:a":"_:z",t)},e.prototype.getRelatedPredicate=function(e){return e.predicate.value},e.prototype.createHashToRelated=function(e,t,r){var n=this,i={},a=n.blankNodeInfo[e].quads;n.forEach(a,function(r,a,o){var s,c;if("blank node"===r.subject.type&&r.subject.value!==e)c=r.subject.value,s="p";else{if("blank node"!==r.object.type||r.object.value===e)return o();c=r.object.value,s="r"}n.hashRelatedBlankNode(c,r,t,s,function(e,t){t in i?i[t].push(c):i[t]=[c],o()})},function(e){r(e,i)})},e}();function V(t,r,n,i,a,o){if(ie(t))for(var s=0;s<t.length;++s)V(t[s],r,n,i,void 0,o);else if(ne(t))if(de(t)){"@type"in t&&0===(u=t["@type"]).indexOf("_:")&&(t["@type"]=u=i.getId(u)),o&&o.push(t)}else{if("@type"in t){var c=t["@type"];for(s=0;s<c.length;++s){var u;0===(u=c[s]).indexOf("_:")&&i.getId(u)}}ue(a)&&(a=pe(t)?i.getId(t["@id"]):t["@id"]),o&&o.push({"@id":a});var l=r[n],f=l[a]=l[a]||{};f["@id"]=a;for(var d=Object.keys(t).sort(),h=0;h<d.length;++h){var p=d[h];if("@id"!==p)if("@reverse"!==p)if("@graph"!==p)if("@type"!==p&&re(p)){if("@index"===p&&p in f&&(t[p]!==f[p]||t[p]["@id"]!==f[p]["@id"]))throw new R("Invalid JSON-LD syntax; conflicting @index property detected.","jsonld.SyntaxError",{code:"conflicting indexes",subject:f});f[p]=t[p]}else{var y=t[p];if(0===p.indexOf("_:")&&(p=i.getId(p)),0!==y.length)for(var m=0;m<y.length;++m){var g=y[m];if("@type"===p&&(g=0===g.indexOf("_:")?i.getId(g):g),le(g)||fe(g)){var b=pe(g)?i.getId(g["@id"]):g["@id"];e.addValue(f,p,{"@id":b},{propertyIsArray:!0,allowDuplicate:!1}),V(g,r,n,i,b)}else if(he(g)){var v=[];V(g["@list"],r,n,i,a,v),g={"@list":v},e.addValue(f,p,g,{propertyIsArray:!0,allowDuplicate:!1})}else V(g,r,n,i,a),e.addValue(f,p,g,{propertyIsArray:!0,allowDuplicate:!1})}else e.addValue(f,p,[],{propertyIsArray:!0})}else{a in r||(r[a]={});var _="@merged"===n?n:a;V(t[p],r,_,i)}else{var w={"@id":a},S=t["@reverse"];for(var E in S)for(var x=S[E],T=0;T<x.length;++T){var O=x[T],A=O["@id"];pe(O)&&(A=i.getId(A)),V(O,r,n,i,A),e.addValue(l[A],E,w,{propertyIsArray:!0,allowDuplicate:!1})}}}}else o&&o.push(t)}function H(e){for(var t=e["@default"],r=Object.keys(e).sort(),n=0;n<r.length;++n){var i=r[n];if("@default"!==i){var a=e[i],o=t[i];o?"@graph"in o||(o["@graph"]=[]):t[i]=o={"@id":i,"@graph":[]};for(var s=o["@graph"],c=Object.keys(a).sort(),u=0;u<c.length;++u){var l=a[c[u]];fe(l)||s.push(l)}}}return t}function z(e){var t={};for(var r in e)void 0!==e[r]&&(t["@"+r]=[e[r]]);return[t]}function G(e,t){for(var r=t.length-1;r>=0;--r)if(t[r]["@id"]===e["@id"])return!0;return!1}function Q(e,t,r){var n="@"+r,i=n in e?e[n][0]:t[r];return"embed"===r&&(!0===i?i="@last":!1===i?i="@never":"@always"!==i&&"@never"!==i&&"@link"!==i&&(i="@last")),i}function X(t,r,n){if("@type"in r&&(1!==r["@type"].length||!ne(r["@type"][0]))){for(var i=r["@type"],a=0;a<i.length;++a)if(e.hasValue(t,"@type",i[a]))return!0;return!1}var o=!0,s=!1;for(var c in r){if(re(c)){if("@id"!==c&&"@type"!==c)continue;if(o=!1,"@id"===c&&oe(r[c])){if(t[c]!==r[c])return!1;s=!0;continue}}if(o=!1,c in t){if(ie(r[c])&&0===r[c].length&&void 0!==t[c])return!1;s=!0}else{var u=ie(r[c])&&ne(r[c][0])&&"@default"in r[c][0];if(n.requireAll&&!u)return!1}}return o||s}function $(t,r){var n=t.uniqueEmbeds,i=n[r],a=i.parent,o=i.property,s={"@id":r};if(ie(a)){for(var c=0;c<a.length;++c)if(e.compareValues(a[c],s)){a[c]=s;break}}else{var u=ie(a[o]);e.removeValue(a,o,s,{propertyIsArray:u}),e.addValue(a,o,s,{propertyIsArray:u})}var l=function(e){for(var t=Object.keys(n),r=0;r<t.length;++r){var i=t[r];i in n&&ne(n[i].parent)&&n[i].parent["@id"]===e&&(delete n[i],l(i))}};l(r)}function J(t,r,n){ne(t)?e.addValue(t,r,n,{propertyIsArray:!0}):t.push(n)}
92/**
93 * Removes the @preserve keywords as the last step of the framing algorithm.
94 *
95 * @param ctx the active context used to compact the input.
96 * @param input the framed, compacted output.
97 * @param options the compaction options used.
98 *
99 * @return the resulting output.
100 */function Y(t,r,n){if(ie(r)){for(var i=[],a=0;a<r.length;++a){null!==(l=Y(t,r[a],n))&&i.push(l)}r=i}else if(ne(r)){
101// remove @preserve
102if("@preserve"in r)return"@null"===r["@preserve"]?null:r["@preserve"];if(de(r))return r;if(he(r))return r["@list"]=Y(t,r["@list"],n),r;var o=W(t,"@id");if(o in r){var s=r[o];if(s in n.link){var c=n.link[s].indexOf(r);if(-1!==c)return n.link[s][c];n.link[s].push(r)}else n.link[s]=[r]}for(var u in r){var l=Y(t,r[u],n),f=e.getContextValue(t,u,"@container");n.compactArrays&&ie(l)&&1===l.length&&null===f&&(l=l[0]),r[u]=l}}return r}function K(e,t){return e.length<t.length?-1:t.length<e.length?1:e===t?0:e<t?-1:1}function W(t,r,n,i,a){if(null===r)return r;ue(n)&&(n=null),ue(a)&&(a=!1),i=i||{};var o=t.getInverse();if(re(r))return r in o?o[r]["@none"]["@type"]["@none"]:r;if(i.vocab&&r in o){var s=t["@language"]||"@none",c=[];ne(n)&&"@index"in n&&c.push("@index");var u="@language",l="@null";if(a)u="@type",l="@reverse",c.push("@set");else if(he(n)){"@index"in n||c.push("@list");for(var f=n["@list"],d=0===f.length?s:null,h=null,p=0;p<f.length;++p){var y=f[p],m="@none",g="@none";if(de(y)?"@language"in y?m=y["@language"]:"@type"in y?g=y["@type"]:m="@null":g="@id",null===d?d=m:m!==d&&de(y)&&(d="@none"),null===h?h=g:g!==h&&(h="@none"),"@none"===d&&"@none"===h)break}d=d||"@none","@none"!==(h=h||"@none")?(u="@type",l=h):l=d}else de(n)?"@language"in n&&!("@index"in n)?(c.push("@language"),l=n["@language"]):"@type"in n&&(u="@type",l=n["@type"]):(u="@type",l="@id"),c.push("@set");c.push("@none");var b=function(e,t,r,n,i,a){null===a&&(a="@null");var o=[];if("@id"!==a&&"@reverse"!==a||!fe(r))o.push(a);else{"@reverse"===a&&o.push("@reverse");var s=W(e,r["@id"],null,{vocab:!0});s in e.mappings&&e.mappings[s]&&e.mappings[s]["@id"]===r["@id"]?o.push.apply(o,["@vocab","@id"]):o.push.apply(o,["@id","@vocab"])}o.push("@none");for(var c=e.inverse[t],u=0;u<n.length;++u){var l=n[u];if(l in c)for(var f=c[l][i],d=0;d<o.length;++d){var h=o[d];if(h in f)return f[h]}}return null}(t,r,n,c,u,l);if(null!==b)return b}if(i.vocab&&"@vocab"in t){var v=t["@vocab"];if(0===r.indexOf(v)&&r!==v){var _=r.substr(v.length);if(!(_ in t.mappings))return _}}for(var w=null,S=0,E=[],x=t.fastCurieMap,T=r.length-1;S<T&&r[S]in x;++S)""in(x=x[r[S]])&&E.push(x[""][0]);for(p=E.length-1;p>=0;--p)for(var O=E[p],A=O.terms,I=0;I<A.length;++I){var N=A[I]+":"+r.substr(O.iri.length);(!(N in t.mappings)||null===n&&t.mappings[N]["@id"]===r)&&(null===w||K(N,w)<0)&&(w=N)}return null!==w?w:i.vocab?r:function(t,r){if(null===t)return r;oe(t)&&(t=e.url.parse(t||""));var n="";""!==t.href?n+=(t.protocol||"")+"//"+(t.authority||""):r.indexOf("//")&&(n+="//");if(0!==r.indexOf(n))return r;var i=e.url.parse(r.substr(n.length)),a=t.normalizedPath.split("/"),o=i.normalizedPath.split("/"),s=i.fragment||i.query?0:1;for(;a.length>0&&o.length>s&&a[0]===o[0];)a.shift(),o.shift();var c="";if(a.length>0){a.pop();for(var u=0;u<a.length;++u)c+="../"}c+=o.join("/"),null!==i.query&&(c+="?"+i.query);null!==i.fragment&&(c+="#"+i.fragment);""===c&&(c="./");return c}(t["@base"],r)}function Z(e,t,r,n){if(r in n){if(n[r])return;throw new R("Cyclical context definition detected.","jsonld.CyclicalContext",{code:"cyclic IRI mapping",context:t,term:r})}if(n[r]=!1,re(r))throw new R("Invalid JSON-LD syntax; keywords cannot be overridden.","jsonld.SyntaxError",{code:"keyword redefinition",context:t,term:r});if(""===r)throw new R("Invalid JSON-LD syntax; a term cannot be an empty string.","jsonld.SyntaxError",{code:"invalid term definition",context:t});e.mappings[r]&&delete e.mappings[r];var i=t[r];if(null===i||ne(i)&&null===i["@id"])return e.mappings[r]=null,void(n[r]=!0);if(oe(i)&&(i={"@id":i}),!ne(i))throw new R("Invalid JSON-LD syntax; @context property values must be strings or objects.","jsonld.SyntaxError",{code:"invalid term definition",context:t});var a=e.mappings[r]={};if(a.reverse=!1,"@reverse"in i){if("@id"in i)throw new R("Invalid JSON-LD syntax; a @reverse term definition must not contain @id.","jsonld.SyntaxError",{code:"invalid reverse property",context:t});var o=i["@reverse"];if(!oe(o))throw new R("Invalid JSON-LD syntax; a @context @reverse value must be a string.","jsonld.SyntaxError",{code:"invalid IRI mapping",context:t});if(!ye(s=ee(e,o,{vocab:!0,base:!1},t,n)))throw new R("Invalid JSON-LD syntax; a @context @reverse value must be an absolute IRI or a blank node identifier.","jsonld.SyntaxError",{code:"invalid IRI mapping",context:t});a["@id"]=s,a.reverse=!0}else if("@id"in i){if(!oe(s=i["@id"]))throw new R("Invalid JSON-LD syntax; a @context @id value must be an array of strings or a string.","jsonld.SyntaxError",{code:"invalid IRI mapping",context:t});if(s!==r){if(!ye(s=ee(e,s,{vocab:!0,base:!1},t,n))&&!re(s))throw new R("Invalid JSON-LD syntax; a @context @id value must be an absolute IRI, a blank node identifier, or a keyword.","jsonld.SyntaxError",{code:"invalid IRI mapping",context:t});a["@id"]=s}}var s,c=r.indexOf(":");if(a._termHasColon=-1!==c,!("@id"in a))if(a._termHasColon){var u=r.substr(0,c);if(u in t&&Z(e,t,u,n),e.mappings[u]){var l=r.substr(c+1);a["@id"]=e.mappings[u]["@id"]+l}else a["@id"]=r}else{if(!("@vocab"in e))throw new R("Invalid JSON-LD syntax; @context terms must define an @id.","jsonld.SyntaxError",{code:"invalid IRI mapping",context:t,term:r});a["@id"]=e["@vocab"]+r}if(n[r]=!0,"@type"in i){var f=i["@type"];if(!oe(f))throw new R("Invalid JSON-LD syntax; an @context @type values must be a string.","jsonld.SyntaxError",{code:"invalid type mapping",context:t});if("@id"!==f&&"@vocab"!==f){if(!ye(f=ee(e,f,{vocab:!0,base:!1},t,n)))throw new R("Invalid JSON-LD syntax; an @context @type value must be an absolute IRI.","jsonld.SyntaxError",{code:"invalid type mapping",context:t});if(0===f.indexOf("_:"))throw new R("Invalid JSON-LD syntax; an @context @type values must be an IRI, not a blank node identifier.","jsonld.SyntaxError",{code:"invalid type mapping",context:t})}a["@type"]=f}if("@container"in i){var d=i["@container"];if("@list"!==d&&"@set"!==d&&"@index"!==d&&"@language"!==d)throw new R("Invalid JSON-LD syntax; @context @container value must be one of the following: @list, @set, @index, or @language.","jsonld.SyntaxError",{code:"invalid container mapping",context:t});if(a.reverse&&"@index"!==d&&"@set"!==d&&null!==d)throw new R("Invalid JSON-LD syntax; @context @container value for a @reverse type definition must be @index or @set.","jsonld.SyntaxError",{code:"invalid reverse property",context:t});a["@container"]=d}if("@language"in i&&!("@type"in i)){var h=i["@language"];if(null!==h&&!oe(h))throw new R("Invalid JSON-LD syntax; @context @language value must be a string or null.","jsonld.SyntaxError",{code:"invalid language mapping",context:t});null!==h&&(h=h.toLowerCase()),a["@language"]=h}
103// disallow aliasing @context and @preserve
104if("@context"===(s=a["@id"])||"@preserve"===s)throw new R("Invalid JSON-LD syntax; @context and @preserve cannot be aliased.","jsonld.SyntaxError",{code:"invalid keyword alias",context:t})}function ee(t,r,n,i,a){if(null===r||re(r))return r;if(r=String(r),i&&r in i&&!0!==a[r]&&Z(t,i,r,a),(n=n||{}).vocab){if(null===(s=t.mappings[r]))return null;if(s)return s["@id"]}var o=r.indexOf(":");if(-1!==o){var s,c=r.substr(0,o),u=r.substr(o+1);return"_"===c||0===u.indexOf("//")?r:(i&&c in i&&Z(t,i,c,a),(s=t.mappings[c])?s["@id"]+u:r)}if(n.vocab&&"@vocab"in t)return t["@vocab"]+r;var l=r;return n.base&&(l=e.prependBase(t["@base"],l)),l}function te(t){return{"@base":e.url.parse(t.base||""),mappings:{},inverse:null,getInverse:function(){if(this.inverse)return this.inverse;for(var e=this.inverse={},t=this.fastCurieMap={},i={},a=this["@language"]||"@none",o=this.mappings,s=Object.keys(o).sort(K),c=0;c<s.length;++c){var u=s[c],l=o[u];if(null!==l){var f=l["@container"]||"@none",d=l["@id"];ie(d)||(d=[d]);for(var h=0;h<d.length;++h){var p=d[h],y=e[p],m=re(p);if(y)m||l._termHasColon||i[p].push(u);else if(e[p]=y={},!m&&!l._termHasColon){i[p]=[u];var g={iri:p,terms:i[p]};p[0]in t?t[p[0]].push(g):t[p[0]]=[g]}if(y[f]||(y[f]={"@language":{},"@type":{}}),y=y[f],l.reverse)n(l,u,y["@type"],"@reverse");else if("@type"in l)n(l,u,y["@type"],l["@type"]);else if("@language"in l){var b=l["@language"]||"@null";n(l,u,y["@language"],b)}else n(l,u,y["@language"],a),n(l,u,y["@type"],"@none"),n(l,u,y["@language"],"@none")}}}for(var v in t)r(t,v,1);return e},clone:function(){var e={};e["@base"]=this["@base"],e.mappings=me(this.mappings),e.clone=this.clone,e.inverse=null,e.getInverse=this.getInverse,"@language"in this&&(e["@language"]=this["@language"]);"@vocab"in this&&(e["@vocab"]=this["@vocab"]);return e}};function r(e,t,n){for(var i,a,o=e[t],s=e[t]={},c=0;c<o.length;++c)(a=n>=(i=o[c].iri).length?"":i[n])in s?s[a].push(o[c]):s[a]=[o[c]];for(var t in s)""!==t&&r(s,t,n+1)}function n(e,t,r,n){n in r||(r[n]=t)}}function re(e){if(!oe(e))return!1;switch(e){case"@base":case"@context":case"@container":case"@default":case"@embed":case"@explicit":case"@graph":case"@id":case"@index":case"@language":case"@list":case"@omitDefault":case"@preserve":case"@requireAll":case"@reverse":case"@set":case"@type":case"@value":case"@vocab":return!0}return!1}function ne(e){return"[object Object]"===Object.prototype.toString.call(e)}function ie(e){return Array.isArray(e)}function ae(e){if(!oe(e)&&!function(e){return ne(e)&&0===Object.keys(e).length}(e)){var t=!1;if(ie(e)){t=!0;for(var r=0;r<e.length;++r)if(!oe(e[r])){t=!1;break}}if(!t)throw new R('Invalid JSON-LD syntax; "@type" value must a string, an array of strings, or an empty object.',"jsonld.SyntaxError",{code:"invalid type value",value:e})}}function oe(e){return"string"==typeof e||"[object String]"===Object.prototype.toString.call(e)}function se(e){return"number"==typeof e||"[object Number]"===Object.prototype.toString.call(e)}function ce(e){return se(e)&&-1!==String(e).indexOf(".")}function ue(e){return void 0===e}function le(e){var t=!1;ne(e)&&!("@value"in e||"@set"in e||"@list"in e)&&(t=Object.keys(e).length>1||!("@id"in e));return t}function fe(e){return ne(e)&&1===Object.keys(e).length&&"@id"in e}function de(e){return ne(e)&&"@value"in e}function he(e){return ne(e)&&"@list"in e}function pe(e){var t=!1;return ne(e)&&(t="@id"in e?0===e["@id"].indexOf("_:"):0===Object.keys(e).length||!("@value"in e||"@set"in e||"@list"in e)),t}function ye(e){return oe(e)&&-1!==e.indexOf(":")}function me(e){if(e&&"object"==typeof e){var t;if(ie(e)){t=[];for(var r=0;r<e.length;++r)t[r]=me(e[r])}else if(ne(e))for(var n in t={},e)t[n]=me(e[n]);else t=e.toString();return t}return e}function ge(t,r,n,i){var a=Object.keys(r).length;if(ie(t)){for(var o=0;o<t.length;++o)ge(t[o],r,n,i);return a<Object.keys(r).length}if(ne(t)){for(var s in t)if("@context"===s){var c=t[s];if(ie(c)){var u=c.length;for(o=0;o<u;++o){var l=c[o];oe(l)&&(l=e.prependBase(i,l),n?ie(l=r[l])?(Array.prototype.splice.apply(c,[o,1].concat(l)),o+=l.length-1,u=c.length):c[o]=l:l in r||(r[l]=!1))}}else oe(c)&&(c=e.prependBase(i,c),n?t[s]=r[c]:c in r||(r[c]=!1))}else ge(t[s],r,n,i);return a<Object.keys(r).length}return!1}function be(e,t,r){var n=null,i=t.documentLoader,a=function(e,t,r,i,o){if(Object.keys(t).length>N)return n=new R("Maximum number of @context URLs exceeded.","jsonld.ContextUrlError",{code:"loading remote context failed",max:N}),o(n);var s={},c=function(){ge(e,s,!0,i),o(null,e)};if(!ge(e,s,!1,i))return c();var u=[];for(var l in s)!1===s[l]&&u.push(l);for(var f=u.length,d=0;d<u.length;++d)!function(e){if(e in t)return n=new R("Cyclical @context URLs detected.","jsonld.ContextUrlError",{code:"recursive context inclusion",url:e}),o(n);var i=me(t);i[e]=!0;var u=function(t,u){if(!n){var l=u?u.document:null;if(!t&&oe(l))try{l=JSON.parse(l)}catch(e){t=e}if(t?t=new R("Dereferencing a URL did not result in a valid JSON-LD object. Possible causes are an inaccessible URL perhaps due to a same-origin policy (ensure the server uses CORS if you are using client-side JavaScript), too many redirects, a non-JSON response, or more than one HTTP Link Header was provided for a remote context.","jsonld.InvalidUrl",{code:"loading remote context failed",url:e,cause:t}):ne(l)||(t=new R("Dereferencing a URL did not result in a JSON object. The response was valid JSON, but it was not a JSON object.","jsonld.InvalidUrl",{code:"invalid remote context",url:e,cause:t})),t)return o(n=t);l="@context"in l?{"@context":l["@context"]}:{"@context":{}},u.contextUrl&&(ie(l["@context"])||(l["@context"]=[l["@context"]]),l["@context"].push(u.contextUrl)),a(l,i,r,e,function(t,r){if(t)return o(t);s[e]=r["@context"],0===(f-=1)&&c()})}},l=r(e,u);l&&"then"in l&&l.then(u.bind(null,null),u)}(u[d])};a(e,{},i,t.base,r)}function ve(e){for(var t=new RegExp("^[ \\t]*(?:#.*)?$"),r=new RegExp('^[ \\t]*(?:(?:<([^:]+:[^>]*)>)|(_:(?:[A-Za-z0-9]+)))[ \\t]+(?:<([^:]+:[^>]*)>)[ \\t]+(?:(?:<([^:]+:[^>]*)>)|(_:(?:[A-Za-z0-9]+))|(?:"([^"\\\\]*(?:\\\\.[^"\\\\]*)*)"(?:(?:\\^\\^(?:<([^:]+:[^>]*)>))|(?:@([a-z]+(?:-[a-z0-9]+)*)))?))[ \\t]*(?:\\.|(?:(?:(?:<([^:]+:[^>]*)>)|(_:(?:[A-Za-z0-9]+)))[ \\t]*\\.))[ \\t]*(?:#.*)?$'),n={},i=e.split(/(?:\r\n)|(?:\n)|(?:\r)/g),a=0,o=0;o<i.length;++o){var s=i[o];if(a++,!t.test(s)){var c=s.match(r);if(null===c)throw new R("Error while parsing N-Quads; invalid quad.","jsonld.ParseError",{line:a});var u={};if(ue(c[1])?u.subject={type:"blank node",value:c[2]}:u.subject={type:"IRI",value:c[1]},u.predicate={type:"IRI",value:c[3]},ue(c[4]))if(ue(c[5])){u.object={type:"literal"},ue(c[7])?ue(c[8])?u.object.datatype=b:(u.object.datatype=A,u.object.language=c[8]):u.object.datatype=c[7];var l=c[6].replace(/\\"/g,'"').replace(/\\t/g,"\t").replace(/\\n/g,"\n").replace(/\\r/g,"\r").replace(/\\\\/g,"\\");u.object.value=l}else u.object={type:"blank node",value:c[5]};else u.object={type:"IRI",value:c[4]};var f="@default";if(ue(c[9])?ue(c[10])||(f=c[10]):f=c[9],f in n){for(var d=!0,h=n[f],p=0;d&&p<h.length;++p)L(h[p],u)&&(d=!1);d&&h.push(u)}else n[f]=[u]}}return n}function _e(e){var t=[];for(var r in e)for(var n=e[r],i=0;i<n.length;++i){var a=n[i];"@default"===r&&(r=null),t.push(we(a,r))}return t.sort().join("")}function we(e,t){var r=e.subject,n=e.predicate,i=e.object,a=t||null;"name"in e&&e.name&&(a=e.name.value);var o="";if("IRI"===r.type?o+="<"+r.value+">":o+=r.value,o+=" ","IRI"===n.type?o+="<"+n.value+">":o+=n.value,o+=" ","IRI"===i.type)o+="<"+i.value+">";else if("blank node"===i.type)o+=i.value;else{o+='"'+i.value.replace(/\\/g,"\\\\").replace(/\t/g,"\\t").replace(/\n/g,"\\n").replace(/\r/g,"\\r").replace(/\"/g,'\\"')+'"',i.datatype===A?i.language&&(o+="@"+i.language):i.datatype!==b&&(o+="^^<"+i.datatype+">")}return null!=a&&(0!==a.indexOf("_:")?o+=" <"+a+">":o+=" "+a),o+=" .\n"}function Se(e){this.prefix=e,this.counter=0,this.existing={}}Object.keys||(Object.keys=function(e){if(e!==Object(e))throw new TypeError("Object.keys called on non-object");var t=[];for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.push(r);return t}),e.registerRDFParser("application/nquads",ve),e.registerRDFParser("rdfa-api",function(e){for(var t={"@default":[]},r=e.getSubjects(),n=0;n<r.length;++n){var i=r[n];if(null!==i){var a=e.getSubjectTriples(i);if(null!==a){var o=a.predicates;for(var s in o)for(var c=o[s].objects,u=0;u<c.length;++u){var l=c[u],f={};0===i.indexOf("_:")?f.subject={type:"blank node",value:i}:f.subject={type:"IRI",value:i},0===s.indexOf("_:")?f.predicate={type:"blank node",value:s}:f.predicate={type:"IRI",value:s};var d=l.value;if(l.type===T){h||Te();var y=new h;d="";for(var m=0;m<l.value.length;m++)l.value[m].nodeType===p.ELEMENT_NODE?d+=y.serializeToString(l.value[m]):l.value[m].nodeType===p.TEXT_NODE&&(d+=l.value[m].nodeValue)}f.object={},l.type===O?0===l.value.indexOf("_:")?f.object.type="blank node":f.object.type="IRI":(f.object.type="literal",l.type===x?l.language?(f.object.datatype=A,f.object.language=l.language):f.object.datatype=b:f.object.datatype=l.type),f.object.value=d,t["@default"].push(f)}}}}return t}),e.IdentifierIssuer=Se,e.UniqueNamer=Se,Se.prototype.clone=function(){var e=new Se(this.prefix);return e.counter=this.counter,e.existing=me(this.existing),e},Se.prototype.getId=function(e){if(e&&e in this.existing)return this.existing[e];var t=this.prefix+this.counter;return this.counter+=1,e&&(this.existing[e]=t),t},Se.prototype.getName=Se.prototype.getName,Se.prototype.hasId=function(e){return e in this.existing},Se.prototype.isNamed=Se.prototype.hasId;var Ee=function(e){this.list=e.sort(),this.done=!1,this.left={};for(var t=0;t<e.length;++t)this.left[e[t]]=!0};Ee.prototype.hasNext=function(){return!this.done},Ee.prototype.next=function(){for(var e=this.list.slice(),t=null,r=0,n=this.list.length,i=0;i<n;++i){var a=this.list[i],o=this.left[a];(null===t||a>t)&&(o&&i>0&&a>this.list[i-1]||!o&&i<n-1&&a>this.list[i+1])&&(t=a,r=i)}if(null===t)this.done=!0;else{var s=this.left[t]?r-1:r+1;this.list[r]=this.list[s],this.list[s]=t;for(i=0;i<n;++i)this.list[i]>t&&(this.left[this.list[i]]=!this.left[this.list[i]])}return e};var xe=function(e){if(!(this instanceof xe))return new xe(e);if(-1===["URDNA2015","URGNA2012"].indexOf(e))throw new Error("Invalid RDF Dataset Normalization algorithm: "+e);xe._init.call(this,e)};if(xe.hashNQuads=function(e,t){for(var r=new xe(e),n=0;n<t.length;++n)r.update(t[n]);return r.digest()},function(e){if(e){var t=r(34);return xe._init=function(e){e="URDNA2015"===e?"sha256":"sha1",this.md=t.createHash(e)},xe.prototype.update=function(e){return this.md.update(e,"utf8")},void(xe.prototype.digest=function(){return this.md.digest("hex")})}xe._init=function(e){e="URDNA2015"===e?new a.Algorithm:new i.Algorithm,this.md=new n(e)},xe.prototype.update=function(e){return this.md.update(e)},xe.prototype.digest=function(){return this.md.digest().toHex()};var n=function(e){if(!(this instanceof n))return new n(e);if(this._algorithm=e,!n._padding||n._padding.length<this._algorithm.blockSize){n._padding=String.fromCharCode(128);for(var t=String.fromCharCode(0),r=64;r>0;)1&r&&(n._padding+=t),(r>>>=1)>0&&(t+=t)}this.start()};n.prototype.start=function(){this.messageLength=0,this.fullMessageLength=[];for(var e=this._algorithm.messageLengthSize/4,t=0;t<e;++t)this.fullMessageLength.push(0);return this._input=new n.ByteBuffer,this.state=this._algorithm.start(),this},n.prototype.update=function(e){e=new n.ByteBuffer(unescape(encodeURIComponent(e))),this.messageLength+=e.length();var t=e.length();t=[t/4294967296>>>0,t>>>0];for(var r=this.fullMessageLength.length-1;r>=0;--r)this.fullMessageLength[r]+=t[1],t[1]=t[0]+(this.fullMessageLength[r]/4294967296>>>0),this.fullMessageLength[r]=this.fullMessageLength[r]>>>0,t[0]=t[1]/4294967296>>>0;for(this._input.putBytes(e.bytes());this._input.length()>=this._algorithm.blockSize;)this.state=this._algorithm.digest(this.state,this._input);return(this._input.read>2048||0===this._input.length())&&this._input.compact(),this},n.prototype.digest=function(){var e=new n.ByteBuffer;e.putBytes(this._input.bytes());var t=this.fullMessageLength[this.fullMessageLength.length-1]+this._algorithm.messageLengthSize&this._algorithm.blockSize-1;e.putBytes(n._padding.substr(0,this._algorithm.blockSize-t));for(var r=new n.ByteBuffer,i=0;i<this.fullMessageLength.length;++i)r.putInt32(this.fullMessageLength[i]<<3|this.fullMessageLength[i+1]>>>28);this._algorithm.writeMessageLength(e,r);var a=this._algorithm.digest(this.state.copy(),e),o=new n.ByteBuffer;return a.write(o),o},n.ByteBuffer=function(e){this.data="string"==typeof e?e:"",this.read=0},n.ByteBuffer.prototype.putInt32=function(e){this.data+=String.fromCharCode(e>>24&255)+String.fromCharCode(e>>16&255)+String.fromCharCode(e>>8&255)+String.fromCharCode(255&e)},n.ByteBuffer.prototype.getInt32=function(){var e=this.data.charCodeAt(this.read)<<24^this.data.charCodeAt(this.read+1)<<16^this.data.charCodeAt(this.read+2)<<8^this.data.charCodeAt(this.read+3);return this.read+=4,e},n.ByteBuffer.prototype.putBytes=function(e){this.data+=e},n.ByteBuffer.prototype.bytes=function(){return this.data.slice(this.read)},n.ByteBuffer.prototype.length=function(){return this.data.length-this.read},n.ByteBuffer.prototype.compact=function(){this.data=this.data.slice(this.read),this.read=0},n.ByteBuffer.prototype.toHex=function(){for(var e="",t=this.read;t<this.data.length;++t){var r=this.data.charCodeAt(t);r<16&&(e+="0"),e+=r.toString(16)}return e};var i={_w:null,Algorithm:function(){this.name="sha1",this.blockSize=64,this.digestLength=20,this.messageLengthSize=8}};i.Algorithm.prototype.start=function(){return i._w||(i._w=new Array(80)),i._createState()},i.Algorithm.prototype.writeMessageLength=function(e,t){e.putBytes(t.bytes())},i.Algorithm.prototype.digest=function(e,t){for(var r,n,a,o,s,c,u,l=t.length(),f=i._w;l>=64;){for(n=e.h0,a=e.h1,o=e.h2,s=e.h3,c=e.h4,u=0;u<16;++u)r=t.getInt32(),f[u]=r,r=(n<<5|n>>>27)+(s^a&(o^s))+c+1518500249+r,c=s,s=o,o=a<<30|a>>>2,a=n,n=r;for(;u<20;++u)r=(r=f[u-3]^f[u-8]^f[u-14]^f[u-16])<<1|r>>>31,f[u]=r,r=(n<<5|n>>>27)+(s^a&(o^s))+c+1518500249+r,c=s,s=o,o=a<<30|a>>>2,a=n,n=r;for(;u<32;++u)r=(r=f[u-3]^f[u-8]^f[u-14]^f[u-16])<<1|r>>>31,f[u]=r,r=(n<<5|n>>>27)+(a^o^s)+c+1859775393+r,c=s,s=o,o=a<<30|a>>>2,a=n,n=r;for(;u<40;++u)r=(r=f[u-6]^f[u-16]^f[u-28]^f[u-32])<<2|r>>>30,f[u]=r,r=(n<<5|n>>>27)+(a^o^s)+c+1859775393+r,c=s,s=o,o=a<<30|a>>>2,a=n,n=r;for(;u<60;++u)r=(r=f[u-6]^f[u-16]^f[u-28]^f[u-32])<<2|r>>>30,f[u]=r,r=(n<<5|n>>>27)+(a&o|s&(a^o))+c+2400959708+r,c=s,s=o,o=a<<30|a>>>2,a=n,n=r;for(;u<80;++u)r=(r=f[u-6]^f[u-16]^f[u-28]^f[u-32])<<2|r>>>30,f[u]=r,r=(n<<5|n>>>27)+(a^o^s)+c+3395469782+r,c=s,s=o,o=a<<30|a>>>2,a=n,n=r;e.h0=e.h0+n|0,e.h1=e.h1+a|0,e.h2=e.h2+o|0,e.h3=e.h3+s|0,e.h4=e.h4+c|0,l-=64}return e},i._createState=function(){var e={h0:1732584193,h1:4023233417,h2:2562383102,h3:271733878,h4:3285377520,copy:function(){var t=i._createState();return t.h0=e.h0,t.h1=e.h1,t.h2=e.h2,t.h3=e.h3,t.h4=e.h4,t},write:function(t){t.putInt32(e.h0),t.putInt32(e.h1),t.putInt32(e.h2),t.putInt32(e.h3),t.putInt32(e.h4)}};return e};var a={_k:null,_w:null,Algorithm:function(){this.name="sha256",this.blockSize=64,this.digestLength=32,this.messageLengthSize=8}};a.Algorithm.prototype.start=function(){return a._k||a._init(),a._createState()},a.Algorithm.prototype.writeMessageLength=function(e,t){e.putBytes(t.bytes())},a.Algorithm.prototype.digest=function(e,t){for(var r,n,i,o,s,c,u,l,f,d,h,p,y,m=t.length(),g=a._k,b=a._w;m>=64;){for(s=0;s<16;++s)b[s]=t.getInt32();for(;s<64;++s)r=((r=b[s-2])>>>17|r<<15)^(r>>>19|r<<13)^r>>>10,n=((n=b[s-15])>>>7|n<<25)^(n>>>18|n<<14)^n>>>3,b[s]=r+b[s-7]+n+b[s-16]|0;for(c=e.h0,u=e.h1,l=e.h2,f=e.h3,d=e.h4,h=e.h5,p=e.h6,y=e.h7,s=0;s<64;++s)i=(c>>>2|c<<30)^(c>>>13|c<<19)^(c>>>22|c<<10),o=c&u|l&(c^u),r=y+((d>>>6|d<<26)^(d>>>11|d<<21)^(d>>>25|d<<7))+(p^d&(h^p))+g[s]+b[s],y=p,p=h,h=d,d=f+r|0,f=l,l=u,u=c,c=r+(n=i+o)|0;e.h0=e.h0+c|0,e.h1=e.h1+u|0,e.h2=e.h2+l|0,e.h3=e.h3+f|0,e.h4=e.h4+d|0,e.h5=e.h5+h|0,e.h6=e.h6+p|0,e.h7=e.h7+y|0,m-=64}return e},a._createState=function(){var e={h0:1779033703,h1:3144134277,h2:1013904242,h3:2773480762,h4:1359893119,h5:2600822924,h6:528734635,h7:1541459225,copy:function(){var t=a._createState();return t.h0=e.h0,t.h1=e.h1,t.h2=e.h2,t.h3=e.h3,t.h4=e.h4,t.h5=e.h5,t.h6=e.h6,t.h7=e.h7,t},write:function(t){t.putInt32(e.h0),t.putInt32(e.h1),t.putInt32(e.h2),t.putInt32(e.h3),t.putInt32(e.h4),t.putInt32(e.h5),t.putInt32(e.h6),t.putInt32(e.h7)}};return e},a._init=function(){a._k=[1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298],a._w=new Array(64)}}(c),!h)var Te=function(){h=r(34).XMLSerializer};function Oe(e,t){var r="";0===e.indexOf("/")&&(r="/");for(var n=e.split("/"),i=[];n.length>0;)"."===n[0]||""===n[0]&&n.length>1?n.shift():".."!==n[0]?i.push(n.shift()):(n.shift(),t||i.length>0&&".."!==i[i.length-1]?i.pop():i.push(".."));return r+i.join("/")}if(e.url={},e.url.parsers={simple:{keys:["href","scheme","authority","path","query","fragment"],regex:/^(?:([^:\/?#]+):)?(?:\/\/([^\/?#]*))?([^?#]*)(?:\?([^#]*))?(?:#(.*))?/},full:{keys:["href","protocol","scheme","authority","auth","user","password","hostname","port","path","directory","file","query","fragment"],regex:/^(([^:\/?#]+):)?(?:\/\/((?:(([^:@]*)(?::([^:@]*))?)?@)?([^:\/?#]*)(?::(\d*))?))?(?:(((?:[^?#\/]*\/)*)([^?#]*))(?:\?([^#]*))?(?:#(.*))?)/}},e.url.parse=function(t,r){for(var n={},i=e.url.parsers[r||"full"],a=i.regex.exec(t),o=i.keys.length;o--;)n[i.keys[o]]=void 0===a[o]?null:a[o];return n.normalizedPath=Oe(n.path,!!n.authority),n},c?e.useDocumentLoader("node"):"undefined"!=typeof XMLHttpRequest&&e.useDocumentLoader("xhr"),c){e.use=function(t){switch(t){case"request":e.request=r(34);break;default:throw new R("Unknown extension.","jsonld.UnknownExtension",{extension:t})}};var Ae={exports:{},filename:o};r(34)(Ae,"version"),e.version=Ae.exports.version}return e},f=function(){return l(function(){return f()})};!c&&r(560)?void 0===(s=function(){return l(f),f}.apply(t,[]))||(e.exports=s):(l(f),e.exports&&(e.exports=f),u&&("undefined"==typeof jsonld?jsonld=jsonldjs=f:jsonldjs=f))}()}).call(this,r(13),r(9),r(15).setImmediate,"/")},function(e,t){},function(e,t){(function(t){e.exports=t}).call(this,{})},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(562))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(213),i=r(194);t.ActorSparqlParseGraphql=class extends n.ActorSparqlParse{constructor(e){super(e),this.graphqlToSparql=new i.Converter({requireContext:!0})}async test(e){if("graphql"!==e.queryFormat)throw new Error("This actor can only parse GraphQL queries");return!0}async run(e){const t=e.context&&e.context.has("@context")?e.context.get("@context"):{},r={singularizeVariables:e.context.get("@comunica/actor-init-sparql:singularizeVariables")};return{operation:await this.graphqlToSparql.graphqlToSparqlAlgebra(e.query,t,r)}}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(564))},function(e,t,r){"use strict";(function(e){Object.defineProperty(t,"__esModule",{value:!0});const n=r(28),i=r(8),a=r(3);t.ActorSparqlSerializeJson=class extends n.ActorSparqlSerializeFixedMediaTypes{constructor(e){super(e)}async testHandleChecked(e,t){if(["bindings","quads","boolean"].indexOf(e.type)<0)throw new Error("This actor can only handle bindings or quad streams.");return!0}async runHandle(t,r,n){const o=new a.Readable;o._read=()=>{};let s=!0;if("bindings"===t.type){const e=t.bindingsStream;o.push("["),e.on("error",e=>o.emit("error",e)),e.on("data",e=>{o.push(s?"\n":",\n"),o.push(JSON.stringify(e.map(i.termToString))),s=!1}),e.on("end",()=>{o.push(s?"]\n":"\n]\n"),o.push(null)})}else if("quads"===t.type){const e=t.quadStream;o.push("["),e.on("error",e=>o.emit("error",e)),e.on("data",e=>{o.push(s?"\n":",\n"),o.push(JSON.stringify(i.quadToStringQuad(e))),s=!1}),e.on("end",()=>{o.push(s?"]\n":"\n]\n"),o.push(null)})}else try{o.push(JSON.stringify(await t.booleanResult)+"\n"),o.push(null)}catch(t){e(()=>o.emit("error",t))}return{data:o}}}}).call(this,r(15).setImmediate)},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(566))},function(e,t,r){"use strict";(function(e){Object.defineProperty(t,"__esModule",{value:!0});const n=r(28),i=r(3);t.ActorSparqlSerializeSimple=class extends n.ActorSparqlSerializeFixedMediaTypes{constructor(e){super(e)}async testHandleChecked(e,t){if(["bindings","quads","boolean"].indexOf(e.type)<0)throw new Error("This actor can only handle bindings streams, quad streams or booleans.");return!0}async runHandle(t,r,n){const a=new i.Readable;let o;if(a._read=()=>{},"bindings"===t.type)(o=t.bindingsStream).on("error",e=>a.emit("error",e)),o.on("data",e=>a.push(e.map((e,t)=>t+": "+e.value).join("\n")+"\n\n")),o.on("end",()=>a.push(null));else if("quads"===t.type)(o=t.quadStream).on("error",e=>a.emit("error",e)),o.on("data",e=>a.push("subject: "+e.subject.value+"\npredicate: "+e.predicate.value+"\nobject: "+e.object.value+"\ngraph: "+e.graph.value+"\n\n")),o.on("end",()=>a.push(null));else try{a.push(JSON.stringify(await t.booleanResult)+"\n"),a.push(null)}catch(t){e(()=>a.emit("error",t))}return{data:a}}}}).call(this,r(15).setImmediate)},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(568))},function(e,t,r){"use strict";(function(e){Object.defineProperty(t,"__esModule",{value:!0});const n=r(28),i=r(3);class a extends n.ActorSparqlSerializeFixedMediaTypes{constructor(e){super(e)}static bindingToJsonBindings(e){if("Literal"===e.termType){const t=e,r={value:t.value,type:"literal"},n=t.language,i=t.datatype;return n?r["xml:lang"]=n:i&&"http://www.w3.org/2001/XMLSchema#string"!==i.value&&(r.datatype=i.value),r}return"BlankNode"===e.termType?{value:e.value,type:"bnode"}:{value:e.value,type:"uri"}}async testHandleChecked(e,t){if(["bindings","boolean"].indexOf(e.type)<0)throw new Error("This actor can only handle bindings streams or booleans.");return!0}async runHandle(t,r,n){const o=new i.Readable;o._read=()=>{};const s={};"bindings"===t.type&&t.variables.length&&(s.vars=t.variables.map(e=>e.substr(1))),o.push('{"head": '+JSON.stringify(s)+",\n");let c=!0;if("bindings"===t.type){const e=t.bindingsStream;e.on("error",e=>{o.emit("error",e)}),e.on("data",e=>{c?o.push('"results": { "bindings": [\n'):o.push(",\n");const t=e.filter((e,t)=>!!e&&t.startsWith("?"));o.push(JSON.stringify(t.mapEntries(([e,t])=>[e.substr(1),a.bindingToJsonBindings(t)]).toJSON())),c=!1}),e.on("end",()=>{c?o.push('"results": { "bindings": [] }}\n'):o.push("\n]}}\n"),o.push(null)})}else try{o.push('"boolean":'+await t.booleanResult+"\n}\n"),o.push(null)}catch(t){e(()=>o.emit("error",t))}return{data:o}}}t.ActorSparqlSerializeSparqlJson=a}).call(this,r(15).setImmediate)},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(570))},function(e,t,r){"use strict";(function(e){Object.defineProperty(t,"__esModule",{value:!0});const n=r(28),i=r(3),a=r(571);class o extends n.ActorSparqlSerializeFixedMediaTypes{constructor(e){super(e)}static bindingToXmlBindings(e,t){let r;if("Literal"===e.termType){const t=e;r={literal:t.value};const n=t.language,i=t.datatype;n?r.literal=[{_attr:{"xml:lang":n}},r.literal]:i&&"http://www.w3.org/2001/XMLSchema#string"!==i.value&&(r.literal=[{_attr:{datatype:i.value}},r.literal])}else r="BlankNode"===e.termType?{bnode:e.value}:{uri:e.value};return{binding:[{_attr:{name:t.substring(1)}},r]}}async testHandleChecked(e,t){if(["bindings","boolean"].indexOf(e.type)<0)throw new Error("This actor can only handle bindings streams or booleans.");return!0}async runHandle(t,r,n){const s=new i.Readable;s._read=()=>{};const c=a.element({_attr:{xlmns:"http://www.w3.org/2005/sparql-results#"}});if(a({sparql:c},{stream:!0,indent:" ",declaration:!0}).on("data",e=>s.push(e+"\n")),"bindings"===t.type&&t.variables.length&&c.push({head:t.variables.map(e=>({variable:{_attr:{name:e.substr(1)}}}))}),"bindings"===t.type){const e=a.element({});c.push({results:e});const r=t.bindingsStream;r.on("error",e=>{s.emit("error",e)}),r.on("data",t=>{const r=t.filter((e,t)=>!!e&&t.startsWith("?"));e.push({result:r.map(o.bindingToXmlBindings)})}),r.on("end",()=>{e.close(),c.close(),s.push(null)})}else try{c.push({boolean:await t.booleanResult}),c.close(),e(()=>s.push(null))}catch(t){e(()=>s.emit("error",t))}return{data:s}}}t.ActorSparqlSerializeSparqlXml=o}).call(this,r(15).setImmediate)},function(e,t,r){(function(t){var n=r(572),i=r(3).Stream,a=" ";function o(e,t,r){r=r||0;var i,a,s=(i=t,new Array(r||0).join(i||"")),c=e;if("object"==typeof e&&((c=e[a=Object.keys(e)[0]])&&c._elem))return c._elem.name=a,c._elem.icount=r,c._elem.indent=t,c._elem.indents=s,c._elem.interrupt=c,c._elem;var u,l=[],f=[];function d(e){Object.keys(e).forEach(function(t){l.push(function(e,t){return e+'="'+n(t)+'"'}(t,e[t]))})}switch(typeof c){case"object":if(null===c)break;c._attr&&d(c._attr),c._cdata&&f.push(("<![CDATA["+c._cdata).replace(/\]\]>/g,"]]]]><![CDATA[>")+"]]>"),c.forEach&&(u=!1,f.push(""),c.forEach(function(e){"object"==typeof e?"_attr"==Object.keys(e)[0]?d(e._attr):f.push(o(e,t,r+1)):(f.pop(),u=!0,f.push(n(e)))}),u||f.push(""));break;default:f.push(n(c))}return{name:a,interrupt:!1,attributes:l,content:f,icount:r,indents:s,indent:t}}function s(e,t,r){if("object"!=typeof t)return e(!1,t);var n=t.interrupt?1:t.content.length;function i(){for(;t.content.length;){var i=t.content.shift();if(void 0!==i){if(a(i))return;s(e,i)}}e(!1,(n>1?t.indents:"")+(t.name?"</"+t.name+">":"")+(t.indent&&!r?"\n":"")),r&&r()}function a(t){return!!t.interrupt&&(t.interrupt.append=e,t.interrupt.end=i,t.interrupt=!1,e(!0),!0)}if(e(!1,t.indents+(t.name?"<"+t.name:"")+(t.attributes.length?" "+t.attributes.join(" "):"")+(n?t.name?">":"":t.name?"/>":"")+(t.indent&&n>1?"\n":"")),!n)return e(!1,t.indent?"\n":"");a(t)||i()}e.exports=function(e,r){"object"!=typeof r&&(r={indent:r});var n,c,u=r.stream?new i:null,l="",f=!1,d=r.indent?!0===r.indent?a:r.indent:"",h=!0;function p(e){h?t.nextTick(e):e()}function y(e,t){if(void 0!==t&&(l+=t),e&&!f&&(u=u||new i,f=!0),e&&f){var r=l;p(function(){u.emit("data",r)}),l=""}}function m(e,t){s(y,o(e,d,d?1:0),t)}function g(){if(u){var e=l;p(function(){u.emit("data",e),u.emit("end"),u.readable=!1,u.emit("close")})}}return p(function(){h=!1}),r.declaration&&(n=r.declaration,c={version:"1.0",encoding:n.encoding||"UTF-8"},n.standalone&&(c.standalone=n.standalone),m({"?xml":{_attr:c}}),l=l.replace("/>","?>")),e&&e.forEach?e.forEach(function(t,r){var n;r+1===e.length&&(n=g),m(t,n)}):m(e,g),u?(u.readable=!0,u):l},e.exports.element=e.exports.Element=function(){var e={_elem:o(Array.prototype.slice.call(arguments)),push:function(e){if(!this.append)throw new Error("not assigned to a parent!");var t=this,r=this._elem.indent;s(this.append,o(e,r,this._elem.icount+(r?1:0)),function(){t.append(!0)})},close:function(e){void 0!==e&&this.push(e),this.end&&this.end()}};return e}}).call(this,r(13))},function(e,t){var r={"&":"&amp;",'"':"&quot;","'":"&apos;","<":"&lt;",">":"&gt;"};e.exports=function(e){return e&&e.replace?e.replace(/([&"<>'])/g,function(e,t){return r[t]}):e}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(574))},function(e,t,r){"use strict";(function(e){Object.defineProperty(t,"__esModule",{value:!0});const n=r(28),i=r(3);t.ActorSparqlSerializeStats=class extends n.ActorSparqlSerializeFixedMediaTypes{constructor(e){super(e)}async testHandleChecked(e,t){if(["bindings","quads"].indexOf(e.type)<0)throw new Error("This actor can only handle bindings streams or quad streams.");return!0}pushHeader(e){const t=["Result","Delay (ms)"].join(",");e.push(t+"\n")}pushStat(e,t,r){const n=[r,this.delay(t)].join(",");e.push(n+"\n")}pushFooter(e,t){const r=["TOTAL",this.delay(t)].join(",");e.push(r+"\n"),e.push(null)}async runHandle(t,r,n){const a=new i.Readable;a._read=()=>{};const o="bindings"===t.type?t.bindingsStream:t.quadStream,s=e.hrtime();let c=1;return this.pushHeader(a),o.on("error",e=>a.emit("error",e)),o.on("data",()=>this.pushStat(a,s,c++)),o.on("end",()=>this.pushFooter(a,s)),{data:a}}delay(t){const r=e.hrtime(t);return 1e3*r[0]+r[1]/1e6}}}).call(this,r(13))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(576))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(28),i=r(27),a=r(3);class o extends n.ActorSparqlSerializeFixedMediaTypes{constructor(e){super(e),this.padding=o.repeat(" ",this.columnWidth)}static repeat(e,t){return new Array(t+1).join(e)}async testHandleChecked(e,t){if(["bindings","quads"].indexOf(e.type)<0)throw new Error("This actor can only handle bindings or quad streams.");return!0}pad(e){return e.length<=this.columnWidth?e+this.padding.slice(e.length):e.slice(0,this.columnWidth-1)+"…"}pushHeader(e,t){const r=t.map(this.pad,this).join(" ");e.push(r+"\n"+o.repeat("-",r.length)+"\n")}async runHandle(e,t,r){const n=new a.Readable;let o;return n._read=()=>{},"bindings"===e.type?(o=e.bindingsStream,this.pushHeader(n,e.variables),o.on("error",e=>n.emit("error",e)),o.on("data",e=>n.push(e.map((e,t)=>this.pad(e?e.value:"")).join(" ")+"\n"))):(o=e.quadStream,this.pushHeader(n,i.QUAD_TERM_NAMES),o.on("error",e=>n.emit("error",e)),o.on("data",e=>n.push(i.getTerms(e).map(e=>this.pad(e.value)).join(" ")+"\n"))),o.on("end",()=>n.push(null)),{data:n}}}t.ActorSparqlSerializeTable=o},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(578))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(37);r(48);const i=r(234);t.ActorHttpMemento=class extends n.ActorHttp{constructor(e){super(e)}async test(e){if(!(e.context&&e.context.has(t.KEY_CONTEXT_DATETIME)&&e.context.get(t.KEY_CONTEXT_DATETIME)instanceof Date))throw new Error("This actor only handles request with a set valid datetime.");if(e.init&&new Headers(e.init.headers||{}).has("accept-datetime"))throw new Error("The request already has a set datetime.");return!0}async run(e){const r=e.init?Object.assign({},e.init):{},n=r.headers=new Headers(r.headers||{});e.context&&e.context.has(t.KEY_CONTEXT_DATETIME)&&n.append("accept-datetime",e.context.get(t.KEY_CONTEXT_DATETIME).toUTCString());const a={context:e.context,input:e.input,init:r},o=await this.mediatorHttp.mediate(a);if(n.has("accept-datetime")&&o.headers&&!o.headers.has("memento-datetime")){const t=o.headers.has("link")&&i(o.headers.get("link"));if(t&&t.timegate){o.body.cancel();const n={context:e.context,input:t.timegate.url,init:r};return this.mediatorHttp.mediate(n)}}return o}},t.KEY_CONTEXT_DATETIME="@comunica/actor-http-memento:datetime"},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}(r(580))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(28);t.ActorSparqlSerializeRdf=class extends n.ActorSparqlSerialize{constructor(e){super(e)}async testHandle(e,t,r){if("quads"!==e.type)throw new Error("Actor "+this.name+" can only handle quad streams");const n=(await this.mediatorMediaTypeCombiner.mediate({context:r,mediaTypes:!0})).mediaTypes;if(!(t in n))throw new Error("Actor "+this.name+" can not handle media type "+t+". All available types: "+Object.keys(n));return!0}async runHandle(e,t,r){return(await this.mediatorRdfSerialize.mediate({context:r,handle:{quads:e.quadStream},handleMediaType:t})).handle}async testMediaType(e){return!0}async getMediaTypes(e){return(await this.mediatorMediaTypeCombiner.mediate({context:e,mediaTypes:!0})).mediaTypes}}},function(e,t,r){"use strict";function n(e){for(var r in e)t.hasOwnProperty(r)||(t[r]=e[r])}Object.defineProperty(t,"__esModule",{value:!0}),n(r(582)),n(r(583))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(37);t.ActorHttpProxy=class extends n.ActorHttp{constructor(e){super(e)}async test(e){const r=e.context.get(t.KEY_CONTEXT_HTTPPROXYHANDLER);if(!r)throw new Error(`Actor ${this.name} could not find a proxy handler in the context.`);if(!await r.getProxy(e))throw new Error(`Actor ${this.name} could not determine a proxy for the given request.`);return{time:1/0}}async run(e){const r="string"==typeof e.input?e.input:e.input.url,n=e.context.get(t.KEY_CONTEXT_HTTPPROXYHANDLER),i=await this.mediatorHttp.mediate(Object.assign({},await n.getProxy(e),{context:e.context.delete(t.KEY_CONTEXT_HTTPPROXYHANDLER)}));return i.url=i.headers.get("x-final-url")||r,i}},t.KEY_CONTEXT_HTTPPROXYHANDLER="@comunica/actor-http-proxy:httpProxyHandler"},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});t.ProxyHandlerStatic=class{constructor(e){this.prefixUrl=e}async getProxy(e){return{init:e.init,input:this.modifyInput(e.input)}}modifyInput(e){return"string"==typeof e?this.prefixUrl+e:new Request(this.prefixUrl+e.url,e)}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(4);t.ActorQueryOperationAsk=class extends n.ActorQueryOperationTypedMediated{constructor(e){super(e,"ask")}async testOperation(e,t){return!0}async runOperation(e,t){const r=await this.mediatorQueryOperation.mediate({operation:e.input,context:t}),i=n.ActorQueryOperation.getSafeBindings(r);return{type:"boolean",booleanResult:new Promise((e,t)=>{i.bindingsStream.once("data",()=>{e(!0),i.bindingsStream.close()}),i.bindingsStream.on("end",()=>e(!1)),i.bindingsStream.on("error",t)})}}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(4),i=r(26),a=r(0),o=r(6),s=r(231);t.ActorQueryOperationService=class extends n.ActorQueryOperationTypedMediated{constructor(e){super(e,"service")}async testOperation(e,t){if("NamedNode"!==e.name.termType)throw new Error(`${this.name} can only query services by IRI, while a ${e.name.termType} was given.`);return!0}async runOperation(e,t){const r=e.name.value;let c=(t=t||a.ActionContext({})).delete(i.KEY_CONTEXT_SOURCE).delete(i.KEY_CONTEXT_SOURCES);const u=this.forceSparqlEndpoint?"sparql":"auto";let l;c=c.set(i.KEY_CONTEXT_SOURCES,s.AsyncReiterableArray.fromFixedData([{type:u,value:r}]));try{l=n.ActorQueryOperation.getSafeBindings(await this.mediatorQueryOperation.mediate({operation:e.input,context:c}))}catch(t){if(!e.silent)throw t;l={bindingsStream:new o.SingletonIterator(n.Bindings({})),type:"bindings",variables:[]}}return l}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(4);t.ActorQueryOperationSlice=class extends n.ActorQueryOperationTypedMediated{constructor(e){super(e,"slice")}async testOperation(e,t){return!0}async runOperation(e,t){const r=n.ActorQueryOperation.getSafeBindings(await this.mediatorQueryOperation.mediate({operation:e.input,context:t})),i=!!e.length||0===e.length;return{type:"bindings",bindingsStream:r.bindingsStream.range(e.start,i?e.start+e.length-1:1/0),metadata:r.metadata?()=>r.metadata().then(t=>{let r=t.totalItems;return isFinite(r)&&(r=Math.max(0,r-e.start),i&&(r=Math.min(r,e.length))),Object.assign({},t,{totalItems:r})}):null,variables:r.variables}}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(4);t.ActorQueryOperationBgpSingle=class extends n.ActorQueryOperationTypedMediated{constructor(e){super(e,"bgp")}async testOperation(e,t){if(1!==e.patterns.length)throw new Error("Actor "+this.name+" can only operate on BGPs with a single pattern.");return!0}runOperation(e,t){if(t&&t.has(n.KEY_CONTEXT_BGP_PARENTMETADATA)){const e=t.get(n.KEY_CONTEXT_BGP_PARENTMETADATA);t=(t=t.delete(n.KEY_CONTEXT_BGP_PARENTMETADATA)).set(n.KEY_CONTEXT_PATTERN_PARENTMETADATA,e[0])}return this.mediatorQueryOperation.mediate({operation:e.patterns[0],context:t})}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(4),i=r(6),a=r(33),o=r(8),s=r(27);class c extends n.ActorQueryOperationTypedMediated{constructor(e){super(e,"bgp")}static createLeftDeepStream(e,t,r){const n=new i.MultiTransformIterator(e);return n._createTransformer=e=>{const n=t=>t.merge(e);return new a.PromiseProxyIterator(async()=>(await r(c.materializePatterns(t,e))).map(n),{autoStart:!0,maxBufferSize:128})},n}static getCombinedVariables(e){return r(244)([].concat.apply([],e.map(e=>e.variables)))}static getSmallestPatternId(e){let t=-1,r=1/0;for(let n=0;n<e.length;n++){const i=e[n],a=c.getTotalItems(i);a<=r&&(r=a,t=n)}return t}static estimateCombinedTotalItems(e,t){const r=c.getTotalItems(e);return t.map(e=>r*c.getTotalItems(e)).reduce((e,t)=>e+t,0)}static getTotalItems(e){const t=(e||{}).totalItems;return t||0===t?t:1/0}static materializePatterns(e,t){return e.map(e=>c.materializePattern(e,t))}static materializePattern(e,t){const r={};return{pattern:Object.assign(s.mapTerms(e,(e,n)=>{const i=c.materializeTerm(e,t);return e!==i&&(r[n]=e),i}),{type:"pattern"}),bindings:r}}static materializeTerm(e,t){if("Variable"===e.termType){const r=t.get(o.termToString(e));if(r)return r}return e}static async hasOneEmptyPatternOutput(e){for(const t of e)if(t.metadata){const e=await t.metadata();if(!c.getTotalItems(e))return!0}return!1}async testOperation(e,t){if(e.patterns.length<2)throw new Error("Actor "+this.name+" can only operate on BGPs with at least two patterns.");return!0}async runOperation(e,t){const r=(await Promise.all(e.patterns.map(e=>this.mediatorQueryOperation.mediate({operation:e,context:t})))).map(n.ActorQueryOperation.getSafeBindings);if(await c.hasOneEmptyPatternOutput(r))return{bindingsStream:new i.EmptyIterator,metadata:()=>Promise.resolve({totalItems:0}),type:"bindings",variables:[]};const a=await Promise.all(r.map(async e=>e.metadata?await e.metadata():{})),o=c.getSmallestPatternId(a);this.logDebug(t,"Smallest pattern: ",{pattern:e.patterns[o],metadata:a[o]});for(let e=0;e<r.length;e++)e!==o&&r[e].bindingsStream.close();const s=r.slice(o)[0],u=e.patterns.concat([]);u.splice(o,1);const l=a.concat([]);l.splice(o,1),n.ActorQueryOperation.validateQueryOutput(s,"bindings");const f=t&&t.set(n.KEY_CONTEXT_BGP_CURRENTMETADATA,a[o]).set(n.KEY_CONTEXT_BGP_PARENTMETADATA,l);return{type:"bindings",bindingsStream:c.createLeftDeepStream(s.bindingsStream,u,async e=>{const t={type:"bgp",patterns:e.map(e=>e.pattern)},r=e.map(e=>e.bindings);return n.ActorQueryOperation.getSafeBindings(await this.mediatorQueryOperation.mediate({operation:t,context:f.set(n.KEY_CONTEXT_BGP_PATTERNBINDINGS,r)})).bindingsStream}),variables:c.getCombinedVariables(r),metadata:()=>Promise.resolve({totalItems:c.estimateCombinedTotalItems(a[o],a.slice(o))})}}}t.ActorQueryOperationBgpLeftDeepSmallest=c},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(4),i=r(27),a=r(590);class o extends n.ActorQueryOperationTypedMediated{constructor(e){super(e,"construct")}static getVariables(e){return i.uniqTerms([].concat.apply([],e.map(e=>i.getVariables(i.getTerms(e)))))}async testOperation(e,t){return!0}async runOperation(e,t){const r=o.getVariables(e.template),i={type:"project",input:e.input,variables:r},s=n.ActorQueryOperation.getSafeBindings(await this.mediatorQueryOperation.mediate({operation:i,context:t})),c=new a.BindingsToQuadsIterator(e.template,s.bindingsStream);let u=null;return s.metadata&&(u=()=>s.metadata().then(t=>t?t.totalItems?Object.assign({},t,{totalItems:t.totalItems*e.template.length}):t:null)),{metadata:u,quadStream:c,type:"quads"}}}t.ActorQueryOperationConstruct=o},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(5),i=r(6),a=r(27);class o extends i.MultiTransformIterator{constructor(e,t){super(t),this.template=e,this.blankNodeCounter=0}static bindTerm(e,t){return"Variable"===t.termType?e.get("?"+t.value):t}static bindQuad(e,t){try{return a.mapTerms(t,t=>{const r=o.bindTerm(e,t);if(!r)throw new Error("Unbound term");return r})}catch(e){return null}}static localizeBlankNode(e,t){return"BlankNode"===t.termType?n.blankNode(t.value+e):t}static localizeQuad(e,t){return a.mapTerms(t,t=>o.localizeBlankNode(e,t))}static bindTemplate(e,t,r){return t.map(o.bindQuad.bind(null,e)).filter(e=>!!e).map(o.localizeQuad.bind(null,r))}_createTransformer(e){return new i.ArrayIterator(o.bindTemplate(e,this.template,this.blankNodeCounter++))}}t.BindingsToQuadsIterator=o},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(100),i=r(4),a=r(5),o=r(76);t.ActorQueryOperationDescribeSubject=class extends i.ActorQueryOperationTypedMediated{constructor(e){super(e,"describe")}async testOperation(e,t){return!0}async runOperation(e,t){const r=e.terms.filter(e=>"Variable"!==e.termType).map(e=>{const t=[a.triple(e,a.variable("__predicate"),a.variable("__object"))];return t.forEach(e=>e.type="pattern"),{input:{type:"bgp",patterns:t},template:t,type:"construct"}});if(r.length!==e.terms.length){let t=[];e.terms.filter(e=>"Variable"===e.termType).forEach((e,r)=>{const n=[a.triple(e,a.variable("__predicate"+r),a.variable("__object"+r))];n.forEach(e=>e.type="pattern"),t=t.concat(n)}),r.push({input:{type:"join",left:e.input,right:{type:"bgp",patterns:t}},template:t,type:"construct"})}const s=(await Promise.all(r.map(e=>this.mediatorQueryOperation.mediate({operation:e,context:t})))).map(i.ActorQueryOperation.getSafeQuads);return{type:"quads",quadStream:new o.RoundRobinUnionIterator(s.map(e=>e.quadStream)),metadata:()=>Promise.all(s.map(e=>e.metadata).filter(e=>!!e).map(e=>e())).then(n.ActorQueryOperationUnion.unionMetadata)}}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(4),i=r(76);class a extends n.ActorQueryOperationTypedMediated{constructor(e){super(e,"union")}static unionVariables(e){return r(150).apply({},e)}static unionMetadata(e){let t=0;for(const r of e){if(!r.totalItems||!isFinite(r.totalItems)){t=1/0;break}t+=r.totalItems}return{totalItems:t}}async testOperation(e,t){return!0}async runOperation(e,t){const r=(await Promise.all([this.mediatorQueryOperation.mediate({operation:e.left,context:t}),this.mediatorQueryOperation.mediate({operation:e.right,context:t})])).map(n.ActorQueryOperation.getSafeBindings);return{type:"bindings",bindingsStream:new i.RoundRobinUnionIterator(r.map(e=>e.bindingsStream)),metadata:r[0].metadata&&r[1].metadata?()=>Promise.all([r[0].metadata(),r[1].metadata()]).then(a.unionMetadata):null,variables:a.unionVariables(r.map(e=>e.variables))}}}t.ActorQueryOperationUnion=a},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(77);t.ActorQueryOperationDistinctHash=class extends n.AbstractBindingHash{constructor(e){super(e,"distinct")}newHashFilter(e,t){const r={};return i=>{const a=n.AbstractFilterHash.hash(e,t,i);return!(a in r)&&(r[a]=!0)}}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(4),i=r(248);t.AbstractBindingHash=class extends n.ActorQueryOperationTypedMediated{constructor(e,t){if(super(e,t),!i.AbstractFilterHash.doesHashAlgorithmExist(this.hashAlgorithm))throw new Error("The given hash algorithm is not present in this version of Node: "+this.hashAlgorithm);if(!i.AbstractFilterHash.doesDigestAlgorithmExist(this.digestAlgorithm))throw new Error("The given digest algorithm is not present in this version of Node: "+this.digestAlgorithm)}async testOperation(e,t){return!0}async runOperation(e,t){const r=n.ActorQueryOperation.getSafeBindings(await this.mediatorQueryOperation.mediate({operation:e.input,context:t}));return{type:"bindings",bindingsStream:r.bindingsStream.filter(this.newHashFilter(this.hashAlgorithm,this.digestAlgorithm)),metadata:r.metadata,variables:r.variables}}}},function(e,t,r){"use strict";t.randomBytes=t.rng=t.pseudoRandomBytes=t.prng=r(43),t.createHash=t.Hash=r(44),t.createHmac=t.Hmac=r(252);var n=r(601),i=Object.keys(n),a=["sha1","sha224","sha256","sha384","sha512","md5","rmd160"].concat(i);t.getHashes=function(){return a};var o=r(255);t.pbkdf2=o.pbkdf2,t.pbkdf2Sync=o.pbkdf2Sync;var s=r(603);t.Cipher=s.Cipher,t.createCipher=s.createCipher,t.Cipheriv=s.Cipheriv,t.createCipheriv=s.createCipheriv,t.Decipher=s.Decipher,t.createDecipher=s.createDecipher,t.Decipheriv=s.Decipheriv,t.createDecipheriv=s.createDecipheriv,t.getCiphers=s.getCiphers,t.listCiphers=s.listCiphers;var c=r(620);t.DiffieHellmanGroup=c.DiffieHellmanGroup,t.createDiffieHellmanGroup=c.createDiffieHellmanGroup,t.getDiffieHellman=c.getDiffieHellman,t.createDiffieHellman=c.createDiffieHellman,t.DiffieHellman=c.DiffieHellman;var u=r(625);t.createSign=u.createSign,t.Sign=u.Sign,t.createVerify=u.createVerify,t.Verify=u.Verify,t.createECDH=r(659);var l=r(660);t.publicEncrypt=l.publicEncrypt,t.privateEncrypt=l.privateEncrypt,t.publicDecrypt=l.publicDecrypt,t.privateDecrypt=l.privateDecrypt;var f=r(663);t.randomFill=f.randomFill,t.randomFillSync=f.randomFillSync,t.createCredentials=function(){throw new Error(["sorry, createCredentials is not implemented yet","we accept pull requests","https://github.com/crypto-browserify/crypto-browserify"].join("\n"))},t.constants={DH_CHECK_P_NOT_SAFE_PRIME:2,DH_CHECK_P_NOT_PRIME:1,DH_UNABLE_TO_CHECK_GENERATOR:4,DH_NOT_SUITABLE_GENERATOR:8,NPN_ENABLED:1,ALPN_ENABLED:1,RSA_PKCS1_PADDING:1,RSA_SSLV23_PADDING:2,RSA_NO_PADDING:3,RSA_PKCS1_OAEP_PADDING:4,RSA_X931_PADDING:5,RSA_PKCS1_PSS_PADDING:6,POINT_CONVERSION_COMPRESSED:2,POINT_CONVERSION_UNCOMPRESSED:4,POINT_CONVERSION_HYBRID:6}},function(e,t,r){var n=r(1),i=r(45),a=r(2).Buffer,o=[1518500249,1859775393,-1894007588,-899497514],s=new Array(80);function c(){this.init(),this._w=s,i.call(this,64,56)}function u(e){return e<<30|e>>>2}function l(e,t,r,n){return 0===e?t&r|~t&n:2===e?t&r|t&n|r&n:t^r^n}n(c,i),c.prototype.init=function(){return this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520,this},c.prototype._update=function(e){for(var t,r=this._w,n=0|this._a,i=0|this._b,a=0|this._c,s=0|this._d,c=0|this._e,f=0;f<16;++f)r[f]=e.readInt32BE(4*f);for(;f<80;++f)r[f]=r[f-3]^r[f-8]^r[f-14]^r[f-16];for(var d=0;d<80;++d){var h=~~(d/20),p=0|((t=n)<<5|t>>>27)+l(h,i,a,s)+c+r[d]+o[h];c=s,s=a,a=u(i),i=n,n=p}this._a=n+this._a|0,this._b=i+this._b|0,this._c=a+this._c|0,this._d=s+this._d|0,this._e=c+this._e|0},c.prototype._hash=function(){var e=a.allocUnsafe(20);return e.writeInt32BE(0|this._a,0),e.writeInt32BE(0|this._b,4),e.writeInt32BE(0|this._c,8),e.writeInt32BE(0|this._d,12),e.writeInt32BE(0|this._e,16),e},e.exports=c},function(e,t,r){var n=r(1),i=r(45),a=r(2).Buffer,o=[1518500249,1859775393,-1894007588,-899497514],s=new Array(80);function c(){this.init(),this._w=s,i.call(this,64,56)}function u(e){return e<<5|e>>>27}function l(e){return e<<30|e>>>2}function f(e,t,r,n){return 0===e?t&r|~t&n:2===e?t&r|t&n|r&n:t^r^n}n(c,i),c.prototype.init=function(){return this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520,this},c.prototype._update=function(e){for(var t,r=this._w,n=0|this._a,i=0|this._b,a=0|this._c,s=0|this._d,c=0|this._e,d=0;d<16;++d)r[d]=e.readInt32BE(4*d);for(;d<80;++d)r[d]=(t=r[d-3]^r[d-8]^r[d-14]^r[d-16])<<1|t>>>31;for(var h=0;h<80;++h){var p=~~(h/20),y=u(n)+f(p,i,a,s)+c+r[h]+o[p]|0;c=s,s=a,a=l(i),i=n,n=y}this._a=n+this._a|0,this._b=i+this._b|0,this._c=a+this._c|0,this._d=s+this._d|0,this._e=c+this._e|0},c.prototype._hash=function(){var e=a.allocUnsafe(20);return e.writeInt32BE(0|this._a,0),e.writeInt32BE(0|this._b,4),e.writeInt32BE(0|this._c,8),e.writeInt32BE(0|this._d,12),e.writeInt32BE(0|this._e,16),e},e.exports=c},function(e,t,r){var n=r(1),i=r(250),a=r(45),o=r(2).Buffer,s=new Array(64);function c(){this.init(),this._w=s,a.call(this,64,56)}n(c,i),c.prototype.init=function(){return this._a=3238371032,this._b=914150663,this._c=812702999,this._d=4144912697,this._e=4290775857,this._f=1750603025,this._g=1694076839,this._h=3204075428,this},c.prototype._hash=function(){var e=o.allocUnsafe(28);return e.writeInt32BE(this._a,0),e.writeInt32BE(this._b,4),e.writeInt32BE(this._c,8),e.writeInt32BE(this._d,12),e.writeInt32BE(this._e,16),e.writeInt32BE(this._f,20),e.writeInt32BE(this._g,24),e},e.exports=c},function(e,t,r){var n=r(1),i=r(251),a=r(45),o=r(2).Buffer,s=new Array(160);function c(){this.init(),this._w=s,a.call(this,128,112)}n(c,i),c.prototype.init=function(){return this._ah=3418070365,this._bh=1654270250,this._ch=2438529370,this._dh=355462360,this._eh=1731405415,this._fh=2394180231,this._gh=3675008525,this._hh=1203062813,this._al=3238371032,this._bl=914150663,this._cl=812702999,this._dl=4144912697,this._el=4290775857,this._fl=1750603025,this._gl=1694076839,this._hl=3204075428,this},c.prototype._hash=function(){var e=o.allocUnsafe(48);function t(t,r,n){e.writeInt32BE(t,n),e.writeInt32BE(r,n+4)}return t(this._ah,this._al,0),t(this._bh,this._bl,8),t(this._ch,this._cl,16),t(this._dh,this._dl,24),t(this._eh,this._el,32),t(this._fh,this._fl,40),e},e.exports=c},function(e,t,r){"use strict";var n=r(1),i=r(2).Buffer,a=r(29),o=i.alloc(128),s=64;function c(e,t){a.call(this,"digest"),"string"==typeof t&&(t=i.from(t)),this._alg=e,this._key=t,t.length>s?t=e(t):t.length<s&&(t=i.concat([t,o],s));for(var r=this._ipad=i.allocUnsafe(s),n=this._opad=i.allocUnsafe(s),c=0;c<s;c++)r[c]=54^t[c],n[c]=92^t[c];this._hash=[r]}n(c,a),c.prototype._update=function(e){this._hash.push(e)},c.prototype._final=function(){var e=this._alg(i.concat(this._hash));return this._alg(i.concat([this._opad,e]))},e.exports=c},function(e,t,r){e.exports=r(254)},function(e,t,r){(function(t,n){var i,a=r(256),o=r(257),s=r(258),c=r(2).Buffer,u=t.crypto&&t.crypto.subtle,l={sha:"SHA-1","sha-1":"SHA-1",sha1:"SHA-1",sha256:"SHA-256","sha-256":"SHA-256",sha384:"SHA-384","sha-384":"SHA-384","sha-512":"SHA-512",sha512:"SHA-512"},f=[];function d(e,t,r,n,i){return u.importKey("raw",e,{name:"PBKDF2"},!1,["deriveBits"]).then(function(e){return u.deriveBits({name:"PBKDF2",salt:t,iterations:r,hash:{name:i}},e,n<<3)}).then(function(e){return c.from(e)})}e.exports=function(e,r,h,p,y,m){"function"==typeof y&&(m=y,y=void 0);var g=l[(y=y||"sha1").toLowerCase()];if(!g||"function"!=typeof t.Promise)return n.nextTick(function(){var t;try{t=s(e,r,h,p,y)}catch(e){return m(e)}m(null,t)});if(a(e,r,h,p),"function"!=typeof m)throw new Error("No callback provided to pbkdf2");c.isBuffer(e)||(e=c.from(e,o)),c.isBuffer(r)||(r=c.from(r,o)),function(e,t){e.then(function(e){n.nextTick(function(){t(null,e)})},function(e){n.nextTick(function(){t(e)})})}(function(e){if(t.process&&!t.process.browser)return Promise.resolve(!1);if(!u||!u.importKey||!u.deriveBits)return Promise.resolve(!1);if(void 0!==f[e])return f[e];var r=d(i=i||c.alloc(8),i,10,128,e).then(function(){return!0}).catch(function(){return!1});return f[e]=r,r}(g).then(function(t){return t?d(e,r,h,p,g):s(e,r,h,p,y)}),m)}}).call(this,r(9),r(13))},function(e,t,r){var n=r(604),i=r(105),a=r(106),o=r(619),s=r(79);function c(e,t,r){if(e=e.toLowerCase(),a[e])return i.createCipheriv(e,t,r);if(o[e])return new n({key:t,iv:r,mode:e});throw new TypeError("invalid suite type")}function u(e,t,r){if(e=e.toLowerCase(),a[e])return i.createDecipheriv(e,t,r);if(o[e])return new n({key:t,iv:r,mode:e,decrypt:!0});throw new TypeError("invalid suite type")}t.createCipher=t.Cipher=function(e,t){var r,n;if(e=e.toLowerCase(),a[e])r=a[e].key,n=a[e].iv;else{if(!o[e])throw new TypeError("invalid suite type");r=8*o[e].key,n=o[e].iv}var i=s(t,!1,r,n);return c(e,i.key,i.iv)},t.createCipheriv=t.Cipheriv=c,t.createDecipher=t.Decipher=function(e,t){var r,n;if(e=e.toLowerCase(),a[e])r=a[e].key,n=a[e].iv;else{if(!o[e])throw new TypeError("invalid suite type");r=8*o[e].key,n=o[e].iv}var i=s(t,!1,r,n);return u(e,i.key,i.iv)},t.createDecipheriv=t.Decipheriv=u,t.listCiphers=t.getCiphers=function(){return Object.keys(o).concat(i.getCiphers())}},function(e,t,r){var n=r(29),i=r(104),a=r(1),o=r(2).Buffer,s={"des-ede3-cbc":i.CBC.instantiate(i.EDE),"des-ede3":i.EDE,"des-ede-cbc":i.CBC.instantiate(i.EDE),"des-ede":i.EDE,"des-cbc":i.CBC.instantiate(i.DES),"des-ecb":i.DES};function c(e){n.call(this);var t,r=e.mode.toLowerCase(),i=s[r];t=e.decrypt?"decrypt":"encrypt";var a=e.key;o.isBuffer(a)||(a=o.from(a)),"des-ede"!==r&&"des-ede-cbc"!==r||(a=o.concat([a,a.slice(0,8)]));var c=e.iv;o.isBuffer(c)||(c=o.from(c)),this._des=i.create({key:a,iv:c,type:t})}s.des=s["des-cbc"],s.des3=s["des-ede3-cbc"],e.exports=c,a(c,n),c.prototype._update=function(e){return o.from(this._des.update(e))},c.prototype._final=function(){return o.from(this._des.final())}},function(e,t,r){"use strict";t.readUInt32BE=function(e,t){return(e[0+t]<<24|e[1+t]<<16|e[2+t]<<8|e[3+t])>>>0},t.writeUInt32BE=function(e,t,r){e[0+r]=t>>>24,e[1+r]=t>>>16&255,e[2+r]=t>>>8&255,e[3+r]=255&t},t.ip=function(e,t,r,n){for(var i=0,a=0,o=6;o>=0;o-=2){for(var s=0;s<=24;s+=8)i<<=1,i|=t>>>s+o&1;for(s=0;s<=24;s+=8)i<<=1,i|=e>>>s+o&1}for(o=6;o>=0;o-=2){for(s=1;s<=25;s+=8)a<<=1,a|=t>>>s+o&1;for(s=1;s<=25;s+=8)a<<=1,a|=e>>>s+o&1}r[n+0]=i>>>0,r[n+1]=a>>>0},t.rip=function(e,t,r,n){for(var i=0,a=0,o=0;o<4;o++)for(var s=24;s>=0;s-=8)i<<=1,i|=t>>>s+o&1,i<<=1,i|=e>>>s+o&1;for(o=4;o<8;o++)for(s=24;s>=0;s-=8)a<<=1,a|=t>>>s+o&1,a<<=1,a|=e>>>s+o&1;r[n+0]=i>>>0,r[n+1]=a>>>0},t.pc1=function(e,t,r,n){for(var i=0,a=0,o=7;o>=5;o--){for(var s=0;s<=24;s+=8)i<<=1,i|=t>>s+o&1;for(s=0;s<=24;s+=8)i<<=1,i|=e>>s+o&1}for(s=0;s<=24;s+=8)i<<=1,i|=t>>s+o&1;for(o=1;o<=3;o++){for(s=0;s<=24;s+=8)a<<=1,a|=t>>s+o&1;for(s=0;s<=24;s+=8)a<<=1,a|=e>>s+o&1}for(s=0;s<=24;s+=8)a<<=1,a|=e>>s+o&1;r[n+0]=i>>>0,r[n+1]=a>>>0},t.r28shl=function(e,t){return e<<t&268435455|e>>>28-t};var n=[14,11,17,4,27,23,25,0,13,22,7,18,5,9,16,24,2,20,12,21,1,8,15,26,15,4,25,19,9,1,26,16,5,11,23,8,12,7,17,0,22,3,10,14,6,20,27,24];t.pc2=function(e,t,r,i){for(var a=0,o=0,s=n.length>>>1,c=0;c<s;c++)a<<=1,a|=e>>>n[c]&1;for(c=s;c<n.length;c++)o<<=1,o|=t>>>n[c]&1;r[i+0]=a>>>0,r[i+1]=o>>>0},t.expand=function(e,t,r){var n=0,i=0;n=(1&e)<<5|e>>>27;for(var a=23;a>=15;a-=4)n<<=6,n|=e>>>a&63;for(a=11;a>=3;a-=4)i|=e>>>a&63,i<<=6;i|=(31&e)<<1|e>>>31,t[r+0]=n>>>0,t[r+1]=i>>>0};var i=[14,0,4,15,13,7,1,4,2,14,15,2,11,13,8,1,3,10,10,6,6,12,12,11,5,9,9,5,0,3,7,8,4,15,1,12,14,8,8,2,13,4,6,9,2,1,11,7,15,5,12,11,9,3,7,14,3,10,10,0,5,6,0,13,15,3,1,13,8,4,14,7,6,15,11,2,3,8,4,14,9,12,7,0,2,1,13,10,12,6,0,9,5,11,10,5,0,13,14,8,7,10,11,1,10,3,4,15,13,4,1,2,5,11,8,6,12,7,6,12,9,0,3,5,2,14,15,9,10,13,0,7,9,0,14,9,6,3,3,4,15,6,5,10,1,2,13,8,12,5,7,14,11,12,4,11,2,15,8,1,13,1,6,10,4,13,9,0,8,6,15,9,3,8,0,7,11,4,1,15,2,14,12,3,5,11,10,5,14,2,7,12,7,13,13,8,14,11,3,5,0,6,6,15,9,0,10,3,1,4,2,7,8,2,5,12,11,1,12,10,4,14,15,9,10,3,6,15,9,0,0,6,12,10,11,1,7,13,13,8,15,9,1,4,3,5,14,11,5,12,2,7,8,2,4,14,2,14,12,11,4,2,1,12,7,4,10,7,11,13,6,1,8,5,5,0,3,15,15,10,13,3,0,9,14,8,9,6,4,11,2,8,1,12,11,7,10,1,13,14,7,2,8,13,15,6,9,15,12,0,5,9,6,10,3,4,0,5,14,3,12,10,1,15,10,4,15,2,9,7,2,12,6,9,8,5,0,6,13,1,3,13,4,14,14,0,7,11,5,3,11,8,9,4,14,3,15,2,5,12,2,9,8,5,12,15,3,10,7,11,0,14,4,1,10,7,1,6,13,0,11,8,6,13,4,13,11,0,2,11,14,7,15,4,0,9,8,1,13,10,3,14,12,3,9,5,7,12,5,2,10,15,6,8,1,6,1,6,4,11,11,13,13,8,12,1,3,4,7,10,14,7,10,9,15,5,6,0,8,15,0,14,5,2,9,3,2,12,13,1,2,15,8,13,4,8,6,10,15,3,11,7,1,4,10,12,9,5,3,6,14,11,5,0,0,14,12,9,7,2,7,2,11,1,4,14,1,7,9,4,12,10,14,8,2,13,0,15,6,12,10,9,13,0,15,3,3,5,5,6,8,11];t.substitute=function(e,t){for(var r=0,n=0;n<4;n++){r<<=4,r|=i[64*n+(e>>>18-6*n&63)]}for(n=0;n<4;n++){r<<=4,r|=i[256+64*n+(t>>>18-6*n&63)]}return r>>>0};var a=[16,25,12,11,3,20,4,15,31,17,9,6,27,14,1,22,30,24,8,18,0,5,29,23,13,19,2,26,10,21,28,7];t.permute=function(e){for(var t=0,r=0;r<a.length;r++)t<<=1,t|=e>>>a[r]&1;return t>>>0},t.padSplit=function(e,t,r){for(var n=e.toString(2);n.length<t;)n="0"+n;for(var i=[],a=0;a<t;a+=r)i.push(n.slice(a,a+r));return i.join(" ")}},function(e,t,r){"use strict";var n=r(16);function i(e){this.options=e,this.type=this.options.type,this.blockSize=8,this._init(),this.buffer=new Array(this.blockSize),this.bufferOff=0}e.exports=i,i.prototype._init=function(){},i.prototype.update=function(e){return 0===e.length?[]:"decrypt"===this.type?this._updateDecrypt(e):this._updateEncrypt(e)},i.prototype._buffer=function(e,t){for(var r=Math.min(this.buffer.length-this.bufferOff,e.length-t),n=0;n<r;n++)this.buffer[this.bufferOff+n]=e[t+n];return this.bufferOff+=r,r},i.prototype._flushBuffer=function(e,t){return this._update(this.buffer,0,e,t),this.bufferOff=0,this.blockSize},i.prototype._updateEncrypt=function(e){var t=0,r=0,n=(this.bufferOff+e.length)/this.blockSize|0,i=new Array(n*this.blockSize);0!==this.bufferOff&&(t+=this._buffer(e,t),this.bufferOff===this.buffer.length&&(r+=this._flushBuffer(i,r)));for(var a=e.length-(e.length-t)%this.blockSize;t<a;t+=this.blockSize)this._update(e,t,i,r),r+=this.blockSize;for(;t<e.length;t++,this.bufferOff++)this.buffer[this.bufferOff]=e[t];return i},i.prototype._updateDecrypt=function(e){for(var t=0,r=0,n=Math.ceil((this.bufferOff+e.length)/this.blockSize)-1,i=new Array(n*this.blockSize);n>0;n--)t+=this._buffer(e,t),r+=this._flushBuffer(i,r);return t+=this._buffer(e,t),i},i.prototype.final=function(e){var t,r;return e&&(t=this.update(e)),r="encrypt"===this.type?this._finalEncrypt():this._finalDecrypt(),t?t.concat(r):r},i.prototype._pad=function(e,t){if(0===t)return!1;for(;t<e.length;)e[t++]=0;return!0},i.prototype._finalEncrypt=function(){if(!this._pad(this.buffer,this.bufferOff))return[];var e=new Array(this.blockSize);return this._update(this.buffer,0,e,0),e},i.prototype._unpad=function(e){return e},i.prototype._finalDecrypt=function(){n.equal(this.bufferOff,this.blockSize,"Not enough data to decrypt");var e=new Array(this.blockSize);return this._flushBuffer(e,0),this._unpad(e)}},function(e,t,r){"use strict";var n=r(16),i=r(1),a=r(104),o=a.utils,s=a.Cipher;function c(){this.tmp=new Array(2),this.keys=null}function u(e){s.call(this,e);var t=new c;this._desState=t,this.deriveKeys(t,e.key)}i(u,s),e.exports=u,u.create=function(e){return new u(e)};var l=[1,1,2,2,2,2,2,2,1,2,2,2,2,2,2,1];u.prototype.deriveKeys=function(e,t){e.keys=new Array(32),n.equal(t.length,this.blockSize,"Invalid key length");var r=o.readUInt32BE(t,0),i=o.readUInt32BE(t,4);o.pc1(r,i,e.tmp,0),r=e.tmp[0],i=e.tmp[1];for(var a=0;a<e.keys.length;a+=2){var s=l[a>>>1];r=o.r28shl(r,s),i=o.r28shl(i,s),o.pc2(r,i,e.keys,a)}},u.prototype._update=function(e,t,r,n){var i=this._desState,a=o.readUInt32BE(e,t),s=o.readUInt32BE(e,t+4);o.ip(a,s,i.tmp,0),a=i.tmp[0],s=i.tmp[1],"encrypt"===this.type?this._encrypt(i,a,s,i.tmp,0):this._decrypt(i,a,s,i.tmp,0),a=i.tmp[0],s=i.tmp[1],o.writeUInt32BE(r,a,n),o.writeUInt32BE(r,s,n+4)},u.prototype._pad=function(e,t){for(var r=e.length-t,n=t;n<e.length;n++)e[n]=r;return!0},u.prototype._unpad=function(e){for(var t=e[e.length-1],r=e.length-t;r<e.length;r++)n.equal(e[r],t);return e.slice(0,e.length-t)},u.prototype._encrypt=function(e,t,r,n,i){for(var a=t,s=r,c=0;c<e.keys.length;c+=2){var u=e.keys[c],l=e.keys[c+1];o.expand(s,e.tmp,0),u^=e.tmp[0],l^=e.tmp[1];var f=o.substitute(u,l),d=s;s=(a^o.permute(f))>>>0,a=d}o.rip(s,a,n,i)},u.prototype._decrypt=function(e,t,r,n,i){for(var a=r,s=t,c=e.keys.length-2;c>=0;c-=2){var u=e.keys[c],l=e.keys[c+1];o.expand(a,e.tmp,0),u^=e.tmp[0],l^=e.tmp[1];var f=o.substitute(u,l),d=a;a=(s^o.permute(f))>>>0,s=d}o.rip(a,s,n,i)}},function(e,t,r){"use strict";var n=r(16),i=r(1),a={};function o(e){n.equal(e.length,8,"Invalid IV length"),this.iv=new Array(8);for(var t=0;t<this.iv.length;t++)this.iv[t]=e[t]}t.instantiate=function(e){function t(t){e.call(this,t),this._cbcInit()}i(t,e);for(var r=Object.keys(a),n=0;n<r.length;n++){var o=r[n];t.prototype[o]=a[o]}return t.create=function(e){return new t(e)},t},a._cbcInit=function(){var e=new o(this.options.iv);this._cbcState=e},a._update=function(e,t,r,n){var i=this._cbcState,a=this.constructor.super_.prototype,o=i.iv;if("encrypt"===this.type){for(var s=0;s<this.blockSize;s++)o[s]^=e[t+s];a._update.call(this,o,0,r,n);for(s=0;s<this.blockSize;s++)o[s]=r[n+s]}else{a._update.call(this,e,t,r,n);for(s=0;s<this.blockSize;s++)r[n+s]^=o[s];for(s=0;s<this.blockSize;s++)o[s]=e[t+s]}}},function(e,t,r){"use strict";var n=r(16),i=r(1),a=r(104),o=a.Cipher,s=a.DES;function c(e,t){n.equal(t.length,24,"Invalid key length");var r=t.slice(0,8),i=t.slice(8,16),a=t.slice(16,24);this.ciphers="encrypt"===e?[s.create({type:"encrypt",key:r}),s.create({type:"decrypt",key:i}),s.create({type:"encrypt",key:a})]:[s.create({type:"decrypt",key:a}),s.create({type:"encrypt",key:i}),s.create({type:"decrypt",key:r})]}function u(e){o.call(this,e);var t=new c(this.type,this.options.key);this._edeState=t}i(u,o),e.exports=u,u.create=function(e){return new u(e)},u.prototype._update=function(e,t,r,n){var i=this._edeState;i.ciphers[0]._update(e,t,r,n),i.ciphers[1]._update(r,n,r,n),i.ciphers[2]._update(r,n,r,n)},u.prototype._pad=s.prototype._pad,u.prototype._unpad=s.prototype._unpad},function(e,t,r){var n=r(106),i=r(262),a=r(2).Buffer,o=r(263),s=r(29),c=r(78),u=r(79);function l(e,t,r){s.call(this),this._cache=new d,this._cipher=new c.AES(t),this._prev=a.from(r),this._mode=e,this._autopadding=!0}r(1)(l,s),l.prototype._update=function(e){var t,r;this._cache.add(e);for(var n=[];t=this._cache.get();)r=this._mode.encrypt(this,t),n.push(r);return a.concat(n)};var f=a.alloc(16,16);function d(){this.cache=a.allocUnsafe(0)}function h(e,t,r){var s=n[e.toLowerCase()];if(!s)throw new TypeError("invalid suite type");if("string"==typeof t&&(t=a.from(t)),t.length!==s.key/8)throw new TypeError("invalid key length "+t.length);if("string"==typeof r&&(r=a.from(r)),"GCM"!==s.mode&&r.length!==s.iv)throw new TypeError("invalid iv length "+r.length);return"stream"===s.type?new o(s.module,t,r):"auth"===s.type?new i(s.module,t,r):new l(s.module,t,r)}l.prototype._final=function(){var e=this._cache.flush();if(this._autopadding)return e=this._mode.encrypt(this,e),this._cipher.scrub(),e;if(!e.equals(f))throw this._cipher.scrub(),new Error("data not multiple of block length")},l.prototype.setAutoPadding=function(e){return this._autopadding=!!e,this},d.prototype.add=function(e){this.cache=a.concat([this.cache,e])},d.prototype.get=function(){if(this.cache.length>15){var e=this.cache.slice(0,16);return this.cache=this.cache.slice(16),e}return null},d.prototype.flush=function(){for(var e=16-this.cache.length,t=a.allocUnsafe(e),r=-1;++r<e;)t.writeUInt8(e,r);return a.concat([this.cache,t])},t.createCipheriv=h,t.createCipher=function(e,t){var r=n[e.toLowerCase()];if(!r)throw new TypeError("invalid suite type");var i=u(t,!1,r.key,r.iv);return h(e,i.key,i.iv)}},function(e,t){t.encrypt=function(e,t){return e._cipher.encryptBlock(t)},t.decrypt=function(e,t){return e._cipher.decryptBlock(t)}},function(e,t,r){var n=r(59);t.encrypt=function(e,t){var r=n(t,e._prev);return e._prev=e._cipher.encryptBlock(r),e._prev},t.decrypt=function(e,t){var r=e._prev;e._prev=t;var i=e._cipher.decryptBlock(t);return n(i,r)}},function(e,t,r){var n=r(2).Buffer,i=r(59);function a(e,t,r){var a=t.length,o=i(t,e._cache);return e._cache=e._cache.slice(a),e._prev=n.concat([e._prev,r?t:o]),o}t.encrypt=function(e,t,r){for(var i,o=n.allocUnsafe(0);t.length;){if(0===e._cache.length&&(e._cache=e._cipher.encryptBlock(e._prev),e._prev=n.allocUnsafe(0)),!(e._cache.length<=t.length)){o=n.concat([o,a(e,t,r)]);break}i=e._cache.length,o=n.concat([o,a(e,t.slice(0,i),r)]),t=t.slice(i)}return o}},function(e,t,r){var n=r(2).Buffer;function i(e,t,r){var i=e._cipher.encryptBlock(e._prev)[0]^t;return e._prev=n.concat([e._prev.slice(1),n.from([r?t:i])]),i}t.encrypt=function(e,t,r){for(var a=t.length,o=n.allocUnsafe(a),s=-1;++s<a;)o[s]=i(e,t[s],r);return o}},function(e,t,r){var n=r(2).Buffer;function i(e,t,r){for(var n,i,o=-1,s=0;++o<8;)n=t&1<<7-o?128:0,s+=(128&(i=e._cipher.encryptBlock(e._prev)[0]^n))>>o%8,e._prev=a(e._prev,r?n:i);return s}function a(e,t){var r=e.length,i=-1,a=n.allocUnsafe(e.length);for(e=n.concat([e,n.from([t])]);++i<r;)a[i]=e[i]<<1|e[i+1]>>7;return a}t.encrypt=function(e,t,r){for(var a=t.length,o=n.allocUnsafe(a),s=-1;++s<a;)o[s]=i(e,t[s],r);return o}},function(e,t,r){(function(e){var n=r(59);function i(e){return e._prev=e._cipher.encryptBlock(e._prev),e._prev}t.encrypt=function(t,r){for(;t._cache.length<r.length;)t._cache=e.concat([t._cache,i(t)]);var a=t._cache.slice(0,r.length);return t._cache=t._cache.slice(r.length),n(r,a)}}).call(this,r(7).Buffer)},function(e,t,r){var n=r(2).Buffer,i=n.alloc(16,0);function a(e){var t=n.allocUnsafe(16);return t.writeUInt32BE(e[0]>>>0,0),t.writeUInt32BE(e[1]>>>0,4),t.writeUInt32BE(e[2]>>>0,8),t.writeUInt32BE(e[3]>>>0,12),t}function o(e){this.h=e,this.state=n.alloc(16,0),this.cache=n.allocUnsafe(0)}o.prototype.ghash=function(e){for(var t=-1;++t<e.length;)this.state[t]^=e[t];this._multiply()},o.prototype._multiply=function(){for(var e,t,r,n=[(e=this.h).readUInt32BE(0),e.readUInt32BE(4),e.readUInt32BE(8),e.readUInt32BE(12)],i=[0,0,0,0],o=-1;++o<128;){for(0!=(this.state[~~(o/8)]&1<<7-o%8)&&(i[0]^=n[0],i[1]^=n[1],i[2]^=n[2],i[3]^=n[3]),r=0!=(1&n[3]),t=3;t>0;t--)n[t]=n[t]>>>1|(1&n[t-1])<<31;n[0]=n[0]>>>1,r&&(n[0]=n[0]^225<<24)}this.state=a(i)},o.prototype.update=function(e){var t;for(this.cache=n.concat([this.cache,e]);this.cache.length>=16;)t=this.cache.slice(0,16),this.cache=this.cache.slice(16),this.ghash(t)},o.prototype.final=function(e,t){return this.cache.length&&this.ghash(n.concat([this.cache,i],16)),this.ghash(a([0,e,0,t])),this.state},e.exports=o},function(e,t,r){var n=r(262),i=r(2).Buffer,a=r(106),o=r(263),s=r(29),c=r(78),u=r(79);function l(e,t,r){s.call(this),this._cache=new f,this._last=void 0,this._cipher=new c.AES(t),this._prev=i.from(r),this._mode=e,this._autopadding=!0}function f(){this.cache=i.allocUnsafe(0)}function d(e,t,r){var s=a[e.toLowerCase()];if(!s)throw new TypeError("invalid suite type");if("string"==typeof r&&(r=i.from(r)),"GCM"!==s.mode&&r.length!==s.iv)throw new TypeError("invalid iv length "+r.length);if("string"==typeof t&&(t=i.from(t)),t.length!==s.key/8)throw new TypeError("invalid key length "+t.length);return"stream"===s.type?new o(s.module,t,r,!0):"auth"===s.type?new n(s.module,t,r,!0):new l(s.module,t,r)}r(1)(l,s),l.prototype._update=function(e){var t,r;this._cache.add(e);for(var n=[];t=this._cache.get(this._autopadding);)r=this._mode.decrypt(this,t),n.push(r);return i.concat(n)},l.prototype._final=function(){var e=this._cache.flush();if(this._autopadding)return function(e){var t=e[15];if(t<1||t>16)throw new Error("unable to decrypt data");var r=-1;for(;++r<t;)if(e[r+(16-t)]!==t)throw new Error("unable to decrypt data");if(16===t)return;return e.slice(0,16-t)}(this._mode.decrypt(this,e));if(e)throw new Error("data not multiple of block length")},l.prototype.setAutoPadding=function(e){return this._autopadding=!!e,this},f.prototype.add=function(e){this.cache=i.concat([this.cache,e])},f.prototype.get=function(e){var t;if(e){if(this.cache.length>16)return t=this.cache.slice(0,16),this.cache=this.cache.slice(16),t}else if(this.cache.length>=16)return t=this.cache.slice(0,16),this.cache=this.cache.slice(16),t;return null},f.prototype.flush=function(){if(this.cache.length)return this.cache},t.createDecipher=function(e,t){var r=a[e.toLowerCase()];if(!r)throw new TypeError("invalid suite type");var n=u(t,!1,r.key,r.iv);return d(e,n.key,n.iv)},t.createDecipheriv=d},function(e,t){t["des-ecb"]={key:8,iv:0},t["des-cbc"]=t.des={key:8,iv:8},t["des-ede3-cbc"]=t.des3={key:24,iv:8},t["des-ede3"]={key:24,iv:0},t["des-ede-cbc"]={key:16,iv:8},t["des-ede"]={key:16,iv:0}},function(e,t,r){(function(e){var n=r(264),i=r(623),a=r(624);var o={binary:!0,hex:!0,base64:!0};t.DiffieHellmanGroup=t.createDiffieHellmanGroup=t.getDiffieHellman=function(t){var r=new e(i[t].prime,"hex"),n=new e(i[t].gen,"hex");return new a(r,n)},t.createDiffieHellman=t.DiffieHellman=function t(r,i,s,c){return e.isBuffer(i)||void 0===o[i]?t(r,"binary",i,s):(i=i||"binary",c=c||"binary",s=s||new e([2]),e.isBuffer(s)||(s=new e(s,c)),"number"==typeof r?new a(n(r,s),s,!0):(e.isBuffer(r)||(r=new e(r,i)),new a(r,s,!0)))}}).call(this,r(7).Buffer)},function(e,t){},function(e,t){},function(e){e.exports=JSON.parse('{"modp1":{"gen":"02","prime":"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a63a3620ffffffffffffffff"},"modp2":{"gen":"02","prime":"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece65381ffffffffffffffff"},"modp5":{"gen":"02","prime":"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca237327ffffffffffffffff"},"modp14":{"gen":"02","prime":"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aacaa68ffffffffffffffff"},"modp15":{"gen":"02","prime":"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a93ad2caffffffffffffffff"},"modp16":{"gen":"02","prime":"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a92108011a723c12a787e6d788719a10bdba5b2699c327186af4e23c1a946834b6150bda2583e9ca2ad44ce8dbbbc2db04de8ef92e8efc141fbecaa6287c59474e6bc05d99b2964fa090c3a2233ba186515be7ed1f612970cee2d7afb81bdd762170481cd0069127d5b05aa993b4ea988d8fddc186ffb7dc90a6c08f4df435c934063199ffffffffffffffff"},"modp17":{"gen":"02","prime":"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a92108011a723c12a787e6d788719a10bdba5b2699c327186af4e23c1a946834b6150bda2583e9ca2ad44ce8dbbbc2db04de8ef92e8efc141fbecaa6287c59474e6bc05d99b2964fa090c3a2233ba186515be7ed1f612970cee2d7afb81bdd762170481cd0069127d5b05aa993b4ea988d8fddc186ffb7dc90a6c08f4df435c93402849236c3fab4d27c7026c1d4dcb2602646dec9751e763dba37bdf8ff9406ad9e530ee5db382f413001aeb06a53ed9027d831179727b0865a8918da3edbebcf9b14ed44ce6cbaced4bb1bdb7f1447e6cc254b332051512bd7af426fb8f401378cd2bf5983ca01c64b92ecf032ea15d1721d03f482d7ce6e74fef6d55e702f46980c82b5a84031900b1c9e59e7c97fbec7e8f323a97a7e36cc88be0f1d45b7ff585ac54bd407b22b4154aacc8f6d7ebf48e1d814cc5ed20f8037e0a79715eef29be32806a1d58bb7c5da76f550aa3d8a1fbff0eb19ccb1a313d55cda56c9ec2ef29632387fe8d76e3c0468043e8f663f4860ee12bf2d5b0b7474d6e694f91e6dcc4024ffffffffffffffff"},"modp18":{"gen":"02","prime":"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a92108011a723c12a787e6d788719a10bdba5b2699c327186af4e23c1a946834b6150bda2583e9ca2ad44ce8dbbbc2db04de8ef92e8efc141fbecaa6287c59474e6bc05d99b2964fa090c3a2233ba186515be7ed1f612970cee2d7afb81bdd762170481cd0069127d5b05aa993b4ea988d8fddc186ffb7dc90a6c08f4df435c93402849236c3fab4d27c7026c1d4dcb2602646dec9751e763dba37bdf8ff9406ad9e530ee5db382f413001aeb06a53ed9027d831179727b0865a8918da3edbebcf9b14ed44ce6cbaced4bb1bdb7f1447e6cc254b332051512bd7af426fb8f401378cd2bf5983ca01c64b92ecf032ea15d1721d03f482d7ce6e74fef6d55e702f46980c82b5a84031900b1c9e59e7c97fbec7e8f323a97a7e36cc88be0f1d45b7ff585ac54bd407b22b4154aacc8f6d7ebf48e1d814cc5ed20f8037e0a79715eef29be32806a1d58bb7c5da76f550aa3d8a1fbff0eb19ccb1a313d55cda56c9ec2ef29632387fe8d76e3c0468043e8f663f4860ee12bf2d5b0b7474d6e694f91e6dbe115974a3926f12fee5e438777cb6a932df8cd8bec4d073b931ba3bc832b68d9dd300741fa7bf8afc47ed2576f6936ba424663aab639c5ae4f5683423b4742bf1c978238f16cbe39d652de3fdb8befc848ad922222e04a4037c0713eb57a81a23f0c73473fc646cea306b4bcbc8862f8385ddfa9d4b7fa2c087e879683303ed5bdd3a062b3cf5b3a278a66d2a13f83f44f82ddf310ee074ab6a364597e899a0255dc164f31cc50846851df9ab48195ded7ea1b1d510bd7ee74d73faf36bc31ecfa268359046f4eb879f924009438b481c6cd7889a002ed5ee382bc9190da6fc026e479558e4475677e9aa9e3050e2765694dfc81f56e880b96e7160c980dd98edd3dfffffffffffffffff"}}')},function(e,t,r){(function(t){var n=r(11),i=new(r(265)),a=new n(24),o=new n(11),s=new n(10),c=new n(3),u=new n(7),l=r(264),f=r(43);function d(e,r){return r=r||"utf8",t.isBuffer(e)||(e=new t(e,r)),this._pub=new n(e),this}function h(e,r){return r=r||"utf8",t.isBuffer(e)||(e=new t(e,r)),this._priv=new n(e),this}e.exports=y;var p={};function y(e,t,r){this.setGenerator(t),this.__prime=new n(e),this._prime=n.mont(this.__prime),this._primeLen=e.length,this._pub=void 0,this._priv=void 0,this._primeCode=void 0,r?(this.setPublicKey=d,this.setPrivateKey=h):this._primeCode=8}function m(e,r){var n=new t(e.toArray());return r?n.toString(r):n}Object.defineProperty(y.prototype,"verifyError",{enumerable:!0,get:function(){return"number"!=typeof this._primeCode&&(this._primeCode=function(e,t){var r=t.toString("hex"),n=[r,e.toString(16)].join("_");if(n in p)return p[n];var f,d=0;if(e.isEven()||!l.simpleSieve||!l.fermatTest(e)||!i.test(e))return d+=1,d+="02"===r||"05"===r?8:4,p[n]=d,d;switch(i.test(e.shrn(1))||(d+=2),r){case"02":e.mod(a).cmp(o)&&(d+=8);break;case"05":(f=e.mod(s)).cmp(c)&&f.cmp(u)&&(d+=8);break;default:d+=4}return p[n]=d,d}(this.__prime,this.__gen)),this._primeCode}}),y.prototype.generateKeys=function(){return this._priv||(this._priv=new n(f(this._primeLen))),this._pub=this._gen.toRed(this._prime).redPow(this._priv).fromRed(),this.getPublicKey()},y.prototype.computeSecret=function(e){var r=(e=(e=new n(e)).toRed(this._prime)).redPow(this._priv).fromRed(),i=new t(r.toArray()),a=this.getPrime();if(i.length<a.length){var o=new t(a.length-i.length);o.fill(0),i=t.concat([o,i])}return i},y.prototype.getPublicKey=function(e){return m(this._pub,e)},y.prototype.getPrivateKey=function(e){return m(this._priv,e)},y.prototype.getPrime=function(e){return m(this.__prime,e)},y.prototype.getGenerator=function(e){return m(this._gen,e)},y.prototype.setGenerator=function(e,r){return r=r||"utf8",t.isBuffer(e)||(e=new t(e,r)),this.__gen=e,this._gen=new n(e),this}}).call(this,r(7).Buffer)},function(e,t,r){(function(t){var n=r(44),i=r(3),a=r(1),o=r(626),s=r(658),c=r(254);function u(e){i.Writable.call(this);var t=c[e];if(!t)throw new Error("Unknown message digest");this._hashType=t.hash,this._hash=n(t.hash),this._tag=t.id,this._signType=t.sign}function l(e){i.Writable.call(this);var t=c[e];if(!t)throw new Error("Unknown message digest");this._hash=n(t.hash),this._tag=t.id,this._signType=t.sign}function f(e){return new u(e)}function d(e){return new l(e)}Object.keys(c).forEach(function(e){c[e].id=new t(c[e].id,"hex"),c[e.toLowerCase()]=c[e]}),a(u,i.Writable),u.prototype._write=function(e,t,r){this._hash.update(e),r()},u.prototype.update=function(e,r){return"string"==typeof e&&(e=new t(e,r)),this._hash.update(e),this},u.prototype.sign=function(e,t){this.end();var r=this._hash.digest(),n=o(r,e,this._hashType,this._signType,this._tag);return t?n.toString(t):n},a(l,i.Writable),l.prototype._write=function(e,t,r){this._hash.update(e),r()},l.prototype.update=function(e,r){return"string"==typeof e&&(e=new t(e,r)),this._hash.update(e),this},l.prototype.verify=function(e,r,n){"string"==typeof r&&(r=new t(r,n)),this.end();var i=this._hash.digest();return s(r,i,e,this._signType,this._tag)},e.exports={Sign:f,Verify:d,createSign:f,createVerify:d}}).call(this,r(7).Buffer)},function(e,t,r){(function(t){var n=r(252),i=r(108),a=r(109).ec,o=r(11),s=r(81),c=r(275);function u(e,r,i,a){if((e=new t(e.toArray())).length<r.byteLength()){var o=new t(r.byteLength()-e.length);o.fill(0),e=t.concat([o,e])}var s=i.length,c=function(e,r){e=(e=l(e,r)).mod(r);var n=new t(e.toArray());if(n.length<r.byteLength()){var i=new t(r.byteLength()-n.length);i.fill(0),n=t.concat([i,n])}return n}(i,r),u=new t(s);u.fill(1);var f=new t(s);return f.fill(0),f=n(a,f).update(u).update(new t([0])).update(e).update(c).digest(),u=n(a,f).update(u).digest(),{k:f=n(a,f).update(u).update(new t([1])).update(e).update(c).digest(),v:u=n(a,f).update(u).digest()}}function l(e,t){var r=new o(e),n=(e.length<<3)-t.bitLength();return n>0&&r.ishrn(n),r}function f(e,r,i){var a,o;do{for(a=new t(0);8*a.length<e.bitLength();)r.v=n(i,r.k).update(r.v).digest(),a=t.concat([a,r.v]);o=l(a,e),r.k=n(i,r.k).update(r.v).update(new t([0])).digest(),r.v=n(i,r.k).update(r.v).digest()}while(-1!==o.cmp(e));return o}function d(e,t,r,n){return e.toRed(o.mont(r)).redPow(t).fromRed().mod(n)}e.exports=function(e,r,n,h,p){var y=s(r);if(y.curve){if("ecdsa"!==h&&"ecdsa/rsa"!==h)throw new Error("wrong private key type");return function(e,r){var n=c[r.curve.join(".")];if(!n)throw new Error("unknown curve "+r.curve.join("."));var i=new a(n).keyFromPrivate(r.privateKey).sign(e);return new t(i.toDER())}(e,y)}if("dsa"===y.type){if("dsa"!==h)throw new Error("wrong private key type");return function(e,r,n){var i,a=r.params.priv_key,s=r.params.p,c=r.params.q,h=r.params.g,p=new o(0),y=l(e,c).mod(c),m=!1,g=u(a,c,e,n);for(;!1===m;)i=f(c,g,n),p=d(h,i,s,c),0===(m=i.invm(c).imul(y.add(a.mul(p))).mod(c)).cmpn(0)&&(m=!1,p=new o(0));return function(e,r){e=e.toArray(),r=r.toArray(),128&e[0]&&(e=[0].concat(e));128&r[0]&&(r=[0].concat(r));var n=[48,e.length+r.length+4,2,e.length];return n=n.concat(e,[2,r.length],r),new t(n)}(p,m)}(e,y,n)}if("rsa"!==h&&"ecdsa/rsa"!==h)throw new Error("wrong private key type");e=t.concat([p,e]);for(var m=y.modulus.byteLength(),g=[0,1];e.length+g.length+1<m;)g.push(255);g.push(0);for(var b=-1;++b<e.length;)g.push(e[b]);return i(g,y)},e.exports.getKey=u,e.exports.makeKey=f}).call(this,r(7).Buffer)},function(e){e.exports=JSON.parse('{"_from":"elliptic@^6.4.0","_id":"elliptic@6.5.0","_inBundle":false,"_integrity":"sha512-eFOJTMyCYb7xtE/caJ6JJu+bhi67WCYNbkGSknu20pmM8Ke/bqOfdnZWxyoGN26JgfxTbXrsCkEw4KheCT/KGg==","_location":"/elliptic","_phantomChildren":{},"_requested":{"type":"range","registry":true,"raw":"elliptic@^6.4.0","name":"elliptic","escapedName":"elliptic","rawSpec":"^6.4.0","saveSpec":null,"fetchSpec":"^6.4.0"},"_requiredBy":["/@trust/keyto","/@trust/webcrypto","/browserify-sign","/create-ecdh"],"_resolved":"https://registry.npmjs.org/elliptic/-/elliptic-6.5.0.tgz","_shasum":"2b8ed4c891b7de3200e14412a5b8248c7af505ca","_spec":"elliptic@^6.4.0","_where":"/Users/ruben/Documents/UGent/Solid/solid-query-ldflex/node_modules/@trust/webcrypto","author":{"name":"Fedor Indutny","email":"fedor@indutny.com"},"bugs":{"url":"https://github.com/indutny/elliptic/issues"},"bundleDependencies":false,"dependencies":{"bn.js":"^4.4.0","brorand":"^1.0.1","hash.js":"^1.0.0","hmac-drbg":"^1.0.0","inherits":"^2.0.1","minimalistic-assert":"^1.0.0","minimalistic-crypto-utils":"^1.0.0"},"deprecated":false,"description":"EC cryptography","devDependencies":{"brfs":"^1.4.3","coveralls":"^2.11.3","grunt":"^0.4.5","grunt-browserify":"^5.0.0","grunt-cli":"^1.2.0","grunt-contrib-connect":"^1.0.0","grunt-contrib-copy":"^1.0.0","grunt-contrib-uglify":"^1.0.1","grunt-mocha-istanbul":"^3.0.1","grunt-saucelabs":"^8.6.2","istanbul":"^0.4.2","jscs":"^2.9.0","jshint":"^2.6.0","mocha":"^2.1.0"},"files":["lib"],"homepage":"https://github.com/indutny/elliptic","keywords":["EC","Elliptic","curve","Cryptography"],"license":"MIT","main":"lib/elliptic.js","name":"elliptic","repository":{"type":"git","url":"git+ssh://git@github.com/indutny/elliptic.git"},"scripts":{"jscs":"jscs benchmarks/*.js lib/*.js lib/**/*.js lib/**/**/*.js test/index.js","jshint":"jscs benchmarks/*.js lib/*.js lib/**/*.js lib/**/**/*.js test/index.js","lint":"npm run jscs && npm run jshint","test":"npm run lint && npm run unit","unit":"istanbul test _mocha --reporter=spec test/index.js","version":"grunt dist && git add dist/"},"version":"6.5.0"}')},function(e,t,r){"use strict";var n=r(17),i=r(11),a=r(1),o=r(80),s=n.assert;function c(e){o.call(this,"short",e),this.a=new i(e.a,16).toRed(this.red),this.b=new i(e.b,16).toRed(this.red),this.tinv=this.two.redInvm(),this.zeroA=0===this.a.fromRed().cmpn(0),this.threeA=0===this.a.fromRed().sub(this.p).cmpn(-3),this.endo=this._getEndomorphism(e),this._endoWnafT1=new Array(4),this._endoWnafT2=new Array(4)}function u(e,t,r,n){o.BasePoint.call(this,e,"affine"),null===t&&null===r?(this.x=null,this.y=null,this.inf=!0):(this.x=new i(t,16),this.y=new i(r,16),n&&(this.x.forceRed(this.curve.red),this.y.forceRed(this.curve.red)),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.inf=!1)}function l(e,t,r,n){o.BasePoint.call(this,e,"jacobian"),null===t&&null===r&&null===n?(this.x=this.curve.one,this.y=this.curve.one,this.z=new i(0)):(this.x=new i(t,16),this.y=new i(r,16),this.z=new i(n,16)),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)),this.zOne=this.z===this.curve.one}a(c,o),e.exports=c,c.prototype._getEndomorphism=function(e){if(this.zeroA&&this.g&&this.n&&1===this.p.modn(3)){var t,r;if(e.beta)t=new i(e.beta,16).toRed(this.red);else{var n=this._getEndoRoots(this.p);t=(t=n[0].cmp(n[1])<0?n[0]:n[1]).toRed(this.red)}if(e.lambda)r=new i(e.lambda,16);else{var a=this._getEndoRoots(this.n);0===this.g.mul(a[0]).x.cmp(this.g.x.redMul(t))?r=a[0]:(r=a[1],s(0===this.g.mul(r).x.cmp(this.g.x.redMul(t))))}return{beta:t,lambda:r,basis:e.basis?e.basis.map(function(e){return{a:new i(e.a,16),b:new i(e.b,16)}}):this._getEndoBasis(r)}}},c.prototype._getEndoRoots=function(e){var t=e===this.p?this.red:i.mont(e),r=new i(2).toRed(t).redInvm(),n=r.redNeg(),a=new i(3).toRed(t).redNeg().redSqrt().redMul(r);return[n.redAdd(a).fromRed(),n.redSub(a).fromRed()]},c.prototype._getEndoBasis=function(e){for(var t,r,n,a,o,s,c,u,l,f=this.n.ushrn(Math.floor(this.n.bitLength()/2)),d=e,h=this.n.clone(),p=new i(1),y=new i(0),m=new i(0),g=new i(1),b=0;0!==d.cmpn(0);){var v=h.div(d);u=h.sub(v.mul(d)),l=m.sub(v.mul(p));var _=g.sub(v.mul(y));if(!n&&u.cmp(f)<0)t=c.neg(),r=p,n=u.neg(),a=l;else if(n&&2==++b)break;c=u,h=d,d=u,m=p,p=l,g=y,y=_}o=u.neg(),s=l;var w=n.sqr().add(a.sqr());return o.sqr().add(s.sqr()).cmp(w)>=0&&(o=t,s=r),n.negative&&(n=n.neg(),a=a.neg()),o.negative&&(o=o.neg(),s=s.neg()),[{a:n,b:a},{a:o,b:s}]},c.prototype._endoSplit=function(e){var t=this.endo.basis,r=t[0],n=t[1],i=n.b.mul(e).divRound(this.n),a=r.b.neg().mul(e).divRound(this.n),o=i.mul(r.a),s=a.mul(n.a),c=i.mul(r.b),u=a.mul(n.b);return{k1:e.sub(o).sub(s),k2:c.add(u).neg()}},c.prototype.pointFromX=function(e,t){(e=new i(e,16)).red||(e=e.toRed(this.red));var r=e.redSqr().redMul(e).redIAdd(e.redMul(this.a)).redIAdd(this.b),n=r.redSqrt();if(0!==n.redSqr().redSub(r).cmp(this.zero))throw new Error("invalid point");var a=n.fromRed().isOdd();return(t&&!a||!t&&a)&&(n=n.redNeg()),this.point(e,n)},c.prototype.validate=function(e){if(e.inf)return!0;var t=e.x,r=e.y,n=this.a.redMul(t),i=t.redSqr().redMul(t).redIAdd(n).redIAdd(this.b);return 0===r.redSqr().redISub(i).cmpn(0)},c.prototype._endoWnafMulAdd=function(e,t,r){for(var n=this._endoWnafT1,i=this._endoWnafT2,a=0;a<e.length;a++){var o=this._endoSplit(t[a]),s=e[a],c=s._getBeta();o.k1.negative&&(o.k1.ineg(),s=s.neg(!0)),o.k2.negative&&(o.k2.ineg(),c=c.neg(!0)),n[2*a]=s,n[2*a+1]=c,i[2*a]=o.k1,i[2*a+1]=o.k2}for(var u=this._wnafMulAdd(1,n,i,2*a,r),l=0;l<2*a;l++)n[l]=null,i[l]=null;return u},a(u,o.BasePoint),c.prototype.point=function(e,t,r){return new u(this,e,t,r)},c.prototype.pointFromJSON=function(e,t){return u.fromJSON(this,e,t)},u.prototype._getBeta=function(){if(this.curve.endo){var e=this.precomputed;if(e&&e.beta)return e.beta;var t=this.curve.point(this.x.redMul(this.curve.endo.beta),this.y);if(e){var r=this.curve,n=function(e){return r.point(e.x.redMul(r.endo.beta),e.y)};e.beta=t,t.precomputed={beta:null,naf:e.naf&&{wnd:e.naf.wnd,points:e.naf.points.map(n)},doubles:e.doubles&&{step:e.doubles.step,points:e.doubles.points.map(n)}}}return t}},u.prototype.toJSON=function(){return this.precomputed?[this.x,this.y,this.precomputed&&{doubles:this.precomputed.doubles&&{step:this.precomputed.doubles.step,points:this.precomputed.doubles.points.slice(1)},naf:this.precomputed.naf&&{wnd:this.precomputed.naf.wnd,points:this.precomputed.naf.points.slice(1)}}]:[this.x,this.y]},u.fromJSON=function(e,t,r){"string"==typeof t&&(t=JSON.parse(t));var n=e.point(t[0],t[1],r);if(!t[2])return n;function i(t){return e.point(t[0],t[1],r)}var a=t[2];return n.precomputed={beta:null,doubles:a.doubles&&{step:a.doubles.step,points:[n].concat(a.doubles.points.map(i))},naf:a.naf&&{wnd:a.naf.wnd,points:[n].concat(a.naf.points.map(i))}},n},u.prototype.inspect=function(){return this.isInfinity()?"<EC Point Infinity>":"<EC Point x: "+this.x.fromRed().toString(16,2)+" y: "+this.y.fromRed().toString(16,2)+">"},u.prototype.isInfinity=function(){return this.inf},u.prototype.add=function(e){if(this.inf)return e;if(e.inf)return this;if(this.eq(e))return this.dbl();if(this.neg().eq(e))return this.curve.point(null,null);if(0===this.x.cmp(e.x))return this.curve.point(null,null);var t=this.y.redSub(e.y);0!==t.cmpn(0)&&(t=t.redMul(this.x.redSub(e.x).redInvm()));var r=t.redSqr().redISub(this.x).redISub(e.x),n=t.redMul(this.x.redSub(r)).redISub(this.y);return this.curve.point(r,n)},u.prototype.dbl=function(){if(this.inf)return this;var e=this.y.redAdd(this.y);if(0===e.cmpn(0))return this.curve.point(null,null);var t=this.curve.a,r=this.x.redSqr(),n=e.redInvm(),i=r.redAdd(r).redIAdd(r).redIAdd(t).redMul(n),a=i.redSqr().redISub(this.x.redAdd(this.x)),o=i.redMul(this.x.redSub(a)).redISub(this.y);return this.curve.point(a,o)},u.prototype.getX=function(){return this.x.fromRed()},u.prototype.getY=function(){return this.y.fromRed()},u.prototype.mul=function(e){return e=new i(e,16),this._hasDoubles(e)?this.curve._fixedNafMul(this,e):this.curve.endo?this.curve._endoWnafMulAdd([this],[e]):this.curve._wnafMul(this,e)},u.prototype.mulAdd=function(e,t,r){var n=[this,t],i=[e,r];return this.curve.endo?this.curve._endoWnafMulAdd(n,i):this.curve._wnafMulAdd(1,n,i,2)},u.prototype.jmulAdd=function(e,t,r){var n=[this,t],i=[e,r];return this.curve.endo?this.curve._endoWnafMulAdd(n,i,!0):this.curve._wnafMulAdd(1,n,i,2,!0)},u.prototype.eq=function(e){return this===e||this.inf===e.inf&&(this.inf||0===this.x.cmp(e.x)&&0===this.y.cmp(e.y))},u.prototype.neg=function(e){if(this.inf)return this;var t=this.curve.point(this.x,this.y.redNeg());if(e&&this.precomputed){var r=this.precomputed,n=function(e){return e.neg()};t.precomputed={naf:r.naf&&{wnd:r.naf.wnd,points:r.naf.points.map(n)},doubles:r.doubles&&{step:r.doubles.step,points:r.doubles.points.map(n)}}}return t},u.prototype.toJ=function(){return this.inf?this.curve.jpoint(null,null,null):this.curve.jpoint(this.x,this.y,this.curve.one)},a(l,o.BasePoint),c.prototype.jpoint=function(e,t,r){return new l(this,e,t,r)},l.prototype.toP=function(){if(this.isInfinity())return this.curve.point(null,null);var e=this.z.redInvm(),t=e.redSqr(),r=this.x.redMul(t),n=this.y.redMul(t).redMul(e);return this.curve.point(r,n)},l.prototype.neg=function(){return this.curve.jpoint(this.x,this.y.redNeg(),this.z)},l.prototype.add=function(e){if(this.isInfinity())return e;if(e.isInfinity())return this;var t=e.z.redSqr(),r=this.z.redSqr(),n=this.x.redMul(t),i=e.x.redMul(r),a=this.y.redMul(t.redMul(e.z)),o=e.y.redMul(r.redMul(this.z)),s=n.redSub(i),c=a.redSub(o);if(0===s.cmpn(0))return 0!==c.cmpn(0)?this.curve.jpoint(null,null,null):this.dbl();var u=s.redSqr(),l=u.redMul(s),f=n.redMul(u),d=c.redSqr().redIAdd(l).redISub(f).redISub(f),h=c.redMul(f.redISub(d)).redISub(a.redMul(l)),p=this.z.redMul(e.z).redMul(s);return this.curve.jpoint(d,h,p)},l.prototype.mixedAdd=function(e){if(this.isInfinity())return e.toJ();if(e.isInfinity())return this;var t=this.z.redSqr(),r=this.x,n=e.x.redMul(t),i=this.y,a=e.y.redMul(t).redMul(this.z),o=r.redSub(n),s=i.redSub(a);if(0===o.cmpn(0))return 0!==s.cmpn(0)?this.curve.jpoint(null,null,null):this.dbl();var c=o.redSqr(),u=c.redMul(o),l=r.redMul(c),f=s.redSqr().redIAdd(u).redISub(l).redISub(l),d=s.redMul(l.redISub(f)).redISub(i.redMul(u)),h=this.z.redMul(o);return this.curve.jpoint(f,d,h)},l.prototype.dblp=function(e){if(0===e)return this;if(this.isInfinity())return this;if(!e)return this.dbl();if(this.curve.zeroA||this.curve.threeA){for(var t=this,r=0;r<e;r++)t=t.dbl();return t}var n=this.curve.a,i=this.curve.tinv,a=this.x,o=this.y,s=this.z,c=s.redSqr().redSqr(),u=o.redAdd(o);for(r=0;r<e;r++){var l=a.redSqr(),f=u.redSqr(),d=f.redSqr(),h=l.redAdd(l).redIAdd(l).redIAdd(n.redMul(c)),p=a.redMul(f),y=h.redSqr().redISub(p.redAdd(p)),m=p.redISub(y),g=h.redMul(m);g=g.redIAdd(g).redISub(d);var b=u.redMul(s);r+1<e&&(c=c.redMul(d)),a=y,s=b,u=g}return this.curve.jpoint(a,u.redMul(i),s)},l.prototype.dbl=function(){return this.isInfinity()?this:this.curve.zeroA?this._zeroDbl():this.curve.threeA?this._threeDbl():this._dbl()},l.prototype._zeroDbl=function(){var e,t,r;if(this.zOne){var n=this.x.redSqr(),i=this.y.redSqr(),a=i.redSqr(),o=this.x.redAdd(i).redSqr().redISub(n).redISub(a);o=o.redIAdd(o);var s=n.redAdd(n).redIAdd(n),c=s.redSqr().redISub(o).redISub(o),u=a.redIAdd(a);u=(u=u.redIAdd(u)).redIAdd(u),e=c,t=s.redMul(o.redISub(c)).redISub(u),r=this.y.redAdd(this.y)}else{var l=this.x.redSqr(),f=this.y.redSqr(),d=f.redSqr(),h=this.x.redAdd(f).redSqr().redISub(l).redISub(d);h=h.redIAdd(h);var p=l.redAdd(l).redIAdd(l),y=p.redSqr(),m=d.redIAdd(d);m=(m=m.redIAdd(m)).redIAdd(m),e=y.redISub(h).redISub(h),t=p.redMul(h.redISub(e)).redISub(m),r=(r=this.y.redMul(this.z)).redIAdd(r)}return this.curve.jpoint(e,t,r)},l.prototype._threeDbl=function(){var e,t,r;if(this.zOne){var n=this.x.redSqr(),i=this.y.redSqr(),a=i.redSqr(),o=this.x.redAdd(i).redSqr().redISub(n).redISub(a);o=o.redIAdd(o);var s=n.redAdd(n).redIAdd(n).redIAdd(this.curve.a),c=s.redSqr().redISub(o).redISub(o);e=c;var u=a.redIAdd(a);u=(u=u.redIAdd(u)).redIAdd(u),t=s.redMul(o.redISub(c)).redISub(u),r=this.y.redAdd(this.y)}else{var l=this.z.redSqr(),f=this.y.redSqr(),d=this.x.redMul(f),h=this.x.redSub(l).redMul(this.x.redAdd(l));h=h.redAdd(h).redIAdd(h);var p=d.redIAdd(d),y=(p=p.redIAdd(p)).redAdd(p);e=h.redSqr().redISub(y),r=this.y.redAdd(this.z).redSqr().redISub(f).redISub(l);var m=f.redSqr();m=(m=(m=m.redIAdd(m)).redIAdd(m)).redIAdd(m),t=h.redMul(p.redISub(e)).redISub(m)}return this.curve.jpoint(e,t,r)},l.prototype._dbl=function(){var e=this.curve.a,t=this.x,r=this.y,n=this.z,i=n.redSqr().redSqr(),a=t.redSqr(),o=r.redSqr(),s=a.redAdd(a).redIAdd(a).redIAdd(e.redMul(i)),c=t.redAdd(t),u=(c=c.redIAdd(c)).redMul(o),l=s.redSqr().redISub(u.redAdd(u)),f=u.redISub(l),d=o.redSqr();d=(d=(d=d.redIAdd(d)).redIAdd(d)).redIAdd(d);var h=s.redMul(f).redISub(d),p=r.redAdd(r).redMul(n);return this.curve.jpoint(l,h,p)},l.prototype.trpl=function(){if(!this.curve.zeroA)return this.dbl().add(this);var e=this.x.redSqr(),t=this.y.redSqr(),r=this.z.redSqr(),n=t.redSqr(),i=e.redAdd(e).redIAdd(e),a=i.redSqr(),o=this.x.redAdd(t).redSqr().redISub(e).redISub(n),s=(o=(o=(o=o.redIAdd(o)).redAdd(o).redIAdd(o)).redISub(a)).redSqr(),c=n.redIAdd(n);c=(c=(c=c.redIAdd(c)).redIAdd(c)).redIAdd(c);var u=i.redIAdd(o).redSqr().redISub(a).redISub(s).redISub(c),l=t.redMul(u);l=(l=l.redIAdd(l)).redIAdd(l);var f=this.x.redMul(s).redISub(l);f=(f=f.redIAdd(f)).redIAdd(f);var d=this.y.redMul(u.redMul(c.redISub(u)).redISub(o.redMul(s)));d=(d=(d=d.redIAdd(d)).redIAdd(d)).redIAdd(d);var h=this.z.redAdd(o).redSqr().redISub(r).redISub(s);return this.curve.jpoint(f,d,h)},l.prototype.mul=function(e,t){return e=new i(e,t),this.curve._wnafMul(this,e)},l.prototype.eq=function(e){if("affine"===e.type)return this.eq(e.toJ());if(this===e)return!0;var t=this.z.redSqr(),r=e.z.redSqr();if(0!==this.x.redMul(r).redISub(e.x.redMul(t)).cmpn(0))return!1;var n=t.redMul(this.z),i=r.redMul(e.z);return 0===this.y.redMul(i).redISub(e.y.redMul(n)).cmpn(0)},l.prototype.eqXToP=function(e){var t=this.z.redSqr(),r=e.toRed(this.curve.red).redMul(t);if(0===this.x.cmp(r))return!0;for(var n=e.clone(),i=this.curve.redN.redMul(t);;){if(n.iadd(this.curve.n),n.cmp(this.curve.p)>=0)return!1;if(r.redIAdd(i),0===this.x.cmp(r))return!0}},l.prototype.inspect=function(){return this.isInfinity()?"<EC JPoint Infinity>":"<EC JPoint x: "+this.x.toString(16,2)+" y: "+this.y.toString(16,2)+" z: "+this.z.toString(16,2)+">"},l.prototype.isInfinity=function(){return 0===this.z.cmpn(0)}},function(e,t,r){"use strict";var n=r(11),i=r(1),a=r(80),o=r(17);function s(e){a.call(this,"mont",e),this.a=new n(e.a,16).toRed(this.red),this.b=new n(e.b,16).toRed(this.red),this.i4=new n(4).toRed(this.red).redInvm(),this.two=new n(2).toRed(this.red),this.a24=this.i4.redMul(this.a.redAdd(this.two))}function c(e,t,r){a.BasePoint.call(this,e,"projective"),null===t&&null===r?(this.x=this.curve.one,this.z=this.curve.zero):(this.x=new n(t,16),this.z=new n(r,16),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)))}i(s,a),e.exports=s,s.prototype.validate=function(e){var t=e.normalize().x,r=t.redSqr(),n=r.redMul(t).redAdd(r.redMul(this.a)).redAdd(t);return 0===n.redSqrt().redSqr().cmp(n)},i(c,a.BasePoint),s.prototype.decodePoint=function(e,t){return this.point(o.toArray(e,t),1)},s.prototype.point=function(e,t){return new c(this,e,t)},s.prototype.pointFromJSON=function(e){return c.fromJSON(this,e)},c.prototype.precompute=function(){},c.prototype._encode=function(){return this.getX().toArray("be",this.curve.p.byteLength())},c.fromJSON=function(e,t){return new c(e,t[0],t[1]||e.one)},c.prototype.inspect=function(){return this.isInfinity()?"<EC Point Infinity>":"<EC Point x: "+this.x.fromRed().toString(16,2)+" z: "+this.z.fromRed().toString(16,2)+">"},c.prototype.isInfinity=function(){return 0===this.z.cmpn(0)},c.prototype.dbl=function(){var e=this.x.redAdd(this.z).redSqr(),t=this.x.redSub(this.z).redSqr(),r=e.redSub(t),n=e.redMul(t),i=r.redMul(t.redAdd(this.curve.a24.redMul(r)));return this.curve.point(n,i)},c.prototype.add=function(){throw new Error("Not supported on Montgomery curve")},c.prototype.diffAdd=function(e,t){var r=this.x.redAdd(this.z),n=this.x.redSub(this.z),i=e.x.redAdd(e.z),a=e.x.redSub(e.z).redMul(r),o=i.redMul(n),s=t.z.redMul(a.redAdd(o).redSqr()),c=t.x.redMul(a.redISub(o).redSqr());return this.curve.point(s,c)},c.prototype.mul=function(e){for(var t=e.clone(),r=this,n=this.curve.point(null,null),i=[];0!==t.cmpn(0);t.iushrn(1))i.push(t.andln(1));for(var a=i.length-1;a>=0;a--)0===i[a]?(r=r.diffAdd(n,this),n=n.dbl()):(n=r.diffAdd(n,this),r=r.dbl());return n},c.prototype.mulAdd=function(){throw new Error("Not supported on Montgomery curve")},c.prototype.jumlAdd=function(){throw new Error("Not supported on Montgomery curve")},c.prototype.eq=function(e){return 0===this.getX().cmp(e.getX())},c.prototype.normalize=function(){return this.x=this.x.redMul(this.z.redInvm()),this.z=this.curve.one,this},c.prototype.getX=function(){return this.normalize(),this.x.fromRed()}},function(e,t,r){"use strict";var n=r(17),i=r(11),a=r(1),o=r(80),s=n.assert;function c(e){this.twisted=1!=(0|e.a),this.mOneA=this.twisted&&-1==(0|e.a),this.extended=this.mOneA,o.call(this,"edwards",e),this.a=new i(e.a,16).umod(this.red.m),this.a=this.a.toRed(this.red),this.c=new i(e.c,16).toRed(this.red),this.c2=this.c.redSqr(),this.d=new i(e.d,16).toRed(this.red),this.dd=this.d.redAdd(this.d),s(!this.twisted||0===this.c.fromRed().cmpn(1)),this.oneC=1==(0|e.c)}function u(e,t,r,n,a){o.BasePoint.call(this,e,"projective"),null===t&&null===r&&null===n?(this.x=this.curve.zero,this.y=this.curve.one,this.z=this.curve.one,this.t=this.curve.zero,this.zOne=!0):(this.x=new i(t,16),this.y=new i(r,16),this.z=n?new i(n,16):this.curve.one,this.t=a&&new i(a,16),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)),this.t&&!this.t.red&&(this.t=this.t.toRed(this.curve.red)),this.zOne=this.z===this.curve.one,this.curve.extended&&!this.t&&(this.t=this.x.redMul(this.y),this.zOne||(this.t=this.t.redMul(this.z.redInvm()))))}a(c,o),e.exports=c,c.prototype._mulA=function(e){return this.mOneA?e.redNeg():this.a.redMul(e)},c.prototype._mulC=function(e){return this.oneC?e:this.c.redMul(e)},c.prototype.jpoint=function(e,t,r,n){return this.point(e,t,r,n)},c.prototype.pointFromX=function(e,t){(e=new i(e,16)).red||(e=e.toRed(this.red));var r=e.redSqr(),n=this.c2.redSub(this.a.redMul(r)),a=this.one.redSub(this.c2.redMul(this.d).redMul(r)),o=n.redMul(a.redInvm()),s=o.redSqrt();if(0!==s.redSqr().redSub(o).cmp(this.zero))throw new Error("invalid point");var c=s.fromRed().isOdd();return(t&&!c||!t&&c)&&(s=s.redNeg()),this.point(e,s)},c.prototype.pointFromY=function(e,t){(e=new i(e,16)).red||(e=e.toRed(this.red));var r=e.redSqr(),n=r.redSub(this.c2),a=r.redMul(this.d).redMul(this.c2).redSub(this.a),o=n.redMul(a.redInvm());if(0===o.cmp(this.zero)){if(t)throw new Error("invalid point");return this.point(this.zero,e)}var s=o.redSqrt();if(0!==s.redSqr().redSub(o).cmp(this.zero))throw new Error("invalid point");return s.fromRed().isOdd()!==t&&(s=s.redNeg()),this.point(s,e)},c.prototype.validate=function(e){if(e.isInfinity())return!0;e.normalize();var t=e.x.redSqr(),r=e.y.redSqr(),n=t.redMul(this.a).redAdd(r),i=this.c2.redMul(this.one.redAdd(this.d.redMul(t).redMul(r)));return 0===n.cmp(i)},a(u,o.BasePoint),c.prototype.pointFromJSON=function(e){return u.fromJSON(this,e)},c.prototype.point=function(e,t,r,n){return new u(this,e,t,r,n)},u.fromJSON=function(e,t){return new u(e,t[0],t[1],t[2])},u.prototype.inspect=function(){return this.isInfinity()?"<EC Point Infinity>":"<EC Point x: "+this.x.fromRed().toString(16,2)+" y: "+this.y.fromRed().toString(16,2)+" z: "+this.z.fromRed().toString(16,2)+">"},u.prototype.isInfinity=function(){return 0===this.x.cmpn(0)&&(0===this.y.cmp(this.z)||this.zOne&&0===this.y.cmp(this.curve.c))},u.prototype._extDbl=function(){var e=this.x.redSqr(),t=this.y.redSqr(),r=this.z.redSqr();r=r.redIAdd(r);var n=this.curve._mulA(e),i=this.x.redAdd(this.y).redSqr().redISub(e).redISub(t),a=n.redAdd(t),o=a.redSub(r),s=n.redSub(t),c=i.redMul(o),u=a.redMul(s),l=i.redMul(s),f=o.redMul(a);return this.curve.point(c,u,f,l)},u.prototype._projDbl=function(){var e,t,r,n=this.x.redAdd(this.y).redSqr(),i=this.x.redSqr(),a=this.y.redSqr();if(this.curve.twisted){var o=(u=this.curve._mulA(i)).redAdd(a);if(this.zOne)e=n.redSub(i).redSub(a).redMul(o.redSub(this.curve.two)),t=o.redMul(u.redSub(a)),r=o.redSqr().redSub(o).redSub(o);else{var s=this.z.redSqr(),c=o.redSub(s).redISub(s);e=n.redSub(i).redISub(a).redMul(c),t=o.redMul(u.redSub(a)),r=o.redMul(c)}}else{var u=i.redAdd(a);s=this.curve._mulC(this.z).redSqr(),c=u.redSub(s).redSub(s);e=this.curve._mulC(n.redISub(u)).redMul(c),t=this.curve._mulC(u).redMul(i.redISub(a)),r=u.redMul(c)}return this.curve.point(e,t,r)},u.prototype.dbl=function(){return this.isInfinity()?this:this.curve.extended?this._extDbl():this._projDbl()},u.prototype._extAdd=function(e){var t=this.y.redSub(this.x).redMul(e.y.redSub(e.x)),r=this.y.redAdd(this.x).redMul(e.y.redAdd(e.x)),n=this.t.redMul(this.curve.dd).redMul(e.t),i=this.z.redMul(e.z.redAdd(e.z)),a=r.redSub(t),o=i.redSub(n),s=i.redAdd(n),c=r.redAdd(t),u=a.redMul(o),l=s.redMul(c),f=a.redMul(c),d=o.redMul(s);return this.curve.point(u,l,d,f)},u.prototype._projAdd=function(e){var t,r,n=this.z.redMul(e.z),i=n.redSqr(),a=this.x.redMul(e.x),o=this.y.redMul(e.y),s=this.curve.d.redMul(a).redMul(o),c=i.redSub(s),u=i.redAdd(s),l=this.x.redAdd(this.y).redMul(e.x.redAdd(e.y)).redISub(a).redISub(o),f=n.redMul(c).redMul(l);return this.curve.twisted?(t=n.redMul(u).redMul(o.redSub(this.curve._mulA(a))),r=c.redMul(u)):(t=n.redMul(u).redMul(o.redSub(a)),r=this.curve._mulC(c).redMul(u)),this.curve.point(f,t,r)},u.prototype.add=function(e){return this.isInfinity()?e:e.isInfinity()?this:this.curve.extended?this._extAdd(e):this._projAdd(e)},u.prototype.mul=function(e){return this._hasDoubles(e)?this.curve._fixedNafMul(this,e):this.curve._wnafMul(this,e)},u.prototype.mulAdd=function(e,t,r){return this.curve._wnafMulAdd(1,[this,t],[e,r],2,!1)},u.prototype.jmulAdd=function(e,t,r){return this.curve._wnafMulAdd(1,[this,t],[e,r],2,!0)},u.prototype.normalize=function(){if(this.zOne)return this;var e=this.z.redInvm();return this.x=this.x.redMul(e),this.y=this.y.redMul(e),this.t&&(this.t=this.t.redMul(e)),this.z=this.curve.one,this.zOne=!0,this},u.prototype.neg=function(){return this.curve.point(this.x.redNeg(),this.y,this.z,this.t&&this.t.redNeg())},u.prototype.getX=function(){return this.normalize(),this.x.fromRed()},u.prototype.getY=function(){return this.normalize(),this.y.fromRed()},u.prototype.eq=function(e){return this===e||0===this.getX().cmp(e.getX())&&0===this.getY().cmp(e.getY())},u.prototype.eqXToP=function(e){var t=e.toRed(this.curve.red).redMul(this.z);if(0===this.x.cmp(t))return!0;for(var r=e.clone(),n=this.curve.redN.redMul(this.z);;){if(r.iadd(this.curve.n),r.cmp(this.curve.p)>=0)return!1;if(t.redIAdd(n),0===this.x.cmp(t))return!0}},u.prototype.toP=u.prototype.normalize,u.prototype.mixedAdd=u.prototype.add},function(e,t,r){"use strict";t.sha1=r(632),t.sha224=r(633),t.sha256=r(269),t.sha384=r(634),t.sha512=r(270)},function(e,t,r){"use strict";var n=r(21),i=r(60),a=r(268),o=n.rotl32,s=n.sum32,c=n.sum32_5,u=a.ft_1,l=i.BlockHash,f=[1518500249,1859775393,2400959708,3395469782];function d(){if(!(this instanceof d))return new d;l.call(this),this.h=[1732584193,4023233417,2562383102,271733878,3285377520],this.W=new Array(80)}n.inherits(d,l),e.exports=d,d.blockSize=512,d.outSize=160,d.hmacStrength=80,d.padLength=64,d.prototype._update=function(e,t){for(var r=this.W,n=0;n<16;n++)r[n]=e[t+n];for(;n<r.length;n++)r[n]=o(r[n-3]^r[n-8]^r[n-14]^r[n-16],1);var i=this.h[0],a=this.h[1],l=this.h[2],d=this.h[3],h=this.h[4];for(n=0;n<r.length;n++){var p=~~(n/20),y=c(o(i,5),u(p,a,l,d),h,r[n],f[p]);h=d,d=l,l=o(a,30),a=i,i=y}this.h[0]=s(this.h[0],i),this.h[1]=s(this.h[1],a),this.h[2]=s(this.h[2],l),this.h[3]=s(this.h[3],d),this.h[4]=s(this.h[4],h)},d.prototype._digest=function(e){return"hex"===e?n.toHex32(this.h,"big"):n.split32(this.h,"big")}},function(e,t,r){"use strict";var n=r(21),i=r(269);function a(){if(!(this instanceof a))return new a;i.call(this),this.h=[3238371032,914150663,812702999,4144912697,4290775857,1750603025,1694076839,3204075428]}n.inherits(a,i),e.exports=a,a.blockSize=512,a.outSize=224,a.hmacStrength=192,a.padLength=64,a.prototype._digest=function(e){return"hex"===e?n.toHex32(this.h.slice(0,7),"big"):n.split32(this.h.slice(0,7),"big")}},function(e,t,r){"use strict";var n=r(21),i=r(270);function a(){if(!(this instanceof a))return new a;i.call(this),this.h=[3418070365,3238371032,1654270250,914150663,2438529370,812702999,355462360,4144912697,1731405415,4290775857,2394180231,1750603025,3675008525,1694076839,1203062813,3204075428]}n.inherits(a,i),e.exports=a,a.blockSize=1024,a.outSize=384,a.hmacStrength=192,a.padLength=128,a.prototype._digest=function(e){return"hex"===e?n.toHex32(this.h.slice(0,12),"big"):n.split32(this.h.slice(0,12),"big")}},function(e,t,r){"use strict";var n=r(21),i=r(60),a=n.rotl32,o=n.sum32,s=n.sum32_3,c=n.sum32_4,u=i.BlockHash;function l(){if(!(this instanceof l))return new l;u.call(this),this.h=[1732584193,4023233417,2562383102,271733878,3285377520],this.endian="little"}function f(e,t,r,n){return e<=15?t^r^n:e<=31?t&r|~t&n:e<=47?(t|~r)^n:e<=63?t&n|r&~n:t^(r|~n)}function d(e){return e<=15?0:e<=31?1518500249:e<=47?1859775393:e<=63?2400959708:2840853838}function h(e){return e<=15?1352829926:e<=31?1548603684:e<=47?1836072691:e<=63?2053994217:0}n.inherits(l,u),t.ripemd160=l,l.blockSize=512,l.outSize=160,l.hmacStrength=192,l.padLength=64,l.prototype._update=function(e,t){for(var r=this.h[0],n=this.h[1],i=this.h[2],u=this.h[3],l=this.h[4],b=r,v=n,_=i,w=u,S=l,E=0;E<80;E++){var x=o(a(c(r,f(E,n,i,u),e[p[E]+t],d(E)),m[E]),l);r=l,l=u,u=a(i,10),i=n,n=x,x=o(a(c(b,f(79-E,v,_,w),e[y[E]+t],h(E)),g[E]),S),b=S,S=w,w=a(_,10),_=v,v=x}x=s(this.h[1],i,w),this.h[1]=s(this.h[2],u,S),this.h[2]=s(this.h[3],l,b),this.h[3]=s(this.h[4],r,v),this.h[4]=s(this.h[0],n,_),this.h[0]=x},l.prototype._digest=function(e){return"hex"===e?n.toHex32(this.h,"little"):n.split32(this.h,"little")};var p=[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,7,4,13,1,10,6,15,3,12,0,9,5,2,14,11,8,3,10,14,4,9,15,8,1,2,7,0,6,13,11,5,12,1,9,11,10,0,8,12,4,13,3,7,15,14,5,6,2,4,0,5,9,7,12,2,10,14,1,3,8,11,6,15,13],y=[5,14,7,0,9,2,11,4,13,6,15,8,1,10,3,12,6,11,3,7,0,13,5,10,14,15,8,12,4,9,1,2,15,5,1,3,7,14,6,9,11,8,12,2,10,0,4,13,8,6,4,1,3,11,15,0,5,12,2,13,9,7,10,14,12,15,10,4,1,5,8,7,6,2,13,14,0,3,9,11],m=[11,14,15,12,5,8,7,9,11,13,14,15,6,7,9,8,7,6,8,13,11,9,7,15,7,12,15,9,11,7,13,12,11,13,6,7,14,9,13,15,14,8,13,6,5,12,7,5,11,12,14,15,14,15,9,8,9,14,5,6,8,6,5,12,9,15,5,11,6,8,13,12,5,12,13,14,11,8,5,6],g=[8,9,9,11,13,15,15,5,7,7,8,11,14,14,12,6,9,13,15,7,12,8,9,11,7,7,12,7,6,15,13,11,9,7,15,11,8,6,6,14,12,13,5,14,13,13,7,5,15,5,8,11,14,14,6,14,6,9,12,9,12,5,15,8,8,5,12,9,12,5,14,6,8,13,6,5,15,13,11,11]},function(e,t,r){"use strict";var n=r(21),i=r(16);function a(e,t,r){if(!(this instanceof a))return new a(e,t,r);this.Hash=e,this.blockSize=e.blockSize/8,this.outSize=e.outSize/8,this.inner=null,this.outer=null,this._init(n.toArray(t,r))}e.exports=a,a.prototype._init=function(e){e.length>this.blockSize&&(e=(new this.Hash).update(e).digest()),i(e.length<=this.blockSize);for(var t=e.length;t<this.blockSize;t++)e.push(0);for(t=0;t<e.length;t++)e[t]^=54;for(this.inner=(new this.Hash).update(e),t=0;t<e.length;t++)e[t]^=106;this.outer=(new this.Hash).update(e)},a.prototype.update=function(e,t){return this.inner.update(e,t),this},a.prototype.digest=function(e){return this.outer.update(this.inner.digest()),this.outer.digest(e)}},function(e,t){e.exports={doubles:{step:4,points:[["e60fce93b59e9ec53011aabc21c23e97b2a31369b87a5ae9c44ee89e2a6dec0a","f7e3507399e595929db99f34f57937101296891e44d23f0be1f32cce69616821"],["8282263212c609d9ea2a6e3e172de238d8c39cabd5ac1ca10646e23fd5f51508","11f8a8098557dfe45e8256e830b60ace62d613ac2f7b17bed31b6eaff6e26caf"],["175e159f728b865a72f99cc6c6fc846de0b93833fd2222ed73fce5b551e5b739","d3506e0d9e3c79eba4ef97a51ff71f5eacb5955add24345c6efa6ffee9fed695"],["363d90d447b00c9c99ceac05b6262ee053441c7e55552ffe526bad8f83ff4640","4e273adfc732221953b445397f3363145b9a89008199ecb62003c7f3bee9de9"],["8b4b5f165df3c2be8c6244b5b745638843e4a781a15bcd1b69f79a55dffdf80c","4aad0a6f68d308b4b3fbd7813ab0da04f9e336546162ee56b3eff0c65fd4fd36"],["723cbaa6e5db996d6bf771c00bd548c7b700dbffa6c0e77bcb6115925232fcda","96e867b5595cc498a921137488824d6e2660a0653779494801dc069d9eb39f5f"],["eebfa4d493bebf98ba5feec812c2d3b50947961237a919839a533eca0e7dd7fa","5d9a8ca3970ef0f269ee7edaf178089d9ae4cdc3a711f712ddfd4fdae1de8999"],["100f44da696e71672791d0a09b7bde459f1215a29b3c03bfefd7835b39a48db0","cdd9e13192a00b772ec8f3300c090666b7ff4a18ff5195ac0fbd5cd62bc65a09"],["e1031be262c7ed1b1dc9227a4a04c017a77f8d4464f3b3852c8acde6e534fd2d","9d7061928940405e6bb6a4176597535af292dd419e1ced79a44f18f29456a00d"],["feea6cae46d55b530ac2839f143bd7ec5cf8b266a41d6af52d5e688d9094696d","e57c6b6c97dce1bab06e4e12bf3ecd5c981c8957cc41442d3155debf18090088"],["da67a91d91049cdcb367be4be6ffca3cfeed657d808583de33fa978bc1ec6cb1","9bacaa35481642bc41f463f7ec9780e5dec7adc508f740a17e9ea8e27a68be1d"],["53904faa0b334cdda6e000935ef22151ec08d0f7bb11069f57545ccc1a37b7c0","5bc087d0bc80106d88c9eccac20d3c1c13999981e14434699dcb096b022771c8"],["8e7bcd0bd35983a7719cca7764ca906779b53a043a9b8bcaeff959f43ad86047","10b7770b2a3da4b3940310420ca9514579e88e2e47fd68b3ea10047e8460372a"],["385eed34c1cdff21e6d0818689b81bde71a7f4f18397e6690a841e1599c43862","283bebc3e8ea23f56701de19e9ebf4576b304eec2086dc8cc0458fe5542e5453"],["6f9d9b803ecf191637c73a4413dfa180fddf84a5947fbc9c606ed86c3fac3a7","7c80c68e603059ba69b8e2a30e45c4d47ea4dd2f5c281002d86890603a842160"],["3322d401243c4e2582a2147c104d6ecbf774d163db0f5e5313b7e0e742d0e6bd","56e70797e9664ef5bfb019bc4ddaf9b72805f63ea2873af624f3a2e96c28b2a0"],["85672c7d2de0b7da2bd1770d89665868741b3f9af7643397721d74d28134ab83","7c481b9b5b43b2eb6374049bfa62c2e5e77f17fcc5298f44c8e3094f790313a6"],["948bf809b1988a46b06c9f1919413b10f9226c60f668832ffd959af60c82a0a","53a562856dcb6646dc6b74c5d1c3418c6d4dff08c97cd2bed4cb7f88d8c8e589"],["6260ce7f461801c34f067ce0f02873a8f1b0e44dfc69752accecd819f38fd8e8","bc2da82b6fa5b571a7f09049776a1ef7ecd292238051c198c1a84e95b2b4ae17"],["e5037de0afc1d8d43d8348414bbf4103043ec8f575bfdc432953cc8d2037fa2d","4571534baa94d3b5f9f98d09fb990bddbd5f5b03ec481f10e0e5dc841d755bda"],["e06372b0f4a207adf5ea905e8f1771b4e7e8dbd1c6a6c5b725866a0ae4fce725","7a908974bce18cfe12a27bb2ad5a488cd7484a7787104870b27034f94eee31dd"],["213c7a715cd5d45358d0bbf9dc0ce02204b10bdde2a3f58540ad6908d0559754","4b6dad0b5ae462507013ad06245ba190bb4850f5f36a7eeddff2c27534b458f2"],["4e7c272a7af4b34e8dbb9352a5419a87e2838c70adc62cddf0cc3a3b08fbd53c","17749c766c9d0b18e16fd09f6def681b530b9614bff7dd33e0b3941817dcaae6"],["fea74e3dbe778b1b10f238ad61686aa5c76e3db2be43057632427e2840fb27b6","6e0568db9b0b13297cf674deccb6af93126b596b973f7b77701d3db7f23cb96f"],["76e64113f677cf0e10a2570d599968d31544e179b760432952c02a4417bdde39","c90ddf8dee4e95cf577066d70681f0d35e2a33d2b56d2032b4b1752d1901ac01"],["c738c56b03b2abe1e8281baa743f8f9a8f7cc643df26cbee3ab150242bcbb891","893fb578951ad2537f718f2eacbfbbbb82314eef7880cfe917e735d9699a84c3"],["d895626548b65b81e264c7637c972877d1d72e5f3a925014372e9f6588f6c14b","febfaa38f2bc7eae728ec60818c340eb03428d632bb067e179363ed75d7d991f"],["b8da94032a957518eb0f6433571e8761ceffc73693e84edd49150a564f676e03","2804dfa44805a1e4d7c99cc9762808b092cc584d95ff3b511488e4e74efdf6e7"],["e80fea14441fb33a7d8adab9475d7fab2019effb5156a792f1a11778e3c0df5d","eed1de7f638e00771e89768ca3ca94472d155e80af322ea9fcb4291b6ac9ec78"],["a301697bdfcd704313ba48e51d567543f2a182031efd6915ddc07bbcc4e16070","7370f91cfb67e4f5081809fa25d40f9b1735dbf7c0a11a130c0d1a041e177ea1"],["90ad85b389d6b936463f9d0512678de208cc330b11307fffab7ac63e3fb04ed4","e507a3620a38261affdcbd9427222b839aefabe1582894d991d4d48cb6ef150"],["8f68b9d2f63b5f339239c1ad981f162ee88c5678723ea3351b7b444c9ec4c0da","662a9f2dba063986de1d90c2b6be215dbbea2cfe95510bfdf23cbf79501fff82"],["e4f3fb0176af85d65ff99ff9198c36091f48e86503681e3e6686fd5053231e11","1e63633ad0ef4f1c1661a6d0ea02b7286cc7e74ec951d1c9822c38576feb73bc"],["8c00fa9b18ebf331eb961537a45a4266c7034f2f0d4e1d0716fb6eae20eae29e","efa47267fea521a1a9dc343a3736c974c2fadafa81e36c54e7d2a4c66702414b"],["e7a26ce69dd4829f3e10cec0a9e98ed3143d084f308b92c0997fddfc60cb3e41","2a758e300fa7984b471b006a1aafbb18d0a6b2c0420e83e20e8a9421cf2cfd51"],["b6459e0ee3662ec8d23540c223bcbdc571cbcb967d79424f3cf29eb3de6b80ef","67c876d06f3e06de1dadf16e5661db3c4b3ae6d48e35b2ff30bf0b61a71ba45"],["d68a80c8280bb840793234aa118f06231d6f1fc67e73c5a5deda0f5b496943e8","db8ba9fff4b586d00c4b1f9177b0e28b5b0e7b8f7845295a294c84266b133120"],["324aed7df65c804252dc0270907a30b09612aeb973449cea4095980fc28d3d5d","648a365774b61f2ff130c0c35aec1f4f19213b0c7e332843967224af96ab7c84"],["4df9c14919cde61f6d51dfdbe5fee5dceec4143ba8d1ca888e8bd373fd054c96","35ec51092d8728050974c23a1d85d4b5d506cdc288490192ebac06cad10d5d"],["9c3919a84a474870faed8a9c1cc66021523489054d7f0308cbfc99c8ac1f98cd","ddb84f0f4a4ddd57584f044bf260e641905326f76c64c8e6be7e5e03d4fc599d"],["6057170b1dd12fdf8de05f281d8e06bb91e1493a8b91d4cc5a21382120a959e5","9a1af0b26a6a4807add9a2daf71df262465152bc3ee24c65e899be932385a2a8"],["a576df8e23a08411421439a4518da31880cef0fba7d4df12b1a6973eecb94266","40a6bf20e76640b2c92b97afe58cd82c432e10a7f514d9f3ee8be11ae1b28ec8"],["7778a78c28dec3e30a05fe9629de8c38bb30d1f5cf9a3a208f763889be58ad71","34626d9ab5a5b22ff7098e12f2ff580087b38411ff24ac563b513fc1fd9f43ac"],["928955ee637a84463729fd30e7afd2ed5f96274e5ad7e5cb09eda9c06d903ac","c25621003d3f42a827b78a13093a95eeac3d26efa8a8d83fc5180e935bcd091f"],["85d0fef3ec6db109399064f3a0e3b2855645b4a907ad354527aae75163d82751","1f03648413a38c0be29d496e582cf5663e8751e96877331582c237a24eb1f962"],["ff2b0dce97eece97c1c9b6041798b85dfdfb6d8882da20308f5404824526087e","493d13fef524ba188af4c4dc54d07936c7b7ed6fb90e2ceb2c951e01f0c29907"],["827fbbe4b1e880ea9ed2b2e6301b212b57f1ee148cd6dd28780e5e2cf856e241","c60f9c923c727b0b71bef2c67d1d12687ff7a63186903166d605b68baec293ec"],["eaa649f21f51bdbae7be4ae34ce6e5217a58fdce7f47f9aa7f3b58fa2120e2b3","be3279ed5bbbb03ac69a80f89879aa5a01a6b965f13f7e59d47a5305ba5ad93d"],["e4a42d43c5cf169d9391df6decf42ee541b6d8f0c9a137401e23632dda34d24f","4d9f92e716d1c73526fc99ccfb8ad34ce886eedfa8d8e4f13a7f7131deba9414"],["1ec80fef360cbdd954160fadab352b6b92b53576a88fea4947173b9d4300bf19","aeefe93756b5340d2f3a4958a7abbf5e0146e77f6295a07b671cdc1cc107cefd"],["146a778c04670c2f91b00af4680dfa8bce3490717d58ba889ddb5928366642be","b318e0ec3354028add669827f9d4b2870aaa971d2f7e5ed1d0b297483d83efd0"],["fa50c0f61d22e5f07e3acebb1aa07b128d0012209a28b9776d76a8793180eef9","6b84c6922397eba9b72cd2872281a68a5e683293a57a213b38cd8d7d3f4f2811"],["da1d61d0ca721a11b1a5bf6b7d88e8421a288ab5d5bba5220e53d32b5f067ec2","8157f55a7c99306c79c0766161c91e2966a73899d279b48a655fba0f1ad836f1"],["a8e282ff0c9706907215ff98e8fd416615311de0446f1e062a73b0610d064e13","7f97355b8db81c09abfb7f3c5b2515888b679a3e50dd6bd6cef7c73111f4cc0c"],["174a53b9c9a285872d39e56e6913cab15d59b1fa512508c022f382de8319497c","ccc9dc37abfc9c1657b4155f2c47f9e6646b3a1d8cb9854383da13ac079afa73"],["959396981943785c3d3e57edf5018cdbe039e730e4918b3d884fdff09475b7ba","2e7e552888c331dd8ba0386a4b9cd6849c653f64c8709385e9b8abf87524f2fd"],["d2a63a50ae401e56d645a1153b109a8fcca0a43d561fba2dbb51340c9d82b151","e82d86fb6443fcb7565aee58b2948220a70f750af484ca52d4142174dcf89405"],["64587e2335471eb890ee7896d7cfdc866bacbdbd3839317b3436f9b45617e073","d99fcdd5bf6902e2ae96dd6447c299a185b90a39133aeab358299e5e9faf6589"],["8481bde0e4e4d885b3a546d3e549de042f0aa6cea250e7fd358d6c86dd45e458","38ee7b8cba5404dd84a25bf39cecb2ca900a79c42b262e556d64b1b59779057e"],["13464a57a78102aa62b6979ae817f4637ffcfed3c4b1ce30bcd6303f6caf666b","69be159004614580ef7e433453ccb0ca48f300a81d0942e13f495a907f6ecc27"],["bc4a9df5b713fe2e9aef430bcc1dc97a0cd9ccede2f28588cada3a0d2d83f366","d3a81ca6e785c06383937adf4b798caa6e8a9fbfa547b16d758d666581f33c1"],["8c28a97bf8298bc0d23d8c749452a32e694b65e30a9472a3954ab30fe5324caa","40a30463a3305193378fedf31f7cc0eb7ae784f0451cb9459e71dc73cbef9482"],["8ea9666139527a8c1dd94ce4f071fd23c8b350c5a4bb33748c4ba111faccae0","620efabbc8ee2782e24e7c0cfb95c5d735b783be9cf0f8e955af34a30e62b945"],["dd3625faef5ba06074669716bbd3788d89bdde815959968092f76cc4eb9a9787","7a188fa3520e30d461da2501045731ca941461982883395937f68d00c644a573"],["f710d79d9eb962297e4f6232b40e8f7feb2bc63814614d692c12de752408221e","ea98e67232d3b3295d3b535532115ccac8612c721851617526ae47a9c77bfc82"]]},naf:{wnd:7,points:[["f9308a019258c31049344f85f89d5229b531c845836f99b08601f113bce036f9","388f7b0f632de8140fe337e62a37f3566500a99934c2231b6cb9fd7584b8e672"],["2f8bde4d1a07209355b4a7250a5c5128e88b84bddc619ab7cba8d569b240efe4","d8ac222636e5e3d6d4dba9dda6c9c426f788271bab0d6840dca87d3aa6ac62d6"],["5cbdf0646e5db4eaa398f365f2ea7a0e3d419b7e0330e39ce92bddedcac4f9bc","6aebca40ba255960a3178d6d861a54dba813d0b813fde7b5a5082628087264da"],["acd484e2f0c7f65309ad178a9f559abde09796974c57e714c35f110dfc27ccbe","cc338921b0a7d9fd64380971763b61e9add888a4375f8e0f05cc262ac64f9c37"],["774ae7f858a9411e5ef4246b70c65aac5649980be5c17891bbec17895da008cb","d984a032eb6b5e190243dd56d7b7b365372db1e2dff9d6a8301d74c9c953c61b"],["f28773c2d975288bc7d1d205c3748651b075fbc6610e58cddeeddf8f19405aa8","ab0902e8d880a89758212eb65cdaf473a1a06da521fa91f29b5cb52db03ed81"],["d7924d4f7d43ea965a465ae3095ff41131e5946f3c85f79e44adbcf8e27e080e","581e2872a86c72a683842ec228cc6defea40af2bd896d3a5c504dc9ff6a26b58"],["defdea4cdb677750a420fee807eacf21eb9898ae79b9768766e4faa04a2d4a34","4211ab0694635168e997b0ead2a93daeced1f4a04a95c0f6cfb199f69e56eb77"],["2b4ea0a797a443d293ef5cff444f4979f06acfebd7e86d277475656138385b6c","85e89bc037945d93b343083b5a1c86131a01f60c50269763b570c854e5c09b7a"],["352bbf4a4cdd12564f93fa332ce333301d9ad40271f8107181340aef25be59d5","321eb4075348f534d59c18259dda3e1f4a1b3b2e71b1039c67bd3d8bcf81998c"],["2fa2104d6b38d11b0230010559879124e42ab8dfeff5ff29dc9cdadd4ecacc3f","2de1068295dd865b64569335bd5dd80181d70ecfc882648423ba76b532b7d67"],["9248279b09b4d68dab21a9b066edda83263c3d84e09572e269ca0cd7f5453714","73016f7bf234aade5d1aa71bdea2b1ff3fc0de2a887912ffe54a32ce97cb3402"],["daed4f2be3a8bf278e70132fb0beb7522f570e144bf615c07e996d443dee8729","a69dce4a7d6c98e8d4a1aca87ef8d7003f83c230f3afa726ab40e52290be1c55"],["c44d12c7065d812e8acf28d7cbb19f9011ecd9e9fdf281b0e6a3b5e87d22e7db","2119a460ce326cdc76c45926c982fdac0e106e861edf61c5a039063f0e0e6482"],["6a245bf6dc698504c89a20cfded60853152b695336c28063b61c65cbd269e6b4","e022cf42c2bd4a708b3f5126f16a24ad8b33ba48d0423b6efd5e6348100d8a82"],["1697ffa6fd9de627c077e3d2fe541084ce13300b0bec1146f95ae57f0d0bd6a5","b9c398f186806f5d27561506e4557433a2cf15009e498ae7adee9d63d01b2396"],["605bdb019981718b986d0f07e834cb0d9deb8360ffb7f61df982345ef27a7479","2972d2de4f8d20681a78d93ec96fe23c26bfae84fb14db43b01e1e9056b8c49"],["62d14dab4150bf497402fdc45a215e10dcb01c354959b10cfe31c7e9d87ff33d","80fc06bd8cc5b01098088a1950eed0db01aa132967ab472235f5642483b25eaf"],["80c60ad0040f27dade5b4b06c408e56b2c50e9f56b9b8b425e555c2f86308b6f","1c38303f1cc5c30f26e66bad7fe72f70a65eed4cbe7024eb1aa01f56430bd57a"],["7a9375ad6167ad54aa74c6348cc54d344cc5dc9487d847049d5eabb0fa03c8fb","d0e3fa9eca8726909559e0d79269046bdc59ea10c70ce2b02d499ec224dc7f7"],["d528ecd9b696b54c907a9ed045447a79bb408ec39b68df504bb51f459bc3ffc9","eecf41253136e5f99966f21881fd656ebc4345405c520dbc063465b521409933"],["49370a4b5f43412ea25f514e8ecdad05266115e4a7ecb1387231808f8b45963","758f3f41afd6ed428b3081b0512fd62a54c3f3afbb5b6764b653052a12949c9a"],["77f230936ee88cbbd73df930d64702ef881d811e0e1498e2f1c13eb1fc345d74","958ef42a7886b6400a08266e9ba1b37896c95330d97077cbbe8eb3c7671c60d6"],["f2dac991cc4ce4b9ea44887e5c7c0bce58c80074ab9d4dbaeb28531b7739f530","e0dedc9b3b2f8dad4da1f32dec2531df9eb5fbeb0598e4fd1a117dba703a3c37"],["463b3d9f662621fb1b4be8fbbe2520125a216cdfc9dae3debcba4850c690d45b","5ed430d78c296c3543114306dd8622d7c622e27c970a1de31cb377b01af7307e"],["f16f804244e46e2a09232d4aff3b59976b98fac14328a2d1a32496b49998f247","cedabd9b82203f7e13d206fcdf4e33d92a6c53c26e5cce26d6579962c4e31df6"],["caf754272dc84563b0352b7a14311af55d245315ace27c65369e15f7151d41d1","cb474660ef35f5f2a41b643fa5e460575f4fa9b7962232a5c32f908318a04476"],["2600ca4b282cb986f85d0f1709979d8b44a09c07cb86d7c124497bc86f082120","4119b88753c15bd6a693b03fcddbb45d5ac6be74ab5f0ef44b0be9475a7e4b40"],["7635ca72d7e8432c338ec53cd12220bc01c48685e24f7dc8c602a7746998e435","91b649609489d613d1d5e590f78e6d74ecfc061d57048bad9e76f302c5b9c61"],["754e3239f325570cdbbf4a87deee8a66b7f2b33479d468fbc1a50743bf56cc18","673fb86e5bda30fb3cd0ed304ea49a023ee33d0197a695d0c5d98093c536683"],["e3e6bd1071a1e96aff57859c82d570f0330800661d1c952f9fe2694691d9b9e8","59c9e0bba394e76f40c0aa58379a3cb6a5a2283993e90c4167002af4920e37f5"],["186b483d056a033826ae73d88f732985c4ccb1f32ba35f4b4cc47fdcf04aa6eb","3b952d32c67cf77e2e17446e204180ab21fb8090895138b4a4a797f86e80888b"],["df9d70a6b9876ce544c98561f4be4f725442e6d2b737d9c91a8321724ce0963f","55eb2dafd84d6ccd5f862b785dc39d4ab157222720ef9da217b8c45cf2ba2417"],["5edd5cc23c51e87a497ca815d5dce0f8ab52554f849ed8995de64c5f34ce7143","efae9c8dbc14130661e8cec030c89ad0c13c66c0d17a2905cdc706ab7399a868"],["290798c2b6476830da12fe02287e9e777aa3fba1c355b17a722d362f84614fba","e38da76dcd440621988d00bcf79af25d5b29c094db2a23146d003afd41943e7a"],["af3c423a95d9f5b3054754efa150ac39cd29552fe360257362dfdecef4053b45","f98a3fd831eb2b749a93b0e6f35cfb40c8cd5aa667a15581bc2feded498fd9c6"],["766dbb24d134e745cccaa28c99bf274906bb66b26dcf98df8d2fed50d884249a","744b1152eacbe5e38dcc887980da38b897584a65fa06cedd2c924f97cbac5996"],["59dbf46f8c94759ba21277c33784f41645f7b44f6c596a58ce92e666191abe3e","c534ad44175fbc300f4ea6ce648309a042ce739a7919798cd85e216c4a307f6e"],["f13ada95103c4537305e691e74e9a4a8dd647e711a95e73cb62dc6018cfd87b8","e13817b44ee14de663bf4bc808341f326949e21a6a75c2570778419bdaf5733d"],["7754b4fa0e8aced06d4167a2c59cca4cda1869c06ebadfb6488550015a88522c","30e93e864e669d82224b967c3020b8fa8d1e4e350b6cbcc537a48b57841163a2"],["948dcadf5990e048aa3874d46abef9d701858f95de8041d2a6828c99e2262519","e491a42537f6e597d5d28a3224b1bc25df9154efbd2ef1d2cbba2cae5347d57e"],["7962414450c76c1689c7b48f8202ec37fb224cf5ac0bfa1570328a8a3d7c77ab","100b610ec4ffb4760d5c1fc133ef6f6b12507a051f04ac5760afa5b29db83437"],["3514087834964b54b15b160644d915485a16977225b8847bb0dd085137ec47ca","ef0afbb2056205448e1652c48e8127fc6039e77c15c2378b7e7d15a0de293311"],["d3cc30ad6b483e4bc79ce2c9dd8bc54993e947eb8df787b442943d3f7b527eaf","8b378a22d827278d89c5e9be8f9508ae3c2ad46290358630afb34db04eede0a4"],["1624d84780732860ce1c78fcbfefe08b2b29823db913f6493975ba0ff4847610","68651cf9b6da903e0914448c6cd9d4ca896878f5282be4c8cc06e2a404078575"],["733ce80da955a8a26902c95633e62a985192474b5af207da6df7b4fd5fc61cd4","f5435a2bd2badf7d485a4d8b8db9fcce3e1ef8e0201e4578c54673bc1dc5ea1d"],["15d9441254945064cf1a1c33bbd3b49f8966c5092171e699ef258dfab81c045c","d56eb30b69463e7234f5137b73b84177434800bacebfc685fc37bbe9efe4070d"],["a1d0fcf2ec9de675b612136e5ce70d271c21417c9d2b8aaaac138599d0717940","edd77f50bcb5a3cab2e90737309667f2641462a54070f3d519212d39c197a629"],["e22fbe15c0af8ccc5780c0735f84dbe9a790badee8245c06c7ca37331cb36980","a855babad5cd60c88b430a69f53a1a7a38289154964799be43d06d77d31da06"],["311091dd9860e8e20ee13473c1155f5f69635e394704eaa74009452246cfa9b3","66db656f87d1f04fffd1f04788c06830871ec5a64feee685bd80f0b1286d8374"],["34c1fd04d301be89b31c0442d3e6ac24883928b45a9340781867d4232ec2dbdf","9414685e97b1b5954bd46f730174136d57f1ceeb487443dc5321857ba73abee"],["f219ea5d6b54701c1c14de5b557eb42a8d13f3abbcd08affcc2a5e6b049b8d63","4cb95957e83d40b0f73af4544cccf6b1f4b08d3c07b27fb8d8c2962a400766d1"],["d7b8740f74a8fbaab1f683db8f45de26543a5490bca627087236912469a0b448","fa77968128d9c92ee1010f337ad4717eff15db5ed3c049b3411e0315eaa4593b"],["32d31c222f8f6f0ef86f7c98d3a3335ead5bcd32abdd94289fe4d3091aa824bf","5f3032f5892156e39ccd3d7915b9e1da2e6dac9e6f26e961118d14b8462e1661"],["7461f371914ab32671045a155d9831ea8793d77cd59592c4340f86cbc18347b5","8ec0ba238b96bec0cbdddcae0aa442542eee1ff50c986ea6b39847b3cc092ff6"],["ee079adb1df1860074356a25aa38206a6d716b2c3e67453d287698bad7b2b2d6","8dc2412aafe3be5c4c5f37e0ecc5f9f6a446989af04c4e25ebaac479ec1c8c1e"],["16ec93e447ec83f0467b18302ee620f7e65de331874c9dc72bfd8616ba9da6b5","5e4631150e62fb40d0e8c2a7ca5804a39d58186a50e497139626778e25b0674d"],["eaa5f980c245f6f038978290afa70b6bd8855897f98b6aa485b96065d537bd99","f65f5d3e292c2e0819a528391c994624d784869d7e6ea67fb18041024edc07dc"],["78c9407544ac132692ee1910a02439958ae04877151342ea96c4b6b35a49f51","f3e0319169eb9b85d5404795539a5e68fa1fbd583c064d2462b675f194a3ddb4"],["494f4be219a1a77016dcd838431aea0001cdc8ae7a6fc688726578d9702857a5","42242a969283a5f339ba7f075e36ba2af925ce30d767ed6e55f4b031880d562c"],["a598a8030da6d86c6bc7f2f5144ea549d28211ea58faa70ebf4c1e665c1fe9b5","204b5d6f84822c307e4b4a7140737aec23fc63b65b35f86a10026dbd2d864e6b"],["c41916365abb2b5d09192f5f2dbeafec208f020f12570a184dbadc3e58595997","4f14351d0087efa49d245b328984989d5caf9450f34bfc0ed16e96b58fa9913"],["841d6063a586fa475a724604da03bc5b92a2e0d2e0a36acfe4c73a5514742881","73867f59c0659e81904f9a1c7543698e62562d6744c169ce7a36de01a8d6154"],["5e95bb399a6971d376026947f89bde2f282b33810928be4ded112ac4d70e20d5","39f23f366809085beebfc71181313775a99c9aed7d8ba38b161384c746012865"],["36e4641a53948fd476c39f8a99fd974e5ec07564b5315d8bf99471bca0ef2f66","d2424b1b1abe4eb8164227b085c9aa9456ea13493fd563e06fd51cf5694c78fc"],["336581ea7bfbbb290c191a2f507a41cf5643842170e914faeab27c2c579f726","ead12168595fe1be99252129b6e56b3391f7ab1410cd1e0ef3dcdcabd2fda224"],["8ab89816dadfd6b6a1f2634fcf00ec8403781025ed6890c4849742706bd43ede","6fdcef09f2f6d0a044e654aef624136f503d459c3e89845858a47a9129cdd24e"],["1e33f1a746c9c5778133344d9299fcaa20b0938e8acff2544bb40284b8c5fb94","60660257dd11b3aa9c8ed618d24edff2306d320f1d03010e33a7d2057f3b3b6"],["85b7c1dcb3cec1b7ee7f30ded79dd20a0ed1f4cc18cbcfcfa410361fd8f08f31","3d98a9cdd026dd43f39048f25a8847f4fcafad1895d7a633c6fed3c35e999511"],["29df9fbd8d9e46509275f4b125d6d45d7fbe9a3b878a7af872a2800661ac5f51","b4c4fe99c775a606e2d8862179139ffda61dc861c019e55cd2876eb2a27d84b"],["a0b1cae06b0a847a3fea6e671aaf8adfdfe58ca2f768105c8082b2e449fce252","ae434102edde0958ec4b19d917a6a28e6b72da1834aff0e650f049503a296cf2"],["4e8ceafb9b3e9a136dc7ff67e840295b499dfb3b2133e4ba113f2e4c0e121e5","cf2174118c8b6d7a4b48f6d534ce5c79422c086a63460502b827ce62a326683c"],["d24a44e047e19b6f5afb81c7ca2f69080a5076689a010919f42725c2b789a33b","6fb8d5591b466f8fc63db50f1c0f1c69013f996887b8244d2cdec417afea8fa3"],["ea01606a7a6c9cdd249fdfcfacb99584001edd28abbab77b5104e98e8e3b35d4","322af4908c7312b0cfbfe369f7a7b3cdb7d4494bc2823700cfd652188a3ea98d"],["af8addbf2b661c8a6c6328655eb96651252007d8c5ea31be4ad196de8ce2131f","6749e67c029b85f52a034eafd096836b2520818680e26ac8f3dfbcdb71749700"],["e3ae1974566ca06cc516d47e0fb165a674a3dabcfca15e722f0e3450f45889","2aeabe7e4531510116217f07bf4d07300de97e4874f81f533420a72eeb0bd6a4"],["591ee355313d99721cf6993ffed1e3e301993ff3ed258802075ea8ced397e246","b0ea558a113c30bea60fc4775460c7901ff0b053d25ca2bdeee98f1a4be5d196"],["11396d55fda54c49f19aa97318d8da61fa8584e47b084945077cf03255b52984","998c74a8cd45ac01289d5833a7beb4744ff536b01b257be4c5767bea93ea57a4"],["3c5d2a1ba39c5a1790000738c9e0c40b8dcdfd5468754b6405540157e017aa7a","b2284279995a34e2f9d4de7396fc18b80f9b8b9fdd270f6661f79ca4c81bd257"],["cc8704b8a60a0defa3a99a7299f2e9c3fbc395afb04ac078425ef8a1793cc030","bdd46039feed17881d1e0862db347f8cf395b74fc4bcdc4e940b74e3ac1f1b13"],["c533e4f7ea8555aacd9777ac5cad29b97dd4defccc53ee7ea204119b2889b197","6f0a256bc5efdf429a2fb6242f1a43a2d9b925bb4a4b3a26bb8e0f45eb596096"],["c14f8f2ccb27d6f109f6d08d03cc96a69ba8c34eec07bbcf566d48e33da6593","c359d6923bb398f7fd4473e16fe1c28475b740dd098075e6c0e8649113dc3a38"],["a6cbc3046bc6a450bac24789fa17115a4c9739ed75f8f21ce441f72e0b90e6ef","21ae7f4680e889bb130619e2c0f95a360ceb573c70603139862afd617fa9b9f"],["347d6d9a02c48927ebfb86c1359b1caf130a3c0267d11ce6344b39f99d43cc38","60ea7f61a353524d1c987f6ecec92f086d565ab687870cb12689ff1e31c74448"],["da6545d2181db8d983f7dcb375ef5866d47c67b1bf31c8cf855ef7437b72656a","49b96715ab6878a79e78f07ce5680c5d6673051b4935bd897fea824b77dc208a"],["c40747cc9d012cb1a13b8148309c6de7ec25d6945d657146b9d5994b8feb1111","5ca560753be2a12fc6de6caf2cb489565db936156b9514e1bb5e83037e0fa2d4"],["4e42c8ec82c99798ccf3a610be870e78338c7f713348bd34c8203ef4037f3502","7571d74ee5e0fb92a7a8b33a07783341a5492144cc54bcc40a94473693606437"],["3775ab7089bc6af823aba2e1af70b236d251cadb0c86743287522a1b3b0dedea","be52d107bcfa09d8bcb9736a828cfa7fac8db17bf7a76a2c42ad961409018cf7"],["cee31cbf7e34ec379d94fb814d3d775ad954595d1314ba8846959e3e82f74e26","8fd64a14c06b589c26b947ae2bcf6bfa0149ef0be14ed4d80f448a01c43b1c6d"],["b4f9eaea09b6917619f6ea6a4eb5464efddb58fd45b1ebefcdc1a01d08b47986","39e5c9925b5a54b07433a4f18c61726f8bb131c012ca542eb24a8ac07200682a"],["d4263dfc3d2df923a0179a48966d30ce84e2515afc3dccc1b77907792ebcc60e","62dfaf07a0f78feb30e30d6295853ce189e127760ad6cf7fae164e122a208d54"],["48457524820fa65a4f8d35eb6930857c0032acc0a4a2de422233eeda897612c4","25a748ab367979d98733c38a1fa1c2e7dc6cc07db2d60a9ae7a76aaa49bd0f77"],["dfeeef1881101f2cb11644f3a2afdfc2045e19919152923f367a1767c11cceda","ecfb7056cf1de042f9420bab396793c0c390bde74b4bbdff16a83ae09a9a7517"],["6d7ef6b17543f8373c573f44e1f389835d89bcbc6062ced36c82df83b8fae859","cd450ec335438986dfefa10c57fea9bcc521a0959b2d80bbf74b190dca712d10"],["e75605d59102a5a2684500d3b991f2e3f3c88b93225547035af25af66e04541f","f5c54754a8f71ee540b9b48728473e314f729ac5308b06938360990e2bfad125"],["eb98660f4c4dfaa06a2be453d5020bc99a0c2e60abe388457dd43fefb1ed620c","6cb9a8876d9cb8520609af3add26cd20a0a7cd8a9411131ce85f44100099223e"],["13e87b027d8514d35939f2e6892b19922154596941888336dc3563e3b8dba942","fef5a3c68059a6dec5d624114bf1e91aac2b9da568d6abeb2570d55646b8adf1"],["ee163026e9fd6fe017c38f06a5be6fc125424b371ce2708e7bf4491691e5764a","1acb250f255dd61c43d94ccc670d0f58f49ae3fa15b96623e5430da0ad6c62b2"],["b268f5ef9ad51e4d78de3a750c2dc89b1e626d43505867999932e5db33af3d80","5f310d4b3c99b9ebb19f77d41c1dee018cf0d34fd4191614003e945a1216e423"],["ff07f3118a9df035e9fad85eb6c7bfe42b02f01ca99ceea3bf7ffdba93c4750d","438136d603e858a3a5c440c38eccbaddc1d2942114e2eddd4740d098ced1f0d8"],["8d8b9855c7c052a34146fd20ffb658bea4b9f69e0d825ebec16e8c3ce2b526a1","cdb559eedc2d79f926baf44fb84ea4d44bcf50fee51d7ceb30e2e7f463036758"],["52db0b5384dfbf05bfa9d472d7ae26dfe4b851ceca91b1eba54263180da32b63","c3b997d050ee5d423ebaf66a6db9f57b3180c902875679de924b69d84a7b375"],["e62f9490d3d51da6395efd24e80919cc7d0f29c3f3fa48c6fff543becbd43352","6d89ad7ba4876b0b22c2ca280c682862f342c8591f1daf5170e07bfd9ccafa7d"],["7f30ea2476b399b4957509c88f77d0191afa2ff5cb7b14fd6d8e7d65aaab1193","ca5ef7d4b231c94c3b15389a5f6311e9daff7bb67b103e9880ef4bff637acaec"],["5098ff1e1d9f14fb46a210fada6c903fef0fb7b4a1dd1d9ac60a0361800b7a00","9731141d81fc8f8084d37c6e7542006b3ee1b40d60dfe5362a5b132fd17ddc0"],["32b78c7de9ee512a72895be6b9cbefa6e2f3c4ccce445c96b9f2c81e2778ad58","ee1849f513df71e32efc3896ee28260c73bb80547ae2275ba497237794c8753c"],["e2cb74fddc8e9fbcd076eef2a7c72b0ce37d50f08269dfc074b581550547a4f7","d3aa2ed71c9dd2247a62df062736eb0baddea9e36122d2be8641abcb005cc4a4"],["8438447566d4d7bedadc299496ab357426009a35f235cb141be0d99cd10ae3a8","c4e1020916980a4da5d01ac5e6ad330734ef0d7906631c4f2390426b2edd791f"],["4162d488b89402039b584c6fc6c308870587d9c46f660b878ab65c82c711d67e","67163e903236289f776f22c25fb8a3afc1732f2b84b4e95dbda47ae5a0852649"],["3fad3fa84caf0f34f0f89bfd2dcf54fc175d767aec3e50684f3ba4a4bf5f683d","cd1bc7cb6cc407bb2f0ca647c718a730cf71872e7d0d2a53fa20efcdfe61826"],["674f2600a3007a00568c1a7ce05d0816c1fb84bf1370798f1c69532faeb1a86b","299d21f9413f33b3edf43b257004580b70db57da0b182259e09eecc69e0d38a5"],["d32f4da54ade74abb81b815ad1fb3b263d82d6c692714bcff87d29bd5ee9f08f","f9429e738b8e53b968e99016c059707782e14f4535359d582fc416910b3eea87"],["30e4e670435385556e593657135845d36fbb6931f72b08cb1ed954f1e3ce3ff6","462f9bce619898638499350113bbc9b10a878d35da70740dc695a559eb88db7b"],["be2062003c51cc3004682904330e4dee7f3dcd10b01e580bf1971b04d4cad297","62188bc49d61e5428573d48a74e1c655b1c61090905682a0d5558ed72dccb9bc"],["93144423ace3451ed29e0fb9ac2af211cb6e84a601df5993c419859fff5df04a","7c10dfb164c3425f5c71a3f9d7992038f1065224f72bb9d1d902a6d13037b47c"],["b015f8044f5fcbdcf21ca26d6c34fb8197829205c7b7d2a7cb66418c157b112c","ab8c1e086d04e813744a655b2df8d5f83b3cdc6faa3088c1d3aea1454e3a1d5f"],["d5e9e1da649d97d89e4868117a465a3a4f8a18de57a140d36b3f2af341a21b52","4cb04437f391ed73111a13cc1d4dd0db1693465c2240480d8955e8592f27447a"],["d3ae41047dd7ca065dbf8ed77b992439983005cd72e16d6f996a5316d36966bb","bd1aeb21ad22ebb22a10f0303417c6d964f8cdd7df0aca614b10dc14d125ac46"],["463e2763d885f958fc66cdd22800f0a487197d0a82e377b49f80af87c897b065","bfefacdb0e5d0fd7df3a311a94de062b26b80c61fbc97508b79992671ef7ca7f"],["7985fdfd127c0567c6f53ec1bb63ec3158e597c40bfe747c83cddfc910641917","603c12daf3d9862ef2b25fe1de289aed24ed291e0ec6708703a5bd567f32ed03"],["74a1ad6b5f76e39db2dd249410eac7f99e74c59cb83d2d0ed5ff1543da7703e9","cc6157ef18c9c63cd6193d83631bbea0093e0968942e8c33d5737fd790e0db08"],["30682a50703375f602d416664ba19b7fc9bab42c72747463a71d0896b22f6da3","553e04f6b018b4fa6c8f39e7f311d3176290d0e0f19ca73f17714d9977a22ff8"],["9e2158f0d7c0d5f26c3791efefa79597654e7a2b2464f52b1ee6c1347769ef57","712fcdd1b9053f09003a3481fa7762e9ffd7c8ef35a38509e2fbf2629008373"],["176e26989a43c9cfeba4029c202538c28172e566e3c4fce7322857f3be327d66","ed8cc9d04b29eb877d270b4878dc43c19aefd31f4eee09ee7b47834c1fa4b1c3"],["75d46efea3771e6e68abb89a13ad747ecf1892393dfc4f1b7004788c50374da8","9852390a99507679fd0b86fd2b39a868d7efc22151346e1a3ca4726586a6bed8"],["809a20c67d64900ffb698c4c825f6d5f2310fb0451c869345b7319f645605721","9e994980d9917e22b76b061927fa04143d096ccc54963e6a5ebfa5f3f8e286c1"],["1b38903a43f7f114ed4500b4eac7083fdefece1cf29c63528d563446f972c180","4036edc931a60ae889353f77fd53de4a2708b26b6f5da72ad3394119daf408f9"]]}}},function(e,t,r){"use strict";var n=r(11),i=r(639),a=r(17),o=r(110),s=r(107),c=a.assert,u=r(640),l=r(641);function f(e){if(!(this instanceof f))return new f(e);"string"==typeof e&&(c(o.hasOwnProperty(e),"Unknown curve "+e),e=o[e]),e instanceof o.PresetCurve&&(e={curve:e}),this.curve=e.curve.curve,this.n=this.curve.n,this.nh=this.n.ushrn(1),this.g=this.curve.g,this.g=e.curve.g,this.g.precompute(e.curve.n.bitLength()+1),this.hash=e.hash||e.curve.hash}e.exports=f,f.prototype.keyPair=function(e){return new u(this,e)},f.prototype.keyFromPrivate=function(e,t){return u.fromPrivate(this,e,t)},f.prototype.keyFromPublic=function(e,t){return u.fromPublic(this,e,t)},f.prototype.genKeyPair=function(e){e||(e={});for(var t=new i({hash:this.hash,pers:e.pers,persEnc:e.persEnc||"utf8",entropy:e.entropy||s(this.hash.hmacStrength),entropyEnc:e.entropy&&e.entropyEnc||"utf8",nonce:this.n.toArray()}),r=this.n.byteLength(),a=this.n.sub(new n(2));;){var o=new n(t.generate(r));if(!(o.cmp(a)>0))return o.iaddn(1),this.keyFromPrivate(o)}},f.prototype._truncateToN=function(e,t){var r=8*e.byteLength()-this.n.bitLength();return r>0&&(e=e.ushrn(r)),!t&&e.cmp(this.n)>=0?e.sub(this.n):e},f.prototype.sign=function(e,t,r,a){"object"==typeof r&&(a=r,r=null),a||(a={}),t=this.keyFromPrivate(t,r),e=this._truncateToN(new n(e,16));for(var o=this.n.byteLength(),s=t.getPrivate().toArray("be",o),c=e.toArray("be",o),u=new i({hash:this.hash,entropy:s,nonce:c,pers:a.pers,persEnc:a.persEnc||"utf8"}),f=this.n.sub(new n(1)),d=0;;d++){var h=a.k?a.k(d):new n(u.generate(this.n.byteLength()));if(!((h=this._truncateToN(h,!0)).cmpn(1)<=0||h.cmp(f)>=0)){var p=this.g.mul(h);if(!p.isInfinity()){var y=p.getX(),m=y.umod(this.n);if(0!==m.cmpn(0)){var g=h.invm(this.n).mul(m.mul(t.getPrivate()).iadd(e));if(0!==(g=g.umod(this.n)).cmpn(0)){var b=(p.getY().isOdd()?1:0)|(0!==y.cmp(m)?2:0);return a.canonical&&g.cmp(this.nh)>0&&(g=this.n.sub(g),b^=1),new l({r:m,s:g,recoveryParam:b})}}}}}},f.prototype.verify=function(e,t,r,i){e=this._truncateToN(new n(e,16)),r=this.keyFromPublic(r,i);var a=(t=new l(t,"hex")).r,o=t.s;if(a.cmpn(1)<0||a.cmp(this.n)>=0)return!1;if(o.cmpn(1)<0||o.cmp(this.n)>=0)return!1;var s,c=o.invm(this.n),u=c.mul(e).umod(this.n),f=c.mul(a).umod(this.n);return this.curve._maxwellTrick?!(s=this.g.jmulAdd(u,r.getPublic(),f)).isInfinity()&&s.eqXToP(a):!(s=this.g.mulAdd(u,r.getPublic(),f)).isInfinity()&&0===s.getX().umod(this.n).cmp(a)},f.prototype.recoverPubKey=function(e,t,r,i){c((3&r)===r,"The recovery param is more than two bits"),t=new l(t,i);var a=this.n,o=new n(e),s=t.r,u=t.s,f=1&r,d=r>>1;if(s.cmp(this.curve.p.umod(this.curve.n))>=0&&d)throw new Error("Unable to find sencond key candinate");s=d?this.curve.pointFromX(s.add(this.curve.n),f):this.curve.pointFromX(s,f);var h=t.r.invm(a),p=a.sub(o).mul(h).umod(a),y=u.mul(h).umod(a);return this.g.mulAdd(p,s,y)},f.prototype.getKeyRecoveryParam=function(e,t,r,n){if(null!==(t=new l(t,n)).recoveryParam)return t.recoveryParam;for(var i=0;i<4;i++){var a;try{a=this.recoverPubKey(e,t,i)}catch(e){continue}if(a.eq(r))return i}throw new Error("Unable to find valid recovery factor")}},function(e,t,r){"use strict";var n=r(111),i=r(266),a=r(16);function o(e){if(!(this instanceof o))return new o(e);this.hash=e.hash,this.predResist=!!e.predResist,this.outLen=this.hash.outSize,this.minEntropy=e.minEntropy||this.hash.hmacStrength,this._reseed=null,this.reseedInterval=null,this.K=null,this.V=null;var t=i.toArray(e.entropy,e.entropyEnc||"hex"),r=i.toArray(e.nonce,e.nonceEnc||"hex"),n=i.toArray(e.pers,e.persEnc||"hex");a(t.length>=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._init(t,r,n)}e.exports=o,o.prototype._init=function(e,t,r){var n=e.concat(t).concat(r);this.K=new Array(this.outLen/8),this.V=new Array(this.outLen/8);for(var i=0;i<this.V.length;i++)this.K[i]=0,this.V[i]=1;this._update(n),this._reseed=1,this.reseedInterval=281474976710656},o.prototype._hmac=function(){return new n.hmac(this.hash,this.K)},o.prototype._update=function(e){var t=this._hmac().update(this.V).update([0]);e&&(t=t.update(e)),this.K=t.digest(),this.V=this._hmac().update(this.V).digest(),e&&(this.K=this._hmac().update(this.V).update([1]).update(e).digest(),this.V=this._hmac().update(this.V).digest())},o.prototype.reseed=function(e,t,r,n){"string"!=typeof t&&(n=r,r=t,t=null),e=i.toArray(e,t),r=i.toArray(r,n),a(e.length>=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._update(e.concat(r||[])),this._reseed=1},o.prototype.generate=function(e,t,r,n){if(this._reseed>this.reseedInterval)throw new Error("Reseed is required");"string"!=typeof t&&(n=r,r=t,t=null),r&&(r=i.toArray(r,n||"hex"),this._update(r));for(var a=[];a.length<e;)this.V=this._hmac().update(this.V).digest(),a=a.concat(this.V);var o=a.slice(0,e);return this._update(r),this._reseed++,i.encode(o,t)}},function(e,t,r){"use strict";var n=r(11),i=r(17).assert;function a(e,t){this.ec=e,this.priv=null,this.pub=null,t.priv&&this._importPrivate(t.priv,t.privEnc),t.pub&&this._importPublic(t.pub,t.pubEnc)}e.exports=a,a.fromPublic=function(e,t,r){return t instanceof a?t:new a(e,{pub:t,pubEnc:r})},a.fromPrivate=function(e,t,r){return t instanceof a?t:new a(e,{priv:t,privEnc:r})},a.prototype.validate=function(){var e=this.getPublic();return e.isInfinity()?{result:!1,reason:"Invalid public key"}:e.validate()?e.mul(this.ec.curve.n).isInfinity()?{result:!0,reason:null}:{result:!1,reason:"Public key * N != O"}:{result:!1,reason:"Public key is not a point"}},a.prototype.getPublic=function(e,t){return"string"==typeof e&&(t=e,e=null),this.pub||(this.pub=this.ec.g.mul(this.priv)),t?this.pub.encode(t,e):this.pub},a.prototype.getPrivate=function(e){return"hex"===e?this.priv.toString(16,2):this.priv},a.prototype._importPrivate=function(e,t){this.priv=new n(e,t||16),this.priv=this.priv.umod(this.ec.curve.n)},a.prototype._importPublic=function(e,t){if(e.x||e.y)return"mont"===this.ec.curve.type?i(e.x,"Need x coordinate"):"short"!==this.ec.curve.type&&"edwards"!==this.ec.curve.type||i(e.x&&e.y,"Need both x and y coordinate"),void(this.pub=this.ec.curve.point(e.x,e.y));this.pub=this.ec.curve.decodePoint(e,t)},a.prototype.derive=function(e){return e.mul(this.priv).getX()},a.prototype.sign=function(e,t,r){return this.ec.sign(e,this,t,r)},a.prototype.verify=function(e,t){return this.ec.verify(e,t,this)},a.prototype.inspect=function(){return"<Key priv: "+(this.priv&&this.priv.toString(16,2))+" pub: "+(this.pub&&this.pub.inspect())+" >"}},function(e,t,r){"use strict";var n=r(11),i=r(17),a=i.assert;function o(e,t){if(e instanceof o)return e;this._importDER(e,t)||(a(e.r&&e.s,"Signature without r or s"),this.r=new n(e.r,16),this.s=new n(e.s,16),void 0===e.recoveryParam?this.recoveryParam=null:this.recoveryParam=e.recoveryParam)}function s(){this.place=0}function c(e,t){var r=e[t.place++];if(!(128&r))return r;for(var n=15&r,i=0,a=0,o=t.place;a<n;a++,o++)i<<=8,i|=e[o];return t.place=o,i}function u(e){for(var t=0,r=e.length-1;!e[t]&&!(128&e[t+1])&&t<r;)t++;return 0===t?e:e.slice(t)}function l(e,t){if(t<128)e.push(t);else{var r=1+(Math.log(t)/Math.LN2>>>3);for(e.push(128|r);--r;)e.push(t>>>(r<<3)&255);e.push(t)}}e.exports=o,o.prototype._importDER=function(e,t){e=i.toArray(e,t);var r=new s;if(48!==e[r.place++])return!1;if(c(e,r)+r.place!==e.length)return!1;if(2!==e[r.place++])return!1;var a=c(e,r),o=e.slice(r.place,a+r.place);if(r.place+=a,2!==e[r.place++])return!1;var u=c(e,r);if(e.length!==u+r.place)return!1;var l=e.slice(r.place,u+r.place);return 0===o[0]&&128&o[1]&&(o=o.slice(1)),0===l[0]&&128&l[1]&&(l=l.slice(1)),this.r=new n(o),this.s=new n(l),this.recoveryParam=null,!0},o.prototype.toDER=function(e){var t=this.r.toArray(),r=this.s.toArray();for(128&t[0]&&(t=[0].concat(t)),128&r[0]&&(r=[0].concat(r)),t=u(t),r=u(r);!(r[0]||128&r[1]);)r=r.slice(1);var n=[2];l(n,t.length),(n=n.concat(t)).push(2),l(n,r.length);var a=n.concat(r),o=[48];return l(o,a.length),o=o.concat(a),i.encode(o,e)}},function(e,t,r){"use strict";var n=r(111),i=r(110),a=r(17),o=a.assert,s=a.parseBytes,c=r(643),u=r(644);function l(e){if(o("ed25519"===e,"only tested with ed25519 so far"),!(this instanceof l))return new l(e);e=i[e].curve;this.curve=e,this.g=e.g,this.g.precompute(e.n.bitLength()+1),this.pointClass=e.point().constructor,this.encodingLength=Math.ceil(e.n.bitLength()/8),this.hash=n.sha512}e.exports=l,l.prototype.sign=function(e,t){e=s(e);var r=this.keyFromSecret(t),n=this.hashInt(r.messagePrefix(),e),i=this.g.mul(n),a=this.encodePoint(i),o=this.hashInt(a,r.pubBytes(),e).mul(r.priv()),c=n.add(o).umod(this.curve.n);return this.makeSignature({R:i,S:c,Rencoded:a})},l.prototype.verify=function(e,t,r){e=s(e),t=this.makeSignature(t);var n=this.keyFromPublic(r),i=this.hashInt(t.Rencoded(),n.pubBytes(),e),a=this.g.mul(t.S());return t.R().add(n.pub().mul(i)).eq(a)},l.prototype.hashInt=function(){for(var e=this.hash(),t=0;t<arguments.length;t++)e.update(arguments[t]);return a.intFromLE(e.digest()).umod(this.curve.n)},l.prototype.keyFromPublic=function(e){return c.fromPublic(this,e)},l.prototype.keyFromSecret=function(e){return c.fromSecret(this,e)},l.prototype.makeSignature=function(e){return e instanceof u?e:new u(this,e)},l.prototype.encodePoint=function(e){var t=e.getY().toArray("le",this.encodingLength);return t[this.encodingLength-1]|=e.getX().isOdd()?128:0,t},l.prototype.decodePoint=function(e){var t=(e=a.parseBytes(e)).length-1,r=e.slice(0,t).concat(-129&e[t]),n=0!=(128&e[t]),i=a.intFromLE(r);return this.curve.pointFromY(i,n)},l.prototype.encodeInt=function(e){return e.toArray("le",this.encodingLength)},l.prototype.decodeInt=function(e){return a.intFromLE(e)},l.prototype.isPoint=function(e){return e instanceof this.pointClass}},function(e,t,r){"use strict";var n=r(17),i=n.assert,a=n.parseBytes,o=n.cachedProperty;function s(e,t){this.eddsa=e,this._secret=a(t.secret),e.isPoint(t.pub)?this._pub=t.pub:this._pubBytes=a(t.pub)}s.fromPublic=function(e,t){return t instanceof s?t:new s(e,{pub:t})},s.fromSecret=function(e,t){return t instanceof s?t:new s(e,{secret:t})},s.prototype.secret=function(){return this._secret},o(s,"pubBytes",function(){return this.eddsa.encodePoint(this.pub())}),o(s,"pub",function(){return this._pubBytes?this.eddsa.decodePoint(this._pubBytes):this.eddsa.g.mul(this.priv())}),o(s,"privBytes",function(){var e=this.eddsa,t=this.hash(),r=e.encodingLength-1,n=t.slice(0,e.encodingLength);return n[0]&=248,n[r]&=127,n[r]|=64,n}),o(s,"priv",function(){return this.eddsa.decodeInt(this.privBytes())}),o(s,"hash",function(){return this.eddsa.hash().update(this.secret()).digest()}),o(s,"messagePrefix",function(){return this.hash().slice(this.eddsa.encodingLength)}),s.prototype.sign=function(e){return i(this._secret,"KeyPair can only verify"),this.eddsa.sign(e,this)},s.prototype.verify=function(e,t){return this.eddsa.verify(e,t,this)},s.prototype.getSecret=function(e){return i(this._secret,"KeyPair is public only"),n.encode(this.secret(),e)},s.prototype.getPublic=function(e){return n.encode(this.pubBytes(),e)},e.exports=s},function(e,t,r){"use strict";var n=r(11),i=r(17),a=i.assert,o=i.cachedProperty,s=i.parseBytes;function c(e,t){this.eddsa=e,"object"!=typeof t&&(t=s(t)),Array.isArray(t)&&(t={R:t.slice(0,e.encodingLength),S:t.slice(e.encodingLength)}),a(t.R&&t.S,"Signature without R or S"),e.isPoint(t.R)&&(this._R=t.R),t.S instanceof n&&(this._S=t.S),this._Rencoded=Array.isArray(t.R)?t.R:t.Rencoded,this._Sencoded=Array.isArray(t.S)?t.S:t.Sencoded}o(c,"S",function(){return this.eddsa.decodeInt(this.Sencoded())}),o(c,"R",function(){return this.eddsa.decodePoint(this.Rencoded())}),o(c,"Rencoded",function(){return this.eddsa.encodePoint(this.R())}),o(c,"Sencoded",function(){return this.eddsa.encodeInt(this.S())}),c.prototype.toBytes=function(){return this.Rencoded().concat(this.Sencoded())},c.prototype.toHex=function(){return i.encode(this.toBytes(),"hex").toUpperCase()},e.exports=c},function(e,t,r){"use strict";var n=r(61);t.certificate=r(655);var i=n.define("RSAPrivateKey",function(){this.seq().obj(this.key("version").int(),this.key("modulus").int(),this.key("publicExponent").int(),this.key("privateExponent").int(),this.key("prime1").int(),this.key("prime2").int(),this.key("exponent1").int(),this.key("exponent2").int(),this.key("coefficient").int())});t.RSAPrivateKey=i;var a=n.define("RSAPublicKey",function(){this.seq().obj(this.key("modulus").int(),this.key("publicExponent").int())});t.RSAPublicKey=a;var o=n.define("SubjectPublicKeyInfo",function(){this.seq().obj(this.key("algorithm").use(s),this.key("subjectPublicKey").bitstr())});t.PublicKey=o;var s=n.define("AlgorithmIdentifier",function(){this.seq().obj(this.key("algorithm").objid(),this.key("none").null_().optional(),this.key("curve").objid().optional(),this.key("params").seq().obj(this.key("p").int(),this.key("q").int(),this.key("g").int()).optional())}),c=n.define("PrivateKeyInfo",function(){this.seq().obj(this.key("version").int(),this.key("algorithm").use(s),this.key("subjectPrivateKey").octstr())});t.PrivateKey=c;var u=n.define("EncryptedPrivateKeyInfo",function(){this.seq().obj(this.key("algorithm").seq().obj(this.key("id").objid(),this.key("decrypt").seq().obj(this.key("kde").seq().obj(this.key("id").objid(),this.key("kdeparams").seq().obj(this.key("salt").octstr(),this.key("iters").int())),this.key("cipher").seq().obj(this.key("algo").objid(),this.key("iv").octstr()))),this.key("subjectPrivateKey").octstr())});t.EncryptedPrivateKey=u;var l=n.define("DSAPrivateKey",function(){this.seq().obj(this.key("version").int(),this.key("p").int(),this.key("q").int(),this.key("g").int(),this.key("pub_key").int(),this.key("priv_key").int())});t.DSAPrivateKey=l,t.DSAparam=n.define("DSAparam",function(){this.int()});var f=n.define("ECPrivateKey",function(){this.seq().obj(this.key("version").int(),this.key("privateKey").octstr(),this.key("parameters").optional().explicit(0).use(d),this.key("publicKey").optional().explicit(1).bitstr())});t.ECPrivateKey=f;var d=n.define("ECParameters",function(){this.choice({namedCurve:this.objid()})});t.signature=n.define("signature",function(){this.seq().obj(this.key("r").int(),this.key("s").int())})},function(e,t,r){var n=r(61),i=r(1);function a(e,t){this.name=e,this.body=t,this.decoders={},this.encoders={}}t.define=function(e,t){return new a(e,t)},a.prototype._createNamed=function(e){var t;try{t=r(647).runInThisContext("(function "+this.name+"(entity) {\n this._initNamed(entity);\n})")}catch(e){t=function(e){this._initNamed(e)}}return i(t,e),t.prototype._initNamed=function(t){e.call(this,t)},new t(this)},a.prototype._getDecoder=function(e){return e=e||"der",this.decoders.hasOwnProperty(e)||(this.decoders[e]=this._createNamed(n.decoders[e])),this.decoders[e]},a.prototype.decode=function(e,t,r){return this._getDecoder(t).decode(e,r)},a.prototype._getEncoder=function(e){return e=e||"der",this.encoders.hasOwnProperty(e)||(this.encoders[e]=this._createNamed(n.encoders[e])),this.encoders[e]},a.prototype.encode=function(e,t,r){return this._getEncoder(t).encode(e,r)}},function(module,exports){var indexOf=function(e,t){if(e.indexOf)return e.indexOf(t);for(var r=0;r<e.length;r++)if(e[r]===t)return r;return-1},Object_keys=function(e){if(Object.keys)return Object.keys(e);var t=[];for(var r in e)t.push(r);return t},forEach=function(e,t){if(e.forEach)return e.forEach(t);for(var r=0;r<e.length;r++)t(e[r],r,e)},defineProp=function(){try{return Object.defineProperty({},"_",{}),function(e,t,r){Object.defineProperty(e,t,{writable:!0,enumerable:!1,configurable:!0,value:r})}}catch(e){return function(e,t,r){e[t]=r}}}(),globals=["Array","Boolean","Date","Error","EvalError","Function","Infinity","JSON","Math","NaN","Number","Object","RangeError","ReferenceError","RegExp","String","SyntaxError","TypeError","URIError","decodeURI","decodeURIComponent","encodeURI","encodeURIComponent","escape","eval","isFinite","isNaN","parseFloat","parseInt","undefined","unescape"];function Context(){}Context.prototype={};var Script=exports.Script=function(e){if(!(this instanceof Script))return new Script(e);this.code=e};Script.prototype.runInContext=function(e){if(!(e instanceof Context))throw new TypeError("needs a 'context' argument.");var t=document.createElement("iframe");t.style||(t.style={}),t.style.display="none",document.body.appendChild(t);var r=t.contentWindow,n=r.eval,i=r.execScript;!n&&i&&(i.call(r,"null"),n=r.eval),forEach(Object_keys(e),function(t){r[t]=e[t]}),forEach(globals,function(t){e[t]&&(r[t]=e[t])});var a=Object_keys(r),o=n.call(r,this.code);return forEach(Object_keys(r),function(t){(t in e||-1===indexOf(a,t))&&(e[t]=r[t])}),forEach(globals,function(t){t in e||defineProp(e,t,r[t])}),document.body.removeChild(t),o},Script.prototype.runInThisContext=function(){return eval(this.code)},Script.prototype.runInNewContext=function(e){var t=Script.createContext(e),r=this.runInContext(t);return e&&forEach(Object_keys(t),function(r){e[r]=t[r]}),r},forEach(Object_keys(Script.prototype),function(e){exports[e]=Script[e]=function(t){var r=Script(t);return r[e].apply(r,[].slice.call(arguments,1))}}),exports.isContext=function(e){return e instanceof Context},exports.createScript=function(e){return exports.Script(e)},exports.createContext=Script.createContext=function(e){var t=new Context;return"object"==typeof e&&forEach(Object_keys(e),function(r){t[r]=e[r]}),t}},function(e,t,r){var n=r(1);function i(e){this._reporterState={obj:null,path:[],options:e||{},errors:[]}}function a(e,t){this.path=e,this.rethrow(t)}t.Reporter=i,i.prototype.isError=function(e){return e instanceof a},i.prototype.save=function(){var e=this._reporterState;return{obj:e.obj,pathLen:e.path.length}},i.prototype.restore=function(e){var t=this._reporterState;t.obj=e.obj,t.path=t.path.slice(0,e.pathLen)},i.prototype.enterKey=function(e){return this._reporterState.path.push(e)},i.prototype.exitKey=function(e){var t=this._reporterState;t.path=t.path.slice(0,e-1)},i.prototype.leaveKey=function(e,t,r){var n=this._reporterState;this.exitKey(e),null!==n.obj&&(n.obj[t]=r)},i.prototype.path=function(){return this._reporterState.path.join("/")},i.prototype.enterObject=function(){var e=this._reporterState,t=e.obj;return e.obj={},t},i.prototype.leaveObject=function(e){var t=this._reporterState,r=t.obj;return t.obj=e,r},i.prototype.error=function(e){var t,r=this._reporterState,n=e instanceof a;if(t=n?e:new a(r.path.map(function(e){return"["+JSON.stringify(e)+"]"}).join(""),e.message||e,e.stack),!r.options.partial)throw t;return n||r.errors.push(t),t},i.prototype.wrapResult=function(e){var t=this._reporterState;return t.options.partial?{result:this.isError(e)?null:e,errors:t.errors}:e},n(a,Error),a.prototype.rethrow=function(e){if(this.message=e+" at: "+(this.path||"(shallow)"),Error.captureStackTrace&&Error.captureStackTrace(this,a),!this.stack)try{throw new Error(this.message)}catch(e){this.stack=e.stack}return this}},function(e,t,r){var n=r(62).Reporter,i=r(62).EncoderBuffer,a=r(62).DecoderBuffer,o=r(16),s=["seq","seqof","set","setof","objid","bool","gentime","utctime","null_","enum","int","objDesc","bitstr","bmpstr","charstr","genstr","graphstr","ia5str","iso646str","numstr","octstr","printstr","t61str","unistr","utf8str","videostr"],c=["key","obj","use","optional","explicit","implicit","def","choice","any","contains"].concat(s);function u(e,t){var r={};this._baseState=r,r.enc=e,r.parent=t||null,r.children=null,r.tag=null,r.args=null,r.reverseArgs=null,r.choice=null,r.optional=!1,r.any=!1,r.obj=!1,r.use=null,r.useDecoder=null,r.key=null,r.default=null,r.explicit=null,r.implicit=null,r.contains=null,r.parent||(r.children=[],this._wrap())}e.exports=u;var l=["enc","parent","children","tag","args","reverseArgs","choice","optional","any","obj","use","alteredUse","key","default","explicit","implicit","contains"];u.prototype.clone=function(){var e=this._baseState,t={};l.forEach(function(r){t[r]=e[r]});var r=new this.constructor(t.parent);return r._baseState=t,r},u.prototype._wrap=function(){var e=this._baseState;c.forEach(function(t){this[t]=function(){var r=new this.constructor(this);return e.children.push(r),r[t].apply(r,arguments)}},this)},u.prototype._init=function(e){var t=this._baseState;o(null===t.parent),e.call(this),t.children=t.children.filter(function(e){return e._baseState.parent===this},this),o.equal(t.children.length,1,"Root node can have only one child")},u.prototype._useArgs=function(e){var t=this._baseState,r=e.filter(function(e){return e instanceof this.constructor},this);e=e.filter(function(e){return!(e instanceof this.constructor)},this),0!==r.length&&(o(null===t.children),t.children=r,r.forEach(function(e){e._baseState.parent=this},this)),0!==e.length&&(o(null===t.args),t.args=e,t.reverseArgs=e.map(function(e){if("object"!=typeof e||e.constructor!==Object)return e;var t={};return Object.keys(e).forEach(function(r){r==(0|r)&&(r|=0);var n=e[r];t[n]=r}),t}))},["_peekTag","_decodeTag","_use","_decodeStr","_decodeObjid","_decodeTime","_decodeNull","_decodeInt","_decodeBool","_decodeList","_encodeComposite","_encodeStr","_encodeObjid","_encodeTime","_encodeNull","_encodeInt","_encodeBool"].forEach(function(e){u.prototype[e]=function(){var t=this._baseState;throw new Error(e+" not implemented for encoding: "+t.enc)}}),s.forEach(function(e){u.prototype[e]=function(){var t=this._baseState,r=Array.prototype.slice.call(arguments);return o(null===t.tag),t.tag=e,this._useArgs(r),this}}),u.prototype.use=function(e){o(e);var t=this._baseState;return o(null===t.use),t.use=e,this},u.prototype.optional=function(){return this._baseState.optional=!0,this},u.prototype.def=function(e){var t=this._baseState;return o(null===t.default),t.default=e,t.optional=!0,this},u.prototype.explicit=function(e){var t=this._baseState;return o(null===t.explicit&&null===t.implicit),t.explicit=e,this},u.prototype.implicit=function(e){var t=this._baseState;return o(null===t.explicit&&null===t.implicit),t.implicit=e,this},u.prototype.obj=function(){var e=this._baseState,t=Array.prototype.slice.call(arguments);return e.obj=!0,0!==t.length&&this._useArgs(t),this},u.prototype.key=function(e){var t=this._baseState;return o(null===t.key),t.key=e,this},u.prototype.any=function(){return this._baseState.any=!0,this},u.prototype.choice=function(e){var t=this._baseState;return o(null===t.choice),t.choice=e,this._useArgs(Object.keys(e).map(function(t){return e[t]})),this},u.prototype.contains=function(e){var t=this._baseState;return o(null===t.use),t.contains=e,this},u.prototype._decode=function(e,t){var r=this._baseState;if(null===r.parent)return e.wrapResult(r.children[0]._decode(e,t));var n,i=r.default,o=!0,s=null;if(null!==r.key&&(s=e.enterKey(r.key)),r.optional){var c=null;if(null!==r.explicit?c=r.explicit:null!==r.implicit?c=r.implicit:null!==r.tag&&(c=r.tag),null!==c||r.any){if(o=this._peekTag(e,c,r.any),e.isError(o))return o}else{var u=e.save();try{null===r.choice?this._decodeGeneric(r.tag,e,t):this._decodeChoice(e,t),o=!0}catch(e){o=!1}e.restore(u)}}if(r.obj&&o&&(n=e.enterObject()),o){if(null!==r.explicit){var l=this._decodeTag(e,r.explicit);if(e.isError(l))return l;e=l}var f=e.offset;if(null===r.use&&null===r.choice){if(r.any)u=e.save();var d=this._decodeTag(e,null!==r.implicit?r.implicit:r.tag,r.any);if(e.isError(d))return d;r.any?i=e.raw(u):e=d}if(t&&t.track&&null!==r.tag&&t.track(e.path(),f,e.length,"tagged"),t&&t.track&&null!==r.tag&&t.track(e.path(),e.offset,e.length,"content"),i=r.any?i:null===r.choice?this._decodeGeneric(r.tag,e,t):this._decodeChoice(e,t),e.isError(i))return i;if(r.any||null!==r.choice||null===r.children||r.children.forEach(function(r){r._decode(e,t)}),r.contains&&("octstr"===r.tag||"bitstr"===r.tag)){var h=new a(i);i=this._getUse(r.contains,e._reporterState.obj)._decode(h,t)}}return r.obj&&o&&(i=e.leaveObject(n)),null===r.key||null===i&&!0!==o?null!==s&&e.exitKey(s):e.leaveKey(s,r.key,i),i},u.prototype._decodeGeneric=function(e,t,r){var n=this._baseState;return"seq"===e||"set"===e?null:"seqof"===e||"setof"===e?this._decodeList(t,e,n.args[0],r):/str$/.test(e)?this._decodeStr(t,e,r):"objid"===e&&n.args?this._decodeObjid(t,n.args[0],n.args[1],r):"objid"===e?this._decodeObjid(t,null,null,r):"gentime"===e||"utctime"===e?this._decodeTime(t,e,r):"null_"===e?this._decodeNull(t,r):"bool"===e?this._decodeBool(t,r):"objDesc"===e?this._decodeStr(t,e,r):"int"===e||"enum"===e?this._decodeInt(t,n.args&&n.args[0],r):null!==n.use?this._getUse(n.use,t._reporterState.obj)._decode(t,r):t.error("unknown tag: "+e)},u.prototype._getUse=function(e,t){var r=this._baseState;return r.useDecoder=this._use(e,t),o(null===r.useDecoder._baseState.parent),r.useDecoder=r.useDecoder._baseState.children[0],r.implicit!==r.useDecoder._baseState.implicit&&(r.useDecoder=r.useDecoder.clone(),r.useDecoder._baseState.implicit=r.implicit),r.useDecoder},u.prototype._decodeChoice=function(e,t){var r=this._baseState,n=null,i=!1;return Object.keys(r.choice).some(function(a){var o=e.save(),s=r.choice[a];try{var c=s._decode(e,t);if(e.isError(c))return!1;n={type:a,value:c},i=!0}catch(t){return e.restore(o),!1}return!0},this),i?n:e.error("Choice not matched")},u.prototype._createEncoderBuffer=function(e){return new i(e,this.reporter)},u.prototype._encode=function(e,t,r){var n=this._baseState;if(null===n.default||n.default!==e){var i=this._encodeValue(e,t,r);if(void 0!==i&&!this._skipDefault(i,t,r))return i}},u.prototype._encodeValue=function(e,t,r){var i=this._baseState;if(null===i.parent)return i.children[0]._encode(e,t||new n);var a=null;if(this.reporter=t,i.optional&&void 0===e){if(null===i.default)return;e=i.default}var o=null,s=!1;if(i.any)a=this._createEncoderBuffer(e);else if(i.choice)a=this._encodeChoice(e,t);else if(i.contains)o=this._getUse(i.contains,r)._encode(e,t),s=!0;else if(i.children)o=i.children.map(function(r){if("null_"===r._baseState.tag)return r._encode(null,t,e);if(null===r._baseState.key)return t.error("Child should have a key");var n=t.enterKey(r._baseState.key);if("object"!=typeof e)return t.error("Child expected, but input is not object");var i=r._encode(e[r._baseState.key],t,e);return t.leaveKey(n),i},this).filter(function(e){return e}),o=this._createEncoderBuffer(o);else if("seqof"===i.tag||"setof"===i.tag){if(!i.args||1!==i.args.length)return t.error("Too many args for : "+i.tag);if(!Array.isArray(e))return t.error("seqof/setof, but data is not Array");var c=this.clone();c._baseState.implicit=null,o=this._createEncoderBuffer(e.map(function(r){var n=this._baseState;return this._getUse(n.args[0],e)._encode(r,t)},c))}else null!==i.use?a=this._getUse(i.use,r)._encode(e,t):(o=this._encodePrimitive(i.tag,e),s=!0);if(!i.any&&null===i.choice){var u=null!==i.implicit?i.implicit:i.tag,l=null===i.implicit?"universal":"context";null===u?null===i.use&&t.error("Tag could be omitted only for .use()"):null===i.use&&(a=this._encodeComposite(u,s,l,o))}return null!==i.explicit&&(a=this._encodeComposite(i.explicit,!1,"context",a)),a},u.prototype._encodeChoice=function(e,t){var r=this._baseState,n=r.choice[e.type];return n||o(!1,e.type+" not found in "+JSON.stringify(Object.keys(r.choice))),n._encode(e.value,t)},u.prototype._encodePrimitive=function(e,t){var r=this._baseState;if(/str$/.test(e))return this._encodeStr(t,e);if("objid"===e&&r.args)return this._encodeObjid(t,r.reverseArgs[0],r.args[1]);if("objid"===e)return this._encodeObjid(t,null,null);if("gentime"===e||"utctime"===e)return this._encodeTime(t,e);if("null_"===e)return this._encodeNull();if("int"===e||"enum"===e)return this._encodeInt(t,r.args&&r.reverseArgs[0]);if("bool"===e)return this._encodeBool(t);if("objDesc"===e)return this._encodeStr(t,e);throw new Error("Unsupported tag: "+e)},u.prototype._isNumstr=function(e){return/^[0-9 ]*$/.test(e)},u.prototype._isPrintstr=function(e){return/^[A-Za-z0-9 '\(\)\+,\-\.\/:=\?]*$/.test(e)}},function(e,t,r){var n=r(272);t.tagClass={0:"universal",1:"application",2:"context",3:"private"},t.tagClassByName=n._reverse(t.tagClass),t.tag={0:"end",1:"bool",2:"int",3:"bitstr",4:"octstr",5:"null_",6:"objid",7:"objDesc",8:"external",9:"real",10:"enum",11:"embed",12:"utf8str",13:"relativeOid",16:"seq",17:"set",18:"numstr",19:"printstr",20:"t61str",21:"videostr",22:"ia5str",23:"utctime",24:"gentime",25:"graphstr",26:"iso646str",27:"genstr",28:"unistr",29:"charstr",30:"bmpstr"},t.tagByName=n._reverse(t.tag)},function(e,t,r){var n=t;n.der=r(273),n.pem=r(652)},function(e,t,r){var n=r(1),i=r(7).Buffer,a=r(273);function o(e){a.call(this,e),this.enc="pem"}n(o,a),e.exports=o,o.prototype.decode=function(e,t){for(var r=e.toString().split(/[\r\n]+/g),n=t.label.toUpperCase(),o=/^-----(BEGIN|END) ([^-]+)-----$/,s=-1,c=-1,u=0;u<r.length;u++){var l=r[u].match(o);if(null!==l&&l[2]===n){if(-1!==s){if("END"!==l[1])break;c=u;break}if("BEGIN"!==l[1])break;s=u}}if(-1===s||-1===c)throw new Error("PEM section not found for: "+n);var f=r.slice(s+1,c).join("");f.replace(/[^a-z0-9\+\/=]+/gi,"");var d=new i(f,"base64");return a.prototype.decode.call(this,d,t)}},function(e,t,r){var n=t;n.der=r(274),n.pem=r(654)},function(e,t,r){var n=r(1),i=r(274);function a(e){i.call(this,e),this.enc="pem"}n(a,i),e.exports=a,a.prototype.encode=function(e,t){for(var r=i.prototype.encode.call(this,e).toString("base64"),n=["-----BEGIN "+t.label+"-----"],a=0;a<r.length;a+=64)n.push(r.slice(a,a+64));return n.push("-----END "+t.label+"-----"),n.join("\n")}},function(e,t,r){"use strict";var n=r(61),i=n.define("Time",function(){this.choice({utcTime:this.utctime(),generalTime:this.gentime()})}),a=n.define("AttributeTypeValue",function(){this.seq().obj(this.key("type").objid(),this.key("value").any())}),o=n.define("AlgorithmIdentifier",function(){this.seq().obj(this.key("algorithm").objid(),this.key("parameters").optional(),this.key("curve").objid().optional())}),s=n.define("SubjectPublicKeyInfo",function(){this.seq().obj(this.key("algorithm").use(o),this.key("subjectPublicKey").bitstr())}),c=n.define("RelativeDistinguishedName",function(){this.setof(a)}),u=n.define("RDNSequence",function(){this.seqof(c)}),l=n.define("Name",function(){this.choice({rdnSequence:this.use(u)})}),f=n.define("Validity",function(){this.seq().obj(this.key("notBefore").use(i),this.key("notAfter").use(i))}),d=n.define("Extension",function(){this.seq().obj(this.key("extnID").objid(),this.key("critical").bool().def(!1),this.key("extnValue").octstr())}),h=n.define("TBSCertificate",function(){this.seq().obj(this.key("version").explicit(0).int().optional(),this.key("serialNumber").int(),this.key("signature").use(o),this.key("issuer").use(l),this.key("validity").use(f),this.key("subject").use(l),this.key("subjectPublicKeyInfo").use(s),this.key("issuerUniqueID").implicit(1).bitstr().optional(),this.key("subjectUniqueID").implicit(2).bitstr().optional(),this.key("extensions").explicit(3).seqof(d).optional())}),p=n.define("X509Certificate",function(){this.seq().obj(this.key("tbsCertificate").use(h),this.key("signatureAlgorithm").use(o),this.key("signatureValue").bitstr())});e.exports=p},function(e){e.exports=JSON.parse('{"2.16.840.1.101.3.4.1.1":"aes-128-ecb","2.16.840.1.101.3.4.1.2":"aes-128-cbc","2.16.840.1.101.3.4.1.3":"aes-128-ofb","2.16.840.1.101.3.4.1.4":"aes-128-cfb","2.16.840.1.101.3.4.1.21":"aes-192-ecb","2.16.840.1.101.3.4.1.22":"aes-192-cbc","2.16.840.1.101.3.4.1.23":"aes-192-ofb","2.16.840.1.101.3.4.1.24":"aes-192-cfb","2.16.840.1.101.3.4.1.41":"aes-256-ecb","2.16.840.1.101.3.4.1.42":"aes-256-cbc","2.16.840.1.101.3.4.1.43":"aes-256-ofb","2.16.840.1.101.3.4.1.44":"aes-256-cfb"}')},function(e,t,r){var n=/Proc-Type: 4,ENCRYPTED[\n\r]+DEK-Info: AES-((?:128)|(?:192)|(?:256))-CBC,([0-9A-H]+)[\n\r]+([0-9A-z\n\r\+\/\=]+)[\n\r]+/m,i=/^-----BEGIN ((?:.*? KEY)|CERTIFICATE)-----/m,a=/^-----BEGIN ((?:.*? KEY)|CERTIFICATE)-----([0-9A-z\n\r\+\/\=]+)-----END \1-----$/m,o=r(79),s=r(105),c=r(2).Buffer;e.exports=function(e,t){var r,u=e.toString(),l=u.match(n);if(l){var f="aes"+l[1],d=c.from(l[2],"hex"),h=c.from(l[3].replace(/[\r\n]/g,""),"base64"),p=o(t,d.slice(0,8),parseInt(l[1],10)).key,y=[],m=s.createDecipheriv(f,p,d);y.push(m.update(h)),y.push(m.final()),r=c.concat(y)}else{var g=u.match(a);r=new c(g[2].replace(/[\r\n]/g,""),"base64")}return{tag:u.match(i)[1],data:r}}},function(e,t,r){(function(t){var n=r(11),i=r(109).ec,a=r(81),o=r(275);function s(e,t){if(e.cmpn(0)<=0)throw new Error("invalid sig");if(e.cmp(t)>=t)throw new Error("invalid sig")}e.exports=function(e,r,c,u,l){var f=a(c);if("ec"===f.type){if("ecdsa"!==u&&"ecdsa/rsa"!==u)throw new Error("wrong public key type");return function(e,t,r){var n=o[r.data.algorithm.curve.join(".")];if(!n)throw new Error("unknown curve "+r.data.algorithm.curve.join("."));var a=new i(n),s=r.data.subjectPrivateKey.data;return a.verify(t,e,s)}(e,r,f)}if("dsa"===f.type){if("dsa"!==u)throw new Error("wrong public key type");return function(e,t,r){var i=r.data.p,o=r.data.q,c=r.data.g,u=r.data.pub_key,l=a.signature.decode(e,"der"),f=l.s,d=l.r;s(f,o),s(d,o);var h=n.mont(i),p=f.invm(o);return 0===c.toRed(h).redPow(new n(t).mul(p).mod(o)).fromRed().mul(u.toRed(h).redPow(d.mul(p).mod(o)).fromRed()).mod(i).mod(o).cmp(d)}(e,r,f)}if("rsa"!==u&&"ecdsa/rsa"!==u)throw new Error("wrong public key type");r=t.concat([l,r]);for(var d=f.modulus.byteLength(),h=[1],p=0;r.length+h.length+2<d;)h.push(255),p++;h.push(0);for(var y=-1;++y<r.length;)h.push(r[y]);h=new t(h);var m=n.mont(f.modulus);e=(e=new n(e).toRed(m)).redPow(new n(f.publicExponent)),e=new t(e.fromRed().toArray());var g=p<8?1:0;for(d=Math.min(e.length,h.length),e.length!==h.length&&(g=1),y=-1;++y<d;)g|=e[y]^h[y];return 0===g}}).call(this,r(7).Buffer)},function(e,t,r){(function(t){var n=r(109),i=r(11);e.exports=function(e){return new o(e)};var a={secp256k1:{name:"secp256k1",byteLength:32},secp224r1:{name:"p224",byteLength:28},prime256v1:{name:"p256",byteLength:32},prime192v1:{name:"p192",byteLength:24},ed25519:{name:"ed25519",byteLength:32},secp384r1:{name:"p384",byteLength:48},secp521r1:{name:"p521",byteLength:66}};function o(e){this.curveType=a[e],this.curveType||(this.curveType={name:e}),this.curve=new n.ec(this.curveType.name),this.keys=void 0}function s(e,r,n){Array.isArray(e)||(e=e.toArray());var i=new t(e);if(n&&i.length<n){var a=new t(n-i.length);a.fill(0),i=t.concat([a,i])}return r?i.toString(r):i}a.p224=a.secp224r1,a.p256=a.secp256r1=a.prime256v1,a.p192=a.secp192r1=a.prime192v1,a.p384=a.secp384r1,a.p521=a.secp521r1,o.prototype.generateKeys=function(e,t){return this.keys=this.curve.genKeyPair(),this.getPublicKey(e,t)},o.prototype.computeSecret=function(e,r,n){return r=r||"utf8",t.isBuffer(e)||(e=new t(e,r)),s(this.curve.keyFromPublic(e).getPublic().mul(this.keys.getPrivate()).getX(),n,this.curveType.byteLength)},o.prototype.getPublicKey=function(e,t){var r=this.keys.getPublic("compressed"===t,!0);return"hybrid"===t&&(r[r.length-1]%2?r[0]=7:r[0]=6),s(r,e)},o.prototype.getPrivateKey=function(e){return s(this.keys.getPrivate(),e)},o.prototype.setPublicKey=function(e,r){return r=r||"utf8",t.isBuffer(e)||(e=new t(e,r)),this.keys._importPublic(e),this},o.prototype.setPrivateKey=function(e,r){r=r||"utf8",t.isBuffer(e)||(e=new t(e,r));var n=new i(e);return n=n.toString(16),this.keys=this.curve.genKeyPair(),this.keys._importPrivate(n),this}}).call(this,r(7).Buffer)},function(e,t,r){t.publicEncrypt=r(661),t.privateDecrypt=r(662),t.privateEncrypt=function(e,r){return t.publicEncrypt(e,r,!0)},t.publicDecrypt=function(e,r){return t.privateDecrypt(e,r,!0)}},function(e,t,r){var n=r(81),i=r(43),a=r(44),o=r(276),s=r(277),c=r(11),u=r(278),l=r(108),f=r(2).Buffer;e.exports=function(e,t,r){var d;d=e.padding?e.padding:r?1:4;var h,p=n(e);if(4===d)h=function(e,t){var r=e.modulus.byteLength(),n=t.length,u=a("sha1").update(f.alloc(0)).digest(),l=u.length,d=2*l;if(n>r-d-2)throw new Error("message too long");var h=f.alloc(r-n-d-2),p=r-l-1,y=i(l),m=s(f.concat([u,h,f.alloc(1,1),t],p),o(y,p)),g=s(y,o(m,l));return new c(f.concat([f.alloc(1),g,m],r))}(p,t);else if(1===d)h=function(e,t,r){var n,a=t.length,o=e.modulus.byteLength();if(a>o-11)throw new Error("message too long");n=r?f.alloc(o-a-3,255):function(e){var t,r=f.allocUnsafe(e),n=0,a=i(2*e),o=0;for(;n<e;)o===a.length&&(a=i(2*e),o=0),(t=a[o++])&&(r[n++]=t);return r}(o-a-3);return new c(f.concat([f.from([0,r?1:2]),n,f.alloc(1),t],o))}(p,t,r);else{if(3!==d)throw new Error("unknown padding");if((h=new c(t)).cmp(p.modulus)>=0)throw new Error("data too long for modulus")}return r?l(h,p):u(h,p)}},function(e,t,r){var n=r(81),i=r(276),a=r(277),o=r(11),s=r(108),c=r(44),u=r(278),l=r(2).Buffer;e.exports=function(e,t,r){var f;f=e.padding?e.padding:r?1:4;var d,h=n(e),p=h.modulus.byteLength();if(t.length>p||new o(t).cmp(h.modulus)>=0)throw new Error("decryption error");d=r?u(new o(t),h):s(t,h);var y=l.alloc(p-d.length);if(d=l.concat([y,d],p),4===f)return function(e,t){var r=e.modulus.byteLength(),n=c("sha1").update(l.alloc(0)).digest(),o=n.length;if(0!==t[0])throw new Error("decryption error");var s=t.slice(1,o+1),u=t.slice(o+1),f=a(s,i(u,o)),d=a(u,i(f,r-o-1));if(function(e,t){e=l.from(e),t=l.from(t);var r=0,n=e.length;e.length!==t.length&&(r++,n=Math.min(e.length,t.length));var i=-1;for(;++i<n;)r+=e[i]^t[i];return r}(n,d.slice(0,o)))throw new Error("decryption error");var h=o;for(;0===d[h];)h++;if(1!==d[h++])throw new Error("decryption error");return d.slice(h)}(h,d);if(1===f)return function(e,t,r){var n=t.slice(0,2),i=2,a=0;for(;0!==t[i++];)if(i>=t.length){a++;break}var o=t.slice(2,i-1);("0002"!==n.toString("hex")&&!r||"0001"!==n.toString("hex")&&r)&&a++;o.length<8&&a++;if(a)throw new Error("decryption error");return t.slice(i)}(0,d,r);if(3===f)return d;throw new Error("unknown padding")}},function(e,t,r){"use strict";(function(e,n){function i(){throw new Error("secure random number generation not supported by this browser\nuse chrome, FireFox or Internet Explorer 11")}var a=r(2),o=r(43),s=a.Buffer,c=a.kMaxLength,u=e.crypto||e.msCrypto,l=Math.pow(2,32)-1;function f(e,t){if("number"!=typeof e||e!=e)throw new TypeError("offset must be a number");if(e>l||e<0)throw new TypeError("offset must be a uint32");if(e>c||e>t)throw new RangeError("offset out of range")}function d(e,t,r){if("number"!=typeof e||e!=e)throw new TypeError("size must be a number");if(e>l||e<0)throw new TypeError("size must be a uint32");if(e+t>r||e>c)throw new RangeError("buffer too small")}function h(e,t,r,i){if(n.browser){var a=e.buffer,s=new Uint8Array(a,t,r);return u.getRandomValues(s),i?void n.nextTick(function(){i(null,e)}):e}if(!i)return o(r).copy(e,t),e;o(r,function(r,n){if(r)return i(r);n.copy(e,t),i(null,e)})}u&&u.getRandomValues||!n.browser?(t.randomFill=function(t,r,n,i){if(!(s.isBuffer(t)||t instanceof e.Uint8Array))throw new TypeError('"buf" argument must be a Buffer or Uint8Array');if("function"==typeof r)i=r,r=0,n=t.length;else if("function"==typeof n)i=n,n=t.length-r;else if("function"!=typeof i)throw new TypeError('"cb" argument must be a function');return f(r,t.length),d(n,r,t.length),h(t,r,n,i)},t.randomFillSync=function(t,r,n){void 0===r&&(r=0);if(!(s.isBuffer(t)||t instanceof e.Uint8Array))throw new TypeError('"buf" argument must be a Buffer or Uint8Array');f(r,t.length),void 0===n&&(n=t.length-r);return d(n,r,t.length),h(t,r,n)}):(t.randomFill=i,t.randomFillSync=i)}).call(this,r(9),r(13))},function(e,t,r){var n="undefined"!=typeof JSON?JSON:r(665);e.exports=function(e,t){t||(t={}),"function"==typeof t&&(t={cmp:t});var r=t.space||"";"number"==typeof r&&(r=Array(r+1).join(" "));var o,s="boolean"==typeof t.cycles&&t.cycles,c=t.replacer||function(e,t){return t},u=t.cmp&&(o=t.cmp,function(e){return function(t,r){var n={key:t,value:e[t]},i={key:r,value:e[r]};return o(n,i)}}),l=[];return function e(t,o,f,d){var h=r?"\n"+new Array(d+1).join(r):"",p=r?": ":":";if(f&&f.toJSON&&"function"==typeof f.toJSON&&(f=f.toJSON()),void 0!==(f=c.call(t,o,f))){if("object"!=typeof f||null===f)return n.stringify(f);if(i(f)){for(var y=[],m=0;m<f.length;m++){var g=e(f,m,f[m],d+1)||n.stringify(null);y.push(h+r+g)}return"["+y.join(",")+h+"]"}if(-1!==l.indexOf(f)){if(s)return n.stringify("__cycle__");throw new TypeError("Converting circular structure to JSON")}l.push(f);var b=a(f).sort(u&&u(f));for(y=[],m=0;m<b.length;m++){var v=e(f,o=b[m],f[o],d+1);if(v){var _=n.stringify(o)+p+v;y.push(h+r+_)}}return l.splice(l.indexOf(f),1),"{"+y.join(",")+h+"}"}}({"":e},"",e,0)};var i=Array.isArray||function(e){return"[object Array]"==={}.toString.call(e)},a=Object.keys||function(e){var t=Object.prototype.hasOwnProperty||function(){return!0},r=[];for(var n in e)t.call(e,n)&&r.push(n);return r}},function(e,t,r){t.parse=r(666),t.stringify=r(667)},function(e,t){var r,n,i,a,o={'"':'"',"\\":"\\","/":"/",b:"\b",f:"\f",n:"\n",r:"\r",t:"\t"},s=function(e){throw{name:"SyntaxError",message:e,at:r,text:i}},c=function(e){return e&&e!==n&&s("Expected '"+e+"' instead of '"+n+"'"),n=i.charAt(r),r+=1,n},u=function(){var e,t="";for("-"===n&&(t="-",c("-"));n>="0"&&n<="9";)t+=n,c();if("."===n)for(t+=".";c()&&n>="0"&&n<="9";)t+=n;if("e"===n||"E"===n)for(t+=n,c(),"-"!==n&&"+"!==n||(t+=n,c());n>="0"&&n<="9";)t+=n,c();if(e=+t,isFinite(e))return e;s("Bad number")},l=function(){var e,t,r,i="";if('"'===n)for(;c();){if('"'===n)return c(),i;if("\\"===n)if(c(),"u"===n){for(r=0,t=0;t<4&&(e=parseInt(c(),16),isFinite(e));t+=1)r=16*r+e;i+=String.fromCharCode(r)}else{if("string"!=typeof o[n])break;i+=o[n]}else i+=n}s("Bad string")},f=function(){for(;n&&n<=" ";)c()};a=function(){switch(f(),n){case"{":return function(){var e,t={};if("{"===n){if(c("{"),f(),"}"===n)return c("}"),t;for(;n;){if(e=l(),f(),c(":"),Object.hasOwnProperty.call(t,e)&&s('Duplicate key "'+e+'"'),t[e]=a(),f(),"}"===n)return c("}"),t;c(","),f()}}s("Bad object")}();case"[":return function(){var e=[];if("["===n){if(c("["),f(),"]"===n)return c("]"),e;for(;n;){if(e.push(a()),f(),"]"===n)return c("]"),e;c(","),f()}}s("Bad array")}();case'"':return l();case"-":return u();default:return n>="0"&&n<="9"?u():function(){switch(n){case"t":return c("t"),c("r"),c("u"),c("e"),!0;case"f":return c("f"),c("a"),c("l"),c("s"),c("e"),!1;case"n":return c("n"),c("u"),c("l"),c("l"),null}s("Unexpected '"+n+"'")}()}},e.exports=function(e,t){var o;return i=e,r=0,n=" ",o=a(),f(),n&&s("Syntax error"),"function"==typeof t?function e(r,n){var i,a,o=r[n];if(o&&"object"==typeof o)for(i in o)Object.prototype.hasOwnProperty.call(o,i)&&(void 0!==(a=e(o,i))?o[i]=a:delete o[i]);return t.call(r,n,o)}({"":o},""):o}},function(e,t){var r,n,i,a=/[\\\"\x00-\x1f\x7f-\x9f\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/g,o={"\b":"\\b","\t":"\\t","\n":"\\n","\f":"\\f","\r":"\\r",'"':'\\"',"\\":"\\\\"};function s(e){return a.lastIndex=0,a.test(e)?'"'+e.replace(a,function(e){var t=o[e];return"string"==typeof t?t:"\\u"+("0000"+e.charCodeAt(0).toString(16)).slice(-4)})+'"':'"'+e+'"'}e.exports=function(e,t,a){var o;if(r="",n="","number"==typeof a)for(o=0;o<a;o+=1)n+=" ";else"string"==typeof a&&(n=a);if(i=t,t&&"function"!=typeof t&&("object"!=typeof t||"number"!=typeof t.length))throw new Error("JSON.stringify");return function e(t,a){var o,c,u,l,f,d=r,h=a[t];switch(h&&"object"==typeof h&&"function"==typeof h.toJSON&&(h=h.toJSON(t)),"function"==typeof i&&(h=i.call(a,t,h)),typeof h){case"string":return s(h);case"number":return isFinite(h)?String(h):"null";case"boolean":case"null":return String(h);case"object":if(!h)return"null";if(r+=n,f=[],"[object Array]"===Object.prototype.toString.apply(h)){for(l=h.length,o=0;o<l;o+=1)f[o]=e(o,h)||"null";return u=0===f.length?"[]":r?"[\n"+r+f.join(",\n"+r)+"\n"+d+"]":"["+f.join(",")+"]",r=d,u}if(i&&"object"==typeof i)for(l=i.length,o=0;o<l;o+=1)"string"==typeof(c=i[o])&&(u=e(c,h))&&f.push(s(c)+(r?": ":":")+u);else for(c in h)Object.prototype.hasOwnProperty.call(h,c)&&(u=e(c,h))&&f.push(s(c)+(r?": ":":")+u);return u=0===f.length?"{}":r?"{\n"+r+f.join(",\n"+r)+"\n"+d+"}":"{"+f.join(",")+"}",r=d,u}}("",{"":e})}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(8),i=r(46),a=r(4);t.ActorQueryOperationExtend=class extends a.ActorQueryOperationTypedMediated{constructor(e){super(e,"extend")}async testOperation(e,t){new i.AsyncEvaluator(e.expression);return!0}async runOperation(e,t){const{expression:r,input:o,variable:s}=e,c=a.ActorQueryOperation.getSafeBindings(await this.mediatorQueryOperation.mediate({operation:o,context:t})),u=n.termToString(s),l=Object.assign({},a.ActorQueryOperation.getExpressionContext(t)),f=new i.AsyncEvaluator(r,l),d=c.variables.concat([u]),h=c.bindingsStream.transform({transform:async(e,r)=>{try{const r=await f.evaluate(e),n=e.set(u,r);h._push(n)}catch(r){i.isExpressionError(r)?(h._push(e),this.logWarn(t,`Expression error for extend operation with bindings '${JSON.stringify(e)}'`)):h.emit("error",r)}r()}}),p=c.metadata;return{type:"bindings",bindingsStream:h,metadata:p,variables:d}}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(82),i=r(281);function a(e){return e}t.AsyncEvaluator=class{constructor(e,t={}){this.algExpr=e,this.config=t,this.expr=n.transformAlgebra(e);const r={now:t.now||new Date(Date.now()),baseIRI:t.baseIRI||void 0,exists:t.exists,aggregate:t.aggregate};this.evaluator=new i.AsyncRecursiveEvaluator(r)}async evaluate(e){return a(await this.evaluator.evaluate(this.expr,e)).toRDF()}async evaluateAsEBV(e){return a(await this.evaluator.evaluate(this.expr,e)).coerceEBV()}async evaluateAsInternal(e){return a(await this.evaluator.evaluate(this.expr,e))}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(30);t.Variable=class{constructor(e){this.expressionType=n.ExpressionType.Variable,this.name=e}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(5),i=r(30),a=r(18),o=r(22);class s{constructor(){this.expressionType=i.ExpressionType.Term}str(){throw new o.InvalidArgumentTypes([this],a.RegularOperator.STR)}coerceEBV(){throw new o.EBVCoercionError(this)}}t.Term=s;t.NamedNode=class extends s{constructor(e){super(),this.value=e,this.termType="namedNode"}toRDF(){return n.namedNode(this.value)}str(){return this.value}};class c extends s{constructor(e){super(),this.value=e,this.termType="blankNode",this.value=e}static nextID(){return c._nextID+=1,c.nextID.toString()}toRDF(){return n.blankNode(this.value)}}c._nextID=0,t.BlankNode=c;class u extends s{constructor(e,t,r,n){super(),this.typedValue=e,this.typeURL=t,this.strValue=r,this.language=n,this.termType="literal",this.type=a.type(t.value)}toRDF(){return n.literal(this.strValue||this.str(),this.language||this.typeURL)}str(){return this.strValue||this.typedValue.toString()}}t.Literal=u;class l extends u{coerceEBV(){return!!this.typedValue}toRDF(){const e=super.toRDF();return isFinite(this.typedValue)||(e.value=e.value.replace("Infinity","INF")),e}str(){return this.strValue||l.specificFormatters[this.type](this.typedValue)}}l.specificFormatters={integer:e=>e.toFixed(),float:e=>e.toString(),decimal:e=>e.toString(),double:e=>{const t=e.toExponential(),[r,n]=t.split("e"),i=n.replace(/\+/,"");return`${r.match(/\./)?r:r+".0"}E${i}`}},t.NumericLiteral=l;t.BooleanLiteral=class extends u{constructor(e,t){super(e,a.make(a.TypeURL.XSD_BOOLEAN),t),this.typedValue=e,this.strValue=t}coerceEBV(){return!!this.typedValue}};t.DateTimeLiteral=class extends u{constructor(e,t){super(e,a.make(a.TypeURL.XSD_DATE_TIME),t),this.typedValue=e,this.strValue=t}};t.LangStringLiteral=class extends u{constructor(e,t){super(e,a.make(a.TypeURL.RDF_LANG_STRING),e,t),this.typedValue=e,this.language=t}coerceEBV(){return 0!==this.strValue.length}};t.StringLiteral=class extends u{constructor(e){super(e,a.make(a.TypeURL.XSD_STRING),e),this.typedValue=e}coerceEBV(){return 0!==this.strValue.length}};t.NonLexicalLiteral=class extends u{constructor(e,t,r,n){super(e,t,r,n),this.typedValue=void 0,this.type="nonlexical",this.shouldBeCategory=a.type(t.value)}coerceEBV(){if(a.PrimitiveNumericTypes.contains(this.shouldBeCategory)||"boolean"===this.shouldBeCategory)return!1;throw new o.EBVCoercionError(this)}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(30);t.Operator=class{constructor(e,t){this.args=e,this.apply=t,this.expressionType=n.ExpressionType.Operator}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(30);t.SpecialOperator=class{constructor(e,t,r){this.args=e,this.applyAsync=t,this.applySync=r,this.expressionType=n.ExpressionType.SpecialOperator}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(30);t.Named=class{constructor(e,t,r){this.name=e,this.args=t,this.apply=r,this.expressionType=n.ExpressionType.Named}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(30);t.Aggregate=class{constructor(e,t){this.name=e,this.expression=t,this.expressionType=n.ExpressionType.Aggregate}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(30);t.Existence=class{constructor(e){this.expression=e,this.expressionType=n.ExpressionType.Existence}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(25),i=r(22),a=r(18),o=r(83),s=r(84),c={arity:1,overloads:s.declare().onTerm1(e=>s.string(e.str())).collect()},u={arity:1,overloads:s.declare().onNumeric1(e=>s.number(e.typedValue)).onBoolean1Typed(e=>s.number(e?1:0)).onUnary("string",e=>{const t=o.parseXSDFloat(e.str());if(!t)throw new i.CastError(e,a.TypeURL.XSD_FLOAT);return s.number(t)}).copy({from:["string"],to:["nonlexical"]}).collect()},l={arity:1,overloads:s.declare().onNumeric1(e=>s.number(e.typedValue,a.TypeURL.XSD_DOUBLE)).onBoolean1Typed(e=>s.number(e?1:0,a.TypeURL.XSD_DOUBLE)).onUnary("string",e=>{const t=o.parseXSDFloat(e.str());if(!t)throw new i.CastError(e,a.TypeURL.XSD_DOUBLE);return s.number(t,a.TypeURL.XSD_DOUBLE)}).copy({from:["string"],to:["nonlexical"]}).collect()},f={arity:1,overloads:s.declare().onNumeric1(e=>{const t=o.parseXSDDecimal(e.str());if(!t)throw new i.CastError(e,a.TypeURL.XSD_DECIMAL);return s.number(t,a.TypeURL.XSD_DECIMAL)}).copy({from:["integer"],to:["string"]}).copy({from:["integer"],to:["nonlexical"]}).onBoolean1Typed(e=>s.number(e?1:0,a.TypeURL.XSD_DECIMAL)).collect()},d={arity:1,overloads:s.declare().onBoolean1Typed(e=>s.number(e?1:0,a.TypeURL.XSD_INTEGER)).onNumeric1(e=>{const t=o.parseXSDInteger(e.str());if(!t)throw new i.CastError(e,a.TypeURL.XSD_INTEGER);return s.number(t,a.TypeURL.XSD_INTEGER)}).copy({from:["integer"],to:["string"]}).copy({from:["integer"],to:["nonlexical"]}).collect()},h={arity:1,overloads:s.declare().onUnary("date",e=>e).onUnary("string",e=>{const t=new Date(e.str());if(isNaN(t.getTime()))throw new i.CastError(e,a.TypeURL.XSD_DATE_TIME);return s.dateTime(t,e.str())}).copy({from:["string"],to:["nonlexical"]}).collect()},p={arity:1,overloads:s.declare().onNumeric1(e=>s.bool(e.coerceEBV())).onUnary("boolean",e=>e).onUnary("string",e=>{const t=e.str();if("true"!==t&&"false"!==t)throw new i.CastError(e,a.TypeURL.XSD_BOOLEAN);return s.bool("true"===t)}).copy({from:["string"],to:["nonlexical"]}).collect()},y={[a.TypeURL.XSD_STRING]:c,[a.TypeURL.XSD_FLOAT]:u,[a.TypeURL.XSD_DOUBLE]:l,[a.TypeURL.XSD_DECIMAL]:f,[a.TypeURL.XSD_INTEGER]:d,[a.TypeURL.XSD_DATE_TIME]:h,[a.TypeURL.XSD_DATE]:h,[a.TypeURL.XSD_BOOLEAN]:p};t.namedDefinitions=n.Map(y)},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(5),i=r(44),a=r(679),o=r(280),s=r(25),c=r(47),u=r(18),l=r(22),f=r(83),d=r(681),h=r(18),p=r(82),y=r(84);function m(e,t){const r=e.toRDF(),n=t.toRDF(),i=r.equals(n);if("Literal"===r.termType&&"Literal"===n.termType)throw new l.RDFEqualTypeError([e,t]);return i}const g=(e,t)=>y.bool(d.matches(e,t)),b=(e,t,r)=>y.bool(d.matches(e,t,r));function v(e){return f.parseXSDDateTime(e.str())}const _={"!":{arity:1,overloads:y.declare().onTerm1(e=>y.bool(!e.coerceEBV())).collect()},UPLUS:{arity:1,overloads:y.declare().onNumeric1(e=>y.number(e.typedValue,e.typeURL.value)).collect()},UMINUS:{arity:1,overloads:y.declare().onNumeric1(e=>y.number(-e.typedValue,e.typeURL.value)).collect()},"*":{arity:2,overloads:y.declare().arithmetic((e,t)=>a.Decimal.mul(e,t).toNumber()).collect()},"/":{arity:2,overloads:y.declare().arithmetic((e,t)=>a.Decimal.div(e,t).toNumber()).onBinaryTyped(["integer","integer"],(e,t)=>{if(0===t)throw new l.ExpressionError("Integer division by 0");return y.number(a.Decimal.div(e,t).toNumber(),h.TypeURL.XSD_DECIMAL)}).collect()},"+":{arity:2,overloads:y.declare().arithmetic((e,t)=>a.Decimal.add(e,t).toNumber()).collect()},"-":{arity:2,overloads:y.declare().arithmetic((e,t)=>a.Decimal.sub(e,t).toNumber()).collect()},"=":{arity:2,overloads:y.declare().numberTest((e,t)=>e===t).stringTest((e,t)=>0===e.localeCompare(t)).booleanTest((e,t)=>e===t).dateTimeTest((e,t)=>e.getTime()===t.getTime()).set(["term","term"],([e,t])=>y.bool(m(e,t))).collect()},"!=":{arity:2,overloads:y.declare().numberTest((e,t)=>e!==t).stringTest((e,t)=>0!==e.localeCompare(t)).booleanTest((e,t)=>e!==t).dateTimeTest((e,t)=>e.getTime()!==t.getTime()).set(["term","term"],([e,t])=>y.bool(!m(e,t))).collect()},"<":{arity:2,overloads:y.declare().numberTest((e,t)=>e<t).stringTest((e,t)=>-1===e.localeCompare(t)).booleanTest((e,t)=>e<t).dateTimeTest((e,t)=>e.getTime()<t.getTime()).collect()},">":{arity:2,overloads:y.declare().numberTest((e,t)=>e>t).stringTest((e,t)=>1===e.localeCompare(t)).booleanTest((e,t)=>e>t).dateTimeTest((e,t)=>e.getTime()>t.getTime()).collect()},"<=":{arity:2,overloads:y.declare().numberTest((e,t)=>e<=t).stringTest((e,t)=>1!==e.localeCompare(t)).booleanTest((e,t)=>e<=t).dateTimeTest((e,t)=>e.getTime()<=t.getTime()).collect()},">=":{arity:2,overloads:y.declare().numberTest((e,t)=>e>=t).stringTest((e,t)=>-1!==e.localeCompare(t)).booleanTest((e,t)=>e>=t).dateTimeTest((e,t)=>e.getTime()>=t.getTime()).collect()},isiri:{arity:1,overloads:y.declare().onTerm1(e=>y.bool("namedNode"===e.termType)).collect()},isblank:{arity:1,overloads:y.declare().onTerm1(e=>y.bool("blankNode"===e.termType)).collect()},isliteral:{arity:1,overloads:y.declare().onTerm1(e=>y.bool("literal"===e.termType)).collect()},isnumeric:{arity:1,overloads:y.declare().onNumeric1(e=>y.bool(!0)).onTerm1(e=>y.bool(!1)).collect()},str:{arity:1,overloads:y.declare().onTerm1(e=>y.string(e.str())).collect()},lang:{arity:1,overloads:y.declare().onLiteral1(e=>y.string(e.language||"")).collect()},datatype:{arity:1,overloads:y.declare().onLiteral1(e=>new c.NamedNode(e.typeURL.value)).collect()},strdt:{arity:2,overloads:y.declare().onBinary(["string","namedNode"],(e,t)=>{const r=n.literal(e.typedValue,n.namedNode(t.value));return p.transformLiteral(r)}).collect()},strlang:{arity:2,overloads:y.declare().onBinaryTyped(["string","string"],(e,t)=>new c.LangStringLiteral(e,t.toLowerCase())).collect()},uuid:{arity:0,overloads:y.declare().set([],()=>new c.NamedNode(`urn:uuid:${o.v4()}`)).collect()},struuid:{arity:0,overloads:y.declare().set([],()=>y.string(o.v4())).collect()},strlen:{arity:1,overloads:y.declare().onStringly1(e=>y.number(e.typedValue.length,h.TypeURL.XSD_INTEGER)).collect()},substr:{arity:[2,3],overloads:y.declare().onBinaryTyped(["string","integer"],(e,t)=>y.string(e.substr(t-1))).onBinary(["langString","integer"],(e,t)=>{const r=e.typedValue.substr(t.typedValue-1);return y.langString(r,e.language)}).onTernaryTyped(["string","integer","integer"],(e,t,r)=>y.string(e.substr(t-1,r))).onTernary(["langString","integer","integer"],(e,t,r)=>{const n=e.typedValue.substr(t.typedValue-1,r.typedValue);return y.langString(n,e.language)}).collect()},ucase:{arity:1,overloads:y.declare().onString1Typed(e=>y.string(e.toUpperCase())).onLangString1(e=>y.langString(e.typedValue.toUpperCase(),e.language)).collect()},lcase:{arity:1,overloads:y.declare().onString1Typed(e=>y.string(e.toLowerCase())).onLangString1(e=>y.langString(e.typedValue.toLowerCase(),e.language)).collect()},strstarts:{arity:2,overloads:y.declare().onBinaryTyped(["string","string"],(e,t)=>y.bool(e.startsWith(t))).onBinaryTyped(["langString","string"],(e,t)=>y.bool(e.includes(t))).onBinary(["langString","langString"],(e,t)=>{if(e.language!==t.language)throw new l.IncompatibleLanguageOperation(e,t);return y.bool(e.typedValue.startsWith(t.typedValue))}).collect()},strends:{arity:2,overloads:y.declare().onBinaryTyped(["string","string"],(e,t)=>y.bool(e.endsWith(t))).onBinaryTyped(["langString","string"],(e,t)=>y.bool(e.includes(t))).onBinary(["langString","langString"],(e,t)=>{if(e.language!==t.language)throw new l.IncompatibleLanguageOperation(e,t);return y.bool(e.typedValue.endsWith(t.typedValue))}).collect()},contains:{arity:2,overloads:y.declare().onBinaryTyped(["string","string"],(e,t)=>y.bool(e.includes(t))).onBinaryTyped(["langString","string"],(e,t)=>y.bool(e.includes(t))).onBinary(["langString","langString"],(e,t)=>{if(e.language!==t.language)throw new l.IncompatibleLanguageOperation(e,t);return y.bool(e.typedValue.includes(t.typedValue))}).collect()},strbefore:{arity:2,overloads:y.declare().onBinaryTyped(["string","string"],(e,t)=>y.string(e.substr(0,e.indexOf(t)))).onBinary(["langString","string"],(e,t)=>{const[r,n]=[e.typedValue,t.typedValue],i=e.typedValue.substr(0,r.indexOf(n));return i||!n?y.langString(i,e.language):y.string(i)}).onBinary(["langString","langString"],(e,t)=>{if(e.language!==t.language)throw new l.IncompatibleLanguageOperation(e,t);const[r,n]=[e.typedValue,t.typedValue],i=e.typedValue.substr(0,r.indexOf(n));return i||!n?y.langString(i,e.language):y.string(i)}).collect()},strafter:{arity:2,overloads:y.declare().onBinaryTyped(["string","string"],(e,t)=>y.string(e.substr(e.indexOf(t)).substr(t.length))).onBinary(["langString","string"],(e,t)=>{const[r,n]=[e.typedValue,t.typedValue],i=r.substr(r.indexOf(n)).substr(n.length);return i||!n?y.langString(i,e.language):y.string(i)}).onBinary(["langString","langString"],(e,t)=>{if(e.language!==t.language)throw new l.IncompatibleLanguageOperation(e,t);const[r,n]=[e.typedValue,t.typedValue],i=r.substr(r.indexOf(n)).substr(n.length);return i||!n?y.langString(i,e.language):y.string(i)}).collect()},encode_for_uri:{arity:1,overloads:y.declare().onStringly1Typed(e=>y.string(encodeURI(e))).collect()},langmatches:{arity:2,overloads:y.declare().onBinaryTyped(["string","string"],(e,t)=>y.bool(d.langMatches(e,t))).collect()},regex:{arity:[2,3],overloads:y.declare().onBinaryTyped(["string","string"],g).onBinaryTyped(["langString","string"],g).onTernaryTyped(["string","string","string"],b).onTernaryTyped(["langString","string","string"],b).collect()},replace:{arity:[3,4],overloads:y.declare().onTernaryTyped(["string","string","string"],(e,t,r)=>y.string(d.replace(e,t,r))).set(["langString","string","string"],([e,t,r])=>{const n=d.replace(e.typedValue,t.typedValue,r.typedValue);return y.langString(n,e.language)}).onQuaternaryTyped(["string","string","string","string"],(e,t,r,n)=>y.string(d.replace(e,t,r,n))).set(["langString","string","string","string"],([e,t,r,n])=>{const i=d.replace(e.typedValue,t.typedValue,r.typedValue,n.typedValue);return y.langString(i,e.language)}).collect()},abs:{arity:1,overloads:y.declare().onNumeric1(e=>y.number(Math.abs(e.typedValue),e.typeURL.value)).collect()},round:{arity:1,overloads:y.declare().onNumeric1(e=>y.number(Math.round(e.typedValue),e.typeURL.value)).collect()},ceil:{arity:1,overloads:y.declare().onNumeric1(e=>y.number(Math.ceil(e.typedValue),e.typeURL.value)).collect()},floor:{arity:1,overloads:y.declare().onNumeric1(e=>y.number(Math.floor(e.typedValue),e.typeURL.value)).collect()},rand:{arity:0,overloads:y.declare().set([],()=>y.number(Math.random(),h.TypeURL.XSD_DOUBLE)).collect()},year:{arity:1,overloads:y.declare().onDateTime1(e=>y.number(Number(v(e).year),h.TypeURL.XSD_INTEGER)).collect()},month:{arity:1,overloads:y.declare().onDateTime1(e=>y.number(Number(v(e).month),h.TypeURL.XSD_INTEGER)).collect()},day:{arity:1,overloads:y.declare().onDateTime1(e=>y.number(Number(v(e).day),h.TypeURL.XSD_INTEGER)).collect()},hours:{arity:1,overloads:y.declare().onDateTime1(e=>y.number(Number(v(e).hours),h.TypeURL.XSD_INTEGER)).collect()},minutes:{arity:1,overloads:y.declare().onDateTime1(e=>y.number(Number(v(e).minutes),h.TypeURL.XSD_INTEGER)).collect()},seconds:{arity:1,overloads:y.declare().onDateTime1(e=>y.number(Number(v(e).seconds),h.TypeURL.XSD_DECIMAL)).collect()},timezone:{arity:1,overloads:y.declare().onDateTime1(e=>{const t=d.formatDayTimeDuration(v(e).timezone);if(!t)throw new l.InvalidTimezoneCall(e.strValue);return new c.Literal(t,u.make(h.TypeURL.XSD_DAYTIME_DURATION),t)}).collect()},tz:{arity:1,overloads:y.declare().onDateTime1(e=>y.string(v(e).timezone)).collect()},md5:{arity:1,overloads:y.declare().onString1Typed(e=>y.string(i("md5").update(e).digest("hex"))).collect()},sha1:{arity:1,overloads:y.declare().onString1Typed(e=>y.string(i("sha1").update(e).digest("hex"))).collect()},sha256:{arity:1,overloads:y.declare().onString1Typed(e=>y.string(i("sha256").update(e).digest("hex"))).collect()},sha384:{arity:1,overloads:y.declare().onString1Typed(e=>y.string(i("sha384").update(e).digest("hex"))).collect()},sha512:{arity:1,overloads:y.declare().onString1Typed(e=>y.string(i("sha512").update(e).digest("hex"))).collect()}};t.definitions=s.Map(_)},function(e,t,r){var n;!function(i){"use strict";var a,o,s,c=9e15,u=1e9,l="0123456789abcdef",f="2.3025850929940456840179914546843642076011014886287729760333279009675726096773524802359972050895982983419677840422862486334095254650828067566662873690987816894829072083255546808437998948262331985283935053089653777326288461633662222876982198867465436674744042432743651550489343149393914796194044002221051017141748003688084012647080685567743216228355220114804663715659121373450747856947683463616792101806445070648000277502684916746550586856935673420670581136429224554405758925724208241314695689016758940256776311356919292033376587141660230105703089634572075440370847469940168269282808481184289314848524948644871927809676271275775397027668605952496716674183485704422507197965004714951050492214776567636938662976979522110718264549734772662425709429322582798502585509785265383207606726317164309505995087807523710333101197857547331541421808427543863591778117054309827482385045648019095610299291824318237525357709750539565187697510374970888692180205189339507238539205144634197265287286965110862571492198849978748873771345686209167058",d="3.1415926535897932384626433832795028841971693993751058209749445923078164062862089986280348253421170679821480865132823066470938446095505822317253594081284811174502841027019385211055596446229489549303819644288109756659334461284756482337867831652712019091456485669234603486104543266482133936072602491412737245870066063155881748815209209628292540917153643678925903600113305305488204665213841469519415116094330572703657595919530921861173819326117931051185480744623799627495673518857527248912279381830119491298336733624406566430860213949463952247371907021798609437027705392171762931767523846748184676694051320005681271452635608277857713427577896091736371787214684409012249534301465495853710507922796892589235420199561121290219608640344181598136297747713099605187072113499999983729780499510597317328160963185950244594553469083026425223082533446850352619311881710100031378387528865875332083814206171776691473035982534904287554687311595628638823537875937519577818577805321712268066130019278766111959092164201989380952572010654858632789",h={precision:20,rounding:4,modulo:1,toExpNeg:-7,toExpPos:21,minE:-c,maxE:c,crypto:!1},p=!0,y="[DecimalError] ",m=y+"Invalid argument: ",g=y+"Precision limit exceeded",b=y+"crypto unavailable",v=Math.floor,_=Math.pow,w=/^0b([01]+(\.[01]*)?|\.[01]+)(p[+-]?\d+)?$/i,S=/^0x([0-9a-f]+(\.[0-9a-f]*)?|\.[0-9a-f]+)(p[+-]?\d+)?$/i,E=/^0o([0-7]+(\.[0-7]*)?|\.[0-7]+)(p[+-]?\d+)?$/i,x=/^(\d+(\.\d*)?|\.\d+)(e[+-]?\d+)?$/i,T=1e7,O=7,A=f.length-1,I=d.length-1,N={name:"[object Decimal]"};function R(e){var t,r,n,i=e.length-1,a="",o=e[0];if(i>0){for(a+=o,t=1;t<i;t++)n=e[t]+"",(r=O-n.length)&&(a+=U(r)),a+=n;o=e[t],(r=O-(n=o+"").length)&&(a+=U(r))}else if(0===o)return"0";for(;o%10==0;)o/=10;return a+o}function k(e,t,r){if(e!==~~e||e<t||e>r)throw Error(m+e)}function P(e,t,r,n){var i,a,o,s;for(a=e[0];a>=10;a/=10)--t;return--t<0?(t+=O,i=0):(i=Math.ceil((t+1)/O),t%=O),a=_(10,O-t),s=e[i]%a|0,null==n?t<3?(0==t?s=s/100|0:1==t&&(s=s/10|0),o=r<4&&99999==s||r>3&&49999==s||5e4==s||0==s):o=(r<4&&s+1==a||r>3&&s+1==a/2)&&(e[i+1]/a/100|0)==_(10,t-2)-1||(s==a/2||0==s)&&0==(e[i+1]/a/100|0):t<4?(0==t?s=s/1e3|0:1==t?s=s/100|0:2==t&&(s=s/10|0),o=(n||r<4)&&9999==s||!n&&r>3&&4999==s):o=((n||r<4)&&s+1==a||!n&&r>3&&s+1==a/2)&&(e[i+1]/a/1e3|0)==_(10,t-3)-1,o}function j(e,t,r){for(var n,i,a=[0],o=0,s=e.length;o<s;){for(i=a.length;i--;)a[i]*=t;for(a[0]+=l.indexOf(e.charAt(o++)),n=0;n<a.length;n++)a[n]>r-1&&(void 0===a[n+1]&&(a[n+1]=0),a[n+1]+=a[n]/r|0,a[n]%=r)}return a.reverse()}N.absoluteValue=N.abs=function(){var e=new this.constructor(this);return e.s<0&&(e.s=1),C(e)},N.ceil=function(){return C(new this.constructor(this),this.e+1,2)},N.comparedTo=N.cmp=function(e){var t,r,n,i,a=this,o=a.d,s=(e=new a.constructor(e)).d,c=a.s,u=e.s;if(!o||!s)return c&&u?c!==u?c:o===s?0:!o^c<0?1:-1:NaN;if(!o[0]||!s[0])return o[0]?c:s[0]?-u:0;if(c!==u)return c;if(a.e!==e.e)return a.e>e.e^c<0?1:-1;for(t=0,r=(n=o.length)<(i=s.length)?n:i;t<r;++t)if(o[t]!==s[t])return o[t]>s[t]^c<0?1:-1;return n===i?0:n>i^c<0?1:-1},N.cosine=N.cos=function(){var e,t,r=this,n=r.constructor;return r.d?r.d[0]?(e=n.precision,t=n.rounding,n.precision=e+Math.max(r.e,r.sd())+O,n.rounding=1,r=function(e,t){var r,n,i=t.d.length;i<32?(r=Math.ceil(i/3),n=(1/K(4,r)).toString()):(r=16,n="2.3283064365386962890625e-10");e.precision+=r,t=Y(e,1,t.times(n),new e(1));for(var a=r;a--;){var o=t.times(t);t=o.times(o).minus(o).times(8).plus(1)}return e.precision-=r,t}(n,W(n,r)),n.precision=e,n.rounding=t,C(2==s||3==s?r.neg():r,e,t,!0)):new n(1):new n(NaN)},N.cubeRoot=N.cbrt=function(){var e,t,r,n,i,a,o,s,c,u,l=this,f=l.constructor;if(!l.isFinite()||l.isZero())return new f(l);for(p=!1,(a=l.s*_(l.s*l,1/3))&&Math.abs(a)!=1/0?n=new f(a.toString()):(r=R(l.d),(a=((e=l.e)-r.length+1)%3)&&(r+=1==a||-2==a?"0":"00"),a=_(r,1/3),e=v((e+1)/3)-(e%3==(e<0?-1:2)),(n=new f(r=a==1/0?"5e"+e:(r=a.toExponential()).slice(0,r.indexOf("e")+1)+e)).s=l.s),o=(e=f.precision)+3;;)if(u=(c=(s=n).times(s).times(s)).plus(l),n=D(u.plus(l).times(s),u.plus(c),o+2,1),R(s.d).slice(0,o)===(r=R(n.d)).slice(0,o)){if("9999"!=(r=r.slice(o-3,o+1))&&(i||"4999"!=r)){+r&&(+r.slice(1)||"5"!=r.charAt(0))||(C(n,e+1,1),t=!n.times(n).times(n).eq(l));break}if(!i&&(C(s,e+1,0),s.times(s).times(s).eq(l))){n=s;break}o+=4,i=1}return p=!0,C(n,e,f.rounding,t)},N.decimalPlaces=N.dp=function(){var e,t=this.d,r=NaN;if(t){if(r=((e=t.length-1)-v(this.e/O))*O,e=t[e])for(;e%10==0;e/=10)r--;r<0&&(r=0)}return r},N.dividedBy=N.div=function(e){return D(this,new this.constructor(e))},N.dividedToIntegerBy=N.divToInt=function(e){var t=this.constructor;return C(D(this,new t(e),0,1,1),t.precision,t.rounding)},N.equals=N.eq=function(e){return 0===this.cmp(e)},N.floor=function(){return C(new this.constructor(this),this.e+1,3)},N.greaterThan=N.gt=function(e){return this.cmp(e)>0},N.greaterThanOrEqualTo=N.gte=function(e){var t=this.cmp(e);return 1==t||0===t},N.hyperbolicCosine=N.cosh=function(){var e,t,r,n,i,a=this,o=a.constructor,s=new o(1);if(!a.isFinite())return new o(a.s?1/0:NaN);if(a.isZero())return s;r=o.precision,n=o.rounding,o.precision=r+Math.max(a.e,a.sd())+4,o.rounding=1,(i=a.d.length)<32?t=(1/K(4,e=Math.ceil(i/3))).toString():(e=16,t="2.3283064365386962890625e-10"),a=Y(o,1,a.times(t),new o(1),!0);for(var c,u=e,l=new o(8);u--;)c=a.times(a),a=s.minus(c.times(l.minus(c.times(l))));return C(a,o.precision=r,o.rounding=n,!0)},N.hyperbolicSine=N.sinh=function(){var e,t,r,n,i=this,a=i.constructor;if(!i.isFinite()||i.isZero())return new a(i);if(t=a.precision,r=a.rounding,a.precision=t+Math.max(i.e,i.sd())+4,a.rounding=1,(n=i.d.length)<3)i=Y(a,2,i,i,!0);else{e=(e=1.4*Math.sqrt(n))>16?16:0|e,i=Y(a,2,i=i.times(1/K(5,e)),i,!0);for(var o,s=new a(5),c=new a(16),u=new a(20);e--;)o=i.times(i),i=i.times(s.plus(o.times(c.times(o).plus(u))))}return a.precision=t,a.rounding=r,C(i,t,r,!0)},N.hyperbolicTangent=N.tanh=function(){var e,t,r=this,n=r.constructor;return r.isFinite()?r.isZero()?new n(r):(e=n.precision,t=n.rounding,n.precision=e+7,n.rounding=1,D(r.sinh(),r.cosh(),n.precision=e,n.rounding=t)):new n(r.s)},N.inverseCosine=N.acos=function(){var e,t=this,r=t.constructor,n=t.abs().cmp(1),i=r.precision,a=r.rounding;return-1!==n?0===n?t.isNeg()?F(r,i,a):new r(0):new r(NaN):t.isZero()?F(r,i+4,a).times(.5):(r.precision=i+6,r.rounding=1,t=t.asin(),e=F(r,i+4,a).times(.5),r.precision=i,r.rounding=a,e.minus(t))},N.inverseHyperbolicCosine=N.acosh=function(){var e,t,r=this,n=r.constructor;return r.lte(1)?new n(r.eq(1)?0:NaN):r.isFinite()?(e=n.precision,t=n.rounding,n.precision=e+Math.max(Math.abs(r.e),r.sd())+4,n.rounding=1,p=!1,r=r.times(r).minus(1).sqrt().plus(r),p=!0,n.precision=e,n.rounding=t,r.ln()):new n(r)},N.inverseHyperbolicSine=N.asinh=function(){var e,t,r=this,n=r.constructor;return!r.isFinite()||r.isZero()?new n(r):(e=n.precision,t=n.rounding,n.precision=e+2*Math.max(Math.abs(r.e),r.sd())+6,n.rounding=1,p=!1,r=r.times(r).plus(1).sqrt().plus(r),p=!0,n.precision=e,n.rounding=t,r.ln())},N.inverseHyperbolicTangent=N.atanh=function(){var e,t,r,n,i=this,a=i.constructor;return i.isFinite()?i.e>=0?new a(i.abs().eq(1)?i.s/0:i.isZero()?i:NaN):(e=a.precision,t=a.rounding,n=i.sd(),Math.max(n,e)<2*-i.e-1?C(new a(i),e,t,!0):(a.precision=r=n-i.e,i=D(i.plus(1),new a(1).minus(i),r+e,1),a.precision=e+4,a.rounding=1,i=i.ln(),a.precision=e,a.rounding=t,i.times(.5))):new a(NaN)},N.inverseSine=N.asin=function(){var e,t,r,n,i=this,a=i.constructor;return i.isZero()?new a(i):(t=i.abs().cmp(1),r=a.precision,n=a.rounding,-1!==t?0===t?((e=F(a,r+4,n).times(.5)).s=i.s,e):new a(NaN):(a.precision=r+6,a.rounding=1,i=i.div(new a(1).minus(i.times(i)).sqrt().plus(1)).atan(),a.precision=r,a.rounding=n,i.times(2)))},N.inverseTangent=N.atan=function(){var e,t,r,n,i,a,o,s,c,u=this,l=u.constructor,f=l.precision,d=l.rounding;if(u.isFinite()){if(u.isZero())return new l(u);if(u.abs().eq(1)&&f+4<=I)return(o=F(l,f+4,d).times(.25)).s=u.s,o}else{if(!u.s)return new l(NaN);if(f+4<=I)return(o=F(l,f+4,d).times(.5)).s=u.s,o}for(l.precision=s=f+10,l.rounding=1,e=r=Math.min(28,s/O+2|0);e;--e)u=u.div(u.times(u).plus(1).sqrt().plus(1));for(p=!1,t=Math.ceil(s/O),n=1,c=u.times(u),o=new l(u),i=u;-1!==e;)if(i=i.times(c),a=o.minus(i.div(n+=2)),i=i.times(c),void 0!==(o=a.plus(i.div(n+=2))).d[t])for(e=t;o.d[e]===a.d[e]&&e--;);return r&&(o=o.times(2<<r-1)),p=!0,C(o,l.precision=f,l.rounding=d,!0)},N.isFinite=function(){return!!this.d},N.isInteger=N.isInt=function(){return!!this.d&&v(this.e/O)>this.d.length-2},N.isNaN=function(){return!this.s},N.isNegative=N.isNeg=function(){return this.s<0},N.isPositive=N.isPos=function(){return this.s>0},N.isZero=function(){return!!this.d&&0===this.d[0]},N.lessThan=N.lt=function(e){return this.cmp(e)<0},N.lessThanOrEqualTo=N.lte=function(e){return this.cmp(e)<1},N.logarithm=N.log=function(e){var t,r,n,i,a,o,s,c,u=this.constructor,l=u.precision,f=u.rounding;if(null==e)e=new u(10),t=!0;else{if(r=(e=new u(e)).d,e.s<0||!r||!r[0]||e.eq(1))return new u(NaN);t=e.eq(10)}if(r=this.d,this.s<0||!r||!r[0]||this.eq(1))return new u(r&&!r[0]?-1/0:1!=this.s?NaN:r?0:1/0);if(t)if(r.length>1)a=!0;else{for(i=r[0];i%10==0;)i/=10;a=1!==i}if(p=!1,o=Q(this,s=l+5),n=t?q(u,s+10):Q(e,s),P((c=D(o,n,s,1)).d,i=l,f))do{if(o=Q(this,s+=10),n=t?q(u,s+10):Q(e,s),c=D(o,n,s,1),!a){+R(c.d).slice(i+1,i+15)+1==1e14&&(c=C(c,l+1,0));break}}while(P(c.d,i+=10,f));return p=!0,C(c,l,f)},N.minus=N.sub=function(e){var t,r,n,i,a,o,s,c,u,l,f,d,h=this,y=h.constructor;if(e=new y(e),!h.d||!e.d)return h.s&&e.s?h.d?e.s=-e.s:e=new y(e.d||h.s!==e.s?h:NaN):e=new y(NaN),e;if(h.s!=e.s)return e.s=-e.s,h.plus(e);if(u=h.d,d=e.d,s=y.precision,c=y.rounding,!u[0]||!d[0]){if(d[0])e.s=-e.s;else{if(!u[0])return new y(3===c?-0:0);e=new y(h)}return p?C(e,s,c):e}if(r=v(e.e/O),l=v(h.e/O),u=u.slice(),a=l-r){for((f=a<0)?(t=u,a=-a,o=d.length):(t=d,r=l,o=u.length),a>(n=Math.max(Math.ceil(s/O),o)+2)&&(a=n,t.length=1),t.reverse(),n=a;n--;)t.push(0);t.reverse()}else{for((f=(n=u.length)<(o=d.length))&&(o=n),n=0;n<o;n++)if(u[n]!=d[n]){f=u[n]<d[n];break}a=0}for(f&&(t=u,u=d,d=t,e.s=-e.s),o=u.length,n=d.length-o;n>0;--n)u[o++]=0;for(n=d.length;n>a;){if(u[--n]<d[n]){for(i=n;i&&0===u[--i];)u[i]=T-1;--u[i],u[n]+=T}u[n]-=d[n]}for(;0===u[--o];)u.pop();for(;0===u[0];u.shift())--r;return u[0]?(e.d=u,e.e=L(u,r),p?C(e,s,c):e):new y(3===c?-0:0)},N.modulo=N.mod=function(e){var t,r=this,n=r.constructor;return e=new n(e),!r.d||!e.s||e.d&&!e.d[0]?new n(NaN):!e.d||r.d&&!r.d[0]?C(new n(r),n.precision,n.rounding):(p=!1,9==n.modulo?(t=D(r,e.abs(),0,3,1)).s*=e.s:t=D(r,e,0,n.modulo,1),t=t.times(e),p=!0,r.minus(t))},N.naturalExponential=N.exp=function(){return G(this)},N.naturalLogarithm=N.ln=function(){return Q(this)},N.negated=N.neg=function(){var e=new this.constructor(this);return e.s=-e.s,C(e)},N.plus=N.add=function(e){var t,r,n,i,a,o,s,c,u,l,f=this,d=f.constructor;if(e=new d(e),!f.d||!e.d)return f.s&&e.s?f.d||(e=new d(e.d||f.s===e.s?f:NaN)):e=new d(NaN),e;if(f.s!=e.s)return e.s=-e.s,f.minus(e);if(u=f.d,l=e.d,s=d.precision,c=d.rounding,!u[0]||!l[0])return l[0]||(e=new d(f)),p?C(e,s,c):e;if(a=v(f.e/O),n=v(e.e/O),u=u.slice(),i=a-n){for(i<0?(r=u,i=-i,o=l.length):(r=l,n=a,o=u.length),i>(o=(a=Math.ceil(s/O))>o?a+1:o+1)&&(i=o,r.length=1),r.reverse();i--;)r.push(0);r.reverse()}for((o=u.length)-(i=l.length)<0&&(i=o,r=l,l=u,u=r),t=0;i;)t=(u[--i]=u[i]+l[i]+t)/T|0,u[i]%=T;for(t&&(u.unshift(t),++n),o=u.length;0==u[--o];)u.pop();return e.d=u,e.e=L(u,n),p?C(e,s,c):e},N.precision=N.sd=function(e){var t,r=this;if(void 0!==e&&e!==!!e&&1!==e&&0!==e)throw Error(m+e);return r.d?(t=B(r.d),e&&r.e+1>t&&(t=r.e+1)):t=NaN,t},N.round=function(){var e=this,t=e.constructor;return C(new t(e),e.e+1,t.rounding)},N.sine=N.sin=function(){var e,t,r=this,n=r.constructor;return r.isFinite()?r.isZero()?new n(r):(e=n.precision,t=n.rounding,n.precision=e+Math.max(r.e,r.sd())+O,n.rounding=1,r=function(e,t){var r,n=t.d.length;if(n<3)return Y(e,2,t,t);r=(r=1.4*Math.sqrt(n))>16?16:0|r,t=t.times(1/K(5,r)),t=Y(e,2,t,t);for(var i,a=new e(5),o=new e(16),s=new e(20);r--;)i=t.times(t),t=t.times(a.plus(i.times(o.times(i).minus(s))));return t}(n,W(n,r)),n.precision=e,n.rounding=t,C(s>2?r.neg():r,e,t,!0)):new n(NaN)},N.squareRoot=N.sqrt=function(){var e,t,r,n,i,a,o=this,s=o.d,c=o.e,u=o.s,l=o.constructor;if(1!==u||!s||!s[0])return new l(!u||u<0&&(!s||s[0])?NaN:s?o:1/0);for(p=!1,0==(u=Math.sqrt(+o))||u==1/0?(((t=R(s)).length+c)%2==0&&(t+="0"),u=Math.sqrt(t),c=v((c+1)/2)-(c<0||c%2),n=new l(t=u==1/0?"1e"+c:(t=u.toExponential()).slice(0,t.indexOf("e")+1)+c)):n=new l(u.toString()),r=(c=l.precision)+3;;)if(n=(a=n).plus(D(o,a,r+2,1)).times(.5),R(a.d).slice(0,r)===(t=R(n.d)).slice(0,r)){if("9999"!=(t=t.slice(r-3,r+1))&&(i||"4999"!=t)){+t&&(+t.slice(1)||"5"!=t.charAt(0))||(C(n,c+1,1),e=!n.times(n).eq(o));break}if(!i&&(C(a,c+1,0),a.times(a).eq(o))){n=a;break}r+=4,i=1}return p=!0,C(n,c,l.rounding,e)},N.tangent=N.tan=function(){var e,t,r=this,n=r.constructor;return r.isFinite()?r.isZero()?new n(r):(e=n.precision,t=n.rounding,n.precision=e+10,n.rounding=1,(r=r.sin()).s=1,r=D(r,new n(1).minus(r.times(r)).sqrt(),e+10,0),n.precision=e,n.rounding=t,C(2==s||4==s?r.neg():r,e,t,!0)):new n(NaN)},N.times=N.mul=function(e){var t,r,n,i,a,o,s,c,u,l=this,f=l.constructor,d=l.d,h=(e=new f(e)).d;if(e.s*=l.s,!(d&&d[0]&&h&&h[0]))return new f(!e.s||d&&!d[0]&&!h||h&&!h[0]&&!d?NaN:d&&h?0*e.s:e.s/0);for(r=v(l.e/O)+v(e.e/O),(c=d.length)<(u=h.length)&&(a=d,d=h,h=a,o=c,c=u,u=o),a=[],n=o=c+u;n--;)a.push(0);for(n=u;--n>=0;){for(t=0,i=c+n;i>n;)s=a[i]+h[n]*d[i-n-1]+t,a[i--]=s%T|0,t=s/T|0;a[i]=(a[i]+t)%T|0}for(;!a[--o];)a.pop();return t?++r:a.shift(),e.d=a,e.e=L(a,r),p?C(e,f.precision,f.rounding):e},N.toBinary=function(e,t){return Z(this,2,e,t)},N.toDecimalPlaces=N.toDP=function(e,t){var r=this,n=r.constructor;return r=new n(r),void 0===e?r:(k(e,0,u),void 0===t?t=n.rounding:k(t,0,8),C(r,e+r.e+1,t))},N.toExponential=function(e,t){var r,n=this,i=n.constructor;return void 0===e?r=M(n,!0):(k(e,0,u),void 0===t?t=i.rounding:k(t,0,8),r=M(n=C(new i(n),e+1,t),!0,e+1)),n.isNeg()&&!n.isZero()?"-"+r:r},N.toFixed=function(e,t){var r,n,i=this,a=i.constructor;return void 0===e?r=M(i):(k(e,0,u),void 0===t?t=a.rounding:k(t,0,8),r=M(n=C(new a(i),e+i.e+1,t),!1,e+n.e+1)),i.isNeg()&&!i.isZero()?"-"+r:r},N.toFraction=function(e){var t,r,n,i,a,o,s,c,u,l,f,d,h=this,y=h.d,g=h.constructor;if(!y)return new g(h);if(u=r=new g(1),n=c=new g(0),o=(a=(t=new g(n)).e=B(y)-h.e-1)%O,t.d[0]=_(10,o<0?O+o:o),null==e)e=a>0?t:u;else{if(!(s=new g(e)).isInt()||s.lt(u))throw Error(m+s);e=s.gt(t)?a>0?t:u:s}for(p=!1,s=new g(R(y)),l=g.precision,g.precision=a=y.length*O*2;f=D(s,t,0,1,1),1!=(i=r.plus(f.times(n))).cmp(e);)r=n,n=i,i=u,u=c.plus(f.times(i)),c=i,i=t,t=s.minus(f.times(i)),s=i;return i=D(e.minus(r),n,0,1,1),c=c.plus(i.times(u)),r=r.plus(i.times(n)),c.s=u.s=h.s,d=D(u,n,a,1).minus(h).abs().cmp(D(c,r,a,1).minus(h).abs())<1?[u,n]:[c,r],g.precision=l,p=!0,d},N.toHexadecimal=N.toHex=function(e,t){return Z(this,16,e,t)},N.toNearest=function(e,t){var r=this,n=r.constructor;if(r=new n(r),null==e){if(!r.d)return r;e=new n(1),t=n.rounding}else{if(e=new n(e),void 0===t?t=n.rounding:k(t,0,8),!r.d)return e.s?r:e;if(!e.d)return e.s&&(e.s=r.s),e}return e.d[0]?(p=!1,r=D(r,e,0,t,1).times(e),p=!0,C(r)):(e.s=r.s,r=e),r},N.toNumber=function(){return+this},N.toOctal=function(e,t){return Z(this,8,e,t)},N.toPower=N.pow=function(e){var t,r,n,i,a,o,s=this,c=s.constructor,u=+(e=new c(e));if(!(s.d&&e.d&&s.d[0]&&e.d[0]))return new c(_(+s,u));if((s=new c(s)).eq(1))return s;if(n=c.precision,a=c.rounding,e.eq(1))return C(s,n,a);if((t=v(e.e/O))>=e.d.length-1&&(r=u<0?-u:u)<=9007199254740991)return i=V(c,s,r,n),e.s<0?new c(1).div(i):C(i,n,a);if((o=s.s)<0){if(t<e.d.length-1)return new c(NaN);if(0==(1&e.d[t])&&(o=1),0==s.e&&1==s.d[0]&&1==s.d.length)return s.s=o,s}return(t=0!=(r=_(+s,u))&&isFinite(r)?new c(r+"").e:v(u*(Math.log("0."+R(s.d))/Math.LN10+s.e+1)))>c.maxE+1||t<c.minE-1?new c(t>0?o/0:0):(p=!1,c.rounding=s.s=1,r=Math.min(12,(t+"").length),(i=G(e.times(Q(s,n+r)),n)).d&&P((i=C(i,n+5,1)).d,n,a)&&(t=n+10,+R((i=C(G(e.times(Q(s,t+r)),t),t+5,1)).d).slice(n+1,n+15)+1==1e14&&(i=C(i,n+1,0))),i.s=o,p=!0,c.rounding=a,C(i,n,a))},N.toPrecision=function(e,t){var r,n=this,i=n.constructor;return void 0===e?r=M(n,n.e<=i.toExpNeg||n.e>=i.toExpPos):(k(e,1,u),void 0===t?t=i.rounding:k(t,0,8),r=M(n=C(new i(n),e,t),e<=n.e||n.e<=i.toExpNeg,e)),n.isNeg()&&!n.isZero()?"-"+r:r},N.toSignificantDigits=N.toSD=function(e,t){var r=this.constructor;return void 0===e?(e=r.precision,t=r.rounding):(k(e,1,u),void 0===t?t=r.rounding:k(t,0,8)),C(new r(this),e,t)},N.toString=function(){var e=this,t=e.constructor,r=M(e,e.e<=t.toExpNeg||e.e>=t.toExpPos);return e.isNeg()&&!e.isZero()?"-"+r:r},N.truncated=N.trunc=function(){return C(new this.constructor(this),this.e+1,1)},N.valueOf=N.toJSON=function(){var e=this,t=e.constructor,r=M(e,e.e<=t.toExpNeg||e.e>=t.toExpPos);return e.isNeg()?"-"+r:r};var D=function(){function e(e,t,r){var n,i=0,a=e.length;for(e=e.slice();a--;)n=e[a]*t+i,e[a]=n%r|0,i=n/r|0;return i&&e.unshift(i),e}function t(e,t,r,n){var i,a;if(r!=n)a=r>n?1:-1;else for(i=a=0;i<r;i++)if(e[i]!=t[i]){a=e[i]>t[i]?1:-1;break}return a}function r(e,t,r,n){for(var i=0;r--;)e[r]-=i,i=e[r]<t[r]?1:0,e[r]=i*n+e[r]-t[r];for(;!e[0]&&e.length>1;)e.shift()}return function(n,i,a,s,c,u){var l,f,d,h,p,y,m,g,b,_,w,S,E,x,A,I,N,R,k,P,j=n.constructor,D=n.s==i.s?1:-1,M=n.d,L=i.d;if(!(M&&M[0]&&L&&L[0]))return new j(n.s&&i.s&&(M?!L||M[0]!=L[0]:L)?M&&0==M[0]||!L?0*D:D/0:NaN);for(u?(p=1,f=n.e-i.e):(u=T,p=O,f=v(n.e/p)-v(i.e/p)),k=L.length,N=M.length,_=(b=new j(D)).d=[],d=0;L[d]==(M[d]||0);d++);if(L[d]>(M[d]||0)&&f--,null==a?(x=a=j.precision,s=j.rounding):x=c?a+(n.e-i.e)+1:a,x<0)_.push(1),y=!0;else{if(x=x/p+2|0,d=0,1==k){for(h=0,L=L[0],x++;(d<N||h)&&x--;d++)A=h*u+(M[d]||0),_[d]=A/L|0,h=A%L|0;y=h||d<N}else{for((h=u/(L[0]+1)|0)>1&&(L=e(L,h,u),M=e(M,h,u),k=L.length,N=M.length),I=k,S=(w=M.slice(0,k)).length;S<k;)w[S++]=0;(P=L.slice()).unshift(0),R=L[0],L[1]>=u/2&&++R;do{h=0,(l=t(L,w,k,S))<0?(E=w[0],k!=S&&(E=E*u+(w[1]||0)),(h=E/R|0)>1?(h>=u&&(h=u-1),1==(l=t(m=e(L,h,u),w,g=m.length,S=w.length))&&(h--,r(m,k<g?P:L,g,u))):(0==h&&(l=h=1),m=L.slice()),(g=m.length)<S&&m.unshift(0),r(w,m,S,u),-1==l&&(l=t(L,w,k,S=w.length))<1&&(h++,r(w,k<S?P:L,S,u)),S=w.length):0===l&&(h++,w=[0]),_[d++]=h,l&&w[0]?w[S++]=M[I]||0:(w=[M[I]],S=1)}while((I++<N||void 0!==w[0])&&x--);y=void 0!==w[0]}_[0]||_.shift()}if(1==p)b.e=f,o=y;else{for(d=1,h=_[0];h>=10;h/=10)d++;b.e=d+f*p-1,C(b,c?a+b.e+1:a,s,y)}return b}}();function C(e,t,r,n){var i,a,o,s,c,u,l,f,d,h=e.constructor;e:if(null!=t){if(!(f=e.d))return e;for(i=1,s=f[0];s>=10;s/=10)i++;if((a=t-i)<0)a+=O,o=t,c=(l=f[d=0])/_(10,i-o-1)%10|0;else if((d=Math.ceil((a+1)/O))>=(s=f.length)){if(!n)break e;for(;s++<=d;)f.push(0);l=c=0,i=1,o=(a%=O)-O+1}else{for(l=s=f[d],i=1;s>=10;s/=10)i++;c=(o=(a%=O)-O+i)<0?0:l/_(10,i-o-1)%10|0}if(n=n||t<0||void 0!==f[d+1]||(o<0?l:l%_(10,i-o-1)),u=r<4?(c||n)&&(0==r||r==(e.s<0?3:2)):c>5||5==c&&(4==r||n||6==r&&(a>0?o>0?l/_(10,i-o):0:f[d-1])%10&1||r==(e.s<0?8:7)),t<1||!f[0])return f.length=0,u?(t-=e.e+1,f[0]=_(10,(O-t%O)%O),e.e=-t||0):f[0]=e.e=0,e;if(0==a?(f.length=d,s=1,d--):(f.length=d+1,s=_(10,O-a),f[d]=o>0?(l/_(10,i-o)%_(10,o)|0)*s:0),u)for(;;){if(0==d){for(a=1,o=f[0];o>=10;o/=10)a++;for(o=f[0]+=s,s=1;o>=10;o/=10)s++;a!=s&&(e.e++,f[0]==T&&(f[0]=1));break}if(f[d]+=s,f[d]!=T)break;f[d--]=0,s=1}for(a=f.length;0===f[--a];)f.pop()}return p&&(e.e>h.maxE?(e.d=null,e.e=NaN):e.e<h.minE&&(e.e=0,e.d=[0])),e}function M(e,t,r){if(!e.isFinite())return X(e);var n,i=e.e,a=R(e.d),o=a.length;return t?(r&&(n=r-o)>0?a=a.charAt(0)+"."+a.slice(1)+U(n):o>1&&(a=a.charAt(0)+"."+a.slice(1)),a=a+(e.e<0?"e":"e+")+e.e):i<0?(a="0."+U(-i-1)+a,r&&(n=r-o)>0&&(a+=U(n))):i>=o?(a+=U(i+1-o),r&&(n=r-i-1)>0&&(a=a+"."+U(n))):((n=i+1)<o&&(a=a.slice(0,n)+"."+a.slice(n)),r&&(n=r-o)>0&&(i+1===o&&(a+="."),a+=U(n))),a}function L(e,t){var r=e[0];for(t*=O;r>=10;r/=10)t++;return t}function q(e,t,r){if(t>A)throw p=!0,r&&(e.precision=r),Error(g);return C(new e(f),t,1,!0)}function F(e,t,r){if(t>I)throw Error(g);return C(new e(d),t,r,!0)}function B(e){var t=e.length-1,r=t*O+1;if(t=e[t]){for(;t%10==0;t/=10)r--;for(t=e[0];t>=10;t/=10)r++}return r}function U(e){for(var t="";e--;)t+="0";return t}function V(e,t,r,n){var i,a=new e(1),o=Math.ceil(n/O+4);for(p=!1;;){if(r%2&&ee((a=a.times(t)).d,o)&&(i=!0),0===(r=v(r/2))){r=a.d.length-1,i&&0===a.d[r]&&++a.d[r];break}ee((t=t.times(t)).d,o)}return p=!0,a}function H(e){return 1&e.d[e.d.length-1]}function z(e,t,r){for(var n,i=new e(t[0]),a=0;++a<t.length;){if(!(n=new e(t[a])).s){i=n;break}i[r](n)&&(i=n)}return i}function G(e,t){var r,n,i,a,o,s,c,u=0,l=0,f=0,d=e.constructor,h=d.rounding,y=d.precision;if(!e.d||!e.d[0]||e.e>17)return new d(e.d?e.d[0]?e.s<0?0:1/0:1:e.s?e.s<0?0:e:NaN);for(null==t?(p=!1,c=y):c=t,s=new d(.03125);e.e>-2;)e=e.times(s),f+=5;for(c+=n=Math.log(_(2,f))/Math.LN10*2+5|0,r=a=o=new d(1),d.precision=c;;){if(a=C(a.times(e),c,1),r=r.times(++l),R((s=o.plus(D(a,r,c,1))).d).slice(0,c)===R(o.d).slice(0,c)){for(i=f;i--;)o=C(o.times(o),c,1);if(null!=t)return d.precision=y,o;if(!(u<3&&P(o.d,c-n,h,u)))return C(o,d.precision=y,h,p=!0);d.precision=c+=10,r=a=s=new d(1),l=0,u++}o=s}}function Q(e,t){var r,n,i,a,o,s,c,u,l,f,d,h=1,y=e,m=y.d,g=y.constructor,b=g.rounding,v=g.precision;if(y.s<0||!m||!m[0]||!y.e&&1==m[0]&&1==m.length)return new g(m&&!m[0]?-1/0:1!=y.s?NaN:m?0:y);if(null==t?(p=!1,l=v):l=t,g.precision=l+=10,n=(r=R(m)).charAt(0),!(Math.abs(a=y.e)<15e14))return u=q(g,l+2,v).times(a+""),y=Q(new g(n+"."+r.slice(1)),l-10).plus(u),g.precision=v,null==t?C(y,v,b,p=!0):y;for(;n<7&&1!=n||1==n&&r.charAt(1)>3;)n=(r=R((y=y.times(e)).d)).charAt(0),h++;for(a=y.e,n>1?(y=new g("0."+r),a++):y=new g(n+"."+r.slice(1)),f=y,c=o=y=D(y.minus(1),y.plus(1),l,1),d=C(y.times(y),l,1),i=3;;){if(o=C(o.times(d),l,1),R((u=c.plus(D(o,new g(i),l,1))).d).slice(0,l)===R(c.d).slice(0,l)){if(c=c.times(2),0!==a&&(c=c.plus(q(g,l+2,v).times(a+""))),c=D(c,new g(h),l,1),null!=t)return g.precision=v,c;if(!P(c.d,l-10,b,s))return C(c,g.precision=v,b,p=!0);g.precision=l+=10,u=o=y=D(f.minus(1),f.plus(1),l,1),d=C(y.times(y),l,1),i=s=1}c=u,i+=2}}function X(e){return String(e.s*e.s/0)}function $(e,t){var r,n,i;for((r=t.indexOf("."))>-1&&(t=t.replace(".","")),(n=t.search(/e/i))>0?(r<0&&(r=n),r+=+t.slice(n+1),t=t.substring(0,n)):r<0&&(r=t.length),n=0;48===t.charCodeAt(n);n++);for(i=t.length;48===t.charCodeAt(i-1);--i);if(t=t.slice(n,i)){if(i-=n,e.e=r=r-n-1,e.d=[],n=(r+1)%O,r<0&&(n+=O),n<i){for(n&&e.d.push(+t.slice(0,n)),i-=O;n<i;)e.d.push(+t.slice(n,n+=O));t=t.slice(n),n=O-t.length}else n-=i;for(;n--;)t+="0";e.d.push(+t),p&&(e.e>e.constructor.maxE?(e.d=null,e.e=NaN):e.e<e.constructor.minE&&(e.e=0,e.d=[0]))}else e.e=0,e.d=[0];return e}function J(e,t){var r,n,i,o,s,c,u,l,f;if("Infinity"===t||"NaN"===t)return+t||(e.s=NaN),e.e=NaN,e.d=null,e;if(S.test(t))r=16,t=t.toLowerCase();else if(w.test(t))r=2;else{if(!E.test(t))throw Error(m+t);r=8}for((o=t.search(/p/i))>0?(u=+t.slice(o+1),t=t.substring(2,o)):t=t.slice(2),s=(o=t.indexOf("."))>=0,n=e.constructor,s&&(o=(c=(t=t.replace(".","")).length)-o,i=V(n,new n(r),o,2*o)),o=f=(l=j(t,r,T)).length-1;0===l[o];--o)l.pop();return o<0?new n(0*e.s):(e.e=L(l,f),e.d=l,p=!1,s&&(e=D(e,i,4*c)),u&&(e=e.times(Math.abs(u)<54?_(2,u):a.pow(2,u))),p=!0,e)}function Y(e,t,r,n,i){var a,o,s,c,u=e.precision,l=Math.ceil(u/O);for(p=!1,c=r.times(r),s=new e(n);;){if(o=D(s.times(c),new e(t++*t++),u,1),s=i?n.plus(o):n.minus(o),n=D(o.times(c),new e(t++*t++),u,1),void 0!==(o=s.plus(n)).d[l]){for(a=l;o.d[a]===s.d[a]&&a--;);if(-1==a)break}a=s,s=n,n=o,o=a,0}return p=!0,o.d.length=l+1,o}function K(e,t){for(var r=e;--t;)r*=e;return r}function W(e,t){var r,n=t.s<0,i=F(e,e.precision,1),a=i.times(.5);if((t=t.abs()).lte(a))return s=n?4:1,t;if((r=t.divToInt(i)).isZero())s=n?3:2;else{if((t=t.minus(r.times(i))).lte(a))return s=H(r)?n?2:3:n?4:1,t;s=H(r)?n?1:4:n?3:2}return t.minus(i).abs()}function Z(e,t,r,n){var i,a,s,c,f,d,h,p,y,m=e.constructor,g=void 0!==r;if(g?(k(r,1,u),void 0===n?n=m.rounding:k(n,0,8)):(r=m.precision,n=m.rounding),e.isFinite()){for(g?(i=2,16==t?r=4*r-3:8==t&&(r=3*r-2)):i=t,(s=(h=M(e)).indexOf("."))>=0&&(h=h.replace(".",""),(y=new m(1)).e=h.length-s,y.d=j(M(y),10,i),y.e=y.d.length),a=f=(p=j(h,10,i)).length;0==p[--f];)p.pop();if(p[0]){if(s<0?a--:((e=new m(e)).d=p,e.e=a,p=(e=D(e,y,r,n,0,i)).d,a=e.e,d=o),s=p[r],c=i/2,d=d||void 0!==p[r+1],d=n<4?(void 0!==s||d)&&(0===n||n===(e.s<0?3:2)):s>c||s===c&&(4===n||d||6===n&&1&p[r-1]||n===(e.s<0?8:7)),p.length=r,d)for(;++p[--r]>i-1;)p[r]=0,r||(++a,p.unshift(1));for(f=p.length;!p[f-1];--f);for(s=0,h="";s<f;s++)h+=l.charAt(p[s]);if(g){if(f>1)if(16==t||8==t){for(s=16==t?4:3,--f;f%s;f++)h+="0";for(f=(p=j(h,i,t)).length;!p[f-1];--f);for(s=1,h="1.";s<f;s++)h+=l.charAt(p[s])}else h=h.charAt(0)+"."+h.slice(1);h=h+(a<0?"p":"p+")+a}else if(a<0){for(;++a;)h="0"+h;h="0."+h}else if(++a>f)for(a-=f;a--;)h+="0";else a<f&&(h=h.slice(0,a)+"."+h.slice(a))}else h=g?"0p+0":"0";h=(16==t?"0x":2==t?"0b":8==t?"0o":"")+h}else h=X(e);return e.s<0?"-"+h:h}function ee(e,t){if(e.length>t)return e.length=t,!0}function te(e){return new this(e).abs()}function re(e){return new this(e).acos()}function ne(e){return new this(e).acosh()}function ie(e,t){return new this(e).plus(t)}function ae(e){return new this(e).asin()}function oe(e){return new this(e).asinh()}function se(e){return new this(e).atan()}function ce(e){return new this(e).atanh()}function ue(e,t){e=new this(e),t=new this(t);var r,n=this.precision,i=this.rounding,a=n+4;return e.s&&t.s?e.d||t.d?!t.d||e.isZero()?(r=t.s<0?F(this,n,i):new this(0)).s=e.s:!e.d||t.isZero()?(r=F(this,a,1).times(.5)).s=e.s:t.s<0?(this.precision=a,this.rounding=1,r=this.atan(D(e,t,a,1)),t=F(this,a,1),this.precision=n,this.rounding=i,r=e.s<0?r.minus(t):r.plus(t)):r=this.atan(D(e,t,a,1)):(r=F(this,a,1).times(t.s>0?.25:.75)).s=e.s:r=new this(NaN),r}function le(e){return new this(e).cbrt()}function fe(e){return C(e=new this(e),e.e+1,2)}function de(e){if(!e||"object"!=typeof e)throw Error(y+"Object expected");var t,r,n,i=!0===e.defaults,a=["precision",1,u,"rounding",0,8,"toExpNeg",-c,0,"toExpPos",0,c,"maxE",0,c,"minE",-c,0,"modulo",0,9];for(t=0;t<a.length;t+=3)if(r=a[t],i&&(this[r]=h[r]),void 0!==(n=e[r])){if(!(v(n)===n&&n>=a[t+1]&&n<=a[t+2]))throw Error(m+r+": "+n);this[r]=n}if(r="crypto",i&&(this[r]=h[r]),void 0!==(n=e[r])){if(!0!==n&&!1!==n&&0!==n&&1!==n)throw Error(m+r+": "+n);if(n){if("undefined"==typeof crypto||!crypto||!crypto.getRandomValues&&!crypto.randomBytes)throw Error(b);this[r]=!0}else this[r]=!1}return this}function he(e){return new this(e).cos()}function pe(e){return new this(e).cosh()}function ye(e,t){return new this(e).div(t)}function me(e){return new this(e).exp()}function ge(e){return C(e=new this(e),e.e+1,3)}function be(){var e,t,r=new this(0);for(p=!1,e=0;e<arguments.length;)if((t=new this(arguments[e++])).d)r.d&&(r=r.plus(t.times(t)));else{if(t.s)return p=!0,new this(1/0);r=t}return p=!0,r.sqrt()}function ve(e){return e instanceof a||e&&"[object Decimal]"===e.name||!1}function _e(e){return new this(e).ln()}function we(e,t){return new this(e).log(t)}function Se(e){return new this(e).log(2)}function Ee(e){return new this(e).log(10)}function xe(){return z(this,arguments,"lt")}function Te(){return z(this,arguments,"gt")}function Oe(e,t){return new this(e).mod(t)}function Ae(e,t){return new this(e).mul(t)}function Ie(e,t){return new this(e).pow(t)}function Ne(e){var t,r,n,i,a=0,o=new this(1),s=[];if(void 0===e?e=this.precision:k(e,1,u),n=Math.ceil(e/O),this.crypto)if(crypto.getRandomValues)for(t=crypto.getRandomValues(new Uint32Array(n));a<n;)(i=t[a])>=429e7?t[a]=crypto.getRandomValues(new Uint32Array(1))[0]:s[a++]=i%1e7;else{if(!crypto.randomBytes)throw Error(b);for(t=crypto.randomBytes(n*=4);a<n;)(i=t[a]+(t[a+1]<<8)+(t[a+2]<<16)+((127&t[a+3])<<24))>=214e7?crypto.randomBytes(4).copy(t,a):(s.push(i%1e7),a+=4);a=n/4}else for(;a<n;)s[a++]=1e7*Math.random()|0;for(n=s[--a],e%=O,n&&e&&(i=_(10,O-e),s[a]=(n/i|0)*i);0===s[a];a--)s.pop();if(a<0)r=0,s=[0];else{for(r=-1;0===s[0];r-=O)s.shift();for(n=1,i=s[0];i>=10;i/=10)n++;n<O&&(r-=O-n)}return o.e=r,o.d=s,o}function Re(e){return C(e=new this(e),e.e+1,this.rounding)}function ke(e){return(e=new this(e)).d?e.d[0]?e.s:0*e.s:e.s||NaN}function Pe(e){return new this(e).sin()}function je(e){return new this(e).sinh()}function De(e){return new this(e).sqrt()}function Ce(e,t){return new this(e).sub(t)}function Me(e){return new this(e).tan()}function Le(e){return new this(e).tanh()}function qe(e){return C(e=new this(e),e.e+1,1)}(a=function e(t){var r,n,i;function a(e){var t,r,n,i=this;if(!(i instanceof a))return new a(e);if(i.constructor=a,e instanceof a)return i.s=e.s,void(p?!e.d||e.e>a.maxE?(i.e=NaN,i.d=null):e.e<a.minE?(i.e=0,i.d=[0]):(i.e=e.e,i.d=e.d.slice()):(i.e=e.e,i.d=e.d?e.d.slice():e.d));if("number"==(n=typeof e)){if(0===e)return i.s=1/e<0?-1:1,i.e=0,void(i.d=[0]);if(e<0?(e=-e,i.s=-1):i.s=1,e===~~e&&e<1e7){for(t=0,r=e;r>=10;r/=10)t++;return void(p?t>a.maxE?(i.e=NaN,i.d=null):t<a.minE?(i.e=0,i.d=[0]):(i.e=t,i.d=[e]):(i.e=t,i.d=[e]))}return 0*e!=0?(e||(i.s=NaN),i.e=NaN,void(i.d=null)):$(i,e.toString())}if("string"!==n)throw Error(m+e);return 45===(r=e.charCodeAt(0))?(e=e.slice(1),i.s=-1):(43===r&&(e=e.slice(1)),i.s=1),x.test(e)?$(i,e):J(i,e)}if(a.prototype=N,a.ROUND_UP=0,a.ROUND_DOWN=1,a.ROUND_CEIL=2,a.ROUND_FLOOR=3,a.ROUND_HALF_UP=4,a.ROUND_HALF_DOWN=5,a.ROUND_HALF_EVEN=6,a.ROUND_HALF_CEIL=7,a.ROUND_HALF_FLOOR=8,a.EUCLID=9,a.config=a.set=de,a.clone=e,a.isDecimal=ve,a.abs=te,a.acos=re,a.acosh=ne,a.add=ie,a.asin=ae,a.asinh=oe,a.atan=se,a.atanh=ce,a.atan2=ue,a.cbrt=le,a.ceil=fe,a.cos=he,a.cosh=pe,a.div=ye,a.exp=me,a.floor=ge,a.hypot=be,a.ln=_e,a.log=we,a.log10=Ee,a.log2=Se,a.max=xe,a.min=Te,a.mod=Oe,a.mul=Ae,a.pow=Ie,a.random=Ne,a.round=Re,a.sign=ke,a.sin=Pe,a.sinh=je,a.sqrt=De,a.sub=Ce,a.tan=Me,a.tanh=Le,a.trunc=qe,void 0===t&&(t={}),t&&!0!==t.defaults)for(i=["precision","rounding","toExpNeg","toExpPos","maxE","minE","modulo","crypto"],r=0;r<i.length;)t.hasOwnProperty(n=i[r++])||(t[n]=this[n]);return a.config(t),a}(h)).default=a.Decimal=a,f=new a(f),d=new a(d),void 0===(n=function(){return a}.call(t,r,t,e))||(e.exports=n)}()},function(e,t,r){var n,i,a=r(135),o=r(136),s=0,c=0;e.exports=function(e,t,r){var u=t&&r||0,l=t||[],f=(e=e||{}).node||n,d=void 0!==e.clockseq?e.clockseq:i;if(null==f||null==d){var h=a();null==f&&(f=n=[1|h[0],h[1],h[2],h[3],h[4],h[5]]),null==d&&(d=i=16383&(h[6]<<8|h[7]))}var p=void 0!==e.msecs?e.msecs:(new Date).getTime(),y=void 0!==e.nsecs?e.nsecs:c+1,m=p-s+(y-c)/1e4;if(m<0&&void 0===e.clockseq&&(d=d+1&16383),(m<0||p>s)&&void 0===e.nsecs&&(y=0),y>=1e4)throw new Error("uuid.v1(): Can't create more than 10M uuids/sec");s=p,c=y,i=d;var g=(1e4*(268435455&(p+=122192928e5))+y)%4294967296;l[u++]=g>>>24&255,l[u++]=g>>>16&255,l[u++]=g>>>8&255,l[u++]=255&g;var b=p/4294967296*1e4&268435455;l[u++]=b>>>8&255,l[u++]=255&b,l[u++]=b>>>24&15|16,l[u++]=b>>>16&255,l[u++]=d>>>8|128,l[u++]=255&d;for(var v=0;v<6;++v)l[u+v]=f[v];return t||o(l)}},function(e,t,r){"use strict";function n(e){return"*"===e}function i(e,t){return new RegExp(`/${e}/`,"i").test(`/${t}/`)}Object.defineProperty(t,"__esModule",{value:!0}),t.matches=function(e,t,r){return new RegExp(t,r).test(e)},t.replace=function(e,t,r,n){let i=new RegExp(t,n);if(!i.global){i=new RegExp(t,(n||"")+"g")}return e.replace(i,r)},t.langMatches=function(e,t){const r=e.split("-"),a=t.split("-");if(!i(a[0],r[0])&&!n(r[0]))return!1;let o=1,s=1;for(;s<a.length;)if(n(a[s]))s++;else{if(o===r.length)return!1;if(i(a[s],r[o]))o++,s++;else{if(1===r[o].length)return!1;o++}}return!0},t.formatDayTimeDuration=function(e){if(e){if("Z"===e[0])return"PT0S";{const[t,r,n,i,a,o]=e,s="0"!==r?r:"",c=s||"0"!==n?n:"",u="0"!==a?a:"",l=u||"0"!==o?o:"";return`${"-"===t?"-":""}PT${`${s+c?s+c+"H":""}${u+l?u+l+"M":""}`}`}}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(25),i=r(683),a=r(280),o=r(47),s=r(18),c=r(22),u=r(84),l=r(112);function f({args:e,mapping:t}){const r=e[0];if(r.expressionType!==o.ExpressionType.Variable)throw new c.InvalidArgumentTypes(e,s.SpecialOperator.BOUND);const n=t.has(r.name)&&!!t.get(r.name);return u.bool(n)}function d(e){return e.length>0&&e.every(t=>t.language===e[0].language)}const h={arity:1,applyAsync:async({args:e,evaluate:t,mapping:r,context:n})=>p(await t(e[0],r),n.baseIRI,e),applySync:({args:e,evaluate:t,mapping:r,context:n})=>p(t(e[0],r),n.baseIRI,e)};function p(e,t,r){const n="namedNode"!==e.termType?u.typeCheckLit(e,["string"],r,s.SpecialOperator.IRI):e,a=i.resolve(t||"",n.str());return new o.NamedNode(a)}function y(e){return new o.BlankNode("blank_"+a.v4())}const m={bound:{arity:1,applyAsync:async({args:e,mapping:t})=>f({args:e,mapping:t}),applySync:({args:e,mapping:t})=>f({args:e,mapping:t})},if:{arity:3,async applyAsync({args:e,mapping:t,evaluate:r}){const n=await r(e[0],t);return r(n.coerceEBV()?e[1]:e[2],t)},applySync({args:e,mapping:t,evaluate:r}){const n=r(e[0],t);return r(n.coerceEBV()?e[1]:e[2],t)}},coalesce:{arity:1/0,async applyAsync({args:e,mapping:t,evaluate:r}){const n=[];for(const i of e)try{return await r(i,t)}catch(e){n.push(e)}throw new c.CoalesceError(n)},applySync({args:e,mapping:t,evaluate:r}){const n=[];for(const i of e)try{return r(i,t)}catch(e){n.push(e)}throw new c.CoalesceError(n)}},"&&":{arity:2,async applyAsync({args:e,mapping:t,evaluate:r}){const[n,i]=e;try{if(!(await r(n,t)).coerceEBV())return u.bool(!1);const e=(await r(i,t)).coerceEBV();return u.bool(e)}catch(e){if((await r(i,t)).coerceEBV())throw e;return u.bool(!1)}},applySync({args:e,mapping:t,evaluate:r}){const[n,i]=e;try{if(!r(n,t).coerceEBV())return u.bool(!1);const e=r(i,t).coerceEBV();return u.bool(e)}catch(e){if(r(i,t).coerceEBV())throw e;return u.bool(!1)}}},"||":{arity:2,async applyAsync({args:e,mapping:t,evaluate:r}){const[n,i]=e;try{if((await r(n,t)).coerceEBV())return u.bool(!0);const e=(await r(i,t)).coerceEBV();return u.bool(e)}catch(e){if(!(await r(i,t)).coerceEBV())throw e;return u.bool(!0)}},applySync({args:e,mapping:t,evaluate:r}){const[n,i]=e;try{if(r(n,t).coerceEBV())return u.bool(!0);const e=r(i,t).coerceEBV();return u.bool(e)}catch(e){if(!r(i,t).coerceEBV())throw e;return u.bool(!0)}}},sameterm:{arity:2,async applyAsync({args:e,mapping:t,evaluate:r}){const[n,i]=e.map(e=>r(e,t)),a=await n,o=await i;return u.bool(a.toRDF().equals(o.toRDF()))},applySync({args:e,mapping:t,evaluate:r}){const[n,i]=e.map(e=>r(e,t));return u.bool(n.toRDF().equals(i.toRDF()))}},in:{arity:1/0,checkArity:e=>e.length>=1,async applyAsync({args:e,mapping:t,evaluate:r,context:n}){const[i,...a]=e;return async function e(t,{args:r,mapping:n,evaluate:i,context:a},o){if(0===r.length){const e=o.every(e=>!e);return e?u.bool(!1):Promise.reject(new c.InError(o))}try{const c=await i(r.shift(),n),f=l.regularFunctions.get(s.RegularOperator.EQUAL);return!0===f.apply([t,c]).typedValue?u.bool(!0):e(t,{args:r,mapping:n,evaluate:i,context:a},[...o,!1])}catch(s){return e(t,{args:r,mapping:n,evaluate:i,context:a},[...o,s])}}(await r(i,t),{args:a,mapping:t,evaluate:r,context:n},[])},applySync({args:e,mapping:t,evaluate:r,context:n}){const[i,...a]=e;return function e(t,{args:r,mapping:n,evaluate:i,context:a},o){if(0===r.length){const e=o.every(e=>!e);if(!e)throw new c.InError(o);u.bool(!1)}try{const c=i(r.shift(),n),f=l.regularFunctions.get(s.RegularOperator.EQUAL);return!0===f.apply([t,c]).typedValue?u.bool(!0):e(t,{args:r,mapping:n,evaluate:i,context:a},[...o,!1])}catch(s){return e(t,{args:r,mapping:n,evaluate:i,context:a},[...o,s])}}(r(i,t),{args:a,mapping:t,evaluate:r,context:n},[])}},notin:{arity:1/0,checkArity:e=>e.length>=1,async applyAsync(e){const t=l.specialFunctions.get(s.SpecialOperator.IN),r=await t.applyAsync(e);return u.bool(!r.typedValue)},applySync(e){const t=l.specialFunctions.get(s.SpecialOperator.IN).applySync(e);return u.bool(!t.typedValue)}},concat:{arity:1/0,async applyAsync({args:e,evaluate:t,mapping:r}){const n=e.map(async e=>t(e,r)).map(async t=>u.typeCheckLit(await t,["string","langString"],e,s.SpecialOperator.CONCAT)),i=await Promise.all(n),a=i.map(e=>e.typedValue).join(""),o=d(i)?i[0].language:void 0;return o?u.langString(a,o):u.string(a)},applySync({args:e,evaluate:t,mapping:r}){const n=e.map(e=>t(e,r)).map(t=>u.typeCheckLit(t,["string","langString"],e,s.SpecialOperator.CONCAT)),i=n.map(e=>e.typedValue).join(""),a=d(n)?n[0].language:void 0;return a?u.langString(i,a):u.string(i)}},now:{arity:0,applyAsync:async({context:e})=>new o.DateTimeLiteral(e.now,e.now.toUTCString()),applySync:({context:e})=>new o.DateTimeLiteral(e.now,e.now.toUTCString())},iri:h,uri:h,BNODE:{arity:1/0,checkArity:e=>0===e.length||1===e.length,async applyAsync({args:e,evaluate:t,mapping:r,context:n}){const i=1===e.length?await t(e[0],r):void 0,a=i?u.typeCheckLit(i,["string"],e,s.SpecialOperator.BNODE).str():void 0;if(n.bnode){const e=await n.bnode(a);return new o.BlankNode(e.value)}return y(a)},applySync({args:e,evaluate:t,mapping:r,context:n}){const i=1===e.length?t(e[0],r):void 0,a=i?u.typeCheckLit(i,["string"],e,s.SpecialOperator.BNODE).str():void 0;if(n.bnode){const e=n.bnode(a);return new o.BlankNode(e.value)}return y(a)}}};t.specialDefinitions=n.Map(m)},function(e,t,r){
105/** @license URI.js v4.2.1 (c) 2011 Gary Court. License: http://github.com/garycourt/uri-js */
106!function(e){"use strict";function t(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];if(t.length>1){t[0]=t[0].slice(0,-1);for(var n=t.length-1,i=1;i<n;++i)t[i]=t[i].slice(1,-1);return t[n]=t[n].slice(1),t.join("")}return t[0]}function r(e){return"(?:"+e+")"}function n(e){return void 0===e?"undefined":null===e?"null":Object.prototype.toString.call(e).split(" ").pop().split("]").shift().toLowerCase()}function i(e){return e.toUpperCase()}function a(e){var n=t("[0-9]","[A-Fa-f]"),i=r(r("%[EFef]"+n+"%"+n+n+"%"+n+n)+"|"+r("%[89A-Fa-f]"+n+"%"+n+n)+"|"+r("%"+n+n)),a="[\\!\\$\\&\\'\\(\\)\\*\\+\\,\\;\\=]",o=t("[\\:\\/\\?\\#\\[\\]\\@]",a),s=e?"[\\uE000-\\uF8FF]":"[]",c=t("[A-Za-z]","[0-9]","[\\-\\.\\_\\~]",e?"[\\xA0-\\u200D\\u2010-\\u2029\\u202F-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF]":"[]"),u=r("[A-Za-z]"+t("[A-Za-z]","[0-9]","[\\+\\-\\.]")+"*"),l=r(r(i+"|"+t(c,a,"[\\:]"))+"*"),f=(r(r("25[0-5]")+"|"+r("2[0-4][0-9]")+"|"+r("1[0-9][0-9]")+"|"+r("[1-9][0-9]")+"|[0-9]"),r(r("25[0-5]")+"|"+r("2[0-4][0-9]")+"|"+r("1[0-9][0-9]")+"|"+r("0?[1-9][0-9]")+"|0?0?[0-9]")),d=r(f+"\\."+f+"\\."+f+"\\."+f),h=r(n+"{1,4}"),p=r(r(h+"\\:"+h)+"|"+d),y=r(r(h+"\\:")+"{6}"+p),m=r("\\:\\:"+r(h+"\\:")+"{5}"+p),g=r(r(h)+"?\\:\\:"+r(h+"\\:")+"{4}"+p),b=r(r(r(h+"\\:")+"{0,1}"+h)+"?\\:\\:"+r(h+"\\:")+"{3}"+p),v=r(r(r(h+"\\:")+"{0,2}"+h)+"?\\:\\:"+r(h+"\\:")+"{2}"+p),_=r(r(r(h+"\\:")+"{0,3}"+h)+"?\\:\\:"+h+"\\:"+p),w=r(r(r(h+"\\:")+"{0,4}"+h)+"?\\:\\:"+p),S=r(r(r(h+"\\:")+"{0,5}"+h)+"?\\:\\:"+h),E=r(r(r(h+"\\:")+"{0,6}"+h)+"?\\:\\:"),x=r([y,m,g,b,v,_,w,S,E].join("|")),T=r(r(c+"|"+i)+"+"),O=(r(x+"\\%25"+T),r(x+r("\\%25|\\%(?!"+n+"{2})")+T)),A=r("[vV]"+n+"+\\."+t(c,a,"[\\:]")+"+"),I=r("\\["+r(O+"|"+x+"|"+A)+"\\]"),N=r(r(i+"|"+t(c,a))+"*"),R=r(I+"|"+d+"(?!"+N+")|"+N),k=r("[0-9]*"),P=r(r(l+"@")+"?"+R+r("\\:"+k)+"?"),j=r(i+"|"+t(c,a,"[\\:\\@]")),D=r(j+"*"),C=r(j+"+"),M=r(r(i+"|"+t(c,a,"[\\@]"))+"+"),L=r(r("\\/"+D)+"*"),q=r("\\/"+r(C+L)+"?"),F=r(M+L),B=r(C+L),U="(?!"+j+")",V=(r(L+"|"+q+"|"+F+"|"+B+"|"+U),r(r(j+"|"+t("[\\/\\?]",s))+"*")),H=r(r(j+"|[\\/\\?]")+"*"),z=r(r("\\/\\/"+P+L)+"|"+q+"|"+B+"|"+U),G=r(u+"\\:"+z+r("\\?"+V)+"?"+r("\\#"+H)+"?"),Q=r(r("\\/\\/"+P+L)+"|"+q+"|"+F+"|"+U),X=r(Q+r("\\?"+V)+"?"+r("\\#"+H)+"?");return r(G+"|"+X),r(u+"\\:"+z+r("\\?"+V)+"?"),r(r("\\/\\/("+r("("+l+")@")+"?("+R+")"+r("\\:("+k+")")+"?)")+"?("+L+"|"+q+"|"+B+"|"+U+")"),r("\\?("+V+")"),r("\\#("+H+")"),r(r("\\/\\/("+r("("+l+")@")+"?("+R+")"+r("\\:("+k+")")+"?)")+"?("+L+"|"+q+"|"+F+"|"+U+")"),r("\\?("+V+")"),r("\\#("+H+")"),r(r("\\/\\/("+r("("+l+")@")+"?("+R+")"+r("\\:("+k+")")+"?)")+"?("+L+"|"+q+"|"+B+"|"+U+")"),r("\\?("+V+")"),r("\\#("+H+")"),r("("+l+")@"),r("\\:("+k+")"),{NOT_SCHEME:new RegExp(t("[^]","[A-Za-z]","[0-9]","[\\+\\-\\.]"),"g"),NOT_USERINFO:new RegExp(t("[^\\%\\:]",c,a),"g"),NOT_HOST:new RegExp(t("[^\\%\\[\\]\\:]",c,a),"g"),NOT_PATH:new RegExp(t("[^\\%\\/\\:\\@]",c,a),"g"),NOT_PATH_NOSCHEME:new RegExp(t("[^\\%\\/\\@]",c,a),"g"),NOT_QUERY:new RegExp(t("[^\\%]",c,a,"[\\:\\@\\/\\?]",s),"g"),NOT_FRAGMENT:new RegExp(t("[^\\%]",c,a,"[\\:\\@\\/\\?]"),"g"),ESCAPE:new RegExp(t("[^]",c,a),"g"),UNRESERVED:new RegExp(c,"g"),OTHER_CHARS:new RegExp(t("[^\\%]",c,o),"g"),PCT_ENCODED:new RegExp(i,"g"),IPV4ADDRESS:new RegExp("^("+d+")$"),IPV6ADDRESS:new RegExp("^\\[?("+x+")"+r(r("\\%25|\\%(?!"+n+"{2})")+"("+T+")")+"?\\]?$")}}var o=a(!1),s=a(!0),c=function(e,t){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return function(e,t){var r=[],n=!0,i=!1,a=void 0;try{for(var o,s=e[Symbol.iterator]();!(n=(o=s.next()).done)&&(r.push(o.value),!t||r.length!==t);n=!0);}catch(e){i=!0,a=e}finally{try{!n&&s.return&&s.return()}finally{if(i)throw a}}return r}(e,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")},u=2147483647,l=/^xn--/,f=/[^\0-\x7E]/,d=/[\x2E\u3002\uFF0E\uFF61]/g,h={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},p=Math.floor,y=String.fromCharCode;function m(e){throw new RangeError(h[e])}function g(e,t){var r=e.split("@"),n="";r.length>1&&(n=r[0]+"@",e=r[1]);var i=function(e,t){for(var r=[],n=e.length;n--;)r[n]=t(e[n]);return r}((e=e.replace(d,".")).split("."),t).join(".");return n+i}function b(e){for(var t=[],r=0,n=e.length;r<n;){var i=e.charCodeAt(r++);if(i>=55296&&i<=56319&&r<n){var a=e.charCodeAt(r++);56320==(64512&a)?t.push(((1023&i)<<10)+(1023&a)+65536):(t.push(i),r--)}else t.push(i)}return t}var v=function(e,t){return e+22+75*(e<26)-((0!=t)<<5)},_=function(e,t,r){var n=0;for(e=r?p(e/700):e>>1,e+=p(e/t);e>455;n+=36)e=p(e/35);return p(n+36*e/(e+38))},w=function(e){var t,r=[],n=e.length,i=0,a=128,o=72,s=e.lastIndexOf("-");s<0&&(s=0);for(var c=0;c<s;++c)e.charCodeAt(c)>=128&&m("not-basic"),r.push(e.charCodeAt(c));for(var l=s>0?s+1:0;l<n;){for(var f=i,d=1,h=36;;h+=36){l>=n&&m("invalid-input");var y=(t=e.charCodeAt(l++))-48<10?t-22:t-65<26?t-65:t-97<26?t-97:36;(y>=36||y>p((u-i)/d))&&m("overflow"),i+=y*d;var g=h<=o?1:h>=o+26?26:h-o;if(y<g)break;var b=36-g;d>p(u/b)&&m("overflow"),d*=b}var v=r.length+1;o=_(i-f,v,0==f),p(i/v)>u-a&&m("overflow"),a+=p(i/v),i%=v,r.splice(i++,0,a)}return String.fromCodePoint.apply(String,r)},S=function(e){var t=[],r=(e=b(e)).length,n=128,i=0,a=72,o=!0,s=!1,c=void 0;try{for(var l,f=e[Symbol.iterator]();!(o=(l=f.next()).done);o=!0){var d=l.value;d<128&&t.push(y(d))}}catch(e){s=!0,c=e}finally{try{!o&&f.return&&f.return()}finally{if(s)throw c}}var h=t.length,g=h;for(h&&t.push("-");g<r;){var w=u,S=!0,E=!1,x=void 0;try{for(var T,O=e[Symbol.iterator]();!(S=(T=O.next()).done);S=!0){var A=T.value;A>=n&&A<w&&(w=A)}}catch(e){E=!0,x=e}finally{try{!S&&O.return&&O.return()}finally{if(E)throw x}}var I=g+1;w-n>p((u-i)/I)&&m("overflow"),i+=(w-n)*I,n=w;var N=!0,R=!1,k=void 0;try{for(var P,j=e[Symbol.iterator]();!(N=(P=j.next()).done);N=!0){var D=P.value;if(D<n&&++i>u&&m("overflow"),D==n){for(var C=i,M=36;;M+=36){var L=M<=a?1:M>=a+26?26:M-a;if(C<L)break;var q=C-L,F=36-L;t.push(y(v(L+q%F,0))),C=p(q/F)}t.push(y(v(C,0))),a=_(i,I,g==h),i=0,++g}}}catch(e){R=!0,k=e}finally{try{!N&&j.return&&j.return()}finally{if(R)throw k}}++i,++n}return t.join("")},E={version:"2.1.0",ucs2:{decode:b,encode:function(e){return String.fromCodePoint.apply(String,function(e){if(Array.isArray(e)){for(var t=0,r=Array(e.length);t<e.length;t++)r[t]=e[t];return r}return Array.from(e)}(e))}},decode:w,encode:S,toASCII:function(e){return g(e,function(e){return f.test(e)?"xn--"+S(e):e})},toUnicode:function(e){return g(e,function(e){return l.test(e)?w(e.slice(4).toLowerCase()):e})}},x={};function T(e){var t=e.charCodeAt(0);return t<16?"%0"+t.toString(16).toUpperCase():t<128?"%"+t.toString(16).toUpperCase():t<2048?"%"+(t>>6|192).toString(16).toUpperCase()+"%"+(63&t|128).toString(16).toUpperCase():"%"+(t>>12|224).toString(16).toUpperCase()+"%"+(t>>6&63|128).toString(16).toUpperCase()+"%"+(63&t|128).toString(16).toUpperCase()}function O(e){for(var t="",r=0,n=e.length;r<n;){var i=parseInt(e.substr(r+1,2),16);if(i<128)t+=String.fromCharCode(i),r+=3;else if(i>=194&&i<224){if(n-r>=6){var a=parseInt(e.substr(r+4,2),16);t+=String.fromCharCode((31&i)<<6|63&a)}else t+=e.substr(r,6);r+=6}else if(i>=224){if(n-r>=9){var o=parseInt(e.substr(r+4,2),16),s=parseInt(e.substr(r+7,2),16);t+=String.fromCharCode((15&i)<<12|(63&o)<<6|63&s)}else t+=e.substr(r,9);r+=9}else t+=e.substr(r,3),r+=3}return t}function A(e,t){function r(e){var r=O(e);return r.match(t.UNRESERVED)?r:e}return e.scheme&&(e.scheme=String(e.scheme).replace(t.PCT_ENCODED,r).toLowerCase().replace(t.NOT_SCHEME,"")),void 0!==e.userinfo&&(e.userinfo=String(e.userinfo).replace(t.PCT_ENCODED,r).replace(t.NOT_USERINFO,T).replace(t.PCT_ENCODED,i)),void 0!==e.host&&(e.host=String(e.host).replace(t.PCT_ENCODED,r).toLowerCase().replace(t.NOT_HOST,T).replace(t.PCT_ENCODED,i)),void 0!==e.path&&(e.path=String(e.path).replace(t.PCT_ENCODED,r).replace(e.scheme?t.NOT_PATH:t.NOT_PATH_NOSCHEME,T).replace(t.PCT_ENCODED,i)),void 0!==e.query&&(e.query=String(e.query).replace(t.PCT_ENCODED,r).replace(t.NOT_QUERY,T).replace(t.PCT_ENCODED,i)),void 0!==e.fragment&&(e.fragment=String(e.fragment).replace(t.PCT_ENCODED,r).replace(t.NOT_FRAGMENT,T).replace(t.PCT_ENCODED,i)),e}function I(e){return e.replace(/^0*(.*)/,"$1")||"0"}function N(e,t){var r=e.match(t.IPV4ADDRESS)||[],n=c(r,2)[1];return n?n.split(".").map(I).join("."):e}function R(e,t){var r=e.match(t.IPV6ADDRESS)||[],n=c(r,3),i=n[1],a=n[2];if(i){for(var o=i.toLowerCase().split("::").reverse(),s=c(o,2),u=s[0],l=s[1],f=l?l.split(":").map(I):[],d=u.split(":").map(I),h=t.IPV4ADDRESS.test(d[d.length-1]),p=h?7:8,y=d.length-p,m=Array(p),g=0;g<p;++g)m[g]=f[g]||d[y+g]||"";h&&(m[p-1]=N(m[p-1],t));var b=m.reduce(function(e,t,r){if(!t||"0"===t){var n=e[e.length-1];n&&n.index+n.length===r?n.length++:e.push({index:r,length:1})}return e},[]).sort(function(e,t){return t.length-e.length})[0],v=void 0;if(b&&b.length>1){var _=m.slice(0,b.index),w=m.slice(b.index+b.length);v=_.join(":")+"::"+w.join(":")}else v=m.join(":");return a&&(v+="%"+a),v}return e}var k=/^(?:([^:\/?#]+):)?(?:\/\/((?:([^\/?#@]*)@)?(\[[^\/?#\]]+\]|[^\/?#:]*)(?:\:(\d*))?))?([^?#]*)(?:\?([^#]*))?(?:#((?:.|\n|\r)*))?/i,P=void 0==="".match(/(){0}/)[1];function j(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r={},n=!1!==t.iri?s:o;"suffix"===t.reference&&(e=(t.scheme?t.scheme+":":"")+"//"+e);var i=e.match(k);if(i){P?(r.scheme=i[1],r.userinfo=i[3],r.host=i[4],r.port=parseInt(i[5],10),r.path=i[6]||"",r.query=i[7],r.fragment=i[8],isNaN(r.port)&&(r.port=i[5])):(r.scheme=i[1]||void 0,r.userinfo=-1!==e.indexOf("@")?i[3]:void 0,r.host=-1!==e.indexOf("//")?i[4]:void 0,r.port=parseInt(i[5],10),r.path=i[6]||"",r.query=-1!==e.indexOf("?")?i[7]:void 0,r.fragment=-1!==e.indexOf("#")?i[8]:void 0,isNaN(r.port)&&(r.port=e.match(/\/\/(?:.|\n)*\:(?:\/|\?|\#|$)/)?i[4]:void 0)),r.host&&(r.host=R(N(r.host,n),n)),void 0!==r.scheme||void 0!==r.userinfo||void 0!==r.host||void 0!==r.port||r.path||void 0!==r.query?void 0===r.scheme?r.reference="relative":void 0===r.fragment?r.reference="absolute":r.reference="uri":r.reference="same-document",t.reference&&"suffix"!==t.reference&&t.reference!==r.reference&&(r.error=r.error||"URI is not a "+t.reference+" reference.");var a=x[(t.scheme||r.scheme||"").toLowerCase()];if(t.unicodeSupport||a&&a.unicodeSupport)A(r,n);else{if(r.host&&(t.domainHost||a&&a.domainHost))try{r.host=E.toASCII(r.host.replace(n.PCT_ENCODED,O).toLowerCase())}catch(e){r.error=r.error||"Host's domain name can not be converted to ASCII via punycode: "+e}A(r,o)}a&&a.parse&&a.parse(r,t)}else r.error=r.error||"URI can not be parsed.";return r}var D=/^\.\.?\//,C=/^\/\.(\/|$)/,M=/^\/\.\.(\/|$)/,L=/^\/?(?:.|\n)*?(?=\/|$)/;function q(e){for(var t=[];e.length;)if(e.match(D))e=e.replace(D,"");else if(e.match(C))e=e.replace(C,"/");else if(e.match(M))e=e.replace(M,"/"),t.pop();else if("."===e||".."===e)e="";else{var r=e.match(L);if(!r)throw new Error("Unexpected dot segment condition");var n=r[0];e=e.slice(n.length),t.push(n)}return t.join("")}function F(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=t.iri?s:o,n=[],i=x[(t.scheme||e.scheme||"").toLowerCase()];if(i&&i.serialize&&i.serialize(e,t),e.host)if(r.IPV6ADDRESS.test(e.host));else if(t.domainHost||i&&i.domainHost)try{e.host=t.iri?E.toUnicode(e.host):E.toASCII(e.host.replace(r.PCT_ENCODED,O).toLowerCase())}catch(r){e.error=e.error||"Host's domain name can not be converted to "+(t.iri?"Unicode":"ASCII")+" via punycode: "+r}A(e,r),"suffix"!==t.reference&&e.scheme&&(n.push(e.scheme),n.push(":"));var a=function(e,t){var r=!1!==t.iri?s:o,n=[];return void 0!==e.userinfo&&(n.push(e.userinfo),n.push("@")),void 0!==e.host&&n.push(R(N(String(e.host),r),r).replace(r.IPV6ADDRESS,function(e,t,r){return"["+t+(r?"%25"+r:"")+"]"})),"number"==typeof e.port&&(n.push(":"),n.push(e.port.toString(10))),n.length?n.join(""):void 0}(e,t);if(void 0!==a&&("suffix"!==t.reference&&n.push("//"),n.push(a),e.path&&"/"!==e.path.charAt(0)&&n.push("/")),void 0!==e.path){var c=e.path;t.absolutePath||i&&i.absolutePath||(c=q(c)),void 0===a&&(c=c.replace(/^\/\//,"/%2F")),n.push(c)}return void 0!==e.query&&(n.push("?"),n.push(e.query)),void 0!==e.fragment&&(n.push("#"),n.push(e.fragment)),n.join("")}function B(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},n={};return arguments[3]||(e=j(F(e,r),r),t=j(F(t,r),r)),!(r=r||{}).tolerant&&t.scheme?(n.scheme=t.scheme,n.userinfo=t.userinfo,n.host=t.host,n.port=t.port,n.path=q(t.path||""),n.query=t.query):(void 0!==t.userinfo||void 0!==t.host||void 0!==t.port?(n.userinfo=t.userinfo,n.host=t.host,n.port=t.port,n.path=q(t.path||""),n.query=t.query):(t.path?("/"===t.path.charAt(0)?n.path=q(t.path):(void 0===e.userinfo&&void 0===e.host&&void 0===e.port||e.path?e.path?n.path=e.path.slice(0,e.path.lastIndexOf("/")+1)+t.path:n.path=t.path:n.path="/"+t.path,n.path=q(n.path)),n.query=t.query):(n.path=e.path,void 0!==t.query?n.query=t.query:n.query=e.query),n.userinfo=e.userinfo,n.host=e.host,n.port=e.port),n.scheme=e.scheme),n.fragment=t.fragment,n}function U(e,t){return e&&e.toString().replace(t&&t.iri?s.PCT_ENCODED:o.PCT_ENCODED,O)}var V={scheme:"http",domainHost:!0,parse:function(e,t){return e.host||(e.error=e.error||"HTTP URIs must have a host."),e},serialize:function(e,t){return e.port!==("https"!==String(e.scheme).toLowerCase()?80:443)&&""!==e.port||(e.port=void 0),e.path||(e.path="/"),e}},H={scheme:"https",domainHost:V.domainHost,parse:V.parse,serialize:V.serialize},z={},G="[A-Za-z0-9\\-\\.\\_\\~\\xA0-\\u200D\\u2010-\\u2029\\u202F-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF]",Q="[0-9A-Fa-f]",X=r(r("%[EFef][0-9A-Fa-f]%"+Q+Q+"%"+Q+Q)+"|"+r("%[89A-Fa-f][0-9A-Fa-f]%"+Q+Q)+"|"+r("%"+Q+Q)),$=t("[\\!\\$\\%\\'\\(\\)\\*\\+\\,\\-\\.0-9\\<\\>A-Z\\x5E-\\x7E]",'[\\"\\\\]'),J=new RegExp(G,"g"),Y=new RegExp(X,"g"),K=new RegExp(t("[^]","[A-Za-z0-9\\!\\$\\%\\'\\*\\+\\-\\^\\_\\`\\{\\|\\}\\~]","[\\.]",'[\\"]',$),"g"),W=new RegExp(t("[^]",G,"[\\!\\$\\'\\(\\)\\*\\+\\,\\;\\:\\@]"),"g"),Z=W;function ee(e){var t=O(e);return t.match(J)?t:e}var te={scheme:"mailto",parse:function(e,t){var r=e,n=r.to=r.path?r.path.split(","):[];if(r.path=void 0,r.query){for(var i=!1,a={},o=r.query.split("&"),s=0,c=o.length;s<c;++s){var u=o[s].split("=");switch(u[0]){case"to":for(var l=u[1].split(","),f=0,d=l.length;f<d;++f)n.push(l[f]);break;case"subject":r.subject=U(u[1],t);break;case"body":r.body=U(u[1],t);break;default:i=!0,a[U(u[0],t)]=U(u[1],t)}}i&&(r.headers=a)}r.query=void 0;for(var h=0,p=n.length;h<p;++h){var y=n[h].split("@");if(y[0]=U(y[0]),t.unicodeSupport)y[1]=U(y[1],t).toLowerCase();else try{y[1]=E.toASCII(U(y[1],t).toLowerCase())}catch(e){r.error=r.error||"Email address's domain name can not be converted to ASCII via punycode: "+e}n[h]=y.join("@")}return r},serialize:function(e,t){var r,n=e,a=null!=(r=e.to)?r instanceof Array?r:"number"!=typeof r.length||r.split||r.setInterval||r.call?[r]:Array.prototype.slice.call(r):[];if(a){for(var o=0,s=a.length;o<s;++o){var c=String(a[o]),u=c.lastIndexOf("@"),l=c.slice(0,u).replace(Y,ee).replace(Y,i).replace(K,T),f=c.slice(u+1);try{f=t.iri?E.toUnicode(f):E.toASCII(U(f,t).toLowerCase())}catch(e){n.error=n.error||"Email address's domain name can not be converted to "+(t.iri?"Unicode":"ASCII")+" via punycode: "+e}a[o]=l+"@"+f}n.path=a.join(",")}var d=e.headers=e.headers||{};e.subject&&(d.subject=e.subject),e.body&&(d.body=e.body);var h=[];for(var p in d)d[p]!==z[p]&&h.push(p.replace(Y,ee).replace(Y,i).replace(W,T)+"="+d[p].replace(Y,ee).replace(Y,i).replace(Z,T));return h.length&&(n.query=h.join("&")),n}},re=/^([^\:]+)\:(.*)/,ne={scheme:"urn",parse:function(e,t){var r=e.path&&e.path.match(re),n=e;if(r){var i=t.scheme||n.scheme||"urn",a=r[1].toLowerCase(),o=r[2],s=i+":"+(t.nid||a),c=x[s];n.nid=a,n.nss=o,n.path=void 0,c&&(n=c.parse(n,t))}else n.error=n.error||"URN can not be parsed.";return n},serialize:function(e,t){var r=t.scheme||e.scheme||"urn",n=e.nid,i=r+":"+(t.nid||n),a=x[i];a&&(e=a.serialize(e,t));var o=e,s=e.nss;return o.path=(n||t.nid)+":"+s,o}},ie=/^[0-9A-Fa-f]{8}(?:\-[0-9A-Fa-f]{4}){3}\-[0-9A-Fa-f]{12}$/,ae={scheme:"urn:uuid",parse:function(e,t){var r=e;return r.uuid=r.nss,r.nss=void 0,t.tolerant||r.uuid&&r.uuid.match(ie)||(r.error=r.error||"UUID is not valid."),r},serialize:function(e,t){var r=e;return r.nss=(e.uuid||"").toLowerCase(),r}};x[V.scheme]=V,x[H.scheme]=H,x[te.scheme]=te,x[ne.scheme]=ne,x[ae.scheme]=ae,e.SCHEMES=x,e.pctEncChar=T,e.pctDecChars=O,e.parse=j,e.removeDotSegments=q,e.serialize=F,e.resolveComponents=B,e.resolve=function(e,t,r){var n=function(e,t){var r=e;if(t)for(var n in t)r[n]=t[n];return r}({scheme:"null"},r);return F(B(j(e,n),j(t,n),n,!0),n)},e.normalize=function(e,t){return"string"==typeof e?e=F(j(e,t),t):"object"===n(e)&&(e=j(F(e,t),t)),e},e.equal=function(e,t,r){return"string"==typeof e?e=F(j(e,r),r):"object"===n(e)&&(e=F(e,r)),"string"==typeof t?t=F(j(t,r),r):"object"===n(t)&&(t=F(t,r)),e===t},e.escapeComponent=function(e,t){return e&&e.toString().replace(t&&t.iri?s.ESCAPE:o.ESCAPE,T)},e.unescapeComponent=U,Object.defineProperty(e,"__esModule",{value:!0})}(t)},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(5),i=r(47),a=r(18),o=r(22),s=r(112),c=r(84),u=r(83),l=r(18),f=r(282);t.AggregateEvaluator=class{constructor(e,r,n){this.throwError=!1,this.expression=e,this.evaluator=new f.SyncEvaluator(e.expression,r),this.aggregator=new t.aggregators[e.aggregator](e),this.throwError=n}static emptyValue(e,r=!1){const n=t.aggregators[e.aggregator].emptyValue();if(void 0===n&&r)throw new o.EmptyAggregateError;return n}put(e){this.init(e),this.state&&(this.put=this.__put,this.result=this.__result)}result(){return this.aggregator.constructor.emptyValue()}__put(e){try{const t=this.evaluator.evaluate(e);this.state=this.aggregator.put(this.state,t)}catch(e){this.safeThrow(e)}}__result(){return this.aggregator.result(this.state)}init(e){try{const t=this.evaluator.evaluate(e);this.state=this.aggregator.init(t)}catch(e){this.safeThrow(e)}}safeThrow(e){if(this.throwError)throw e;this.put=()=>{},this.result=()=>void 0}};class d{constructor(e){this.distinct=e.distinct,this.separator=e.separator||" "}static emptyValue(){}}function h(e){if("Literal"!==e.termType||!a.NumericTypeURLs.contains(e.datatype.value))throw new Error("Term is not numeric");return{type:e.datatype.value,value:u.parseXSDFloat(e.value)}}t.aggregators={count:class extends d{static emptyValue(){return c.number(0,l.TypeURL.XSD_INTEGER).toRDF()}init(e){return 1}put(e,t){return e+1}result(e){return c.number(e,l.TypeURL.XSD_INTEGER).toRDF()}},sum:class extends d{constructor(){super(...arguments),this.summer=s.regularFunctions.get(a.RegularOperator.ADDITION)}static emptyValue(){return c.number(0,l.TypeURL.XSD_INTEGER).toRDF()}init(e){const{value:t,type:r}=h(e);return new i.NumericLiteral(t,n.namedNode(r))}put(e,t){const{value:r,type:a}=h(t),o=new i.NumericLiteral(r,n.namedNode(a));return this.summer.apply([e,o])}result(e){return e.toRDF()}},min:class extends d{init(e){const{value:t}=h(e);return{minNum:t,minTerm:e}}put(e,t){const{value:r}=h(t);return r<e.minNum?{minNum:r,minTerm:t}:e}result(e){return e.minTerm}},max:class extends d{init(e){const{value:t}=h(e);return{maxNum:t,maxTerm:e}}put(e,t){const{value:r}=h(t);return r>=e.maxNum?{maxNum:r,maxTerm:t}:e}result(e){return e.maxTerm}},avg:class extends d{constructor(){super(...arguments),this.summer=s.regularFunctions.get(a.RegularOperator.ADDITION),this.divider=s.regularFunctions.get(a.RegularOperator.DIVISION)}static emptyValue(){return c.number(0,l.TypeURL.XSD_INTEGER).toRDF()}init(e){const{value:t,type:r}=h(e);return{sum:new i.NumericLiteral(t,n.namedNode(r)),count:1}}put(e,t){const{value:r,type:a}=h(t),o=new i.NumericLiteral(r,n.namedNode(a));return{sum:this.summer.apply([e.sum,o]),count:e.count+1}}result(e){const t=new i.NumericLiteral(e.count,n.namedNode(a.TypeURL.XSD_INTEGER));return this.divider.apply([e.sum,t]).toRDF()}},group_concat:class extends d{static emptyValue(){return c.string("").toRDF()}init(e){return e.value}put(e,t){return e+this.separator+t.value}result(e){return c.string(e).toRDF()}},sample:class extends d{init(e){return e}put(e,t){return e}result(e){return e}}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(77),i=r(99);t.ActorQueryOperationReducedHash=class extends n.AbstractBindingHash{constructor(e){super(e,"reduced")}newHashFilter(e,t){const r=new i({max:this.cacheSize});return i=>{const a=n.AbstractFilterHash.hash(e,t,i);return!r.has(a)&&r.set(a,!0)}}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(8),i=r(10),a=r(46),o=r(4);t.ActorQueryOperationFilterSparqlee=class extends o.ActorQueryOperationTypedMediated{constructor(e){super(e,"filter")}async testOperation(e,t){const r={exists:this.createExistenceResolver(t)};new a.AsyncEvaluator(e.expression,r);return!0}async runOperation(e,t){const r=await this.mediatorQueryOperation.mediate({operation:e.input,context:t}),n=o.ActorQueryOperation.getSafeBindings(r);o.ActorQueryOperation.validateQueryOutput(n,"bindings");const{variables:i,metadata:s}=n,c=o.ActorQueryOperation.getExpressionContext(t),u=Object.assign({},c,{exists:this.createExistenceResolver(t)}),l=new a.AsyncEvaluator(e.expression,u),f=n.bindingsStream.transform({transform:async(e,t)=>{try{await l.evaluateAsEBV(e)&&f._push(e)}catch(e){a.isExpressionError(e)||f.emit("error",e)}t()}});return{type:"bindings",bindingsStream:f,metadata:s,variables:i}}createExistenceResolver(e){return async(t,r)=>{const n=this.substitute(t.input,r),i=await this.mediatorQueryOperation.mediate({operation:n,context:e}),a=o.ActorQueryOperation.getSafeBindings(i);return new Promise((e,t)=>{a.bindingsStream.on("end",()=>{e(!1)}),a.bindingsStream.on("error",t),a.bindingsStream.on("data",()=>{a.bindingsStream.close(),e(!0)})}).then(e=>t.not?!e:e)}}substitute(e,t){return i.Util.mapOperation(e,{path:(e,r)=>({recurse:!1,result:r.createPath(this.substituteSingle(e.subject,t),e.predicate,this.substituteSingle(e.object,t),this.substituteSingle(e.graph,t))}),pattern:(e,r)=>({recurse:!1,result:r.createPattern(this.substituteSingle(e.subject,t),this.substituteSingle(e.predicate,t),this.substituteSingle(e.object,t),this.substituteSingle(e.graph,t))})})}substituteSingle(e,t){return"Variable"===e.termType?t.get(n.termToString(e),e):e}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(4),i=r(10);class a extends n.ActorQueryOperationTypedMediated{constructor(e){super(e,"from")}static copyOperation(e,t){const r={};for(const n of Object.keys(e))Array.isArray(e[n])?r[n]="variables"===n?e[n]:e[n].map(t):a.ALGEBRA_TYPES.indexOf(e[n].type)>=0?r[n]=t(e[n]):r[n]=e[n];return r}static applyOperationDefaultGraph(e,t){if("bgp"===e.type&&e.patterns.length||"path"===e.type){if("bgp"===e.type)return a.joinOperations(e.patterns.map(e=>{if("DefaultGraph"!==e.graph.termType)return a.FACTORY.createBgp([e]);const r=t.map(t=>a.FACTORY.createBgp([a.FACTORY.createPattern(e.subject,e.predicate,e.object,t)]));return a.unionOperations(r)}));{if("DefaultGraph"!==e.graph.termType)return e;const r=t.map(t=>a.FACTORY.createPath(e.subject,e.predicate,e.object,t));return a.joinOperations(r)}}return a.copyOperation(e,e=>this.applyOperationDefaultGraph(e,t))}static applyOperationNamedGraph(e,t,n){if("bgp"===e.type&&e.patterns.length||"path"===e.type){let i;if("DefaultGraph"===(i="bgp"===e.type?e.patterns[0].graph:e.graph).termType)return{type:"bgp",patterns:[]};if("Variable"===i.termType){if(1===t.length){const r=t[0],n={};n["?"+i.value]=r;const o=a.FACTORY.createValues([i],[n]);let s;return s="bgp"===e.type?a.FACTORY.createBgp(e.patterns.map(e=>a.FACTORY.createPattern(e.subject,e.predicate,e.object,r))):a.FACTORY.createPath(e.subject,e.predicate,e.object,r),a.FACTORY.createJoin(o,s)}return a.unionOperations(t.map(t=>a.applyOperationNamedGraph(e,[t],n)))}return r(688)(t.concat(n),e=>e.equals(i))?e:{type:"bgp",patterns:[]}}return a.copyOperation(e,e=>this.applyOperationNamedGraph(e,t,n))}static joinOperations(e){if(1===e.length)return e[0];if(2===e.length)return a.FACTORY.createJoin(e[0],e[1]);if(e.length>2)return a.FACTORY.createJoin(e.shift(),this.joinOperations(e));throw new Error("A join can only be applied on at least one operation")}static unionOperations(e){if(1===e.length)return e[0];if(2===e.length)return a.FACTORY.createUnion(e[0],e[1]);if(e.length>2)return a.FACTORY.createUnion(e.shift(),this.unionOperations(e));throw new Error("A union can only be applied on at least one operation")}static createOperation(e){let t=e.input;return e.default.length&&(t=a.applyOperationDefaultGraph(t,e.default)),e.named.length&&(t=a.applyOperationNamedGraph(t,e.named,e.default)),t}async testOperation(e,t){return!0}async runOperation(e,t){const r=a.createOperation(e);return this.mediatorQueryOperation.mediate({operation:r,context:t})}}a.FACTORY=new i.Factory,a.ALGEBRA_TYPES=Object.keys(i.Algebra.types).map(e=>i.Algebra.types[e]),t.ActorQueryOperationFromQuad=a},function(e,t,r){(function(e,r){var n=200,i="Expected a function",a="__lodash_hash_undefined__",o=1,s=2,c=1/0,u=9007199254740991,l=17976931348623157e292,f=NaN,d="[object Arguments]",h="[object Array]",p="[object Boolean]",y="[object Date]",m="[object Error]",g="[object Function]",b="[object GeneratorFunction]",v="[object Map]",_="[object Number]",w="[object Object]",S="[object RegExp]",E="[object Set]",x="[object String]",T="[object Symbol]",O="[object ArrayBuffer]",A="[object DataView]",I=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,N=/^\w*$/,R=/^\./,k=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,P=/^\s+|\s+$/g,j=/\\(\\)?/g,D=/^[-+]0x[0-9a-f]+$/i,C=/^0b[01]+$/i,M=/^\[object .+?Constructor\]$/,L=/^0o[0-7]+$/i,q=/^(?:0|[1-9]\d*)$/,F={};F["[object Float32Array]"]=F["[object Float64Array]"]=F["[object Int8Array]"]=F["[object Int16Array]"]=F["[object Int32Array]"]=F["[object Uint8Array]"]=F["[object Uint8ClampedArray]"]=F["[object Uint16Array]"]=F["[object Uint32Array]"]=!0,F[d]=F[h]=F[O]=F[p]=F[A]=F[y]=F[m]=F[g]=F[v]=F[_]=F[w]=F[S]=F[E]=F[x]=F["[object WeakMap]"]=!1;var B=parseInt,U="object"==typeof e&&e&&e.Object===Object&&e,V="object"==typeof self&&self&&self.Object===Object&&self,H=U||V||Function("return this")(),z=t&&!t.nodeType&&t,G=z&&"object"==typeof r&&r&&!r.nodeType&&r,Q=G&&G.exports===z&&U.process,X=function(){try{return Q&&Q.binding("util")}catch(e){}}(),$=X&&X.isTypedArray;function J(e,t){for(var r=-1,n=e?e.length:0;++r<n;)if(t(e[r],r,e))return!0;return!1}function Y(e){var t=!1;if(null!=e&&"function"!=typeof e.toString)try{t=!!(e+"")}catch(e){}return t}function K(e){var t=-1,r=Array(e.size);return e.forEach(function(e,n){r[++t]=[n,e]}),r}function W(e){var t=-1,r=Array(e.size);return e.forEach(function(e){r[++t]=e}),r}var Z,ee,te,re=Array.prototype,ne=Function.prototype,ie=Object.prototype,ae=H["__core-js_shared__"],oe=(Z=/[^.]+$/.exec(ae&&ae.keys&&ae.keys.IE_PROTO||""))?"Symbol(src)_1."+Z:"",se=ne.toString,ce=ie.hasOwnProperty,ue=ie.toString,le=RegExp("^"+se.call(ce).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),fe=H.Symbol,de=H.Uint8Array,he=ie.propertyIsEnumerable,pe=re.splice,ye=(ee=Object.keys,te=Object,function(e){return ee(te(e))}),me=Math.max,ge=Xe(H,"DataView"),be=Xe(H,"Map"),ve=Xe(H,"Promise"),_e=Xe(H,"Set"),we=Xe(H,"WeakMap"),Se=Xe(Object,"create"),Ee=tt(ge),xe=tt(be),Te=tt(ve),Oe=tt(_e),Ae=tt(we),Ie=fe?fe.prototype:void 0,Ne=Ie?Ie.valueOf:void 0,Re=Ie?Ie.toString:void 0;function ke(e){var t=-1,r=e?e.length:0;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}function Pe(e){var t=-1,r=e?e.length:0;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}function je(e){var t=-1,r=e?e.length:0;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}function De(e){var t=-1,r=e?e.length:0;for(this.__data__=new je;++t<r;)this.add(e[t])}function Ce(e){this.__data__=new Pe(e)}function Me(e,t){var r=st(e)||ot(e)?function(e,t){for(var r=-1,n=Array(e);++r<e;)n[r]=t(r);return n}(e.length,String):[],n=r.length,i=!!n;for(var a in e)!t&&!ce.call(e,a)||i&&("length"==a||Je(a,n))||r.push(a);return r}function Le(e,t){for(var r=e.length;r--;)if(at(e[r][0],t))return r;return-1}function qe(e,t){for(var r=0,n=(t=Ye(t,e)?[t]:ze(t)).length;null!=e&&r<n;)e=e[et(t[r++])];return r&&r==n?e:void 0}function Fe(e,t){return null!=e&&t in Object(e)}function Be(e,t,r,n,i){return e===t||(null==e||null==t||!ft(e)&&!dt(t)?e!=e&&t!=t:function(e,t,r,n,i,a){var c=st(e),u=st(t),l=h,f=h;c||(l=(l=$e(e))==d?w:l);u||(f=(f=$e(t))==d?w:f);var g=l==w&&!Y(e),b=f==w&&!Y(t),I=l==f;if(I&&!g)return a||(a=new Ce),c||pt(e)?Ge(e,t,r,n,i,a):function(e,t,r,n,i,a,c){switch(r){case A:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case O:return!(e.byteLength!=t.byteLength||!n(new de(e),new de(t)));case p:case y:case _:return at(+e,+t);case m:return e.name==t.name&&e.message==t.message;case S:case x:return e==t+"";case v:var u=K;case E:var l=a&s;if(u||(u=W),e.size!=t.size&&!l)return!1;var f=c.get(e);if(f)return f==t;a|=o,c.set(e,t);var d=Ge(u(e),u(t),n,i,a,c);return c.delete(e),d;case T:if(Ne)return Ne.call(e)==Ne.call(t)}return!1}(e,t,l,r,n,i,a);if(!(i&s)){var N=g&&ce.call(e,"__wrapped__"),R=b&&ce.call(t,"__wrapped__");if(N||R){var k=N?e.value():e,P=R?t.value():t;return a||(a=new Ce),r(k,P,n,i,a)}}if(!I)return!1;return a||(a=new Ce),function(e,t,r,n,i,a){var o=i&s,c=yt(e),u=c.length,l=yt(t).length;if(u!=l&&!o)return!1;var f=u;for(;f--;){var d=c[f];if(!(o?d in t:ce.call(t,d)))return!1}var h=a.get(e);if(h&&a.get(t))return h==t;var p=!0;a.set(e,t),a.set(t,e);var y=o;for(;++f<u;){d=c[f];var m=e[d],g=t[d];if(n)var b=o?n(g,m,d,t,e,a):n(m,g,d,e,t,a);if(!(void 0===b?m===g||r(m,g,n,i,a):b)){p=!1;break}y||(y="constructor"==d)}if(p&&!y){var v=e.constructor,_=t.constructor;v!=_&&"constructor"in e&&"constructor"in t&&!("function"==typeof v&&v instanceof v&&"function"==typeof _&&_ instanceof _)&&(p=!1)}return a.delete(e),a.delete(t),p}(e,t,r,n,i,a)}(e,t,Be,r,n,i))}function Ue(e){return!(!ft(e)||function(e){return!!oe&&oe in e}(e))&&(ut(e)||Y(e)?le:M).test(tt(e))}function Ve(e){return"function"==typeof e?e:null==e?mt:"object"==typeof e?st(e)?function(e,t){if(Ye(e)&&Ke(t))return We(et(e),t);return function(r){var n=function(e,t,r){var n=null==e?void 0:qe(e,t);return void 0===n?r:n}(r,e);return void 0===n&&n===t?function(e,t){return null!=e&&function(e,t,r){t=Ye(t,e)?[t]:ze(t);var n,i=-1,a=t.length;for(;++i<a;){var o=et(t[i]);if(!(n=null!=e&&r(e,o)))break;e=e[o]}if(n)return n;return!!(a=e?e.length:0)&&lt(a)&&Je(o,a)&&(st(e)||ot(e))}(e,t,Fe)}(r,e):Be(t,n,void 0,o|s)}}(e[0],e[1]):function(e){var t=function(e){var t=yt(e),r=t.length;for(;r--;){var n=t[r],i=e[n];t[r]=[n,i,Ke(i)]}return t}(e);if(1==t.length&&t[0][2])return We(t[0][0],t[0][1]);return function(r){return r===e||function(e,t,r,n){var i=r.length,a=i,c=!n;if(null==e)return!a;for(e=Object(e);i--;){var u=r[i];if(c&&u[2]?u[1]!==e[u[0]]:!(u[0]in e))return!1}for(;++i<a;){var l=(u=r[i])[0],f=e[l],d=u[1];if(c&&u[2]){if(void 0===f&&!(l in e))return!1}else{var h=new Ce;if(n)var p=n(f,d,l,e,t,h);if(!(void 0===p?Be(d,f,n,o|s,h):p))return!1}}return!0}(r,e,t)}}(e):Ye(t=e)?(r=et(t),function(e){return null==e?void 0:e[r]}):function(e){return function(t){return qe(t,e)}}(t);var t,r}function He(e){if(r=(t=e)&&t.constructor,n="function"==typeof r&&r.prototype||ie,t!==n)return ye(e);var t,r,n,i=[];for(var a in Object(e))ce.call(e,a)&&"constructor"!=a&&i.push(a);return i}function ze(e){return st(e)?e:Ze(e)}function Ge(e,t,r,n,i,a){var c=i&s,u=e.length,l=t.length;if(u!=l&&!(c&&l>u))return!1;var f=a.get(e);if(f&&a.get(t))return f==t;var d=-1,h=!0,p=i&o?new De:void 0;for(a.set(e,t),a.set(t,e);++d<u;){var y=e[d],m=t[d];if(n)var g=c?n(m,y,d,t,e,a):n(y,m,d,e,t,a);if(void 0!==g){if(g)continue;h=!1;break}if(p){if(!J(t,function(e,t){if(!p.has(t)&&(y===e||r(y,e,n,i,a)))return p.add(t)})){h=!1;break}}else if(y!==m&&!r(y,m,n,i,a)){h=!1;break}}return a.delete(e),a.delete(t),h}function Qe(e,t){var r,n,i=e.__data__;return("string"==(n=typeof(r=t))||"number"==n||"symbol"==n||"boolean"==n?"__proto__"!==r:null===r)?i["string"==typeof t?"string":"hash"]:i.map}function Xe(e,t){var r=function(e,t){return null==e?void 0:e[t]}(e,t);return Ue(r)?r:void 0}ke.prototype.clear=function(){this.__data__=Se?Se(null):{}},ke.prototype.delete=function(e){return this.has(e)&&delete this.__data__[e]},ke.prototype.get=function(e){var t=this.__data__;if(Se){var r=t[e];return r===a?void 0:r}return ce.call(t,e)?t[e]:void 0},ke.prototype.has=function(e){var t=this.__data__;return Se?void 0!==t[e]:ce.call(t,e)},ke.prototype.set=function(e,t){return this.__data__[e]=Se&&void 0===t?a:t,this},Pe.prototype.clear=function(){this.__data__=[]},Pe.prototype.delete=function(e){var t=this.__data__,r=Le(t,e);return!(r<0)&&(r==t.length-1?t.pop():pe.call(t,r,1),!0)},Pe.prototype.get=function(e){var t=this.__data__,r=Le(t,e);return r<0?void 0:t[r][1]},Pe.prototype.has=function(e){return Le(this.__data__,e)>-1},Pe.prototype.set=function(e,t){var r=this.__data__,n=Le(r,e);return n<0?r.push([e,t]):r[n][1]=t,this},je.prototype.clear=function(){this.__data__={hash:new ke,map:new(be||Pe),string:new ke}},je.prototype.delete=function(e){return Qe(this,e).delete(e)},je.prototype.get=function(e){return Qe(this,e).get(e)},je.prototype.has=function(e){return Qe(this,e).has(e)},je.prototype.set=function(e,t){return Qe(this,e).set(e,t),this},De.prototype.add=De.prototype.push=function(e){return this.__data__.set(e,a),this},De.prototype.has=function(e){return this.__data__.has(e)},Ce.prototype.clear=function(){this.__data__=new Pe},Ce.prototype.delete=function(e){return this.__data__.delete(e)},Ce.prototype.get=function(e){return this.__data__.get(e)},Ce.prototype.has=function(e){return this.__data__.has(e)},Ce.prototype.set=function(e,t){var r=this.__data__;if(r instanceof Pe){var i=r.__data__;if(!be||i.length<n-1)return i.push([e,t]),this;r=this.__data__=new je(i)}return r.set(e,t),this};var $e=function(e){return ue.call(e)};function Je(e,t){return!!(t=null==t?u:t)&&("number"==typeof e||q.test(e))&&e>-1&&e%1==0&&e<t}function Ye(e,t){if(st(e))return!1;var r=typeof e;return!("number"!=r&&"symbol"!=r&&"boolean"!=r&&null!=e&&!ht(e))||(N.test(e)||!I.test(e)||null!=t&&e in Object(t))}function Ke(e){return e==e&&!ft(e)}function We(e,t){return function(r){return null!=r&&(r[e]===t&&(void 0!==t||e in Object(r)))}}(ge&&$e(new ge(new ArrayBuffer(1)))!=A||be&&$e(new be)!=v||ve&&"[object Promise]"!=$e(ve.resolve())||_e&&$e(new _e)!=E||we&&"[object WeakMap]"!=$e(new we))&&($e=function(e){var t=ue.call(e),r=t==w?e.constructor:void 0,n=r?tt(r):void 0;if(n)switch(n){case Ee:return A;case xe:return v;case Te:return"[object Promise]";case Oe:return E;case Ae:return"[object WeakMap]"}return t});var Ze=it(function(e){var t;e=null==(t=e)?"":function(e){if("string"==typeof e)return e;if(ht(e))return Re?Re.call(e):"";var t=e+"";return"0"==t&&1/e==-c?"-0":t}(t);var r=[];return R.test(e)&&r.push(""),e.replace(k,function(e,t,n,i){r.push(n?i.replace(j,"$1"):t||e)}),r});function et(e){if("string"==typeof e||ht(e))return e;var t=e+"";return"0"==t&&1/e==-c?"-0":t}function tt(e){if(null!=e){try{return se.call(e)}catch(e){}try{return e+""}catch(e){}}return""}var rt,nt=(rt=function(e,t,r){var n=e?e.length:0;if(!n)return-1;var i,a,o=null==r?0:(i=function(e){return e?(e=function(e){if("number"==typeof e)return e;if(ht(e))return f;if(ft(e)){var t="function"==typeof e.valueOf?e.valueOf():e;e=ft(t)?t+"":t}if("string"!=typeof e)return 0===e?e:+e;e=e.replace(P,"");var r=C.test(e);return r||L.test(e)?B(e.slice(2),r?2:8):D.test(e)?f:+e}(e))===c||e===-c?(e<0?-1:1)*l:e==e?e:0:0===e?e:0}(r),a=i%1,i==i?a?i-a:i:0);return o<0&&(o=me(n+o,0)),function(e,t,r,n){for(var i=e.length,a=r+(n?1:-1);n?a--:++a<i;)if(t(e[a],a,e))return a;return-1}(e,Ve(t),o)},function(e,t,r){var n=Object(e);if(!ct(e)){var i=Ve(t);e=yt(e),t=function(e){return i(n[e],e,n)}}var a=rt(e,t,r);return a>-1?n[i?e[a]:a]:void 0});function it(e,t){if("function"!=typeof e||t&&"function"!=typeof t)throw new TypeError(i);var r=function(){var n=arguments,i=t?t.apply(this,n):n[0],a=r.cache;if(a.has(i))return a.get(i);var o=e.apply(this,n);return r.cache=a.set(i,o),o};return r.cache=new(it.Cache||je),r}function at(e,t){return e===t||e!=e&&t!=t}function ot(e){return function(e){return dt(e)&&ct(e)}(e)&&ce.call(e,"callee")&&(!he.call(e,"callee")||ue.call(e)==d)}it.Cache=je;var st=Array.isArray;function ct(e){return null!=e&&lt(e.length)&&!ut(e)}function ut(e){var t=ft(e)?ue.call(e):"";return t==g||t==b}function lt(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=u}function ft(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}function dt(e){return!!e&&"object"==typeof e}function ht(e){return"symbol"==typeof e||dt(e)&&ue.call(e)==T}var pt=$?function(e){return function(t){return e(t)}}($):function(e){return dt(e)&&lt(e.length)&&!!F[ue.call(e)]};function yt(e){return ct(e)?Me(e):He(e)}function mt(e){return e}r.exports=nt}).call(this,r(9),r(40)(e))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(6),i=r(8),a=r(46),o=r(4),s=r(690);t.ActorQueryOperationGroup=class extends o.ActorQueryOperationTypedMediated{constructor(e){super(e,"group")}async testOperation(e,t){for(const t in e.aggregates){new a.SyncEvaluator(e.aggregates[t].expression)}return!0}async runOperation(e,t){const{input:r,aggregates:a}=e,c=await this.mediatorQueryOperation.mediate({operation:r,context:t}),u=o.ActorQueryOperation.getSafeBindings(c),l=e.variables.map(i.termToString).concat(a.map(e=>i.termToString(e.variable))),f=Object.assign({},o.ActorQueryOperation.getExpressionContext(t));return new Promise((t,r)=>{const i=new s.GroupsState(e,f);u.bindingsStream.on("end",()=>{try{const e=new n.ArrayIterator(i.collectResults()),a=u.metadata;t({type:"bindings",bindingsStream:e,metadata:a,variables:l})}catch(e){r(e)}}),u.bindingsStream.on("error",r),u.bindingsStream.on("data",e=>{try{i.consumeBindings(e)}catch(e){r(e)}})})}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(8),i=r(46),a=r(77),o=r(4);t.GroupsState=class{constructor(e,t){this.pattern=e,this.sparqleeConfig=t,this.groups=new Map,this.groupVariables=new Set(this.pattern.variables.map(n.termToString)),this.distinctHashes=e.aggregates.some(({distinct:e})=>e)?new Map:null}consumeBindings(e){const t=e.filter((e,t)=>this.groupVariables.has(t)).toMap(),r=this.hashBindings(t);if(this.groups.has(r)){const t=this.groups.get(r);for(const i in this.pattern.aggregates){const a=this.pattern.aggregates[i];if(a.distinct){const t=this.hashBindings(e);if(this.distinctHashes.get(r).has(t))continue;this.distinctHashes.get(r).add(t)}const o=n.termToString(a.variable);t.aggregators[o].put(e)}}else{const a={};for(const t in this.pattern.aggregates){const r=this.pattern.aggregates[t],o=n.termToString(r.variable);a[o]=new i.AggregateEvaluator(r,this.sparqleeConfig),a[o].put(e)}const o={aggregators:a,bindings:t};if(this.groups.set(r,o),this.distinctHashes){const t=this.hashBindings(e);this.distinctHashes.set(r,new Set([t]))}}}collectResults(){let e=Array.from(this.groups,([e,t])=>{const{bindings:r,aggregators:n}=t,i={};for(const e in n){const t=n[e].result();void 0!==t&&(i[e]=t)}return r.merge(i)});if(0===e.length){const t={};for(const e in this.pattern.aggregates){const r=this.pattern.aggregates[e],a=n.termToString(r.variable),o=i.AggregateEvaluator.emptyValue(r);void 0!==o&&(t[a]=o)}e=[o.Bindings(t)]}return e}hashBindings(e){return a.AbstractFilterHash.hash("sha1","hex",e)}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(4);t.ActorQueryOperationJoin=class extends n.ActorQueryOperationTypedMediated{constructor(e){super(e,"join")}async testOperation(e,t){return!0}async runOperation(e,t){const r=this.mediatorQueryOperation.mediate({operation:e.left,context:t}),i=this.mediatorQueryOperation.mediate({operation:e.right,context:t});return this.mediatorJoin.mediate({entries:[n.ActorQueryOperation.getSafeBindings(await r),n.ActorQueryOperation.getSafeBindings(await i)]})}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(4),i=r(149),a=r(46);t.ActorQueryOperationLeftJoinNestedLoop=class extends n.ActorQueryOperationTypedMediated{constructor(e){super(e,"leftjoin")}async testOperation(e,t){return!0}async runOperation(e,t){const r=await this.mediatorQueryOperation.mediate({operation:e.left,context:t}),o=n.ActorQueryOperation.getSafeBindings(r),s=await this.mediatorQueryOperation.mediate({operation:e.right,context:t}),c=n.ActorQueryOperation.getSafeBindings(s),u=Object.assign({},n.ActorQueryOperation.getExpressionContext(t)),l=e.expression?new a.AsyncEvaluator(e.expression,u):null,f=(t,r)=>{const n=((t,r)=>{const n=r.transform({transform:async(r,o)=>{const s=i.ActorRdfJoin.join(t,r);if(s){if(!e.expression)return n._push({joinedBindings:s,result:!0}),void o();try{const e=await l.evaluateAsEBV(s);n._push({joinedBindings:s,result:e})}catch(e){a.isExpressionError(e)||d.emit("error",e)}o()}else o()}});return n})(t,c.bindingsStream.clone());n.on("end",()=>r()),n.on("data",async({joinedBindings:e,result:t})=>{t&&d._push(e)})},d=o.bindingsStream.transform({optional:!0,transform:f}),h=i.ActorRdfJoin.joinVariables({entries:[o,c]});return{type:"bindings",bindingsStream:d,metadata:()=>Promise.all([o,c].map(e=>e.metadata())).then(e=>e.reduce((e,t)=>e*t.totalItems,1)).catch(()=>1/0).then(e=>({totalItems:e})),variables:h}}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(8),i=r(10),a=r(46),o=r(4),s=r(694);t.ActorQueryOperationOrderBySparqlee=class extends o.ActorQueryOperationTypedMediated{constructor(e){super(e,"orderby"),this.window=e.window||1/0}async testOperation(e,t){for(let t of e.expressions){t=this.extractSortExpression(t);new a.AsyncEvaluator(t)}return!0}async runOperation(e,t){const r=await this.mediatorQueryOperation.mediate({operation:e.input,context:t}),i=o.ActorQueryOperation.getSafeBindings(r),c={window:this.window},u=Object.assign({},o.ActorQueryOperation.getExpressionContext(t));let l=i.bindingsStream;for(let t of e.expressions){const e=this.isAscending(t);t=this.extractSortExpression(t);const r=new a.AsyncEvaluator(t,u),i=async(e,t)=>{try{const t=await r.evaluate(e);o._push({bindings:e,result:t})}catch(t){a.isExpressionError(t)||l.emit("error",t),o._push({bindings:e,result:void 0})}t()},o=l.transform({transform:i}),f=new s.SortIterator(o,(t,r)=>{const i=n.termToString(t.result),a=n.termToString(r.result);return i&&a?i>a===e?1:-1:0},c);l=f.map(({bindings:e,result:t})=>e)}return{type:"bindings",bindingsStream:l,metadata:i.metadata,variables:i.variables}}extractSortExpression(e){const{expressionType:t,operator:r}=e;return t!==i.Algebra.expressionTypes.OPERATOR?e:"desc"===r?e.args[0]:e}isAscending(e){const{expressionType:t,operator:r}=e;return t!==i.Algebra.expressionTypes.OPERATOR||"desc"!==r}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(6);t.SortIterator=class extends n.TransformIterator{constructor(e,t,r){super(e,r);const n=r&&r.window;this.windowLength=isFinite(n)&&n>0?n:1/0,this.sort=t,this.sorted=[]}_read(e,t){let r,n=this.sorted.length;for(;n!==this.windowLength&&null!==(r=this.source.read());){let e,t,i=0,a=n-1;for(;i<=a;)e=Math.trunc((i+a)/2),(t=this.sort(r,this.sorted[e]))<0?i=e+1:t>0?a=e-1:(i=e,a=-1);this.sorted.splice(i,0,r),n++}n===this.windowLength&&this._push(this.sorted.pop()),t()}_flush(e){let t=this.sorted.length;for(;t--;)this._push(this.sorted.pop());e()}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(4),i=r(8);t.ActorQueryOperationProject=class extends n.ActorQueryOperationTypedMediated{constructor(e){super(e,"project")}async testOperation(e,t){return!0}async runOperation(e,t){const r=n.ActorQueryOperation.getSafeBindings(await this.mediatorQueryOperation.mediate({operation:e.input,context:t})),a=e.variables.map(i.termToString),o=r.variables.filter(e=>a.indexOf(e)<0),s=a.filter(e=>r.variables.indexOf(e)<0);return{type:"bindings",bindingsStream:o.length||s.length?r.bindingsStream.map(e=>{for(const t of o)e=e.delete(t);for(const t of s)e=e.set(t,null);return e}):r.bindingsStream,metadata:r.metadata,variables:a}}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(77),i=r(4),a=r(33);class o extends n.AbstractFilterHash{constructor(e){super(e,"minus")}newHashFilter(e,t,r,n){return i=>{return!(o.hash(e,t,i.filter((e,t)=>r[t]))in n)}}async runOperation(e,t){const r=i.ActorQueryOperation.getSafeBindings(await this.mediatorQueryOperation.mediate({operation:e.right,context:t})),n=i.ActorQueryOperation.getSafeBindings(await this.mediatorQueryOperation.mediate({operation:e.left,context:t})),s=this.getCommonVariables(r.variables,n.variables);if(0!==Object.keys(s).length){const e={};return{type:"bindings",bindingsStream:new a.PromiseProxyIterator(async()=>(await new Promise(t=>{r.bindingsStream.on("data",t=>{const r=o.hash(this.hashAlgorithm,this.digestAlgorithm,t.filter((e,t)=>s[t]));e[r]=!0}),r.bindingsStream.on("end",()=>{t()})}),n.bindingsStream.filter(this.newHashFilter(this.hashAlgorithm,this.digestAlgorithm,s,e)))),variables:n.variables,metadata:n.metadata}}return n}getCommonVariables(e,t){return e.filter(e=>-1!==t.indexOf(e)).reduce((e,t)=>(e[t]=!0,e),{})}}t.ActorQueryOperationMinus=o},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(35),i=r(4),a=r(76),o=r(10);t.ActorQueryOperationPathAlt=class extends n.ActorAbstractPath{constructor(e){super(e,o.Algebra.types.ALT)}async runOperation(e,t){const o=e.predicate,s=(await Promise.all([this.mediatorQueryOperation.mediate({context:t,operation:n.ActorAbstractPath.FACTORY.createPath(e.subject,o.left,e.object,e.graph)}),this.mediatorQueryOperation.mediate({context:t,operation:n.ActorAbstractPath.FACTORY.createPath(e.subject,o.right,e.object,e.graph)})])).map(e=>i.ActorQueryOperation.getSafeBindings(e));return{type:"bindings",bindingsStream:new a.RoundRobinUnionIterator(s.map(e=>e.bindingsStream)),variables:r(244)([].concat.apply([],s.map(e=>e.variables)))}}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(35),i=r(10);t.ActorQueryOperationPathInv=class extends n.ActorAbstractPath{constructor(e){super(e,i.Algebra.types.INV)}async runOperation(e,t){const r=e.predicate,i=n.ActorAbstractPath.FACTORY.createPath(e.object,r.path,e.subject,e.graph);return this.mediatorQueryOperation.mediate({operation:i,context:t})}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(35),i=r(10);t.ActorQueryOperationPathLink=class extends n.ActorAbstractPath{constructor(e){super(e,i.Algebra.types.LINK)}async runOperation(e,t){const r=e.predicate,i=n.ActorAbstractPath.FACTORY.createPattern(e.subject,r.iri,e.object,e.graph);return this.mediatorQueryOperation.mediate({operation:i,context:t})}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(35),i=r(4),a=r(8),o=r(10);t.ActorQueryOperationPathNps=class extends n.ActorAbstractPath{constructor(e){super(e,o.Algebra.types.NPS)}async runOperation(e,t){const r=e.predicate,o=this.generateBlankNode(e),s=a.termToString(o),c=n.ActorAbstractPath.FACTORY.createPattern(e.subject,o,e.object,e.graph),u=i.ActorQueryOperation.getSafeBindings(await this.mediatorQueryOperation.mediate({operation:c,context:t})),l=u.bindingsStream.transform({filter:e=>!r.iris.some(t=>t.equals(e.get(s))),transform:(e,t)=>{l._push(e.delete(s)),t(null)}});return{type:"bindings",bindingsStream:l,variables:u.variables}}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(35),i=r(4),a=r(6),o=r(33),s=r(8),c=r(10);t.ActorQueryOperationPathOneOrMore=class extends n.ActorAbstractPath{constructor(e){super(e,c.Algebra.types.ONE_OR_MORE_PATH)}async runOperation(e,t){const r=e.predicate,c="Variable"===e.subject.termType,u="Variable"===e.object.termType;if(!c&&u){const c=n.ActorAbstractPath.FACTORY.createPath(e.subject,r.path,e.object,e.graph),u=i.ActorQueryOperation.getSafeBindings(await this.mediatorQueryOperation.mediate({context:t,operation:c})),l=s.termToString(e.object),f={},d=new a.MultiTransformIterator(u.bindingsStream);return d._createTransformer=e=>{const n=e.get(l);return new o.PromiseProxyIterator(async()=>{const e=new a.BufferedIterator;return await this.ALP(n,r.path,t,f,e,{count:0}),e.transform({transform:(e,t)=>{d._push(i.Bindings({[l]:e})),t(null)}})},{autoStart:!0,maxBufferSize:128})},{type:"bindings",bindingsStream:d,variables:[l]}}if(c&&u)throw new Error("ZeroOrMore path expressions with 2 variables not supported yet");if(c&&!u)return this.mediatorQueryOperation.mediate({context:t,operation:n.ActorAbstractPath.FACTORY.createPath(e.object,n.ActorAbstractPath.FACTORY.createOneOrMorePath(n.ActorAbstractPath.FACTORY.createInv(r.path)),e.subject,e.graph)});{const a=this.generateBlankNode(),o=s.termToString(a),c=i.ActorQueryOperation.getSafeBindings(await this.mediatorQueryOperation.mediate({context:t,operation:n.ActorAbstractPath.FACTORY.createPath(e.subject,r,a,e.graph)})).bindingsStream.transform({filter:t=>t.get(o).equals(e.object),transform:(e,t)=>{c._push(i.Bindings({})),t(null)}});return{type:"bindings",bindingsStream:c,variables:[]}}}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(35),i=r(4),a=r(8),o=r(10);t.ActorQueryOperationPathSeq=class extends n.ActorAbstractPath{constructor(e){super(e,o.Algebra.types.SEQ)}async runOperation(e,t){const r=e.predicate,o=this.generateBlankNode(e),s=a.termToString(o),c=(await Promise.all([this.mediatorQueryOperation.mediate({context:t,operation:n.ActorAbstractPath.FACTORY.createPath(e.subject,r.left,o,e.graph)}),this.mediatorQueryOperation.mediate({context:t,operation:n.ActorAbstractPath.FACTORY.createPath(o,r.right,e.object,e.graph)})])).map(e=>i.ActorQueryOperation.getSafeBindings(e)),u=i.ActorQueryOperation.getSafeBindings(await this.mediatorJoin.mediate({entries:c})),l=u.bindingsStream.transform({transform:(e,t)=>{l._push(e.delete(s)),t(null)}});return{type:"bindings",bindingsStream:l,variables:u.variables}}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(35),i=r(4),a=r(8),o=r(10);t.ActorQueryOperationPathZeroOrMore=class extends n.ActorAbstractPath{constructor(e){super(e,o.Algebra.types.ZERO_OR_MORE_PATH)}async runOperation(e,t){const r=e.predicate,o="Variable"===e.subject.termType,s="Variable"===e.object.termType;if(o&&s)throw new Error("ZeroOrMore path expressions with 2 variables not supported yet");if(o||s){const s=a.termToString(o?e.subject:e.object),c=o?n.ActorAbstractPath.FACTORY.createInv(r.path):r.path,u=(await this.ALPeval(o?e.object:e.subject,c,t)).transform({transform:(e,t)=>{u._push(i.Bindings({[s]:e})),t(null)}});return{type:"bindings",bindingsStream:u,variables:[s]}}{const n=(await this.ALPeval(e.subject,r.path,t)).transform({filter:t=>t.equals(e.object),transform:(e,t)=>{n._push(i.Bindings({})),t(null)}});return{type:"bindings",bindingsStream:n,variables:[]}}}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const n=r(293),i=r(4),a=r(6),o=r(8),s=r(10);t.ActorQueryOperationPathZeroOrOne=class extends n.ActorAbstractPath{constructor(e){super(e,s.Algebra.types.ZERO_OR_ONE_PATH)}async runOperation(e,t){const r=e.predicate,s="Variable"===e.subject.termType,c="Variable"===e.object.termType,u=[];if(!s&&!c&&e.subject.equals(e.object))return{type:"bindings",bindingsStream:new a.SingletonIterator(i.Bindings({})),variables:[]};if(s&&c)throw new Error("ZeroOrOne path expressions with 2 variables not supported yet");s&&u.push(i.Bindings({[o.termToString(e.subject)]:e.object})),c&&u.push(i.Bindings({[o.termToString(e.object)]:e.subject}));const l=i.ActorQueryOperation.getSafeBindings(await this.mediatorQueryOperation.mediate({context:t,operation:n.ActorAbstractPath.FACTORY.createPath(e.subject,r.path,e.object,e.graph)}));return{type:"bindings",bindingsStream:l.bindingsStream.prepend(u),variables:l.variables}}}},function(e,t,r){"use strict";function n(e,t){if(!Boolean(e))throw new Error(t)}r.r(t);var i,a=function(e,t,r){this.body=e,this.name=t||"GraphQL request",this.locationOffset=r||{line:1,column:1},this.locationOffset.line>0||n(0,"line in locationOffset is 1-indexed and must be positive"),this.locationOffset.column>0||n(0,"column in locationOffset is 1-indexed and must be positive")};function o(e,t){for(var r,n=/\r\n|[\n\r]/g,i=1,a=t+1;(r=n.exec(e.body))&&r.index<t;)i+=1,a=t+1-(r.index+r[0].length);return{line:i,column:a}}function s(e){return c(e.source,o(e.source,e.start))}function c(e,t){var r=e.locationOffset.column-1,n=l(r)+e.body,i=t.line-1,a=e.locationOffset.line-1,o=t.line+a,s=1===t.line?r:0,c=t.column+s,f="".concat(e.name,":").concat(o,":").concat(c,"\n"),d=n.split(/\r\n|[\n\r]/g),h=d[i];if(h.length>120){for(var p=Math.floor(c/80),y=c%80,m=[],g=0;g<h.length;g+=80)m.push(h.slice(g,g+80));return f+u([["".concat(o),m[0]]].concat(m.slice(1,p+1).map(function(e){return["",e]}),[[" ",l(y-1)+"^"],["",m[p+1]]]))}return f+u([["".concat(o-1),d[i-1]],["".concat(o),h],["",l(c-1)+"^"],["".concat(o+1),d[i+1]]])}function u(e){var t=e.filter(function(e){e[0];return void 0!==e[1]}),r=Math.max.apply(Math,t.map(function(e){return e[0].length}));return t.map(function(e){var t,n=e[0],i=e[1];return l(r-(t=n).length)+t+" | "+i}).join("\n")}function l(e){return Array(e+1).join(" ")}i=a,"function"==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(i.prototype,Symbol.toStringTag,{get:function(){return this.constructor.name}});var f=Object.freeze({NAME:"Name",DOCUMENT:"Document",OPERATION_DEFINITION:"OperationDefinition",VARIABLE_DEFINITION:"VariableDefinition",SELECTION_SET:"SelectionSet",FIELD:"Field",ARGUMENT:"Argument",FRAGMENT_SPREAD:"FragmentSpread",INLINE_FRAGMENT:"InlineFragment",FRAGMENT_DEFINITION:"FragmentDefinition",VARIABLE:"Variable",INT:"IntValue",FLOAT:"FloatValue",STRING:"StringValue",BOOLEAN:"BooleanValue",NULL:"NullValue",ENUM:"EnumValue",LIST:"ListValue",OBJECT:"ObjectValue",OBJECT_FIELD:"ObjectField",DIRECTIVE:"Directive",NAMED_TYPE:"NamedType",LIST_TYPE:"ListType",NON_NULL_TYPE:"NonNullType",SCHEMA_DEFINITION:"SchemaDefinition",OPERATION_TYPE_DEFINITION:"OperationTypeDefinition",SCALAR_TYPE_DEFINITION:"ScalarTypeDefinition",OBJECT_TYPE_DEFINITION:"ObjectTypeDefinition",FIELD_DEFINITION:"FieldDefinition",INPUT_VALUE_DEFINITION:"InputValueDefinition",INTERFACE_TYPE_DEFINITION:"InterfaceTypeDefinition",UNION_TYPE_DEFINITION:"UnionTypeDefinition",ENUM_TYPE_DEFINITION:"EnumTypeDefinition",ENUM_VALUE_DEFINITION:"EnumValueDefinition",INPUT_OBJECT_TYPE_DEFINITION:"InputObjectTypeDefinition",DIRECTIVE_DEFINITION:"DirectiveDefinition",SCHEMA_EXTENSION:"SchemaExtension",SCALAR_TYPE_EXTENSION:"ScalarTypeExtension",OBJECT_TYPE_EXTENSION:"ObjectTypeExtension",INTERFACE_TYPE_EXTENSION:"InterfaceTypeExtension",UNION_TYPE_EXTENSION:"UnionTypeExtension",ENUM_TYPE_EXTENSION:"EnumTypeExtension",INPUT_OBJECT_TYPE_EXTENSION:"InputObjectTypeExtension"}),d=Object.freeze({SOF:"<SOF>",EOF:"<EOF>",BANG:"!",DOLLAR:"$",AMP:"&",PAREN_L:"(",PAREN_R:")",SPREAD:"...",COLON:":",EQUALS:"=",AT:"@",BRACKET_L:"[",BRACKET_R:"]",BRACE_L:"{",PIPE:"|",BRACE_R:"}",NAME:"Name",INT:"Int",FLOAT:"Float",STRING:"String",BLOCK_STRING:"BlockString",COMMENT:"Comment"}),h="function"==typeof Symbol&&"function"==typeof Symbol.for?Symbol.for("nodejs.util.inspect.custom"):void 0;function p(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:e.prototype.toString;e.prototype.toJSON=t,e.prototype.inspect=t,h&&(e.prototype[h]=t)}function y(e){return(y="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function m(e,t,r,n,i,a,s){var c=Array.isArray(t)?0!==t.length?t:void 0:t?[t]:void 0,u=r;if(!u&&c){var l=c[0];u=l&&l.loc&&l.loc.source}var f,d=n;!d&&c&&(d=c.reduce(function(e,t){return t.loc&&e.push(t.loc.start),e},[])),d&&0===d.length&&(d=void 0),n&&r?f=n.map(function(e){return o(r,e)}):c&&(f=c.reduce(function(e,t){return t.loc&&e.push(o(t.loc.source,t.loc.start)),e},[]));var h,p=s;if(null==p&&null!=a){var g=a.extensions;"object"==y(h=g)&&null!==h&&(p=g)}Object.defineProperties(this,{message:{value:e,enumerable:!0,writable:!0},locations:{value:f||void 0,enumerable:Boolean(f)},path:{value:i||void 0,enumerable:Boolean(i)},nodes:{value:c||void 0},source:{value:u||void 0},positions:{value:d||void 0},originalError:{value:a},extensions:{value:p||void 0,enumerable:Boolean(p)}}),a&&a.stack?Object.defineProperty(this,"stack",{value:a.stack,writable:!0,configurable:!0}):Error.captureStackTrace?Error.captureStackTrace(this,m):Object.defineProperty(this,"stack",{value:Error().stack,writable:!0,configurable:!0})}function g(e,t,r){return new m("Syntax Error: ".concat(r),void 0,e,[t])}function b(e){var t=e.split(/\r\n|[\n\r]/g),r=function(e){for(var t=null,r=1;r<e.length;r++){var n=e[r],i=v(n);if(i!==n.length&&((null===t||i<t)&&0===(t=i)))break}return null===t?0:t}(t);if(0!==r)for(var n=1;n<t.length;n++)t[n]=t[n].slice(r);for(;t.length>0&&_(t[0]);)t.shift();for(;t.length>0&&_(t[t.length-1]);)t.pop();return t.join("\n")}function v(e){for(var t=0;t<e.length&&(" "===e[t]||"\t"===e[t]);)t++;return t}function _(e){return v(e)===e.length}function w(e,t){var r=new T(d.SOF,0,0,0,0,null);return{source:e,options:t,lastToken:r,token:r,line:1,lineStart:0,advance:S,lookahead:E}}function S(){return this.lastToken=this.token,this.token=this.lookahead()}function E(){var e=this.token;if(e.kind!==d.EOF)do{e=e.next||(e.next=A(this,e))}while(e.kind===d.COMMENT);return e}function x(e){var t=e.value;return t?"".concat(e.kind,' "').concat(t,'"'):e.kind}function T(e,t,r,n,i,a,o){this.kind=e,this.start=t,this.end=r,this.line=n,this.column=i,this.value=o,this.prev=a,this.next=null}function O(e){return isNaN(e)?d.EOF:e<127?JSON.stringify(String.fromCharCode(e)):'"\\u'.concat(("00"+e.toString(16).toUpperCase()).slice(-4),'"')}function A(e,t){var r=e.source,n=r.body,i=n.length,a=function(e,t,r){var n=e.length,i=t;for(;i<n;){var a=e.charCodeAt(i);if(9===a||32===a||44===a||65279===a)++i;else if(10===a)++i,++r.line,r.lineStart=i;else{if(13!==a)break;10===e.charCodeAt(i+1)?i+=2:++i,++r.line,r.lineStart=i}}return i}(n,t.end,e),o=e.line,s=1+a-e.lineStart;if(a>=i)return new T(d.EOF,i,i,o,s,t);var c=n.charCodeAt(a);switch(c){case 33:return new T(d.BANG,a,a+1,o,s,t);case 35:return function(e,t,r,n,i){var a,o=e.body,s=t;do{a=o.charCodeAt(++s)}while(!isNaN(a)&&(a>31||9===a));return new T(d.COMMENT,t,s,r,n,i,o.slice(t+1,s))}(r,a,o,s,t);case 36:return new T(d.DOLLAR,a,a+1,o,s,t);case 38:return new T(d.AMP,a,a+1,o,s,t);case 40:return new T(d.PAREN_L,a,a+1,o,s,t);case 41:return new T(d.PAREN_R,a,a+1,o,s,t);case 46:if(46===n.charCodeAt(a+1)&&46===n.charCodeAt(a+2))return new T(d.SPREAD,a,a+3,o,s,t);break;case 58:return new T(d.COLON,a,a+1,o,s,t);case 61:return new T(d.EQUALS,a,a+1,o,s,t);case 64:return new T(d.AT,a,a+1,o,s,t);case 91:return new T(d.BRACKET_L,a,a+1,o,s,t);case 93:return new T(d.BRACKET_R,a,a+1,o,s,t);case 123:return new T(d.BRACE_L,a,a+1,o,s,t);case 124:return new T(d.PIPE,a,a+1,o,s,t);case 125:return new T(d.BRACE_R,a,a+1,o,s,t);case 65:case 66:case 67:case 68:case 69:case 70:case 71:case 72:case 73:case 74:case 75:case 76:case 77:case 78:case 79:case 80:case 81:case 82:case 83:case 84:case 85:case 86:case 87:case 88:case 89:case 90:case 95:case 97:case 98:case 99:case 100:case 101:case 102:case 103:case 104:case 105:case 106:case 107:case 108:case 109:case 110:case 111:case 112:case 113:case 114:case 115:case 116:case 117:case 118:case 119:case 120:case 121:case 122:return function(e,t,r,n,i){var a=e.body,o=a.length,s=t+1,c=0;for(;s!==o&&!isNaN(c=a.charCodeAt(s))&&(95===c||c>=48&&c<=57||c>=65&&c<=90||c>=97&&c<=122);)++s;return new T(d.NAME,t,s,r,n,i,a.slice(t,s))}(r,a,o,s,t);case 45:case 48:case 49:case 50:case 51:case 52:case 53:case 54:case 55:case 56:case 57:return function(e,t,r,n,i,a){var o=e.body,s=r,c=t,u=!1;45===s&&(s=o.charCodeAt(++c));if(48===s){if((s=o.charCodeAt(++c))>=48&&s<=57)throw g(e,c,"Invalid number, unexpected digit after 0: ".concat(O(s),"."))}else c=I(e,c,s),s=o.charCodeAt(c);46===s&&(u=!0,s=o.charCodeAt(++c),c=I(e,c,s),s=o.charCodeAt(c));69!==s&&101!==s||(u=!0,43!==(s=o.charCodeAt(++c))&&45!==s||(s=o.charCodeAt(++c)),c=I(e,c,s));return new T(u?d.FLOAT:d.INT,t,c,n,i,a,o.slice(t,c))}(r,a,c,o,s,t);case 34:return 34===n.charCodeAt(a+1)&&34===n.charCodeAt(a+2)?function(e,t,r,n,i,a){var o=e.body,s=t+3,c=s,u=0,l="";for(;s<o.length&&!isNaN(u=o.charCodeAt(s));){if(34===u&&34===o.charCodeAt(s+1)&&34===o.charCodeAt(s+2))return l+=o.slice(c,s),new T(d.BLOCK_STRING,t,s+3,r,n,i,b(l));if(u<32&&9!==u&&10!==u&&13!==u)throw g(e,s,"Invalid character within String: ".concat(O(u),"."));10===u?(++s,++a.line,a.lineStart=s):13===u?(10===o.charCodeAt(s+1)?s+=2:++s,++a.line,a.lineStart=s):92===u&&34===o.charCodeAt(s+1)&&34===o.charCodeAt(s+2)&&34===o.charCodeAt(s+3)?(l+=o.slice(c,s)+'"""',c=s+=4):++s}throw g(e,s,"Unterminated string.")}(r,a,o,s,t,e):function(e,t,r,n,i){var a=e.body,o=t+1,s=o,c=0,u="";for(;o<a.length&&!isNaN(c=a.charCodeAt(o))&&10!==c&&13!==c;){if(34===c)return u+=a.slice(s,o),new T(d.STRING,t,o+1,r,n,i,u);if(c<32&&9!==c)throw g(e,o,"Invalid character within String: ".concat(O(c),"."));if(++o,92===c){switch(u+=a.slice(s,o-1),c=a.charCodeAt(o)){case 34:u+='"';break;case 47:u+="/";break;case 92:u+="\\";break;case 98:u+="\b";break;case 102:u+="\f";break;case 110:u+="\n";break;case 114:u+="\r";break;case 116:u+="\t";break;case 117:var l=(h=a.charCodeAt(o+1),p=a.charCodeAt(o+2),y=a.charCodeAt(o+3),m=a.charCodeAt(o+4),N(h)<<12|N(p)<<8|N(y)<<4|N(m));if(l<0){var f=a.slice(o+1,o+5);throw g(e,o,"Invalid character escape sequence: \\u".concat(f,"."))}u+=String.fromCharCode(l),o+=4;break;default:throw g(e,o,"Invalid character escape sequence: \\".concat(String.fromCharCode(c),"."))}s=++o}}var h,p,y,m;throw g(e,o,"Unterminated string.")}(r,a,o,s,t)}throw g(r,a,function(e){if(e<32&&9!==e&&10!==e&&13!==e)return"Cannot contain the invalid character ".concat(O(e),".");if(39===e)return"Unexpected single quote character ('), did you mean to use a double quote (\")?";return"Cannot parse the unexpected character ".concat(O(e),".")}(c))}function I(e,t,r){var n=e.body,i=t,a=r;if(a>=48&&a<=57){do{a=n.charCodeAt(++i)}while(a>=48&&a<=57);return i}throw g(e,i,"Invalid number, expected digit but got: ".concat(O(a),"."))}function N(e){return e>=48&&e<=57?e-48:e>=65&&e<=70?e-55:e>=97&&e<=102?e-87:-1}function R(e){return(R="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}m.prototype=Object.create(Error.prototype,{constructor:{value:m},name:{value:"GraphQLError"},toString:{value:function(){return function(e){var t=e.message;if(e.nodes){var r=!0,n=!1,i=void 0;try{for(var a,o=e.nodes[Symbol.iterator]();!(r=(a=o.next()).done);r=!0){var u=a.value;u.loc&&(t+="\n\n"+s(u.loc))}}catch(e){n=!0,i=e}finally{try{r||null==o.return||o.return()}finally{if(n)throw i}}}else if(e.source&&e.locations){var l=!0,f=!1,d=void 0;try{for(var h,p=e.locations[Symbol.iterator]();!(l=(h=p.next()).done);l=!0){var y=h.value;t+="\n\n"+c(e.source,y)}}catch(e){f=!0,d=e}finally{try{l||null==p.return||p.return()}finally{if(f)throw d}}}return t}(this)}}}),p(T,function(){return{kind:this.kind,value:this.value,line:this.line,column:this.column}});var k=10,P=2;function j(e){return D(e,[])}function D(e,t){switch(R(e)){case"string":return JSON.stringify(e);case"function":return e.name?"[function ".concat(e.name,"]"):"[function]";case"object":return null===e?"null":function(e,t){if(-1!==t.indexOf(e))return"[Circular]";var r=[].concat(t,[e]),n=function(e){var t=e[String(h)];if("function"==typeof t)return t;if("function"==typeof e.inspect)return e.inspect}(e);if(void 0!==n){var i=n.call(e);if(i!==e)return"string"==typeof i?i:D(i,r)}else if(Array.isArray(e))return function(e,t){if(0===e.length)return"[]";if(t.length>P)return"[Array]";for(var r=Math.min(k,e.length),n=e.length-r,i=[],a=0;a<r;++a)i.push(D(e[a],t));1===n?i.push("... 1 more item"):n>1&&i.push("... ".concat(n," more items"));return"["+i.join(", ")+"]"}(e,r);return function(e,t){var r=Object.keys(e);if(0===r.length)return"{}";if(t.length>P)return"["+function(e){var t=Object.prototype.toString.call(e).replace(/^\[object /,"").replace(/]$/,"");if("Object"===t&&"function"==typeof e.constructor){var r=e.constructor.name;if("string"==typeof r)return r}return t}(e)+"]";return"{ "+r.map(function(r){return r+": "+D(e[r],t)}).join(", ")+" }"}(e,r)}(e,t);default:return String(e)}}var C=Object.freeze({QUERY:"QUERY",MUTATION:"MUTATION",SUBSCRIPTION:"SUBSCRIPTION",FIELD:"FIELD",FRAGMENT_DEFINITION:"FRAGMENT_DEFINITION",FRAGMENT_SPREAD:"FRAGMENT_SPREAD",INLINE_FRAGMENT:"INLINE_FRAGMENT",VARIABLE_DEFINITION:"VARIABLE_DEFINITION",SCHEMA:"SCHEMA",SCALAR:"SCALAR",OBJECT:"OBJECT",FIELD_DEFINITION:"FIELD_DEFINITION",ARGUMENT_DEFINITION:"ARGUMENT_DEFINITION",INTERFACE:"INTERFACE",UNION:"UNION",ENUM:"ENUM",ENUM_VALUE:"ENUM_VALUE",INPUT_OBJECT:"INPUT_OBJECT",INPUT_FIELD_DEFINITION:"INPUT_FIELD_DEFINITION"});function M(e,t){var r="string"==typeof e?new a(e):e;if(!(r instanceof a))throw new TypeError("Must provide Source. Received: ".concat(j(r)));return function(e){var t=e.token;return{kind:f.DOCUMENT,definitions:Re(e,d.SOF,B,d.EOF),loc:we(e,t)}}(w(r,t||{}))}function L(e,t){var r=w("string"==typeof e?new a(e):e,t||{});xe(r,d.SOF);var n=Z(r,!1);return xe(r,d.EOF),n}function q(e,t){var r=w("string"==typeof e?new a(e):e,t||{});xe(r,d.SOF);var n=ae(r);return xe(r,d.EOF),n}function F(e){var t=xe(e,d.NAME);return{kind:f.NAME,value:t.value,loc:we(e,t)}}function B(e){if(Ee(e,d.NAME))switch(e.token.value){case"query":case"mutation":case"subscription":case"fragment":return U(e);case"schema":case"scalar":case"type":case"interface":case"union":case"enum":case"input":case"directive":return se(e);case"extend":return function(e){var t=e.lookahead();if(t.kind===d.NAME)switch(t.value){case"schema":return function(e){var t=e.token;Oe(e,"extend"),Oe(e,"schema");var r=ne(e,!0),n=Ee(e,d.BRACE_L)?Re(e,d.BRACE_L,le,d.BRACE_R):[];if(0===r.length&&0===n.length)throw Ie(e);return{kind:f.SCHEMA_EXTENSION,directives:r,operationTypes:n,loc:we(e,t)}}(e);case"scalar":return function(e){var t=e.token;Oe(e,"extend"),Oe(e,"scalar");var r=F(e),n=ne(e,!0);if(0===n.length)throw Ie(e);return{kind:f.SCALAR_TYPE_EXTENSION,name:r,directives:n,loc:we(e,t)}}(e);case"type":return function(e){var t=e.token;Oe(e,"extend"),Oe(e,"type");var r=F(e),n=fe(e),i=ne(e,!0),a=de(e);if(0===n.length&&0===i.length&&0===a.length)throw Ie(e);return{kind:f.OBJECT_TYPE_EXTENSION,name:r,interfaces:n,directives:i,fields:a,loc:we(e,t)}}(e);case"interface":return function(e){var t=e.token;Oe(e,"extend"),Oe(e,"interface");var r=F(e),n=ne(e,!0),i=de(e);if(0===n.length&&0===i.length)throw Ie(e);return{kind:f.INTERFACE_TYPE_EXTENSION,name:r,directives:n,fields:i,loc:we(e,t)}}(e);case"union":return function(e){var t=e.token;Oe(e,"extend"),Oe(e,"union");var r=F(e),n=ne(e,!0),i=me(e);if(0===n.length&&0===i.length)throw Ie(e);return{kind:f.UNION_TYPE_EXTENSION,name:r,directives:n,types:i,loc:we(e,t)}}(e);case"enum":return function(e){var t=e.token;Oe(e,"extend"),Oe(e,"enum");var r=F(e),n=ne(e,!0),i=ge(e);if(0===n.length&&0===i.length)throw Ie(e);return{kind:f.ENUM_TYPE_EXTENSION,name:r,directives:n,values:i,loc:we(e,t)}}(e);case"input":return function(e){var t=e.token;Oe(e,"extend"),Oe(e,"input");var r=F(e),n=ne(e,!0),i=ve(e);if(0===n.length&&0===i.length)throw Ie(e);return{kind:f.INPUT_OBJECT_TYPE_EXTENSION,name:r,directives:n,fields:i,loc:we(e,t)}}(e)}throw Ie(e,t)}(e)}else{if(Ee(e,d.BRACE_L))return U(e);if(ce(e))return se(e)}throw Ie(e)}function U(e){if(Ee(e,d.NAME))switch(e.token.value){case"query":case"mutation":case"subscription":return V(e);case"fragment":return function(e){var t=e.token;if(Oe(e,"fragment"),e.options.experimentalFragmentVariables)return{kind:f.FRAGMENT_DEFINITION,name:W(e),variableDefinitions:z(e),typeCondition:(Oe(e,"on"),oe(e)),directives:ne(e,!1),selectionSet:X(e),loc:we(e,t)};return{kind:f.FRAGMENT_DEFINITION,name:W(e),typeCondition:(Oe(e,"on"),oe(e)),directives:ne(e,!1),selectionSet:X(e),loc:we(e,t)}}(e)}else if(Ee(e,d.BRACE_L))return V(e);throw Ie(e)}function V(e){var t=e.token;if(Ee(e,d.BRACE_L))return{kind:f.OPERATION_DEFINITION,operation:"query",name:void 0,variableDefinitions:[],directives:[],selectionSet:X(e),loc:we(e,t)};var r,n=H(e);return Ee(e,d.NAME)&&(r=F(e)),{kind:f.OPERATION_DEFINITION,operation:n,name:r,variableDefinitions:z(e),directives:ne(e,!1),selectionSet:X(e),loc:we(e,t)}}function H(e){var t=xe(e,d.NAME);switch(t.value){case"query":return"query";case"mutation":return"mutation";case"subscription":return"subscription"}throw Ie(e,t)}function z(e){return Ee(e,d.PAREN_L)?Re(e,d.PAREN_L,G,d.PAREN_R):[]}function G(e){var t=e.token;return{kind:f.VARIABLE_DEFINITION,variable:Q(e),type:(xe(e,d.COLON),ae(e)),defaultValue:Te(e,d.EQUALS)?Z(e,!0):void 0,directives:ne(e,!0),loc:we(e,t)}}function Q(e){var t=e.token;return xe(e,d.DOLLAR),{kind:f.VARIABLE,name:F(e),loc:we(e,t)}}function X(e){var t=e.token;return{kind:f.SELECTION_SET,selections:Re(e,d.BRACE_L,$,d.BRACE_R),loc:we(e,t)}}function $(e){return Ee(e,d.SPREAD)?function(e){var t=e.token;xe(e,d.SPREAD);var r=Ae(e,"on");if(!r&&Ee(e,d.NAME))return{kind:f.FRAGMENT_SPREAD,name:W(e),directives:ne(e,!1),loc:we(e,t)};return{kind:f.INLINE_FRAGMENT,typeCondition:r?oe(e):void 0,directives:ne(e,!1),selectionSet:X(e),loc:we(e,t)}}(e):function(e){var t,r,n=e.token,i=F(e);Te(e,d.COLON)?(t=i,r=F(e)):r=i;return{kind:f.FIELD,alias:t,name:r,arguments:J(e,!1),directives:ne(e,!1),selectionSet:Ee(e,d.BRACE_L)?X(e):void 0,loc:we(e,n)}}(e)}function J(e,t){var r=t?K:Y;return Ee(e,d.PAREN_L)?Re(e,d.PAREN_L,r,d.PAREN_R):[]}function Y(e){var t=e.token,r=F(e);return xe(e,d.COLON),{kind:f.ARGUMENT,name:r,value:Z(e,!1),loc:we(e,t)}}function K(e){var t=e.token;return{kind:f.ARGUMENT,name:F(e),value:(xe(e,d.COLON),te(e)),loc:we(e,t)}}function W(e){if("on"===e.token.value)throw Ie(e);return F(e)}function Z(e,t){var r=e.token;switch(r.kind){case d.BRACKET_L:return function(e,t){var r=e.token,n=t?te:re;return{kind:f.LIST,values:Ne(e,d.BRACKET_L,n,d.BRACKET_R),loc:we(e,r)}}(e,t);case d.BRACE_L:return function(e,t){var r=e.token;return{kind:f.OBJECT,fields:Ne(e,d.BRACE_L,function(){return function(e,t){var r=e.token,n=F(e);return xe(e,d.COLON),{kind:f.OBJECT_FIELD,name:n,value:Z(e,t),loc:we(e,r)}}(e,t)},d.BRACE_R),loc:we(e,r)}}(e,t);case d.INT:return e.advance(),{kind:f.INT,value:r.value,loc:we(e,r)};case d.FLOAT:return e.advance(),{kind:f.FLOAT,value:r.value,loc:we(e,r)};case d.STRING:case d.BLOCK_STRING:return ee(e);case d.NAME:return"true"===r.value||"false"===r.value?(e.advance(),{kind:f.BOOLEAN,value:"true"===r.value,loc:we(e,r)}):"null"===r.value?(e.advance(),{kind:f.NULL,loc:we(e,r)}):(e.advance(),{kind:f.ENUM,value:r.value,loc:we(e,r)});case d.DOLLAR:if(!t)return Q(e)}throw Ie(e)}function ee(e){var t=e.token;return e.advance(),{kind:f.STRING,value:t.value,block:t.kind===d.BLOCK_STRING,loc:we(e,t)}}function te(e){return Z(e,!0)}function re(e){return Z(e,!1)}function ne(e,t){for(var r=[];Ee(e,d.AT);)r.push(ie(e,t));return r}function ie(e,t){var r=e.token;return xe(e,d.AT),{kind:f.DIRECTIVE,name:F(e),arguments:J(e,t),loc:we(e,r)}}function ae(e){var t,r=e.token;return Te(e,d.BRACKET_L)?(t=ae(e),xe(e,d.BRACKET_R),t={kind:f.LIST_TYPE,type:t,loc:we(e,r)}):t=oe(e),Te(e,d.BANG)?{kind:f.NON_NULL_TYPE,type:t,loc:we(e,r)}:t}function oe(e){var t=e.token;return{kind:f.NAMED_TYPE,name:F(e),loc:we(e,t)}}function se(e){var t=ce(e)?e.lookahead():e.token;if(t.kind===d.NAME)switch(t.value){case"schema":return function(e){var t=e.token;Oe(e,"schema");var r=ne(e,!0),n=Re(e,d.BRACE_L,le,d.BRACE_R);return{kind:f.SCHEMA_DEFINITION,directives:r,operationTypes:n,loc:we(e,t)}}(e);case"scalar":return function(e){var t=e.token,r=ue(e);Oe(e,"scalar");var n=F(e),i=ne(e,!0);return{kind:f.SCALAR_TYPE_DEFINITION,description:r,name:n,directives:i,loc:we(e,t)}}(e);case"type":return function(e){var t=e.token,r=ue(e);Oe(e,"type");var n=F(e),i=fe(e),a=ne(e,!0),o=de(e);return{kind:f.OBJECT_TYPE_DEFINITION,description:r,name:n,interfaces:i,directives:a,fields:o,loc:we(e,t)}}(e);case"interface":return function(e){var t=e.token,r=ue(e);Oe(e,"interface");var n=F(e),i=ne(e,!0),a=de(e);return{kind:f.INTERFACE_TYPE_DEFINITION,description:r,name:n,directives:i,fields:a,loc:we(e,t)}}(e);case"union":return function(e){var t=e.token,r=ue(e);Oe(e,"union");var n=F(e),i=ne(e,!0),a=me(e);return{kind:f.UNION_TYPE_DEFINITION,description:r,name:n,directives:i,types:a,loc:we(e,t)}}(e);case"enum":return function(e){var t=e.token,r=ue(e);Oe(e,"enum");var n=F(e),i=ne(e,!0),a=ge(e);return{kind:f.ENUM_TYPE_DEFINITION,description:r,name:n,directives:i,values:a,loc:we(e,t)}}(e);case"input":return function(e){var t=e.token,r=ue(e);Oe(e,"input");var n=F(e),i=ne(e,!0),a=ve(e);return{kind:f.INPUT_OBJECT_TYPE_DEFINITION,description:r,name:n,directives:i,fields:a,loc:we(e,t)}}(e);case"directive":return function(e){var t=e.token,r=ue(e);Oe(e,"directive"),xe(e,d.AT);var n=F(e),i=pe(e),a=Ae(e,"repeatable");Oe(e,"on");var o=function(e){Te(e,d.PIPE);var t=[];do{t.push(_e(e))}while(Te(e,d.PIPE));return t}(e);return{kind:f.DIRECTIVE_DEFINITION,description:r,name:n,arguments:i,repeatable:a,locations:o,loc:we(e,t)}}(e)}throw Ie(e,t)}function ce(e){return Ee(e,d.STRING)||Ee(e,d.BLOCK_STRING)}function ue(e){if(ce(e))return ee(e)}function le(e){var t=e.token,r=H(e);xe(e,d.COLON);var n=oe(e);return{kind:f.OPERATION_TYPE_DEFINITION,operation:r,type:n,loc:we(e,t)}}function fe(e){var t=[];if(Ae(e,"implements")){Te(e,d.AMP);do{t.push(oe(e))}while(Te(e,d.AMP)||e.options.allowLegacySDLImplementsInterfaces&&Ee(e,d.NAME))}return t}function de(e){return e.options.allowLegacySDLEmptyFields&&Ee(e,d.BRACE_L)&&e.lookahead().kind===d.BRACE_R?(e.advance(),e.advance(),[]):Ee(e,d.BRACE_L)?Re(e,d.BRACE_L,he,d.BRACE_R):[]}function he(e){var t=e.token,r=ue(e),n=F(e),i=pe(e);xe(e,d.COLON);var a=ae(e),o=ne(e,!0);return{kind:f.FIELD_DEFINITION,description:r,name:n,arguments:i,type:a,directives:o,loc:we(e,t)}}function pe(e){return Ee(e,d.PAREN_L)?Re(e,d.PAREN_L,ye,d.PAREN_R):[]}function ye(e){var t=e.token,r=ue(e),n=F(e);xe(e,d.COLON);var i,a=ae(e);Te(e,d.EQUALS)&&(i=te(e));var o=ne(e,!0);return{kind:f.INPUT_VALUE_DEFINITION,description:r,name:n,type:a,defaultValue:i,directives:o,loc:we(e,t)}}function me(e){var t=[];if(Te(e,d.EQUALS)){Te(e,d.PIPE);do{t.push(oe(e))}while(Te(e,d.PIPE))}return t}function ge(e){return Ee(e,d.BRACE_L)?Re(e,d.BRACE_L,be,d.BRACE_R):[]}function be(e){var t=e.token,r=ue(e),n=F(e),i=ne(e,!0);return{kind:f.ENUM_VALUE_DEFINITION,description:r,name:n,directives:i,loc:we(e,t)}}function ve(e){return Ee(e,d.BRACE_L)?Re(e,d.BRACE_L,ye,d.BRACE_R):[]}function _e(e){var t=e.token,r=F(e);if(void 0!==C[r.value])return r;throw Ie(e,t)}function we(e,t){if(!e.options.noLocation)return new Se(t,e.lastToken,e.source)}function Se(e,t,r){this.start=e.start,this.end=t.end,this.startToken=e,this.endToken=t,this.source=r}function Ee(e,t){return e.token.kind===t}function xe(e,t){var r=e.token;if(r.kind===t)return e.advance(),r;throw g(e.source,r.start,"Expected ".concat(t,", found ").concat(x(r)))}function Te(e,t){var r=e.token;if(r.kind===t)return e.advance(),r}function Oe(e,t){var r=e.token;if(r.kind!==d.NAME||r.value!==t)throw g(e.source,r.start,'Expected "'.concat(t,'", found ').concat(x(r)));e.advance()}function Ae(e,t){var r=e.token;return r.kind===d.NAME&&r.value===t&&(e.advance(),!0)}function Ie(e,t){var r=t||e.token;return g(e.source,r.start,"Unexpected ".concat(x(r)))}function Ne(e,t,r,n){xe(e,t);for(var i=[];!Te(e,n);)i.push(r(e));return i}function Re(e,t,r,n){xe(e,t);for(var i=[r(e)];!Te(e,n);)i.push(r(e));return i}p(Se,function(){return{start:this.start,end:this.end}});var ke={Name:[],Document:["definitions"],OperationDefinition:["name","variableDefinitions","directives","selectionSet"],VariableDefinition:["variable","type","defaultValue","directives"],Variable:["name"],SelectionSet:["selections"],Field:["alias","name","arguments","directives","selectionSet"],Argument:["name","value"],FragmentSpread:["name","directives"],InlineFragment:["typeCondition","directives","selectionSet"],FragmentDefinition:["name","variableDefinitions","typeCondition","directives","selectionSet"],IntValue:[],FloatValue:[],StringValue:[],BooleanValue:[],NullValue:[],EnumValue:[],ListValue:["values"],ObjectValue:["fields"],ObjectField:["name","value"],Directive:["name","arguments"],NamedType:["name"],ListType:["type"],NonNullType:["type"],SchemaDefinition:["directives","operationTypes"],OperationTypeDefinition:["type"],ScalarTypeDefinition:["description","name","directives"],ObjectTypeDefinition:["description","name","interfaces","directives","fields"],FieldDefinition:["description","name","arguments","type","directives"],InputValueDefinition:["description","name","type","defaultValue","directives"],InterfaceTypeDefinition:["description","name","directives","fields"],UnionTypeDefinition:["description","name","directives","types"],EnumTypeDefinition:["description","name","directives","values"],EnumValueDefinition:["description","name","directives"],InputObjectTypeDefinition:["description","name","directives","fields"],DirectiveDefinition:["description","name","arguments","locations"],SchemaExtension:["directives","operationTypes"],ScalarTypeExtension:["name","directives"],ObjectTypeExtension:["name","interfaces","directives","fields"],InterfaceTypeExtension:["name","directives","fields"],UnionTypeExtension:["name","directives","types"],EnumTypeExtension:["name","directives","values"],InputObjectTypeExtension:["name","directives","fields"]},Pe=Object.freeze({});function je(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:ke,n=void 0,i=Array.isArray(e),a=[e],o=-1,s=[],c=void 0,u=void 0,l=void 0,f=[],d=[],h=e;do{var p=++o===a.length,y=p&&0!==s.length;if(p){if(u=0===d.length?void 0:f[f.length-1],c=l,l=d.pop(),y){if(i)c=c.slice();else{for(var m={},g=0,b=Object.keys(c);g<b.length;g++){var v=b[g];m[v]=c[v]}c=m}for(var _=0,w=0;w<s.length;w++){var S=s[w][0],E=s[w][1];i&&(S-=_),i&&null===E?(c.splice(S,1),_++):c[S]=E}}o=n.index,a=n.keys,s=n.edits,i=n.inArray,n=n.prev}else{if(u=l?i?o:a[o]:void 0,null==(c=l?l[u]:h))continue;l&&f.push(u)}var x=void 0;if(!Array.isArray(c)){if(!De(c))throw new Error("Invalid AST Node: "+j(c));var T=Le(t,c.kind,p);if(T){if((x=T.call(t,c,u,l,f,d))===Pe)break;if(!1===x){if(!p){f.pop();continue}}else if(void 0!==x&&(s.push([u,x]),!p)){if(!De(x)){f.pop();continue}c=x}}}void 0===x&&y&&s.push([u,c]),p?f.pop():(n={inArray:i,index:o,keys:a,edits:s,prev:n},a=(i=Array.isArray(c))?c:r[c.kind]||[],o=-1,s=[],l&&d.push(l),l=c)}while(void 0!==n);return 0!==s.length&&(h=s[s.length-1][1]),h}function De(e){return Boolean(e&&"string"==typeof e.kind)}function Ce(e){var t=new Array(e.length);return{enter:function(r){for(var n=0;n<e.length;n++)if(!t[n]){var i=Le(e[n],r.kind,!1);if(i){var a=i.apply(e[n],arguments);if(!1===a)t[n]=r;else if(a===Pe)t[n]=Pe;else if(void 0!==a)return a}}},leave:function(r){for(var n=0;n<e.length;n++)if(t[n])t[n]===r&&(t[n]=null);else{var i=Le(e[n],r.kind,!0);if(i){var a=i.apply(e[n],arguments);if(a===Pe)t[n]=Pe;else if(void 0!==a&&!1!==a)return a}}}}}function Me(e,t){return{enter:function(r){e.enter(r);var n=Le(t,r.kind,!1);if(n){var i=n.apply(t,arguments);return void 0!==i&&(e.leave(r),De(i)&&e.enter(i)),i}},leave:function(r){var n,i=Le(t,r.kind,!0);return i&&(n=i.apply(t,arguments)),e.leave(r),n}}}function Le(e,t,r){var n=e[t];if(n){if(!r&&"function"==typeof n)return n;var i=r?n.leave:n.enter;if("function"==typeof i)return i}else{var a=r?e.leave:e.enter;if(a){if("function"==typeof a)return a;var o=a[t];if("function"==typeof o)return o}}}function qe(e){return je(e,{leave:Fe})}var Fe={Name:function(e){return e.value},Variable:function(e){return"$"+e.name},Document:function(e){return Ue(e.definitions,"\n\n")+"\n"},OperationDefinition:function(e){var t=e.operation,r=e.name,n=He("(",Ue(e.variableDefinitions,", "),")"),i=Ue(e.directives," "),a=e.selectionSet;return r||i||n||"query"!==t?Ue([t,Ue([r,n]),i,a]," "):a},VariableDefinition:function(e){var t=e.variable,r=e.type,n=e.defaultValue,i=e.directives;return t+": "+r+He(" = ",n)+He(" ",Ue(i," "))},SelectionSet:function(e){return Ve(e.selections)},Field:function(e){var t=e.alias,r=e.name,n=e.arguments,i=e.directives,a=e.selectionSet;return Ue([He("",t,": ")+r+He("(",Ue(n,", "),")"),Ue(i," "),a]," ")},Argument:function(e){return e.name+": "+e.value},FragmentSpread:function(e){return"..."+e.name+He(" ",Ue(e.directives," "))},InlineFragment:function(e){var t=e.typeCondition,r=e.directives,n=e.selectionSet;return Ue(["...",He("on ",t),Ue(r," "),n]," ")},FragmentDefinition:function(e){var t=e.name,r=e.typeCondition,n=e.variableDefinitions,i=e.directives,a=e.selectionSet;return"fragment ".concat(t).concat(He("(",Ue(n,", "),")")," ")+"on ".concat(r," ").concat(He("",Ue(i," ")," "))+a},IntValue:function(e){return e.value},FloatValue:function(e){return e.value},StringValue:function(e,t){var r=e.value;return e.block?function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",r=arguments.length>2&&void 0!==arguments[2]&&arguments[2],n=-1===e.indexOf("\n"),i=" "===e[0]||"\t"===e[0],a='"'===e[e.length-1],o=!n||a||r,s="";return!o||n&&i||(s+="\n"+t),s+=t?e.replace(/\n/g,"\n"+t):e,o&&(s+="\n"),'"""'+s.replace(/"""/g,'\\"""')+'"""'}(r,"description"===t?"":" "):JSON.stringify(r)},BooleanValue:function(e){return e.value?"true":"false"},NullValue:function(){return"null"},EnumValue:function(e){return e.value},ListValue:function(e){return"["+Ue(e.values,", ")+"]"},ObjectValue:function(e){return"{"+Ue(e.fields,", ")+"}"},ObjectField:function(e){return e.name+": "+e.value},Directive:function(e){return"@"+e.name+He("(",Ue(e.arguments,", "),")")},NamedType:function(e){return e.name},ListType:function(e){return"["+e.type+"]"},NonNullType:function(e){return e.type+"!"},SchemaDefinition:function(e){var t=e.directives,r=e.operationTypes;return Ue(["schema",Ue(t," "),Ve(r)]," ")},OperationTypeDefinition:function(e){return e.operation+": "+e.type},ScalarTypeDefinition:Be(function(e){return Ue(["scalar",e.name,Ue(e.directives," ")]," ")}),ObjectTypeDefinition:Be(function(e){var t=e.name,r=e.interfaces,n=e.directives,i=e.fields;return Ue(["type",t,He("implements ",Ue(r," & ")),Ue(n," "),Ve(i)]," ")}),FieldDefinition:Be(function(e){var t=e.name,r=e.arguments,n=e.type,i=e.directives;return t+(Qe(r)?He("(\n",ze(Ue(r,"\n")),"\n)"):He("(",Ue(r,", "),")"))+": "+n+He(" ",Ue(i," "))}),InputValueDefinition:Be(function(e){var t=e.name,r=e.type,n=e.defaultValue,i=e.directives;return Ue([t+": "+r,He("= ",n),Ue(i," ")]," ")}),InterfaceTypeDefinition:Be(function(e){var t=e.name,r=e.directives,n=e.fields;return Ue(["interface",t,Ue(r," "),Ve(n)]," ")}),UnionTypeDefinition:Be(function(e){var t=e.name,r=e.directives,n=e.types;return Ue(["union",t,Ue(r," "),n&&0!==n.length?"= "+Ue(n," | "):""]," ")}),EnumTypeDefinition:Be(function(e){var t=e.name,r=e.directives,n=e.values;return Ue(["enum",t,Ue(r," "),Ve(n)]," ")}),EnumValueDefinition:Be(function(e){return Ue([e.name,Ue(e.directives," ")]," ")}),InputObjectTypeDefinition:Be(function(e){var t=e.name,r=e.directives,n=e.fields;return Ue(["input",t,Ue(r," "),Ve(n)]," ")}),DirectiveDefinition:Be(function(e){var t=e.name,r=e.arguments,n=e.repeatable,i=e.locations;return"directive @"+t+(Qe(r)?He("(\n",ze(Ue(r,"\n")),"\n)"):He("(",Ue(r,", "),")"))+(n?" repeatable":"")+" on "+Ue(i," | ")}),SchemaExtension:function(e){var t=e.directives,r=e.operationTypes;return Ue(["extend schema",Ue(t," "),Ve(r)]," ")},ScalarTypeExtension:function(e){return Ue(["extend scalar",e.name,Ue(e.directives," ")]," ")},ObjectTypeExtension:function(e){var t=e.name,r=e.interfaces,n=e.directives,i=e.fields;return Ue(["extend type",t,He("implements ",Ue(r," & ")),Ue(n," "),Ve(i)]," ")},InterfaceTypeExtension:function(e){var t=e.name,r=e.directives,n=e.fields;return Ue(["extend interface",t,Ue(r," "),Ve(n)]," ")},UnionTypeExtension:function(e){var t=e.name,r=e.directives,n=e.types;return Ue(["extend union",t,Ue(r," "),n&&0!==n.length?"= "+Ue(n," | "):""]," ")},EnumTypeExtension:function(e){var t=e.name,r=e.directives,n=e.values;return Ue(["extend enum",t,Ue(r," "),Ve(n)]," ")},InputObjectTypeExtension:function(e){var t=e.name,r=e.directives,n=e.fields;return Ue(["extend input",t,Ue(r," "),Ve(n)]," ")}};function Be(e){return function(t){return Ue([t.description,e(t)],"\n")}}function Ue(e,t){return e?e.filter(function(e){return e}).join(t||""):""}function Ve(e){return e&&0!==e.length?"{\n"+ze(Ue(e,"\n"))+"\n}":""}function He(e,t,r){return t?e+t+(r||""):""}function ze(e){return e&&" "+e.replace(/\n/g,"\n ")}function Ge(e){return-1!==e.indexOf("\n")}function Qe(e){return e&&e.some(Ge)}function Xe(e){return $e(e)||We(e)||et(e)}function $e(e){return e.kind===f.OPERATION_DEFINITION||e.kind===f.FRAGMENT_DEFINITION}function Je(e){return e.kind===f.FIELD||e.kind===f.FRAGMENT_SPREAD||e.kind===f.INLINE_FRAGMENT}function Ye(e){return e.kind===f.VARIABLE||e.kind===f.INT||e.kind===f.FLOAT||e.kind===f.STRING||e.kind===f.BOOLEAN||e.kind===f.NULL||e.kind===f.ENUM||e.kind===f.LIST||e.kind===f.OBJECT}function Ke(e){return e.kind===f.NAMED_TYPE||e.kind===f.LIST_TYPE||e.kind===f.NON_NULL_TYPE}function We(e){return e.kind===f.SCHEMA_DEFINITION||Ze(e)||e.kind===f.DIRECTIVE_DEFINITION}function Ze(e){return e.kind===f.SCALAR_TYPE_DEFINITION||e.kind===f.OBJECT_TYPE_DEFINITION||e.kind===f.INTERFACE_TYPE_DEFINITION||e.kind===f.UNION_TYPE_DEFINITION||e.kind===f.ENUM_TYPE_DEFINITION||e.kind===f.INPUT_OBJECT_TYPE_DEFINITION}function et(e){return e.kind===f.SCHEMA_EXTENSION||tt(e)}function tt(e){return e.kind===f.SCALAR_TYPE_EXTENSION||e.kind===f.OBJECT_TYPE_EXTENSION||e.kind===f.INTERFACE_TYPE_EXTENSION||e.kind===f.UNION_TYPE_EXTENSION||e.kind===f.ENUM_TYPE_EXTENSION||e.kind===f.INPUT_OBJECT_TYPE_EXTENSION}r.d(t,"Source",function(){return a}),r.d(t,"getLocation",function(){return o}),r.d(t,"printLocation",function(){return s}),r.d(t,"printSourceLocation",function(){return c}),r.d(t,"Kind",function(){return f}),r.d(t,"TokenKind",function(){return d}),r.d(t,"createLexer",function(){return w}),r.d(t,"parse",function(){return M}),r.d(t,"parseValue",function(){return L}),r.d(t,"parseType",function(){return q}),r.d(t,"print",function(){return qe}),r.d(t,"visit",function(){return je}),r.d(t,"visitInParallel",function(){return Ce}),r.d(t,"visitWithTypeInfo",function(){return Me}),r.d(t,"getVisitFn",function(){return Le}),r.d(t,"BREAK",function(){return Pe}),r.d(t,"isDefinitionNode",function(){return Xe}),r.d(t,"isExecutableDefinitionNode",function(){return $e}),r.d(t,"isSelectionNode",function(){return Je}),r.d(t,"isValueNode",function(){return Ye}),r.d(t,"isTypeNode",function(){return Ke}),r.d(t,"isTypeSystemDefinitionNode",function(){return We}),r.d(t,"isTypeDefinitionNode",function(){return Ze}),r.d(t,"isTypeSystemExtensionNode",function(){return et}),r.d(t,"isTypeExtensionNode",function(){return tt}),r.d(t,"DirectiveLocation",function(){return C})},function(e,t,r){"use strict";r.r(t);var n=r(14),i=r(36);var a=r(5);function o(e){return new u(e)}function s(e){return function(){return new c(e.apply(this,arguments))}}function c(e){var t,r;function n(t,r){try{var a=e[t](r),o=a.value,s=o instanceof u;Promise.resolve(s?o.wrapped:o).then(function(e){s?n("next",e):i(a.done?"return":"normal",e)},function(e){n("throw",e)})}catch(e){i("throw",e)}}function i(e,i){switch(e){case"return":t.resolve({value:i,done:!0});break;case"throw":t.reject(i);break;default:t.resolve({value:i,done:!1})}(t=t.next)?n(t.key,t.arg):r=null}this._invoke=function(e,i){return new Promise(function(a,o){var s={key:e,arg:i,resolve:a,reject:o,next:null};r?r=r.next=s:(t=r=s,n(e,i))})},"function"!=typeof e.return&&(this.return=void 0)}function u(e){this.wrapped=e}function l(e){var t;if("undefined"!=typeof Symbol){if(Symbol.asyncIterator&&null!=(t=e[Symbol.asyncIterator]))return t.call(e);if(Symbol.iterator&&null!=(t=e[Symbol.iterator]))return t.call(e)}throw new TypeError("Object is not async iterable")}"function"==typeof Symbol&&Symbol.asyncIterator&&(c.prototype[Symbol.asyncIterator]=function(){return this}),c.prototype.next=function(e){return this._invoke("next",e)},c.prototype.throw=function(e){return this._invoke("throw",e)},c.prototype.return=function(e){return this._invoke("return",e)};const{as:f}=i["@context"];class d{constructor(){let{activitiesPath:e="/public/activities"}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};var t,r,n;n=!0,(r="requireUser")in(t=this)?Object.defineProperty(t,r,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[r]=n,this.activitiesPath=e}handle(e,t){const r=this,{root:i}=t,{settings:{queryEngine:c}}=e;return function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"".concat(f,"Like");return Object(n.toIterablePromise)(s(function*(){let n;try{n=yield o(i.user)}catch(e){if(r.requireUser)throw e;return}const s=yield o(i.user.pim$storage),u=new URL(r.activitiesPath,s||n).href,f=[],d=Object(a.namedNode)(n);e=Object(a.namedNode)(e);var h,p=!0,y=!1;try{for(var m,g,b=l(t);p=(m=yield o(b.next())).done,g=yield o(m.value),!p;p=!0){const t=g;if("NamedNode"===t.termType){const n={actor:d,type:e,object:t};var v,_=!0,w=!1;try{for(var S,E,x=l(r.createResults(n,u,c));_=(S=yield o(x.next())).done,E=yield o(S.value),!_;_=!0){const e=E;f.push(e)}}catch(e){w=!0,v=e}finally{try{_||null==x.return||(yield o(x.return()))}finally{if(w)throw v}}}}}catch(e){y=!0,h=e}finally{try{p||null==b.return||(yield o(b.return()))}finally{if(y)throw h}}for(const e of yield o(r.processResults(f,u,c)))yield i[e.value]}))}}async processResults(e){return e}}const{termToString:h}=n.SparqlHandler.prototype;function p(e,t){for(const r in t)e=e.replace(new RegExp("_:".concat(r),"g"),h(t[r]));return e}function y(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];return{size:t.length,values:()=>({next:()=>({value:t.shift()})})}}function m(e){return new b(e)}function g(e){var t,r;function n(t,r){try{var a=e[t](r),o=a.value,s=o instanceof b;Promise.resolve(s?o.wrapped:o).then(function(e){s?n("next",e):i(a.done?"return":"normal",e)},function(e){n("throw",e)})}catch(e){i("throw",e)}}function i(e,i){switch(e){case"return":t.resolve({value:i,done:!0});break;case"throw":t.reject(i);break;default:t.resolve({value:i,done:!1})}(t=t.next)?n(t.key,t.arg):r=null}this._invoke=function(e,i){return new Promise(function(a,o){var s={key:e,arg:i,resolve:a,reject:o,next:null};r?r=r.next=s:(t=r=s,n(e,i))})},"function"!=typeof e.return&&(this.return=void 0)}function b(e){this.wrapped=e}"function"==typeof Symbol&&Symbol.asyncIterator&&(g.prototype[Symbol.asyncIterator]=function(){return this}),g.prototype.next=function(e){return this._invoke("next",e)},g.prototype.throw=function(e){return this._invoke("throw",e)},g.prototype.return=function(e){return this._invoke("return",e)};const v="SELECT ?activity WHERE {\n ?activity a _:type;\n <https://www.w3.org/ns/activitystreams#actor> _:actor;\n <https://www.w3.org/ns/activitystreams#object> _:object.\n}\n";var _=r(114),w=r.n(_);function S(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function E(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function x(e){var t,r;function n(t,r){try{var a=e[t](r),o=a.value,s=o instanceof T;Promise.resolve(s?o.wrapped:o).then(function(e){s?n("next",e):i(a.done?"return":"normal",e)},function(e){n("throw",e)})}catch(e){i("throw",e)}}function i(e,i){switch(e){case"return":t.resolve({value:i,done:!0});break;case"throw":t.reject(i);break;default:t.resolve({value:i,done:!1})}(t=t.next)?n(t.key,t.arg):r=null}this._invoke=function(e,i){return new Promise(function(a,o){var s={key:e,arg:i,resolve:a,reject:o,next:null};r?r=r.next=s:(t=r=s,n(e,i))})},"function"!=typeof e.return&&(this.return=void 0)}function T(e){this.wrapped=e}"function"==typeof Symbol&&Symbol.asyncIterator&&(x.prototype[Symbol.asyncIterator]=function(){return this}),x.prototype.next=function(e){return this._invoke("next",e)},x.prototype.throw=function(e){return this._invoke("throw",e)},x.prototype.return=function(e){return this._invoke("return",e)};const O="_:id a _:type;\n <https://www.w3.org/ns/activitystreams#actor> _:actor;\n <https://www.w3.org/ns/activitystreams#object> _:object;\n <https://www.w3.org/ns/activitystreams#published> _:published.\n",{xsd:A}=i["@context"];function I(e){return new R(e)}function N(e){var t,r;function n(t,r){try{var a=e[t](r),o=a.value,s=o instanceof R;Promise.resolve(s?o.wrapped:o).then(function(e){s?n("next",e):i(a.done?"return":"normal",e)},function(e){n("throw",e)})}catch(e){i("throw",e)}}function i(e,i){switch(e){case"return":t.resolve({value:i,done:!0});break;case"throw":t.reject(i);break;default:t.resolve({value:i,done:!1})}(t=t.next)?n(t.key,t.arg):r=null}this._invoke=function(e,i){return new Promise(function(a,o){var s={key:e,arg:i,resolve:a,reject:o,next:null};r?r=r.next=s:(t=r=s,n(e,i))})},"function"!=typeof e.return&&(this.return=void 0)}function R(e){this.wrapped=e}"function"==typeof Symbol&&Symbol.asyncIterator&&(N.prototype[Symbol.asyncIterator]=function(){return this}),N.prototype.next=function(e){return this._invoke("next",e)},N.prototype.throw=function(e){return this._invoke("throw",e)},N.prototype.return=function(e){return this._invoke("return",e)};const k="SELECT ?subject ?predicate ?object WHERE {\n ?subject a _:type;\n <https://www.w3.org/ns/activitystreams#actor> _:actor;\n <https://www.w3.org/ns/activitystreams#object> _:object.\n ?subject ?predicate ?object.\n}\n",P=["?subject","?predicate","?object"];var j=r(301),D=r.n(j),C=r(63),M=r.n(C);class L extends D.a{executeUpdate(e,t){let r=!1;return{next:async()=>{if(r)return{done:r};r=!0;const n=await(t?this.toComunicaSources(t):this._sources);if(!n||1!==n.length)throw new Error("Can only update a single source.");const[{value:i}]=n;if(!/^https?:\/\//.test(i))throw new Error("Can only update an HTTP(s) document.");const{ok:a,status:o,statusText:s}=await M.a.fetch(i,{method:"PATCH",headers:{"Content-Type":"application/sparql-update"},body:e});if(!a)throw new Error("Update query failed (".concat(o,"): ").concat(s));return await this.clearCache(i),{value:y({ok:a})}},[Symbol.asyncIterator](){return this}}}async clearCache(e){await this._engine.invalidateHttpCache(e)}}class q{constructor(e,t){this._paths=e,this._source=t}supports(e){return"string"==typeof e}resolve(e){return this._createSubjectPath(Object(a.namedNode)(e))}_createSubjectPath(e){const t=this._source||Promise.resolve(e).catch(()=>null),r=new L(t);return this._paths.create({queryEngine:r},{subject:e})}}function F(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function B(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?F(r,!0).forEach(function(t){U(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):F(r).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}function U(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function V(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function H(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?V(r,!0).forEach(function(t){z(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):V(r).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}function z(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const{as:G}=i["@context"],Q=new class extends n.JSONLDResolver{constructor(e){var t;super(e),t=this;const r=this._exposedContext=Object.create(e["@context"]);Object.defineProperty(r,"extend",{value:function(){return t.extendContext(...arguments)}}),Object.defineProperty(r,"then",{value:(e,t)=>this._context.then(e,t)})}handle(){return this._exposedContext}}(i);let X;const $=new n.PathFactory({handlers:H({},n.defaultHandlers,{delete:new class extends n.DeleteFunctionHandler{async extractObjects(e,t,r){const n=await super.extractObjects(e,t,r),i=[];var a,o=!0,s=!1;try{for(var c,u,l=function(e){var t;if("undefined"!=typeof Symbol){if(Symbol.asyncIterator&&null!=(t=e[Symbol.asyncIterator]))return t.call(e);if(Symbol.iterator&&null!=(t=e[Symbol.iterator]))return t.call(e)}throw new TypeError("Object is not async iterable")}(t);o=(c=await l.next()).done,u=await c.value,!o;o=!0){const e=u;"BlankNode"!==e.termType&&i.push(e)}}catch(e){s=!0,a=e}finally{try{o||null==l.return||await l.return()}finally{if(s)throw a}}return n?i.filter(e=>n.some(t=>t.equals(e))):i}},findActivity:new class extends d{constructor(){var e,t,r;super(...arguments),r=!1,(t="requireUser")in(e=this)?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r}createResults(e,t,r){return(n=function*(){const n=p(v,e);var i,a=!0,o=!1;try{for(var s,c,u=function(e){var t;if("undefined"!=typeof Symbol){if(Symbol.asyncIterator&&null!=(t=e[Symbol.asyncIterator]))return t.call(e);if(Symbol.iterator&&null!=(t=e[Symbol.iterator]))return t.call(e)}throw new TypeError("Object is not async iterable")}(r.execute(n,t));a=(s=yield m(u.next())).done,c=yield m(s.value),!a;a=!0){const e=c;yield e.values().next().value}}catch(e){o=!0,i=e}finally{try{a||null==u.return||(yield m(u.return()))}finally{if(o)throw i}}},function(){return new g(n.apply(this,arguments))})();var n}},likes:(e,t)=>t.findActivity("".concat(G,"Like")),dislikes:(e,t)=>t.findActivity("".concat(G,"Dislike")),follows:(e,t)=>t.findActivity("".concat(G,"Follow")),createActivity:new class extends d{createResults(e,t){return(r=function*(){const r=Object(a.namedNode)(new URL("#".concat(w()()),t).href),n=Object(a.literal)((new Date).toISOString(),"".concat(A,"dateTime"));e=function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?S(r,!0).forEach(function(t){E(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):S(r).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}({id:r,published:n},e);const i=p(O,e);yield{id:r,insert:i}},function(){return new x(r.apply(this,arguments))})();var r}async processResults(e,t,r){const n="INSERT {\n".concat(e.map(e=>e.insert).join(""),"}");return await r.executeUpdate(n,t).next(),e.map(e=>e.id)}},like:(e,t)=>()=>t.createActivity("".concat(G,"Like")),dislike:(e,t)=>()=>t.createActivity("".concat(G,"Dislike")),follow:(e,t)=>()=>t.createActivity("".concat(G,"Follow")),deleteActivity:new class extends d{createResults(e,t,r){return(n=function*(){const n=p(k,e);var i,a=!0,o=!1;try{for(var s,c,u=function(e){var t;if("undefined"!=typeof Symbol){if(Symbol.asyncIterator&&null!=(t=e[Symbol.asyncIterator]))return t.call(e);if(Symbol.iterator&&null!=(t=e[Symbol.iterator]))return t.call(e)}throw new TypeError("Object is not async iterable")}(r.execute(n,t));a=(s=yield I(u.next())).done,c=yield I(s.value),!a;a=!0){const e=c,t=P.map(t=>h(e.get(t)));yield"".concat(t.join(" "),".\n")}}catch(e){o=!0,i=e}finally{try{a||null==u.return||(yield I(u.return()))}finally{if(o)throw i}}},function(){return new N(n.apply(this,arguments))})();var n}async processResults(e,t,r){const n="DELETE {\n".concat(e.join(""),"}");return await r.executeUpdate(n,t).next(),[]}},unlike:(e,t)=>()=>t.deleteActivity("".concat(G,"Like")),undislike:(e,t)=>()=>t.deleteActivity("".concat(G,"Dislike")),unfollow:(e,t)=>()=>t.deleteActivity("".concat(G,"Follow")),root:()=>X}),resolvers:[Q]});t.default=X=new n.PathFactory({handlers:H({},n.defaultHandlers,{from:new class{constructor(e){this._paths=e}handle(){return e=>this._createSourcePathFactory(e)}_createSourcePathFactory(e){return new n.PathFactory({handlers:B({},n.defaultHandlers),resolvers:[new q(this._paths,e)]}).create()}}($),user:new class extends q{handle(){const e=this.getWebId().then(a.namedNode);return this._createSubjectPath(e)}async getWebId(){const e=await M.a.currentSession();if(!e)throw new Error("Cannot resolve user path: no user logged in");return e.webId}}($),clearCache:e=>{let{settings:t}=e;return e=>t.queryEngine.clearCache(e)},context:Q}),resolvers:[new q($)],queryEngine:new L}).create()}]).default;
107//# sourceMappingURL=solid-query-ldflex.bundle.js.map
\No newline at end of file