terminus.hpp (77e6fe7ae064915e73760a94ae2c674bc6d3ef8a) | terminus.hpp (9fc7912818a9fb62af1b7dfca6bd98a5f5377ea4) |
---|---|
1#pragma once 2 3#include "libpldm/platform.h" 4 5#include "common/types.hpp" 6#include "numeric_sensor.hpp" 7#include "requester/handler.hpp" 8#include "terminus.hpp" --- 108 unchanged lines hidden (view full) --- 117 118 /** @brief The getter to return terminus's TID */ 119 pldm_tid_t getTid() 120 { 121 return tid; 122 } 123 124 /** @brief The getter to get terminus's mctp medium */ | 1#pragma once 2 3#include "libpldm/platform.h" 4 5#include "common/types.hpp" 6#include "numeric_sensor.hpp" 7#include "requester/handler.hpp" 8#include "terminus.hpp" --- 108 unchanged lines hidden (view full) --- 117 118 /** @brief The getter to return terminus's TID */ 119 pldm_tid_t getTid() 120 { 121 return tid; 122 } 123 124 /** @brief The getter to get terminus's mctp medium */ |
125 std::string_view getTerminusName() | 125 std::optional<std::string_view> getTerminusName() |
126 { | 126 { |
127 if (terminusName.empty()) 128 { 129 return std::nullopt; 130 } |
|
127 return terminusName; 128 } 129 130 /** @brief A list of PDRs fetched from Terminus */ 131 std::vector<std::vector<uint8_t>> pdrs{}; 132 133 /** @brief A flag to indicate if terminus has been initialized */ 134 bool initialized = false; --- 134 unchanged lines hidden --- | 131 return terminusName; 132 } 133 134 /** @brief A list of PDRs fetched from Terminus */ 135 std::vector<std::vector<uint8_t>> pdrs{}; 136 137 /** @brief A flag to indicate if terminus has been initialized */ 138 bool initialized = false; --- 134 unchanged lines hidden --- |