Guest User

Untitled

a guest
Jan 28th, 2018
105
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.19 KB | None | 0 0
  1. Public Interface IAccount
  2. Property Username As String
  3. Property Password As String
  4. Property LoginCookie As Net.CookieContainer
  5. Property CreationDate As Date
  6. Property LastLoginDate As Date
  7. Property EmailAccount As IEmailAccount
  8. Property Proxy As HelperLib.Proxy
  9. Sub Login()
  10. Sub Create()
  11. End Interface
  12.  
  13. Public Interface IEmailAccount
  14. Property Username As String
  15. Property Password As String
  16. Property LoginCookie As Net.CookieContainer
  17. Property CreationDate As Date
  18. Property LastLoginDate As Date
  19. Property EmailAccount As IEmailAccount
  20. Property Proxy As HelperLib.Proxy
  21. Property Emails As List(Of Email)
  22.  
  23. Sub Login()
  24. Sub Create()
  25. Sub SendMail(recipient As String, title As String, body As String)
  26. Function GetEmails() As List(Of Email)
  27. End Interface
  28.  
  29. Public MustInherit Class EmailAccountBase
  30. Implements IEmailAccount
  31. Implements IAccount
  32.  
  33. Public Property Emails As List(Of Email) Implements IEmailAccount.Emails
  34. Public Property Username As String Implements IEmailAccount.Username, IAccount.Username
  35. Public Property Password As String Implements IEmailAccount.Password, IAccount.Password
  36. Public Property LoginCookie As CookieContainer Implements IEmailAccount.LoginCookie, IAccount.LoginCookie
  37. Public Property CreationDate As Date Implements IEmailAccount.CreationDate, IAccount.CreationDate
  38. Public Property LastLoginDate As Date Implements IEmailAccount.LastLoginDate, IAccount.LastLoginDate
  39. Public Property EmailAccount As IEmailAccount Implements IEmailAccount.EmailAccount, IAccount.EmailAccount
  40. Public Property Proxy As Proxy Implements IEmailAccount.Proxy, IAccount.Proxy
  41.  
  42. Public MustOverride Sub Login() Implements IEmailAccount.Login, IAccount.Login
  43. Public MustOverride Sub Create() Implements IEmailAccount.Create, IAccount.Create
  44. Public MustOverride Sub SendMail(recipient As String, title As String, body As String) Implements IEmailAccount.SendMail
  45. Public MustOverride Function GetEmails() As List(Of Email) Implements IEmailAccount.GetEmails
  46.  
  47. Public Sub New(username As String, password As String)
  48. Me.Username = username
  49. Me.Password = password
  50. End Sub
  51.  
  52. End Class
Add Comment
Please, Sign In to add comment