public void ConvertGbpToUsd(Currencies convertFrom, Currencies convertTo)
        {
            ConvertToType   = convertTo.ToString();
            ConvertFromType = convertFrom.ToString();

            _request = Factory.PerformApiRequest(Endpoints.GetConversionAmount);
            _request.PerformApiRequest(Endpoints.GetConversionAmount);
        }
        public void GetDateOfLastUpdate()
        {
            // Get the last date the converter was updated and store it as a static object
            _request = Factory.PerformApiRequest(Endpoints.GetLastUpdateDate);
            _request.PerformApiRequest(Endpoints.GetLastUpdateDate);

            // Get all the currency rates and store them as a static object
            _request = Factory.PerformApiRequest(Endpoints.GetCurrencyRates);
            _request.PerformApiRequest(Endpoints.GetCurrencyRates);
        }
        public virtual IPerformApiRequest PerformApiRequest(Endpoints endpoints)
        {
            IPerformApiRequest request = null;

            switch (endpoints)
            {
            case Endpoints.GetConversionAmount:
                request = new GetConversionRate();
                break;

            case Endpoints.GetCurrencyRates:
                request = new GetCurrencyRates();
                break;

            case Endpoints.GetLastUpdateDate:
                request = new GetDateOfLastUpdate();
                break;
            }
            return(request);
        }