@libp2p/interface-internal 0.0.1-7debe031 → 0.0.1-7f60b579

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.
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAA"}
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":""}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAA"}
@@ -16,6 +16,12 @@ export interface StreamHandlerOptions {
16
16
  * How many outgoing streams can be open for this protocol at the same time on each connection (default: 64)
17
17
  */
18
18
  maxOutboundStreams?: number;
19
+ /**
20
+ * If true, allow this protocol to run on limited connections (e.g.
21
+ * connections with data or duration limits such as circuit relay
22
+ * connections) (default: false)
23
+ */
24
+ runOnTransientConnection?: boolean;
19
25
  }
20
26
  export interface StreamHandlerRecord {
21
27
  handler: StreamHandler;
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/registrar/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,EAAE,MAAM,8BAA8B,CAAA;AACtE,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,4BAA4B,CAAA;AAE1D,MAAM,WAAW,kBAAkB;IACjC,MAAM,EAAE,MAAM,CAAA;IACd,UAAU,EAAE,UAAU,CAAA;CACvB;AAED,MAAM,WAAW,aAAa;IAC5B,CAAC,IAAI,EAAE,kBAAkB,GAAG,IAAI,CAAA;CACjC;AAED,MAAM,WAAW,oBAAoB;IACnC;;OAEG;IACH,iBAAiB,CAAC,EAAE,MAAM,CAAA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BAAoB;IACnC;;OAEG;IACH,iBAAiB,CAAC,EAAE,MAAM,CAAA;IAE1B;;OAEG;IACH,kBAAkB,CAAC,EAAE,MAAM,CAAA;IAE3B;;;;OAIG;IACH,wBAAwB,CAAC,EAAE,OAAO,CAAA;CACnC;AAED,MAAM,WAAW,mBAAmB;IAClC,OAAO,EAAE,aAAa,CAAA;IACtB,OAAO,EAAE,oBAAoB,CAAA;CAC9B;AAED,MAAM,WAAW,SAAS;IACxB;;OAEG;IACH,YAAY,EAAE,MAAM,MAAM,EAAE,CAAA;IAE5B;;OAEG;IACH,MAAM,EAAE,CAAC,QAAQ,EAAE,MAAM,EAAE,OAAO,EAAE,aAAa,EAAE,OAAO,CAAC,EAAE,oBAAoB,KAAK,OAAO,CAAC,IAAI,CAAC,CAAA;IAEnG;;OAEG;IACH,QAAQ,EAAE,CAAC,QAAQ,EAAE,MAAM,KAAK,OAAO,CAAC,IAAI,CAAC,CAAA;IAE7C;;OAEG;IACH,UAAU,EAAE,CAAC,QAAQ,EAAE,MAAM,KAAK,mBAAmB,CAAA;IAErD;;;;;;;OAOG;IACH,QAAQ,EAAE,CAAC,QAAQ,EAAE,MAAM,EAAE,QAAQ,EAAE,QAAQ,KAAK,OAAO,CAAC,MAAM,CAAC,CAAA;IAEnE;;OAEG;IACH,UAAU,EAAE,CAAC,EAAE,EAAE,MAAM,KAAK,IAAI,CAAA;IAEhC;;;OAGG;IACH,aAAa,EAAE,CAAC,QAAQ,EAAE,MAAM,KAAK,QAAQ,EAAE,CAAA;CAChD"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@libp2p/interface-internal",
3
- "version": "0.0.1-7debe031",
3
+ "version": "0.0.1-7f60b579",
4
4
  "description": "Interfaces implemented by internal libp2p components",
5
5
  "license": "Apache-2.0 OR MIT",
6
6
  "homepage": "https://github.com/libp2p/js-libp2p/tree/master/packages/interface-internal#readme",
@@ -60,10 +60,6 @@
60
60
  "types": "./dist/src/registrar/index.d.ts",
61
61
  "import": "./dist/src/registrar/index.js"
62
62
  },
63
- "./transport": {
64
- "types": "./dist/src/transport/index.d.ts",
65
- "import": "./dist/src/transport/index.js"
66
- },
67
63
  "./transport-manager": {
68
64
  "types": "./dist/src/transport-manager/index.d.ts",
69
65
  "import": "./dist/src/transport-manager/index.js"
@@ -82,15 +78,12 @@
82
78
  "build": "aegir build"
83
79
  },
84
80
  "dependencies": {
85
- "@libp2p/interface": "0.0.1-7debe031",
86
- "@libp2p/peer-collections": "3.0.2-7debe031",
81
+ "@libp2p/interface": "0.0.1-7f60b579",
82
+ "@libp2p/peer-collections": "3.0.2-7f60b579",
87
83
  "@multiformats/multiaddr": "^12.1.3",
88
84
  "uint8arraylist": "^2.4.3"
89
85
  },
90
86
  "devDependencies": {
91
- "aegir": "^39.0.13"
92
- },
93
- "typedoc": {
94
- "entryPoint": "./src/index.ts"
87
+ "aegir": "^40.0.1"
95
88
  }
96
89
  }
package/src/index.ts CHANGED
@@ -1,2 +1 @@
1
-
2
1
  export {}
@@ -20,6 +20,13 @@ export interface StreamHandlerOptions {
20
20
  * How many outgoing streams can be open for this protocol at the same time on each connection (default: 64)
21
21
  */
22
22
  maxOutboundStreams?: number
23
+
24
+ /**
25
+ * If true, allow this protocol to run on limited connections (e.g.
26
+ * connections with data or duration limits such as circuit relay
27
+ * connections) (default: false)
28
+ */
29
+ runOnTransientConnection?: boolean
23
30
  }
24
31
 
25
32
  export interface StreamHandlerRecord {
@@ -1,18 +0,0 @@
1
- import type { Connection, MultiaddrConnection } from '@libp2p/interface/connection';
2
- import type { StreamMuxerFactory } from '@libp2p/interface/stream-muxer';
3
- export interface UpgraderOptions {
4
- skipEncryption?: boolean;
5
- skipProtection?: boolean;
6
- muxerFactory?: StreamMuxerFactory;
7
- }
8
- export interface Upgrader {
9
- /**
10
- * Upgrades an outbound connection on `transport.dial`.
11
- */
12
- upgradeOutbound: (maConn: MultiaddrConnection, opts?: UpgraderOptions) => Promise<Connection>;
13
- /**
14
- * Upgrades an inbound connection on transport listener.
15
- */
16
- upgradeInbound: (maConn: MultiaddrConnection, opts?: UpgraderOptions) => Promise<Connection>;
17
- }
18
- //# sourceMappingURL=index.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/upgrader/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAE,mBAAmB,EAAE,MAAM,8BAA8B,CAAA;AACnF,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,gCAAgC,CAAA;AAExE,MAAM,WAAW,eAAe;IAC9B,cAAc,CAAC,EAAE,OAAO,CAAA;IACxB,cAAc,CAAC,EAAE,OAAO,CAAA;IACxB,YAAY,CAAC,EAAE,kBAAkB,CAAA;CAClC;AAED,MAAM,WAAW,QAAQ;IACvB;;OAEG;IACH,eAAe,EAAE,CAAC,MAAM,EAAE,mBAAmB,EAAE,IAAI,CAAC,EAAE,eAAe,KAAK,OAAO,CAAC,UAAU,CAAC,CAAA;IAE7F;;OAEG;IACH,cAAc,EAAE,CAAC,MAAM,EAAE,mBAAmB,EAAE,IAAI,CAAC,EAAE,eAAe,KAAK,OAAO,CAAC,UAAU,CAAC,CAAA;CAC7F"}
@@ -1,2 +0,0 @@
1
- export {};
2
- //# sourceMappingURL=index.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/upgrader/index.ts"],"names":[],"mappings":""}
@@ -1,20 +0,0 @@
1
- import type { Connection, MultiaddrConnection } from '@libp2p/interface/connection'
2
- import type { StreamMuxerFactory } from '@libp2p/interface/stream-muxer'
3
-
4
- export interface UpgraderOptions {
5
- skipEncryption?: boolean
6
- skipProtection?: boolean
7
- muxerFactory?: StreamMuxerFactory
8
- }
9
-
10
- export interface Upgrader {
11
- /**
12
- * Upgrades an outbound connection on `transport.dial`.
13
- */
14
- upgradeOutbound: (maConn: MultiaddrConnection, opts?: UpgraderOptions) => Promise<Connection>
15
-
16
- /**
17
- * Upgrades an inbound connection on transport listener.
18
- */
19
- upgradeInbound: (maConn: MultiaddrConnection, opts?: UpgraderOptions) => Promise<Connection>
20
- }