RDK Documentation (Open Sourced RDK Components)
Components_XrdkSDCard.h
Go to the documentation of this file.
1 /*
2  * If not stated otherwise in this file or this component's Licenses.txt file the
3  * following copyright and licenses apply:
4  *
5  * Copyright 2016 RDK Management
6  *
7  * Licensed under the Apache License, Version 2.0 (the "License");
8  * you may not use this file except in compliance with the License.
9  * You may obtain a copy of the License at
10  *
11  * http://www.apache.org/licenses/LICENSE-2.0
12  *
13  * Unless required by applicable law or agreed to in writing, software
14  * distributed under the License is distributed on an "AS IS" BASIS,
15  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16  * See the License for the specific language governing permissions and
17  * limitations under the License.
18 */
19 /*
20  * Components_X_SDCard.h
21  *
22  * Created on: May 5, 2015
23  * Author: rdey
24  */
25 
26 
27 /**
28  * @file Components_XrdkSDCard.h
29  * @brief The header file provides components Xrdk SDCard information APIs.
30  */
31 
32 /**
33  * @defgroup TR69_HOSTIF_STBSERVICES_SDCARD TR-069 Object (Device.STBServices.{i}.Components.XrdkSDCard.{i})
34  * @par External rdk SDCard
35  * @ingroup TR69_HOSTIF_STBSERVICES
36  *
37  * @defgroup TR69_HOSTIF_STBSERVICES_SDCARD_API TR-069 Object (Device.STBServices.{i}.Components.XrdkSDCard.{i}) Public APIs
38  * Describe the details about RDK TR-069 components XRDK_SDK APIs specifications.
39  * @ingroup TR69_HOSTIF_STBSERVICES_SDCARD
40  *
41  * @defgroup TR69_HOSTIF_STBSERVICES_SDCARD_CLASSES TR-069 Object (Device.STBServices.{i}.Components.XrdkSDCard.{i}) Public Classes
42  * Describe the details about classes used in TR069 components XRDK_SDCARD.
43  * @ingroup TR69_HOSTIF_STBSERVICES_SDCARD
44  */
45 
46 /**
47 * @defgroup tr69hostif
48 * @{
49 * @defgroup hostif
50 * @{
51 **/
52 
53 
54 #ifndef STBSERVICE_COMPONENTS_X_RDKCENTRAL_COM_SDCARD_H_
55 #define STBSERVICE_COMPONENTS_X_RDKCENTRAL_COM_SDCARD_H_
56 
57 //#ifdef USE_XRDK_SDCARD_PROFILE
58 #include "hostIf_utils.h"
59 #include "hostIf_tr69ReqHandler.h"
60 #include "hostIf_main.h"
61 
62 #define SD_PARAM_LEN 64
63 
64 #define X_SDCARD_OBJ "Device.Services.STBService.1.Components.X_RDKCENTRAL-COM_SDCard."
65 
66 #define CAPACITY_STRING "capacity"
67 #define CARDFAILED_STRING "cardFailed"
68 #define LIFEELAPSED_STRING "lifeElapsed"
69 #define LOTID_STRING "lotID"
70 #define MANUFACTURED_STRING "manufacturer"
71 #define MODEL_STRING "model"
72 #define READONLY_STRING "readOnly"
73 #define SERIALNUMBER_STRING "serialNumber"
74 #define TSBQUALIFIED_STRING "tsbQualified"
75 #define SDCARD_STATUS "Status"
76 
77 /**
78  * @brief This class provides the TR-069 components XSD Card information.
79  * @ingroup TR69_HOSTIF_STBSERVICES_SDCARD_CLASSES
80  */
82 {
83  static GHashTable *ifHash;
86 
87 private:
88  static hostIf_STBServiceXSDCard *instance;
89  int getCapacity(HOSTIF_MsgData_t *);
90  int getCardFailed(HOSTIF_MsgData_t *);
91  int getLifeElapsed(HOSTIF_MsgData_t *);
92  int getLotID(HOSTIF_MsgData_t *);
93  int getManufacturer(HOSTIF_MsgData_t *);
94  int getModel(HOSTIF_MsgData_t *);
95  int getReadOnly(HOSTIF_MsgData_t *);
96  int getSerialNumber(HOSTIF_MsgData_t *);
97  int getTSBQualified(HOSTIF_MsgData_t *);
98  int getStatus(HOSTIF_MsgData_t *);
99 public:
100  static hostIf_STBServiceXSDCard *getInstance();
101  static void closeInstance(hostIf_STBServiceXSDCard *);
102  int handleGetMsg(HOSTIF_MsgData_t *);
103  int handleSetMsg(HOSTIF_MsgData_t *);
104 };
105 //#endif /*#USE_XRDK_SDCARD_PROFILE*/
106 #endif /* STBSERVICE_COMPONENTS_X_RDKCENTRAL_COM_SDCARD_H_ */
107 
108 
109 /** @} */
110 /** @} */
_HostIf_MsgData_t
Definition: hostIf_tr69ReqHandler.h:170
hostIf_main.h
hostIf_main API.
hostIf_STBServiceXSDCard
This class provides the TR-069 components XSD Card information.
Definition: Components_XrdkSDCard.h:81