Revision: 16269
Author: oleg.kulikoff
Date: Sat Jan 8 09:33:06 2011
Log: Changed DTMF detector SPI
http://code.google.com/p/mobicents/source/detail?r=16269
Deleted:
/trunk/servers/media/core/server-spi/src/main/java/org/mobicents/media/server/spi/dtmf/DtmfDetectorEvent.java
Modified:
/trunk/servers/media/core/server-spi/src/main/java/org/mobicents/media/server/spi/dtmf/DtmfDetector.java
/trunk/servers/media/core/server-spi/src/main/java/org/mobicents/media/server/spi/dtmf/DtmfDetectorListener.java
/trunk/servers/media/core/server-spi/src/main/java/org/mobicents/media/server/spi/dtmf/DtmfEvent.java
=======================================
---
/trunk/servers/media/core/server-spi/src/main/java/org/mobicents/media/server/spi/dtmf/DtmfDetectorEvent.java
Sat Jan 8 01:33:59 2011
+++ /dev/null
@@ -1,46 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright XXXX, Red Hat Middleware LLC, and individual contributors as
indicated
- * by the @authors tag. All rights reserved.
- * See the copyright.txt in the distribution for a full listing
- * of individual contributors.
- * This copyrighted material is made available to anyone wishing to use,
- * modify, copy, or redistribute it subject to the terms and conditions
- * of the GNU General Public License, v. 2.0.
- * This program is distributed in the hope that it will be useful, but
WITHOUT A
- * WARRANTY; without even the implied warranty of MERCHANTABILITY or
FITNESS FOR A
- * PARTICULAR PURPOSE. See the GNU General Public License for more details.
- * You should have received a copy of the GNU General Public License,
- * v. 2.0 along with this distribution; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
- * MA 02110-1301, USA.
- */
-
-package org.mobicents.media.server.spi.dtmf;
-
-import org.mobicents.media.server.spi.listener.Event;
-
-/**
- *
- * @author kulikov
- */
-public interface DtmfDetectorEvent extends Event<DtmfDetector> {
- public final static int DTMF_0 = 0;
- public final static int DTMF_1 = 1;
- public final static int DTMF_2 = 2;
- public final static int DTMF_3 = 3;
- public final static int DTMF_4 = 4;
- public final static int DTMF_5 = 5;
- public final static int DTMF_6 = 6;
- public final static int DTMF_7 = 7;
- public final static int DTMF_8 = 8;
- public final static int DTMF_9 = 9;
- public final static int DTMF_A = 10;
- public final static int DTMF_B = 11;
- public final static int DTMF_C = 12;
- public final static int DTMF_D = 13;
- public final static int DTMF_HASH = 14;
- public final static int DTMF_STAR = 15;
-
- public String getTone();
-}
=======================================
---
/trunk/servers/media/core/server-spi/src/main/java/org/mobicents/media/server/spi/dtmf/DtmfDetector.java
Sat Jan 8 01:33:59 2011
+++
/trunk/servers/media/core/server-spi/src/main/java/org/mobicents/media/server/spi/dtmf/DtmfDetector.java
Sat Jan 8 09:33:06 2011
@@ -18,6 +18,7 @@
package org.mobicents.media.server.spi.dtmf;
import org.mobicents.media.MediaSink;
+import org.mobicents.media.server.spi.listener.TooManyListenersException;
/**
*
@@ -78,4 +79,6 @@
*/
public void flushBuffer();
-}
+ public void addListener(DtmfDetectorListener listener) throws
TooManyListenersException;
+ public void removeListener(DtmfDetectorListener listener);
+}
=======================================
---
/trunk/servers/media/core/server-spi/src/main/java/org/mobicents/media/server/spi/dtmf/DtmfDetectorListener.java
Sat Jan 8 01:33:59 2011
+++
/trunk/servers/media/core/server-spi/src/main/java/org/mobicents/media/server/spi/dtmf/DtmfDetectorListener.java
Sat Jan 8 09:33:06 2011
@@ -24,6 +24,6 @@
*
* @author kulikov
*/
-public interface DtmfDetectorListener extends Listener<DtmfDetectorEvent> {
+public interface DtmfDetectorListener extends Listener<DtmfEvent> {
}
=======================================
---
/trunk/servers/media/core/server-spi/src/main/java/org/mobicents/media/server/spi/dtmf/DtmfEvent.java
Thu Dec 30 01:33:29 2010
+++
/trunk/servers/media/core/server-spi/src/main/java/org/mobicents/media/server/spi/dtmf/DtmfEvent.java
Sat Jan 8 09:33:06 2011
@@ -17,13 +17,13 @@
*/
package org.mobicents.media.server.spi.dtmf;
-import org.mobicents.media.server.spi.events.NotifyEvent;
+import org.mobicents.media.server.spi.listener.Event;
/**
*
* @author kulikov
*/
-public interface DtmfEvent extends NotifyEvent {
+public interface DtmfEvent extends Event<DtmfDetector> {
public final static int DTMF_0 = 0;
public final static int DTMF_1 = 1;
@@ -42,4 +42,6 @@
public final static int DTMF_HASH = 14;
public final static int DTMF_STAR = 15;
-}
+ public int getVolume();
+ public String getTone();
+}