[asterisk-scf-commits] asterisk-scf/integration/slice.git branch "media" created.

Commits to the Asterisk SCF project code repositories asterisk-scf-commits at lists.digium.com
Thu Jun 9 08:44:43 CDT 2011


branch "media" has been created
        at  96d0ce2307bc2794b25b7b086ad7bcbf4c1b354a (commit)

- Log -----------------------------------------------------------------
commit 96d0ce2307bc2794b25b7b086ad7bcbf4c1b354a
Author: Joshua Colp <jcolp at digium.com>
Date:   Thu Jun 9 10:47:03 2011 -0300

    Add reworked media format, SDP descriptor interface, and two basic audio formats (ulaw and alaw).

diff --git a/AsteriskSCF/Media/Formats/AudioFormats.ice b/AsteriskSCF/Media/Formats/AudioFormats.ice
new file mode 100644
index 0000000..21f52ac
--- /dev/null
+++ b/AsteriskSCF/Media/Formats/AudioFormats.ice
@@ -0,0 +1,67 @@
+/*
+ * Asterisk SCF -- An open-source communications framework.
+ *
+ * Copyright (C) 2011, Digium, Inc.
+ *
+ * See http://www.asterisk.org for more information about
+ * the Asterisk SCF project. Please do not directly contact
+ * any of the maintainers of this project for assistance;
+ * the project provides a web site, mailing lists and IRC
+ * channels for your use.
+ *
+ * This program is free software, distributed under the terms of
+ * the GNU General Public License Version 2. See the LICENSE.txt file
+ * at the top of the source tree.
+ */
+
+#include <AsteriskSCF/Media/MediaIf.ice>
+
+module AsteriskSCF
+{
+
+module Media
+{
+
+module Formats
+{
+
+module Audio
+{
+
+["suppress"]
+module V1
+{
+   /**
+    * String representation of the version of this interface
+    */
+   const string Version = "V1";
+
+   /**
+    * ULAW Audio Format 
+    */
+   unsliceable class ULAW extends AsteriskSCF::Media::V1::AudioFormat
+   {
+       /**
+	* ULAW is so basic that no additional parameters are required
+	*/
+   };
+
+   /**
+    * ALAW Audio Format
+    */
+   unsliceable class ALAW extends AsteriskSCF::Media::V1::AudioFormat
+   {
+       /**
+        * ALAW is so basic that no additional parameters are required
+        */
+   };
+
+}; /*  end module V1 */
+
+}; /*  end module Audio */
+
+}; /*  end module Formats */
+
+}; /*  end module Media */
+
+}; /*  end module AsteriskSCF */
diff --git a/AsteriskSCF/Media/MediaIf.ice b/AsteriskSCF/Media/MediaIf.ice
index 9c79cd6..fb8524e 100644
--- a/AsteriskSCF/Media/MediaIf.ice
+++ b/AsteriskSCF/Media/MediaIf.ice
@@ -130,18 +130,24 @@ module V1
    interface StreamSource
    {
       /**
-       * Method which changes where the implementation should send media that originates from itself.
+       * Method which adds a sink that media will be written to.
        *
        * @param destination A proxy to a stream sink where media will be sent to.
        */
-      idempotent void setSink(StreamSink* destination);
+      void addSink(StreamSink* destination);
+      /**
+       * Method which removes a sink. Once removed media will no longer be written to it.
+       *
+       * @param destination A proxy to the stream sink to be removed.
+       */
+      void removeSink(StreamSink* destination);
 
       /**
-       * Method which retrieves the current stream sink for media.
+       * Method which retrieves the current stream sinks for media.
        *
-       * @return StreamSink* A proxy to the stream sink where media is being sent to.
+       * @return StreamSinkSeq A sequence of proxies where media is being written to.
        */
-      idempotent StreamSink* getSink();
+      idempotent StreamSinkSeq getSinks();
 
       /**
        * Method which returns the formats that frames from this source may come in.
@@ -215,209 +221,6 @@ module V1
    };
 
    /**
-    * Interface to a media operation session. This extends the normal Session interface and provides additional
-    * resource specific methods.
-    */
-   interface MediaOperationSession extends Session
-   {
-      /**
-       * Method which releases any resources associated with this media operation session.
-       */
-      void release();
-   };
-
-   /**
-    * A generic format discovery class that can be extended for adding parameters. The parameters are used to find
-    * a component capable of interpreting and providing a concrete class for a format.
-    */
-   unsliceable class FormatDiscovery extends AsteriskSCF::Core::Discovery::V1::ServiceLocatorParams
-   {
-   };
-
-   /**
-    * A format discovery class that allows finding a format based on name.
-    */
-   unsliceable class FormatDiscoveryName extends FormatDiscovery
-   {
-      /**
-       * A string identifier for the format.
-       */
-      string name;
-   };
-
-   /**
-    * A sequence of strings with each string containing a format specific parameter from SDP.
-    */
-   sequence<string> SDPFormatParameterSeq;
-
-   /**
-    * A format discovery class that allows finding a format based on information taken from SDP.
-    */
-   unsliceable class FormatDiscoverySDP extends FormatDiscovery
-   {
-      /**
-       * Numerical payload value given in the SDP.
-       */
-      int payload;
-
-      /**
-       * String type of the format (audio/video/etc)
-       */
-      string type;
-
-      /**
-       * String subtype of the format (in the case of audio something like PCMU)
-       */
-      string subtype;
-
-      /**
-       * Numerical sample rate of the format.
-       */
-      int samplerate;
-
-      /**
-       * A sequence of format specific parameters.
-       */
-      SDPFormatParameterSeq parameters;
-   };
-
-   /**
-    * A format discovery class that allows finding a format based on numerical value, used for IAX2.
-    */
-   unsliceable class FormatDiscoveryIAX2 extends FormatDiscovery
-   {
-      /**
-       * Numerical codec flag value.
-       */
-      int codec;
-   };
-
-   /**
-    * A format discovery class that allows finding an audio format based on a few parameters.
-    */
-   unsliceable class FormatDiscoveryGenericAudio extends FormatDiscovery
-   {
-      /**
-       * String name of the codec being used.
-       */
-      string name;
-
-      /**
-       * Numerical sample rate.
-       */
-      int samplerate;
-
-      /**
-       * Number of channels present.
-       */
-      int channels;
-   };
-
-   /**
-    * Interface to a service that interprets format discovery parameters and returns a concrete class
-    * representing them.
-    */
-   interface MediaFormatService
-   {
-      /**
-       * Method which returns a concrete format class given discovery parameters.
-       *
-       * @param format A concrete format discovery class containing parameters of the format.
-       *
-       * @return Format A concrete format class representing the format as described in the
-       *                format discovery class.
-       */
-      idempotent Format getFormat(FormatDiscovery format);
-   };
-
-   /**
-    * A generic media operation class that can be extended for adding parameters. The parameters are used to find
-    * a component capable of performing the described operation.
-    */
-   ["visitor"] local class MediaOperationVisitor
-   {
-   };
-
-   ["visitor:MediaOperationVisitor"] class MediaOperation
-   {
-   };
-
-   /**
-    * A sequence of media operations. These are ordered in the order in which they should be
-    * executed.
-    */
-   sequence<MediaOperation> MediaOperationSeq;
-
-   /**
-    * A transcoding media operation class that is used to transcode from one format to other.
-    */
-   class MediaOperationTranscode extends MediaOperation
-   {
-      /**
-       * A concrete format class describing the format that frames will be received in.
-       */
-      Format from;
-
-      /**
-       * A concrete format class describing the format that frames should be sent in.
-       */
-      Format to;
-   };
-
-   /**
-    * A media operation query result class, this gets returned by a media operation service when queried.
-    */
-   ["visitor"] local class MediaOperationQueryResultVisitor
-   {
-   };
-
-   ["visitor:MediaOperationQueryResultVisitor"] class MediaOperationQueryResult
-   {
-      /**
-       * A concrete class describing the operation that the media operation service can perform.
-       */
-      MediaOperation operation;
-
-      /**
-       * An arbitrary numerical score from 1 to 100 of how well the media operation service can perform
-       * the above operation. This value is used to determine the best route and best component to use
-       * for a sequence of media operations when faced with multiple choices.
-       */
-      int score;
-   };
-
-   /**
-    * A sequence of media operation query results, returned by the MediaOperationService interface.
-    */
-   sequence<MediaOperationQueryResult> MediaOperationQueryResultSeq;
-
-   /**
-    * Interface to a service which performs a media operation.
-    */
-   interface MediaOperationService
-   {
-      /**
-       * Method which determines how well supported operations are.
-       *
-       * @param operations A sequence of media operations that are to be performed.
-       *
-       * @return MediaOperationQueryResultSeq A sequence of supported operations with a score of how well
-       *                                      they can be performed.
-       */
-      idempotent MediaOperationQueryResultSeq isSupported(MediaOperationSeq operations);
-
-      /**
-       * Method which allocates a media operation session.
-       *
-       * @param operations A sequence of media operations that are to be performed.
-       *
-       * @return MediaOperationSession* A proxy to a media operation session that will perform the given media
-       *                                operations.
-       */
-      MediaOperationSession *allocate(MediaOperationSeq operations);
-   };
-
-   /**
     * A generic frame class that contains common details about frames. Additional classes should extend this to provide
     * additional details about the frame.
     */
diff --git a/AsteriskSCF/Media/SDP/MediaSDPIf.ice b/AsteriskSCF/Media/SDP/MediaSDPIf.ice
new file mode 100644
index 0000000..e1a3c57
--- /dev/null
+++ b/AsteriskSCF/Media/SDP/MediaSDPIf.ice
@@ -0,0 +1,123 @@
+/*
+ * Asterisk SCF -- An open-source communications framework.
+ *
+ * Copyright (C) 2011, Digium, Inc.
+ *
+ * See http://www.asterisk.org for more information about
+ * the Asterisk SCF project. Please do not directly contact
+ * any of the maintainers of this project for assistance;
+ * the project provides a web site, mailing lists and IRC
+ * channels for your use.
+ *
+ * This program is free software, distributed under the terms of
+ * the GNU General Public License Version 2. See the LICENSE.txt file
+ * at the top of the source tree.
+ */
+
+#include <AsteriskSCF/Core/Discovery/ServiceLocatorIf.ice>
+#include <AsteriskSCF/Media/MediaIf.ice>
+
+module AsteriskSCF
+{
+
+module Media
+{
+
+module SDP
+{
+
+["suppress"]
+module V1
+{
+   /**
+    * String representation of the version of this interface
+    */
+   const string Version = "V1";
+
+   /**
+    * Extended discovery class for SDP descriptor services.
+    */
+   unsliceable class SDPDescriptorServiceLocatorParams extends AsteriskSCF::Core::Discovery::V1::ServiceLocatorParams
+   {
+      /**
+       * Name of the media format.
+       */
+      string name;
+   };
+
+   /**
+    * A sequence of strings with each string containing a format specific parameter from SDP.
+    */
+   sequence<string> SDPFormatParameterSeq;
+
+   /**
+    * SDP Descriptor class. Contains description information for a media format.
+    */
+   class SDPDescriptor
+   {
+       /**
+	* Numerical payload value given in the SDP.
+	*/
+       int payload;
+
+       /**
+	* String type of the format (audio/video/etc)
+	*/
+       string type;
+
+       /**
+	* String subtype of the format (in the case of audio something like PCMU)
+	*/
+       string subtype;
+
+       /**
+	* Numerical sample rate of the format.
+	*/
+       int samplerate;
+
+       /**
+	* A sequence of format specific parameters.
+	*/
+       SDPFormatParameterSeq parameters;
+   };
+
+   /**
+    * Interface to the SDP descriptor service which translates between SDP and media formats.
+    */
+   interface SDPDescriptorService
+   {
+       /**
+	* Method which retrieves a media format concrete class given a specific name.
+	*
+	* @param name Name of the media format, may contain additional details according to the descriptor service.
+	*
+	* @return Format A concrete class containing media format details for the given format.
+	*/
+       idempotent AsteriskSCF::Media::V1::Format getNamedFormat(string name);
+
+       /**
+	* Method which retrieves a media format concrete class given an SDP descriptor concrete class.
+	*
+	* @param descriptor Populated SDP descriptor class.
+	*
+	* @return Format A concrete class containing media format details for the SDP.
+	*/
+       idempotent AsteriskSCF::Media::V1::Format getDescribedFormat(SDPDescriptor descriptor);
+
+       /**
+	* Method which retrieves an SDP descriptor concrete class given a media format concrete class.
+	*
+	* @param mediaformat Media format concrete class.
+	*
+	* @return SDPDescriptor A concrete class containing SDP describing the media format.
+	*/
+       idempotent SDPDescriptor getDescriptor(AsteriskSCF::Media::V1::Format mediaformat);
+   };
+
+}; /*  end module V1 */
+
+}; /*  end module SDP */
+
+}; /*  end module Media */
+
+}; /*  end module AsteriskSCF */

commit 00b74e2a2f13a5cb8f5308badf97cc3d37bd0365
Author: Joshua Colp <jcolp at digium.com>
Date:   Tue Jun 7 19:44:18 2011 -0300

    Add slice files for party identification.

diff --git a/AsteriskSCF/SessionCommunications/ISDNPartyIdentificationIf.ice b/AsteriskSCF/SessionCommunications/ISDNPartyIdentificationIf.ice
new file mode 100644
index 0000000..82fb0fe
--- /dev/null
+++ b/AsteriskSCF/SessionCommunications/ISDNPartyIdentificationIf.ice
@@ -0,0 +1,108 @@
+/*
+ * Asterisk SCF -- An open-source communications framework.
+ *
+ * Copyright (C) 2011, Digium, Inc.
+ *
+ * See http://www.asterisk.org for more information about
+ * the Asterisk SCF project. Please do not directly contact
+ * any of the maintainers of this project for assistance;
+ * the project provides a web site, mailing lists and IRC
+ * channels for your use.
+ *
+ * This program is free software, distributed under the terms of
+ * the GNU General Public License Version 2. See the LICENSE.txt file
+ * at the top of the source tree.
+ */
+
+#pragma once
+
+#include <AsteriskSCF/SessionCommunications/PartyIdentificationIf.ice>
+
+module AsteriskSCF
+{
+
+module SessionCommunications
+{
+
+module PartyIdentification
+{
+
+["suppress"]
+module V1
+{
+    /**
+     * ISDN derived class for name part of party identification
+     */
+    unsliceable class IsdnName extends Name
+    {
+	/**
+	 * Q.931 Presentation-indicator
+	 */
+	int presentation;
+
+	/**
+	 * Q.931 Screening-indicator
+	 */
+	int screening;
+    };
+
+    /**
+     * ISDN derived class for number part of party identification
+     */
+    unsliceable class IsdnNumber extends Number
+    {
+	/**
+	 * Q.931 Presentation-indicator
+	 */
+	int presentation;
+
+	/**
+	 * Q.931 Screening-indicator
+	 */
+	int screening;
+
+	/**
+	 * Q.931 Type-of-number
+	 */
+	int type_of_number;
+
+	/**
+	 * Q.931 Numbering-plan
+	 */
+	int numbering_plan;
+    };
+
+    /**
+     * ISDN derived class for combined identity
+     */
+    unsliceable class IsdnId extends Id
+    {
+	/**
+	 * Subaddress, if present
+	 */
+	Number subaddress;
+    };
+
+    /**
+     * ISDN derived class for calling party information
+     */
+    unsliceable class IsdnCaller extends Caller
+    {
+	/**
+	 * ANI identity information
+	 */
+	Id ani;
+
+	/**
+	 * ANI2 value
+	 */
+	int ani2;
+    };
+
+}; /* End of module V1 */
+
+}; /* End of module PartyIdentification */
+
+}; /* End of module SessionCommunications */
+
+}; /* End of module AsteriskSCF */
diff --git a/AsteriskSCF/SessionCommunications/PartyIdentificationIf.ice b/AsteriskSCF/SessionCommunications/PartyIdentificationIf.ice
new file mode 100644
index 0000000..7046ec2
--- /dev/null
+++ b/AsteriskSCF/SessionCommunications/PartyIdentificationIf.ice
@@ -0,0 +1,186 @@
+/*
+ * Asterisk SCF -- An open-source communications framework.
+ *
+ * Copyright (C) 2011, Digium, Inc.
+ *
+ * See http://www.asterisk.org for more information about
+ * the Asterisk SCF project. Please do not directly contact
+ * any of the maintainers of this project for assistance;
+ * the project provides a web site, mailing lists and IRC
+ * channels for your use.
+ *
+ * This program is free software, distributed under the terms of
+ * the GNU General Public License Version 2. See the LICENSE.txt file
+ * at the top of the source tree.
+ */
+
+#pragma once
+
+module AsteriskSCF
+{
+
+module SessionCommunications
+{
+
+module PartyIdentification
+{
+
+["suppress"]
+module V1
+{
+    /**
+     * String representation of the version of this interface
+     */
+    const string Version = "V1";
+
+    /**
+     * Base class for name part of party identification
+     */
+    unsliceable class Name
+    {
+	/**
+	 * String representation of the name
+	 */
+	string partyName;
+    };
+
+    /**
+     * Base class for number part of party identification
+     */
+    unsliceable class Number
+    {
+	/**
+	 * String representation of the number
+	 */
+	string partyNumber;
+    };
+
+    /**
+     * Base class for combined identity of name and number
+     */
+    unsliceable class Id
+    {
+	/**
+	 * Name of the party
+	 */
+	Name partyName;
+
+	/**
+	 * Number of the party
+	 */
+	Number partyNumber;
+    };
+
+    /**
+     * A sequence of identities
+     */
+    sequence<Id> IdSeq;
+
+    /**
+     * Base class for dialed party information
+     */
+    unsliceable class Dialed
+    {
+	/**
+	 * Number that was dialed
+	 */
+	Number partyNumber;
+    };
+
+    /**
+     * Base class for calling party information
+     */
+    unsliceable class Caller
+    {
+	/**
+	 * Identities of the caller
+	 */
+	IdSeq ids;
+    };
+
+    /**
+     * Derived class for connected line information, currently exactly like Caller
+     */
+    unsliceable class ConnectedLine extends Caller
+    {
+    };
+
+    /**
+     * Base class for redirecting information
+     */
+    unsliceable class Redirecting
+    {
+	/**
+	 * Party identification information for who the session is being redirected away from
+	 */
+	Id from;
+
+	/**
+	 * Party identification information for who the session is being redirected to
+	 */
+	Id to;
+
+	/**
+	 * Number of times the session has been redirected
+	 */
+	int count;
+    };
+
+    /**
+     * Interface for party identification retrieval and setting
+     */
+    interface IdentificationManager
+    {
+	/**
+	 * Method which retrieves caller party identification information
+	 *
+	 * @return Concrete class containing caller party information
+	 *
+	 * @see Caller
+	 */
+	idempotent Caller getCaller();
+
+	/**
+	 * Method which retrieves dialed party identification information
+	 *
+	 * @return Concrete class containing dialed party information
+	 *
+	 * @see Dialed
+	 */
+	idempotent Dialed getDialed();
+
+	/**
+	 * Method which retrieves redirecting party identification information
+	 *
+	 * @return Concrete class containing redirecting party information
+	 *
+	 * @see Redirecting
+	 */
+	idempotent Redirecting getRedirecting();
+
+	/**
+	 * Method which updates connected line party information
+	 *
+	 * @param party Connected line party information
+	 *
+	 * @see ConnectedLine
+	 */
+	void updateConnectedLine(ConnectedLine party);
+
+	/**
+	 * Method which updates redirecting party information
+	 *
+	 * @param party Redirecting party information
+	 *
+	 * @see Redirecting
+	 */
+	void updateRedirecting(Redirecting party);
+    };
+
+}; /* End of module V1 */
+
+}; /* End of module PartyIdentification */
+
+}; /* End of module SessionCommunications */
+
+}; /* End of module AsteriskSCF */

-----------------------------------------------------------------------


-- 
asterisk-scf/integration/slice.git



More information about the asterisk-scf-commits mailing list