/* * Copyright (c) 2023 Fancy Code. * 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. */ /** * @file ConfigBaseCode.h * @brief Contains internal definitions and declarations for configuration codes. * * This header file is intended for internal use only and should not be included * directly by other files. It defines the StatusCode creation function for configuration * related codes. */ #ifndef CONFIG_BASE_CODE_H #define CONFIG_BASE_CODE_H #include "ConfigBase.h" #include "StatusCode.h" #ifdef __cplusplus extern "C" { #endif /** * @brief Error directive indicating that this file is for internal use only. * * This directive is used to prevent accidental inclusion of the internal header file * by external code. If this file is included without the CONFIG_OWNER macro being defined, * it will cause a compile-time error. */ #ifndef CONFIG_OWNER #error This is internal file, never include it. #endif /** * @brief Creates a StatusCode for configuration codes. * * This function is used internally to create a StatusCode that represents a configuration * related code. It is not part of the public API and should not be used by external code. * * @param code The long integer value to be encapsulated in a StatusCode. * @return A StatusCode object representing the configuration code. */ const StatusCode CreateConfigCode(const long int code); #ifdef __cplusplus } #endif #endif