blob: 2152c899c8f0cfc76835bc9eb000cb91c59c7f0d [file] [log] [blame]
Amy126ee922019-08-09 16:25:12 -07001/*
2 * Copyright (C) 2019 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#ifndef ANDROID_HARDWARE_TV_TUNER_V1_0_TUNER_H_
18#define ANDROID_HARDWARE_TV_TUNER_V1_0_TUNER_H_
19
20#include <android/hardware/tv/tuner/1.0/ITuner.h>
21#include "Frontend.h"
22
23using namespace std;
24
25namespace android {
26namespace hardware {
27namespace tv {
28namespace tuner {
29namespace V1_0 {
30namespace implementation {
31
32class Tuner : public ITuner {
33 public:
34 Tuner();
35 virtual Return<void> getFrontendIds(getFrontendIds_cb _hidl_cb) override;
36
37 virtual Return<void> openFrontendById(uint32_t frontendId,
38 openFrontendById_cb _hidl_cb) override;
39
40 private:
41 virtual ~Tuner();
42 // Static mFrontends array to maintain local frontends information
43 vector<sp<Frontend>> mFrontends;
44 // To maintain how many Frontends we have
45 int mFrontendSize;
46};
47
48} // namespace implementation
49} // namespace V1_0
50} // namespace tuner
51} // namespace tv
52} // namespace hardware
53} // namespace android
54
55#endif // ANDROID_HARDWARE_TV_TUNER_V1_0_TUNER_H_