export = PeerList; /** * @typedef {import('peer-id')} PeerId */ /** * A list of unique peers. */ declare class PeerList { /** @type {PeerId[]} */ list: PeerId[]; /** * Add a new peer. Returns `true` if it was a new one * * @param {PeerId} peerId */ push(peerId: PeerId): boolean; /** * Check if this PeerData is already in here. * * @param {PeerId} peerId */ has(peerId: PeerId): boolean; /** * Get the list as an array. */ toArray(): import("peer-id")[]; /** * Remove the last element */ pop(): import("peer-id") | undefined; /** * The length of the list */ get length(): number; } declare namespace PeerList { export { PeerId }; } type PeerId = import('peer-id'); //# sourceMappingURL=index.d.ts.map