Advertisement
Guest User

Untitled

a guest
Sep 26th, 2017
166
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C# 1.34 KB | None | 0 0
  1. NamespaceA
  2. ----------
  3.     public class Wrapper
  4.     {
  5.         private Connection _mysqlConnection;
  6.  
  7.         public Wrapper(ConnectionInformation connectionInformation)
  8.         {
  9.             _mysqlConnection = new Connection(connectionInformation);
  10.         }
  11.     }
  12.  
  13. NamespaceB
  14. ----------
  15.     public class Connection
  16.     {
  17.         private ConnectionInformation _connectionInformation;
  18.  
  19.         public Connection(ConnectionInformation connectionInformation)
  20.         {
  21.             _connectionInformation = connectionInformation;
  22.         }
  23.     }
  24.     public class ConnectionInformation
  25.     {
  26.         private String _mysqlHostname;
  27.         private String _mysqlUsername;
  28.         private String _mysqlPassword;
  29.         private String _mysqlDatabase;
  30.  
  31.         public String MySqlHostname
  32.         {
  33.             get { return _mysqlHostname; }
  34.             set { _mysqlHostname = value; }
  35.         }
  36.  
  37.         public String MySqlUsername
  38.         {
  39.             get { return _mysqlUsername; }
  40.             set { _mysqlUsername = value; }
  41.         }
  42.  
  43.         public String MySqlPassword
  44.         {
  45.             get { return _mysqlPassword; }
  46.             set { _mysqlPassword = value; }
  47.         }
  48.  
  49.         public String MySqlDatabase
  50.         {
  51.             get { return _mysqlDatabase; }
  52.             set { _mysqlDatabase = value; }
  53.         }
  54.     }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement