2 * Copyright (c) 2011 Samsung Electronics Co., Ltd All Rights Reserved
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
8 * http://www.apache.org/licenses/LICENSE-2.0
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
17 #include <commons/Exception.h>
20 const bool CLAMSHELL_SUPPORTED = false;
21 const bool KEYPAD_SUPPORTED = false;
24 namespace WrtPlugins {
27 Manager& Manager::getInstance()
29 static Manager instance;
37 bool Manager::hasClamshell() const
39 return CLAMSHELL_SUPPORTED;
42 Api::Device::IClamshell* Manager::getClamshell() const
44 ThrowMsg(Commons::UnsupportedException,
45 "Device is not equipped with clamshell.");
48 bool Manager::hasKeypad() const
50 return KEYPAD_SUPPORTED;
53 Api::Device::IKeypad* Manager::getKeypad() const
55 ThrowMsg(Commons::UnsupportedException,
56 "Device is not equipped with keypad.");
59 std::string Manager::getImei() const
62 return m_imei.getString();
64 Catch(Commons::ConversionException) {
65 ReThrow(Commons::PlatformException);
69 Manager::Manager() : m_imei(VCONFKEY_TELEPHONY_IMEI)