securitysettings/qtconfigutils/eapqtconfiginterface/src/eapqtconfiginterface.cpp
branchGCC_SURGE
changeset 40 60f08993dad0
parent 39 fe6b6762fccd
equal deleted inserted replaced
29:77618ad58aba 40:60f08993dad0
     1 /*
     1 /*
     2  * Copyright (c) 2010 Nokia Corporation and/or its subsidiary(-ies).
     2  * Copyright (c) 2010 Nokia Corporation and/or its subsidiary(-ies).
     3  * All rights reserved.
     3  * All rights reserved.
     4  * This component and the accompanying materials are made available
     4  * This component and the accompanying materials are made available
     5  * under the terms of the License "Eclipse Public License v1.0"
     5  * under the terms of "Eclipse Public License v1.0"
     6  * which accompanies this distribution, and is available
     6  * which accompanies this distribution, and is available
     7  * at the URL "http://www.eclipse.org/legal/epl-v10.html".
     7  * at the URL "http://www.eclipse.org/legal/epl-v10.html".
     8  *
     8  *
     9  * Initial Contributors:
     9  * Initial Contributors:
    10  * Nokia Corporation - initial contribution.
    10  * Nokia Corporation - initial contribution.
    15  *   EAP method configuration QT interface
    15  *   EAP method configuration QT interface
    16  *
    16  *
    17  */
    17  */
    18 
    18 
    19 /*
    19 /*
    20  * %version: 1 %
    20  * %version: 25 %
    21  */
    21  */
    22 
    22 
       
    23 // System includes
    23 #include <QList>
    24 #include <QList>
       
    25 #include <eapqtconfiginterface.h>
       
    26 #include <eapqtexpandedeaptype.h>
    24 
    27 
    25 #include "eapqtconfiginterface.h"
    28 // User includes
       
    29 #include "eapqtconfiginterface_p.h"
    26 #include "cpeapplugininterface.h"
    30 #include "cpeapplugininterface.h"
    27 #include "eapqtplugininfo.h"
       
    28 
    31 
    29 //----------------------------------------------------------------------------
    32 /*!
    30 //              EapQtConfigInterface
    33  *  \class EapQtConfigInterface
    31 //----------------------------------------------------------------------------
    34  *  \brief Public implementation of EAP QT configuration interface
       
    35  */
    32 
    36 
    33 // stub implementation for now
    37 // External function prototypes
    34 
    38 
    35 EapQtConfigInterface::EapQtConfigInterface(const EapBearerType /* bearerType */, const int /* databaseIndex */)
    39 // Local constants
       
    40 
       
    41 // ======== LOCAL FUNCTIONS ========
       
    42 
       
    43 // ======== MEMBER FUNCTIONS ========
       
    44 
       
    45 EapQtConfigInterface::EapQtConfigInterface() :
       
    46     d_ptr(new EapQtConfigInterfacePrivate)
       
    47 {
       
    48 }
       
    49 
       
    50 EapQtConfigInterface::EapQtConfigInterface(const EapBearerType bearerType, const int iapId) :
       
    51     d_ptr(new EapQtConfigInterfacePrivate(bearerType, iapId))
    36 {
    52 {
    37 }
    53 }
    38 
    54 
    39 EapQtConfigInterface::~EapQtConfigInterface()
    55 EapQtConfigInterface::~EapQtConfigInterface()
    40 {
    56 {
       
    57     // d_ptr is scoped pointer, deleted automatically
       
    58 }
       
    59 
       
    60 bool EapQtConfigInterface::setConfigurationReference(const int iapId) const
       
    61 {
       
    62     return d_ptr->setConfigurationReference(iapId);
    41 }
    63 }
    42 
    64 
    43 QList<EapQtPluginInfo> EapQtConfigInterface::supportedOuterTypes() const
    65 QList<EapQtPluginInfo> EapQtConfigInterface::supportedOuterTypes() const
    44 {
    66 {
    45     // stub
    67     return d_ptr->supportedOuterTypes();
    46     QList<EapQtPluginInfo> tmp;
       
    47     return tmp;
       
    48 }
    68 }
    49 
    69 
    50 CpBaseSettingView *EapQtConfigInterface::uiInstance(const EapQtPluginHandle& /* pluginInfo */) const
    70 QList<EapQtPluginInfo> EapQtConfigInterface::supportedInnerTypes(const EapQtPluginHandle &outerType) const
    51 {
    71 {
    52     // stub
    72     return d_ptr->supportedInnerTypes(outerType);
    53     return NULL;
       
    54 }
    73 }
       
    74 
       
    75 bool EapQtConfigInterface::updateCertificates() const
       
    76 {
       
    77     return d_ptr->updateCertificates();
       
    78 }
       
    79 
       
    80 QList<EapQtCertificateInfo> EapQtConfigInterface::certificateAuthorityCertificates() const
       
    81 {
       
    82     return d_ptr->certificateAuthorityCertificates();
       
    83 }
       
    84 
       
    85 QList<EapQtCertificateInfo> EapQtConfigInterface::userCertificates() const
       
    86 {
       
    87     return d_ptr->userCertificates();
       
    88 }
       
    89 
       
    90 CpBaseSettingView *EapQtConfigInterface::uiInstance(const EapQtPluginHandle &outerHandle,
       
    91     const EapQtPluginHandle &pluginHandle) const
       
    92 {
       
    93     return d_ptr->uiInstance(outerHandle, pluginHandle);
       
    94 }
       
    95 
       
    96 QList<EapQtPluginHandle> EapQtConfigInterface::selectedOuterTypes() const
       
    97 {
       
    98     return d_ptr->selectedOuterTypes();
       
    99 }
       
   100 
       
   101 bool EapQtConfigInterface::isSupportedOuterType(const EapQtPluginHandle &handle) const
       
   102 {
       
   103     return d_ptr->isSupportedOuterType(handle);
       
   104 }
       
   105 
       
   106 bool EapQtConfigInterface::isSupportedInnerType(const EapQtPluginHandle &outerHandle,
       
   107     const EapQtPluginHandle& innerHandle) const
       
   108 {
       
   109     return d_ptr->isSupportedInnerType(outerHandle, innerHandle);
       
   110 }
       
   111 
       
   112 bool EapQtConfigInterface::setSelectedOuterTypes(const QList<EapQtPluginHandle> &outerHandles) const
       
   113 {
       
   114     return d_ptr->setSelectedOuterTypes(outerHandles);
       
   115 }
       
   116 
       
   117 bool EapQtConfigInterface::readConfiguration(const EapQtPluginHandle &outerHandle,
       
   118     const EapQtPluginHandle &pluginHandle, EapQtConfig &config) const
       
   119 {
       
   120     return d_ptr->readConfiguration(outerHandle, pluginHandle, config);
       
   121 }
       
   122 
       
   123 bool EapQtConfigInterface::saveConfiguration(const EapQtPluginHandle &pluginInfo,
       
   124     const EapQtConfig &config) const
       
   125 {
       
   126     return d_ptr->saveConfiguration(pluginInfo, config);
       
   127 }
       
   128 
       
   129 bool EapQtConfigInterface::deleteConfiguration() const
       
   130 {
       
   131     return d_ptr->deleteConfiguration();
       
   132 }
       
   133 
       
   134 EapQtValidator *EapQtConfigInterface::validatorEap(const EapQtExpandedEapType &type,
       
   135     const EapQtConfig::SettingsId id) const
       
   136 {
       
   137     return d_ptr->validatorEap(type, id);
       
   138 }
       
   139 
       
   140 bool EapQtConfigInterface::readPacStoreConfiguration(EapQtPacStoreConfig &config) const
       
   141 {
       
   142     return d_ptr->readPacStoreConfiguration(config);
       
   143 }
       
   144 
       
   145 bool EapQtConfigInterface::savePacStoreConfiguration(const EapQtPacStoreConfig &config) const
       
   146 {
       
   147     return d_ptr->savePacStoreConfiguration(config);
       
   148 }
       
   149 
       
   150 EapQtValidator *EapQtConfigInterface::validatorPacStore(
       
   151     const EapQtPacStoreConfig::PacStoreSettings id) const
       
   152 {
       
   153     return d_ptr->validatorPacStore(id);
       
   154 }