Exemple #1
0
        public Program(LibraNetwork network)
        {
            this.network = network;
            this.wallet  = new LibraWallet();
            this.client  = new LibraClient(network);
            switch (network)
            {
            case LibraNetwork.Testnet:
                this.serverHost = Constant.ServerHosts.TestnetAdmissionControl;
                break;
            }

            Console.WriteLine("Blockcoli.Libra.Net.Cli command-line interface for Libra Wallet.");
        }
Exemple #2
0
        public LibraClient(LibraNetwork network)
        {
            this.Network = network;

            switch (network)
            {
            case LibraNetwork.Testnet:
                Host = Constant.ServerHosts.TestnetAdmissionControl;
                Port = 80;
                ChannelCredentials = ChannelCredentials.Insecure;
                FaucetServerHost   = Constant.ServerHosts.TestnetFaucet;
                break;
            }

            Channel channel = new Channel(Host, Port, ChannelCredentials);

            acClient = new AdmissionControlClient(channel);
        }