Add CultMesh peer exchange catalogs
This commit is contained in:
parent
dfa7db607a
commit
c612eb4307
10 changed files with 718 additions and 1 deletions
|
|
@ -196,6 +196,14 @@ namespace GameCult.Mesh
|
|||
return new CultMeshVerseCatalog();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Creates a local reactive catalog for discovered peers.
|
||||
/// </summary>
|
||||
public static CultMeshPeerCatalog CreatePeerCatalog()
|
||||
{
|
||||
return new CultMeshPeerCatalog();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Attaches Verse discovery responses to a CultMesh node.
|
||||
/// </summary>
|
||||
|
|
@ -207,6 +215,26 @@ namespace GameCult.Mesh
|
|||
return new CultMeshVerseDiscoveryServer(node.Server, catalog);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Creates a client for fetching Verse catalogs from discovery endpoints.
|
||||
/// </summary>
|
||||
public static CultMeshVerseDiscoveryClient CreateVerseDiscoveryClient(
|
||||
CultMeshVerseDiscoveryClientOptions? options = null)
|
||||
{
|
||||
return new CultMeshVerseDiscoveryClient(options);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Attaches peer exchange responses to a CultMesh node.
|
||||
/// </summary>
|
||||
public static CultMeshPeerExchangeServer ServePeerExchange(
|
||||
CultMeshNode node,
|
||||
CultMeshPeerCatalog catalog)
|
||||
{
|
||||
if (node == null) throw new ArgumentNullException(nameof(node));
|
||||
return new CultMeshPeerExchangeServer(node.Server, catalog);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Creates a CultNet client configured for CultMesh use.
|
||||
/// </summary>
|
||||
|
|
|
|||
Loading…
Reference in a new issue