// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
-// http://www.apache.org/licenses/LICENSE-2.0
+// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
#include <FNetWifiWifiBssInfo.h>
#include <FNetWifiWifiManager.h>
#include <FSec_AccessController.h>
+#include "FSys_SystemInfoImpl.h"
#include "FNetWifi_WifiManagerImpl.h"
+static const wchar_t* _WIFI_FEATURE_INFO_KEY = L"http://tizen.org/feature/network.wifi";
+
using namespace std;
using namespace Tizen::Base;
using namespace Tizen::Base::Runtime;
using namespace Tizen::Base::Collection;
using namespace Tizen::Security;
+using namespace Tizen::System;
namespace Tizen { namespace Net { namespace Wifi {
{
result r = E_SUCCESS;
+ bool isWifiSupported = false;
+ r = _SystemInfoImpl::GetSysInfo(_WIFI_FEATURE_INFO_KEY, isWifiSupported);
+
+ SysTryReturnResult(NID_NET_WIFI, r == E_SUCCESS && isWifiSupported == true, E_UNSUPPORTED_OPERATION, "Wi-Fi is not supported.");
+
SysAssertf(__pWifiManagerImpl == null,
"Already constructed. Calling Construct() twice or more on a same instance is not allowed for this class.");