diff options
| author | Amlal <amlal@nekernel.org> | 2025-04-25 13:08:33 +0200 |
|---|---|---|
| committer | Amlal <amlal@nekernel.org> | 2025-04-25 13:08:33 +0200 |
| commit | fb790b07aeba8e22e4190cf3e1834d11ecde6c96 (patch) | |
| tree | 4cec7d1b321307b1d5935577631dae116a658a37 /dev/kernel/CFKit/Property.h | |
| parent | 63a2d92c5dfe976175cda024ec01905d11b43738 (diff) | |
dev: better .clang-format, ran format command.
Signed-off-by: Amlal <amlal@nekernel.org>
Diffstat (limited to 'dev/kernel/CFKit/Property.h')
| -rw-r--r-- | dev/kernel/CFKit/Property.h | 75 |
1 files changed, 36 insertions, 39 deletions
diff --git a/dev/kernel/CFKit/Property.h b/dev/kernel/CFKit/Property.h index 510b2c53..4dde15f9 100644 --- a/dev/kernel/CFKit/Property.h +++ b/dev/kernel/CFKit/Property.h @@ -1,56 +1,53 @@ /* ------------------------------------------- - Copyright (C) 2024-2025, Amlal El Mahrouss, all rights reserved. + Copyright (C) 2024-2025, Amlal El Mahrouss, all rights reserved. ------------------------------------------- */ #ifndef CFKIT_PROPS_H #define CFKIT_PROPS_H +#include <CFKit/GUIDWrapper.h> #include <NewKit/Array.h> #include <NewKit/Defines.h> #include <NewKit/Function.h> #include <NewKit/KString.h> -#include <CFKit/GUIDWrapper.h> #define kMaxPropLen (256U) -namespace CF -{ - using namespace Kernel; - - /// @brief handle to anything (number, ptr, string...) - using PropertyId = UIntPtr; - - /// @brief Kernel property class. - /// @example /prop/smp_max or /prop/kern_ver - class Property - { - public: - Property(); - virtual ~Property(); - - public: - Property& operator=(const Property&) = default; - Property(const Property&) = default; - - BOOL StringEquals(KString& name); - PropertyId& GetValue(); - KString& GetKey(); - - private: - KString fName{kMaxPropLen}; - PropertyId fValue{0UL}; - Ref<XRN::GUID> fGUID{}; - }; - - template <SizeT N> - using PropertyArray = Array<Property, N>; -} // namespace CF - -namespace Kernel -{ - using namespace CF; +namespace CF { +using namespace Kernel; + +/// @brief handle to anything (number, ptr, string...) +using PropertyId = UIntPtr; + +/// @brief Kernel property class. +/// @example /prop/smp_max or /prop/kern_ver +class Property { + public: + Property(); + virtual ~Property(); + + public: + Property& operator=(const Property&) = default; + Property(const Property&) = default; + + BOOL StringEquals(KString& name); + PropertyId& GetValue(); + KString& GetKey(); + + private: + KString fName{kMaxPropLen}; + PropertyId fValue{0UL}; + Ref<XRN::GUID> fGUID{}; +}; + +template <SizeT N> +using PropertyArray = Array<Property, N>; +} // namespace CF + +namespace Kernel { +using namespace CF; } -#endif // !CFKIT_PROPS_H +#endif // !CFKIT_PROPS_H |
