• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * Copyright (C) 2016 The Android Open Source Project
3  *
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
7  *
8  *      http://www.apache.org/licenses/LICENSE-2.0
9  *
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.
15  */
16 
17 #include "chre_api/chre/version.h"
18 #include "chre/platform/platform_nanoapp.h"
19 
20 namespace chre {
21 
~PlatformNanoapp()22 PlatformNanoapp::~PlatformNanoapp() {}
23 
start()24 bool PlatformNanoapp::start() {
25   return mStart();
26 }
27 
handleEvent(uint32_t senderInstanceId,uint16_t eventType,const void * eventData)28 void PlatformNanoapp::handleEvent(uint32_t senderInstanceId,
29                                   uint16_t eventType,
30                                   const void *eventData) {
31   mHandleEvent(senderInstanceId, eventType, eventData);
32 }
33 
end()34 void PlatformNanoapp::end() {
35   mEnd();
36 }
37 
getAppId() const38 uint64_t PlatformNanoapp::getAppId() const {
39   return mAppId;
40 }
41 
getAppVersion() const42 uint32_t PlatformNanoapp::getAppVersion() const {
43   return mAppVersion;
44 }
45 
getTargetApiVersion() const46 uint32_t PlatformNanoapp::getTargetApiVersion() const {
47   return CHRE_API_VERSION;
48 }
49 
isSystemNanoapp() const50 bool PlatformNanoapp::isSystemNanoapp() const {
51   return true;
52 }
53 
54 }  // namespace chre
55