From e5e1153c763e4985855c6c18c125ad381903fed9 Mon Sep 17 00:00:00 2001 From: Aaron Yarborough Date: Wed, 25 Jan 2017 17:44:06 +0000 Subject: [PATCH] Started adding GetBalance/GetAccounts items --- BankingBot/BankingBot.csproj | 1 + BankingBot/Client.cs | 17 ++++++++++++++++- BankingBot/Contracts/IClient.cs | 10 +++++++++- BankingBot/Models/Account.cs | 17 +++++++++++++++++ 4 files changed, 43 insertions(+), 2 deletions(-) create mode 100644 BankingBot/Models/Account.cs diff --git a/BankingBot/BankingBot.csproj b/BankingBot/BankingBot.csproj index c77255c..e7ee3a6 100644 --- a/BankingBot/BankingBot.csproj +++ b/BankingBot/BankingBot.csproj @@ -63,6 +63,7 @@ + diff --git a/BankingBot/Client.cs b/BankingBot/Client.cs index 315d763..22a3452 100644 --- a/BankingBot/Client.cs +++ b/BankingBot/Client.cs @@ -5,6 +5,7 @@ using System.Text; using System.Threading.Tasks; using BankingBot.Contracts; using BankingBot.LoginManagers; +using BankingBot.Models; using OpenQA.Selenium; namespace BankingBot @@ -25,11 +26,25 @@ namespace BankingBot _loginManager = new LoginManager(BrowserBot); } + #region Actions + public void Login(ILoginCredentials credentials) { - this.LoginCredentials = credentials; + LoginCredentials = credentials; _loginManager.Login(credentials); } + + public decimal GetBalance() + { + throw new NotImplementedException(); + } + + public IEnumerable GetAccounts() + { + throw new NotImplementedException(); + } + + #endregion } } diff --git a/BankingBot/Contracts/IClient.cs b/BankingBot/Contracts/IClient.cs index 6f1156e..83a8d90 100644 --- a/BankingBot/Contracts/IClient.cs +++ b/BankingBot/Contracts/IClient.cs @@ -1,7 +1,15 @@ -namespace BankingBot.Contracts +using System.Collections; +using System.Collections.Generic; +using BankingBot.Models; + +namespace BankingBot.Contracts { public interface IClient { void Login(ILoginCredentials credentials); + + decimal GetBalance(); + + IEnumerable GetAccounts(); } } \ No newline at end of file diff --git a/BankingBot/Models/Account.cs b/BankingBot/Models/Account.cs new file mode 100644 index 0000000..ecb7186 --- /dev/null +++ b/BankingBot/Models/Account.cs @@ -0,0 +1,17 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace BankingBot.Models +{ + public class Account + { + public string SortCode { get; set; } + + public string AccountNumber { get; set; } + + public string Name { get; set; } + } +}