Created
          March 27, 2013 16:36 
        
      - 
      
 - 
        
Save dtryon/5255794 to your computer and use it in GitHub Desktop.  
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
  | public class Order | |
| { | |
| private Customer customer; | |
| private ISendEmail sendEmail; | |
| public Order(Customer customer, ISendEmail sendEmal) | |
| { | |
| this.customer = customer; | |
| this.sendEmail = sendEmail; | |
| } | |
| // snip | |
| public void Place() | |
| { | |
| // place order | |
| sendEmail.ConfirmationTo(customer.EmailAddress); | |
| } | |
| } | 
  
    Sign up for free
    to join this conversation on GitHub.
    Already have an account?
    Sign in to comment