Commit Graph

16 Commits

Author SHA1 Message Date
2eca802d01 refactor(serif): fixed typos and updated names to reflect 4DSSE->SERiF 2025-06-12 09:04:03 -04:00
72f08238b6 Merge remote-tracking branch 'upstream/main' into feature/mixedPolytrope
# Conflicts:
#	.gitignore
#	build-config/meson.build
#	meson.build
#	meson_options.txt
#	src/composition/public/composition.h
#	src/config/public/config.h
#	src/constants/public/const.h
#	src/meson.build
#	tests/composition_sandbox/comp.cpp
2025-06-11 15:05:11 -04:00
6e4ff1ece9 refactor(serif): refactored entire codebase into serif and sub namespaces 2025-06-11 14:49:11 -04:00
b014300d99 refactor(config): header guard -> pragma once 2025-05-05 14:36:16 -04:00
9307c398b6 build(config): added compile time option to disable config file load error
In general we may want to enforce that a config file is explicitly loaded before any access is requested. However, there are times when this is non ideal behavior. We introduce a compile time flag (CONFIG_HARSH, and CONFIG_WARN). If config hars is defined then a runtime error will be thrown if a config value is requested before the config file has been loaded. If Config warn is defined (and config harsh is not) then a warning will be printed, otherwise nothing will happen. If either warn or nothing is defined this means that the default values defined in the get methods will be used.

Note that the meson build system has had an option added -Dconfig_error_handling=["none", "warn", "harsh"] (default="none") which can be used to manage these compile time options. In general release builds should have this disabled while debug builts should have it set to harsh.
2025-04-30 11:48:38 -04:00
91d66ea62e build(meson): switched almost all intermediate targets to shared libraries 2025-04-30 11:44:53 -04:00
30a6cb074f docs(src): updated file headers 2025-04-21 08:56:45 -04:00
14bc8a49b3 Merge branch 'main' into feature/pointwisePolytrope 2025-03-26 11:38:07 -04:00
18f3f6689d feat(config): added ability to get all keys and check if a key exists in the given config file
also added the ability to get a config value without specifying a default (this is only avalible to freind classes)
2025-03-20 14:27:57 -04:00
18e719fba1 refactor(header): brought auto header changes from main into polytrope branch 2025-03-18 07:21:47 -04:00
3f86d0ceb1 docs(src): added file headers to all files 2025-03-17 12:42:33 -04:00
6aaa25df4b fix(config): loaded flag and checks added
added check to make sure that config file has been loaded before any config variables are accessed
2025-03-03 09:53:42 -05:00
a20a150c85 fix(config): restored deleted code
I accidently deleted some cacheing mechanisms, these have been restored
2025-02-21 10:39:43 -05:00
e54a5be967 docs(config): rebuild docs and removed redundant documentation 2025-02-20 09:45:47 -05:00
2dcff35e01 perf(config): added cache
In order to prevent traversing the YAML tree I have added a hash map (O(1) lookup) to cache already accessed config variables. I have also added a vector to store keys requested but not found so we do not need to check for those every time
2025-02-20 09:30:43 -05:00
a134878e67 feat(config): config class added
At many points in the code we may want configurable options, the Config class usses a yaml file to make this easy. It also allows for namespace references "opac:lowtemp:file" etc...
2025-02-19 16:11:55 -05:00