EmailToPhoneImpl.java
01 package biz.xsoftware.examples.fullapi;
02 
03 /**
04  */
05 public class EmailToPhoneImpl implements EmailToPhone
06 {
07 
08     private PhoneFactory phoneFactory;
09 
10     /**
11      * Creates an instance of EmailToPhoneImpl.
12      @param factory
13      */
14     public EmailToPhoneImpl(PhoneFactory factory)
15     {
16         this.phoneFactory = factory;
17     }
18 
19     /**
20      @see biz.xsoftware.examples.fullapi.EmailToPhone#receivedHighPriorityEmail(java.lang.String, java.lang.String, java.lang.String)
21      */
22     public void receivedHighPriorityEmail(String extension, String emailTitle, String emailContents)
23     {
24         Phone phone = phoneFactory.createPhone();
25         phone.makeCall(extension);
26     }
27 
28     
29 }