From 337734d34075f83b57bc58c5b7859e175e00f1b5 Mon Sep 17 00:00:00 2001 From: yyc12345 Date: Thu, 25 Dec 2025 15:12:29 +0800 Subject: [PATCH] refactor: refactor doc layout --- doc/src/{ => carton}/arg_parser.dox | 0 doc/src/{ => carton}/config_manager.dox | 0 doc/src/{ => carton}/console_helper.dox | 0 doc/src/{ => carton}/encoding_helper.dox | 0 doc/src/{ => carton}/exception_helper.dox | 0 doc/src/constraints.dox | 49 ----------- doc/src/index.dox | 14 ++-- doc/src/{library_macros.dox => macro.dox} | 36 ++++---- doc/src/{ => num}/parser_helper.dox | 0 doc/src/{ => patch}/io_helper.dox | 0 doc/src/{ => patch}/std_patch.dox | 0 doc/src/premise_and_principle.dox | 8 +- doc/src/{ => string}/string_helper.dox | 0 .../string_reinterpret.dox} | 82 +++++-------------- doc/src/{ => windows}/com_helper.dox | 0 doc/src/{ => windows}/dialog_helper.dox | 0 doc/src/{ => windows}/win_fct_helper.dox | 0 doc/src/{ => windows}/win_import.dox | 0 18 files changed, 52 insertions(+), 137 deletions(-) rename doc/src/{ => carton}/arg_parser.dox (100%) rename doc/src/{ => carton}/config_manager.dox (100%) rename doc/src/{ => carton}/console_helper.dox (100%) rename doc/src/{ => carton}/encoding_helper.dox (100%) rename doc/src/{ => carton}/exception_helper.dox (100%) delete mode 100644 doc/src/constraints.dox rename doc/src/{library_macros.dox => macro.dox} (89%) rename doc/src/{ => num}/parser_helper.dox (100%) rename doc/src/{ => patch}/io_helper.dox (100%) rename doc/src/{ => patch}/std_patch.dox (100%) rename doc/src/{ => string}/string_helper.dox (100%) rename doc/src/{library_encoding.dox => string/string_reinterpret.dox} (67%) rename doc/src/{ => windows}/com_helper.dox (100%) rename doc/src/{ => windows}/dialog_helper.dox (100%) rename doc/src/{ => windows}/win_fct_helper.dox (100%) rename doc/src/{ => windows}/win_import.dox (100%) diff --git a/doc/src/arg_parser.dox b/doc/src/carton/arg_parser.dox similarity index 100% rename from doc/src/arg_parser.dox rename to doc/src/carton/arg_parser.dox diff --git a/doc/src/config_manager.dox b/doc/src/carton/config_manager.dox similarity index 100% rename from doc/src/config_manager.dox rename to doc/src/carton/config_manager.dox diff --git a/doc/src/console_helper.dox b/doc/src/carton/console_helper.dox similarity index 100% rename from doc/src/console_helper.dox rename to doc/src/carton/console_helper.dox diff --git a/doc/src/encoding_helper.dox b/doc/src/carton/encoding_helper.dox similarity index 100% rename from doc/src/encoding_helper.dox rename to doc/src/carton/encoding_helper.dox diff --git a/doc/src/exception_helper.dox b/doc/src/carton/exception_helper.dox similarity index 100% rename from doc/src/exception_helper.dox rename to doc/src/carton/exception_helper.dox diff --git a/doc/src/constraints.dox b/doc/src/constraints.dox deleted file mode 100644 index 90780f0..0000000 --- a/doc/src/constraints.dox +++ /dev/null @@ -1,49 +0,0 @@ -namespace YYCC::Constraints { -/** - -\page constraints Constraints - -YYCC::Constraints namespace provide Constraint struct declaration -and various common constraint generator function. - -This namespace is specifically used by YYCC::ConfigManager and YYCC::ArgParser namespaces. -See \ref config_manager chapter and \ref arg_parser chapter for how to utlize this namespace. - -\section constraints__prototype Prototype - -Constraint instruct library how check whether given value is in range, -and how to clamp it if it is invalid. -For example, you can use constraint to limit a number in given minimum maximum value, -or limit a string in specific format by using regex and etc. - -Constraint is a template struct. -The argument of template is the underlying data type which need to be checked. -The struct with different template argument is not compatible. - -Currently, this struct only contain 1 function pointer, -which is used for detecting whether given value is in range / valid. - -\subsection constraints__presets Constraint Presets - -YYCC::Constraints provides some constraint presets which are commonly used. -All functions inside this namespace will return a Constraint instance, -and you can directly use it. - -There is a list of all provided functions: - -\li GetMinMaxRangeConstraint(): Limit the number value in given minimum maximum value range (inclusive). -\li GetEnumEnumerationConstraint(): Limit the enum value by given all possible value set. -\li GetStringEnumerationConstraint(): Limit the string by given all possible value set. - -\subsection config_manager__constraint__custom Custom Constraint - -For creating your personal constraint, -you need to create Constraint instance manually. -You can browse all existing constraint preset functions code for know how to write it. - -The things you need to do is simple. -First, you need decide the template argument of Constraint. -Second, you need assign class member of Constraint by C++ lambda syntax. - -*/ -} \ No newline at end of file diff --git a/doc/src/index.dox b/doc/src/index.dox index 6772831..dfd44cd 100644 --- a/doc/src/index.dox +++ b/doc/src/index.dox @@ -31,15 +31,17 @@ \li \subpage premise_and_principle - \li \subpage library_macros + STL Enhancements + + \li \subpage macro + + \li \subpage string_reinterpret - Advanced Features -