summaryrefslogtreecommitdiff
path: root/PluginControlInterface
diff options
context:
space:
mode:
authorchristian mueller <christian.ei.mueller@bmw.de>2012-03-01 19:12:55 +0100
committerchristian mueller <christian.ei.mueller@bmw.de>2012-03-01 19:12:55 +0100
commitdfcafbec34e0e454d9995551998af5d40a27c7ad (patch)
treed93d70fea7feb7004f6a2ce9bfce9b83d3469e42 /PluginControlInterface
parentffccf1e2003cea4230413ccfdfd4cd6515484e4f (diff)
downloadaudiomanager-dfcafbec34e0e454d9995551998af5d40a27c7ad.tar.gz
* fix [GAM-28] problems in routingsender.cpp
* [GAM-27] major refactoring: bringing everything to standardized names * Enhancement of CAmSerializer.h * improvement of documentation * adoption & regeneration of inerfaces
Diffstat (limited to 'PluginControlInterface')
-rw-r--r--PluginControlInterface/CMakeLists.txt8
-rw-r--r--PluginControlInterface/include/CAmControlSenderBase.h (renamed from PluginControlInterface/include/ControlSender.h)14
-rw-r--r--PluginControlInterface/src/CAmControlSenderBase.cpp (renamed from PluginControlInterface/src/ControlSender.cpp)112
3 files changed, 67 insertions, 67 deletions
diff --git a/PluginControlInterface/CMakeLists.txt b/PluginControlInterface/CMakeLists.txt
index 5946df7..7701364 100644
--- a/PluginControlInterface/CMakeLists.txt
+++ b/PluginControlInterface/CMakeLists.txt
@@ -4,9 +4,9 @@ PROJECT(PluginControlInterface)
set(LIBRARY_OUTPUT_PATH ${PLUGINS_OUTPUT_PATH}/control)
set(DOC_OUTPUT_PATH ${DOC_OUTPUT_PATH}/ControlPlugin)
-set(INCLUDES_FOLDER "include")
+set(include_FOLDER "include")
-FILE(READ "${AUDIO_INCLUDES_FOLDER}/control/ControlSendInterface.h" VERSION_BUFFER LIMIT 6000)
+FILE(READ "${AUDIO_include_FOLDER}/control/IAmControlSend.h" VERSION_BUFFER LIMIT 6000)
STRING(REGEX MATCH "ControlSendVersion*.[^0-9]*[0-9].[0-9]*[0-9]" LIB_INTERFACE_VERSION_STRING ${VERSION_BUFFER})
STRING(REGEX REPLACE "ControlSendVersion*.." "" LIB_INTERFACE_VERSION ${LIB_INTERFACE_VERSION_STRING})
MESSAGE(STATUS "Building against control interface version ${LIB_INTERFACE_VERSION}")
@@ -15,8 +15,8 @@ INCLUDE_DIRECTORIES(
${CMAKE_SOURCE_DIR}
${STD_INCLUDE_DIRS}
${CMAKE_CURRENT_BINARY_DIR}
- ${AUDIO_INCLUDES_FOLDER}
- ${INCLUDES_FOLDER}
+ ${AUDIO_include_FOLDER}
+ ${include_FOLDER}
)
# all source files go here
diff --git a/PluginControlInterface/include/ControlSender.h b/PluginControlInterface/include/CAmControlSenderBase.h
index e96f445..3d06356 100644
--- a/PluginControlInterface/include/ControlSender.h
+++ b/PluginControlInterface/include/CAmControlSenderBase.h
@@ -3,7 +3,7 @@
*
* GeniviAudioMananger DbusPlugin
*
- * \file ControlSender.h
+ * \file CAmControlSender.h
*
* \date 20-Oct-2011 3:42:04 PM
* \author Christian Mueller (christian.ei.mueller@bmw.de)
@@ -26,17 +26,17 @@
#ifndef CONTROLSENDER_H_
#define CONTROLSENDER_H_
-#include <control/ControlSendInterface.h>
+#include "control/IAmControlSend.h"
#include <list>
using namespace am;
-class ControlSenderPlugin: public ControlSendInterface
+class CAmControlSenderBase: public IAmControlSend
{
public:
- ControlSenderPlugin();
- virtual ~ControlSenderPlugin();
- am_Error_e startupController(ControlReceiveInterface* controlreceiveinterface);
+ CAmControlSenderBase();
+ virtual ~CAmControlSenderBase();
+ am_Error_e startupController(IAmControlReceive* controlreceiveinterface);
void setControllerReady();
void setControllerRundown();
am_Error_e hookUserConnectionRequest(const am_sourceID_t sourceID, const am_sinkID_t sinkID, am_mainConnectionID_t& mainConnectionID);
@@ -85,7 +85,7 @@ public:
void confirmRoutingRundown();
private:
- ControlReceiveInterface * mControlReceiveInterface;
+ IAmControlReceive * mControlReceiveInterface;
struct handleStatus
{
bool status;
diff --git a/PluginControlInterface/src/ControlSender.cpp b/PluginControlInterface/src/CAmControlSenderBase.cpp
index 567f8c6..9538ca3 100644
--- a/PluginControlInterface/src/ControlSender.cpp
+++ b/PluginControlInterface/src/CAmControlSenderBase.cpp
@@ -3,7 +3,7 @@
*
* GeniviAudioMananger DbusPlugin
*
- * \file ControlSender.cpp
+ * \file CAmControlSender.cpp
*
* \date 20-Oct-2011 3:42:04 PM
* \author Christian Mueller (christian.ei.mueller@bmw.de)
@@ -23,25 +23,25 @@
* THIS CODE HAS BEEN GENERATED BY ENTERPRISE ARCHITECT GENIVI MODEL. PLEASE CHANGE ONLY IN ENTERPRISE ARCHITECT AND GENERATE AGAIN
*/
-#include "ControlSender.h"
-#include "control/ControlReceiveInterface.h"
+#include "CAmControlSenderBase.h"
#include <cassert>
#include <algorithm>
-#include "DLTWrapper.h"
+#include "shared/CAmDltWrapper.h"
+#include "control/IAmControlReceive.h"
using namespace am;
-extern "C" ControlSendInterface* PluginControlInterfaceFactory()
+extern "C" IAmControlSend* PluginControlInterfaceFactory()
{
- return (new ControlSenderPlugin());
+ return (new CAmControlSenderBase());
}
-extern "C" void destroyControlPluginInterface(ControlSendInterface* controlSendInterface)
+extern "C" void destroyControlPluginInterface(IAmControlSend* controlSendInterface)
{
delete controlSendInterface;
}
-ControlSenderPlugin::ControlSenderPlugin() :
+CAmControlSenderBase::CAmControlSenderBase() :
mControlReceiveInterface(NULL), //
mListOpenConnections(), //
mListOpenDisconnections(), //
@@ -49,11 +49,11 @@ ControlSenderPlugin::ControlSenderPlugin() :
{
}
-ControlSenderPlugin::~ControlSenderPlugin()
+CAmControlSenderBase::~CAmControlSenderBase()
{
}
-am_Error_e ControlSenderPlugin::startupController(ControlReceiveInterface *controlreceiveinterface)
+am_Error_e CAmControlSenderBase::startupController(IAmControlReceive *controlreceiveinterface)
{
assert(controlreceiveinterface);
mControlReceiveInterface = controlreceiveinterface;
@@ -62,14 +62,14 @@ am_Error_e ControlSenderPlugin::startupController(ControlReceiveInterface *contr
return E_NOT_USED;
}
-void ControlSenderPlugin::setControllerReady()
+void CAmControlSenderBase::setControllerReady()
{
//here is a good place to insert Source and SinkClasses into the database...
mControlReceiveInterface->setRoutingReady();
mControlReceiveInterface->setCommandReady();
}
-am_Error_e ControlSenderPlugin::hookUserConnectionRequest(const am_sourceID_t sourceID, const am_sinkID_t sinkID, am_mainConnectionID_t & mainConnectionID)
+am_Error_e CAmControlSenderBase::hookUserConnectionRequest(const am_sourceID_t sourceID, const am_sinkID_t sinkID, am_mainConnectionID_t & mainConnectionID)
{
std::vector<am_Route_s> listRoutes;
std::vector<am_connectionID_t> listConnectionIDs;
@@ -103,7 +103,7 @@ am_Error_e ControlSenderPlugin::hookUserConnectionRequest(const am_sourceID_t so
return E_OK;
}
-am_Error_e ControlSenderPlugin::hookUserDisconnectionRequest(const am_mainConnectionID_t connectionID)
+am_Error_e CAmControlSenderBase::hookUserDisconnectionRequest(const am_mainConnectionID_t connectionID)
{
//first check if there is a connectionID like that
am_MainConnection_s mainConnection;
@@ -129,7 +129,7 @@ am_Error_e ControlSenderPlugin::hookUserDisconnectionRequest(const am_mainConnec
return E_OK;
}
-am_Error_e ControlSenderPlugin::hookUserSetMainSinkSoundProperty(const am_sinkID_t sinkID, const am_MainSoundProperty_s & soundProperty)
+am_Error_e CAmControlSenderBase::hookUserSetMainSinkSoundProperty(const am_sinkID_t sinkID, const am_MainSoundProperty_s & soundProperty)
{
if (sinkID == 0)
return E_NON_EXISTENT;
@@ -150,20 +150,20 @@ am_Error_e ControlSenderPlugin::hookUserSetMainSinkSoundProperty(const am_sinkID
return E_OK;
}
-am_Error_e ControlSenderPlugin::hookUserSetMainSourceSoundProperty(const am_sourceID_t sourceID, const am_MainSoundProperty_s & soundProperty)
+am_Error_e CAmControlSenderBase::hookUserSetMainSourceSoundProperty(const am_sourceID_t sourceID, const am_MainSoundProperty_s & soundProperty)
{
(void) sourceID;
(void) soundProperty;
return E_NOT_USED;
}
-am_Error_e ControlSenderPlugin::hookUserSetSystemProperty(const am_SystemProperty_s & property)
+am_Error_e CAmControlSenderBase::hookUserSetSystemProperty(const am_SystemProperty_s & property)
{
(void) property;
return E_NOT_USED;
}
-am_Error_e ControlSenderPlugin::hookUserVolumeChange(const am_sinkID_t SinkID, const am_mainVolume_t newVolume)
+am_Error_e CAmControlSenderBase::hookUserVolumeChange(const am_sinkID_t SinkID, const am_mainVolume_t newVolume)
{
assert(SinkID!=0);
mainVolumeSet set;
@@ -178,7 +178,7 @@ am_Error_e ControlSenderPlugin::hookUserVolumeChange(const am_sinkID_t SinkID, c
return E_OK;
}
-am_Error_e ControlSenderPlugin::hookUserVolumeStep(const am_sinkID_t SinkID, const int16_t increment)
+am_Error_e CAmControlSenderBase::hookUserVolumeStep(const am_sinkID_t SinkID, const int16_t increment)
{
assert(SinkID!=0);
mainVolumeSet set;
@@ -195,133 +195,133 @@ am_Error_e ControlSenderPlugin::hookUserVolumeStep(const am_sinkID_t SinkID, con
return E_OK;
}
-am_Error_e ControlSenderPlugin::hookUserSetSinkMuteState(const am_sinkID_t sinkID, const am_MuteState_e muteState)
+am_Error_e CAmControlSenderBase::hookUserSetSinkMuteState(const am_sinkID_t sinkID, const am_MuteState_e muteState)
{
(void) sinkID;
(void) muteState;
return E_NOT_USED;
}
-am_Error_e ControlSenderPlugin::hookSystemRegisterDomain(const am_Domain_s & domainData, am_domainID_t & domainID)
+am_Error_e CAmControlSenderBase::hookSystemRegisterDomain(const am_Domain_s & domainData, am_domainID_t & domainID)
{
//this application does not do anything with it -> but some product might want to take influence here
return mControlReceiveInterface->enterDomainDB(domainData, domainID);
}
-am_Error_e ControlSenderPlugin::hookSystemDeregisterDomain(const am_domainID_t domainID)
+am_Error_e CAmControlSenderBase::hookSystemDeregisterDomain(const am_domainID_t domainID)
{
//this application does not do anything with it -> but some product might want to take influence here
return mControlReceiveInterface->removeDomainDB(domainID);
}
-void ControlSenderPlugin::hookSystemDomainRegistrationComplete(const am_domainID_t domainID)
+void CAmControlSenderBase::hookSystemDomainRegistrationComplete(const am_domainID_t domainID)
{
(void) domainID;
}
-am_Error_e ControlSenderPlugin::hookSystemRegisterSink(const am_Sink_s & sinkData, am_sinkID_t & sinkID)
+am_Error_e CAmControlSenderBase::hookSystemRegisterSink(const am_Sink_s & sinkData, am_sinkID_t & sinkID)
{
//this application does not do anything with it -> but some product might want to take influence here
return mControlReceiveInterface->enterSinkDB(sinkData, sinkID);
}
-am_Error_e ControlSenderPlugin::hookSystemDeregisterSink(const am_sinkID_t sinkID)
+am_Error_e CAmControlSenderBase::hookSystemDeregisterSink(const am_sinkID_t sinkID)
{
//this application does not do anything with it -> but some product might want to take influence here
return mControlReceiveInterface->removeSinkDB(sinkID);
}
-am_Error_e ControlSenderPlugin::hookSystemRegisterSource(const am_Source_s & sourceData, am_sourceID_t & sourceID)
+am_Error_e CAmControlSenderBase::hookSystemRegisterSource(const am_Source_s & sourceData, am_sourceID_t & sourceID)
{
//this application does not do anything with it -> but some product might want to take influence here
return mControlReceiveInterface->enterSourceDB(sourceData, sourceID);
}
-am_Error_e ControlSenderPlugin::hookSystemDeregisterSource(const am_sourceID_t sourceID)
+am_Error_e CAmControlSenderBase::hookSystemDeregisterSource(const am_sourceID_t sourceID)
{
//this application does not do anything with it -> but some product might want to take influence here
return mControlReceiveInterface->removeSourceDB(sourceID);
}
-am_Error_e ControlSenderPlugin::hookSystemRegisterGateway(const am_Gateway_s & gatewayData, am_gatewayID_t & gatewayID)
+am_Error_e CAmControlSenderBase::hookSystemRegisterGateway(const am_Gateway_s & gatewayData, am_gatewayID_t & gatewayID)
{
//this application does not do anything with it -> but some product might want to take influence here
return mControlReceiveInterface->enterGatewayDB(gatewayData, gatewayID);
}
-am_Error_e ControlSenderPlugin::hookSystemDeregisterGateway(const am_gatewayID_t gatewayID)
+am_Error_e CAmControlSenderBase::hookSystemDeregisterGateway(const am_gatewayID_t gatewayID)
{
//this application does not do anything with it -> but some product might want to take influence here
return mControlReceiveInterface->removeGatewayDB(gatewayID);
}
-am_Error_e ControlSenderPlugin::hookSystemRegisterCrossfader(const am_Crossfader_s & crossfaderData, am_crossfaderID_t & crossfaderID)
+am_Error_e CAmControlSenderBase::hookSystemRegisterCrossfader(const am_Crossfader_s & crossfaderData, am_crossfaderID_t & crossfaderID)
{
//this application does not do anything with it -> but some product might want to take influence here
return mControlReceiveInterface->enterCrossfaderDB(crossfaderData, crossfaderID);
}
-am_Error_e ControlSenderPlugin::hookSystemDeregisterCrossfader(const am_crossfaderID_t crossfaderID)
+am_Error_e CAmControlSenderBase::hookSystemDeregisterCrossfader(const am_crossfaderID_t crossfaderID)
{
//this application does not do anything with it -> but some product might want to take influence here
return mControlReceiveInterface->removeCrossfaderDB(crossfaderID);
}
-void ControlSenderPlugin::hookSystemSinkVolumeTick(const am_Handle_s handle, const am_sinkID_t sinkID, const am_volume_t volume)
+void CAmControlSenderBase::hookSystemSinkVolumeTick(const am_Handle_s handle, const am_sinkID_t sinkID, const am_volume_t volume)
{
(void) handle;
(void) sinkID;
(void) volume;
}
-void ControlSenderPlugin::hookSystemSourceVolumeTick(const am_Handle_s handle, const am_sourceID_t sourceID, const am_volume_t volume)
+void CAmControlSenderBase::hookSystemSourceVolumeTick(const am_Handle_s handle, const am_sourceID_t sourceID, const am_volume_t volume)
{
(void) handle;
(void) sourceID;
(void) volume;
}
-void ControlSenderPlugin::hookSystemInterruptStateChange(const am_sourceID_t sourceID, const am_InterruptState_e interruptState)
+void CAmControlSenderBase::hookSystemInterruptStateChange(const am_sourceID_t sourceID, const am_InterruptState_e interruptState)
{
(void) sourceID;
(void) interruptState;
}
-void ControlSenderPlugin::hookSystemSinkAvailablityStateChange(const am_sinkID_t sinkID, const am_Availability_s & availability)
+void CAmControlSenderBase::hookSystemSinkAvailablityStateChange(const am_sinkID_t sinkID, const am_Availability_s & availability)
{
(void) sinkID;
(void) availability;
}
-void ControlSenderPlugin::hookSystemSourceAvailablityStateChange(const am_sourceID_t sourceID, const am_Availability_s & availability)
+void CAmControlSenderBase::hookSystemSourceAvailablityStateChange(const am_sourceID_t sourceID, const am_Availability_s & availability)
{
(void) sourceID;
(void) availability;
}
-void ControlSenderPlugin::hookSystemDomainStateChange(const am_domainID_t domainID, const am_DomainState_e state)
+void CAmControlSenderBase::hookSystemDomainStateChange(const am_domainID_t domainID, const am_DomainState_e state)
{
(void) domainID;
(void) state;
}
-void ControlSenderPlugin::hookSystemReceiveEarlyData(const std::vector<am_EarlyData_s> & data)
+void CAmControlSenderBase::hookSystemReceiveEarlyData(const std::vector<am_EarlyData_s> & data)
{
(void) data;
}
-void ControlSenderPlugin::hookSystemSpeedChange(const am_speed_t speed)
+void CAmControlSenderBase::hookSystemSpeedChange(const am_speed_t speed)
{
(void) speed;
}
-void ControlSenderPlugin::hookSystemTimingInformationChanged(const am_mainConnectionID_t mainConnectionID, const am_timeSync_t time)
+void CAmControlSenderBase::hookSystemTimingInformationChanged(const am_mainConnectionID_t mainConnectionID, const am_timeSync_t time)
{
(void) mainConnectionID;
(void) time;
}
-void ControlSenderPlugin::cbAckConnect(const am_Handle_s handle, const am_Error_e errorID)
+void CAmControlSenderBase::cbAckConnect(const am_Handle_s handle, const am_Error_e errorID)
{
(void) errorID;
//\todo:error checking
@@ -345,7 +345,7 @@ void ControlSenderPlugin::cbAckConnect(const am_Handle_s handle, const am_Error_
}
}
-void ControlSenderPlugin::cbAckDisconnect(const am_Handle_s handle, const am_Error_e errorID)
+void CAmControlSenderBase::cbAckDisconnect(const am_Handle_s handle, const am_Error_e errorID)
{
(void) errorID;
//\todo:error checking
@@ -369,14 +369,14 @@ void ControlSenderPlugin::cbAckDisconnect(const am_Handle_s handle, const am_Err
}
}
-void ControlSenderPlugin::cbAckCrossFade(const am_Handle_s handle, const am_HotSink_e hostsink, const am_Error_e error)
+void CAmControlSenderBase::cbAckCrossFade(const am_Handle_s handle, const am_HotSink_e hostsink, const am_Error_e error)
{
(void) handle;
(void) hostsink;
(void) error;
}
-void ControlSenderPlugin::cbAckSetSinkVolumeChange(const am_Handle_s handle, const am_volume_t volume, const am_Error_e error)
+void CAmControlSenderBase::cbAckSetSinkVolumeChange(const am_Handle_s handle, const am_volume_t volume, const am_Error_e error)
{
(void) error;
(void) volume;
@@ -391,26 +391,26 @@ void ControlSenderPlugin::cbAckSetSinkVolumeChange(const am_Handle_s handle, con
}
}
-void ControlSenderPlugin::cbAckSetSourceVolumeChange(const am_Handle_s handle, const am_volume_t voulme, const am_Error_e error)
+void CAmControlSenderBase::cbAckSetSourceVolumeChange(const am_Handle_s handle, const am_volume_t voulme, const am_Error_e error)
{
(void) error;
(void) voulme;
(void) handle;
}
-void ControlSenderPlugin::cbAckSetSourceState(const am_Handle_s handle, const am_Error_e error)
+void CAmControlSenderBase::cbAckSetSourceState(const am_Handle_s handle, const am_Error_e error)
{
(void) error;
(void) handle;
}
-void ControlSenderPlugin::cbAckSetSourceSoundProperty(const am_Handle_s handle, const am_Error_e error)
+void CAmControlSenderBase::cbAckSetSourceSoundProperty(const am_Handle_s handle, const am_Error_e error)
{
(void) error;
(void) handle;
}
-void ControlSenderPlugin::cbAckSetSinkSoundProperty(const am_Handle_s handle, const am_Error_e error)
+void CAmControlSenderBase::cbAckSetSinkSoundProperty(const am_Handle_s handle, const am_Error_e error)
{
(void) error;
//\todo:error checking
@@ -424,23 +424,23 @@ void ControlSenderPlugin::cbAckSetSinkSoundProperty(const am_Handle_s handle, co
}
}
-void ControlSenderPlugin::cbAckSetSourceSoundProperties(const am_Handle_s handle, const am_Error_e error)
+void CAmControlSenderBase::cbAckSetSourceSoundProperties(const am_Handle_s handle, const am_Error_e error)
{
(void) error;
(void) handle;
}
-void ControlSenderPlugin::cbAckSetSinkSoundProperties(const am_Handle_s handle, const am_Error_e error)
+void CAmControlSenderBase::cbAckSetSinkSoundProperties(const am_Handle_s handle, const am_Error_e error)
{
(void) error;
(void) handle;
}
-void ControlSenderPlugin::setControllerRundown()
+void CAmControlSenderBase::setControllerRundown()
{
}
-am_Error_e ControlSenderPlugin::getConnectionFormatChoice(const am_sourceID_t sourceID, const am_sinkID_t sinkID, const am_Route_s listRoute, const std::vector<am_ConnectionFormat_e> listPossibleConnectionFormats, std::vector<am_ConnectionFormat_e> & listPrioConnectionFormats)
+am_Error_e CAmControlSenderBase::getConnectionFormatChoice(const am_sourceID_t sourceID, const am_sinkID_t sinkID, const am_Route_s listRoute, const std::vector<am_ConnectionFormat_e> listPossibleConnectionFormats, std::vector<am_ConnectionFormat_e> & listPrioConnectionFormats)
{
(void) sourceID;
(void) sinkID;
@@ -450,27 +450,27 @@ am_Error_e ControlSenderPlugin::getConnectionFormatChoice(const am_sourceID_t so
return (E_OK);
}
-void ControlSenderPlugin::getInterfaceVersion(std::string & version) const
+void CAmControlSenderBase::getInterfaceVersion(std::string & version) const
{
version = ControlSendVersion;
}
-void ControlSenderPlugin::confirmCommandReady()
+void CAmControlSenderBase::confirmCommandReady()
{
logInfo("ControlSenderPlugin got Routing Ready confirmed");
}
-void ControlSenderPlugin::confirmRoutingReady()
+void CAmControlSenderBase::confirmRoutingReady()
{
logInfo("ControlSenderPlugin got Command Ready confirmed");
}
-void ControlSenderPlugin::confirmCommandRundown()
+void CAmControlSenderBase::confirmCommandRundown()
{
logInfo("ControlSenderPlugin got Routing Rundown confirmed");
}
-void ControlSenderPlugin::confirmRoutingRundown()
+void CAmControlSenderBase::confirmRoutingRundown()
{
logInfo("ControlSenderPlugin got Command Rundown confirmed");
}