- Jan 04, 2023
-
-
Jonathan Schöbel authored
The validator was used to check that every created tag is validate. However I now think that validation should take place at a later time, so it is not mandatory. Thus developing the validator is now discontinued.
-
- Nov 15, 2022
-
-
Jonathan Schöbel authored
Instead of the trivial structure SH_Error, SH_Status is used. The name was chosen, because error/status is set independently whether an error has occurred. Beside the error type, it also contains the associated errno and an error message. The error message is also printed, when it is set. Generating error messages with variadic arguments is now also supported. There are also macros to check for a set status. The exception handling was removed for the *_free methods, because they can't fail predictably during runtime. Unfortunately the compiler reports, that inside the macro set_status printf may be called with NULL [printf (NULL)], although, this is explicitly debarred.
-
- Sep 20, 2022
-
-
Jonathan Schöbel authored
-
- Sep 18, 2022
-
-
Jonathan Schöbel authored
This renaming is neccessary, as the future Fragmment will be the base class to all Fragment types.
-
- Sep 08, 2022
-
-
Jonathan Schöbel authored
When the wrap mode is used, after each tag a newline is started. Also the html is indented, which can be configured by the parameters indent_base, indent_base, indent_char. The parameter indent_base specifies the width the first tag should be indented with, while indent_step specifies the increment of the indent when switching to a child tag. The character, that is used for indenting is taken from indent_char. (It could also be a string longer than a single character). This aguments can't be set by the user, but are hardcoded (by now).
-
Jonathan Schöbel authored
Fragment can be copied, either recursive (copying also all childs) or nonrecursive (ignoring the childs, thus the copy has always no childs). Adding the same element twice in the tree (graph) isn't possible, as this leads to problems e.g. double free or similars.
-
- Sep 05, 2022
-
-
Jonathan Schöbel authored
The methods - SH_Fragment_get_child (by index) - SH_Fragment_is_child (non recursive) and - SH_Fragment_is_descendant (recursive) were added.
-
- Sep 04, 2022
-
-
Jonathan Schöbel authored
A Fragment can contain childs. When building the html, the childs html is generated where appropiate.
-
- Sep 01, 2022
-
-
Jonathan Schöbel authored
A Fragment can output it's html. If there is an error the method aborts and returns NULL.
-
- Jun 22, 2022
-
-
Jonathan Schöbel authored
Check in tests whether error really was written, by setting it to undefined before each call.
-
- Aug 31, 2022
-
-
Jonathan Schöbel authored
-
- Jun 20, 2022
-
-
Jonathan Schöbel authored
-
Jonathan Schöbel authored
Tests are done using check, allowing to integrate the tests into the Autotools. Methods that are part of another unit, but are called in this unit aren't tested as this would interfere with the idea of unittests. This also applies for purely wrapper functions, where a call is passed to another unit.
-
- Jun 21, 2022
-
-
Jonathan Schöbel authored
Error handling is done by passing an Error structure as inout parameter to functions that can fail on runtime predictable. This parameter is always the last one. Methods, where this is not the case, doesn't have an error parameter. When an Error is detected, also an ERROR is passed to the log. Because this isn't implemented yet, it is replaced by a nop. The macro EXIT becomes now useless. It was used earlier in case of an error, to terminate the program in the first place. This behaviour is not userfriendly, but it can't be decided on the library's side, whether there is an option to inform the user, something must be cleaned up or even that recovering is possible at all. Often these recognized errors are a non-working malloc or an over-/underflow. Error handling can be ignored by the caller by passing NULL to the Error parameter. Whether an error had occured, is also always possible to be determined, by examining the return value. If the error occours in a function returning a pointer, NULL will be returned. If it returns an value, a special error value of that type is returned, i.e. PAGE_ERR in SH_Data_register_page. If the return type would be void, a boolean is returned, which tells, whether the method has succeeded. (False means, that an error has occured.) The error may have occured in an intern method and is passed upwards (the stack). Internally errors are handled by an enum, but this must be considered an implementation detail and can be changed in later versions. It is in the responsibility of the caller to recover gracefully. It has to be assumed that the requested operation have neither worked, nor actually took place. Those the operation can be retried (hopefully).
-
- Jun 20, 2022
-
-
Jonathan Schöbel authored
Pages are hold by Data, CMS passes trough the call(s).
-
Jonathan Schöbel authored
data handels all intern data and serves as a cache between the CMS and the (R)DBMS.
-
Jonathan Schöbel authored
cms will be the base "object", that performs all neccessary actions.
-
Jonathan Schöbel authored
-