Exemple #1
0
        public static ILifecycle Create(RpcEndPoint endPoint, IAccountLoginService accountLoginService)
        {
            var port       = new ServerPort(endPoint.Host, endPoint.Port, ServerCredentials.Insecure);
            var controller = new RpcServiceController(port);

            controller.RegisterService(token => AccountAuthentication.BindService(new AccountAuthenticationService(accountLoginService, token)));
            return(controller);
        }
Exemple #2
0
        public static ILifecycle Create(RpcEndPoint endPoint, IGameServerRegistrar gameServerRegistrar)
        {
            var port       = new ServerPort(endPoint.Host, endPoint.Port, ServerCredentials.Insecure);
            var controller = new RpcServiceController(port);

            controller.RegisterService(token => GameServerRegistrar.BindService(new GameServerRegistrarService(gameServerRegistrar, token)));
            return(controller);
        }
Exemple #3
0
 public RPCClient CreateRpcClient()
 {
     return(new RPCClient($"{Creds.UserName}:{Creds.Password}", RpcEndPoint.ToString(RpcPort), Network.RegTest));
 }
Exemple #4
0
 /// <summary>Initializes a new instance of the <see cref="AccountLoginServiceProxy"/> class.</summary>
 public AccountLoginServiceProxy(RpcEndPoint endPoint) => this.endPoint = endPoint;