1 /* 2 * Copyright (C) 2022 Huawei Device Co., Ltd. 3 * Licensed under the Apache License, Version 2.0 (the "License"); 4 * you may not use this file except in compliance with the License. 5 * You may obtain a copy of the License at 6 * 7 * http://www.apache.org/licenses/LICENSE-2.0 8 * 9 * Unless required by applicable law or agreed to in writing, software 10 * distributed under the License is distributed on an "AS IS" BASIS, 11 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12 * See the License for the specific language governing permissions and 13 * limitations under the License. 14 */ 15 16 #ifndef OPP_TRANSFER_INFORMATION_H 17 #define OPP_TRANSFER_INFORMATION_H 18 19 #include <cstdint> 20 #include <string> 21 #include "iosfwd" 22 23 namespace OHOS { 24 namespace bluetooth { 25 class IOppTransferInformation { 26 public: 27 IOppTransferInformation() = default; 28 virtual ~IOppTransferInformation() = default; 29 30 int GetId() const; 31 void SetId(int id); 32 std::string GetFileName() const; 33 void SetFileName(const std::string &fileName); 34 std::string GetFilePath() const; 35 void SetFilePath(const std::string &filePath); 36 std::string GetFileType() const; 37 void SetFileType(const std::string &fileType); 38 std::string GetDeviceName() const; 39 void SetDeviceName(const std::string &deviceName); 40 std::string GetDeviceAddress() const; 41 void SetDeviceAddress(const std::string &deviceAddress); 42 int GetDirection() const; 43 void SetDirection(int direction); 44 int GetStatus() const; 45 void SetStatus(int status); 46 int GetFailedReason() const; 47 void SetFailedReason(int failedReason); 48 uint64_t GetTimeStamp() const; 49 void SetTimeStamp(uint64_t timeStamp); 50 uint64_t GetCurrentBytes() const; 51 void SetCurrentBytes(uint64_t currentBytes); 52 uint64_t GetTotalBytes() const; 53 void SetTotalBytes(uint64_t totalBytes); 54 55 private: 56 int id_ = -1; 57 std::string fileName_; 58 std::string filePath_; 59 std::string fileType_; 60 std::string deviceName_; 61 std::string deviceAddress_; 62 int direction_ = 0; 63 int status_ = 0; 64 int failedReason_ = 0; 65 uint64_t timeStamp_ = 0; 66 uint64_t currentBytes_ = 0; 67 uint64_t totalBytes_ = 0; 68 }; 69 } // namespace bluetooth 70 } // namespace OHOS 71 72 #endif // OPP_TRANSFER_INFORMATION_H