1 /* 2 * Copyright (C) 2017 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_automotive_vehicle_V2_0_impl_FakeValueGenerator_H_ 18 #define android_hardware_automotive_vehicle_V2_0_impl_FakeValueGenerator_H_ 19 20 #include <android/hardware/automotive/vehicle/2.0/types.h> 21 22 namespace android { 23 namespace hardware { 24 namespace automotive { 25 namespace vehicle { 26 namespace V2_0 { 27 28 namespace impl { 29 30 class FakeValueGenerator { 31 public: 32 virtual ~FakeValueGenerator() = default; 33 34 virtual VehiclePropValue nextEvent() = 0; 35 36 virtual bool hasNext() = 0; 37 }; 38 39 using Clock = std::chrono::steady_clock; 40 using Nanos = std::chrono::nanoseconds; 41 using TimePoint = std::chrono::time_point<Clock, Nanos>; 42 43 using FakeValueGeneratorPtr = std::unique_ptr<FakeValueGenerator>; 44 45 } // namespace impl 46 47 } // namespace V2_0 48 } // namespace vehicle 49 } // namespace automotive 50 } // namespace hardware 51 } // namespace android 52 53 #endif // android_hardware_automotive_vehicle_V2_0_impl_FakeValueGenerator_H_ 54