@code0-tech/tucana 0.0.64 → 0.0.66
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/aquila.cjs.js +1 -0
- package/dist/aquila.d.ts +2 -0
- package/dist/aquila.es.js +942 -0
- package/dist/helpers/helpers.d.ts +1 -0
- package/{helpers → dist/helpers}/shared.struct_helper.d.ts +1 -1
- package/dist/helpers.cjs.js +1 -0
- package/dist/helpers.d.ts +2 -0
- package/dist/helpers.es.js +61 -0
- package/{pb → dist/pb}/_generated/aquila.action_pb.client.d.ts +7 -12
- package/{pb → dist/pb}/_generated/aquila.action_pb.d.ts +5 -14
- package/{pb → dist/pb}/_generated/aquila.data_type_pb.client.d.ts +7 -12
- package/{pb → dist/pb}/_generated/aquila.data_type_pb.d.ts +4 -11
- package/{pb → dist/pb}/_generated/aquila.flow_type_pb.client.d.ts +7 -12
- package/{pb → dist/pb}/_generated/aquila.flow_type_pb.d.ts +4 -11
- package/dist/pb/_generated/aquila.function_pb.client.d.ts +31 -0
- package/dist/pb/_generated/aquila.function_pb.d.ts +54 -0
- package/{pb → dist/pb}/_generated/aquila.runtime_function_pb.client.d.ts +7 -12
- package/{pb → dist/pb}/_generated/aquila.runtime_function_pb.d.ts +4 -11
- package/{pb → dist/pb}/_generated/aquila.runtime_status_pb.client.d.ts +7 -12
- package/{pb → dist/pb}/_generated/aquila.runtime_status_pb.d.ts +4 -12
- package/{pb → dist/pb}/_generated/aquila.runtime_usage_pb.client.d.ts +7 -12
- package/{pb → dist/pb}/_generated/aquila.runtime_usage_pb.d.ts +4 -11
- package/{pb → dist/pb}/_generated/sagittarius.action_configuration_pb.client.d.ts +7 -12
- package/{pb → dist/pb}/_generated/sagittarius.action_configuration_pb.d.ts +4 -11
- package/{pb → dist/pb}/_generated/sagittarius.data_type_pb.client.d.ts +7 -12
- package/{pb → dist/pb}/_generated/sagittarius.data_type_pb.d.ts +4 -11
- package/{pb → dist/pb}/_generated/sagittarius.flow_pb.client.d.ts +7 -12
- package/{pb → dist/pb}/_generated/sagittarius.flow_pb.d.ts +5 -13
- package/{pb → dist/pb}/_generated/sagittarius.flow_type_pb.client.d.ts +7 -12
- package/{pb → dist/pb}/_generated/sagittarius.flow_type_pb.d.ts +4 -11
- package/dist/pb/_generated/sagittarius.function_pb.client.d.ts +31 -0
- package/dist/pb/_generated/sagittarius.function_pb.d.ts +54 -0
- package/{pb → dist/pb}/_generated/sagittarius.ping_pb.client.d.ts +7 -11
- package/{pb → dist/pb}/_generated/sagittarius.ping_pb.d.ts +3 -10
- package/{pb → dist/pb}/_generated/sagittarius.runtime_function_pb.client.d.ts +7 -12
- package/{pb → dist/pb}/_generated/sagittarius.runtime_function_pb.d.ts +4 -11
- package/{pb → dist/pb}/_generated/sagittarius.runtime_status_pb.client.d.ts +7 -12
- package/{pb → dist/pb}/_generated/sagittarius.runtime_status_pb.d.ts +4 -12
- package/{pb → dist/pb}/_generated/sagittarius.runtime_usage_pb.client.d.ts +7 -12
- package/{pb → dist/pb}/_generated/sagittarius.runtime_usage_pb.d.ts +4 -11
- package/dist/pb/_generated/sagittarius.text_execution_pb.client.d.ts +27 -0
- package/{pb → dist/pb}/_generated/sagittarius.text_execution_pb.d.ts +4 -11
- package/{pb → dist/pb}/_generated/shared.action_configuration_pb.d.ts +3 -11
- package/{pb → dist/pb}/_generated/shared.data_type_pb.d.ts +2 -10
- package/{pb → dist/pb}/_generated/shared.flow_definition_pb.d.ts +35 -47
- package/{pb → dist/pb}/_generated/shared.flow_pb.d.ts +12 -24
- package/dist/pb/_generated/shared.function_pb.d.ts +121 -0
- package/{pb → dist/pb}/_generated/shared.runtime_function_pb.d.ts +3 -11
- package/{pb → dist/pb}/_generated/shared.runtime_status_pb.d.ts +52 -32
- package/{pb → dist/pb}/_generated/shared.runtime_usage_pb.d.ts +1 -9
- package/{pb → dist/pb}/_generated/shared.struct_pb.d.ts +17 -52
- package/{pb → dist/pb}/_generated/shared.translation_pb.d.ts +1 -9
- package/dist/pb/aquila.d.ts +14 -0
- package/dist/pb/sagittarius.d.ts +20 -0
- package/dist/pb/shared.d.ts +10 -0
- package/dist/rpc-interceptor-DoXs3DS5.js +52 -0
- package/dist/rpc-interceptor-HyblNryO.cjs +1 -0
- package/dist/sagittarius.cjs.js +1 -0
- package/dist/sagittarius.d.ts +2 -0
- package/dist/sagittarius.es.js +1296 -0
- package/dist/shared.cjs.js +1 -0
- package/dist/shared.d.ts +2 -0
- package/dist/shared.es.js +3 -0
- package/dist/shared.flow_pb-B6NUNPA6.js +717 -0
- package/dist/shared.flow_pb-DxbQUcL4.cjs +1 -0
- package/dist/shared.runtime_usage_pb-aFASLTvC.js +3320 -0
- package/dist/shared.runtime_usage_pb-auJkQYdP.cjs +2 -0
- package/package.json +24 -22
- package/helpers/helpers.d.ts +0 -1
- package/helpers/helpers.js +0 -1
- package/helpers/helpers.ts +0 -1
- package/helpers/shared.struct_helper.js +0 -89
- package/helpers/shared.struct_helper.ts +0 -99
- package/index.js +0 -0
- package/pb/_generated/.gitkeep +0 -0
- package/pb/_generated/aquila.action_pb.client.js +0 -25
- package/pb/_generated/aquila.action_pb.js +0 -468
- package/pb/_generated/aquila.data_type_pb.client.js +0 -23
- package/pb/_generated/aquila.data_type_pb.js +0 -112
- package/pb/_generated/aquila.flow_type_pb.client.js +0 -25
- package/pb/_generated/aquila.flow_type_pb.js +0 -112
- package/pb/_generated/aquila.runtime_function_pb.client.js +0 -25
- package/pb/_generated/aquila.runtime_function_pb.js +0 -112
- package/pb/_generated/aquila.runtime_status_pb.client.js +0 -23
- package/pb/_generated/aquila.runtime_status_pb.js +0 -126
- package/pb/_generated/aquila.runtime_usage_pb.client.js +0 -23
- package/pb/_generated/aquila.runtime_usage_pb.js +0 -112
- package/pb/_generated/sagittarius.action_configuration_pb.client.js +0 -23
- package/pb/_generated/sagittarius.action_configuration_pb.js +0 -120
- package/pb/_generated/sagittarius.data_type_pb.client.js +0 -23
- package/pb/_generated/sagittarius.data_type_pb.js +0 -112
- package/pb/_generated/sagittarius.flow_pb.client.js +0 -23
- package/pb/_generated/sagittarius.flow_pb.js +0 -138
- package/pb/_generated/sagittarius.flow_type_pb.client.js +0 -25
- package/pb/_generated/sagittarius.flow_type_pb.js +0 -112
- package/pb/_generated/sagittarius.ping_pb.client.js +0 -23
- package/pb/_generated/sagittarius.ping_pb.js +0 -64
- package/pb/_generated/sagittarius.runtime_function_pb.client.js +0 -25
- package/pb/_generated/sagittarius.runtime_function_pb.js +0 -112
- package/pb/_generated/sagittarius.runtime_status_pb.client.js +0 -23
- package/pb/_generated/sagittarius.runtime_status_pb.js +0 -126
- package/pb/_generated/sagittarius.runtime_usage_pb.client.js +0 -23
- package/pb/_generated/sagittarius.runtime_usage_pb.js +0 -112
- package/pb/_generated/sagittarius.text_execution_pb.client.d.ts +0 -32
- package/pb/_generated/sagittarius.text_execution_pb.client.js +0 -23
- package/pb/_generated/sagittarius.text_execution_pb.js +0 -568
- package/pb/_generated/shared.action_configuration_pb.js +0 -251
- package/pb/_generated/shared.data_type_pb.js +0 -411
- package/pb/_generated/shared.flow_definition_pb.js +0 -269
- package/pb/_generated/shared.flow_pb.js +0 -762
- package/pb/_generated/shared.runtime_function_pb.js +0 -238
- package/pb/_generated/shared.runtime_status_pb.js +0 -315
- package/pb/_generated/shared.runtime_usage_pb.js +0 -62
- package/pb/_generated/shared.struct_pb.js +0 -334
- package/pb/_generated/shared.translation_pb.js +0 -62
- package/pb/aquila.d.ts +0 -24
- package/pb/aquila.js +0 -24
- package/pb/aquila.ts +0 -24
- package/pb/sagittarius.d.ts +0 -36
- package/pb/sagittarius.js +0 -36
- package/pb/sagittarius.ts +0 -36
- package/pb/shared.d.ts +0 -18
- package/pb/shared.js +0 -18
- package/pb/shared.ts +0 -18
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
function e(e){let t=typeof e;if(t==`object`){if(Array.isArray(e))return`array`;if(e===null)return`null`}return t}function t(e){return typeof e==`object`&&!!e&&!Array.isArray(e)}var n=`ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/`.split(``),r=[];for(let e=0;e<n.length;e++)r[n[e].charCodeAt(0)]=e;r[45]=n.indexOf(`+`),r[95]=n.indexOf(`/`);function i(e){let t=e.length*3/4;e[e.length-2]==`=`?t-=2:e[e.length-1]==`=`&&--t;let n=new Uint8Array(t),i=0,a=0,o,s=0;for(let t=0;t<e.length;t++){if(o=r[e.charCodeAt(t)],o===void 0)switch(e[t]){case`=`:a=0;case`
|
|
2
|
+
`:case`\r`:case` `:case` `:continue;default:throw Error(`invalid base64 string.`)}switch(a){case 0:s=o,a=1;break;case 1:n[i++]=s<<2|(o&48)>>4,s=o,a=2;break;case 2:n[i++]=(s&15)<<4|(o&60)>>2,s=o,a=3;break;case 3:n[i++]=(s&3)<<6|o,a=0;break}}if(a==1)throw Error(`invalid base64 string.`);return n.subarray(0,i)}function a(e){let t=``,r=0,i,a=0;for(let o=0;o<e.length;o++)switch(i=e[o],r){case 0:t+=n[i>>2],a=(i&3)<<4,r=1;break;case 1:t+=n[a|i>>4],a=(i&15)<<2,r=2;break;case 2:t+=n[a|i>>6],t+=n[i&63],r=0;break}return r&&(t+=n[a],t+=`=`,r==1&&(t+=`=`)),t}var o;(function(e){e.symbol=Symbol.for(`protobuf-ts/unknown`),e.onRead=(n,r,i,a,o)=>{(t(r)?r[e.symbol]:r[e.symbol]=[]).push({no:i,wireType:a,data:o})},e.onWrite=(t,n,r)=>{for(let{no:t,wireType:i,data:a}of e.list(n))r.tag(t,i).raw(a)},e.list=(n,r)=>{if(t(n)){let t=n[e.symbol];return r?t.filter(e=>e.no==r):t}return[]},e.last=(t,n)=>e.list(t,n).slice(-1)[0];let t=t=>t&&Array.isArray(t[e.symbol])})(o||={});var s;(function(e){e[e.Varint=0]=`Varint`,e[e.Bit64=1]=`Bit64`,e[e.LengthDelimited=2]=`LengthDelimited`,e[e.StartGroup=3]=`StartGroup`,e[e.EndGroup=4]=`EndGroup`,e[e.Bit32=5]=`Bit32`})(s||={});function c(){let e=0,t=0;for(let n=0;n<28;n+=7){let r=this.buf[this.pos++];if(e|=(r&127)<<n,!(r&128))return this.assertBounds(),[e,t]}let n=this.buf[this.pos++];if(e|=(n&15)<<28,t=(n&112)>>4,!(n&128))return this.assertBounds(),[e,t];for(let n=3;n<=31;n+=7){let r=this.buf[this.pos++];if(t|=(r&127)<<n,!(r&128))return this.assertBounds(),[e,t]}throw Error(`invalid varint`)}function l(e,t,n){for(let r=0;r<28;r+=7){let i=e>>>r,a=!(!(i>>>7)&&t==0),o=(a?i|128:i)&255;if(n.push(o),!a)return}let r=e>>>28&15|(t&7)<<4,i=!!(t>>3);if(n.push((i?r|128:r)&255),i){for(let e=3;e<31;e+=7){let r=t>>>e,i=!!(r>>>7),a=(i?r|128:r)&255;if(n.push(a),!i)return}n.push(t>>>31&1)}}var u=65536*65536;function d(e){let t=e[0]==`-`;t&&(e=e.slice(1));let n=1e6,r=0,i=0;function a(t,a){let o=Number(e.slice(t,a));i*=n,r=r*n+o,r>=u&&(i+=r/u|0,r%=u)}return a(-24,-18),a(-18,-12),a(-12,-6),a(-6),[t,r,i]}function f(e,t){if(t>>>0<=2097151)return``+(u*t+(e>>>0));let n=e&16777215,r=(e>>>24|t<<8)>>>0&16777215,i=t>>16&65535,a=n+r*6777216+i*6710656,o=r+i*8147497,s=i*2,c=1e7;a>=c&&(o+=Math.floor(a/c),a%=c),o>=c&&(s+=Math.floor(o/c),o%=c);function l(e,t){let n=e?String(e):``;return t?`0000000`.slice(n.length)+n:n}return l(s,0)+l(o,s)+l(a,1)}function p(e,t){if(e>=0){for(;e>127;)t.push(e&127|128),e>>>=7;t.push(e)}else{for(let n=0;n<9;n++)t.push(e&127|128),e>>=7;t.push(1)}}function ee(){let e=this.buf[this.pos++],t=e&127;if(!(e&128)||(e=this.buf[this.pos++],t|=(e&127)<<7,!(e&128))||(e=this.buf[this.pos++],t|=(e&127)<<14,!(e&128))||(e=this.buf[this.pos++],t|=(e&127)<<21,!(e&128)))return this.assertBounds(),t;e=this.buf[this.pos++],t|=(e&15)<<28;for(let t=5;e&128&&t<10;t++)e=this.buf[this.pos++];if(e&128)throw Error(`invalid varint`);return this.assertBounds(),t>>>0}var m;function te(){let e=new DataView(new ArrayBuffer(8));m=globalThis.BigInt!==void 0&&typeof e.getBigInt64==`function`&&typeof e.getBigUint64==`function`&&typeof e.setBigInt64==`function`&&typeof e.setBigUint64==`function`?{MIN:BigInt(`-9223372036854775808`),MAX:BigInt(`9223372036854775807`),UMIN:BigInt(`0`),UMAX:BigInt(`18446744073709551615`),C:BigInt,V:e}:void 0}te();function ne(e){if(!e)throw Error(`BigInt unavailable, see https://github.com/timostamm/protobuf-ts/blob/v1.0.8/MANUAL.md#bigint-support`)}var re=/^-?[0-9]+$/,h=4294967296,g=2147483648,_=class{constructor(e,t){this.lo=e|0,this.hi=t|0}isZero(){return this.lo==0&&this.hi==0}toNumber(){let e=this.hi*h+(this.lo>>>0);if(!Number.isSafeInteger(e))throw Error(`cannot convert to safe number`);return e}},v=class e extends _{static from(t){if(m)switch(typeof t){case`string`:if(t==`0`)return this.ZERO;if(t==``)throw Error(`string is no integer`);t=m.C(t);case`number`:if(t===0)return this.ZERO;t=m.C(t);case`bigint`:if(!t)return this.ZERO;if(t<m.UMIN)throw Error(`signed value for ulong`);if(t>m.UMAX)throw Error(`ulong too large`);return m.V.setBigUint64(0,t,!0),new e(m.V.getInt32(0,!0),m.V.getInt32(4,!0))}else switch(typeof t){case`string`:if(t==`0`)return this.ZERO;if(t=t.trim(),!re.test(t))throw Error(`string is no integer`);let[n,r,i]=d(t);if(n)throw Error(`signed value for ulong`);return new e(r,i);case`number`:if(t==0)return this.ZERO;if(!Number.isSafeInteger(t))throw Error(`number is no integer`);if(t<0)throw Error(`signed value for ulong`);return new e(t,t/h)}throw Error(`unknown value `+typeof t)}toString(){return m?this.toBigInt().toString():f(this.lo,this.hi)}toBigInt(){return ne(m),m.V.setInt32(0,this.lo,!0),m.V.setInt32(4,this.hi,!0),m.V.getBigUint64(0,!0)}};v.ZERO=new v(0,0);var y=class e extends _{static from(t){if(m)switch(typeof t){case`string`:if(t==`0`)return this.ZERO;if(t==``)throw Error(`string is no integer`);t=m.C(t);case`number`:if(t===0)return this.ZERO;t=m.C(t);case`bigint`:if(!t)return this.ZERO;if(t<m.MIN)throw Error(`signed long too small`);if(t>m.MAX)throw Error(`signed long too large`);return m.V.setBigInt64(0,t,!0),new e(m.V.getInt32(0,!0),m.V.getInt32(4,!0))}else switch(typeof t){case`string`:if(t==`0`)return this.ZERO;if(t=t.trim(),!re.test(t))throw Error(`string is no integer`);let[n,r,i]=d(t);if(n){if(i>g||i==g&&r!=0)throw Error(`signed long too small`)}else if(i>=g)throw Error(`signed long too large`);let a=new e(r,i);return n?a.negate():a;case`number`:if(t==0)return this.ZERO;if(!Number.isSafeInteger(t))throw Error(`number is no integer`);return t>0?new e(t,t/h):new e(-t,-t/h).negate()}throw Error(`unknown value `+typeof t)}isNegative(){return(this.hi&g)!==0}negate(){let t=~this.hi,n=this.lo;return n?n=~n+1:t+=1,new e(n,t)}toString(){if(m)return this.toBigInt().toString();if(this.isNegative()){let e=this.negate();return`-`+f(e.lo,e.hi)}return f(this.lo,this.hi)}toBigInt(){return ne(m),m.V.setInt32(0,this.lo,!0),m.V.setInt32(4,this.hi,!0),m.V.getBigInt64(0,!0)}};y.ZERO=new y(0,0);var b={readUnknownField:!0,readerFactory:e=>new ae(e)};function ie(e){return e?Object.assign(Object.assign({},b),e):b}var ae=class{constructor(e,t){this.varint64=c,this.uint32=ee,this.buf=e,this.len=e.length,this.pos=0,this.view=new DataView(e.buffer,e.byteOffset,e.byteLength),this.textDecoder=t??new TextDecoder(`utf-8`,{fatal:!0,ignoreBOM:!0})}tag(){let e=this.uint32(),t=e>>>3,n=e&7;if(t<=0||n<0||n>5)throw Error(`illegal tag: field no `+t+` wire type `+n);return[t,n]}skip(e){let t=this.pos;switch(e){case s.Varint:for(;this.buf[this.pos++]&128;);break;case s.Bit64:this.pos+=4;case s.Bit32:this.pos+=4;break;case s.LengthDelimited:let t=this.uint32();this.pos+=t;break;case s.StartGroup:let n;for(;(n=this.tag()[1])!==s.EndGroup;)this.skip(n);break;default:throw Error(`cant skip wire type `+e)}return this.assertBounds(),this.buf.subarray(t,this.pos)}assertBounds(){if(this.pos>this.len)throw RangeError(`premature EOF`)}int32(){return this.uint32()|0}sint32(){let e=this.uint32();return e>>>1^-(e&1)}int64(){return new y(...this.varint64())}uint64(){return new v(...this.varint64())}sint64(){let[e,t]=this.varint64(),n=-(e&1);return e=(e>>>1|(t&1)<<31)^n,t=t>>>1^n,new y(e,t)}bool(){let[e,t]=this.varint64();return e!==0||t!==0}fixed32(){return this.view.getUint32((this.pos+=4)-4,!0)}sfixed32(){return this.view.getInt32((this.pos+=4)-4,!0)}fixed64(){return new v(this.sfixed32(),this.sfixed32())}sfixed64(){return new y(this.sfixed32(),this.sfixed32())}float(){return this.view.getFloat32((this.pos+=4)-4,!0)}double(){return this.view.getFloat64((this.pos+=8)-8,!0)}bytes(){let e=this.uint32(),t=this.pos;return this.pos+=e,this.assertBounds(),this.buf.subarray(t,t+e)}string(){return this.textDecoder.decode(this.bytes())}};function x(e,t){if(!e)throw Error(t)}function oe(e,t){throw Error(t??`Unexpected object: `+e)}var se=34028234663852886e22,ce=-34028234663852886e22,le=4294967295,ue=2147483647,de=-2147483648;function S(e){if(typeof e!=`number`)throw Error(`invalid int 32: `+typeof e);if(!Number.isInteger(e)||e>ue||e<de)throw Error(`invalid int 32: `+e)}function C(e){if(typeof e!=`number`)throw Error(`invalid uint 32: `+typeof e);if(!Number.isInteger(e)||e>le||e<0)throw Error(`invalid uint 32: `+e)}function w(e){if(typeof e!=`number`)throw Error(`invalid float 32: `+typeof e);if(Number.isFinite(e)&&(e>se||e<ce))throw Error(`invalid float 32: `+e)}var fe={writeUnknownFields:!0,writerFactory:()=>new me};function pe(e){return e?Object.assign(Object.assign({},fe),e):fe}var me=class{constructor(e){this.stack=[],this.textEncoder=e??new TextEncoder,this.chunks=[],this.buf=[]}finish(){this.chunks.push(new Uint8Array(this.buf));let e=0;for(let t=0;t<this.chunks.length;t++)e+=this.chunks[t].length;let t=new Uint8Array(e),n=0;for(let e=0;e<this.chunks.length;e++)t.set(this.chunks[e],n),n+=this.chunks[e].length;return this.chunks=[],t}fork(){return this.stack.push({chunks:this.chunks,buf:this.buf}),this.chunks=[],this.buf=[],this}join(){let e=this.finish(),t=this.stack.pop();if(!t)throw Error(`invalid state, fork stack empty`);return this.chunks=t.chunks,this.buf=t.buf,this.uint32(e.byteLength),this.raw(e)}tag(e,t){return this.uint32((e<<3|t)>>>0)}raw(e){return this.buf.length&&(this.chunks.push(new Uint8Array(this.buf)),this.buf=[]),this.chunks.push(e),this}uint32(e){for(C(e);e>127;)this.buf.push(e&127|128),e>>>=7;return this.buf.push(e),this}int32(e){return S(e),p(e,this.buf),this}bool(e){return this.buf.push(e?1:0),this}bytes(e){return this.uint32(e.byteLength),this.raw(e)}string(e){let t=this.textEncoder.encode(e);return this.uint32(t.byteLength),this.raw(t)}float(e){w(e);let t=new Uint8Array(4);return new DataView(t.buffer).setFloat32(0,e,!0),this.raw(t)}double(e){let t=new Uint8Array(8);return new DataView(t.buffer).setFloat64(0,e,!0),this.raw(t)}fixed32(e){C(e);let t=new Uint8Array(4);return new DataView(t.buffer).setUint32(0,e,!0),this.raw(t)}sfixed32(e){S(e);let t=new Uint8Array(4);return new DataView(t.buffer).setInt32(0,e,!0),this.raw(t)}sint32(e){return S(e),e=(e<<1^e>>31)>>>0,p(e,this.buf),this}sfixed64(e){let t=new Uint8Array(8),n=new DataView(t.buffer),r=y.from(e);return n.setInt32(0,r.lo,!0),n.setInt32(4,r.hi,!0),this.raw(t)}fixed64(e){let t=new Uint8Array(8),n=new DataView(t.buffer),r=v.from(e);return n.setInt32(0,r.lo,!0),n.setInt32(4,r.hi,!0),this.raw(t)}int64(e){let t=y.from(e);return l(t.lo,t.hi,this.buf),this}sint64(e){let t=y.from(e),n=t.hi>>31;return l(t.lo<<1^n,(t.hi<<1|t.lo>>>31)^n,this.buf),this}uint64(e){let t=v.from(e);return l(t.lo,t.hi,this.buf),this}},he={emitDefaultValues:!1,enumAsInteger:!1,useProtoFieldName:!1,prettySpaces:0},T={ignoreUnknownFields:!1};function ge(e){return e?Object.assign(Object.assign({},T),e):T}function _e(e){return e?Object.assign(Object.assign({},he),e):he}var E=Symbol.for(`protobuf-ts/message-type`);function D(e){let t=!1,n=[];for(let r=0;r<e.length;r++){let i=e.charAt(r);i==`_`?t=!0:/\d/.test(i)?(n.push(i),t=!0):t?(n.push(i.toUpperCase()),t=!1):r==0?n.push(i.toLowerCase()):n.push(i)}return n.join(``)}var O;(function(e){e[e.DOUBLE=1]=`DOUBLE`,e[e.FLOAT=2]=`FLOAT`,e[e.INT64=3]=`INT64`,e[e.UINT64=4]=`UINT64`,e[e.INT32=5]=`INT32`,e[e.FIXED64=6]=`FIXED64`,e[e.FIXED32=7]=`FIXED32`,e[e.BOOL=8]=`BOOL`,e[e.STRING=9]=`STRING`,e[e.BYTES=12]=`BYTES`,e[e.UINT32=13]=`UINT32`,e[e.SFIXED32=15]=`SFIXED32`,e[e.SFIXED64=16]=`SFIXED64`,e[e.SINT32=17]=`SINT32`,e[e.SINT64=18]=`SINT64`})(O||={});var k;(function(e){e[e.BIGINT=0]=`BIGINT`,e[e.STRING=1]=`STRING`,e[e.NUMBER=2]=`NUMBER`})(k||={});var A;(function(e){e[e.NO=0]=`NO`,e[e.PACKED=1]=`PACKED`,e[e.UNPACKED=2]=`UNPACKED`})(A||={});function ve(e){return e.localName=e.localName??D(e.name),e.jsonName=e.jsonName??D(e.name),e.repeat=e.repeat??A.NO,e.opt=e.opt??(e.repeat||e.oneof?!1:e.kind==`message`),e}function ye(e){if(typeof e!=`object`||!e||!e.hasOwnProperty(`oneofKind`))return!1;switch(typeof e.oneofKind){case`string`:return e[e.oneofKind]===void 0?!1:Object.keys(e).length==2;case`undefined`:return Object.keys(e).length==1;default:return!1}}var be=class{constructor(e){this.fields=e.fields??[]}prepare(){if(this.data)return;let e=[],t=[],n=[];for(let r of this.fields)if(r.oneof)n.includes(r.oneof)||(n.push(r.oneof),e.push(r.oneof),t.push(r.oneof));else switch(t.push(r.localName),r.kind){case`scalar`:case`enum`:(!r.opt||r.repeat)&&e.push(r.localName);break;case`message`:r.repeat&&e.push(r.localName);break;case`map`:e.push(r.localName);break}this.data={req:e,known:t,oneofs:Object.values(n)}}is(e,t,n=!1){if(t<0)return!0;if(typeof e!=`object`||!e)return!1;this.prepare();let r=Object.keys(e),i=this.data;if(r.length<i.req.length||i.req.some(e=>!r.includes(e))||!n&&r.some(e=>!i.known.includes(e)))return!1;if(t<1)return!0;for(let r of i.oneofs){let i=e[r];if(!ye(i))return!1;if(i.oneofKind===void 0)continue;let a=this.fields.find(e=>e.localName===i.oneofKind);if(!a||!this.field(i[i.oneofKind],a,n,t))return!1}for(let r of this.fields)if(r.oneof===void 0&&!this.field(e[r.localName],r,n,t))return!1;return!0}field(e,t,n,r){let i=t.repeat;switch(t.kind){case`scalar`:return e===void 0?t.opt:i?this.scalars(e,t.T,r,t.L):this.scalar(e,t.T,t.L);case`enum`:return e===void 0?t.opt:i?this.scalars(e,O.INT32,r):this.scalar(e,O.INT32);case`message`:return e===void 0?!0:i?this.messages(e,t.T(),n,r):this.message(e,t.T(),n,r);case`map`:if(typeof e!=`object`||!e)return!1;if(r<2)return!0;if(!this.mapKeys(e,t.K,r))return!1;switch(t.V.kind){case`scalar`:return this.scalars(Object.values(e),t.V.T,r,t.V.L);case`enum`:return this.scalars(Object.values(e),O.INT32,r);case`message`:return this.messages(Object.values(e),t.V.T(),n,r)}break}return!0}message(e,t,n,r){return n?t.isAssignable(e,r):t.is(e,r)}messages(e,t,n,r){if(!Array.isArray(e))return!1;if(r<2)return!0;if(n){for(let n=0;n<e.length&&n<r;n++)if(!t.isAssignable(e[n],r-1))return!1}else for(let n=0;n<e.length&&n<r;n++)if(!t.is(e[n],r-1))return!1;return!0}scalar(e,t,n){let r=typeof e;switch(t){case O.UINT64:case O.FIXED64:case O.INT64:case O.SFIXED64:case O.SINT64:switch(n){case k.BIGINT:return r==`bigint`;case k.NUMBER:return r==`number`&&!isNaN(e);default:return r==`string`}case O.BOOL:return r==`boolean`;case O.STRING:return r==`string`;case O.BYTES:return e instanceof Uint8Array;case O.DOUBLE:case O.FLOAT:return r==`number`&&!isNaN(e);default:return r==`number`&&Number.isInteger(e)}}scalars(e,t,n,r){if(!Array.isArray(e))return!1;if(n<2)return!0;if(Array.isArray(e)){for(let i=0;i<e.length&&i<n;i++)if(!this.scalar(e[i],t,r))return!1}return!0}mapKeys(e,t,n){let r=Object.keys(e);switch(t){case O.INT32:case O.FIXED32:case O.SFIXED32:case O.SINT32:case O.UINT32:return this.scalars(r.slice(0,n).map(e=>parseInt(e)),t,n);case O.BOOL:return this.scalars(r.slice(0,n).map(e=>e==`true`?!0:e==`false`?!1:e),t,n);default:return this.scalars(r,t,n,k.STRING)}}};function j(e,t){switch(t){case k.BIGINT:return e.toBigInt();case k.NUMBER:return e.toNumber();default:return e.toString()}}var xe=class{constructor(e){this.info=e}prepare(){if(this.fMap===void 0){this.fMap={};let e=this.info.fields??[];for(let t of e)this.fMap[t.name]=t,this.fMap[t.jsonName]=t,this.fMap[t.localName]=t}}assert(t,n,r){if(!t){let t=e(r);throw(t==`number`||t==`boolean`)&&(t=r.toString()),Error(`Cannot parse JSON ${t} for ${this.info.typeName}#${n}`)}}read(e,n,r){this.prepare();let i=[];for(let[a,o]of Object.entries(e)){let e=this.fMap[a];if(!e){if(!r.ignoreUnknownFields)throw Error(`Found unknown field while reading ${this.info.typeName} from JSON format. JSON key: ${a}`);continue}let s=e.localName,c;if(e.oneof){if(o===null&&(e.kind!==`enum`||e.T()[0]!==`google.protobuf.NullValue`))continue;if(i.includes(e.oneof))throw Error(`Multiple members of the oneof group "${e.oneof}" of ${this.info.typeName} are present in JSON.`);i.push(e.oneof),c=n[e.oneof]={oneofKind:s}}else c=n;if(e.kind==`map`){if(o===null)continue;this.assert(t(o),e.name,o);let n=c[s];for(let[t,i]of Object.entries(o)){this.assert(i!==null,e.name+` map value`,null);let a;switch(e.V.kind){case`message`:a=e.V.T().internalJsonRead(i,r);break;case`enum`:if(a=this.enum(e.V.T(),i,e.name,r.ignoreUnknownFields),a===!1)continue;break;case`scalar`:a=this.scalar(i,e.V.T,e.V.L,e.name);break}this.assert(a!==void 0,e.name+` map value`,i);let o=t;e.K==O.BOOL&&(o=o==`true`?!0:o==`false`?!1:o),o=this.scalar(o,e.K,k.STRING,e.name).toString(),n[o]=a}}else if(e.repeat){if(o===null)continue;this.assert(Array.isArray(o),e.name,o);let t=c[s];for(let n of o){this.assert(n!==null,e.name,null);let i;switch(e.kind){case`message`:i=e.T().internalJsonRead(n,r);break;case`enum`:if(i=this.enum(e.T(),n,e.name,r.ignoreUnknownFields),i===!1)continue;break;case`scalar`:i=this.scalar(n,e.T,e.L,e.name);break}this.assert(i!==void 0,e.name,o),t.push(i)}}else switch(e.kind){case`message`:if(o===null&&e.T().typeName!=`google.protobuf.Value`){this.assert(e.oneof===void 0,e.name+` (oneof member)`,null);continue}c[s]=e.T().internalJsonRead(o,r,c[s]);break;case`enum`:if(o===null)continue;let t=this.enum(e.T(),o,e.name,r.ignoreUnknownFields);if(t===!1)continue;c[s]=t;break;case`scalar`:if(o===null)continue;c[s]=this.scalar(o,e.T,e.L,e.name);break}}}enum(e,t,n,r){if(e[0]==`google.protobuf.NullValue`&&x(t===null||t===`NULL_VALUE`,`Unable to parse field ${this.info.typeName}#${n}, enum ${e[0]} only accepts null.`),t===null)return 0;switch(typeof t){case`number`:return x(Number.isInteger(t),`Unable to parse field ${this.info.typeName}#${n}, enum can only be integral number, got ${t}.`),t;case`string`:let i=t;e[2]&&t.substring(0,e[2].length)===e[2]&&(i=t.substring(e[2].length));let a=e[1][i];return a===void 0&&r?!1:(x(typeof a==`number`,`Unable to parse field ${this.info.typeName}#${n}, enum ${e[0]} has no value for "${t}".`),a)}x(!1,`Unable to parse field ${this.info.typeName}#${n}, cannot parse enum value from ${typeof t}".`)}scalar(e,t,n,r){let a;try{switch(t){case O.DOUBLE:case O.FLOAT:if(e===null)return 0;if(e===`NaN`)return NaN;if(e===`Infinity`)return 1/0;if(e===`-Infinity`)return-1/0;if(e===``){a=`empty string`;break}if(typeof e==`string`&&e.trim().length!==e.length){a=`extra whitespace`;break}if(typeof e!=`string`&&typeof e!=`number`)break;let r=Number(e);if(Number.isNaN(r)){a=`not a number`;break}if(!Number.isFinite(r)){a=`too large or small`;break}return t==O.FLOAT&&w(r),r;case O.INT32:case O.FIXED32:case O.SFIXED32:case O.SINT32:case O.UINT32:if(e===null)return 0;let o;if(typeof e==`number`?o=e:e===``?a=`empty string`:typeof e==`string`&&(e.trim().length===e.length?o=Number(e):a=`extra whitespace`),o===void 0)break;return t==O.UINT32?C(o):S(o),o;case O.INT64:case O.SFIXED64:case O.SINT64:if(e===null)return j(y.ZERO,n);if(typeof e!=`number`&&typeof e!=`string`)break;return j(y.from(e),n);case O.FIXED64:case O.UINT64:if(e===null)return j(v.ZERO,n);if(typeof e!=`number`&&typeof e!=`string`)break;return j(v.from(e),n);case O.BOOL:if(e===null)return!1;if(typeof e!=`boolean`)break;return e;case O.STRING:if(e===null)return``;if(typeof e!=`string`){a=`extra whitespace`;break}return e;case O.BYTES:if(e===null||e===``)return new Uint8Array;if(typeof e!=`string`)break;return i(e)}}catch(e){a=e.message}this.assert(!1,r+(a?` - `+a:``),e)}},Se=class{constructor(e){this.fields=e.fields??[]}write(e,t){let n={},r=e;for(let e of this.fields){if(!e.oneof){let i=this.field(e,r[e.localName],t);i!==void 0&&(n[t.useProtoFieldName?e.name:e.jsonName]=i);continue}let i=r[e.oneof];if(i.oneofKind!==e.localName)continue;let a=e.kind==`scalar`||e.kind==`enum`?Object.assign(Object.assign({},t),{emitDefaultValues:!0}):t,o=this.field(e,i[e.localName],a);x(o!==void 0),n[t.useProtoFieldName?e.name:e.jsonName]=o}return n}field(e,t,n){let r;if(e.kind==`map`){x(typeof t==`object`&&!!t);let i={};switch(e.V.kind){case`scalar`:for(let[n,r]of Object.entries(t)){let t=this.scalar(e.V.T,r,e.name,!1,!0);x(t!==void 0),i[n.toString()]=t}break;case`message`:let r=e.V.T();for(let[a,o]of Object.entries(t)){let t=this.message(r,o,e.name,n);x(t!==void 0),i[a.toString()]=t}break;case`enum`:let a=e.V.T();for(let[r,o]of Object.entries(t)){x(o===void 0||typeof o==`number`);let t=this.enum(a,o,e.name,!1,!0,n.enumAsInteger);x(t!==void 0),i[r.toString()]=t}break}(n.emitDefaultValues||Object.keys(i).length>0)&&(r=i)}else if(e.repeat){x(Array.isArray(t));let i=[];switch(e.kind){case`scalar`:for(let n=0;n<t.length;n++){let r=this.scalar(e.T,t[n],e.name,e.opt,!0);x(r!==void 0),i.push(r)}break;case`enum`:let r=e.T();for(let a=0;a<t.length;a++){x(t[a]===void 0||typeof t[a]==`number`);let o=this.enum(r,t[a],e.name,e.opt,!0,n.enumAsInteger);x(o!==void 0),i.push(o)}break;case`message`:let a=e.T();for(let r=0;r<t.length;r++){let o=this.message(a,t[r],e.name,n);x(o!==void 0),i.push(o)}break}(n.emitDefaultValues||i.length>0||n.emitDefaultValues)&&(r=i)}else switch(e.kind){case`scalar`:r=this.scalar(e.T,t,e.name,e.opt,n.emitDefaultValues);break;case`enum`:r=this.enum(e.T(),t,e.name,e.opt,n.emitDefaultValues,n.enumAsInteger);break;case`message`:r=this.message(e.T(),t,e.name,n);break}return r}enum(e,t,n,r,i,a){if(e[0]==`google.protobuf.NullValue`)return!i&&!r?void 0:null;if(t===void 0){x(r);return}if(!(t===0&&!i&&!r))return x(typeof t==`number`),x(Number.isInteger(t)),a||!e[1].hasOwnProperty(t)?t:e[2]?e[2]+e[1][t]:e[1][t]}message(e,t,n,r){return t===void 0?r.emitDefaultValues?null:void 0:e.internalJsonWrite(t,r)}scalar(e,t,n,r,i){if(t===void 0){x(r);return}let o=i||r;switch(e){case O.INT32:case O.SFIXED32:case O.SINT32:return t===0?o?0:void 0:(S(t),t);case O.FIXED32:case O.UINT32:return t===0?o?0:void 0:(C(t),t);case O.FLOAT:w(t);case O.DOUBLE:return t===0?o?0:void 0:(x(typeof t==`number`),Number.isNaN(t)?`NaN`:t===1/0?`Infinity`:t===-1/0?`-Infinity`:t);case O.STRING:return t===``?o?``:void 0:(x(typeof t==`string`),t);case O.BOOL:return t===!1?o?!1:void 0:(x(typeof t==`boolean`),t);case O.UINT64:case O.FIXED64:x(typeof t==`number`||typeof t==`string`||typeof t==`bigint`);let e=v.from(t);return e.isZero()&&!o?void 0:e.toString();case O.INT64:case O.SFIXED64:case O.SINT64:x(typeof t==`number`||typeof t==`string`||typeof t==`bigint`);let n=y.from(t);return n.isZero()&&!o?void 0:n.toString();case O.BYTES:return x(t instanceof Uint8Array),t.byteLength?a(t):o?``:void 0}}};function M(e,t=k.STRING){switch(e){case O.BOOL:return!1;case O.UINT64:case O.FIXED64:return j(v.ZERO,t);case O.INT64:case O.SFIXED64:case O.SINT64:return j(y.ZERO,t);case O.DOUBLE:case O.FLOAT:return 0;case O.BYTES:return new Uint8Array;case O.STRING:return``;default:return 0}}var Ce=class{constructor(e){this.info=e}prepare(){if(!this.fieldNoToField){let e=this.info.fields??[];this.fieldNoToField=new Map(e.map(e=>[e.no,e]))}}read(e,t,n,r){this.prepare();let i=r===void 0?e.len:e.pos+r;for(;e.pos<i;){let[r,i]=e.tag(),a=this.fieldNoToField.get(r);if(!a){let a=n.readUnknownField;if(a==`throw`)throw Error(`Unknown field ${r} (wire type ${i}) for ${this.info.typeName}`);let s=e.skip(i);a!==!1&&(a===!0?o.onRead:a)(this.info.typeName,t,r,i,s);continue}let c=t,l=a.repeat,u=a.localName;switch(a.oneof&&(c=c[a.oneof],c.oneofKind!==u&&(c=t[a.oneof]={oneofKind:u})),a.kind){case`scalar`:case`enum`:let t=a.kind==`enum`?O.INT32:a.T,r=a.kind==`scalar`?a.L:void 0;if(l){let n=c[u];if(i==s.LengthDelimited&&t!=O.STRING&&t!=O.BYTES){let i=e.uint32()+e.pos;for(;e.pos<i;)n.push(this.scalar(e,t,r))}else n.push(this.scalar(e,t,r))}else c[u]=this.scalar(e,t,r);break;case`message`:if(l){let t=c[u],r=a.T().internalBinaryRead(e,e.uint32(),n);t.push(r)}else c[u]=a.T().internalBinaryRead(e,e.uint32(),n,c[u]);break;case`map`:let[o,d]=this.mapEntry(a,e,n);c[u][o]=d;break}}}mapEntry(e,t,n){let r=t.uint32(),i=t.pos+r,a,o;for(;t.pos<i;){let[r,i]=t.tag();switch(r){case 1:a=e.K==O.BOOL?t.bool().toString():this.scalar(t,e.K,k.STRING);break;case 2:switch(e.V.kind){case`scalar`:o=this.scalar(t,e.V.T,e.V.L);break;case`enum`:o=t.int32();break;case`message`:o=e.V.T().internalBinaryRead(t,t.uint32(),n);break}break;default:throw Error(`Unknown field ${r} (wire type ${i}) in map entry for ${this.info.typeName}#${e.name}`)}}if(a===void 0){let t=M(e.K);a=e.K==O.BOOL?t.toString():t}if(o===void 0)switch(e.V.kind){case`scalar`:o=M(e.V.T,e.V.L);break;case`enum`:o=0;break;case`message`:o=e.V.T().create();break}return[a,o]}scalar(e,t,n){switch(t){case O.INT32:return e.int32();case O.STRING:return e.string();case O.BOOL:return e.bool();case O.DOUBLE:return e.double();case O.FLOAT:return e.float();case O.INT64:return j(e.int64(),n);case O.UINT64:return j(e.uint64(),n);case O.FIXED64:return j(e.fixed64(),n);case O.FIXED32:return e.fixed32();case O.BYTES:return e.bytes();case O.UINT32:return e.uint32();case O.SFIXED32:return e.sfixed32();case O.SFIXED64:return j(e.sfixed64(),n);case O.SINT32:return e.sint32();case O.SINT64:return j(e.sint64(),n)}}},we=class{constructor(e){this.info=e}prepare(){this.fields||=(this.info.fields?this.info.fields.concat():[]).sort((e,t)=>e.no-t.no)}write(e,t,n){this.prepare();for(let r of this.fields){let i,a,o=r.repeat,s=r.localName;if(r.oneof){let t=e[r.oneof];if(t.oneofKind!==s)continue;i=t[s],a=!0}else i=e[s],a=!1;switch(r.kind){case`scalar`:case`enum`:let e=r.kind==`enum`?O.INT32:r.T;if(o)if(x(Array.isArray(i)),o==A.PACKED)this.packed(t,e,r.no,i);else for(let n of i)this.scalar(t,e,r.no,n,!0);else i===void 0?x(r.opt):this.scalar(t,e,r.no,i,a||r.opt);break;case`message`:if(o){x(Array.isArray(i));for(let e of i)this.message(t,n,r.T(),r.no,e)}else this.message(t,n,r.T(),r.no,i);break;case`map`:x(typeof i==`object`&&!!i);for(let[e,a]of Object.entries(i))this.mapEntry(t,n,r,e,a);break}}let r=n.writeUnknownFields;r!==!1&&(r===!0?o.onWrite:r)(this.info.typeName,e,t)}mapEntry(e,t,n,r,i){e.tag(n.no,s.LengthDelimited),e.fork();let a=r;switch(n.K){case O.INT32:case O.FIXED32:case O.UINT32:case O.SFIXED32:case O.SINT32:a=Number.parseInt(r);break;case O.BOOL:x(r==`true`||r==`false`),a=r==`true`;break}switch(this.scalar(e,n.K,1,a,!0),n.V.kind){case`scalar`:this.scalar(e,n.V.T,2,i,!0);break;case`enum`:this.scalar(e,O.INT32,2,i,!0);break;case`message`:this.message(e,t,n.V.T(),2,i);break}e.join()}message(e,t,n,r,i){i!==void 0&&(n.internalBinaryWrite(i,e.tag(r,s.LengthDelimited).fork(),t),e.join())}scalar(e,t,n,r,i){let[a,o,s]=this.scalarInfo(t,r);(!s||i)&&(e.tag(n,a),e[o](r))}packed(e,t,n,r){if(!r.length)return;x(t!==O.BYTES&&t!==O.STRING),e.tag(n,s.LengthDelimited),e.fork();let[,i]=this.scalarInfo(t);for(let t=0;t<r.length;t++)e[i](r[t]);e.join()}scalarInfo(e,t){let n=s.Varint,r,i=t===void 0,a=t===0;switch(e){case O.INT32:r=`int32`;break;case O.STRING:a=i||!t.length,n=s.LengthDelimited,r=`string`;break;case O.BOOL:a=t===!1,r=`bool`;break;case O.UINT32:r=`uint32`;break;case O.DOUBLE:n=s.Bit64,r=`double`;break;case O.FLOAT:n=s.Bit32,r=`float`;break;case O.INT64:a=i||y.from(t).isZero(),r=`int64`;break;case O.UINT64:a=i||v.from(t).isZero(),r=`uint64`;break;case O.FIXED64:a=i||v.from(t).isZero(),n=s.Bit64,r=`fixed64`;break;case O.BYTES:a=i||!t.byteLength,n=s.LengthDelimited,r=`bytes`;break;case O.FIXED32:n=s.Bit32,r=`fixed32`;break;case O.SFIXED32:n=s.Bit32,r=`sfixed32`;break;case O.SFIXED64:a=i||y.from(t).isZero(),n=s.Bit64,r=`sfixed64`;break;case O.SINT32:r=`sint32`;break;case O.SINT64:a=i||y.from(t).isZero(),r=`sint64`;break}return[n,r,i||a]}};function Te(e){let t=e.messagePrototype?Object.create(e.messagePrototype):Object.defineProperty({},E,{value:e});for(let n of e.fields){let e=n.localName;if(!n.opt)if(n.oneof)t[n.oneof]={oneofKind:void 0};else if(n.repeat)t[e]=[];else switch(n.kind){case`scalar`:t[e]=M(n.T,n.L);break;case`enum`:t[e]=0;break;case`map`:t[e]={};break}}return t}function N(e,t,n){let r,i=n,a;for(let n of e.fields){let e=n.localName;if(n.oneof){let o=i[n.oneof];if(o?.oneofKind==null)continue;if(r=o[e],a=t[n.oneof],a.oneofKind=o.oneofKind,r==null){delete a[e];continue}}else if(r=i[e],a=t,r==null)continue;switch(n.repeat&&(a[e].length=r.length),n.kind){case`scalar`:case`enum`:if(n.repeat)for(let t=0;t<r.length;t++)a[e][t]=r[t];else a[e]=r;break;case`message`:let t=n.T();if(n.repeat)for(let n=0;n<r.length;n++)a[e][n]=t.create(r[n]);else a[e]===void 0?a[e]=t.create(r):t.mergePartial(a[e],r);break;case`map`:switch(n.V.kind){case`scalar`:case`enum`:Object.assign(a[e],r);break;case`message`:let t=n.V.T();for(let n of Object.keys(r))a[e][n]=t.create(r[n]);break}break}}}function Ee(e,t,n){if(t===n)return!0;if(!t||!n)return!1;for(let r of e.fields){let e=r.localName,i=r.oneof?t[r.oneof][e]:t[e],a=r.oneof?n[r.oneof][e]:n[e];switch(r.kind){case`enum`:case`scalar`:let e=r.kind==`enum`?O.INT32:r.T;if(!(r.repeat?I(e,i,a):F(e,i,a)))return!1;break;case`map`:if(!(r.V.kind==`message`?De(r.V.T(),P(i),P(a)):I(r.V.kind==`enum`?O.INT32:r.V.T,P(i),P(a))))return!1;break;case`message`:let t=r.T();if(!(r.repeat?De(t,i,a):t.equals(i,a)))return!1;break}}return!0}var P=Object.values;function F(e,t,n){if(t===n)return!0;if(e!==O.BYTES)return!1;let r=t,i=n;if(r.length!==i.length)return!1;for(let e=0;e<r.length;e++)if(r[e]!=i[e])return!1;return!0}function I(e,t,n){if(t.length!==n.length)return!1;for(let r=0;r<t.length;r++)if(!F(e,t[r],n[r]))return!1;return!0}function De(e,t,n){if(t.length!==n.length)return!1;for(let r=0;r<t.length;r++)if(!e.equals(t[r],n[r]))return!1;return!0}var Oe=Object.getOwnPropertyDescriptors(Object.getPrototypeOf({})),ke=Oe[E]={},L=class{constructor(e,t,n){this.defaultCheckDepth=16,this.typeName=e,this.fields=t.map(ve),this.options=n??{},ke.value=this,this.messagePrototype=Object.create(null,Oe),this.refTypeCheck=new be(this),this.refJsonReader=new xe(this),this.refJsonWriter=new Se(this),this.refBinReader=new Ce(this),this.refBinWriter=new we(this)}create(e){let t=Te(this);return e!==void 0&&N(this,t,e),t}clone(e){let t=this.create();return N(this,t,e),t}equals(e,t){return Ee(this,e,t)}is(e,t=this.defaultCheckDepth){return this.refTypeCheck.is(e,t,!1)}isAssignable(e,t=this.defaultCheckDepth){return this.refTypeCheck.is(e,t,!0)}mergePartial(e,t){N(this,e,t)}fromBinary(e,t){let n=ie(t);return this.internalBinaryRead(n.readerFactory(e),e.byteLength,n)}fromJson(e,t){return this.internalJsonRead(e,ge(t))}fromJsonString(e,t){let n=JSON.parse(e);return this.fromJson(n,t)}toJson(e,t){return this.internalJsonWrite(e,_e(t))}toJsonString(e,t){let n=this.toJson(e,t);return JSON.stringify(n,null,t?.prettySpaces??0)}toBinary(e,t){let n=pe(t);return this.internalBinaryWrite(e,n.writerFactory(),n).finish()}internalJsonRead(t,n,r){if(typeof t==`object`&&t&&!Array.isArray(t)){let e=r??this.create();return this.refJsonReader.read(t,e,n),e}throw Error(`Unable to parse message ${this.typeName} from JSON ${e(t)}.`)}internalJsonWrite(e,t){return this.refJsonWriter.write(e,t)}internalBinaryWrite(e,t,n){return this.refBinWriter.write(e,t,n),t}internalBinaryRead(e,t,n,r){let i=r??this.create();return this.refBinReader.read(e,i,n,t),i}},R=new class extends L{constructor(){super(`shared.Translation`,[{no:1,name:`code`,kind:`scalar`,T:9},{no:2,name:`content`,kind:`scalar`,T:9}])}create(e){let t=globalThis.Object.create(this.messagePrototype);return t.code=``,t.content=``,e!==void 0&&N(this,t,e),t}internalBinaryRead(e,t,n,r){let i=r??this.create(),a=e.pos+t;for(;e.pos<a;){let[t,r]=e.tag();switch(t){case 1:i.code=e.string();break;case 2:i.content=e.string();break;default:let a=n.readUnknownField;if(a===`throw`)throw new globalThis.Error(`Unknown field ${t} (wire type ${r}) for ${this.typeName}`);let s=e.skip(r);a!==!1&&(a===!0?o.onRead:a)(this.typeName,i,t,r,s)}}return i}internalBinaryWrite(e,t,n){e.code!==``&&t.tag(1,s.LengthDelimited).string(e.code),e.content!==``&&t.tag(2,s.LengthDelimited).string(e.content);let r=n.writeUnknownFields;return r!==!1&&(r==1?o.onWrite:r)(this.typeName,e,t),t}},Ae=function(e){return e[e.NULL_VALUE=0]=`NULL_VALUE`,e}({}),z=new class extends L{constructor(){super(`shared.Struct`,[{no:1,name:`fields`,kind:`map`,K:9,V:{kind:`message`,T:()=>B}}])}create(e){let t=globalThis.Object.create(this.messagePrototype);return t.fields={},e!==void 0&&N(this,t,e),t}internalBinaryRead(e,t,n,r){let i=r??this.create(),a=e.pos+t;for(;e.pos<a;){let[t,r]=e.tag();switch(t){case 1:this.binaryReadMap1(i.fields,e,n);break;default:let a=n.readUnknownField;if(a===`throw`)throw new globalThis.Error(`Unknown field ${t} (wire type ${r}) for ${this.typeName}`);let s=e.skip(r);a!==!1&&(a===!0?o.onRead:a)(this.typeName,i,t,r,s)}}return i}binaryReadMap1(e,t,n){let r=t.uint32(),i=t.pos+r,a,o;for(;t.pos<i;){let[e,r]=t.tag();switch(e){case 1:a=t.string();break;case 2:o=B.internalBinaryRead(t,t.uint32(),n);break;default:throw new globalThis.Error(`unknown map entry field for shared.Struct.fields`)}}e[a??``]=o??B.create()}internalBinaryWrite(e,t,n){for(let r of globalThis.Object.keys(e.fields))t.tag(1,s.LengthDelimited).fork().tag(1,s.LengthDelimited).string(r),t.tag(2,s.LengthDelimited).fork(),B.internalBinaryWrite(e.fields[r],t,n),t.join().join();let r=n.writeUnknownFields;return r!==!1&&(r==1?o.onWrite:r)(this.typeName,e,t),t}},B=new class extends L{constructor(){super(`shared.Value`,[{no:1,name:`null_value`,kind:`enum`,oneof:`kind`,T:()=>[`shared.NullValue`,Ae]},{no:2,name:`number_value`,kind:`message`,oneof:`kind`,T:()=>V},{no:3,name:`string_value`,kind:`scalar`,oneof:`kind`,T:9},{no:4,name:`bool_value`,kind:`scalar`,oneof:`kind`,T:8},{no:5,name:`struct_value`,kind:`message`,oneof:`kind`,T:()=>z},{no:6,name:`list_value`,kind:`message`,oneof:`kind`,T:()=>H}])}create(e){let t=globalThis.Object.create(this.messagePrototype);return t.kind={oneofKind:void 0},e!==void 0&&N(this,t,e),t}internalBinaryRead(e,t,n,r){let i=r??this.create(),a=e.pos+t;for(;e.pos<a;){let[t,r]=e.tag();switch(t){case 1:i.kind={oneofKind:`nullValue`,nullValue:e.int32()};break;case 2:i.kind={oneofKind:`numberValue`,numberValue:V.internalBinaryRead(e,e.uint32(),n,i.kind.numberValue)};break;case 3:i.kind={oneofKind:`stringValue`,stringValue:e.string()};break;case 4:i.kind={oneofKind:`boolValue`,boolValue:e.bool()};break;case 5:i.kind={oneofKind:`structValue`,structValue:z.internalBinaryRead(e,e.uint32(),n,i.kind.structValue)};break;case 6:i.kind={oneofKind:`listValue`,listValue:H.internalBinaryRead(e,e.uint32(),n,i.kind.listValue)};break;default:let a=n.readUnknownField;if(a===`throw`)throw new globalThis.Error(`Unknown field ${t} (wire type ${r}) for ${this.typeName}`);let s=e.skip(r);a!==!1&&(a===!0?o.onRead:a)(this.typeName,i,t,r,s)}}return i}internalBinaryWrite(e,t,n){e.kind.oneofKind===`nullValue`&&t.tag(1,s.Varint).int32(e.kind.nullValue),e.kind.oneofKind===`numberValue`&&V.internalBinaryWrite(e.kind.numberValue,t.tag(2,s.LengthDelimited).fork(),n).join(),e.kind.oneofKind===`stringValue`&&t.tag(3,s.LengthDelimited).string(e.kind.stringValue),e.kind.oneofKind===`boolValue`&&t.tag(4,s.Varint).bool(e.kind.boolValue),e.kind.oneofKind===`structValue`&&z.internalBinaryWrite(e.kind.structValue,t.tag(5,s.LengthDelimited).fork(),n).join(),e.kind.oneofKind===`listValue`&&H.internalBinaryWrite(e.kind.listValue,t.tag(6,s.LengthDelimited).fork(),n).join();let r=n.writeUnknownFields;return r!==!1&&(r==1?o.onWrite:r)(this.typeName,e,t),t}},V=new class extends L{constructor(){super(`shared.NumberValue`,[{no:1,name:`integer`,kind:`scalar`,oneof:`number`,T:3,L:0},{no:2,name:`float`,kind:`scalar`,oneof:`number`,T:1}])}create(e){let t=globalThis.Object.create(this.messagePrototype);return t.number={oneofKind:void 0},e!==void 0&&N(this,t,e),t}internalBinaryRead(e,t,n,r){let i=r??this.create(),a=e.pos+t;for(;e.pos<a;){let[t,r]=e.tag();switch(t){case 1:i.number={oneofKind:`integer`,integer:e.int64().toBigInt()};break;case 2:i.number={oneofKind:`float`,float:e.double()};break;default:let a=n.readUnknownField;if(a===`throw`)throw new globalThis.Error(`Unknown field ${t} (wire type ${r}) for ${this.typeName}`);let s=e.skip(r);a!==!1&&(a===!0?o.onRead:a)(this.typeName,i,t,r,s)}}return i}internalBinaryWrite(e,t,n){e.number.oneofKind===`integer`&&t.tag(1,s.Varint).int64(e.number.integer),e.number.oneofKind===`float`&&t.tag(2,s.Bit64).double(e.number.float);let r=n.writeUnknownFields;return r!==!1&&(r==1?o.onWrite:r)(this.typeName,e,t),t}},H=new class extends L{constructor(){super(`shared.ListValue`,[{no:1,name:`values`,kind:`message`,repeat:2,T:()=>B}])}create(e){let t=globalThis.Object.create(this.messagePrototype);return t.values=[],e!==void 0&&N(this,t,e),t}internalBinaryRead(e,t,n,r){let i=r??this.create(),a=e.pos+t;for(;e.pos<a;){let[t,r]=e.tag();switch(t){case 1:i.values.push(B.internalBinaryRead(e,e.uint32(),n));break;default:let a=n.readUnknownField;if(a===`throw`)throw new globalThis.Error(`Unknown field ${t} (wire type ${r}) for ${this.typeName}`);let s=e.skip(r);a!==!1&&(a===!0?o.onRead:a)(this.typeName,i,t,r,s)}}return i}internalBinaryWrite(e,t,n){for(let r=0;r<e.values.length;r++)B.internalBinaryWrite(e.values[r],t.tag(1,s.LengthDelimited).fork(),n).join();let r=n.writeUnknownFields;return r!==!1&&(r==1?o.onWrite:r)(this.typeName,e,t),t}},U=new class extends L{constructor(){super(`shared.ActionConfiguration`,[{no:1,name:`identifier`,kind:`scalar`,T:9},{no:2,name:`value`,kind:`message`,T:()=>B}])}create(e){let t=globalThis.Object.create(this.messagePrototype);return t.identifier=``,e!==void 0&&N(this,t,e),t}internalBinaryRead(e,t,n,r){let i=r??this.create(),a=e.pos+t;for(;e.pos<a;){let[t,r]=e.tag();switch(t){case 1:i.identifier=e.string();break;case 2:i.value=B.internalBinaryRead(e,e.uint32(),n,i.value);break;default:let a=n.readUnknownField;if(a===`throw`)throw new globalThis.Error(`Unknown field ${t} (wire type ${r}) for ${this.typeName}`);let s=e.skip(r);a!==!1&&(a===!0?o.onRead:a)(this.typeName,i,t,r,s)}}return i}internalBinaryWrite(e,t,n){e.identifier!==``&&t.tag(1,s.LengthDelimited).string(e.identifier),e.value&&B.internalBinaryWrite(e.value,t.tag(2,s.LengthDelimited).fork(),n).join();let r=n.writeUnknownFields;return r!==!1&&(r==1?o.onWrite:r)(this.typeName,e,t),t}},W=new class extends L{constructor(){super(`shared.ActionProjectConfiguration`,[{no:1,name:`project_id`,kind:`scalar`,T:3,L:0},{no:2,name:`action_configurations`,kind:`message`,repeat:2,T:()=>U}])}create(e){let t=globalThis.Object.create(this.messagePrototype);return t.projectId=0n,t.actionConfigurations=[],e!==void 0&&N(this,t,e),t}internalBinaryRead(e,t,n,r){let i=r??this.create(),a=e.pos+t;for(;e.pos<a;){let[t,r]=e.tag();switch(t){case 1:i.projectId=e.int64().toBigInt();break;case 2:i.actionConfigurations.push(U.internalBinaryRead(e,e.uint32(),n));break;default:let a=n.readUnknownField;if(a===`throw`)throw new globalThis.Error(`Unknown field ${t} (wire type ${r}) for ${this.typeName}`);let s=e.skip(r);a!==!1&&(a===!0?o.onRead:a)(this.typeName,i,t,r,s)}}return i}internalBinaryWrite(e,t,n){e.projectId!==0n&&t.tag(1,s.Varint).int64(e.projectId);for(let r=0;r<e.actionConfigurations.length;r++)U.internalBinaryWrite(e.actionConfigurations[r],t.tag(2,s.LengthDelimited).fork(),n).join();let r=n.writeUnknownFields;return r!==!1&&(r==1?o.onWrite:r)(this.typeName,e,t),t}},je=new class extends L{constructor(){super(`shared.ActionConfigurations`,[{no:1,name:`action_configurations`,kind:`message`,repeat:2,T:()=>W}])}create(e){let t=globalThis.Object.create(this.messagePrototype);return t.actionConfigurations=[],e!==void 0&&N(this,t,e),t}internalBinaryRead(e,t,n,r){let i=r??this.create(),a=e.pos+t;for(;e.pos<a;){let[t,r]=e.tag();switch(t){case 1:i.actionConfigurations.push(W.internalBinaryRead(e,e.uint32(),n));break;default:let a=n.readUnknownField;if(a===`throw`)throw new globalThis.Error(`Unknown field ${t} (wire type ${r}) for ${this.typeName}`);let s=e.skip(r);a!==!1&&(a===!0?o.onRead:a)(this.typeName,i,t,r,s)}}return i}internalBinaryWrite(e,t,n){for(let r=0;r<e.actionConfigurations.length;r++)W.internalBinaryWrite(e.actionConfigurations[r],t.tag(1,s.LengthDelimited).fork(),n).join();let r=n.writeUnknownFields;return r!==!1&&(r==1?o.onWrite:r)(this.typeName,e,t),t}},Me=new class extends L{constructor(){super(`shared.ActionConfigurationDefinition`,[{no:1,name:`name`,kind:`message`,repeat:2,T:()=>R},{no:2,name:`description`,kind:`message`,repeat:2,T:()=>R},{no:3,name:`type`,kind:`scalar`,T:9},{no:4,name:`linked_data_type_identifiers`,kind:`scalar`,repeat:2,T:9},{no:5,name:`default_value`,kind:`message`,T:()=>B},{no:6,name:`identifier`,kind:`scalar`,T:9}])}create(e){let t=globalThis.Object.create(this.messagePrototype);return t.name=[],t.description=[],t.type=``,t.linkedDataTypeIdentifiers=[],t.identifier=``,e!==void 0&&N(this,t,e),t}internalBinaryRead(e,t,n,r){let i=r??this.create(),a=e.pos+t;for(;e.pos<a;){let[t,r]=e.tag();switch(t){case 1:i.name.push(R.internalBinaryRead(e,e.uint32(),n));break;case 2:i.description.push(R.internalBinaryRead(e,e.uint32(),n));break;case 3:i.type=e.string();break;case 4:i.linkedDataTypeIdentifiers.push(e.string());break;case 5:i.defaultValue=B.internalBinaryRead(e,e.uint32(),n,i.defaultValue);break;case 6:i.identifier=e.string();break;default:let a=n.readUnknownField;if(a===`throw`)throw new globalThis.Error(`Unknown field ${t} (wire type ${r}) for ${this.typeName}`);let s=e.skip(r);a!==!1&&(a===!0?o.onRead:a)(this.typeName,i,t,r,s)}}return i}internalBinaryWrite(e,t,n){for(let r=0;r<e.name.length;r++)R.internalBinaryWrite(e.name[r],t.tag(1,s.LengthDelimited).fork(),n).join();for(let r=0;r<e.description.length;r++)R.internalBinaryWrite(e.description[r],t.tag(2,s.LengthDelimited).fork(),n).join();e.type!==``&&t.tag(3,s.LengthDelimited).string(e.type);for(let n=0;n<e.linkedDataTypeIdentifiers.length;n++)t.tag(4,s.LengthDelimited).string(e.linkedDataTypeIdentifiers[n]);e.defaultValue&&B.internalBinaryWrite(e.defaultValue,t.tag(5,s.LengthDelimited).fork(),n).join(),e.identifier!==``&&t.tag(6,s.LengthDelimited).string(e.identifier);let r=n.writeUnknownFields;return r!==!1&&(r==1?o.onWrite:r)(this.typeName,e,t),t}},Ne=new class extends L{constructor(){super(`shared.DefinitionDataType`,[{no:1,name:`identifier`,kind:`scalar`,T:9},{no:2,name:`name`,kind:`message`,repeat:2,T:()=>R},{no:3,name:`display_message`,kind:`message`,repeat:2,T:()=>R},{no:4,name:`alias`,kind:`message`,repeat:2,T:()=>R},{no:5,name:`rules`,kind:`message`,repeat:2,T:()=>G},{no:6,name:`generic_keys`,kind:`scalar`,repeat:2,T:9},{no:7,name:`type`,kind:`scalar`,T:9},{no:8,name:`linked_data_type_identifiers`,kind:`scalar`,repeat:2,T:9},{no:9,name:`version`,kind:`scalar`,T:9},{no:10,name:`definition_source`,kind:`scalar`,T:9}])}create(e){let t=globalThis.Object.create(this.messagePrototype);return t.identifier=``,t.name=[],t.displayMessage=[],t.alias=[],t.rules=[],t.genericKeys=[],t.type=``,t.linkedDataTypeIdentifiers=[],t.version=``,t.definitionSource=``,e!==void 0&&N(this,t,e),t}internalBinaryRead(e,t,n,r){let i=r??this.create(),a=e.pos+t;for(;e.pos<a;){let[t,r]=e.tag();switch(t){case 1:i.identifier=e.string();break;case 2:i.name.push(R.internalBinaryRead(e,e.uint32(),n));break;case 3:i.displayMessage.push(R.internalBinaryRead(e,e.uint32(),n));break;case 4:i.alias.push(R.internalBinaryRead(e,e.uint32(),n));break;case 5:i.rules.push(G.internalBinaryRead(e,e.uint32(),n));break;case 6:i.genericKeys.push(e.string());break;case 7:i.type=e.string();break;case 8:i.linkedDataTypeIdentifiers.push(e.string());break;case 9:i.version=e.string();break;case 10:i.definitionSource=e.string();break;default:let a=n.readUnknownField;if(a===`throw`)throw new globalThis.Error(`Unknown field ${t} (wire type ${r}) for ${this.typeName}`);let s=e.skip(r);a!==!1&&(a===!0?o.onRead:a)(this.typeName,i,t,r,s)}}return i}internalBinaryWrite(e,t,n){e.identifier!==``&&t.tag(1,s.LengthDelimited).string(e.identifier);for(let r=0;r<e.name.length;r++)R.internalBinaryWrite(e.name[r],t.tag(2,s.LengthDelimited).fork(),n).join();for(let r=0;r<e.displayMessage.length;r++)R.internalBinaryWrite(e.displayMessage[r],t.tag(3,s.LengthDelimited).fork(),n).join();for(let r=0;r<e.alias.length;r++)R.internalBinaryWrite(e.alias[r],t.tag(4,s.LengthDelimited).fork(),n).join();for(let r=0;r<e.rules.length;r++)G.internalBinaryWrite(e.rules[r],t.tag(5,s.LengthDelimited).fork(),n).join();for(let n=0;n<e.genericKeys.length;n++)t.tag(6,s.LengthDelimited).string(e.genericKeys[n]);e.type!==``&&t.tag(7,s.LengthDelimited).string(e.type);for(let n=0;n<e.linkedDataTypeIdentifiers.length;n++)t.tag(8,s.LengthDelimited).string(e.linkedDataTypeIdentifiers[n]);e.version!==``&&t.tag(9,s.LengthDelimited).string(e.version),e.definitionSource!==``&&t.tag(10,s.LengthDelimited).string(e.definitionSource);let r=n.writeUnknownFields;return r!==!1&&(r==1?o.onWrite:r)(this.typeName,e,t),t}},Pe=new class extends L{constructor(){super(`shared.ExecutionDataType`,[{no:1,name:`identifier`,kind:`scalar`,T:9},{no:2,name:`rules`,kind:`message`,repeat:2,T:()=>K}])}create(e){let t=globalThis.Object.create(this.messagePrototype);return t.identifier=``,t.rules=[],e!==void 0&&N(this,t,e),t}internalBinaryRead(e,t,n,r){let i=r??this.create(),a=e.pos+t;for(;e.pos<a;){let[t,r]=e.tag();switch(t){case 1:i.identifier=e.string();break;case 2:i.rules.push(K.internalBinaryRead(e,e.uint32(),n));break;default:let a=n.readUnknownField;if(a===`throw`)throw new globalThis.Error(`Unknown field ${t} (wire type ${r}) for ${this.typeName}`);let s=e.skip(r);a!==!1&&(a===!0?o.onRead:a)(this.typeName,i,t,r,s)}}return i}internalBinaryWrite(e,t,n){e.identifier!==``&&t.tag(1,s.LengthDelimited).string(e.identifier);for(let r=0;r<e.rules.length;r++)K.internalBinaryWrite(e.rules[r],t.tag(2,s.LengthDelimited).fork(),n).join();let r=n.writeUnknownFields;return r!==!1&&(r==1?o.onWrite:r)(this.typeName,e,t),t}},G=new class extends L{constructor(){super(`shared.DefinitionDataTypeRule`,[{no:1,name:`number_range`,kind:`message`,oneof:`config`,T:()=>q},{no:2,name:`regex`,kind:`message`,oneof:`config`,T:()=>J}])}create(e){let t=globalThis.Object.create(this.messagePrototype);return t.config={oneofKind:void 0},e!==void 0&&N(this,t,e),t}internalBinaryRead(e,t,n,r){let i=r??this.create(),a=e.pos+t;for(;e.pos<a;){let[t,r]=e.tag();switch(t){case 1:i.config={oneofKind:`numberRange`,numberRange:q.internalBinaryRead(e,e.uint32(),n,i.config.numberRange)};break;case 2:i.config={oneofKind:`regex`,regex:J.internalBinaryRead(e,e.uint32(),n,i.config.regex)};break;default:let a=n.readUnknownField;if(a===`throw`)throw new globalThis.Error(`Unknown field ${t} (wire type ${r}) for ${this.typeName}`);let s=e.skip(r);a!==!1&&(a===!0?o.onRead:a)(this.typeName,i,t,r,s)}}return i}internalBinaryWrite(e,t,n){e.config.oneofKind===`numberRange`&&q.internalBinaryWrite(e.config.numberRange,t.tag(1,s.LengthDelimited).fork(),n).join(),e.config.oneofKind===`regex`&&J.internalBinaryWrite(e.config.regex,t.tag(2,s.LengthDelimited).fork(),n).join();let r=n.writeUnknownFields;return r!==!1&&(r==1?o.onWrite:r)(this.typeName,e,t),t}},K=new class extends L{constructor(){super(`shared.ExecutionDataTypeRule`,[{no:1,name:`number_range`,kind:`message`,oneof:`config`,T:()=>q},{no:2,name:`regex`,kind:`message`,oneof:`config`,T:()=>J}])}create(e){let t=globalThis.Object.create(this.messagePrototype);return t.config={oneofKind:void 0},e!==void 0&&N(this,t,e),t}internalBinaryRead(e,t,n,r){let i=r??this.create(),a=e.pos+t;for(;e.pos<a;){let[t,r]=e.tag();switch(t){case 1:i.config={oneofKind:`numberRange`,numberRange:q.internalBinaryRead(e,e.uint32(),n,i.config.numberRange)};break;case 2:i.config={oneofKind:`regex`,regex:J.internalBinaryRead(e,e.uint32(),n,i.config.regex)};break;default:let a=n.readUnknownField;if(a===`throw`)throw new globalThis.Error(`Unknown field ${t} (wire type ${r}) for ${this.typeName}`);let s=e.skip(r);a!==!1&&(a===!0?o.onRead:a)(this.typeName,i,t,r,s)}}return i}internalBinaryWrite(e,t,n){e.config.oneofKind===`numberRange`&&q.internalBinaryWrite(e.config.numberRange,t.tag(1,s.LengthDelimited).fork(),n).join(),e.config.oneofKind===`regex`&&J.internalBinaryWrite(e.config.regex,t.tag(2,s.LengthDelimited).fork(),n).join();let r=n.writeUnknownFields;return r!==!1&&(r==1?o.onWrite:r)(this.typeName,e,t),t}},q=new class extends L{constructor(){super(`shared.DataTypeNumberRangeRuleConfig`,[{no:1,name:`from`,kind:`scalar`,T:3,L:0},{no:2,name:`to`,kind:`scalar`,T:3,L:0},{no:3,name:`steps`,kind:`scalar`,opt:!0,T:3,L:0}])}create(e){let t=globalThis.Object.create(this.messagePrototype);return t.from=0n,t.to=0n,e!==void 0&&N(this,t,e),t}internalBinaryRead(e,t,n,r){let i=r??this.create(),a=e.pos+t;for(;e.pos<a;){let[t,r]=e.tag();switch(t){case 1:i.from=e.int64().toBigInt();break;case 2:i.to=e.int64().toBigInt();break;case 3:i.steps=e.int64().toBigInt();break;default:let a=n.readUnknownField;if(a===`throw`)throw new globalThis.Error(`Unknown field ${t} (wire type ${r}) for ${this.typeName}`);let s=e.skip(r);a!==!1&&(a===!0?o.onRead:a)(this.typeName,i,t,r,s)}}return i}internalBinaryWrite(e,t,n){e.from!==0n&&t.tag(1,s.Varint).int64(e.from),e.to!==0n&&t.tag(2,s.Varint).int64(e.to),e.steps!==void 0&&t.tag(3,s.Varint).int64(e.steps);let r=n.writeUnknownFields;return r!==!1&&(r==1?o.onWrite:r)(this.typeName,e,t),t}},J=new class extends L{constructor(){super(`shared.DataTypeRegexRuleConfig`,[{no:1,name:`pattern`,kind:`scalar`,T:9}])}create(e){let t=globalThis.Object.create(this.messagePrototype);return t.pattern=``,e!==void 0&&N(this,t,e),t}internalBinaryRead(e,t,n,r){let i=r??this.create(),a=e.pos+t;for(;e.pos<a;){let[t,r]=e.tag();switch(t){case 1:i.pattern=e.string();break;default:let a=n.readUnknownField;if(a===`throw`)throw new globalThis.Error(`Unknown field ${t} (wire type ${r}) for ${this.typeName}`);let s=e.skip(r);a!==!1&&(a===!0?o.onRead:a)(this.typeName,i,t,r,s)}}return i}internalBinaryWrite(e,t,n){e.pattern!==``&&t.tag(1,s.LengthDelimited).string(e.pattern);let r=n.writeUnknownFields;return r!==!1&&(r==1?o.onWrite:r)(this.typeName,e,t),t}},Fe=function(e){return e[e.UNKNOWN=0]=`UNKNOWN`,e[e.NONE=1]=`NONE`,e[e.PROJECT=2]=`PROJECT`,e}({}),Ie=new class extends L{constructor(){super(`shared.FlowType`,[{no:1,name:`identifier`,kind:`scalar`,T:9},{no:2,name:`settings`,kind:`message`,repeat:2,T:()=>Y},{no:3,name:`editable`,kind:`scalar`,T:8},{no:4,name:`name`,kind:`message`,repeat:2,T:()=>R},{no:5,name:`description`,kind:`message`,repeat:2,T:()=>R},{no:6,name:`documentation`,kind:`message`,repeat:2,T:()=>R},{no:7,name:`display_message`,kind:`message`,repeat:2,T:()=>R},{no:8,name:`alias`,kind:`message`,repeat:2,T:()=>R},{no:9,name:`version`,kind:`scalar`,T:9},{no:10,name:`display_icon`,kind:`scalar`,T:9},{no:11,name:`definition_source`,kind:`scalar`,opt:!0,T:9},{no:12,name:`linked_data_type_identifiers`,kind:`scalar`,repeat:2,T:9},{no:13,name:`signature`,kind:`scalar`,T:9}])}create(e){let t=globalThis.Object.create(this.messagePrototype);return t.identifier=``,t.settings=[],t.editable=!1,t.name=[],t.description=[],t.documentation=[],t.displayMessage=[],t.alias=[],t.version=``,t.displayIcon=``,t.linkedDataTypeIdentifiers=[],t.signature=``,e!==void 0&&N(this,t,e),t}internalBinaryRead(e,t,n,r){let i=r??this.create(),a=e.pos+t;for(;e.pos<a;){let[t,r]=e.tag();switch(t){case 1:i.identifier=e.string();break;case 2:i.settings.push(Y.internalBinaryRead(e,e.uint32(),n));break;case 3:i.editable=e.bool();break;case 4:i.name.push(R.internalBinaryRead(e,e.uint32(),n));break;case 5:i.description.push(R.internalBinaryRead(e,e.uint32(),n));break;case 6:i.documentation.push(R.internalBinaryRead(e,e.uint32(),n));break;case 7:i.displayMessage.push(R.internalBinaryRead(e,e.uint32(),n));break;case 8:i.alias.push(R.internalBinaryRead(e,e.uint32(),n));break;case 9:i.version=e.string();break;case 10:i.displayIcon=e.string();break;case 11:i.definitionSource=e.string();break;case 12:i.linkedDataTypeIdentifiers.push(e.string());break;case 13:i.signature=e.string();break;default:let a=n.readUnknownField;if(a===`throw`)throw new globalThis.Error(`Unknown field ${t} (wire type ${r}) for ${this.typeName}`);let s=e.skip(r);a!==!1&&(a===!0?o.onRead:a)(this.typeName,i,t,r,s)}}return i}internalBinaryWrite(e,t,n){e.identifier!==``&&t.tag(1,s.LengthDelimited).string(e.identifier);for(let r=0;r<e.settings.length;r++)Y.internalBinaryWrite(e.settings[r],t.tag(2,s.LengthDelimited).fork(),n).join();e.editable!==!1&&t.tag(3,s.Varint).bool(e.editable);for(let r=0;r<e.name.length;r++)R.internalBinaryWrite(e.name[r],t.tag(4,s.LengthDelimited).fork(),n).join();for(let r=0;r<e.description.length;r++)R.internalBinaryWrite(e.description[r],t.tag(5,s.LengthDelimited).fork(),n).join();for(let r=0;r<e.documentation.length;r++)R.internalBinaryWrite(e.documentation[r],t.tag(6,s.LengthDelimited).fork(),n).join();for(let r=0;r<e.displayMessage.length;r++)R.internalBinaryWrite(e.displayMessage[r],t.tag(7,s.LengthDelimited).fork(),n).join();for(let r=0;r<e.alias.length;r++)R.internalBinaryWrite(e.alias[r],t.tag(8,s.LengthDelimited).fork(),n).join();e.version!==``&&t.tag(9,s.LengthDelimited).string(e.version),e.displayIcon!==``&&t.tag(10,s.LengthDelimited).string(e.displayIcon),e.definitionSource!==void 0&&t.tag(11,s.LengthDelimited).string(e.definitionSource);for(let n=0;n<e.linkedDataTypeIdentifiers.length;n++)t.tag(12,s.LengthDelimited).string(e.linkedDataTypeIdentifiers[n]);e.signature!==``&&t.tag(13,s.LengthDelimited).string(e.signature);let r=n.writeUnknownFields;return r!==!1&&(r==1?o.onWrite:r)(this.typeName,e,t),t}},Y=new class extends L{constructor(){super(`shared.FlowTypeSetting`,[{no:1,name:`identifier`,kind:`scalar`,T:9},{no:2,name:`unique`,kind:`enum`,T:()=>[`shared.FlowTypeSetting.UniquenessScope`,Fe]},{no:3,name:`default_value`,kind:`message`,T:()=>B},{no:4,name:`name`,kind:`message`,repeat:2,T:()=>R},{no:5,name:`description`,kind:`message`,repeat:2,T:()=>R}])}create(e){let t=globalThis.Object.create(this.messagePrototype);return t.identifier=``,t.unique=0,t.name=[],t.description=[],e!==void 0&&N(this,t,e),t}internalBinaryRead(e,t,n,r){let i=r??this.create(),a=e.pos+t;for(;e.pos<a;){let[t,r]=e.tag();switch(t){case 1:i.identifier=e.string();break;case 2:i.unique=e.int32();break;case 3:i.defaultValue=B.internalBinaryRead(e,e.uint32(),n,i.defaultValue);break;case 4:i.name.push(R.internalBinaryRead(e,e.uint32(),n));break;case 5:i.description.push(R.internalBinaryRead(e,e.uint32(),n));break;default:let a=n.readUnknownField;if(a===`throw`)throw new globalThis.Error(`Unknown field ${t} (wire type ${r}) for ${this.typeName}`);let s=e.skip(r);a!==!1&&(a===!0?o.onRead:a)(this.typeName,i,t,r,s)}}return i}internalBinaryWrite(e,t,n){e.identifier!==``&&t.tag(1,s.LengthDelimited).string(e.identifier),e.unique!==0&&t.tag(2,s.Varint).int32(e.unique),e.defaultValue&&B.internalBinaryWrite(e.defaultValue,t.tag(3,s.LengthDelimited).fork(),n).join();for(let r=0;r<e.name.length;r++)R.internalBinaryWrite(e.name[r],t.tag(4,s.LengthDelimited).fork(),n).join();for(let r=0;r<e.description.length;r++)R.internalBinaryWrite(e.description[r],t.tag(5,s.LengthDelimited).fork(),n).join();let r=n.writeUnknownFields;return r!==!1&&(r==1?o.onWrite:r)(this.typeName,e,t),t}},Le=new class extends L{constructor(){super(`shared.FunctionDefinition`,[{no:1,name:`runtime_name`,kind:`scalar`,T:9},{no:2,name:`parameter_definitions`,kind:`message`,repeat:2,T:()=>X},{no:3,name:`signature`,kind:`scalar`,T:9},{no:4,name:`throws_error`,kind:`scalar`,T:8},{no:5,name:`name`,kind:`message`,repeat:2,T:()=>R},{no:6,name:`description`,kind:`message`,repeat:2,T:()=>R},{no:7,name:`documentation`,kind:`message`,repeat:2,T:()=>R},{no:8,name:`deprecation_message`,kind:`message`,repeat:2,T:()=>R},{no:9,name:`display_message`,kind:`message`,repeat:2,T:()=>R},{no:10,name:`alias`,kind:`message`,repeat:2,T:()=>R},{no:11,name:`linked_data_type_identifiers`,kind:`scalar`,repeat:2,T:9},{no:12,name:`version`,kind:`scalar`,T:9},{no:13,name:`display_icon`,kind:`scalar`,T:9},{no:14,name:`definition_source`,kind:`scalar`,T:9}])}create(e){let t=globalThis.Object.create(this.messagePrototype);return t.runtimeName=``,t.parameterDefinitions=[],t.signature=``,t.throwsError=!1,t.name=[],t.description=[],t.documentation=[],t.deprecationMessage=[],t.displayMessage=[],t.alias=[],t.linkedDataTypeIdentifiers=[],t.version=``,t.displayIcon=``,t.definitionSource=``,e!==void 0&&N(this,t,e),t}internalBinaryRead(e,t,n,r){let i=r??this.create(),a=e.pos+t;for(;e.pos<a;){let[t,r]=e.tag();switch(t){case 1:i.runtimeName=e.string();break;case 2:i.parameterDefinitions.push(X.internalBinaryRead(e,e.uint32(),n));break;case 3:i.signature=e.string();break;case 4:i.throwsError=e.bool();break;case 5:i.name.push(R.internalBinaryRead(e,e.uint32(),n));break;case 6:i.description.push(R.internalBinaryRead(e,e.uint32(),n));break;case 7:i.documentation.push(R.internalBinaryRead(e,e.uint32(),n));break;case 8:i.deprecationMessage.push(R.internalBinaryRead(e,e.uint32(),n));break;case 9:i.displayMessage.push(R.internalBinaryRead(e,e.uint32(),n));break;case 10:i.alias.push(R.internalBinaryRead(e,e.uint32(),n));break;case 11:i.linkedDataTypeIdentifiers.push(e.string());break;case 12:i.version=e.string();break;case 13:i.displayIcon=e.string();break;case 14:i.definitionSource=e.string();break;default:let a=n.readUnknownField;if(a===`throw`)throw new globalThis.Error(`Unknown field ${t} (wire type ${r}) for ${this.typeName}`);let s=e.skip(r);a!==!1&&(a===!0?o.onRead:a)(this.typeName,i,t,r,s)}}return i}internalBinaryWrite(e,t,n){e.runtimeName!==``&&t.tag(1,s.LengthDelimited).string(e.runtimeName);for(let r=0;r<e.parameterDefinitions.length;r++)X.internalBinaryWrite(e.parameterDefinitions[r],t.tag(2,s.LengthDelimited).fork(),n).join();e.signature!==``&&t.tag(3,s.LengthDelimited).string(e.signature),e.throwsError!==!1&&t.tag(4,s.Varint).bool(e.throwsError);for(let r=0;r<e.name.length;r++)R.internalBinaryWrite(e.name[r],t.tag(5,s.LengthDelimited).fork(),n).join();for(let r=0;r<e.description.length;r++)R.internalBinaryWrite(e.description[r],t.tag(6,s.LengthDelimited).fork(),n).join();for(let r=0;r<e.documentation.length;r++)R.internalBinaryWrite(e.documentation[r],t.tag(7,s.LengthDelimited).fork(),n).join();for(let r=0;r<e.deprecationMessage.length;r++)R.internalBinaryWrite(e.deprecationMessage[r],t.tag(8,s.LengthDelimited).fork(),n).join();for(let r=0;r<e.displayMessage.length;r++)R.internalBinaryWrite(e.displayMessage[r],t.tag(9,s.LengthDelimited).fork(),n).join();for(let r=0;r<e.alias.length;r++)R.internalBinaryWrite(e.alias[r],t.tag(10,s.LengthDelimited).fork(),n).join();for(let n=0;n<e.linkedDataTypeIdentifiers.length;n++)t.tag(11,s.LengthDelimited).string(e.linkedDataTypeIdentifiers[n]);e.version!==``&&t.tag(12,s.LengthDelimited).string(e.version),e.displayIcon!==``&&t.tag(13,s.LengthDelimited).string(e.displayIcon),e.definitionSource!==``&&t.tag(14,s.LengthDelimited).string(e.definitionSource);let r=n.writeUnknownFields;return r!==!1&&(r==1?o.onWrite:r)(this.typeName,e,t),t}},X=new class extends L{constructor(){super(`shared.ParameterDefinition`,[{no:1,name:`runtime_name`,kind:`scalar`,T:9},{no:2,name:`default_value`,kind:`message`,T:()=>B},{no:3,name:`name`,kind:`message`,repeat:2,T:()=>R},{no:4,name:`description`,kind:`message`,repeat:2,T:()=>R},{no:5,name:`documentation`,kind:`message`,repeat:2,T:()=>R}])}create(e){let t=globalThis.Object.create(this.messagePrototype);return t.runtimeName=``,t.name=[],t.description=[],t.documentation=[],e!==void 0&&N(this,t,e),t}internalBinaryRead(e,t,n,r){let i=r??this.create(),a=e.pos+t;for(;e.pos<a;){let[t,r]=e.tag();switch(t){case 1:i.runtimeName=e.string();break;case 2:i.defaultValue=B.internalBinaryRead(e,e.uint32(),n,i.defaultValue);break;case 3:i.name.push(R.internalBinaryRead(e,e.uint32(),n));break;case 4:i.description.push(R.internalBinaryRead(e,e.uint32(),n));break;case 5:i.documentation.push(R.internalBinaryRead(e,e.uint32(),n));break;default:let a=n.readUnknownField;if(a===`throw`)throw new globalThis.Error(`Unknown field ${t} (wire type ${r}) for ${this.typeName}`);let s=e.skip(r);a!==!1&&(a===!0?o.onRead:a)(this.typeName,i,t,r,s)}}return i}internalBinaryWrite(e,t,n){e.runtimeName!==``&&t.tag(1,s.LengthDelimited).string(e.runtimeName),e.defaultValue&&B.internalBinaryWrite(e.defaultValue,t.tag(2,s.LengthDelimited).fork(),n).join();for(let r=0;r<e.name.length;r++)R.internalBinaryWrite(e.name[r],t.tag(3,s.LengthDelimited).fork(),n).join();for(let r=0;r<e.description.length;r++)R.internalBinaryWrite(e.description[r],t.tag(4,s.LengthDelimited).fork(),n).join();for(let r=0;r<e.documentation.length;r++)R.internalBinaryWrite(e.documentation[r],t.tag(5,s.LengthDelimited).fork(),n).join();let r=n.writeUnknownFields;return r!==!1&&(r==1?o.onWrite:r)(this.typeName,e,t),t}},Re=new class extends L{constructor(){super(`shared.RuntimeFunctionDefinition`,[{no:1,name:`runtime_name`,kind:`scalar`,T:9},{no:2,name:`runtime_parameter_definitions`,kind:`message`,repeat:2,T:()=>Z},{no:3,name:`signature`,kind:`scalar`,T:9},{no:4,name:`throws_error`,kind:`scalar`,T:8},{no:5,name:`name`,kind:`message`,repeat:2,T:()=>R},{no:6,name:`description`,kind:`message`,repeat:2,T:()=>R},{no:7,name:`documentation`,kind:`message`,repeat:2,T:()=>R},{no:8,name:`deprecation_message`,kind:`message`,repeat:2,T:()=>R},{no:9,name:`display_message`,kind:`message`,repeat:2,T:()=>R},{no:10,name:`alias`,kind:`message`,repeat:2,T:()=>R},{no:11,name:`linked_data_type_identifiers`,kind:`scalar`,repeat:2,T:9},{no:12,name:`version`,kind:`scalar`,T:9},{no:13,name:`display_icon`,kind:`scalar`,T:9},{no:14,name:`definition_source`,kind:`scalar`,T:9}])}create(e){let t=globalThis.Object.create(this.messagePrototype);return t.runtimeName=``,t.runtimeParameterDefinitions=[],t.signature=``,t.throwsError=!1,t.name=[],t.description=[],t.documentation=[],t.deprecationMessage=[],t.displayMessage=[],t.alias=[],t.linkedDataTypeIdentifiers=[],t.version=``,t.displayIcon=``,t.definitionSource=``,e!==void 0&&N(this,t,e),t}internalBinaryRead(e,t,n,r){let i=r??this.create(),a=e.pos+t;for(;e.pos<a;){let[t,r]=e.tag();switch(t){case 1:i.runtimeName=e.string();break;case 2:i.runtimeParameterDefinitions.push(Z.internalBinaryRead(e,e.uint32(),n));break;case 3:i.signature=e.string();break;case 4:i.throwsError=e.bool();break;case 5:i.name.push(R.internalBinaryRead(e,e.uint32(),n));break;case 6:i.description.push(R.internalBinaryRead(e,e.uint32(),n));break;case 7:i.documentation.push(R.internalBinaryRead(e,e.uint32(),n));break;case 8:i.deprecationMessage.push(R.internalBinaryRead(e,e.uint32(),n));break;case 9:i.displayMessage.push(R.internalBinaryRead(e,e.uint32(),n));break;case 10:i.alias.push(R.internalBinaryRead(e,e.uint32(),n));break;case 11:i.linkedDataTypeIdentifiers.push(e.string());break;case 12:i.version=e.string();break;case 13:i.displayIcon=e.string();break;case 14:i.definitionSource=e.string();break;default:let a=n.readUnknownField;if(a===`throw`)throw new globalThis.Error(`Unknown field ${t} (wire type ${r}) for ${this.typeName}`);let s=e.skip(r);a!==!1&&(a===!0?o.onRead:a)(this.typeName,i,t,r,s)}}return i}internalBinaryWrite(e,t,n){e.runtimeName!==``&&t.tag(1,s.LengthDelimited).string(e.runtimeName);for(let r=0;r<e.runtimeParameterDefinitions.length;r++)Z.internalBinaryWrite(e.runtimeParameterDefinitions[r],t.tag(2,s.LengthDelimited).fork(),n).join();e.signature!==``&&t.tag(3,s.LengthDelimited).string(e.signature),e.throwsError!==!1&&t.tag(4,s.Varint).bool(e.throwsError);for(let r=0;r<e.name.length;r++)R.internalBinaryWrite(e.name[r],t.tag(5,s.LengthDelimited).fork(),n).join();for(let r=0;r<e.description.length;r++)R.internalBinaryWrite(e.description[r],t.tag(6,s.LengthDelimited).fork(),n).join();for(let r=0;r<e.documentation.length;r++)R.internalBinaryWrite(e.documentation[r],t.tag(7,s.LengthDelimited).fork(),n).join();for(let r=0;r<e.deprecationMessage.length;r++)R.internalBinaryWrite(e.deprecationMessage[r],t.tag(8,s.LengthDelimited).fork(),n).join();for(let r=0;r<e.displayMessage.length;r++)R.internalBinaryWrite(e.displayMessage[r],t.tag(9,s.LengthDelimited).fork(),n).join();for(let r=0;r<e.alias.length;r++)R.internalBinaryWrite(e.alias[r],t.tag(10,s.LengthDelimited).fork(),n).join();for(let n=0;n<e.linkedDataTypeIdentifiers.length;n++)t.tag(11,s.LengthDelimited).string(e.linkedDataTypeIdentifiers[n]);e.version!==``&&t.tag(12,s.LengthDelimited).string(e.version),e.displayIcon!==``&&t.tag(13,s.LengthDelimited).string(e.displayIcon),e.definitionSource!==``&&t.tag(14,s.LengthDelimited).string(e.definitionSource);let r=n.writeUnknownFields;return r!==!1&&(r==1?o.onWrite:r)(this.typeName,e,t),t}},Z=new class extends L{constructor(){super(`shared.RuntimeParameterDefinition`,[{no:1,name:`runtime_name`,kind:`scalar`,T:9},{no:2,name:`default_value`,kind:`message`,T:()=>B},{no:3,name:`name`,kind:`message`,repeat:2,T:()=>R},{no:4,name:`description`,kind:`message`,repeat:2,T:()=>R},{no:5,name:`documentation`,kind:`message`,repeat:2,T:()=>R}])}create(e){let t=globalThis.Object.create(this.messagePrototype);return t.runtimeName=``,t.name=[],t.description=[],t.documentation=[],e!==void 0&&N(this,t,e),t}internalBinaryRead(e,t,n,r){let i=r??this.create(),a=e.pos+t;for(;e.pos<a;){let[t,r]=e.tag();switch(t){case 1:i.runtimeName=e.string();break;case 2:i.defaultValue=B.internalBinaryRead(e,e.uint32(),n,i.defaultValue);break;case 3:i.name.push(R.internalBinaryRead(e,e.uint32(),n));break;case 4:i.description.push(R.internalBinaryRead(e,e.uint32(),n));break;case 5:i.documentation.push(R.internalBinaryRead(e,e.uint32(),n));break;default:let a=n.readUnknownField;if(a===`throw`)throw new globalThis.Error(`Unknown field ${t} (wire type ${r}) for ${this.typeName}`);let s=e.skip(r);a!==!1&&(a===!0?o.onRead:a)(this.typeName,i,t,r,s)}}return i}internalBinaryWrite(e,t,n){e.runtimeName!==``&&t.tag(1,s.LengthDelimited).string(e.runtimeName),e.defaultValue&&B.internalBinaryWrite(e.defaultValue,t.tag(2,s.LengthDelimited).fork(),n).join();for(let r=0;r<e.name.length;r++)R.internalBinaryWrite(e.name[r],t.tag(3,s.LengthDelimited).fork(),n).join();for(let r=0;r<e.description.length;r++)R.internalBinaryWrite(e.description[r],t.tag(4,s.LengthDelimited).fork(),n).join();for(let r=0;r<e.documentation.length;r++)R.internalBinaryWrite(e.documentation[r],t.tag(5,s.LengthDelimited).fork(),n).join();let r=n.writeUnknownFields;return r!==!1&&(r==1?o.onWrite:r)(this.typeName,e,t),t}},ze=function(e){return e[e.UNKNOWN=0]=`UNKNOWN`,e[e.NOT_RESPONDING=1]=`NOT_RESPONDING`,e[e.NOT_READY=2]=`NOT_READY`,e[e.RUNNING=3]=`RUNNING`,e[e.STOPPED=4]=`STOPPED`,e}({}),Be=function(e){return e[e.UNKNOWN=0]=`UNKNOWN`,e[e.NOT_RESPONDING=1]=`NOT_RESPONDING`,e[e.NOT_READY=2]=`NOT_READY`,e[e.RUNNING=3]=`RUNNING`,e[e.STOPPED=4]=`STOPPED`,e}({}),Q=new class extends L{constructor(){super(`shared.AdapterConfiguration`,[{no:1,name:`endpoint`,kind:`scalar`,oneof:`data`,T:9}])}create(e){let t=globalThis.Object.create(this.messagePrototype);return t.data={oneofKind:void 0},e!==void 0&&N(this,t,e),t}internalBinaryRead(e,t,n,r){let i=r??this.create(),a=e.pos+t;for(;e.pos<a;){let[t,r]=e.tag();switch(t){case 1:i.data={oneofKind:`endpoint`,endpoint:e.string()};break;default:let a=n.readUnknownField;if(a===`throw`)throw new globalThis.Error(`Unknown field ${t} (wire type ${r}) for ${this.typeName}`);let s=e.skip(r);a!==!1&&(a===!0?o.onRead:a)(this.typeName,i,t,r,s)}}return i}internalBinaryWrite(e,t,n){e.data.oneofKind===`endpoint`&&t.tag(1,s.LengthDelimited).string(e.data.endpoint);let r=n.writeUnknownFields;return r!==!1&&(r==1?o.onWrite:r)(this.typeName,e,t),t}},$=new class extends L{constructor(){super(`shared.RuntimeFeature`,[{no:1,name:`name`,kind:`message`,repeat:2,T:()=>R},{no:2,name:`description`,kind:`message`,repeat:2,T:()=>R}])}create(e){let t=globalThis.Object.create(this.messagePrototype);return t.name=[],t.description=[],e!==void 0&&N(this,t,e),t}internalBinaryRead(e,t,n,r){let i=r??this.create(),a=e.pos+t;for(;e.pos<a;){let[t,r]=e.tag();switch(t){case 1:i.name.push(R.internalBinaryRead(e,e.uint32(),n));break;case 2:i.description.push(R.internalBinaryRead(e,e.uint32(),n));break;default:let a=n.readUnknownField;if(a===`throw`)throw new globalThis.Error(`Unknown field ${t} (wire type ${r}) for ${this.typeName}`);let s=e.skip(r);a!==!1&&(a===!0?o.onRead:a)(this.typeName,i,t,r,s)}}return i}internalBinaryWrite(e,t,n){for(let r=0;r<e.name.length;r++)R.internalBinaryWrite(e.name[r],t.tag(1,s.LengthDelimited).fork(),n).join();for(let r=0;r<e.description.length;r++)R.internalBinaryWrite(e.description[r],t.tag(2,s.LengthDelimited).fork(),n).join();let r=n.writeUnknownFields;return r!==!1&&(r==1?o.onWrite:r)(this.typeName,e,t),t}},Ve=new class extends L{constructor(){super(`shared.AdapterRuntimeStatus`,[{no:1,name:`status`,kind:`enum`,T:()=>[`shared.AdapterRuntimeStatus.Status`,ze]},{no:2,name:`timestamp`,kind:`scalar`,T:3,L:0},{no:3,name:`identifier`,kind:`scalar`,T:9},{no:4,name:`features`,kind:`message`,repeat:2,T:()=>$},{no:5,name:`configurations`,kind:`message`,repeat:2,T:()=>Q}])}create(e){let t=globalThis.Object.create(this.messagePrototype);return t.status=0,t.timestamp=0n,t.identifier=``,t.features=[],t.configurations=[],e!==void 0&&N(this,t,e),t}internalBinaryRead(e,t,n,r){let i=r??this.create(),a=e.pos+t;for(;e.pos<a;){let[t,r]=e.tag();switch(t){case 1:i.status=e.int32();break;case 2:i.timestamp=e.int64().toBigInt();break;case 3:i.identifier=e.string();break;case 4:i.features.push($.internalBinaryRead(e,e.uint32(),n));break;case 5:i.configurations.push(Q.internalBinaryRead(e,e.uint32(),n));break;default:let a=n.readUnknownField;if(a===`throw`)throw new globalThis.Error(`Unknown field ${t} (wire type ${r}) for ${this.typeName}`);let s=e.skip(r);a!==!1&&(a===!0?o.onRead:a)(this.typeName,i,t,r,s)}}return i}internalBinaryWrite(e,t,n){e.status!==0&&t.tag(1,s.Varint).int32(e.status),e.timestamp!==0n&&t.tag(2,s.Varint).int64(e.timestamp),e.identifier!==``&&t.tag(3,s.LengthDelimited).string(e.identifier);for(let r=0;r<e.features.length;r++)$.internalBinaryWrite(e.features[r],t.tag(4,s.LengthDelimited).fork(),n).join();for(let r=0;r<e.configurations.length;r++)Q.internalBinaryWrite(e.configurations[r],t.tag(5,s.LengthDelimited).fork(),n).join();let r=n.writeUnknownFields;return r!==!1&&(r==1?o.onWrite:r)(this.typeName,e,t),t}},He=new class extends L{constructor(){super(`shared.ExecutionRuntimeStatus`,[{no:1,name:`status`,kind:`enum`,T:()=>[`shared.ExecutionRuntimeStatus.Status`,Be]},{no:2,name:`timestamp`,kind:`scalar`,T:3,L:0},{no:3,name:`identifier`,kind:`scalar`,T:9},{no:4,name:`features`,kind:`message`,repeat:2,T:()=>$}])}create(e){let t=globalThis.Object.create(this.messagePrototype);return t.status=0,t.timestamp=0n,t.identifier=``,t.features=[],e!==void 0&&N(this,t,e),t}internalBinaryRead(e,t,n,r){let i=r??this.create(),a=e.pos+t;for(;e.pos<a;){let[t,r]=e.tag();switch(t){case 1:i.status=e.int32();break;case 2:i.timestamp=e.int64().toBigInt();break;case 3:i.identifier=e.string();break;case 4:i.features.push($.internalBinaryRead(e,e.uint32(),n));break;default:let a=n.readUnknownField;if(a===`throw`)throw new globalThis.Error(`Unknown field ${t} (wire type ${r}) for ${this.typeName}`);let s=e.skip(r);a!==!1&&(a===!0?o.onRead:a)(this.typeName,i,t,r,s)}}return i}internalBinaryWrite(e,t,n){e.status!==0&&t.tag(1,s.Varint).int32(e.status),e.timestamp!==0n&&t.tag(2,s.Varint).int64(e.timestamp),e.identifier!==``&&t.tag(3,s.LengthDelimited).string(e.identifier);for(let r=0;r<e.features.length;r++)$.internalBinaryWrite(e.features[r],t.tag(4,s.LengthDelimited).fork(),n).join();let r=n.writeUnknownFields;return r!==!1&&(r==1?o.onWrite:r)(this.typeName,e,t),t}},Ue=new class extends L{constructor(){super(`shared.RuntimeUsage`,[{no:1,name:`flow_id`,kind:`scalar`,T:3,L:0},{no:2,name:`duration`,kind:`scalar`,T:3,L:0}])}create(e){let t=globalThis.Object.create(this.messagePrototype);return t.flowId=0n,t.duration=0n,e!==void 0&&N(this,t,e),t}internalBinaryRead(e,t,n,r){let i=r??this.create(),a=e.pos+t;for(;e.pos<a;){let[t,r]=e.tag();switch(t){case 1:i.flowId=e.int64().toBigInt();break;case 2:i.duration=e.int64().toBigInt();break;default:let a=n.readUnknownField;if(a===`throw`)throw new globalThis.Error(`Unknown field ${t} (wire type ${r}) for ${this.typeName}`);let s=e.skip(r);a!==!1&&(a===!0?o.onRead:a)(this.typeName,i,t,r,s)}}return i}internalBinaryWrite(e,t,n){e.flowId!==0n&&t.tag(1,s.Varint).int64(e.flowId),e.duration!==0n&&t.tag(2,s.Varint).int64(e.duration);let r=n.writeUnknownFields;return r!==!1&&(r==1?o.onWrite:r)(this.typeName,e,t),t}};Object.defineProperty(exports,`A`,{enumerable:!0,get:function(){return R}}),Object.defineProperty(exports,`C`,{enumerable:!0,get:function(){return je}}),Object.defineProperty(exports,`D`,{enumerable:!0,get:function(){return V}}),Object.defineProperty(exports,`E`,{enumerable:!0,get:function(){return Ae}}),Object.defineProperty(exports,`F`,{enumerable:!0,get:function(){return o}}),Object.defineProperty(exports,`I`,{enumerable:!0,get:function(){return s}}),Object.defineProperty(exports,`M`,{enumerable:!0,get:function(){return N}}),Object.defineProperty(exports,`N`,{enumerable:!0,get:function(){return D}}),Object.defineProperty(exports,`O`,{enumerable:!0,get:function(){return z}}),Object.defineProperty(exports,`P`,{enumerable:!0,get:function(){return oe}}),Object.defineProperty(exports,`S`,{enumerable:!0,get:function(){return Me}}),Object.defineProperty(exports,`T`,{enumerable:!0,get:function(){return H}}),Object.defineProperty(exports,`_`,{enumerable:!0,get:function(){return Ne}}),Object.defineProperty(exports,`a`,{enumerable:!0,get:function(){return He}}),Object.defineProperty(exports,`b`,{enumerable:!0,get:function(){return K}}),Object.defineProperty(exports,`c`,{enumerable:!0,get:function(){return Re}}),Object.defineProperty(exports,`d`,{enumerable:!0,get:function(){return X}}),Object.defineProperty(exports,`f`,{enumerable:!0,get:function(){return Ie}}),Object.defineProperty(exports,`g`,{enumerable:!0,get:function(){return J}}),Object.defineProperty(exports,`h`,{enumerable:!0,get:function(){return q}}),Object.defineProperty(exports,`i`,{enumerable:!0,get:function(){return ze}}),Object.defineProperty(exports,`j`,{enumerable:!0,get:function(){return L}}),Object.defineProperty(exports,`k`,{enumerable:!0,get:function(){return B}}),Object.defineProperty(exports,`l`,{enumerable:!0,get:function(){return Z}}),Object.defineProperty(exports,`m`,{enumerable:!0,get:function(){return Fe}}),Object.defineProperty(exports,`n`,{enumerable:!0,get:function(){return Q}}),Object.defineProperty(exports,`o`,{enumerable:!0,get:function(){return Be}}),Object.defineProperty(exports,`p`,{enumerable:!0,get:function(){return Y}}),Object.defineProperty(exports,`r`,{enumerable:!0,get:function(){return Ve}}),Object.defineProperty(exports,`s`,{enumerable:!0,get:function(){return $}}),Object.defineProperty(exports,`t`,{enumerable:!0,get:function(){return Ue}}),Object.defineProperty(exports,`u`,{enumerable:!0,get:function(){return Le}}),Object.defineProperty(exports,`v`,{enumerable:!0,get:function(){return G}}),Object.defineProperty(exports,`w`,{enumerable:!0,get:function(){return W}}),Object.defineProperty(exports,`x`,{enumerable:!0,get:function(){return U}}),Object.defineProperty(exports,`y`,{enumerable:!0,get:function(){return Pe}});
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@code0-tech/tucana",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.66",
|
|
4
4
|
"description": "Code0 GRPC Protocol",
|
|
5
5
|
"homepage": "https://github.com/code0-tech/tucana#readme",
|
|
6
6
|
"bugs": {
|
|
@@ -13,47 +13,49 @@
|
|
|
13
13
|
"license": "Apache-2.0",
|
|
14
14
|
"author": "",
|
|
15
15
|
"type": "module",
|
|
16
|
-
"main": "index.js",
|
|
17
16
|
"scripts": {
|
|
18
|
-
"build": "
|
|
19
|
-
"generate:aquila": "protoc --ts_opt=add_pb_suffix
|
|
20
|
-
"generate:sagittarius": "protoc --ts_opt=add_pb_suffix --ts_opt=
|
|
21
|
-
"generate:shared": "protoc --ts_opt=add_pb_suffix --ts_opt=
|
|
22
|
-
"generate": "npm run clean && npm run generate:shared && npm run generate:sagittarius && npm run generate:aquila && npm run generate:exports
|
|
17
|
+
"build": "vite build",
|
|
18
|
+
"generate:aquila": "protoc --ts_opt=add_pb_suffix --ts_opt=generate_dependencies --ts_out=pb/_generated --proto_path=../../proto/aquila --proto_path=../../proto/shared ../../proto/aquila/*.proto",
|
|
19
|
+
"generate:sagittarius": "protoc --ts_opt=add_pb_suffix --ts_opt=generate_dependencies --ts_out=pb/_generated --proto_path=../../proto/sagittarius --proto_path=../../proto/shared ../../proto/sagittarius/*.proto",
|
|
20
|
+
"generate:shared": "protoc --ts_opt=add_pb_suffix --ts_opt=generate_dependencies --ts_out=pb/_generated --proto_path=../../proto/shared ../../proto/shared/*.proto",
|
|
21
|
+
"generate": "npm run clean && npm run generate:shared && npm run generate:sagittarius && npm run generate:aquila && npm run generate:exports",
|
|
23
22
|
"generate:exports": "node scripts/generateExports.mjs",
|
|
24
|
-
"generate:replace-enums": "npx ts-node scripts/replace-enums.ts",
|
|
25
23
|
"clean": "rm -rf pb/_generated/*.js && rm -rf pb/_generated/*.ts && rm -rf helpers/*.js"
|
|
26
24
|
},
|
|
27
25
|
"devDependencies": {
|
|
26
|
+
"vite": "^8.0.3",
|
|
27
|
+
"vite-plugin-dts": "^4.5.4",
|
|
28
28
|
"@protobuf-ts/plugin": "^2.11.1",
|
|
29
29
|
"protoc": "^34.0.0",
|
|
30
30
|
"ts-morph": "^27.0.2",
|
|
31
31
|
"ts-node": "^10.9.2"
|
|
32
32
|
},
|
|
33
33
|
"files": [
|
|
34
|
-
"
|
|
35
|
-
"helpers",
|
|
36
|
-
"index.ts",
|
|
37
|
-
"index.js",
|
|
38
|
-
"index.d.ts",
|
|
39
|
-
"package.json"
|
|
34
|
+
"dist"
|
|
40
35
|
],
|
|
41
|
-
"
|
|
36
|
+
"main": "./dist/tucana.cjs.js",
|
|
37
|
+
"module": "./dist/tucana.es.js",
|
|
38
|
+
"types": "./dist/tucana.d.ts",
|
|
42
39
|
"exports": {
|
|
43
|
-
".": {
|
|
44
|
-
"import": "./index.js"
|
|
45
|
-
},
|
|
46
40
|
"./shared": {
|
|
47
|
-
"
|
|
41
|
+
"types": "./dist/shared.d.ts",
|
|
42
|
+
"import": "./dist/shared.es.js",
|
|
43
|
+
"require": "./dist/shared.cjs.js"
|
|
48
44
|
},
|
|
49
45
|
"./aquila": {
|
|
50
|
-
"
|
|
46
|
+
"types": "./dist/aquila.d.ts",
|
|
47
|
+
"import": "./dist/aquila.es.js",
|
|
48
|
+
"require": "./dist/aquila.cjs.js"
|
|
51
49
|
},
|
|
52
50
|
"./sagittarius": {
|
|
53
|
-
"
|
|
51
|
+
"types": "./dist/sagittarius.d.ts",
|
|
52
|
+
"import": "./dist/sagittarius.es.js",
|
|
53
|
+
"require": "./dist/sagittarius.cjs.js"
|
|
54
54
|
},
|
|
55
55
|
"./helpers": {
|
|
56
|
-
"
|
|
56
|
+
"types": "./dist/helpers.d.ts",
|
|
57
|
+
"import": "./dist/helpers.es.js",
|
|
58
|
+
"require": "./dist/helpers.cjs.js"
|
|
57
59
|
}
|
|
58
60
|
},
|
|
59
61
|
"publishConfig": {
|
package/helpers/helpers.d.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from "./shared.struct_helper.js";
|
package/helpers/helpers.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from "./shared.struct_helper.js";
|
package/helpers/helpers.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from "./shared.struct_helper.js";
|
|
@@ -1,89 +0,0 @@
|
|
|
1
|
-
function toAllowedValue(value) {
|
|
2
|
-
switch (value.kind.oneofKind) {
|
|
3
|
-
case "nullValue":
|
|
4
|
-
return null;
|
|
5
|
-
case "numberValue":
|
|
6
|
-
const numberValue = value.kind.numberValue;
|
|
7
|
-
if (numberValue.number.oneofKind === "integer") {
|
|
8
|
-
return numberValue.number.integer;
|
|
9
|
-
}
|
|
10
|
-
else if (numberValue.number.oneofKind === "float") {
|
|
11
|
-
return numberValue.number.float;
|
|
12
|
-
}
|
|
13
|
-
else {
|
|
14
|
-
throw new Error("Unsupported NumberValue number kind: " + numberValue.number.oneofKind);
|
|
15
|
-
}
|
|
16
|
-
case "stringValue":
|
|
17
|
-
return value.kind.stringValue;
|
|
18
|
-
case "boolValue":
|
|
19
|
-
return value.kind.boolValue;
|
|
20
|
-
case "listValue":
|
|
21
|
-
return value.kind.listValue.values.map(toAllowedValue);
|
|
22
|
-
case "structValue":
|
|
23
|
-
const obj = {};
|
|
24
|
-
for (const [k, v] of Object.entries(value.kind.structValue.fields)) {
|
|
25
|
-
obj[k] = toAllowedValue(v);
|
|
26
|
-
}
|
|
27
|
-
return obj;
|
|
28
|
-
default:
|
|
29
|
-
throw new Error(`Unsupported Value kind: ${value.kind.oneofKind}`);
|
|
30
|
-
}
|
|
31
|
-
}
|
|
32
|
-
function constructValue(value) {
|
|
33
|
-
if (value === null) {
|
|
34
|
-
return { kind: { oneofKind: "nullValue", nullValue: 0 } };
|
|
35
|
-
}
|
|
36
|
-
if (typeof value === "number" || typeof value === "bigint") {
|
|
37
|
-
if (Number.isInteger(value) || typeof value === "bigint") {
|
|
38
|
-
return {
|
|
39
|
-
kind: {
|
|
40
|
-
oneofKind: "numberValue", numberValue: {
|
|
41
|
-
number: {
|
|
42
|
-
oneofKind: "integer",
|
|
43
|
-
integer: BigInt(value)
|
|
44
|
-
}
|
|
45
|
-
}
|
|
46
|
-
}
|
|
47
|
-
};
|
|
48
|
-
}
|
|
49
|
-
return {
|
|
50
|
-
kind: {
|
|
51
|
-
oneofKind: "numberValue", numberValue: {
|
|
52
|
-
number: {
|
|
53
|
-
oneofKind: "float",
|
|
54
|
-
float: value
|
|
55
|
-
}
|
|
56
|
-
}
|
|
57
|
-
}
|
|
58
|
-
};
|
|
59
|
-
}
|
|
60
|
-
if (typeof value === "string") {
|
|
61
|
-
return { kind: { oneofKind: "stringValue", stringValue: value } };
|
|
62
|
-
}
|
|
63
|
-
if (typeof value === "boolean") {
|
|
64
|
-
return { kind: { oneofKind: "boolValue", boolValue: value } };
|
|
65
|
-
}
|
|
66
|
-
if (Array.isArray(value)) {
|
|
67
|
-
const listValues = value.map(v => constructValue(v));
|
|
68
|
-
return {
|
|
69
|
-
kind: {
|
|
70
|
-
oneofKind: "listValue",
|
|
71
|
-
listValue: { values: listValues }
|
|
72
|
-
}
|
|
73
|
-
};
|
|
74
|
-
}
|
|
75
|
-
if (typeof value === "object") {
|
|
76
|
-
const structFields = {};
|
|
77
|
-
for (const [k, v] of Object.entries(value)) {
|
|
78
|
-
structFields[k] = constructValue(v);
|
|
79
|
-
}
|
|
80
|
-
return {
|
|
81
|
-
kind: {
|
|
82
|
-
oneofKind: "structValue",
|
|
83
|
-
structValue: { fields: structFields }
|
|
84
|
-
}
|
|
85
|
-
};
|
|
86
|
-
}
|
|
87
|
-
throw new Error(`Unsupported value type: ${typeof value}`);
|
|
88
|
-
}
|
|
89
|
-
export { toAllowedValue, constructValue };
|
|
@@ -1,99 +0,0 @@
|
|
|
1
|
-
import {Value} from "../pb/shared";
|
|
2
|
-
|
|
3
|
-
type PlainValue = null | bigint | number | string | boolean | Array<PlainValue> | object;
|
|
4
|
-
|
|
5
|
-
function toAllowedValue(value: Value): PlainValue {
|
|
6
|
-
switch (value.kind.oneofKind) {
|
|
7
|
-
case "nullValue":
|
|
8
|
-
return null;
|
|
9
|
-
case "numberValue":
|
|
10
|
-
const numberValue = value.kind.numberValue;
|
|
11
|
-
if (numberValue.number.oneofKind === "integer") {
|
|
12
|
-
return numberValue.number.integer;
|
|
13
|
-
} else if (numberValue.number.oneofKind === "float") {
|
|
14
|
-
return numberValue.number.float;
|
|
15
|
-
} else {
|
|
16
|
-
throw new Error("Unsupported NumberValue number kind: " + numberValue.number.oneofKind);
|
|
17
|
-
}
|
|
18
|
-
case "stringValue":
|
|
19
|
-
return value.kind.stringValue;
|
|
20
|
-
case "boolValue":
|
|
21
|
-
return value.kind.boolValue;
|
|
22
|
-
case "listValue":
|
|
23
|
-
return value.kind.listValue.values.map(toAllowedValue);
|
|
24
|
-
case "structValue":
|
|
25
|
-
const obj: { [key: string]: PlainValue } = {};
|
|
26
|
-
for (const [k, v] of Object.entries(value.kind.structValue.fields)) {
|
|
27
|
-
obj[k] = toAllowedValue(v);
|
|
28
|
-
}
|
|
29
|
-
return obj;
|
|
30
|
-
default:
|
|
31
|
-
throw new Error(`Unsupported Value kind: ${value.kind.oneofKind}`);
|
|
32
|
-
}
|
|
33
|
-
}
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
function constructValue(value: PlainValue): Value {
|
|
37
|
-
if (value === null) {
|
|
38
|
-
return {kind: {oneofKind: "nullValue", nullValue: 0}};
|
|
39
|
-
}
|
|
40
|
-
if (typeof value === "number" || typeof value === "bigint") {
|
|
41
|
-
if (Number.isInteger(value) || typeof value === "bigint") {
|
|
42
|
-
return {
|
|
43
|
-
kind: {
|
|
44
|
-
oneofKind: "numberValue", numberValue: {
|
|
45
|
-
number: {
|
|
46
|
-
oneofKind: "integer",
|
|
47
|
-
integer: BigInt(value)
|
|
48
|
-
}
|
|
49
|
-
}
|
|
50
|
-
}
|
|
51
|
-
};
|
|
52
|
-
}
|
|
53
|
-
|
|
54
|
-
return {
|
|
55
|
-
kind: {
|
|
56
|
-
oneofKind: "numberValue", numberValue: {
|
|
57
|
-
number: {
|
|
58
|
-
oneofKind: "float",
|
|
59
|
-
float: value
|
|
60
|
-
}
|
|
61
|
-
}
|
|
62
|
-
}
|
|
63
|
-
};
|
|
64
|
-
}
|
|
65
|
-
if (typeof value === "string") {
|
|
66
|
-
return {kind: {oneofKind: "stringValue", stringValue: value}};
|
|
67
|
-
}
|
|
68
|
-
if (typeof value === "boolean") {
|
|
69
|
-
return {kind: {oneofKind: "boolValue", boolValue: value}};
|
|
70
|
-
}
|
|
71
|
-
if (Array.isArray(value)) {
|
|
72
|
-
const listValues = value.map(v => constructValue(v));
|
|
73
|
-
return {
|
|
74
|
-
kind: {
|
|
75
|
-
oneofKind: "listValue",
|
|
76
|
-
listValue: {values: listValues}
|
|
77
|
-
}
|
|
78
|
-
};
|
|
79
|
-
}
|
|
80
|
-
if (typeof value === "object") {
|
|
81
|
-
const structFields: { [key: string]: Value } = {};
|
|
82
|
-
for (const [k, v] of Object.entries(value)) {
|
|
83
|
-
structFields[k] = constructValue(v);
|
|
84
|
-
}
|
|
85
|
-
return {
|
|
86
|
-
kind: {
|
|
87
|
-
oneofKind: "structValue",
|
|
88
|
-
structValue: {fields: structFields}
|
|
89
|
-
}
|
|
90
|
-
};
|
|
91
|
-
}
|
|
92
|
-
throw new Error(`Unsupported value type: ${typeof value}`);
|
|
93
|
-
}
|
|
94
|
-
|
|
95
|
-
export {
|
|
96
|
-
toAllowedValue,
|
|
97
|
-
constructValue,
|
|
98
|
-
PlainValue
|
|
99
|
-
}
|
package/index.js
DELETED
|
File without changes
|
package/pb/_generated/.gitkeep
DELETED
|
File without changes
|
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
// @generated by protobuf-ts 2.11.1 with parameter add_pb_suffix,output_javascript,generate_dependencies
|
|
2
|
-
// @generated from protobuf file "aquila.action.proto" (package "aquila", syntax proto3)
|
|
3
|
-
// tslint:disable
|
|
4
|
-
import { ActionTransferService } from "./aquila.action_pb";
|
|
5
|
-
import { stackIntercept } from "@protobuf-ts/runtime-rpc";
|
|
6
|
-
/**
|
|
7
|
-
* @generated from protobuf service aquila.ActionTransferService
|
|
8
|
-
*/
|
|
9
|
-
export class ActionTransferServiceClient {
|
|
10
|
-
constructor(_transport) {
|
|
11
|
-
this._transport = _transport;
|
|
12
|
-
this.typeName = ActionTransferService.typeName;
|
|
13
|
-
this.methods = ActionTransferService.methods;
|
|
14
|
-
this.options = ActionTransferService.options;
|
|
15
|
-
}
|
|
16
|
-
/**
|
|
17
|
-
* This behavior achieves a bi-directional stream so that both services aren't required to be a server & client on their own
|
|
18
|
-
*
|
|
19
|
-
* @generated from protobuf rpc: Transfer
|
|
20
|
-
*/
|
|
21
|
-
transfer(options) {
|
|
22
|
-
const method = this.methods[0], opt = this._transport.mergeOptions(options);
|
|
23
|
-
return stackIntercept("duplex", this._transport, method, opt);
|
|
24
|
-
}
|
|
25
|
-
}
|