@streamr/dht 101.1.2 → 102.0.0-beta.1
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/package.json +17 -18
- package/dist/src/connection/Connection.d.ts +1 -1
- package/dist/src/connection/ConnectionLockRpcLocal.d.ts +5 -3
- package/dist/src/connection/ConnectionLockRpcLocal.js +9 -3
- package/dist/src/connection/ConnectionLockRpcLocal.js.map +1 -1
- package/dist/src/connection/ConnectionLockRpcRemote.d.ts +3 -2
- package/dist/src/connection/ConnectionLockRpcRemote.js +14 -3
- package/dist/src/connection/ConnectionLockRpcRemote.js.map +1 -1
- package/dist/src/connection/ConnectionLockStates.d.ts +5 -0
- package/dist/src/connection/ConnectionLockStates.js +14 -0
- package/dist/src/connection/ConnectionLockStates.js.map +1 -1
- package/dist/src/connection/ConnectionManager.d.ts +8 -1
- package/dist/src/connection/ConnectionManager.js +96 -32
- package/dist/src/connection/ConnectionManager.js.map +1 -1
- package/dist/src/connection/ConnectionsView.d.ts +1 -1
- package/dist/src/connection/ConnectorFacade.d.ts +1 -1
- package/dist/src/connection/Handshaker.d.ts +2 -2
- package/dist/src/connection/Handshaker.js +11 -7
- package/dist/src/connection/Handshaker.js.map +1 -1
- package/dist/src/connection/ManagedConnection.d.ts +7 -1
- package/dist/src/connection/ManagedConnection.js +41 -8
- package/dist/src/connection/ManagedConnection.js.map +1 -1
- package/dist/src/connection/PendingConnection.d.ts +1 -1
- package/dist/src/connection/connectivityChecker.d.ts +1 -1
- package/dist/src/connection/connectivityChecker.js +22 -11
- package/dist/src/connection/connectivityChecker.js.map +1 -1
- package/dist/src/connection/connectivityRequestHandler.js +4 -4
- package/dist/src/connection/connectivityRequestHandler.js.map +1 -1
- package/dist/src/connection/simulator/Simulator.d.ts +1 -1
- package/dist/src/connection/simulator/Simulator.js +5 -4
- package/dist/src/connection/simulator/Simulator.js.map +1 -1
- package/dist/src/connection/simulator/SimulatorConnection.d.ts +1 -1
- package/dist/src/connection/simulator/SimulatorConnection.js +9 -9
- package/dist/src/connection/simulator/SimulatorConnection.js.map +1 -1
- package/dist/src/connection/simulator/SimulatorConnector.d.ts +1 -1
- package/dist/src/connection/simulator/SimulatorConnector.js +4 -4
- package/dist/src/connection/simulator/SimulatorConnector.js.map +1 -1
- package/dist/src/connection/simulator/SimulatorTransport.d.ts +1 -1
- package/dist/src/connection/simulator/SimulatorTransport.js +2 -1
- package/dist/src/connection/simulator/SimulatorTransport.js.map +1 -1
- package/dist/src/connection/simulator/pings.d.ts +1 -1
- package/dist/src/connection/simulator/pings.js +3 -3
- package/dist/src/connection/simulator/pings.js.map +1 -1
- package/dist/src/connection/webrtc/NodeWebrtcConnection.d.ts +2 -1
- package/dist/src/connection/webrtc/NodeWebrtcConnection.js +13 -8
- package/dist/src/connection/webrtc/NodeWebrtcConnection.js.map +1 -1
- package/dist/src/connection/webrtc/WebrtcConnector.d.ts +2 -1
- package/dist/src/connection/webrtc/WebrtcConnector.js +28 -17
- package/dist/src/connection/webrtc/WebrtcConnector.js.map +1 -1
- package/dist/src/connection/webrtc/WebrtcConnectorRpcLocal.d.ts +3 -3
- package/dist/src/connection/webrtc/WebrtcConnectorRpcLocal.js +4 -4
- package/dist/src/connection/webrtc/WebrtcConnectorRpcLocal.js.map +1 -1
- package/dist/src/connection/webrtc/WebrtcConnectorRpcRemote.d.ts +1 -1
- package/dist/src/connection/webrtc/iceServerAsString.js +1 -2
- package/dist/src/connection/webrtc/iceServerAsString.js.map +1 -1
- package/dist/src/connection/websocket/AbstractWebsocketClientConnection.d.ts +0 -1
- package/dist/src/connection/websocket/WebsocketClientConnector.d.ts +1 -1
- package/dist/src/connection/websocket/WebsocketClientConnector.js +3 -3
- package/dist/src/connection/websocket/WebsocketClientConnector.js.map +1 -1
- package/dist/src/connection/websocket/WebsocketClientConnectorRpcLocal.d.ts +3 -4
- package/dist/src/connection/websocket/WebsocketClientConnectorRpcLocal.js +1 -1
- package/dist/src/connection/websocket/WebsocketClientConnectorRpcLocal.js.map +1 -1
- package/dist/src/connection/websocket/WebsocketClientConnectorRpcRemote.d.ts +1 -1
- package/dist/src/connection/websocket/WebsocketClientConnectorRpcRemote.js +1 -1
- package/dist/src/connection/websocket/WebsocketClientConnectorRpcRemote.js.map +1 -1
- package/dist/src/connection/websocket/WebsocketServerConnection.d.ts +0 -1
- package/dist/src/connection/websocket/WebsocketServerConnector.d.ts +1 -1
- package/dist/src/connection/websocket/WebsocketServerConnector.js +34 -24
- package/dist/src/connection/websocket/WebsocketServerConnector.js.map +1 -1
- package/dist/src/dht/DhtNode.d.ts +5 -2
- package/dist/src/dht/DhtNode.js +20 -8
- package/dist/src/dht/DhtNode.js.map +1 -1
- package/dist/src/dht/DhtNodeRpcLocal.d.ts +4 -4
- package/dist/src/dht/DhtNodeRpcLocal.js +3 -3
- package/dist/src/dht/DhtNodeRpcLocal.js.map +1 -1
- package/dist/src/dht/DhtNodeRpcRemote.d.ts +2 -2
- package/dist/src/dht/DhtNodeRpcRemote.js +3 -3
- package/dist/src/dht/DhtNodeRpcRemote.js.map +1 -1
- package/dist/src/dht/ExternalApiRpcLocal.d.ts +3 -3
- package/dist/src/dht/ExternalApiRpcLocal.js +3 -3
- package/dist/src/dht/ExternalApiRpcLocal.js.map +1 -1
- package/dist/src/dht/ExternalApiRpcRemote.d.ts +3 -3
- package/dist/src/dht/ExternalApiRpcRemote.js +2 -2
- package/dist/src/dht/ExternalApiRpcRemote.js.map +1 -1
- package/dist/src/dht/PeerManager.d.ts +3 -2
- package/dist/src/dht/PeerManager.js +12 -11
- package/dist/src/dht/PeerManager.js.map +1 -1
- package/dist/src/dht/contact/Contact.d.ts +1 -1
- package/dist/src/dht/contact/Contact.js +1 -1
- package/dist/src/dht/contact/Contact.js.map +1 -1
- package/dist/src/dht/contact/RingContactList.d.ts +1 -1
- package/dist/src/dht/contact/RingContactList.js +1 -1
- package/dist/src/dht/contact/RingContactList.js.map +1 -1
- package/dist/src/dht/contact/RpcRemote.d.ts +1 -1
- package/dist/src/dht/contact/SortedContactList.js +2 -2
- package/dist/src/dht/contact/SortedContactList.js.map +1 -1
- package/dist/src/dht/contact/ringIdentifiers.d.ts +1 -1
- package/dist/src/dht/discovery/DiscoverySession.d.ts +1 -2
- package/dist/src/dht/discovery/DiscoverySession.js +3 -3
- package/dist/src/dht/discovery/DiscoverySession.js.map +1 -1
- package/dist/src/dht/discovery/PeerDiscovery.d.ts +1 -2
- package/dist/src/dht/discovery/PeerDiscovery.js +7 -7
- package/dist/src/dht/discovery/PeerDiscovery.js.map +1 -1
- package/dist/src/dht/discovery/RingDiscoverySession.d.ts +0 -1
- package/dist/src/dht/discovery/RingDiscoverySession.js +1 -1
- package/dist/src/dht/discovery/RingDiscoverySession.js.map +1 -1
- package/dist/src/dht/recursive-operation/RecursiveOperationManager.d.ts +3 -3
- package/dist/src/dht/recursive-operation/RecursiveOperationManager.js +8 -8
- package/dist/src/dht/recursive-operation/RecursiveOperationManager.js.map +1 -1
- package/dist/src/dht/recursive-operation/RecursiveOperationRpcLocal.d.ts +2 -2
- package/dist/src/dht/recursive-operation/RecursiveOperationRpcLocal.js +2 -2
- package/dist/src/dht/recursive-operation/RecursiveOperationRpcLocal.js.map +1 -1
- package/dist/src/dht/recursive-operation/RecursiveOperationRpcRemote.d.ts +2 -2
- package/dist/src/dht/recursive-operation/RecursiveOperationRpcRemote.js +3 -3
- package/dist/src/dht/recursive-operation/RecursiveOperationRpcRemote.js.map +1 -1
- package/dist/src/dht/recursive-operation/RecursiveOperationSession.d.ts +1 -1
- package/dist/src/dht/recursive-operation/RecursiveOperationSession.js +7 -7
- package/dist/src/dht/recursive-operation/RecursiveOperationSession.js.map +1 -1
- package/dist/src/dht/recursive-operation/RecursiveOperationSessionRpcLocal.d.ts +3 -3
- package/dist/src/dht/recursive-operation/RecursiveOperationSessionRpcLocal.js +1 -1
- package/dist/src/dht/recursive-operation/RecursiveOperationSessionRpcLocal.js.map +1 -1
- package/dist/src/dht/recursive-operation/RecursiveOperationSessionRpcRemote.d.ts +2 -2
- package/dist/src/dht/routing/DuplicateDetector.js.map +1 -1
- package/dist/src/dht/routing/Router.d.ts +4 -1
- package/dist/src/dht/routing/Router.js +17 -9
- package/dist/src/dht/routing/Router.js.map +1 -1
- package/dist/src/dht/routing/RouterRpcLocal.d.ts +2 -2
- package/dist/src/dht/routing/RouterRpcLocal.js +5 -5
- package/dist/src/dht/routing/RouterRpcLocal.js.map +1 -1
- package/dist/src/dht/routing/RouterRpcRemote.d.ts +2 -2
- package/dist/src/dht/routing/RouterRpcRemote.js +7 -7
- package/dist/src/dht/routing/RouterRpcRemote.js.map +1 -1
- package/dist/src/dht/routing/RoutingSession.d.ts +1 -1
- package/dist/src/dht/routing/RoutingSession.js +7 -8
- package/dist/src/dht/routing/RoutingSession.js.map +1 -1
- package/dist/src/dht/routing/RoutingTablesCache.d.ts +1 -1
- package/dist/src/dht/routing/getPreviousPeer.d.ts +1 -1
- package/dist/src/dht/store/LocalDataStore.d.ts +1 -1
- package/dist/src/dht/store/LocalDataStore.js +3 -3
- package/dist/src/dht/store/LocalDataStore.js.map +1 -1
- package/dist/src/dht/store/StoreManager.d.ts +3 -3
- package/dist/src/dht/store/StoreManager.js +8 -8
- package/dist/src/dht/store/StoreManager.js.map +1 -1
- package/dist/src/dht/store/StoreRpcLocal.d.ts +4 -4
- package/dist/src/dht/store/StoreRpcLocal.js +4 -4
- package/dist/src/dht/store/StoreRpcLocal.js.map +1 -1
- package/dist/src/dht/store/StoreRpcRemote.d.ts +3 -3
- package/dist/src/dht/store/StoreRpcRemote.js +7 -4
- package/dist/src/dht/store/StoreRpcRemote.js.map +1 -1
- package/dist/src/exports.d.ts +2 -2
- package/dist/src/exports.js +6 -6
- package/dist/src/exports.js.map +1 -1
- package/dist/src/helpers/AddressTools.js +2 -3
- package/dist/src/helpers/AddressTools.js.map +1 -1
- package/dist/src/helpers/Connectivity.d.ts +1 -1
- package/dist/src/helpers/Connectivity.js +1 -1
- package/dist/src/helpers/Connectivity.js.map +1 -1
- package/dist/src/helpers/createPeerDescriptor.d.ts +1 -1
- package/dist/src/helpers/createPeerDescriptor.js +2 -2
- package/dist/src/helpers/createPeerDescriptor.js.map +1 -1
- package/dist/src/helpers/createPeerDescriptorSignaturePayload.d.ts +1 -1
- package/dist/src/helpers/createPeerDescriptorSignaturePayload.js +1 -1
- package/dist/src/helpers/createPeerDescriptorSignaturePayload.js.map +1 -1
- package/dist/src/helpers/debugHelpers.js +2 -2
- package/dist/src/helpers/debugHelpers.js.map +1 -1
- package/dist/src/helpers/protoClasses.d.ts +1 -1
- package/dist/src/helpers/protoClasses.js +1 -1
- package/dist/src/helpers/protoClasses.js.map +1 -1
- package/dist/src/helpers/protoToString.js +1 -2
- package/dist/src/helpers/protoToString.js.map +1 -1
- package/dist/src/helpers/version.d.ts +1 -1
- package/dist/src/helpers/version.js +4 -4
- package/dist/src/helpers/version.js.map +1 -1
- package/dist/src/identifiers.d.ts +5 -5
- package/dist/src/identifiers.js +11 -11
- package/dist/src/identifiers.js.map +1 -1
- package/dist/src/rpc-protocol/DhtCallContext.d.ts +1 -1
- package/dist/src/rpc-protocol/DhtRpcOptions.d.ts +1 -1
- package/dist/src/transport/ITransport.d.ts +2 -1
- package/dist/src/transport/ListeningRpcCommunicator.d.ts +2 -1
- package/dist/src/transport/ListeningRpcCommunicator.js +13 -4
- package/dist/src/transport/ListeningRpcCommunicator.js.map +1 -1
- package/dist/src/transport/RoutingRpcCommunicator.d.ts +1 -1
- package/eslint.config.mjs +12 -0
- package/jest.config.ts +12 -0
- package/package.json +17 -18
- package/proto.sh +2 -3
- package/protos/DhtRpc.proto +11 -4
- package/src/connection/Connection.ts +1 -1
- package/src/connection/ConnectionLockRpcLocal.ts +16 -7
- package/src/connection/ConnectionLockRpcRemote.ts +18 -6
- package/src/connection/ConnectionLockStates.ts +18 -0
- package/src/connection/ConnectionManager.ts +93 -27
- package/src/connection/ConnectionsView.ts +1 -1
- package/src/connection/ConnectorFacade.ts +1 -1
- package/src/connection/Handshaker.ts +18 -14
- package/src/connection/ManagedConnection.ts +28 -3
- package/src/connection/PendingConnection.ts +1 -1
- package/src/connection/connectivityChecker.ts +6 -5
- package/src/connection/connectivityRequestHandler.ts +4 -4
- package/src/connection/simulator/Simulator.ts +8 -7
- package/src/connection/simulator/SimulatorConnection.ts +10 -10
- package/src/connection/simulator/SimulatorConnector.ts +5 -5
- package/src/connection/simulator/SimulatorTransport.ts +3 -2
- package/src/connection/simulator/pings.ts +1 -1
- package/src/connection/webrtc/BrowserWebrtcConnection.ts +10 -1
- package/src/connection/webrtc/NodeWebrtcConnection.ts +15 -11
- package/src/connection/webrtc/WebrtcConnector.ts +13 -11
- package/src/connection/webrtc/WebrtcConnectorRpcLocal.ts +8 -8
- package/src/connection/webrtc/WebrtcConnectorRpcRemote.ts +2 -2
- package/src/connection/websocket/WebsocketClientConnector.ts +5 -5
- package/src/connection/websocket/WebsocketClientConnectorRpcLocal.ts +5 -5
- package/src/connection/websocket/WebsocketClientConnectorRpcRemote.ts +4 -4
- package/src/connection/websocket/WebsocketServerConnector.ts +24 -20
- package/src/dht/DhtNode.ts +29 -11
- package/src/dht/DhtNodeRpcLocal.ts +8 -8
- package/src/dht/DhtNodeRpcRemote.ts +5 -5
- package/src/dht/ExternalApiRpcLocal.ts +8 -8
- package/src/dht/ExternalApiRpcRemote.ts +6 -6
- package/src/dht/PeerManager.ts +16 -14
- package/src/dht/contact/Contact.ts +3 -3
- package/src/dht/contact/RingContactList.ts +3 -3
- package/src/dht/contact/RpcRemote.ts +1 -1
- package/src/dht/contact/SortedContactList.ts +3 -3
- package/src/dht/contact/ringIdentifiers.ts +1 -1
- package/src/dht/discovery/DiscoverySession.ts +5 -5
- package/src/dht/discovery/PeerDiscovery.ts +12 -12
- package/src/dht/discovery/RingDiscoverySession.ts +3 -3
- package/src/dht/recursive-operation/RecursiveOperationManager.ts +10 -10
- package/src/dht/recursive-operation/RecursiveOperationRpcLocal.ts +4 -4
- package/src/dht/recursive-operation/RecursiveOperationRpcRemote.ts +6 -6
- package/src/dht/recursive-operation/RecursiveOperationSession.ts +8 -8
- package/src/dht/recursive-operation/RecursiveOperationSessionRpcLocal.ts +5 -5
- package/src/dht/recursive-operation/RecursiveOperationSessionRpcRemote.ts +2 -2
- package/src/dht/routing/DuplicateDetector.ts +1 -1
- package/src/dht/routing/Router.ts +19 -10
- package/src/dht/routing/RouterRpcLocal.ts +7 -7
- package/src/dht/routing/RouterRpcRemote.ts +9 -9
- package/src/dht/routing/RoutingSession.ts +9 -10
- package/src/dht/routing/RoutingTablesCache.ts +1 -1
- package/src/dht/routing/getPreviousPeer.ts +1 -1
- package/src/dht/store/LocalDataStore.ts +5 -5
- package/src/dht/store/StoreManager.ts +13 -13
- package/src/dht/store/StoreRpcLocal.ts +9 -9
- package/src/dht/store/StoreRpcRemote.ts +10 -7
- package/src/exports.ts +5 -5
- package/src/helpers/Connectivity.ts +1 -1
- package/src/helpers/createPeerDescriptor.ts +3 -3
- package/src/helpers/createPeerDescriptorSignaturePayload.ts +1 -1
- package/src/helpers/protoClasses.ts +2 -2
- package/src/helpers/version.ts +2 -2
- package/src/identifiers.ts +7 -7
- package/src/rpc-protocol/DhtCallContext.ts +1 -1
- package/src/rpc-protocol/DhtRpcOptions.ts +1 -1
- package/src/transport/ITransport.ts +2 -1
- package/src/transport/ListeningRpcCommunicator.ts +14 -6
- package/src/transport/RoutingRpcCommunicator.ts +2 -2
- package/test/benchmark/Find.test.ts +9 -9
- package/test/benchmark/KademliaCorrectness.test.ts +7 -7
- package/test/benchmark/RingCorrectness.test.ts +8 -8
- package/test/benchmark/SortedContactListBenchmark.test.ts +10 -10
- package/test/benchmark/hybrid-network-simulation/RingContactList.test.ts +3 -3
- package/test/end-to-end/Layer0Webrtc-Layer1.test.ts +6 -6
- package/test/end-to-end/Layer0Webrtc.test.ts +6 -6
- package/test/end-to-end/RecoveryFromFailedAutoCertification.test.ts +1 -1
- package/test/end-to-end/WebsocketConnectionRequest.test.ts +3 -3
- package/test/end-to-end/memory-leak.test.ts +6 -6
- package/test/integration/ConnectionLocking.test.ts +48 -37
- package/test/integration/ConnectionManager.test.ts +62 -6
- package/test/integration/ConnectivityChecking.test.ts +3 -2
- package/test/integration/DhtJoinPeerDiscovery.test.ts +2 -2
- package/test/integration/DhtNode.test.ts +6 -6
- package/test/integration/DhtNodeExternalAPI.test.ts +7 -7
- package/test/integration/DhtNodeRpcRemote.test.ts +9 -9
- package/test/integration/DhtRpc.test.ts +12 -13
- package/test/integration/Find.test.ts +5 -5
- package/test/integration/GeoIpConnectivityChecking.test.ts +8 -7
- package/test/integration/Layer1-scale.test.ts +3 -3
- package/test/integration/Mock-Layer1-Layer0.test.ts +6 -6
- package/test/integration/MultipleEntryPointJoining.test.ts +1 -1
- package/test/integration/ReplicateData.test.ts +10 -11
- package/test/integration/RouteMessage.test.ts +13 -13
- package/test/integration/RouterRpcRemote.test.ts +7 -7
- package/test/integration/SimultaneousConnections.test.ts +14 -13
- package/test/integration/Store.test.ts +9 -9
- package/test/integration/StoreAndDelete.test.ts +10 -10
- package/test/integration/StoreOnDhtWithThreeNodes.test.ts +10 -10
- package/test/integration/StoreOnDhtWithTwoNodes.test.ts +10 -10
- package/test/integration/StoreRpcRemote.test.ts +11 -11
- package/test/integration/WebrtcConnectionManagement.test.ts +4 -31
- package/test/integration/WebrtcConnectorRpc.test.ts +14 -14
- package/test/integration/Websocket.test.ts +0 -2
- package/test/integration/WebsocketClientConnectorRpc.test.ts +8 -8
- package/test/integration/WebsocketConnectionManagement.test.ts +11 -12
- package/test/integration/{rpc-connections-over-webrpc.test.ts → rpc-connections-over-webrtc.test.ts} +12 -46
- package/test/unit/AutoCertifierClientFacade.test.ts +6 -6
- package/test/unit/ConnectionManager.test.ts +4 -3
- package/test/unit/ConnectivityHelpers.test.ts +1 -1
- package/test/unit/DiscoverySession.test.ts +6 -6
- package/test/unit/Handshaker.test.ts +2 -2
- package/test/unit/ListeningRpcCommunicator.test.ts +52 -0
- package/test/unit/LocalDataStore.test.ts +21 -21
- package/test/unit/PeerManager.test.ts +15 -15
- package/test/unit/PendingConnection.test.ts +1 -1
- package/test/unit/ProtobufMessage.test.ts +1 -1
- package/test/unit/RandomContactList.test.ts +2 -2
- package/test/unit/RecursiveOperationManager.test.ts +3 -3
- package/test/unit/RecursiveOperationSession.test.ts +6 -6
- package/test/unit/Router.test.ts +6 -6
- package/test/unit/RoutingSession.test.ts +13 -6
- package/test/unit/SortedContactList.test.ts +8 -8
- package/test/unit/StoreManager.test.ts +12 -12
- package/test/unit/StoreRpcLocal.test.ts +9 -9
- package/test/unit/WebrtcConnection.test.ts +29 -0
- package/test/unit/WebsocketClientConnector.test.ts +1 -1
- package/test/unit/WebsocketServerConnector.test.ts +1 -1
- package/test/unit/connectivityRequestHandler.test.ts +6 -6
- package/test/unit/createPeerDescriptor.test.ts +4 -4
- package/test/unit/customMatchers.test.ts +18 -0
- package/test/unit/getClosestNodes.test.ts +5 -5
- package/test/unit/version.test.ts +9 -9
- package/test/utils/FakeConnectorFacade.ts +1 -1
- package/test/utils/FakeTransport.ts +12 -9
- package/test/utils/customMatchers.ts +9 -9
- package/test/utils/mock/MockConnectionsView.ts +1 -1
- package/test/utils/mock/MockRouter.ts +5 -1
- package/test/utils/mock/MockTransport.ts +6 -1
- package/test/utils/mock/mockDataEntry.ts +6 -6
- package/test/utils/topology.ts +3 -4
- package/test/utils/utils.ts +11 -11
- package/tsconfig.jest.json +2 -1
- package/tsconfig.node.json +1 -0
- package/.eslintignore +0 -5
- package/.eslintrc +0 -3
- package/dist/src/proto/google/protobuf/any.d.ts +0 -173
- package/dist/src/proto/google/protobuf/any.js +0 -155
- package/dist/src/proto/google/protobuf/any.js.map +0 -1
- package/dist/src/proto/google/protobuf/empty.d.ts +0 -32
- package/dist/src/proto/google/protobuf/empty.js +0 -32
- package/dist/src/proto/google/protobuf/empty.js.map +0 -1
- package/dist/src/proto/google/protobuf/timestamp.d.ts +0 -149
- package/dist/src/proto/google/protobuf/timestamp.js +0 -136
- package/dist/src/proto/google/protobuf/timestamp.js.map +0 -1
- package/dist/src/proto/packages/dht/protos/DhtRpc.client.d.ts +0 -352
- package/dist/src/proto/packages/dht/protos/DhtRpc.client.js +0 -278
- package/dist/src/proto/packages/dht/protos/DhtRpc.client.js.map +0 -1
- package/dist/src/proto/packages/dht/protos/DhtRpc.d.ts +0 -975
- package/dist/src/proto/packages/dht/protos/DhtRpc.js +0 -661
- package/dist/src/proto/packages/dht/protos/DhtRpc.js.map +0 -1
- package/dist/src/proto/packages/dht/protos/DhtRpc.server.d.ts +0 -157
- package/dist/src/proto/packages/dht/protos/DhtRpc.server.js +0 -3
- package/dist/src/proto/packages/dht/protos/DhtRpc.server.js.map +0 -1
- package/dist/src/proto/packages/proto-rpc/protos/ProtoRpc.d.ts +0 -87
- package/dist/src/proto/packages/proto-rpc/protos/ProtoRpc.js +0 -66
- package/dist/src/proto/packages/proto-rpc/protos/ProtoRpc.js.map +0 -1
- package/dist/src/proto/tests.d.ts +0 -39
- package/dist/src/proto/tests.js +0 -34
- package/dist/src/proto/tests.js.map +0 -1
- package/jest.config.js +0 -5
- package/src/proto/google/protobuf/any.ts +0 -319
- package/src/proto/google/protobuf/empty.ts +0 -82
- package/src/proto/google/protobuf/timestamp.ts +0 -281
- package/src/proto/packages/dht/protos/DhtRpc.client.ts +0 -407
- package/src/proto/packages/dht/protos/DhtRpc.server.ts +0 -160
- package/src/proto/packages/dht/protos/DhtRpc.ts +0 -1244
- package/src/proto/packages/proto-rpc/protos/ProtoRpc.ts +0 -108
- package/src/proto/tests.ts +0 -52
- package/test/benchmark/any.test.ts +0 -28
- /package/{src/types/glogal.d.ts → test/types/global.d.ts} +0 -0
|
@@ -1,155 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.Any = void 0;
|
|
4
|
-
const runtime_1 = require("@protobuf-ts/runtime");
|
|
5
|
-
const runtime_2 = require("@protobuf-ts/runtime");
|
|
6
|
-
const runtime_3 = require("@protobuf-ts/runtime");
|
|
7
|
-
const runtime_4 = require("@protobuf-ts/runtime");
|
|
8
|
-
const runtime_5 = require("@protobuf-ts/runtime");
|
|
9
|
-
const runtime_6 = require("@protobuf-ts/runtime");
|
|
10
|
-
const runtime_7 = require("@protobuf-ts/runtime");
|
|
11
|
-
// @generated message type with reflection information, may provide speed optimized methods
|
|
12
|
-
class Any$Type extends runtime_7.MessageType {
|
|
13
|
-
constructor() {
|
|
14
|
-
super("google.protobuf.Any", [
|
|
15
|
-
{ no: 1, name: "type_url", kind: "scalar", T: 9 /*ScalarType.STRING*/ },
|
|
16
|
-
{ no: 2, name: "value", kind: "scalar", T: 12 /*ScalarType.BYTES*/ }
|
|
17
|
-
]);
|
|
18
|
-
}
|
|
19
|
-
/**
|
|
20
|
-
* Pack the message into a new `Any`.
|
|
21
|
-
*
|
|
22
|
-
* Uses 'type.googleapis.com/full.type.name' as the type URL.
|
|
23
|
-
*/
|
|
24
|
-
pack(message, type) {
|
|
25
|
-
return {
|
|
26
|
-
typeUrl: this.typeNameToUrl(type.typeName), value: type.toBinary(message),
|
|
27
|
-
};
|
|
28
|
-
}
|
|
29
|
-
/**
|
|
30
|
-
* Unpack the message from the `Any`.
|
|
31
|
-
*/
|
|
32
|
-
unpack(any, type, options) {
|
|
33
|
-
if (!this.contains(any, type))
|
|
34
|
-
throw new Error("Cannot unpack google.protobuf.Any with typeUrl '" + any.typeUrl + "' as " + type.typeName + ".");
|
|
35
|
-
return type.fromBinary(any.value, options);
|
|
36
|
-
}
|
|
37
|
-
/**
|
|
38
|
-
* Does the given `Any` contain a packed message of the given type?
|
|
39
|
-
*/
|
|
40
|
-
contains(any, type) {
|
|
41
|
-
if (!any.typeUrl.length)
|
|
42
|
-
return false;
|
|
43
|
-
let wants = typeof type == "string" ? type : type.typeName;
|
|
44
|
-
let has = this.typeUrlToName(any.typeUrl);
|
|
45
|
-
return wants === has;
|
|
46
|
-
}
|
|
47
|
-
/**
|
|
48
|
-
* Convert the message to canonical JSON value.
|
|
49
|
-
*
|
|
50
|
-
* You have to provide the `typeRegistry` option so that the
|
|
51
|
-
* packed message can be converted to JSON.
|
|
52
|
-
*
|
|
53
|
-
* The `typeRegistry` option is also required to read
|
|
54
|
-
* `google.protobuf.Any` from JSON format.
|
|
55
|
-
*/
|
|
56
|
-
internalJsonWrite(any, options) {
|
|
57
|
-
if (any.typeUrl === "")
|
|
58
|
-
return {};
|
|
59
|
-
let typeName = this.typeUrlToName(any.typeUrl);
|
|
60
|
-
let opt = (0, runtime_6.jsonWriteOptions)(options);
|
|
61
|
-
let type = opt.typeRegistry?.find(t => t.typeName === typeName);
|
|
62
|
-
if (!type)
|
|
63
|
-
throw new globalThis.Error("Unable to convert google.protobuf.Any with typeUrl '" + any.typeUrl + "' to JSON. The specified type " + typeName + " is not available in the type registry.");
|
|
64
|
-
let value = type.fromBinary(any.value, { readUnknownField: false });
|
|
65
|
-
let json = type.internalJsonWrite(value, opt);
|
|
66
|
-
if (typeName.startsWith("google.protobuf.") || !(0, runtime_4.isJsonObject)(json))
|
|
67
|
-
json = { value: json };
|
|
68
|
-
json["@type"] = any.typeUrl;
|
|
69
|
-
return json;
|
|
70
|
-
}
|
|
71
|
-
internalJsonRead(json, options, target) {
|
|
72
|
-
if (!(0, runtime_4.isJsonObject)(json))
|
|
73
|
-
throw new globalThis.Error("Unable to parse google.protobuf.Any from JSON " + (0, runtime_5.typeofJsonValue)(json) + ".");
|
|
74
|
-
if (typeof json["@type"] != "string" || json["@type"] == "")
|
|
75
|
-
return this.create();
|
|
76
|
-
let typeName = this.typeUrlToName(json["@type"]);
|
|
77
|
-
let type = options?.typeRegistry?.find(t => t.typeName == typeName);
|
|
78
|
-
if (!type)
|
|
79
|
-
throw new globalThis.Error("Unable to parse google.protobuf.Any from JSON. The specified type " + typeName + " is not available in the type registry.");
|
|
80
|
-
let value;
|
|
81
|
-
if (typeName.startsWith("google.protobuf.") && json.hasOwnProperty("value"))
|
|
82
|
-
value = type.fromJson(json["value"], options);
|
|
83
|
-
else {
|
|
84
|
-
let copy = Object.assign({}, json);
|
|
85
|
-
delete copy["@type"];
|
|
86
|
-
value = type.fromJson(copy, options);
|
|
87
|
-
}
|
|
88
|
-
if (target === undefined)
|
|
89
|
-
target = this.create();
|
|
90
|
-
target.typeUrl = json["@type"];
|
|
91
|
-
target.value = type.toBinary(value);
|
|
92
|
-
return target;
|
|
93
|
-
}
|
|
94
|
-
typeNameToUrl(name) {
|
|
95
|
-
if (!name.length)
|
|
96
|
-
throw new Error("invalid type name: " + name);
|
|
97
|
-
return "type.googleapis.com/" + name;
|
|
98
|
-
}
|
|
99
|
-
typeUrlToName(url) {
|
|
100
|
-
if (!url.length)
|
|
101
|
-
throw new Error("invalid type url: " + url);
|
|
102
|
-
let slash = url.lastIndexOf("/");
|
|
103
|
-
let name = slash > 0 ? url.substring(slash + 1) : url;
|
|
104
|
-
if (!name.length)
|
|
105
|
-
throw new Error("invalid type url: " + url);
|
|
106
|
-
return name;
|
|
107
|
-
}
|
|
108
|
-
create(value) {
|
|
109
|
-
const message = globalThis.Object.create((this.messagePrototype));
|
|
110
|
-
message.typeUrl = "";
|
|
111
|
-
message.value = new Uint8Array(0);
|
|
112
|
-
if (value !== undefined)
|
|
113
|
-
(0, runtime_3.reflectionMergePartial)(this, message, value);
|
|
114
|
-
return message;
|
|
115
|
-
}
|
|
116
|
-
internalBinaryRead(reader, length, options, target) {
|
|
117
|
-
let message = target ?? this.create(), end = reader.pos + length;
|
|
118
|
-
while (reader.pos < end) {
|
|
119
|
-
let [fieldNo, wireType] = reader.tag();
|
|
120
|
-
switch (fieldNo) {
|
|
121
|
-
case /* string type_url */ 1:
|
|
122
|
-
message.typeUrl = reader.string();
|
|
123
|
-
break;
|
|
124
|
-
case /* bytes value */ 2:
|
|
125
|
-
message.value = reader.bytes();
|
|
126
|
-
break;
|
|
127
|
-
default:
|
|
128
|
-
let u = options.readUnknownField;
|
|
129
|
-
if (u === "throw")
|
|
130
|
-
throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
|
|
131
|
-
let d = reader.skip(wireType);
|
|
132
|
-
if (u !== false)
|
|
133
|
-
(u === true ? runtime_2.UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
|
|
134
|
-
}
|
|
135
|
-
}
|
|
136
|
-
return message;
|
|
137
|
-
}
|
|
138
|
-
internalBinaryWrite(message, writer, options) {
|
|
139
|
-
/* string type_url = 1; */
|
|
140
|
-
if (message.typeUrl !== "")
|
|
141
|
-
writer.tag(1, runtime_1.WireType.LengthDelimited).string(message.typeUrl);
|
|
142
|
-
/* bytes value = 2; */
|
|
143
|
-
if (message.value.length)
|
|
144
|
-
writer.tag(2, runtime_1.WireType.LengthDelimited).bytes(message.value);
|
|
145
|
-
let u = options.writeUnknownFields;
|
|
146
|
-
if (u !== false)
|
|
147
|
-
(u == true ? runtime_2.UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
|
148
|
-
return writer;
|
|
149
|
-
}
|
|
150
|
-
}
|
|
151
|
-
/**
|
|
152
|
-
* @generated MessageType for protobuf message google.protobuf.Any
|
|
153
|
-
*/
|
|
154
|
-
exports.Any = new Any$Type();
|
|
155
|
-
//# sourceMappingURL=any.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"any.js","sourceRoot":"","sources":["../../../../../src/proto/google/protobuf/any.ts"],"names":[],"mappings":";;;AAoCA,kDAAgD;AAEhD,kDAA2D;AAE3D,kDAA8D;AAC9D,kDAAoD;AACpD,kDAAuD;AAEvD,kDAAwD;AAKxD,kDAAmD;AA8HnD,2FAA2F;AAC3F,MAAM,QAAS,SAAQ,qBAAgB;IACnC;QACI,KAAK,CAAC,qBAAqB,EAAE;YACzB,EAAE,EAAE,EAAE,CAAC,EAAE,IAAI,EAAE,UAAU,EAAE,IAAI,EAAE,QAAQ,EAAE,CAAC,EAAE,CAAC,CAAC,qBAAqB,EA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AAE,MAAM,CAAC,CAAC;QAClF,OAAO,MAAM,CAAC;IAClB,CAAC;CACJ;AACD;;GAEG;AACU,QAAA,GAAG,GAAG,IAAI,QAAQ,EAAE,CAAC"}
|
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
import type { BinaryWriteOptions } from "@protobuf-ts/runtime";
|
|
2
|
-
import type { IBinaryWriter } from "@protobuf-ts/runtime";
|
|
3
|
-
import type { BinaryReadOptions } from "@protobuf-ts/runtime";
|
|
4
|
-
import type { IBinaryReader } from "@protobuf-ts/runtime";
|
|
5
|
-
import type { PartialMessage } from "@protobuf-ts/runtime";
|
|
6
|
-
import { MessageType } from "@protobuf-ts/runtime";
|
|
7
|
-
/**
|
|
8
|
-
* A generic empty message that you can re-use to avoid defining duplicated
|
|
9
|
-
* empty messages in your APIs. A typical example is to use it as the request
|
|
10
|
-
* or the response type of an API method. For instance:
|
|
11
|
-
*
|
|
12
|
-
* service Foo {
|
|
13
|
-
* rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty);
|
|
14
|
-
* }
|
|
15
|
-
*
|
|
16
|
-
* The JSON representation for `Empty` is empty JSON object `{}`.
|
|
17
|
-
*
|
|
18
|
-
* @generated from protobuf message google.protobuf.Empty
|
|
19
|
-
*/
|
|
20
|
-
export interface Empty {
|
|
21
|
-
}
|
|
22
|
-
declare class Empty$Type extends MessageType<Empty> {
|
|
23
|
-
constructor();
|
|
24
|
-
create(value?: PartialMessage<Empty>): Empty;
|
|
25
|
-
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: Empty): Empty;
|
|
26
|
-
internalBinaryWrite(message: Empty, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter;
|
|
27
|
-
}
|
|
28
|
-
/**
|
|
29
|
-
* @generated MessageType for protobuf message google.protobuf.Empty
|
|
30
|
-
*/
|
|
31
|
-
export declare const Empty: Empty$Type;
|
|
32
|
-
export {};
|
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.Empty = void 0;
|
|
4
|
-
const runtime_1 = require("@protobuf-ts/runtime");
|
|
5
|
-
const runtime_2 = require("@protobuf-ts/runtime");
|
|
6
|
-
const runtime_3 = require("@protobuf-ts/runtime");
|
|
7
|
-
// @generated message type with reflection information, may provide speed optimized methods
|
|
8
|
-
class Empty$Type extends runtime_3.MessageType {
|
|
9
|
-
constructor() {
|
|
10
|
-
super("google.protobuf.Empty", []);
|
|
11
|
-
}
|
|
12
|
-
create(value) {
|
|
13
|
-
const message = globalThis.Object.create((this.messagePrototype));
|
|
14
|
-
if (value !== undefined)
|
|
15
|
-
(0, runtime_2.reflectionMergePartial)(this, message, value);
|
|
16
|
-
return message;
|
|
17
|
-
}
|
|
18
|
-
internalBinaryRead(reader, length, options, target) {
|
|
19
|
-
return target ?? this.create();
|
|
20
|
-
}
|
|
21
|
-
internalBinaryWrite(message, writer, options) {
|
|
22
|
-
let u = options.writeUnknownFields;
|
|
23
|
-
if (u !== false)
|
|
24
|
-
(u == true ? runtime_1.UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
|
25
|
-
return writer;
|
|
26
|
-
}
|
|
27
|
-
}
|
|
28
|
-
/**
|
|
29
|
-
* @generated MessageType for protobuf message google.protobuf.Empty
|
|
30
|
-
*/
|
|
31
|
-
exports.Empty = new Empty$Type();
|
|
32
|
-
//# sourceMappingURL=empty.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"empty.js","sourceRoot":"","sources":["../../../../../src/proto/google/protobuf/empty.ts"],"names":[],"mappings":";;;AAoCA,kDAA2D;AAI3D,kDAA8D;AAC9D,kDAAmD;AAgBnD,2FAA2F;AAC3F,MAAM,UAAW,SAAQ,qBAAkB;IACvC;QACI,KAAK,CAAC,uBAAuB,EAAE,EAAE,CAAC,CAAC;IACvC,CAAC;IACD,MAAM,CAAC,KAA6B;QAChC,MAAM,OAAO,GAAG,UAAU,CAAC,MAAM,CAAC,MAAM,CAAC,CAAC,IAAI,CAAC,gBAAiB,CAAC,CAAC,CAAC;QACnE,IAAI,KAAK,KAAK,SAAS;YACnB,IAAA,gCAAsB,EAAQ,IAAI,EAAE,OAAO,EAAE,KAAK,CAAC,CAAC;QACxD,OAAO,OAAO,CAAC;IACnB,CAAC;IACD,kBAAkB,CAAC,MAAqB,EAAE,MAAc,EAAE,OAA0B,EAAE,MAAc;QAChG,OAAO,MAAM,IAAI,IAAI,CAAC,MAAM,EAAE,CAAC;IACnC,CAAC;IACD,mBAAmB,CAAC,OAAc,EAAE,MAAqB,EAAE,OAA2B;QAClF,IAAI,CAAC,GAAG,OAAO,CAAC,kBAAkB,CAAC;QACnC,IAAI,CAAC,KAAK,KAAK;YACX,CAAC,CAAC,IAAI,IAAI,CAAC,CAAC,CAAC,6BAAmB,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,QAAQ,EAAE,OAAO,EAAE,MAAM,CAAC,CAAC;QAClF,OAAO,MAAM,CAAC;IAClB,CAAC;CACJ;AACD;;GAEG;AACU,QAAA,KAAK,GAAG,IAAI,UAAU,EAAE,CAAC"}
|
|
@@ -1,149 +0,0 @@
|
|
|
1
|
-
import type { BinaryWriteOptions } from "@protobuf-ts/runtime";
|
|
2
|
-
import type { IBinaryWriter } from "@protobuf-ts/runtime";
|
|
3
|
-
import type { BinaryReadOptions } from "@protobuf-ts/runtime";
|
|
4
|
-
import type { IBinaryReader } from "@protobuf-ts/runtime";
|
|
5
|
-
import type { PartialMessage } from "@protobuf-ts/runtime";
|
|
6
|
-
import type { JsonValue } from "@protobuf-ts/runtime";
|
|
7
|
-
import type { JsonReadOptions } from "@protobuf-ts/runtime";
|
|
8
|
-
import type { JsonWriteOptions } from "@protobuf-ts/runtime";
|
|
9
|
-
import { MessageType } from "@protobuf-ts/runtime";
|
|
10
|
-
/**
|
|
11
|
-
* A Timestamp represents a point in time independent of any time zone or local
|
|
12
|
-
* calendar, encoded as a count of seconds and fractions of seconds at
|
|
13
|
-
* nanosecond resolution. The count is relative to an epoch at UTC midnight on
|
|
14
|
-
* January 1, 1970, in the proleptic Gregorian calendar which extends the
|
|
15
|
-
* Gregorian calendar backwards to year one.
|
|
16
|
-
*
|
|
17
|
-
* All minutes are 60 seconds long. Leap seconds are "smeared" so that no leap
|
|
18
|
-
* second table is needed for interpretation, using a [24-hour linear
|
|
19
|
-
* smear](https://developers.google.com/time/smear).
|
|
20
|
-
*
|
|
21
|
-
* The range is from 0001-01-01T00:00:00Z to 9999-12-31T23:59:59.999999999Z. By
|
|
22
|
-
* restricting to that range, we ensure that we can convert to and from [RFC
|
|
23
|
-
* 3339](https://www.ietf.org/rfc/rfc3339.txt) date strings.
|
|
24
|
-
*
|
|
25
|
-
* # Examples
|
|
26
|
-
*
|
|
27
|
-
* Example 1: Compute Timestamp from POSIX `time()`.
|
|
28
|
-
*
|
|
29
|
-
* Timestamp timestamp;
|
|
30
|
-
* timestamp.set_seconds(time(NULL));
|
|
31
|
-
* timestamp.set_nanos(0);
|
|
32
|
-
*
|
|
33
|
-
* Example 2: Compute Timestamp from POSIX `gettimeofday()`.
|
|
34
|
-
*
|
|
35
|
-
* struct timeval tv;
|
|
36
|
-
* gettimeofday(&tv, NULL);
|
|
37
|
-
*
|
|
38
|
-
* Timestamp timestamp;
|
|
39
|
-
* timestamp.set_seconds(tv.tv_sec);
|
|
40
|
-
* timestamp.set_nanos(tv.tv_usec * 1000);
|
|
41
|
-
*
|
|
42
|
-
* Example 3: Compute Timestamp from Win32 `GetSystemTimeAsFileTime()`.
|
|
43
|
-
*
|
|
44
|
-
* FILETIME ft;
|
|
45
|
-
* GetSystemTimeAsFileTime(&ft);
|
|
46
|
-
* UINT64 ticks = (((UINT64)ft.dwHighDateTime) << 32) | ft.dwLowDateTime;
|
|
47
|
-
*
|
|
48
|
-
* // A Windows tick is 100 nanoseconds. Windows epoch 1601-01-01T00:00:00Z
|
|
49
|
-
* // is 11644473600 seconds before Unix epoch 1970-01-01T00:00:00Z.
|
|
50
|
-
* Timestamp timestamp;
|
|
51
|
-
* timestamp.set_seconds((INT64) ((ticks / 10000000) - 11644473600LL));
|
|
52
|
-
* timestamp.set_nanos((INT32) ((ticks % 10000000) * 100));
|
|
53
|
-
*
|
|
54
|
-
* Example 4: Compute Timestamp from Java `System.currentTimeMillis()`.
|
|
55
|
-
*
|
|
56
|
-
* long millis = System.currentTimeMillis();
|
|
57
|
-
*
|
|
58
|
-
* Timestamp timestamp = Timestamp.newBuilder().setSeconds(millis / 1000)
|
|
59
|
-
* .setNanos((int) ((millis % 1000) * 1000000)).build();
|
|
60
|
-
*
|
|
61
|
-
*
|
|
62
|
-
* Example 5: Compute Timestamp from current time in Python.
|
|
63
|
-
*
|
|
64
|
-
* timestamp = Timestamp()
|
|
65
|
-
* timestamp.GetCurrentTime()
|
|
66
|
-
*
|
|
67
|
-
* # JSON Mapping
|
|
68
|
-
*
|
|
69
|
-
* In JSON format, the Timestamp type is encoded as a string in the
|
|
70
|
-
* [RFC 3339](https://www.ietf.org/rfc/rfc3339.txt) format. That is, the
|
|
71
|
-
* format is "{year}-{month}-{day}T{hour}:{min}:{sec}[.{frac_sec}]Z"
|
|
72
|
-
* where {year} is always expressed using four digits while {month}, {day},
|
|
73
|
-
* {hour}, {min}, and {sec} are zero-padded to two digits each. The fractional
|
|
74
|
-
* seconds, which can go up to 9 digits (i.e. up to 1 nanosecond resolution),
|
|
75
|
-
* are optional. The "Z" suffix indicates the timezone ("UTC"); the timezone
|
|
76
|
-
* is required. A proto3 JSON serializer should always use UTC (as indicated by
|
|
77
|
-
* "Z") when printing the Timestamp type and a proto3 JSON parser should be
|
|
78
|
-
* able to accept both UTC and other timezones (as indicated by an offset).
|
|
79
|
-
*
|
|
80
|
-
* For example, "2017-01-15T01:30:15.01Z" encodes 15.01 seconds past
|
|
81
|
-
* 01:30 UTC on January 15, 2017.
|
|
82
|
-
*
|
|
83
|
-
* In JavaScript, one can convert a Date object to this format using the
|
|
84
|
-
* standard
|
|
85
|
-
* [toISOString()](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toISOString)
|
|
86
|
-
* method. In Python, a standard `datetime.datetime` object can be converted
|
|
87
|
-
* to this format using
|
|
88
|
-
* [`strftime`](https://docs.python.org/2/library/time.html#time.strftime) with
|
|
89
|
-
* the time format spec '%Y-%m-%dT%H:%M:%S.%fZ'. Likewise, in Java, one can use
|
|
90
|
-
* the Joda Time's [`ISODateTimeFormat.dateTime()`](
|
|
91
|
-
* http://www.joda.org/joda-time/apidocs/org/joda/time/format/ISODateTimeFormat.html#dateTime%2D%2D
|
|
92
|
-
* ) to obtain a formatter capable of generating timestamps in this format.
|
|
93
|
-
*
|
|
94
|
-
*
|
|
95
|
-
*
|
|
96
|
-
* @generated from protobuf message google.protobuf.Timestamp
|
|
97
|
-
*/
|
|
98
|
-
export interface Timestamp {
|
|
99
|
-
/**
|
|
100
|
-
* Represents seconds of UTC time since Unix epoch
|
|
101
|
-
* 1970-01-01T00:00:00Z. Must be from 0001-01-01T00:00:00Z to
|
|
102
|
-
* 9999-12-31T23:59:59Z inclusive.
|
|
103
|
-
*
|
|
104
|
-
* @generated from protobuf field: int64 seconds = 1;
|
|
105
|
-
*/
|
|
106
|
-
seconds: number;
|
|
107
|
-
/**
|
|
108
|
-
* Non-negative fractions of a second at nanosecond resolution. Negative
|
|
109
|
-
* second values with fractions must still have non-negative nanos values
|
|
110
|
-
* that count forward in time. Must be from 0 to 999,999,999
|
|
111
|
-
* inclusive.
|
|
112
|
-
*
|
|
113
|
-
* @generated from protobuf field: int32 nanos = 2;
|
|
114
|
-
*/
|
|
115
|
-
nanos: number;
|
|
116
|
-
}
|
|
117
|
-
declare class Timestamp$Type extends MessageType<Timestamp> {
|
|
118
|
-
constructor();
|
|
119
|
-
/**
|
|
120
|
-
* Creates a new `Timestamp` for the current time.
|
|
121
|
-
*/
|
|
122
|
-
now(): Timestamp;
|
|
123
|
-
/**
|
|
124
|
-
* Converts a `Timestamp` to a JavaScript Date.
|
|
125
|
-
*/
|
|
126
|
-
toDate(message: Timestamp): Date;
|
|
127
|
-
/**
|
|
128
|
-
* Converts a JavaScript Date to a `Timestamp`.
|
|
129
|
-
*/
|
|
130
|
-
fromDate(date: Date): Timestamp;
|
|
131
|
-
/**
|
|
132
|
-
* In JSON format, the `Timestamp` type is encoded as a string
|
|
133
|
-
* in the RFC 3339 format.
|
|
134
|
-
*/
|
|
135
|
-
internalJsonWrite(message: Timestamp, options: JsonWriteOptions): JsonValue;
|
|
136
|
-
/**
|
|
137
|
-
* In JSON format, the `Timestamp` type is encoded as a string
|
|
138
|
-
* in the RFC 3339 format.
|
|
139
|
-
*/
|
|
140
|
-
internalJsonRead(json: JsonValue, options: JsonReadOptions, target?: Timestamp): Timestamp;
|
|
141
|
-
create(value?: PartialMessage<Timestamp>): Timestamp;
|
|
142
|
-
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: Timestamp): Timestamp;
|
|
143
|
-
internalBinaryWrite(message: Timestamp, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter;
|
|
144
|
-
}
|
|
145
|
-
/**
|
|
146
|
-
* @generated MessageType for protobuf message google.protobuf.Timestamp
|
|
147
|
-
*/
|
|
148
|
-
export declare const Timestamp: Timestamp$Type;
|
|
149
|
-
export {};
|
|
@@ -1,136 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.Timestamp = void 0;
|
|
4
|
-
const runtime_1 = require("@protobuf-ts/runtime");
|
|
5
|
-
const runtime_2 = require("@protobuf-ts/runtime");
|
|
6
|
-
const runtime_3 = require("@protobuf-ts/runtime");
|
|
7
|
-
const runtime_4 = require("@protobuf-ts/runtime");
|
|
8
|
-
const runtime_5 = require("@protobuf-ts/runtime");
|
|
9
|
-
const runtime_6 = require("@protobuf-ts/runtime");
|
|
10
|
-
// @generated message type with reflection information, may provide speed optimized methods
|
|
11
|
-
class Timestamp$Type extends runtime_6.MessageType {
|
|
12
|
-
constructor() {
|
|
13
|
-
super("google.protobuf.Timestamp", [
|
|
14
|
-
{ no: 1, name: "seconds", kind: "scalar", T: 3 /*ScalarType.INT64*/, L: 2 /*LongType.NUMBER*/ },
|
|
15
|
-
{ no: 2, name: "nanos", kind: "scalar", T: 5 /*ScalarType.INT32*/ }
|
|
16
|
-
]);
|
|
17
|
-
}
|
|
18
|
-
/**
|
|
19
|
-
* Creates a new `Timestamp` for the current time.
|
|
20
|
-
*/
|
|
21
|
-
now() {
|
|
22
|
-
const msg = this.create();
|
|
23
|
-
const ms = Date.now();
|
|
24
|
-
msg.seconds = runtime_5.PbLong.from(Math.floor(ms / 1000)).toNumber();
|
|
25
|
-
msg.nanos = (ms % 1000) * 1000000;
|
|
26
|
-
return msg;
|
|
27
|
-
}
|
|
28
|
-
/**
|
|
29
|
-
* Converts a `Timestamp` to a JavaScript Date.
|
|
30
|
-
*/
|
|
31
|
-
toDate(message) {
|
|
32
|
-
return new Date(runtime_5.PbLong.from(message.seconds).toNumber() * 1000 + Math.ceil(message.nanos / 1000000));
|
|
33
|
-
}
|
|
34
|
-
/**
|
|
35
|
-
* Converts a JavaScript Date to a `Timestamp`.
|
|
36
|
-
*/
|
|
37
|
-
fromDate(date) {
|
|
38
|
-
const msg = this.create();
|
|
39
|
-
const ms = date.getTime();
|
|
40
|
-
msg.seconds = runtime_5.PbLong.from(Math.floor(ms / 1000)).toNumber();
|
|
41
|
-
msg.nanos = (ms % 1000) * 1000000;
|
|
42
|
-
return msg;
|
|
43
|
-
}
|
|
44
|
-
/**
|
|
45
|
-
* In JSON format, the `Timestamp` type is encoded as a string
|
|
46
|
-
* in the RFC 3339 format.
|
|
47
|
-
*/
|
|
48
|
-
internalJsonWrite(message, options) {
|
|
49
|
-
let ms = runtime_5.PbLong.from(message.seconds).toNumber() * 1000;
|
|
50
|
-
if (ms < Date.parse("0001-01-01T00:00:00Z") || ms > Date.parse("9999-12-31T23:59:59Z"))
|
|
51
|
-
throw new Error("Unable to encode Timestamp to JSON. Must be from 0001-01-01T00:00:00Z to 9999-12-31T23:59:59Z inclusive.");
|
|
52
|
-
if (message.nanos < 0)
|
|
53
|
-
throw new Error("Unable to encode invalid Timestamp to JSON. Nanos must not be negative.");
|
|
54
|
-
let z = "Z";
|
|
55
|
-
if (message.nanos > 0) {
|
|
56
|
-
let nanosStr = (message.nanos + 1000000000).toString().substring(1);
|
|
57
|
-
if (nanosStr.substring(3) === "000000")
|
|
58
|
-
z = "." + nanosStr.substring(0, 3) + "Z";
|
|
59
|
-
else if (nanosStr.substring(6) === "000")
|
|
60
|
-
z = "." + nanosStr.substring(0, 6) + "Z";
|
|
61
|
-
else
|
|
62
|
-
z = "." + nanosStr + "Z";
|
|
63
|
-
}
|
|
64
|
-
return new Date(ms).toISOString().replace(".000Z", z);
|
|
65
|
-
}
|
|
66
|
-
/**
|
|
67
|
-
* In JSON format, the `Timestamp` type is encoded as a string
|
|
68
|
-
* in the RFC 3339 format.
|
|
69
|
-
*/
|
|
70
|
-
internalJsonRead(json, options, target) {
|
|
71
|
-
if (typeof json !== "string")
|
|
72
|
-
throw new Error("Unable to parse Timestamp from JSON " + (0, runtime_4.typeofJsonValue)(json) + ".");
|
|
73
|
-
let matches = json.match(/^([0-9]{4})-([0-9]{2})-([0-9]{2})T([0-9]{2}):([0-9]{2}):([0-9]{2})(?:Z|\.([0-9]{3,9})Z|([+-][0-9][0-9]:[0-9][0-9]))$/);
|
|
74
|
-
if (!matches)
|
|
75
|
-
throw new Error("Unable to parse Timestamp from JSON. Invalid format.");
|
|
76
|
-
let ms = Date.parse(matches[1] + "-" + matches[2] + "-" + matches[3] + "T" + matches[4] + ":" + matches[5] + ":" + matches[6] + (matches[8] ? matches[8] : "Z"));
|
|
77
|
-
if (Number.isNaN(ms))
|
|
78
|
-
throw new Error("Unable to parse Timestamp from JSON. Invalid value.");
|
|
79
|
-
if (ms < Date.parse("0001-01-01T00:00:00Z") || ms > Date.parse("9999-12-31T23:59:59Z"))
|
|
80
|
-
throw new globalThis.Error("Unable to parse Timestamp from JSON. Must be from 0001-01-01T00:00:00Z to 9999-12-31T23:59:59Z inclusive.");
|
|
81
|
-
if (!target)
|
|
82
|
-
target = this.create();
|
|
83
|
-
target.seconds = runtime_5.PbLong.from(ms / 1000).toNumber();
|
|
84
|
-
target.nanos = 0;
|
|
85
|
-
if (matches[7])
|
|
86
|
-
target.nanos = (parseInt("1" + matches[7] + "0".repeat(9 - matches[7].length)) - 1000000000);
|
|
87
|
-
return target;
|
|
88
|
-
}
|
|
89
|
-
create(value) {
|
|
90
|
-
const message = globalThis.Object.create((this.messagePrototype));
|
|
91
|
-
message.seconds = 0;
|
|
92
|
-
message.nanos = 0;
|
|
93
|
-
if (value !== undefined)
|
|
94
|
-
(0, runtime_3.reflectionMergePartial)(this, message, value);
|
|
95
|
-
return message;
|
|
96
|
-
}
|
|
97
|
-
internalBinaryRead(reader, length, options, target) {
|
|
98
|
-
let message = target ?? this.create(), end = reader.pos + length;
|
|
99
|
-
while (reader.pos < end) {
|
|
100
|
-
let [fieldNo, wireType] = reader.tag();
|
|
101
|
-
switch (fieldNo) {
|
|
102
|
-
case /* int64 seconds */ 1:
|
|
103
|
-
message.seconds = reader.int64().toNumber();
|
|
104
|
-
break;
|
|
105
|
-
case /* int32 nanos */ 2:
|
|
106
|
-
message.nanos = reader.int32();
|
|
107
|
-
break;
|
|
108
|
-
default:
|
|
109
|
-
let u = options.readUnknownField;
|
|
110
|
-
if (u === "throw")
|
|
111
|
-
throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
|
|
112
|
-
let d = reader.skip(wireType);
|
|
113
|
-
if (u !== false)
|
|
114
|
-
(u === true ? runtime_2.UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
|
|
115
|
-
}
|
|
116
|
-
}
|
|
117
|
-
return message;
|
|
118
|
-
}
|
|
119
|
-
internalBinaryWrite(message, writer, options) {
|
|
120
|
-
/* int64 seconds = 1; */
|
|
121
|
-
if (message.seconds !== 0)
|
|
122
|
-
writer.tag(1, runtime_1.WireType.Varint).int64(message.seconds);
|
|
123
|
-
/* int32 nanos = 2; */
|
|
124
|
-
if (message.nanos !== 0)
|
|
125
|
-
writer.tag(2, runtime_1.WireType.Varint).int32(message.nanos);
|
|
126
|
-
let u = options.writeUnknownFields;
|
|
127
|
-
if (u !== false)
|
|
128
|
-
(u == true ? runtime_2.UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
|
129
|
-
return writer;
|
|
130
|
-
}
|
|
131
|
-
}
|
|
132
|
-
/**
|
|
133
|
-
* @generated MessageType for protobuf message google.protobuf.Timestamp
|
|
134
|
-
*/
|
|
135
|
-
exports.Timestamp = new Timestamp$Type();
|
|
136
|
-
//# sourceMappingURL=timestamp.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"timestamp.js","sourceRoot":"","sources":["../../../../../src/proto/google/protobuf/timestamp.ts"],"names":[],"mappings":";;;AAoCA,kDAAgD;AAGhD,kDAA2D;AAE3D,kDAA8D;AAC9D,kDAAuD;AAIvD,kDAA8C;AAC9C,kDAAmD;AA4GnD,2FAA2F;AAC3F,MAAM,cAAe,SAAQ,qBAAsB;IAC/C;QACI,KAAK,CAAC,2BAA2B,EAAE;YAC/B,EAAE,EAAE,EAAE,CAAC,EAAE,IAAI,EAAE,SAAS,EAAE,IAAI,EAAE,QAAQ,EAAE,CAAC,EAAE,CAAC,CAAC,oBAAoB,EAAE,CAAC,EAAE,CAAC,CAAC,mBAAmB,EAAE;YAC/F,EAAE,EAAE,EAAE,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,IAAI,EAAE,QAAQ,EAAE,CAAC,EAAE,CAAC,CAAC,oBAAoB,EAAE;SACtE,CAAC,CAAC;IACP,CAAC;IACD;;OAEG;IACH,GAAG;QACC,MAAM,GAAG,GAAG,IAAI,CAAC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