static TaskExecutor()
        {
            var settings = GdaxSettings.Parse(AppConsts.KEYS_PATH);

            ExchangeClientBase.IsSandbox = settings.IsSandbox;

            _api = new GdaxApi(settings.ToAuthContainer());
        }
        public OldMainForm()
        {
            InitializeComponent();

            var settings = GdaxSettings.Parse(AppConsts.KEYS_PATH);

            ExchangeClientBase.IsSandbox = settings.IsSandbox;

            _api = new GdaxApi(settings.ToAuthContainer());
        }
        public static GdaxSettings Parse(string relativeFilePath)
        {
            var lines = File.ReadAllLines(relativeFilePath);

            var set = new GdaxSettings
            {
                PassPhrase = lines[0],
                ApiKey     = lines[1],
                SecretKey  = lines[2],
                IsSandbox  = String.Compare(lines[3], "SANDBOX", true) == 0
            };

            return(set);
        }