From e1c733b5d551b4111788f55014e0c045758b2bfd Mon Sep 17 00:00:00 2001 From: liyu Date: Sun, 9 Oct 2022 19:45:28 +0800 Subject: [PATCH 1/6] * adapt build Change-Id: I43bc8c29dfe4647fafd9a420ab7c3729a4f3af17 Signed-off-by: liyu --- base/BUILD.gn | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/base/BUILD.gn b/base/BUILD.gn index 924d1d4..c882175 100644 --- a/base/BUILD.gn +++ b/base/BUILD.gn @@ -73,6 +73,21 @@ sources_utils = [ "src/rwlock.cpp", ] +if (current_os == "mingw" || current_os == "mac") { + sources_utils -= [ + "src/ashmem.cpp", + "src/datetime_ex.cpp", + "src/event_demultiplexer.cpp", + "src/event_handler.cpp", + "src/event_reactor.cpp", + "src/file_ex.cpp", + "src/semaphore_ex.cpp", + "src/thread_ex.cpp", + "src/timer.cpp", + "src/timer_event_handler.cpp", + ] +} + ohos_static_library("utilsbase") { sources = sources_utils configs = [ ":utils_coverage_config" ] -- Gitee From f1f50d01018e8c58d1188c4b05932635a01e00c7 Mon Sep 17 00:00:00 2001 From: liyu Date: Sun, 9 Oct 2022 19:45:28 +0800 Subject: [PATCH 2/6] * adapt _WIN32 Change-Id: I89de64592585872e2fe5c43fed30241f4cf36f6f Signed-off-by: liyu --- base/include/flat_obj.h | 112 +++++++++++++++++++++++--------------- base/src/directory_ex.cpp | 35 +++++++++++- base/src/thread_pool.cpp | 2 + 3 files changed, 105 insertions(+), 44 deletions(-) diff --git a/base/include/flat_obj.h b/base/include/flat_obj.h index 0c7dd7c..79c6a4d 100644 --- a/base/include/flat_obj.h +++ b/base/include/flat_obj.h @@ -1,43 +1,69 @@ -/* - * Copyright (c) 2021 Huawei Device Co., Ltd. - * 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. - */ - -#ifndef UTILS_BASE_FLAT_OBJ_H -#define UTILS_BASE_FLAT_OBJ_H - -#include -#include - -#ifdef BINDER_IPC_32BIT - typedef __u32 binder_size_t; - typedef __u32 binder_uintptr_t; -#else - typedef __u64 binder_size_t; - typedef __u64 binder_uintptr_t; -#endif - -struct parcel_binder_object_header { - __u32 type; -}; -struct parcel_flat_binder_object { - struct parcel_binder_object_header hdr; - __u32 flags; - union { - binder_uintptr_t binder; - __u32 handle; - }; - binder_uintptr_t cookie; -}; - -#endif +/* + * Copyright (c) 2021 Huawei Device Co., Ltd. + * 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. + */ + +#ifndef UTILS_BASE_FLAT_OBJ_H +#define UTILS_BASE_FLAT_OBJ_H + +#if defined(__APPLE__) || defined(_WIN32) +#include +#include + +#ifdef BINDER_IPC_32BIT + typedef uint32_t binder_size_t; + typedef uint32_t binder_uintptr_t; +#else + typedef uint64_t binder_size_t; + typedef uint64_t binder_uintptr_t; +#endif + +struct parcel_binder_object_header { + uint32_t type; +}; +struct parcel_flat_binder_object { + struct parcel_binder_object_header hdr; + uint32_t flags; + union { + binder_uintptr_t binder; + uint32_t handle; + }; + binder_uintptr_t cookie; +}; +#else // !_WIN32 +#include +#include + +#ifdef BINDER_IPC_32BIT + typedef __u32 binder_size_t; + typedef __u32 binder_uintptr_t; +#else + typedef __u64 binder_size_t; + typedef __u64 binder_uintptr_t; +#endif + +struct parcel_binder_object_header { + __u32 type; +}; +struct parcel_flat_binder_object { + struct parcel_binder_object_header hdr; + __u32 flags; + union { + binder_uintptr_t binder; + __u32 handle; + }; + binder_uintptr_t cookie; +}; +#endif // _WIN32 + +#endif // UTILS_BASE_FLAT_OBJ_H diff --git a/base/src/directory_ex.cpp b/base/src/directory_ex.cpp index fd8a366..35959f0 100644 --- a/base/src/directory_ex.cpp +++ b/base/src/directory_ex.cpp @@ -13,6 +13,7 @@ * limitations under the License. */ +#include #include "directory_ex.h" #include #include @@ -23,6 +24,7 @@ using namespace std; namespace OHOS { +#if !defined(__APPLE__) && !defined(_WIN32) string GetCurrentProcFullFileName() { char procFile[PATH_MAX + 1] = {0}; @@ -34,6 +36,13 @@ string GetCurrentProcFullFileName() procFile[ret] = '\0'; return string(procFile); } +#else +string GetCurrentProcFullFileName() +{ + assert("GetCurrentProcFullFileName Not Implement"); + return ""; +} +#endif string GetCurrentProcPath() { @@ -82,6 +91,7 @@ string IncludeTrailingPathDelimiter(const std::string& path) return path; } +#if !defined(__APPLE__) && !defined(_WIN32) void GetDirFiles(const string& path, vector& files) { string pathStringWithDelimiter; @@ -108,7 +118,14 @@ void GetDirFiles(const string& path, vector& files) } closedir(dir); } +#else +void GetDirFiles(const string& path, vector& files) +{ + assert("GetCurrentProcFullFileName Not Implement"); +} +#endif +#if !defined(__APPLE__) && !defined(_WIN32) bool ForceCreateDirectory(const string& path) { string::size_type index = 0; @@ -130,7 +147,15 @@ bool ForceCreateDirectory(const string& path) return access(path.c_str(), F_OK) == 0; } +#else +bool ForceCreateDirectory(const string& path) +{ + assert("GetCurrentProcFullFileName Not Implement"); + return false; +} +#endif +#if !defined(__APPLE__) && !defined(_WIN32) bool ForceRemoveDirectory(const string& path) { string subPath; @@ -173,6 +198,7 @@ bool ForceRemoveDirectory(const string& path) return ret && (access(path.c_str(), F_OK) != 0); } +#endif bool RemoveFile(const string& fileName) { @@ -220,6 +246,7 @@ bool ChangeModeFile(const string& fileName, const mode_t& mode) return ChangeMode(fileName, mode); } +#if !defined(__APPLE__) && !defined(_WIN32) bool ChangeModeDirectory(const string& path, const mode_t& mode) { string subPath; @@ -262,6 +289,7 @@ bool ChangeModeDirectory(const string& path, const mode_t& mode) } return ret; } +#endif bool PathToRealPath(const string& path, string& realPath) { @@ -276,7 +304,12 @@ bool PathToRealPath(const string& path, string& realPath) } char tmpPath[PATH_MAX] = {0}; - if (realpath(path.c_str(), tmpPath) == nullptr) { +#ifdef _WIN32 + auto ret = _fullpath(tmpPath, path.c_str(), sizeof(tmpPath)); +#else + auto ret = realpath(path.c_str(), tmpPath); +#endif + if (ret == nullptr) { UTILS_LOGD("path to realpath error"); return false; } diff --git a/base/src/thread_pool.cpp b/base/src/thread_pool.cpp index 9951929..ea48c81 100644 --- a/base/src/thread_pool.cpp +++ b/base/src/thread_pool.cpp @@ -48,11 +48,13 @@ uint32_t ThreadPool::Start(int numThreads) for (int i = 0; i < numThreads; ++i) { std::thread t(&ThreadPool::WorkInThread, this); +#ifndef _WIN32 // Give the name of ThreadPool to threads created by the ThreadPool. int err = pthread_setname_np(t.native_handle(), (myName_ + std::to_string(i)).c_str()); if (err != 0) { UTILS_LOGW("Failed to set name to thread. %{public}s", strerror(err)); } +#endif threads_.push_back(std::move(t)); } return ERR_OK; -- Gitee From 03972aa87499649b11fb10bb70896a6e0ceac6ec Mon Sep 17 00:00:00 2001 From: liyu Date: Sun, 9 Oct 2022 19:45:28 +0800 Subject: [PATCH 3/6] * export Change-Id: Ia98d4b7e9cb92bc8ec7c5b2755c336e2f6a0051e Signed-off-by: liyu --- base/include/directory_ex.h | 16 ++++++++++++++++ base/include/parcel.h | 4 ++-- base/include/refbase.h | 4 ++-- base/include/rwlock.h | 2 +- base/include/string_ex.h | 18 ++++++++++++++++++ 5 files changed, 39 insertions(+), 5 deletions(-) diff --git a/base/include/directory_ex.h b/base/include/directory_ex.h index ee7d46c..da9f9ac 100644 --- a/base/include/directory_ex.h +++ b/base/include/directory_ex.h @@ -25,90 +25,106 @@ namespace OHOS { /** * The GetCurrentProcFullFileName function get the current process exe name. */ +OHOS_EXPORT std::string GetCurrentProcFullFileName(); /** * The GetCurrentProcPath function get the current process exe path. */ +OHOS_EXPORT std::string GetCurrentProcPath(); /** * The ExtractFilePath function extract the input file path. */ +OHOS_EXPORT std::string ExtractFilePath(const std::string& fileFullName); /** * The ExtractFilePath function extract the input file name. */ +OHOS_EXPORT std::string ExtractFileName(const std::string& fileFullName); /** * The ExtractFileExt function extract the input file name type. */ +OHOS_EXPORT std::string ExtractFileExt(const std::string& fileName); /** * The ExcludeTrailingPathDelimiter function exclude the end '/' from the strPath, * return the path without the end '/'. */ +OHOS_EXPORT std::string ExcludeTrailingPathDelimiter(const std::string& path); /** * The IncludeTrailingPathDelimiter function include the end '/' from the strPath, * return the path with the end '/'. */ +OHOS_EXPORT std::string IncludeTrailingPathDelimiter(const std::string& path); /** * The GetDirFiles function get all files in the path. */ +OHOS_EXPORT void GetDirFiles(const std::string& path, std::vector& files); /** * The IsEmptyFolder function judge the path is empty, * return true if is empty, else false. */ +OHOS_EXPORT bool IsEmptyFolder(const std::string& path); /** * The ForceCreateDirectory function is force create the dir with subdir, * return true if create succ, else false. */ +OHOS_EXPORT bool ForceCreateDirectory(const std::string& path); /** * The ForceRemoveDirectory function is force delete the dir with subdir and files, * return true if remove succ, else false. */ +OHOS_EXPORT bool ForceRemoveDirectory(const std::string& path); /** * The RemoveFile function is remove the input strFileName, * return true if remove succ, else false. */ +OHOS_EXPORT bool RemoveFile(const std::string& fileName); /** * The GetFolderSize function is get the folder size(bytes). */ +OHOS_EXPORT uint64_t GetFolderSize(const std::string& path); /** * The ChangeModeFile function is change the input file authority, * return true if change succ, else false. */ +OHOS_EXPORT bool ChangeModeFile(const std::string& fileName, const mode_t& mode); /** * The ChangeModeDirectory function is change the input Directory authority, include subdir, * return true if change succ, else false. */ +OHOS_EXPORT bool ChangeModeDirectory(const std::string& path, const mode_t& mode); /** * The PathToRealPath function is get real path from relative path, * return true if change succ, else false. */ +OHOS_EXPORT bool PathToRealPath(const std::string& path, std::string& realPath); } // OHOS #endif diff --git a/base/include/parcel.h b/base/include/parcel.h index 93de825..af8b6e7 100644 --- a/base/include/parcel.h +++ b/base/include/parcel.h @@ -26,7 +26,7 @@ namespace OHOS { class Parcel; -class Parcelable : public virtual RefBase { +class OHOS_EXPORT Parcelable : public virtual RefBase { public: virtual ~Parcelable() = default; @@ -85,7 +85,7 @@ private: void *Realloc(void *data, size_t newSize) override; }; -class Parcel { +class OHOS_EXPORT Parcel { public: Parcel(); explicit Parcel(Allocator *allocator); diff --git a/base/include/refbase.h b/base/include/refbase.h index d551030..917e96f 100644 --- a/base/include/refbase.h +++ b/base/include/refbase.h @@ -142,7 +142,7 @@ private: }; #endif -class WeakRefCounter { +class OHOS_EXPORT WeakRefCounter { public: WeakRefCounter(RefCounter *counter, void *cookie); @@ -162,7 +162,7 @@ private: void *cookie_ = nullptr; }; -class RefBase { +class OHOS_EXPORT RefBase { public: RefBase(); diff --git a/base/include/rwlock.h b/base/include/rwlock.h index fde028d..9a4f89a 100644 --- a/base/include/rwlock.h +++ b/base/include/rwlock.h @@ -24,7 +24,7 @@ namespace OHOS { namespace Utils { -class RWLock : NoCopyable { +class OHOS_EXPORT RWLock : NoCopyable { public: enum LockStatus { LOCK_STATUS_WRITE = -1, diff --git a/base/include/string_ex.h b/base/include/string_ex.h index 41be2ad..fbca492 100644 --- a/base/include/string_ex.h +++ b/base/include/string_ex.h @@ -23,31 +23,37 @@ namespace OHOS { /** * The UpperStr function convert all letters of str to uppercase. */ +OHOS_EXPORT std::string UpperStr(const std::string& str); /** * The LowerStr function convert all letters of str to lowercase. */ +OHOS_EXPORT std::string LowerStr(const std::string& str); /** * The ReplaceStr function will replace src with dst int base. */ +OHOS_EXPORT std::string ReplaceStr(const std::string& str, const std::string& src, const std::string& dst); /** * The TrimStr function will trim str by cTrim front and end. */ +OHOS_EXPORT std::string TrimStr(const std::string& str, const char cTrim = ' '); /** * The DexToHexString function convert decimal to hexadecimal string. */ +OHOS_EXPORT std::string DexToHexString(int value, bool upper = true); /** * The SplitStr function will split str by strSep. */ +OHOS_EXPORT void SplitStr(const std::string& str, const std::string& sep, std::vector& strs, bool canEmpty = false, bool needTrim = true); @@ -63,48 +69,56 @@ inline std::string ToString(T iValue) /** * The StrToInt function convert str to int. */ +OHOS_EXPORT bool StrToInt(const std::string& str, int& value); /** * The IsNumericStr function judge all characters of the string are numbers, * return true if all are numbers, else false. */ +OHOS_EXPORT bool IsNumericStr(const std::string& str); /** * The IsAlphaStr function judge all characters of the string are alphabet, * return true if all are alphabet, else false. */ +OHOS_EXPORT bool IsAlphaStr(const std::string& str); /** * The IsUpperStr function judge all characters of the string are uppercase, * return true if all are uppercase, else false. */ +OHOS_EXPORT bool IsUpperStr(const std::string& str); /** * The IsLowerStr function judge all characters of the string are lowercase, * return true if all are lowercase, else false. */ +OHOS_EXPORT bool IsLowerStr(const std::string& str); /** * The IsSubStr function judge the sub in str, * return true if sub in str, else false. */ +OHOS_EXPORT bool IsSubStr(const std::string& str, const std::string& sub); /** * The GetFirstSubStrBetween function get the first sub_str between left and right * return the rightstr pos, if failed return string::npos. */ +OHOS_EXPORT std::string::size_type GetFirstSubStrBetween(const std::string& str, const std::string& left, const std::string& right, std::string& sub); /** * The GetSubStrBetween function get the sub strings between left and right. */ +OHOS_EXPORT void GetSubStrBetween(const std::string& str, const std::string& left, const std::string& right, std::vector& sub); @@ -112,20 +126,24 @@ void GetSubStrBetween(const std::string& str, const std::string& left, * The IsSameTextStr function judge the first's letter is same with second, * return true if same, else false. */ +OHOS_EXPORT bool IsSameTextStr(const std::string& first, const std::string& second); +OHOS_EXPORT bool IsAsciiString(const std::string& str); /** * The str16ToStr8 function convert string16 to string8. * If convert failed, return an empty string. */ +OHOS_EXPORT std::string Str16ToStr8(const std::u16string& str16); /** * The Str8ToStr16 function convert string8 to string16. * If convert failed, return an empty u16string. */ +OHOS_EXPORT std::u16string Str8ToStr16(const std::string& str); } // namespace OHOS -- Gitee From 6917781676ef2b8b5a16d8d8e052f01d2aad7dab Mon Sep 17 00:00:00 2001 From: liyu Date: Sun, 9 Oct 2022 19:45:28 +0800 Subject: [PATCH 4/6] * export api Change-Id: Ibcbe57a3d7cd5b58f463838eb3acc9d0de06189d Signed-off-by: liyu --- base/BUILD.gn | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/base/BUILD.gn b/base/BUILD.gn index c882175..4938c9e 100644 --- a/base/BUILD.gn +++ b/base/BUILD.gn @@ -133,5 +133,13 @@ ohos_shared_library("utils") { "system", "updater", ] + + if (current_os == "mingw") { + cflags = [ "-Wno-ignored-attributes" ] # need because stdio.h dont have dllexport, but SECUREC_API have + defines += [ + "SECUREC_DLL_EXPORT", + "SECUREC_IS_DLL_LIBRARY", + ] + } } ############################################################################### -- Gitee From b08703dc59101e6e4239de85d86b19305636ce3b Mon Sep 17 00:00:00 2001 From: liyu Date: Sun, 9 Oct 2022 19:45:28 +0800 Subject: [PATCH 5/6] * adapt __gnu_linux__ Change-Id: Ia6d00f8972c1cf2687465093152286ac9fc4ee87 Signed-off-by: liyu --- base/BUILD.gn | 2 +- base/src/event_reactor.h | 1 + base/src/file_ex.cpp | 3 ++- base/src/parcel.cpp | 1 + base/src/string_ex.cpp | 2 ++ base/src/thread_pool.cpp | 1 + 6 files changed, 8 insertions(+), 2 deletions(-) diff --git a/base/BUILD.gn b/base/BUILD.gn index 4938c9e..1a53d4c 100644 --- a/base/BUILD.gn +++ b/base/BUILD.gn @@ -73,7 +73,7 @@ sources_utils = [ "src/rwlock.cpp", ] -if (current_os == "mingw" || current_os == "mac") { +if (current_os == "mingw" || current_os == "mac" || current_os == "linux") { sources_utils -= [ "src/ashmem.cpp", "src/datetime_ex.cpp", diff --git a/base/src/event_reactor.h b/base/src/event_reactor.h index 794e44a..3b3194f 100644 --- a/base/src/event_reactor.h +++ b/base/src/event_reactor.h @@ -18,6 +18,7 @@ #include #include +#include #include #include #include diff --git a/base/src/file_ex.cpp b/base/src/file_ex.cpp index 578b1be..c888a9e 100644 --- a/base/src/file_ex.cpp +++ b/base/src/file_ex.cpp @@ -24,6 +24,7 @@ #include #include #include +#include #include "directory_ex.h" #include "utils_log.h" @@ -262,7 +263,7 @@ bool SaveBufferToFile(const string& filePath, const vector& content, bool } // if the file is not exist,create it first! - uint32_t mode = truncated ? (ios::out | ios::binary | ios::trunc) : (ios::out | ios::binary | ios::app); + auto mode = truncated ? (ios::out | ios::binary | ios::trunc) : (ios::out | ios::binary | ios::app); ofstream file; file.open(filePath.c_str(), mode); if (!file.is_open()) { diff --git a/base/src/parcel.cpp b/base/src/parcel.cpp index 65b15f4..d810eba 100644 --- a/base/src/parcel.cpp +++ b/base/src/parcel.cpp @@ -14,6 +14,7 @@ */ #include "parcel.h" +#include #include "securec.h" #include "utils_log.h" diff --git a/base/src/string_ex.cpp b/base/src/string_ex.cpp index 32340ae..efefadc 100644 --- a/base/src/string_ex.cpp +++ b/base/src/string_ex.cpp @@ -17,6 +17,8 @@ #include "unicode_ex.h" #include "utils_log.h" #include "securec.h" +#include +#include #include #include #include diff --git a/base/src/thread_pool.cpp b/base/src/thread_pool.cpp index ea48c81..fe884ac 100644 --- a/base/src/thread_pool.cpp +++ b/base/src/thread_pool.cpp @@ -17,6 +17,7 @@ #include "errors.h" #include "utils_log.h" +#include #include #include -- Gitee From f71c3351120452b04fc6a1b3cf9c53666d0a745b Mon Sep 17 00:00:00 2001 From: liyu Date: Sun, 9 Oct 2022 19:45:29 +0800 Subject: [PATCH 6/6] * copyright Change-Id: I6e2dc28ddf3d20a3d275568b3d02bc80b4a12547 Signed-off-by: liyu --- base/BUILD.gn | 2 +- base/include/directory_ex.h | 2 +- base/include/flat_obj.h | 2 +- base/include/parcel.h | 2 +- base/include/refbase.h | 2 +- base/include/rwlock.h | 2 +- base/include/string_ex.h | 2 +- base/src/directory_ex.cpp | 2 +- base/src/event_reactor.h | 2 +- base/src/file_ex.cpp | 2 +- base/src/parcel.cpp | 2 +- base/src/string_ex.cpp | 2 +- 12 files changed, 12 insertions(+), 12 deletions(-) diff --git a/base/BUILD.gn b/base/BUILD.gn index 1a53d4c..b23ecde 100644 --- a/base/BUILD.gn +++ b/base/BUILD.gn @@ -1,4 +1,4 @@ -# Copyright (c) 2021 Huawei Device Co., Ltd. +# Copyright (c) 2021-2022 Huawei Device Co., Ltd. # 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 diff --git a/base/include/directory_ex.h b/base/include/directory_ex.h index da9f9ac..12aba37 100644 --- a/base/include/directory_ex.h +++ b/base/include/directory_ex.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 Huawei Device Co., Ltd. + * Copyright (c) 2021-2022 Huawei Device Co., Ltd. * 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 diff --git a/base/include/flat_obj.h b/base/include/flat_obj.h index 79c6a4d..da17568 100644 --- a/base/include/flat_obj.h +++ b/base/include/flat_obj.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 Huawei Device Co., Ltd. + * Copyright (c) 2021-2022 Huawei Device Co., Ltd. * 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 diff --git a/base/include/parcel.h b/base/include/parcel.h index af8b6e7..3aa66ca 100644 --- a/base/include/parcel.h +++ b/base/include/parcel.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 Huawei Device Co., Ltd. + * Copyright (c) 2021-2022 Huawei Device Co., Ltd. * 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 diff --git a/base/include/refbase.h b/base/include/refbase.h index 917e96f..506c7f4 100644 --- a/base/include/refbase.h +++ b/base/include/refbase.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 Huawei Device Co., Ltd. + * Copyright (c) 2021-2022 Huawei Device Co., Ltd. * 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 diff --git a/base/include/rwlock.h b/base/include/rwlock.h index 9a4f89a..cf9ba13 100644 --- a/base/include/rwlock.h +++ b/base/include/rwlock.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 Huawei Device Co., Ltd. + * Copyright (c) 2021-2022 Huawei Device Co., Ltd. * 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 diff --git a/base/include/string_ex.h b/base/include/string_ex.h index fbca492..a7135a9 100644 --- a/base/include/string_ex.h +++ b/base/include/string_ex.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 Huawei Device Co., Ltd. + * Copyright (c) 2021-2022 Huawei Device Co., Ltd. * 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 diff --git a/base/src/directory_ex.cpp b/base/src/directory_ex.cpp index 35959f0..438b188 100644 --- a/base/src/directory_ex.cpp +++ b/base/src/directory_ex.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 Huawei Device Co., Ltd. + * Copyright (c) 2021-2022 Huawei Device Co., Ltd. * 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 diff --git a/base/src/event_reactor.h b/base/src/event_reactor.h index 3b3194f..c628e76 100644 --- a/base/src/event_reactor.h +++ b/base/src/event_reactor.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 Huawei Device Co., Ltd. + * Copyright (c) 2021-2022 Huawei Device Co., Ltd. * 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 diff --git a/base/src/file_ex.cpp b/base/src/file_ex.cpp index c888a9e..488da8a 100644 --- a/base/src/file_ex.cpp +++ b/base/src/file_ex.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 Huawei Device Co., Ltd. + * Copyright (c) 2021-2022 Huawei Device Co., Ltd. * 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 diff --git a/base/src/parcel.cpp b/base/src/parcel.cpp index d810eba..51ff846 100644 --- a/base/src/parcel.cpp +++ b/base/src/parcel.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 Huawei Device Co., Ltd. + * Copyright (c) 2021-2022 Huawei Device Co., Ltd. * 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 diff --git a/base/src/string_ex.cpp b/base/src/string_ex.cpp index efefadc..8facfe5 100644 --- a/base/src/string_ex.cpp +++ b/base/src/string_ex.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 Huawei Device Co., Ltd. + * Copyright (c) 2021-2022 Huawei Device Co., Ltd. * 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 -- Gitee