mmserv/tms/tmsapi/src/tmsg711.cpp
changeset 0 71ca22bcf22a
equal deleted inserted replaced
-1:000000000000 0:71ca22bcf22a
       
     1 /*
       
     2  * Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies).
       
     3  * All rights reserved.
       
     4  * This component and the accompanying materials are made available
       
     5  * under the terms of "Eclipse Public License v1.0"
       
     6  * which accompanies this distribution, and is available
       
     7  * at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     8  *
       
     9  * Initial Contributors:
       
    10  * Nokia Corporation - initial contribution.
       
    11  *
       
    12  * Contributors:
       
    13  *
       
    14  * Description: Telephony Multimedia Service
       
    15  *
       
    16  */
       
    17 
       
    18 #include <tmsg711format.h>
       
    19 #include "tmsg711formatbody.h"
       
    20 #include "tmsutility.h"
       
    21 
       
    22 using namespace TMS;
       
    23 
       
    24 EXPORT_C TMSG711Format::TMSG711Format() :
       
    25     iBody(NULL)
       
    26     {
       
    27     }
       
    28 
       
    29 EXPORT_C TMSG711Format::~TMSG711Format()
       
    30     {
       
    31     // iBody is deleted with TMSFormat::iFormatBody
       
    32     }
       
    33 
       
    34 EXPORT_C gint TMSG711Format::SetMode(const TMSG711CodecMode aMode)
       
    35     {
       
    36     gint status(TMS_RESULT_UNINITIALIZED_OBJECT);
       
    37     if (iBody)
       
    38         {
       
    39         status = iBody->SetMode(aMode);
       
    40         }
       
    41     return status;
       
    42     }
       
    43 
       
    44 EXPORT_C gint TMSG711Format::GetMode(TMSG711CodecMode& aMode)
       
    45     {
       
    46     gint status(TMS_RESULT_UNINITIALIZED_OBJECT);
       
    47     if (iBody)
       
    48         {
       
    49         status = iBody->GetMode(aMode);
       
    50         }
       
    51     return status;
       
    52     }
       
    53 
       
    54 EXPORT_C gint TMSG711Format::SetCNG(const gboolean aCng)
       
    55     {
       
    56     gint status(TMS_RESULT_UNINITIALIZED_OBJECT);
       
    57     if (iBody)
       
    58         {
       
    59         status = iBody->SetCNG(aCng);
       
    60         }
       
    61     return status;
       
    62     }
       
    63 
       
    64 EXPORT_C gint TMSG711Format::GetCNG(gboolean& aCng)
       
    65     {
       
    66     gint status(TMS_RESULT_UNINITIALIZED_OBJECT);
       
    67     if (iBody)
       
    68         {
       
    69         status = iBody->GetCNG(aCng);
       
    70         }
       
    71     return status;
       
    72     }
       
    73 
       
    74 EXPORT_C gint TMSG711Format::SetPlc(const gboolean aPlc)
       
    75     {
       
    76     gint status(TMS_RESULT_UNINITIALIZED_OBJECT);
       
    77     if (iBody)
       
    78         {
       
    79         status = iBody->SetPlc(aPlc);
       
    80         }
       
    81     return status;
       
    82     }
       
    83 
       
    84 EXPORT_C gint TMSG711Format::GetPlc(gboolean& aPlc)
       
    85     {
       
    86     gint status(TMS_RESULT_UNINITIALIZED_OBJECT);
       
    87     if (iBody)
       
    88         {
       
    89         status = iBody->GetPlc(aPlc);
       
    90         }
       
    91     return status;
       
    92     }
       
    93 
       
    94 EXPORT_C gint TMSG711Format::SetVADMode(const gboolean aVad)
       
    95     {
       
    96     gint status(TMS_RESULT_UNINITIALIZED_OBJECT);
       
    97     if (iBody)
       
    98         {
       
    99         status = iBody->SetVADMode(aVad);
       
   100         }
       
   101     return status;
       
   102     }
       
   103 
       
   104 EXPORT_C gint TMSG711Format::GetVADMode(gboolean& aVad)
       
   105     {
       
   106     gint status(TMS_RESULT_UNINITIALIZED_OBJECT);
       
   107     if (iBody)
       
   108         {
       
   109         status = iBody->GetVADMode(aVad);
       
   110         }
       
   111     return status;
       
   112     }
       
   113 
       
   114 // End of file