Go to the documentation of this file.00001 
00002 
00003 
00004 
00005 package audio;
00006 
00007 import java.io.IOException;
00008 
00009 
00010 
00011 
00012 
00013 
00014 public interface AudioInterface
00015 {
00016 
00017 
00018 
00019 
00020     public interface Packetizer 
00021     {
00022         public abstract void send () throws IOException;
00023     }
00024 
00025 
00026 
00027 
00028     public abstract int getSampleSize ();
00029     
00030 
00031 
00032 
00033 
00034 
00035     public abstract long readWithTimestamp( byte[] buff ) throws IOException;
00036     
00037 
00038 
00039 
00040     public abstract void stopRecording ();
00041     
00042 
00043 
00044 
00045     public abstract long startRecording ();
00046     
00047 
00048 
00049 
00050     public abstract void startPlay ();
00051     
00052 
00053 
00054 
00055     public abstract void stopPlay ();
00056 
00057 
00058 
00059 
00060     public abstract void startRinging ();
00061     
00062 
00063 
00064 
00065     public abstract void stopRinging();
00066     
00067 
00068 
00069 
00070 
00071     public abstract void writeBuffered( byte[] buff, long timestamp ) throws IOException;
00072     
00073 
00074 
00075 
00076     public abstract void writeDirectly( byte[] buff ) throws IOException;
00077     
00078 
00079 
00080 
00081     public abstract int getVoicePduSubclass();
00082     
00083 
00084 
00085 
00086     public abstract void setAudioSender( AudioInterface.Packetizer as );
00087     
00088 
00089 
00090 
00091     public abstract void cleanUp ();
00092     
00093 
00094 
00095 
00096     public abstract AudioInterface getByFormat( Integer format );
00097 }