@libp2p/interface-internal
Advanced tools
Comparing version 0.1.3 to 0.1.4-32825633
@@ -6,2 +6,15 @@ import type { AbortOptions, PendingDial } from '@libp2p/interface'; | ||
import type { Multiaddr } from '@multiformats/multiaddr'; | ||
export interface OpenConnectionOptions extends AbortOptions { | ||
/** | ||
* Connection requests with a higher priority will be executed before those | ||
* with a lower priority. (default: 50) | ||
*/ | ||
priority?: number; | ||
/** | ||
* When opening a connection to a remote peer, if a connection already exists | ||
* it will be returned instead of creating a new connection. Pass true here | ||
* to override that and dial a new connection anyway. (default: false) | ||
*/ | ||
force?: boolean; | ||
} | ||
export interface ConnectionManager { | ||
@@ -38,3 +51,3 @@ /** | ||
*/ | ||
openConnection: (peer: PeerId | Multiaddr | Multiaddr[], options?: AbortOptions) => Promise<Connection>; | ||
openConnection: (peer: PeerId | Multiaddr | Multiaddr[], options?: OpenConnectionOptions) => Promise<Connection>; | ||
/** | ||
@@ -41,0 +54,0 @@ * Close our connections to a peer |
{ | ||
"name": "@libp2p/interface-internal", | ||
"version": "0.1.3", | ||
"version": "0.1.4-32825633", | ||
"description": "Interfaces implemented by internal libp2p components", | ||
@@ -81,4 +81,4 @@ "license": "Apache-2.0 OR MIT", | ||
"dependencies": { | ||
"@libp2p/interface": "^0.1.2", | ||
"@libp2p/peer-collections": "^4.0.3", | ||
"@libp2p/interface": "0.1.2-32825633", | ||
"@libp2p/peer-collections": "4.0.3-32825633", | ||
"@multiformats/multiaddr": "^12.1.5", | ||
@@ -85,0 +85,0 @@ "uint8arraylist": "^2.4.3" |
@@ -7,2 +7,17 @@ import type { AbortOptions, PendingDial } from '@libp2p/interface' | ||
export interface OpenConnectionOptions extends AbortOptions { | ||
/** | ||
* Connection requests with a higher priority will be executed before those | ||
* with a lower priority. (default: 50) | ||
*/ | ||
priority?: number | ||
/** | ||
* When opening a connection to a remote peer, if a connection already exists | ||
* it will be returned instead of creating a new connection. Pass true here | ||
* to override that and dial a new connection anyway. (default: false) | ||
*/ | ||
force?: boolean | ||
} | ||
export interface ConnectionManager { | ||
@@ -41,3 +56,3 @@ /** | ||
*/ | ||
openConnection: (peer: PeerId | Multiaddr | Multiaddr[], options?: AbortOptions) => Promise<Connection> | ||
openConnection: (peer: PeerId | Multiaddr | Multiaddr[], options?: OpenConnectionOptions) => Promise<Connection> | ||
@@ -44,0 +59,0 @@ /** |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
458
24821
34
+ Added@libp2p/interface@0.1.2-32825633(transitive)
+ Added@libp2p/peer-collections@4.0.3-32825633(transitive)
+ Added@libp2p/peer-id@3.0.2-32825633(transitive)
- Removed@libp2p/interface@0.1.6(transitive)
- Removed@libp2p/peer-collections@4.0.11(transitive)
- Removed@libp2p/peer-id@3.0.6(transitive)
- Removedrace-signal@1.1.0(transitive)