Skip to content

Interface IServerService

Namespace: Void.Proxy.Api.Servers
Assembly: Void.Proxy.Api.dll

Provides access to the collection of servers available to the proxy.

public interface IServerService

Properties

All

Gets all configured servers.

IEnumerable<IServer> All { get; }

Property Value

IEnumerable<IServer>

Methods

GetByName(string)

Finds a configured server by name using an ordinal, case-insensitive comparison.

IServer? GetByName(string name)

Parameters

name string

The server name to find.

Returns

IServer?

The first matching server, or null when no server has that name.

TryGetByName(string, out IServer)

Attempts to find a configured server by name using an ordinal, case-insensitive comparison.

bool TryGetByName(string name, out IServer server)

Parameters

name string

The server name to find.

server IServer

When this method returns true, the first matching server; otherwise, null.

Returns

bool

true when a matching server exists; otherwise, false.