foxconn-yumeeting-sdk-js
Version:
A js sdk for ion yumeeting
8 lines • 323 kB
JavaScript
var Signal=function(e){var t={};function r(o){if(t[o])return t[o].exports;var n=t[o]={i:o,l:!1,exports:{}};return e[o].call(n.exports,n,n.exports,r),n.l=!0,n.exports}return r.m=e,r.c=t,r.d=function(e,t,o){r.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:o})},r.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.t=function(e,t){if(1&t&&(e=r(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var o=Object.create(null);if(r.r(o),Object.defineProperty(o,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var n in e)r.d(o,n,function(t){return e[t]}.bind(null,n));return o},r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,"a",t),t},r.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r.p="",r(r.s=5)}([function(e,t,r){var o=r(8),n=o,i=Function("return this")();n.exportSymbol("proto.sfu.AnswerSignal",null,i),n.exportSymbol("proto.sfu.JoinReply",null,i),n.exportSymbol("proto.sfu.JoinRequest",null,i),n.exportSymbol("proto.sfu.OfferSignal",null,i),n.exportSymbol("proto.sfu.SignalReply",null,i),n.exportSymbol("proto.sfu.SignalReply.PayloadCase",null,i),n.exportSymbol("proto.sfu.SignalRequest",null,i),n.exportSymbol("proto.sfu.SignalRequest.PayloadCase",null,i),n.exportSymbol("proto.sfu.Trickle",null,i),n.exportSymbol("proto.sfu.Trickle.Target",null,i),proto.sfu.SignalRequest=function(e){o.Message.initialize(this,e,0,-1,null,proto.sfu.SignalRequest.oneofGroups_)},n.inherits(proto.sfu.SignalRequest,o.Message),n.DEBUG&&!COMPILED&&(proto.sfu.SignalRequest.displayName="proto.sfu.SignalRequest"),proto.sfu.SignalReply=function(e){o.Message.initialize(this,e,0,-1,null,proto.sfu.SignalReply.oneofGroups_)},n.inherits(proto.sfu.SignalReply,o.Message),n.DEBUG&&!COMPILED&&(proto.sfu.SignalReply.displayName="proto.sfu.SignalReply"),proto.sfu.JoinRequest=function(e){o.Message.initialize(this,e,0,-1,null,null)},n.inherits(proto.sfu.JoinRequest,o.Message),n.DEBUG&&!COMPILED&&(proto.sfu.JoinRequest.displayName="proto.sfu.JoinRequest"),proto.sfu.JoinReply=function(e){o.Message.initialize(this,e,0,-1,null,null)},n.inherits(proto.sfu.JoinReply,o.Message),n.DEBUG&&!COMPILED&&(proto.sfu.JoinReply.displayName="proto.sfu.JoinReply"),proto.sfu.Trickle=function(e){o.Message.initialize(this,e,0,-1,null,null)},n.inherits(proto.sfu.Trickle,o.Message),n.DEBUG&&!COMPILED&&(proto.sfu.Trickle.displayName="proto.sfu.Trickle"),proto.sfu.OfferSignal=function(e){o.Message.initialize(this,e,0,-1,null,null)},n.inherits(proto.sfu.OfferSignal,o.Message),n.DEBUG&&!COMPILED&&(proto.sfu.OfferSignal.displayName="proto.sfu.OfferSignal"),proto.sfu.AnswerSignal=function(e){o.Message.initialize(this,e,0,-1,null,null)},n.inherits(proto.sfu.AnswerSignal,o.Message),n.DEBUG&&!COMPILED&&(proto.sfu.AnswerSignal.displayName="proto.sfu.AnswerSignal"),proto.sfu.SignalRequest.oneofGroups_=[[2,3,4]],proto.sfu.SignalRequest.PayloadCase={PAYLOAD_NOT_SET:0,JOIN:2,DESCRIPTION:3,TRICKLE:4},proto.sfu.SignalRequest.prototype.getPayloadCase=function(){return o.Message.computeOneofCase(this,proto.sfu.SignalRequest.oneofGroups_[0])},o.Message.GENERATE_TO_OBJECT&&(proto.sfu.SignalRequest.prototype.toObject=function(e){return proto.sfu.SignalRequest.toObject(e,this)},proto.sfu.SignalRequest.toObject=function(e,t){var r,n={id:o.Message.getFieldWithDefault(t,1,""),join:(r=t.getJoin())&&proto.sfu.JoinRequest.toObject(e,r),description:t.getDescription_asB64(),trickle:(r=t.getTrickle())&&proto.sfu.Trickle.toObject(e,r)};return e&&(n.$jspbMessageInstance=t),n}),proto.sfu.SignalRequest.deserializeBinary=function(e){var t=new o.BinaryReader(e),r=new proto.sfu.SignalRequest;return proto.sfu.SignalRequest.deserializeBinaryFromReader(r,t)},proto.sfu.SignalRequest.deserializeBinaryFromReader=function(e,t){for(;t.nextField()&&!t.isEndGroup();){switch(t.getFieldNumber()){case 1:var r=t.readString();e.setId(r);break;case 2:r=new proto.sfu.JoinRequest;t.readMessage(r,proto.sfu.JoinRequest.deserializeBinaryFromReader),e.setJoin(r);break;case 3:r=t.readBytes();e.setDescription(r);break;case 4:r=new proto.sfu.Trickle;t.readMessage(r,proto.sfu.Trickle.deserializeBinaryFromReader),e.setTrickle(r);break;default:t.skipField()}}return e},proto.sfu.SignalRequest.prototype.serializeBinary=function(){var e=new o.BinaryWriter;return proto.sfu.SignalRequest.serializeBinaryToWriter(this,e),e.getResultBuffer()},proto.sfu.SignalRequest.serializeBinaryToWriter=function(e,t){var r=void 0;(r=e.getId()).length>0&&t.writeString(1,r),null!=(r=e.getJoin())&&t.writeMessage(2,r,proto.sfu.JoinRequest.serializeBinaryToWriter),null!=(r=o.Message.getField(e,3))&&t.writeBytes(3,r),null!=(r=e.getTrickle())&&t.writeMessage(4,r,proto.sfu.Trickle.serializeBinaryToWriter)},proto.sfu.SignalRequest.prototype.getId=function(){return o.Message.getFieldWithDefault(this,1,"")},proto.sfu.SignalRequest.prototype.setId=function(e){return o.Message.setProto3StringField(this,1,e)},proto.sfu.SignalRequest.prototype.getJoin=function(){return o.Message.getWrapperField(this,proto.sfu.JoinRequest,2)},proto.sfu.SignalRequest.prototype.setJoin=function(e){return o.Message.setOneofWrapperField(this,2,proto.sfu.SignalRequest.oneofGroups_[0],e)},proto.sfu.SignalRequest.prototype.clearJoin=function(){return this.setJoin(void 0)},proto.sfu.SignalRequest.prototype.hasJoin=function(){return null!=o.Message.getField(this,2)},proto.sfu.SignalRequest.prototype.getDescription=function(){return o.Message.getFieldWithDefault(this,3,"")},proto.sfu.SignalRequest.prototype.getDescription_asB64=function(){return o.Message.bytesAsB64(this.getDescription())},proto.sfu.SignalRequest.prototype.getDescription_asU8=function(){return o.Message.bytesAsU8(this.getDescription())},proto.sfu.SignalRequest.prototype.setDescription=function(e){return o.Message.setOneofField(this,3,proto.sfu.SignalRequest.oneofGroups_[0],e)},proto.sfu.SignalRequest.prototype.clearDescription=function(){return o.Message.setOneofField(this,3,proto.sfu.SignalRequest.oneofGroups_[0],void 0)},proto.sfu.SignalRequest.prototype.hasDescription=function(){return null!=o.Message.getField(this,3)},proto.sfu.SignalRequest.prototype.getTrickle=function(){return o.Message.getWrapperField(this,proto.sfu.Trickle,4)},proto.sfu.SignalRequest.prototype.setTrickle=function(e){return o.Message.setOneofWrapperField(this,4,proto.sfu.SignalRequest.oneofGroups_[0],e)},proto.sfu.SignalRequest.prototype.clearTrickle=function(){return this.setTrickle(void 0)},proto.sfu.SignalRequest.prototype.hasTrickle=function(){return null!=o.Message.getField(this,4)},proto.sfu.SignalReply.oneofGroups_=[[2,3,4,5,6]],proto.sfu.SignalReply.PayloadCase={PAYLOAD_NOT_SET:0,JOIN:2,DESCRIPTION:3,TRICKLE:4,ICECONNECTIONSTATE:5,ERROR:6},proto.sfu.SignalReply.prototype.getPayloadCase=function(){return o.Message.computeOneofCase(this,proto.sfu.SignalReply.oneofGroups_[0])},o.Message.GENERATE_TO_OBJECT&&(proto.sfu.SignalReply.prototype.toObject=function(e){return proto.sfu.SignalReply.toObject(e,this)},proto.sfu.SignalReply.toObject=function(e,t){var r,n={id:o.Message.getFieldWithDefault(t,1,""),join:(r=t.getJoin())&&proto.sfu.JoinReply.toObject(e,r),description:t.getDescription_asB64(),trickle:(r=t.getTrickle())&&proto.sfu.Trickle.toObject(e,r),iceconnectionstate:o.Message.getFieldWithDefault(t,5,""),error:o.Message.getFieldWithDefault(t,6,"")};return e&&(n.$jspbMessageInstance=t),n}),proto.sfu.SignalReply.deserializeBinary=function(e){var t=new o.BinaryReader(e),r=new proto.sfu.SignalReply;return proto.sfu.SignalReply.deserializeBinaryFromReader(r,t)},proto.sfu.SignalReply.deserializeBinaryFromReader=function(e,t){for(;t.nextField()&&!t.isEndGroup();){switch(t.getFieldNumber()){case 1:var r=t.readString();e.setId(r);break;case 2:r=new proto.sfu.JoinReply;t.readMessage(r,proto.sfu.JoinReply.deserializeBinaryFromReader),e.setJoin(r);break;case 3:r=t.readBytes();e.setDescription(r);break;case 4:r=new proto.sfu.Trickle;t.readMessage(r,proto.sfu.Trickle.deserializeBinaryFromReader),e.setTrickle(r);break;case 5:r=t.readString();e.setIceconnectionstate(r);break;case 6:r=t.readString();e.setError(r);break;default:t.skipField()}}return e},proto.sfu.SignalReply.prototype.serializeBinary=function(){var e=new o.BinaryWriter;return proto.sfu.SignalReply.serializeBinaryToWriter(this,e),e.getResultBuffer()},proto.sfu.SignalReply.serializeBinaryToWriter=function(e,t){var r=void 0;(r=e.getId()).length>0&&t.writeString(1,r),null!=(r=e.getJoin())&&t.writeMessage(2,r,proto.sfu.JoinReply.serializeBinaryToWriter),null!=(r=o.Message.getField(e,3))&&t.writeBytes(3,r),null!=(r=e.getTrickle())&&t.writeMessage(4,r,proto.sfu.Trickle.serializeBinaryToWriter),null!=(r=o.Message.getField(e,5))&&t.writeString(5,r),null!=(r=o.Message.getField(e,6))&&t.writeString(6,r)},proto.sfu.SignalReply.prototype.getId=function(){return o.Message.getFieldWithDefault(this,1,"")},proto.sfu.SignalReply.prototype.setId=function(e){return o.Message.setProto3StringField(this,1,e)},proto.sfu.SignalReply.prototype.getJoin=function(){return o.Message.getWrapperField(this,proto.sfu.JoinReply,2)},proto.sfu.SignalReply.prototype.setJoin=function(e){return o.Message.setOneofWrapperField(this,2,proto.sfu.SignalReply.oneofGroups_[0],e)},proto.sfu.SignalReply.prototype.clearJoin=function(){return this.setJoin(void 0)},proto.sfu.SignalReply.prototype.hasJoin=function(){return null!=o.Message.getField(this,2)},proto.sfu.SignalReply.prototype.getDescription=function(){return o.Message.getFieldWithDefault(this,3,"")},proto.sfu.SignalReply.prototype.getDescription_asB64=function(){return o.Message.bytesAsB64(this.getDescription())},proto.sfu.SignalReply.prototype.getDescription_asU8=function(){return o.Message.bytesAsU8(this.getDescription())},proto.sfu.SignalReply.prototype.setDescription=function(e){return o.Message.setOneofField(this,3,proto.sfu.SignalReply.oneofGroups_[0],e)},proto.sfu.SignalReply.prototype.clearDescription=function(){return o.Message.setOneofField(this,3,proto.sfu.SignalReply.oneofGroups_[0],void 0)},proto.sfu.SignalReply.prototype.hasDescription=function(){return null!=o.Message.getField(this,3)},proto.sfu.SignalReply.prototype.getTrickle=function(){return o.Message.getWrapperField(this,proto.sfu.Trickle,4)},proto.sfu.SignalReply.prototype.setTrickle=function(e){return o.Message.setOneofWrapperField(this,4,proto.sfu.SignalReply.oneofGroups_[0],e)},proto.sfu.SignalReply.prototype.clearTrickle=function(){return this.setTrickle(void 0)},proto.sfu.SignalReply.prototype.hasTrickle=function(){return null!=o.Message.getField(this,4)},proto.sfu.SignalReply.prototype.getIceconnectionstate=function(){return o.Message.getFieldWithDefault(this,5,"")},proto.sfu.SignalReply.prototype.setIceconnectionstate=function(e){return o.Message.setOneofField(this,5,proto.sfu.SignalReply.oneofGroups_[0],e)},proto.sfu.SignalReply.prototype.clearIceconnectionstate=function(){return o.Message.setOneofField(this,5,proto.sfu.SignalReply.oneofGroups_[0],void 0)},proto.sfu.SignalReply.prototype.hasIceconnectionstate=function(){return null!=o.Message.getField(this,5)},proto.sfu.SignalReply.prototype.getError=function(){return o.Message.getFieldWithDefault(this,6,"")},proto.sfu.SignalReply.prototype.setError=function(e){return o.Message.setOneofField(this,6,proto.sfu.SignalReply.oneofGroups_[0],e)},proto.sfu.SignalReply.prototype.clearError=function(){return o.Message.setOneofField(this,6,proto.sfu.SignalReply.oneofGroups_[0],void 0)},proto.sfu.SignalReply.prototype.hasError=function(){return null!=o.Message.getField(this,6)},o.Message.GENERATE_TO_OBJECT&&(proto.sfu.JoinRequest.prototype.toObject=function(e){return proto.sfu.JoinRequest.toObject(e,this)},proto.sfu.JoinRequest.toObject=function(e,t){var r,n={sid:o.Message.getFieldWithDefault(t,1,""),uid:o.Message.getFieldWithDefault(t,2,""),description:t.getDescription_asB64(),configMap:(r=t.getConfigMap())?r.toObject(e,void 0):[]};return e&&(n.$jspbMessageInstance=t),n}),proto.sfu.JoinRequest.deserializeBinary=function(e){var t=new o.BinaryReader(e),r=new proto.sfu.JoinRequest;return proto.sfu.JoinRequest.deserializeBinaryFromReader(r,t)},proto.sfu.JoinRequest.deserializeBinaryFromReader=function(e,t){for(;t.nextField()&&!t.isEndGroup();){switch(t.getFieldNumber()){case 1:var r=t.readString();e.setSid(r);break;case 2:r=t.readString();e.setUid(r);break;case 3:r=t.readBytes();e.setDescription(r);break;case 4:r=e.getConfigMap();t.readMessage(r,function(e,t){o.Map.deserializeBinary(e,t,o.BinaryReader.prototype.readString,o.BinaryReader.prototype.readString,null,"","")});break;default:t.skipField()}}return e},proto.sfu.JoinRequest.prototype.serializeBinary=function(){var e=new o.BinaryWriter;return proto.sfu.JoinRequest.serializeBinaryToWriter(this,e),e.getResultBuffer()},proto.sfu.JoinRequest.serializeBinaryToWriter=function(e,t){var r=void 0;(r=e.getSid()).length>0&&t.writeString(1,r),(r=e.getUid()).length>0&&t.writeString(2,r),(r=e.getDescription_asU8()).length>0&&t.writeBytes(3,r),(r=e.getConfigMap(!0))&&r.getLength()>0&&r.serializeBinary(4,t,o.BinaryWriter.prototype.writeString,o.BinaryWriter.prototype.writeString)},proto.sfu.JoinRequest.prototype.getSid=function(){return o.Message.getFieldWithDefault(this,1,"")},proto.sfu.JoinRequest.prototype.setSid=function(e){return o.Message.setProto3StringField(this,1,e)},proto.sfu.JoinRequest.prototype.getUid=function(){return o.Message.getFieldWithDefault(this,2,"")},proto.sfu.JoinRequest.prototype.setUid=function(e){return o.Message.setProto3StringField(this,2,e)},proto.sfu.JoinRequest.prototype.getDescription=function(){return o.Message.getFieldWithDefault(this,3,"")},proto.sfu.JoinRequest.prototype.getDescription_asB64=function(){return o.Message.bytesAsB64(this.getDescription())},proto.sfu.JoinRequest.prototype.getDescription_asU8=function(){return o.Message.bytesAsU8(this.getDescription())},proto.sfu.JoinRequest.prototype.setDescription=function(e){return o.Message.setProto3BytesField(this,3,e)},proto.sfu.JoinRequest.prototype.getConfigMap=function(e){return o.Message.getMapField(this,4,e,null)},proto.sfu.JoinRequest.prototype.clearConfigMap=function(){return this.getConfigMap().clear(),this},o.Message.GENERATE_TO_OBJECT&&(proto.sfu.JoinReply.prototype.toObject=function(e){return proto.sfu.JoinReply.toObject(e,this)},proto.sfu.JoinReply.toObject=function(e,t){var r={description:t.getDescription_asB64()};return e&&(r.$jspbMessageInstance=t),r}),proto.sfu.JoinReply.deserializeBinary=function(e){var t=new o.BinaryReader(e),r=new proto.sfu.JoinReply;return proto.sfu.JoinReply.deserializeBinaryFromReader(r,t)},proto.sfu.JoinReply.deserializeBinaryFromReader=function(e,t){for(;t.nextField()&&!t.isEndGroup();){switch(t.getFieldNumber()){case 1:var r=t.readBytes();e.setDescription(r);break;default:t.skipField()}}return e},proto.sfu.JoinReply.prototype.serializeBinary=function(){var e=new o.BinaryWriter;return proto.sfu.JoinReply.serializeBinaryToWriter(this,e),e.getResultBuffer()},proto.sfu.JoinReply.serializeBinaryToWriter=function(e,t){var r;(r=e.getDescription_asU8()).length>0&&t.writeBytes(1,r)},proto.sfu.JoinReply.prototype.getDescription=function(){return o.Message.getFieldWithDefault(this,1,"")},proto.sfu.JoinReply.prototype.getDescription_asB64=function(){return o.Message.bytesAsB64(this.getDescription())},proto.sfu.JoinReply.prototype.getDescription_asU8=function(){return o.Message.bytesAsU8(this.getDescription())},proto.sfu.JoinReply.prototype.setDescription=function(e){return o.Message.setProto3BytesField(this,1,e)},o.Message.GENERATE_TO_OBJECT&&(proto.sfu.Trickle.prototype.toObject=function(e){return proto.sfu.Trickle.toObject(e,this)},proto.sfu.Trickle.toObject=function(e,t){var r={target:o.Message.getFieldWithDefault(t,1,0),init:o.Message.getFieldWithDefault(t,2,"")};return e&&(r.$jspbMessageInstance=t),r}),proto.sfu.Trickle.deserializeBinary=function(e){var t=new o.BinaryReader(e),r=new proto.sfu.Trickle;return proto.sfu.Trickle.deserializeBinaryFromReader(r,t)},proto.sfu.Trickle.deserializeBinaryFromReader=function(e,t){for(;t.nextField()&&!t.isEndGroup();){switch(t.getFieldNumber()){case 1:var r=t.readEnum();e.setTarget(r);break;case 2:r=t.readString();e.setInit(r);break;default:t.skipField()}}return e},proto.sfu.Trickle.prototype.serializeBinary=function(){var e=new o.BinaryWriter;return proto.sfu.Trickle.serializeBinaryToWriter(this,e),e.getResultBuffer()},proto.sfu.Trickle.serializeBinaryToWriter=function(e,t){var r=void 0;0!==(r=e.getTarget())&&t.writeEnum(1,r),(r=e.getInit()).length>0&&t.writeString(2,r)},proto.sfu.Trickle.Target={PUBLISHER:0,SUBSCRIBER:1},proto.sfu.Trickle.prototype.getTarget=function(){return o.Message.getFieldWithDefault(this,1,0)},proto.sfu.Trickle.prototype.setTarget=function(e){return o.Message.setProto3EnumField(this,1,e)},proto.sfu.Trickle.prototype.getInit=function(){return o.Message.getFieldWithDefault(this,2,"")},proto.sfu.Trickle.prototype.setInit=function(e){return o.Message.setProto3StringField(this,2,e)},o.Message.GENERATE_TO_OBJECT&&(proto.sfu.OfferSignal.prototype.toObject=function(e){return proto.sfu.OfferSignal.toObject(e,this)},proto.sfu.OfferSignal.toObject=function(e,t){var r={nid:o.Message.getFieldWithDefault(t,1,""),uid:o.Message.getFieldWithDefault(t,2,""),sid:o.Message.getFieldWithDefault(t,3,""),signal:t.getSignal_asB64(),sendlocalvideo:o.Message.getBooleanFieldWithDefault(t,5,!1)};return e&&(r.$jspbMessageInstance=t),r}),proto.sfu.OfferSignal.deserializeBinary=function(e){var t=new o.BinaryReader(e),r=new proto.sfu.OfferSignal;return proto.sfu.OfferSignal.deserializeBinaryFromReader(r,t)},proto.sfu.OfferSignal.deserializeBinaryFromReader=function(e,t){for(;t.nextField()&&!t.isEndGroup();){switch(t.getFieldNumber()){case 1:var r=t.readString();e.setNid(r);break;case 2:r=t.readString();e.setUid(r);break;case 3:r=t.readString();e.setSid(r);break;case 4:r=t.readBytes();e.setSignal(r);break;case 5:r=t.readBool();e.setSendlocalvideo(r);break;default:t.skipField()}}return e},proto.sfu.OfferSignal.prototype.serializeBinary=function(){var e=new o.BinaryWriter;return proto.sfu.OfferSignal.serializeBinaryToWriter(this,e),e.getResultBuffer()},proto.sfu.OfferSignal.serializeBinaryToWriter=function(e,t){var r=void 0;(r=e.getNid()).length>0&&t.writeString(1,r),(r=e.getUid()).length>0&&t.writeString(2,r),(r=e.getSid()).length>0&&t.writeString(3,r),(r=e.getSignal_asU8()).length>0&&t.writeBytes(4,r),(r=e.getSendlocalvideo())&&t.writeBool(5,r)},proto.sfu.OfferSignal.prototype.getNid=function(){return o.Message.getFieldWithDefault(this,1,"")},proto.sfu.OfferSignal.prototype.setNid=function(e){return o.Message.setProto3StringField(this,1,e)},proto.sfu.OfferSignal.prototype.getUid=function(){return o.Message.getFieldWithDefault(this,2,"")},proto.sfu.OfferSignal.prototype.setUid=function(e){return o.Message.setProto3StringField(this,2,e)},proto.sfu.OfferSignal.prototype.getSid=function(){return o.Message.getFieldWithDefault(this,3,"")},proto.sfu.OfferSignal.prototype.setSid=function(e){return o.Message.setProto3StringField(this,3,e)},proto.sfu.OfferSignal.prototype.getSignal=function(){return o.Message.getFieldWithDefault(this,4,"")},proto.sfu.OfferSignal.prototype.getSignal_asB64=function(){return o.Message.bytesAsB64(this.getSignal())},proto.sfu.OfferSignal.prototype.getSignal_asU8=function(){return o.Message.bytesAsU8(this.getSignal())},proto.sfu.OfferSignal.prototype.setSignal=function(e){return o.Message.setProto3BytesField(this,4,e)},proto.sfu.OfferSignal.prototype.getSendlocalvideo=function(){return o.Message.getBooleanFieldWithDefault(this,5,!1)},proto.sfu.OfferSignal.prototype.setSendlocalvideo=function(e){return o.Message.setProto3BooleanField(this,5,e)},o.Message.GENERATE_TO_OBJECT&&(proto.sfu.AnswerSignal.prototype.toObject=function(e){return proto.sfu.AnswerSignal.toObject(e,this)},proto.sfu.AnswerSignal.toObject=function(e,t){var r={signal:t.getSignal_asB64()};return e&&(r.$jspbMessageInstance=t),r}),proto.sfu.AnswerSignal.deserializeBinary=function(e){var t=new o.BinaryReader(e),r=new proto.sfu.AnswerSignal;return proto.sfu.AnswerSignal.deserializeBinaryFromReader(r,t)},proto.sfu.AnswerSignal.deserializeBinaryFromReader=function(e,t){for(;t.nextField()&&!t.isEndGroup();){switch(t.getFieldNumber()){case 1:var r=t.readBytes();e.setSignal(r);break;default:t.skipField()}}return e},proto.sfu.AnswerSignal.prototype.serializeBinary=function(){var e=new o.BinaryWriter;return proto.sfu.AnswerSignal.serializeBinaryToWriter(this,e),e.getResultBuffer()},proto.sfu.AnswerSignal.serializeBinaryToWriter=function(e,t){var r;(r=e.getSignal_asU8()).length>0&&t.writeBytes(1,r)},proto.sfu.AnswerSignal.prototype.getSignal=function(){return o.Message.getFieldWithDefault(this,1,"")},proto.sfu.AnswerSignal.prototype.getSignal_asB64=function(){return o.Message.bytesAsB64(this.getSignal())},proto.sfu.AnswerSignal.prototype.getSignal_asU8=function(){return o.Message.bytesAsU8(this.getSignal())},proto.sfu.AnswerSignal.prototype.setSignal=function(e){return o.Message.setProto3BytesField(this,1,e)},n.object.extend(t,proto.sfu)},function(e,t){var r;r=function(){return this}();try{r=r||new Function("return this")()}catch(e){"object"==typeof window&&(r=window)}e.exports=r},function(e,t,r){e.exports=function(e){var t={};function r(o){if(t[o])return t[o].exports;var n=t[o]={i:o,l:!1,exports:{}};return e[o].call(n.exports,n,n.exports,r),n.l=!0,n.exports}return r.m=e,r.c=t,r.d=function(e,t,o){r.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:o})},r.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.t=function(e,t){if(1&t&&(e=r(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var o=Object.create(null);if(r.r(o),Object.defineProperty(o,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var n in e)r.d(o,n,function(t){return e[t]}.bind(null,n));return o},r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,"a",t),t},r.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r.p="",r(r.s=10)}([function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=r(3);t.Metadata=o.BrowserHeaders},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.debug=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];console.debug?console.debug.apply(null,e):console.log.apply(null,e)}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=r(0),n=r(8),i=r(9),s=r(1),a=r(4),g=r(14);t.client=function(e,t){return new u(e,t)};var u=function(){function e(e,t){this.started=!1,this.sentFirstMessage=!1,this.completed=!1,this.closed=!1,this.finishedSending=!1,this.onHeadersCallbacks=[],this.onMessageCallbacks=[],this.onEndCallbacks=[],this.parser=new n.ChunkParser,this.methodDefinition=e,this.props=t,this.createTransport()}return e.prototype.createTransport=function(){var e=this.props.host+"/"+this.methodDefinition.service.serviceName+"/"+this.methodDefinition.methodName,t={methodDefinition:this.methodDefinition,debug:this.props.debug||!1,url:e,onHeaders:this.onTransportHeaders.bind(this),onChunk:this.onTransportChunk.bind(this),onEnd:this.onTransportEnd.bind(this)};this.props.transport?this.transport=this.props.transport(t):this.transport=a.makeDefaultTransport(t)},e.prototype.onTransportHeaders=function(e,t){if(this.props.debug&&s.debug("onHeaders",e,t),this.closed)this.props.debug&&s.debug("grpc.onHeaders received after request was closed - ignoring");else if(0===t);else{this.responseHeaders=e,this.props.debug&&s.debug("onHeaders.responseHeaders",JSON.stringify(this.responseHeaders,null,2));var r=l(e);this.props.debug&&s.debug("onHeaders.gRPCStatus",r);var o=r&&r>=0?r:i.httpStatusToCode(t);this.props.debug&&s.debug("onHeaders.code",o);var n=e.get("grpc-message")||[];if(this.props.debug&&s.debug("onHeaders.gRPCMessage",n),this.rawOnHeaders(e),o!==i.Code.OK){var a=this.decodeGRPCStatus(n[0]);this.rawOnError(o,a,e)}}},e.prototype.onTransportChunk=function(e){var t=this;if(this.closed)this.props.debug&&s.debug("grpc.onChunk received after request was closed - ignoring");else{var r=[];try{r=this.parser.parse(e)}catch(e){return this.props.debug&&s.debug("onChunk.parsing error",e,e.message),void this.rawOnError(i.Code.Internal,"parsing error: "+e.message)}r.forEach(function(e){if(e.chunkType===n.ChunkType.MESSAGE){var r=t.methodDefinition.responseType.deserializeBinary(e.data);t.rawOnMessage(r)}else e.chunkType===n.ChunkType.TRAILERS&&(t.responseHeaders?(t.responseTrailers=new o.Metadata(e.trailers),t.props.debug&&s.debug("onChunk.trailers",t.responseTrailers)):(t.responseHeaders=new o.Metadata(e.trailers),t.rawOnHeaders(t.responseHeaders)))})}},e.prototype.onTransportEnd=function(){if(this.props.debug&&s.debug("grpc.onEnd"),this.closed)this.props.debug&&s.debug("grpc.onEnd received after request was closed - ignoring");else if(void 0!==this.responseTrailers){var e=l(this.responseTrailers);if(null!==e){var t=this.responseTrailers.get("grpc-message"),r=this.decodeGRPCStatus(t[0]);this.rawOnEnd(e,r,this.responseTrailers)}else this.rawOnError(i.Code.Internal,"Response closed without grpc-status (Trailers provided)")}else{if(void 0===this.responseHeaders)return void this.rawOnError(i.Code.Unknown,"Response closed without headers");var o=l(this.responseHeaders),n=this.responseHeaders.get("grpc-message");if(this.props.debug&&s.debug("grpc.headers only response ",o,n),null===o)return void this.rawOnEnd(i.Code.Unknown,"Response closed without grpc-status (Headers only)",this.responseHeaders);var a=this.decodeGRPCStatus(n[0]);this.rawOnEnd(o,a,this.responseHeaders)}},e.prototype.decodeGRPCStatus=function(e){if(!e)return"";try{return decodeURIComponent(e)}catch(t){return e}},e.prototype.rawOnEnd=function(e,t,r){var o=this;this.props.debug&&s.debug("rawOnEnd",e,t,r),this.completed||(this.completed=!0,this.onEndCallbacks.forEach(function(n){if(!o.closed)try{n(e,t,r)}catch(e){setTimeout(function(){throw e})}}))},e.prototype.rawOnHeaders=function(e){this.props.debug&&s.debug("rawOnHeaders",e),this.completed||this.onHeadersCallbacks.forEach(function(t){try{t(e)}catch(e){setTimeout(function(){throw e})}})},e.prototype.rawOnError=function(e,t,r){var n=this;void 0===r&&(r=new o.Metadata),this.props.debug&&s.debug("rawOnError",e,t),this.completed||(this.completed=!0,this.onEndCallbacks.forEach(function(o){if(!n.closed)try{o(e,t,r)}catch(e){setTimeout(function(){throw e})}}))},e.prototype.rawOnMessage=function(e){var t=this;this.props.debug&&s.debug("rawOnMessage",e.toObject()),this.completed||this.closed||this.onMessageCallbacks.forEach(function(r){if(!t.closed)try{r(e)}catch(e){setTimeout(function(){throw e})}})},e.prototype.onHeaders=function(e){this.onHeadersCallbacks.push(e)},e.prototype.onMessage=function(e){this.onMessageCallbacks.push(e)},e.prototype.onEnd=function(e){this.onEndCallbacks.push(e)},e.prototype.start=function(e){if(this.started)throw new Error("Client already started - cannot .start()");this.started=!0;var t=new o.Metadata(e||{});t.set("content-type","application/grpc-web+proto"),t.set("x-grpc-web","1"),this.transport.start(t)},e.prototype.send=function(e){if(!this.started)throw new Error("Client not started - .start() must be called before .send()");if(this.closed)throw new Error("Client already closed - cannot .send()");if(this.finishedSending)throw new Error("Client already finished sending - cannot .send()");if(!this.methodDefinition.requestStream&&this.sentFirstMessage)throw new Error("Message already sent for non-client-streaming method - cannot .send()");this.sentFirstMessage=!0;var t=g.frameRequest(e);this.transport.sendMessage(t)},e.prototype.finishSend=function(){if(!this.started)throw new Error("Client not started - .finishSend() must be called before .close()");if(this.closed)throw new Error("Client already closed - cannot .send()");if(this.finishedSending)throw new Error("Client already finished sending - cannot .finishSend()");this.finishedSending=!0,this.transport.finishSend()},e.prototype.close=function(){if(!this.started)throw new Error("Client not started - .start() must be called before .close()");if(this.closed)throw new Error("Client already closed - cannot .close()");this.closed=!0,this.props.debug&&s.debug("request.abort aborting request"),this.transport.cancel()},e}();function l(e){var t=e.get("grpc-status")||[];if(t.length>0)try{var r=t[0];return parseInt(r,10)}catch(e){return null}return null}},function(e,t,r){var o;o=function(){return function(e){var t={};function r(o){if(t[o])return t[o].exports;var n=t[o]={i:o,l:!1,exports:{}};return e[o].call(n.exports,n,n.exports,r),n.l=!0,n.exports}return r.m=e,r.c=t,r.i=function(e){return e},r.d=function(e,t,o){r.o(e,t)||Object.defineProperty(e,t,{configurable:!1,enumerable:!0,get:o})},r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,"a",t),t},r.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r.p="",r(r.s=1)}([function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=r(3),n=function(){function e(e,t){void 0===e&&(e={}),void 0===t&&(t={splitValues:!1});var r,n=this;this.headersMap={},e&&("undefined"!=typeof Headers&&e instanceof Headers?o.getHeaderKeys(e).forEach(function(r){o.getHeaderValues(e,r).forEach(function(e){t.splitValues?n.append(r,o.splitHeaderValue(e)):n.append(r,e)})}):"object"==typeof(r=e)&&"object"==typeof r.headersMap&&"function"==typeof r.forEach?e.forEach(function(e,t){n.append(e,t)}):"undefined"!=typeof Map&&e instanceof Map?e.forEach(function(e,t){n.append(t,e)}):"string"==typeof e?this.appendFromString(e):"object"==typeof e&&Object.getOwnPropertyNames(e).forEach(function(t){var r=e[t];Array.isArray(r)?r.forEach(function(e){n.append(t,e)}):n.append(t,r)}))}return e.prototype.appendFromString=function(e){for(var t=e.split("\r\n"),r=0;r<t.length;r++){var o=t[r],n=o.indexOf(":");if(n>0){var i=o.substring(0,n).trim(),s=o.substring(n+1).trim();this.append(i,s)}}},e.prototype.delete=function(e,t){var r=o.normalizeName(e);if(void 0===t)delete this.headersMap[r];else{var n=this.headersMap[r];if(n){var i=n.indexOf(t);i>=0&&n.splice(i,1),0===n.length&&delete this.headersMap[r]}}},e.prototype.append=function(e,t){var r=this,n=o.normalizeName(e);Array.isArray(this.headersMap[n])||(this.headersMap[n]=[]),Array.isArray(t)?t.forEach(function(e){r.headersMap[n].push(o.normalizeValue(e))}):this.headersMap[n].push(o.normalizeValue(t))},e.prototype.set=function(e,t){var r=o.normalizeName(e);if(Array.isArray(t)){var n=[];t.forEach(function(e){n.push(o.normalizeValue(e))}),this.headersMap[r]=n}else this.headersMap[r]=[o.normalizeValue(t)]},e.prototype.has=function(e,t){var r=this.headersMap[o.normalizeName(e)];if(!Array.isArray(r))return!1;if(void 0!==t){var n=o.normalizeValue(t);return r.indexOf(n)>=0}return!0},e.prototype.get=function(e){var t=this.headersMap[o.normalizeName(e)];return void 0!==t?t.concat():[]},e.prototype.forEach=function(e){var t=this;Object.getOwnPropertyNames(this.headersMap).forEach(function(r){e(r,t.headersMap[r])},this)},e.prototype.toHeaders=function(){if("undefined"!=typeof Headers){var e=new Headers;return this.forEach(function(t,r){r.forEach(function(r){e.append(t,r)})}),e}throw new Error("Headers class is not defined")},e}();t.BrowserHeaders=n},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=r(0);t.BrowserHeaders=o.BrowserHeaders},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.iterateHeaders=function(e,t){for(var r=e[Symbol.iterator](),o=r.next();!o.done;)t(o.value[0]),o=r.next()},t.iterateHeadersKeys=function(e,t){for(var r=e.keys(),o=r.next();!o.done;)t(o.value),o=r.next()}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=r(2);function n(e){return e}t.normalizeName=function(e){if("string"!=typeof e&&(e=String(e)),/[^a-z0-9\-#$%&'*+.\^_`|~]/i.test(e))throw new TypeError("Invalid character in header field name");return e.toLowerCase()},t.normalizeValue=function(e){return"string"!=typeof e&&(e=String(e)),e},t.getHeaderValues=function(e,t){var r=n(e);if(r instanceof Headers&&r.getAll)return r.getAll(t);var o=r.get(t);return o&&"string"==typeof o?[o]:o},t.getHeaderKeys=function(e){var t=n(e),r={},i=[];return t.keys?o.iterateHeadersKeys(t,function(e){r[e]||(r[e]=!0,i.push(e))}):t.forEach?t.forEach(function(e,t){r[t]||(r[t]=!0,i.push(t))}):o.iterateHeaders(t,function(e){var t=e[0];r[t]||(r[t]=!0,i.push(t))}),i},t.splitHeaderValue=function(e){var t=[];return e.split(", ").forEach(function(e){e.split(",").forEach(function(e){t.push(e)})}),t}}])},e.exports=o()},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=r(5),n=function(e){return o.CrossBrowserHttpTransport({withCredentials:!1})(e)};t.setDefaultTransportFactory=function(e){n=e},t.makeDefaultTransport=function(e){return n(e)}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=r(6),n=r(7);t.CrossBrowserHttpTransport=function(e){if(o.detectFetchSupport()){var t={credentials:e.withCredentials?"include":"same-origin"};return o.FetchReadableStreamTransport(t)}return n.XhrTransport({withCredentials:e.withCredentials})}},function(e,t,r){"use strict";var o=this&&this.__assign||function(){return(o=Object.assign||function(e){for(var t,r=1,o=arguments.length;r<o;r++)for(var n in t=arguments[r])Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0});var n=r(0),i=r(1);t.FetchReadableStreamTransport=function(e){return function(t){return function(e,t){return e.debug&&i.debug("fetchRequest",e),new s(e,t)}(t,e)}};var s=function(){function e(e,t){this.cancelled=!1,this.controller=self.AbortController&&new AbortController,this.options=e,this.init=t}return e.prototype.pump=function(e,t){var r=this;if(this.reader=e,this.cancelled)return this.options.debug&&i.debug("Fetch.pump.cancel at first pump"),void this.reader.cancel();this.reader.read().then(function(e){if(e.done)return r.options.onEnd(),t;r.options.onChunk(e.value),r.pump(r.reader,t)}).catch(function(e){r.cancelled?r.options.debug&&i.debug("Fetch.catch - request cancelled"):(r.cancelled=!0,r.options.debug&&i.debug("Fetch.catch",e.message),r.options.onEnd(e))})},e.prototype.send=function(e){var t=this;fetch(this.options.url,o({},this.init,{headers:this.metadata.toHeaders(),method:"POST",body:e,signal:this.controller&&this.controller.signal})).then(function(e){if(t.options.debug&&i.debug("Fetch.response",e),t.options.onHeaders(new n.Metadata(e.headers),e.status),!e.body)return e;t.pump(e.body.getReader(),e)}).catch(function(e){t.cancelled?t.options.debug&&i.debug("Fetch.catch - request cancelled"):(t.cancelled=!0,t.options.debug&&i.debug("Fetch.catch",e.message),t.options.onEnd(e))})},e.prototype.sendMessage=function(e){this.send(e)},e.prototype.finishSend=function(){},e.prototype.start=function(e){this.metadata=e},e.prototype.cancel=function(){this.cancelled?this.options.debug&&i.debug("Fetch.abort.cancel already cancelled"):(this.cancelled=!0,this.reader?(this.options.debug&&i.debug("Fetch.abort.cancel"),this.reader.cancel()):this.options.debug&&i.debug("Fetch.abort.cancel before reader"),this.controller&&this.controller.abort())},e}();t.detectFetchSupport=function(){return"undefined"!=typeof Response&&Response.prototype.hasOwnProperty("body")&&"function"==typeof Headers}},function(e,t,r){"use strict";var o,n=this&&this.__extends||(o=function(e,t){return(o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)},function(e,t){function r(){this.constructor=e}o(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0});var i=r(0),s=r(1),a=r(11);t.XhrTransport=function(e){return function(t){if(a.detectMozXHRSupport())return new u(t,e);if(a.detectXHROverrideMimeTypeSupport())return new g(t,e);throw new Error("This environment's XHR implementation cannot support binary transfer.")}};var g=function(){function e(e,t){this.options=e,this.init=t}return e.prototype.onProgressEvent=function(){this.options.debug&&s.debug("XHR.onProgressEvent.length: ",this.xhr.response.length);var e=this.xhr.response.substr(this.index);this.index=this.xhr.response.length;var t=p(e);this.options.onChunk(t)},e.prototype.onLoadEvent=function(){this.options.debug&&s.debug("XHR.onLoadEvent"),this.options.onEnd()},e.prototype.onStateChange=function(){this.options.debug&&s.debug("XHR.onStateChange",this.xhr.readyState),this.xhr.readyState===XMLHttpRequest.HEADERS_RECEIVED&&this.options.onHeaders(new i.Metadata(this.xhr.getAllResponseHeaders()),this.xhr.status)},e.prototype.sendMessage=function(e){this.xhr.send(e)},e.prototype.finishSend=function(){},e.prototype.start=function(e){var t=this;this.metadata=e;var r=new XMLHttpRequest;this.xhr=r,r.open("POST",this.options.url),this.configureXhr(),this.metadata.forEach(function(e,t){r.setRequestHeader(e,t.join(", "))}),r.withCredentials=Boolean(this.init.withCredentials),r.addEventListener("readystatechange",this.onStateChange.bind(this)),r.addEventListener("progress",this.onProgressEvent.bind(this)),r.addEventListener("loadend",this.onLoadEvent.bind(this)),r.addEventListener("error",function(e){t.options.debug&&s.debug("XHR.error",e),t.options.onEnd(e.error)})},e.prototype.configureXhr=function(){this.xhr.responseType="text",this.xhr.overrideMimeType("text/plain; charset=x-user-defined")},e.prototype.cancel=function(){this.options.debug&&s.debug("XHR.abort"),this.xhr.abort()},e}();t.XHR=g;var u=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return n(t,e),t.prototype.configureXhr=function(){this.options.debug&&s.debug("MozXHR.configureXhr: setting responseType to 'moz-chunked-arraybuffer'"),this.xhr.responseType="moz-chunked-arraybuffer"},t.prototype.onProgressEvent=function(){var e=this.xhr.response;this.options.debug&&s.debug("MozXHR.onProgressEvent: ",new Uint8Array(e)),this.options.onChunk(new Uint8Array(e))},t}(g);function l(e,t){var r=e.charCodeAt(t);if(r>=55296&&r<=56319){var o=e.charCodeAt(t+1);o>=56320&&o<=57343&&(r=65536+(r-55296<<10)+(o-56320))}return r}function p(e){for(var t=new Uint8Array(e.length),r=0,o=0;o<e.length;o++){var n=String.prototype.codePointAt?e.codePointAt(o):l(e,o);t[r++]=255&n}return t}t.MozChunkedArrayBufferXHR=u,t.stringToArrayBuffer=p},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o,n=r(0),i=function(e){return 9===e||10===e||13===e};function s(e){return i(e)||e>=32&&e<=126}function a(e){for(var t=0;t!==e.length;++t)if(!s(e[t]))throw new Error("Metadata is not valid (printable) ASCII");return String.fromCharCode.apply(String,Array.prototype.slice.call(e))}function g(e){return 128==(128&e.getUint8(0))}function u(e){return e.getUint32(1,!1)}function l(e,t,r){return e.byteLength-t>=r}function p(e,t,r){if(e.slice)return e.slice(t,r);var o=e.length;void 0!==r&&(o=r);for(var n=new Uint8Array(o-t),i=0,s=t;s<o;s++)n[i++]=e[s];return n}t.decodeASCII=a,t.encodeASCII=function(e){for(var t=new Uint8Array(e.length),r=0;r!==e.length;++r){var o=e.charCodeAt(r);if(!s(o))throw new Error("Metadata contains invalid ASCII");t[r]=o}return t},function(e){e[e.MESSAGE=1]="MESSAGE",e[e.TRAILERS=2]="TRAILERS"}(o=t.ChunkType||(t.ChunkType={}));var c=function(){function e(){this.buffer=null,this.position=0}return e.prototype.parse=function(e,t){if(0===e.length&&t)return[];var r,i=[];if(null==this.buffer)this.buffer=e,this.position=0;else if(this.position===this.buffer.byteLength)this.buffer=e,this.position=0;else{var s=this.buffer.byteLength-this.position,c=new Uint8Array(s+e.byteLength),f=p(this.buffer,this.position);c.set(f,0);var d=new Uint8Array(e);c.set(d,s),this.buffer=c,this.position=0}for(;;){if(!l(this.buffer,this.position,5))return i;var h=p(this.buffer,this.position,this.position+5),y=new DataView(h.buffer,h.byteOffset,h.byteLength),_=u(y);if(!l(this.buffer,this.position,5+_))return i;var b=p(this.buffer,this.position+5,this.position+5+_);if(this.position+=5+_,g(y))return i.push({chunkType:o.TRAILERS,trailers:(r=b,new n.Metadata(a(r)))}),i;i.push({chunkType:o.MESSAGE,data:b})}},e}();t.ChunkParser=c},function(e,t,r){"use strict";var o;Object.defineProperty(t,"__esModule",{value:!0}),function(e){e[e.OK=0]="OK",e[e.Canceled=1]="Canceled",e[e.Unknown=2]="Unknown",e[e.InvalidArgument=3]="InvalidArgument",e[e.DeadlineExceeded=4]="DeadlineExceeded",e[e.NotFound=5]="NotFound",e[e.AlreadyExists=6]="AlreadyExists",e[e.PermissionDenied=7]="PermissionDenied",e[e.ResourceExhausted=8]="ResourceExhausted",e[e.FailedPrecondition=9]="FailedPrecondition",e[e.Aborted=10]="Aborted",e[e.OutOfRange=11]="OutOfRange",e[e.Unimplemented=12]="Unimplemented",e[e.Internal=13]="Internal",e[e.Unavailable=14]="Unavailable",e[e.DataLoss=15]="DataLoss",e[e.Unauthenticated=16]="Unauthenticated"}(o=t.Code||(t.Code={})),t.httpStatusToCode=function(e){switch(e){case 0:return o.Internal;case 200:return o.OK;case 400:return o.InvalidArgument;case 401:return o.Unauthenticated;case 403:return o.PermissionDenied;case 404:return o.NotFound;case 409:return o.Aborted;case 412:return o.FailedPrecondition;case 429:return o.ResourceExhausted;case 499:return o.Canceled;case 500:return o.Unknown;case 501:return o.Unimplemented;case 503:return o.Unavailable;case 504:return o.DeadlineExceeded;default:return o.Unknown}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=r(3),n=r(4),i=r(6),s=r(12),a=r(7),g=r(5),u=r(9),l=r(13),p=r(15),c=r(2);!function(e){e.setDefaultTransport=n.setDefaultTransportFactory,e.CrossBrowserHttpTransport=g.CrossBrowserHttpTransport,e.FetchReadableStreamTransport=i.FetchReadableStreamTransport,e.XhrTransport=a.XhrTransport,e.WebsocketTransport=s.WebsocketTransport,e.Code=u.Code,e.Metadata=o.BrowserHeaders,e.client=function(e,t){return c.client(e,t)},e.invoke=l.invoke,e.unary=p.unary}(t.grpc||(t.grpc={}))},function(e,t,r){"use strict";var o;function n(e){var t=function(){if(void 0!==o)return o;if(XMLHttpRequest){o=new XMLHttpRequest;try{o.open("GET","https://localhost")}catch(e){}}return o}();if(!t)return!1;try{return t.responseType=e,t.responseType===e}catch(e){}return!1}Object.defineProperty(t,"__esModule",{value:!0}),t.xhrSupportsResponseType=n,t.detectMozXHRSupport=function(){return"undefined"!=typeof XMLHttpRequest&&n("moz-chunked-arraybuffer")},t.detectXHROverrideMimeTypeSupport=function(){return"undefined"!=typeof XMLHttpRequest&&XMLHttpRequest.prototype.hasOwnProperty("overrideMimeType")}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o,n=r(1),i=r(8);!function(e){e[e.FINISH_SEND=1]="FINISH_SEND"}(o||(o={}));var s=new Uint8Array([1]);t.WebsocketTransport=function(){return function(e){return function(e){e.debug&&n.debug("websocketRequest",e);var t,r=function(e){if("https://"===e.substr(0,8))return"wss://"+e.substr(8);if("http://"===e.substr(0,7))return"ws://"+e.substr(7);throw new Error("Websocket transport constructed with non-https:// or http:// host.")}(e.url),a=[];function g(e){if(e===o.FINISH_SEND)t.send(s);else{var r=e,n=new Int8Array(r.byteLength+1);n.set(new Uint8Array([0])),n.set(r,1),t.send(n)}}return{sendMessage:function(e){t&&t.readyState!==t.CONNECTING?g(e):a.push(e)},finishSend:function(){t&&t.readyState!==t.CONNECTING?g(o.FINISH_SEND):a.push(o.FINISH_SEND)},start:function(o){(t=new WebSocket(r,["grpc-websockets"])).binaryType="arraybuffer",t.onopen=function(){var r;e.debug&&n.debug("websocketRequest.onopen"),t.send((r="",o.forEach(function(e,t){r+=e+": "+t.join(", ")+"\r\n"}),i.encodeASCII(r))),a.forEach(function(e){g(e)})},t.onclose=function(t){e.debug&&n.debug("websocketRequest.onclose",t),e.onEnd()},t.onerror=function(t){e.debug&&n.debug("websocketRequest.onerror",t)},t.onmessage=function(t){e.onChunk(new Uint8Array(t.data))}},cancel:function(){e.debug&&n.debug("websocket.abort"),t.close()}}}(e)}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=r(2);t.invoke=function(e,t){if(e.requestStream)throw new Error(".invoke cannot be used with client-streaming methods. Use .client instead.");var r=o.client(e,{host:t.host,transport:t.transport,debug:t.debug});return t.onHeaders&&r.onHeaders(t.onHeaders),t.onMessage&&r.onMessage(t.onMessage),t.onEnd&&r.onEnd(t.onEnd),r.start(t.metadata),r.send(t.request),r.finishSend(),{close:function(){r.close()}}}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.frameRequest=function(e){var t=e.serializeBinary(),r=new ArrayBuffer(t.byteLength+5);return new DataView(r,1,4).setUint32(0,t.length,!1),new Uint8Array(r,5).set(t),new Uint8Array(r)}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var o=r(0),n=r(2);t.unary=function(e,t){if(e.responseStream)throw new Error(".unary cannot be used with server-streaming methods. Use .invoke or .client instead.");if(e.requestStream)throw new Error(".unary cannot be used with client-streaming methods. Use .client instead.");var r=null,i=null,s=n.client(e,{host:t.host,transport:t.transport,debug:t.debug});return s.onHeaders(function(e){r=e}),s.onMessage(function(e){i=e}),s.onEnd(function(e,n,s){t.onEnd({status:e,statusMessage:n,headers:r||new o.Metadata,message:i,trailers:s})}),s.start(t.metadata),s.send(t.request),s.finishSend(),{close:function(){s.close()}}}}])},function(e,t,r){"use strict";(function(e){
/*!
* The buffer module from node.js, for the browser.
*
* @author Feross Aboukhadijeh <http://feross.org>
* @license MIT
*/
var o=r(9),n=r(10),i=r(11);function s(){return g.TYPED_ARRAY_SUPPORT?2147483647:1073741823}function a(e,t){if(s()<t)throw new RangeError("Invalid typed array length");return g.TYPED_ARRAY_SUPPORT?(e=new Uint8Array(t)).__proto__=g.prototype:(null===e&&(e=new g(t)),e.length=t),e}function g(e,t,r){if(!(g.TYPED_ARRAY_SUPPORT||this instanceof g))return new g(e,t,r);if("number"==typeof e){if("string"==typeof t)throw new Error("If encoding is specified then the first argument must be a string");return p(this,e)}return u(this,e,t,r)}function u(e,t,r,o){if("number"==typeof t)throw new TypeError('"value" argument must not be a number');return"undefined"!=typeof ArrayBuffer&&t instanceof ArrayBuffer?function(e,t,r,o){if(t.byteLength,r<0||t.byteLength<r)throw new RangeError("'offset' is out of bounds");if(t.byteLength<r+(o||0))throw new RangeError("'length' is out of bounds");t=void 0===r&&void 0===o?new Uint8Array(t):void 0===o?new Uint8Array(t,r):new Uint8Array(t,r,o);g.TYPED_ARRAY_SUPPORT?(e=t).__proto__=g.prototype:e=c(e,t);return e}(e,t,r,o):"string"==typeof t?function(e,t,r){"string"==typeof r&&""!==r||(r="utf8");if(!g.isEncoding(r))throw new TypeError('"encoding" must be a valid string encoding');var o=0|d(t,r),n=(e=a(e,o)).write(t,r);n!==o&&(e=e.slice(0,n));return e}(e,t,r):function(e,t){if(g.isBuffer(t)){var r=0|f(t.length);return 0===(e=a(e,r)).length?e:(t.copy(e,0,0,r),e)}if(t){if("undefined"!=typeof ArrayBuffer&&t.buffer instanceof ArrayBuffer||"length"in t)return"number"!=typeof t.length||function(e){return e!=e}(t.length)?a(e,0):c(e,t);if("Buffer"===t.type&&i(t.data))return c(e,t.data)}throw new TypeError("First argument must be a string, Buffer, ArrayBuffer, Array, or array-like object.")}(e,t)}function l(e){if("number"!=typeof e)throw new TypeError('"size" argument must be a number');if(e<0)throw new RangeError('"size" argument must not be negative')}function p(e,t){if(l(t),e=a(e,t<0?0:0|f(t)),!g.TYPED_ARRAY_SUPPORT)for(var r=0;r<t;++r)e[r]=0;return e}function c(e,t){var r=t.length<0?0:0|f(t.length);e=a(e,r);for(var o=0;o<r;o+=1)e[o]=255&t[o];return e}function f(e){if(e>=s())throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+s().toString(16)+" bytes");return 0|e}function d(e,t){if(g.isBuffer(e))return e.length;if("undefined"!=typeof ArrayBuffer&&"function"==typeof ArrayBuffer.isView&&(ArrayBuffer.isView(e)||e instanceof ArrayBuffer))return e.byteLength;"string"!=typeof e&&(e=""+e);var r=e.length;if(0===r)return 0;for(var o=!1;;)switch(t){case"ascii":case"latin1":case"binary":return r;case"utf8":case"utf-8":case void 0:return x(e).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*r;case"hex":return r>>>1;case"base64":return W(e).length;default:if(o)return x(e).length;t=(""+t).toLowerCase(),o=!0}}function h(e,t,r){var o=e[t];e[t]=e[r],e[r]=o}function y(e,t,r,o,n){if(0===e.length)return-1;if("string"==typeof r?(o=r,r=0):r>2147483647?r=2147483647:r<-2147483648&&(r=-2147483648),r=+r,isNaN(r)&&(r=n?0:e.length-1),r<0&&(r=e.length+r),r>=e.length){if(n)return-1;r=e.length-1}else if(r<0){if(!n)return-1;r=0}if("string"==typeof t&&(t=g.from(t,o)),g.isBuffer(t))return 0===t.length?-1:_(e,t,r,o,n);if("number"==typeof t)return t&=255,g.TYPED_ARRAY_SUPPORT&&"function"==typeof Uint8Array.prototype.indexOf?n?Uint8Array.prototype.indexOf.call(e,t,r):Uint8Array.prototype.lastIndexOf.call(e,t,r):_(e,[t],r,o,n);throw new TypeError("val must be string, number or Buffer")}function _(e,t,r,o,n){var i,s=1,a=e.length,g=t.length;if(void 0!==o&&("ucs2"===(o=String(o).toLowerCase())||"ucs-2"===o||"utf16le"===o||"utf-16le"===o)){if(e.length<2||t.length<2)return-1;s=2,a/=2,g/=2,r/=2}function u(e,t){return 1===s?e[t]:e.readUInt16BE(t*s)}if(n){var l=-1;for(i=r;i<a;i++)if(u(e,i)===u(t,-1===l?0:i-l)){if(-1===l&&(l=i),i-l+1===g)return l*s}else-1!==l&&(i-=i-l),l=-1}else for(r+g>a&&(r=a-g),i=r;i>=0;i--){for(var p=!0,c=0;c<g;c++)if(u(e,i+c)!==u(t,c)){p=!1;break}if(p)return i}return-1}function b(e,t,r,o){r=Number(r)||0;var n=e.length-r;o?(o=Number(o))>n&&(o=n):o=n;var i=t.length;if(i%2!=0)throw new TypeError("Invalid hex stri