| François Gaffie | 2110e04 | 2015-03-24 08:41:51 +0100 | [diff] [blame^] | 1 | /* | 
 | 2 |  * Copyright (C) 2015 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 | #pragma once | 
 | 18 |  | 
 | 19 | #include <AudioGain.h> | 
 | 20 | #include <AudioPort.h> | 
 | 21 | #include <AudioPatch.h> | 
 | 22 | #include <IOProfile.h> | 
 | 23 | #include <DeviceDescriptor.h> | 
 | 24 | #include <AudioInputDescriptor.h> | 
 | 25 | #include <AudioOutputDescriptor.h> | 
 | 26 | #include <AudioPolicyMix.h> | 
 | 27 | #include <SoundTriggerSession.h> | 
 | 28 | #include <StreamDescriptor.h> | 
 | 29 |  | 
 | 30 | namespace android { | 
 | 31 |  | 
 | 32 | /** | 
 | 33 |  * This interface is an observer that the manager shall implement to allows e.g. the engine | 
 | 34 |  * to access to policy pillars elements (like output / input descritors collections, | 
 | 35 |  * HwModule collections, AudioMix, ... | 
 | 36 |  */ | 
 | 37 | class AudioPolicyManagerObserver | 
 | 38 | { | 
 | 39 | public: | 
 | 40 |     virtual const AudioPatchCollection &getAudioPatches() const = 0; | 
 | 41 |  | 
 | 42 |     virtual const SoundTriggerSessionCollection &getSoundTriggerSessionCollection() const = 0; | 
 | 43 |  | 
 | 44 |     virtual const AudioPolicyMixCollection &getAudioPolicyMixCollection() const = 0; | 
 | 45 |  | 
 | 46 |     virtual const AudioOutputCollection &getOutputs() const = 0; | 
 | 47 |  | 
 | 48 |     virtual const AudioInputCollection &getInputs() const = 0; | 
 | 49 |  | 
 | 50 |     virtual const DeviceVector &getAvailableOutputDevices() const = 0; | 
 | 51 |  | 
 | 52 |     virtual const DeviceVector &getAvailableInputDevices() const = 0; | 
 | 53 |  | 
 | 54 |     virtual StreamDescriptorCollection &getStreamDescriptors() = 0; | 
 | 55 |  | 
 | 56 |     virtual const sp<DeviceDescriptor> &getDefaultOutputDevice() const = 0; | 
 | 57 |  | 
 | 58 | protected: | 
 | 59 |     virtual ~AudioPolicyManagerObserver() {} | 
 | 60 | }; | 
 | 61 |  | 
 | 62 | }; // namespace android |