1fc0b0055Sopenharmony_ci/* 2fc0b0055Sopenharmony_ci * Copyright (c) 2022-2024 Huawei Device Co., Ltd. 3fc0b0055Sopenharmony_ci * Licensed under the Apache License, Version 2.0 (the "License"); 4fc0b0055Sopenharmony_ci * you may not use this file except in compliance with the License. 5fc0b0055Sopenharmony_ci * You may obtain a copy of the License at 6fc0b0055Sopenharmony_ci * 7fc0b0055Sopenharmony_ci * http://www.apache.org/licenses/LICENSE-2.0 8fc0b0055Sopenharmony_ci * 9fc0b0055Sopenharmony_ci * Unless required by applicable law or agreed to in writing, software 10fc0b0055Sopenharmony_ci * distributed under the License is distributed on an "AS IS" BASIS, 11fc0b0055Sopenharmony_ci * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12fc0b0055Sopenharmony_ci * See the License for the specific language governing permissions and 13fc0b0055Sopenharmony_ci * limitations under the License. 14fc0b0055Sopenharmony_ci */ 15fc0b0055Sopenharmony_ci 16fc0b0055Sopenharmony_ci#ifndef TO_STRING_H 17fc0b0055Sopenharmony_ci#define TO_STRING_H 18fc0b0055Sopenharmony_ci 19fc0b0055Sopenharmony_ci#include <string> 20fc0b0055Sopenharmony_ci#include "permission_used_request.h" 21fc0b0055Sopenharmony_ci#include "permission_used_result.h" 22fc0b0055Sopenharmony_ci#include "permission_used_type_info.h" 23fc0b0055Sopenharmony_ci 24fc0b0055Sopenharmony_cinamespace OHOS { 25fc0b0055Sopenharmony_cinamespace Security { 26fc0b0055Sopenharmony_cinamespace AccessToken { 27fc0b0055Sopenharmony_ciclass ToString { 28fc0b0055Sopenharmony_cipublic: 29fc0b0055Sopenharmony_ci static void DetailUsedRecordToString( 30fc0b0055Sopenharmony_ci bool isAccessDetail, const std::vector<UsedRecordDetail>& detailRecord, std::string& infos); 31fc0b0055Sopenharmony_ci static void PermissionUsedRecordToString( 32fc0b0055Sopenharmony_ci const std::vector<PermissionUsedRecord>& permissionRecords, std::string& infos); 33fc0b0055Sopenharmony_ci static void BundleUsedRecordToString(const BundleUsedRecord& bundleRecord, std::string& infos); 34fc0b0055Sopenharmony_ci static void PermissionUsedResultToString(const PermissionUsedResult& result, std::string& infos); 35fc0b0055Sopenharmony_ci static void PermissionUsedTypeInfoToString(const PermissionUsedTypeInfo& type, std::string& infos); 36fc0b0055Sopenharmony_ci}; 37fc0b0055Sopenharmony_ci} // namespace AccessToken 38fc0b0055Sopenharmony_ci} // namespace Security 39fc0b0055Sopenharmony_ci} // namespace OHOS 40fc0b0055Sopenharmony_ci#endif // TO_STRING_H 41