diff options
author | Scott Lobdell <slobdell@google.com> | 2022-03-11 19:27:17 +0000 |
---|---|---|
committer | Scott Lobdell <slobdell@google.com> | 2022-03-11 19:57:09 +0000 |
commit | c9218ef1b82430a07d94f74c212a30e7ccc52975 (patch) | |
tree | 241b7fdeb6bdf1cf3af925ba8996f18faa8973d9 /system/embdrv/lc3_dec/TestSupport/DatapointsAndroid.cpp | |
parent | a26bda4d37221f2f7ef750b413502091e3bcddd4 (diff) | |
parent | 480d2270b269a0e47bf475eb439111f3f966e2a9 (diff) |
Merge TP1A.220225.003
Change-Id: Id71ac466dbfe3707fe2e544ce22b1da8f474ec2b
Diffstat (limited to 'system/embdrv/lc3_dec/TestSupport/DatapointsAndroid.cpp')
-rw-r--r-- | system/embdrv/lc3_dec/TestSupport/DatapointsAndroid.cpp | 76 |
1 files changed, 0 insertions, 76 deletions
diff --git a/system/embdrv/lc3_dec/TestSupport/DatapointsAndroid.cpp b/system/embdrv/lc3_dec/TestSupport/DatapointsAndroid.cpp deleted file mode 100644 index 2caa9628f2..0000000000 --- a/system/embdrv/lc3_dec/TestSupport/DatapointsAndroid.cpp +++ /dev/null @@ -1,76 +0,0 @@ -/* - * DatapointsDummy.cpp - * - * Copyright 2021 HIMSA II K/S - www.himsa.com. Represented by EHIMA - - * www.ehima.com - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -#include <base/logging.h> - -#include <iomanip> -#include <iostream> -#include <sstream> - -#include "Datapoints.hpp" - -class ContainerRealization {}; - -DatapointContainer::DatapointContainer() : m_pContainer(nullptr) { - // nothing stored yet; we may integrate a complete datapoint container when - // more debugging is needed in the android context - (void)m_pContainer; -} - -DatapointContainer::~DatapointContainer() {} - -void DatapointContainer::addDatapoint(const char* label, - Datapoint* pDatapoint) {} - -void DatapointContainer::addDatapoint(const char* label, void* pData, - uint16_t sizeInBytes) {} - -void DatapointContainer::addDatapoint(const char* label, const void* pData, - uint16_t sizeInBytes) {} - -void DatapointContainer::log(const char* label, const void* pData, - uint16_t sizeInBytes) { - // Note: this is just a first simple step to demonstrate the possibilities we - // have. - // In this case the datapoint label its size in bytes and its content as - // hex-byte-stream is send to the android LOG. - const uint8_t* pByteData = reinterpret_cast<const uint8_t*>(pData); - std::string valueAsHexString("0x"); - std::ostringstream vStream; - vStream << "0x"; - for (uint16_t byteNr = 0; byteNr < sizeInBytes; byteNr++) { - vStream << std::right << std::setw(2) << std::setfill('0') << std::hex - << static_cast<int>(pByteData[byteNr]); - } - // TODO: uncomment for testing - // LOG(INFO) << label << "[" << sizeInBytes << "]:" << vStream.str(); -} - -uint16_t DatapointContainer::getDatapointSize(const char* label) { return 0; } - -bool DatapointContainer::getDatapointValue(const char* label, void* pDataBuffer, - uint16_t bufferSize) { - return false; -} - -bool DatapointContainer::setDatapointValue(const char* label, - const void* pDataBuffer, - uint16_t bufferSize) { - return false; -} |