Exemple #1
0
        public static StratumConnection Parse(AlgoNiceHashEnum algo, string stratumConnectionString)
        {
            var values = stratumConnectionString.Split(',');

            var connection = new StratumConnection {
                Algo = algo, Host = values[0], Port = int.Parse(values[1]), UserOrWallet = values[2], Worker = values[3], Password = values[4]
            };

            return(connection);
        }
Exemple #2
0
 public static double SetLimit(this Model.Order order, AlgoNiceHashEnum currentAlgo, double newLimit)
 {
     return(APIWrapper.OrderSetLimit(order.Server == ServerEnum.Europe ? 0 : 1, (int)currentAlgo, order.Id, newLimit));
 }
Exemple #3
0
 public static double SetPriceDecrease(this Model.Order order, AlgoNiceHashEnum currentAlgo)
 {
     return(APIWrapper.OrderSetPriceDecrease(order.Server == ServerEnum.Europe ? 0 : 1, (int)currentAlgo, order.Id));
 }
Exemple #4
0
 public static int OrderCreate(this ServerEnum server, AlgoNiceHashEnum currentAlgo, double amount, double price, double limit, Pool pool)
 {
     return(APIWrapper.OrderCreate(server == ServerEnum.Europe ? 0 : 1, (int)currentAlgo, amount, price, limit, pool));
 }
Exemple #5
0
 public static List <Order> GetMyOrders(this ServerEnum server, AlgoNiceHashEnum currentAlgo)
 {
     return(APIWrapper.GetMyOrders(server == ServerEnum.Europe ? 0 : 1, (byte)currentAlgo));
 }