]> Kevux Git Server - fll/commitdiff
Update: Add FSS Simple Packet related functionality and remove delimit and comment...
authorKevin Day <kevin@kevux.org>
Mon, 17 Jul 2023 05:24:37 +0000 (00:24 -0500)
committerKevin Day <kevin@kevux.org>
Mon, 17 Jul 2023 05:24:37 +0000 (00:24 -0500)
The FSS Simple Packet functionality is added, to provide for processing of the FSS Simple Packet.
The f_fss_simple_packet_ranges_t represents a set of ranges for designating where/how the packet is defined within some string.

The delimit and comment types are just helper type definitions for existing number types.
Simplify the design by getting rid of those, replacing them with the type that they effectively represent.
A lot of code is updated to reflect this change.

110 files changed:
build/disable/about.txt
build/disable/level_0/f_fss.h
build/level_0/settings
build/monolithic/settings
build/stand_alone/fake.config.h
build/stand_alone/fake.settings
level_0/f_fss/c/fss.c
level_0/f_fss/c/fss.h
level_0/f_fss/c/fss/comment.h [deleted file]
level_0/f_fss/c/fss/common.h
level_0/f_fss/c/fss/delimit.c [deleted file]
level_0/f_fss/c/fss/delimit.h [deleted file]
level_0/f_fss/c/fss/item.c [new file with mode: 0644]
level_0/f_fss/c/fss/item.h [new file with mode: 0644]
level_0/f_fss/c/fss/named.c
level_0/f_fss/c/fss/named.h
level_0/f_fss/c/fss/nest.c
level_0/f_fss/c/fss/nest.h
level_0/f_fss/c/fss/private-item.c [new file with mode: 0644]
level_0/f_fss/c/fss/private-item.h [new file with mode: 0644]
level_0/f_fss/c/fss/private-named.c [new file with mode: 0644]
level_0/f_fss/c/fss/private-named.h [new file with mode: 0644]
level_0/f_fss/c/fss/private-nest.c [new file with mode: 0644]
level_0/f_fss/c/fss/private-nest.h [new file with mode: 0644]
level_0/f_fss/c/fss/private-set.c [new file with mode: 0644]
level_0/f_fss/c/fss/private-set.h [new file with mode: 0644]
level_0/f_fss/c/fss/private-set_quote.c [new file with mode: 0644]
level_0/f_fss/c/fss/private-set_quote.h [new file with mode: 0644]
level_0/f_fss/c/fss/private-simple_packet.c [new file with mode: 0644]
level_0/f_fss/c/fss/private-simple_packet.h [new file with mode: 0644]
level_0/f_fss/c/fss/quote.c [moved from level_0/f_fss/c/fss/comment.c with 100% similarity]
level_0/f_fss/c/fss/set.c
level_0/f_fss/c/fss/set.h
level_0/f_fss/c/fss/set_quote.c [new file with mode: 0644]
level_0/f_fss/c/fss/set_quote.h [new file with mode: 0644]
level_0/f_fss/c/fss/simple_packet.c [new file with mode: 0644]
level_0/f_fss/c/fss/simple_packet.h [new file with mode: 0644]
level_0/f_fss/c/private-fss.c
level_0/f_fss/c/private-fss.h
level_0/f_fss/data/build/settings
level_0/f_fss/data/build/settings-mocks
level_0/f_fss/data/build/settings-tests
level_0/f_fss/tests/unit/c/test-fss-apply_delimit.c
level_0/f_fss/tests/unit/c/test-fss-apply_delimit_range.c
level_0/f_fss/tests/unit/c/test-fss-simple_packet_ranges_adjust.c [new file with mode: 0644]
level_0/f_fss/tests/unit/c/test-fss-simple_packet_ranges_adjust.h [new file with mode: 0644]
level_0/f_fss/tests/unit/c/test-fss-simple_packet_ranges_decimate_by.c [new file with mode: 0644]
level_0/f_fss/tests/unit/c/test-fss-simple_packet_ranges_decimate_by.h [new file with mode: 0644]
level_0/f_fss/tests/unit/c/test-fss-simple_packet_ranges_decrease_by.c [new file with mode: 0644]
level_0/f_fss/tests/unit/c/test-fss-simple_packet_ranges_decrease_by.h [new file with mode: 0644]
level_0/f_fss/tests/unit/c/test-fss-simple_packet_ranges_increase.c [new file with mode: 0644]
level_0/f_fss/tests/unit/c/test-fss-simple_packet_ranges_increase.h [new file with mode: 0644]
level_0/f_fss/tests/unit/c/test-fss-simple_packet_ranges_increase_by.c [new file with mode: 0644]
level_0/f_fss/tests/unit/c/test-fss-simple_packet_ranges_increase_by.h [new file with mode: 0644]
level_0/f_fss/tests/unit/c/test-fss-simple_packet_ranges_resize.c [new file with mode: 0644]
level_0/f_fss/tests/unit/c/test-fss-simple_packet_ranges_resize.h [new file with mode: 0644]
level_0/f_fss/tests/unit/c/test-fss.c
level_0/f_fss/tests/unit/c/test-fss.h
level_0/f_status/c/status.h
level_0/f_status_string/c/status_string.c
level_0/f_status_string/c/status_string.h
level_0/f_status_string/tests/unit/c/test-status_string-to.c
level_1/fl_fss/c/fss/basic.c
level_1/fl_fss/c/fss/basic.h
level_1/fl_fss/c/fss/basic_list.c
level_1/fl_fss/c/fss/basic_list.h
level_1/fl_fss/c/fss/embedded_list.c
level_1/fl_fss/c/fss/embedded_list.h
level_1/fl_fss/c/fss/extended.c
level_1/fl_fss/c/fss/extended.h
level_1/fl_fss/c/fss/extended_list.c
level_1/fl_fss/c/fss/extended_list.h
level_1/fl_fss/c/private-fss.c
level_1/fl_fss/c/private-fss.h
level_1/fl_status_string/c/status_string.c
level_1/fl_status_string/tests/unit/c/test-status_string-from.c
level_2/fll_fss/c/fss.c
level_2/fll_fss/c/fss.h
level_2/fll_fss/c/fss/basic.c
level_2/fll_fss/c/fss/basic.h
level_2/fll_fss/c/fss/basic_list.c
level_2/fll_fss/c/fss/basic_list.h
level_2/fll_fss/c/fss/embedded_list.c
level_2/fll_fss/c/fss/embedded_list.h
level_2/fll_fss/c/fss/extended.c
level_2/fll_fss/c/fss/extended.h
level_2/fll_fss/c/fss/extended_list.c
level_2/fll_fss/c/fss/extended_list.h
level_2/fll_fss/c/fss/payload.c
level_2/fll_fss/c/fss/payload.h
level_3/control/c/private-common.h
level_3/control/c/private-control.c
level_3/controller/c/common/private-cache.h
level_3/controller/c/rule/private-rule.c
level_3/controller/c/rule/private-rule.h
level_3/fake/c/main/build/load.c
level_3/fake/c/main/build/load.h
level_3/fake/c/main/make/load_fakefile.c
level_3/fake/c/main/make/load_fakefile.h
level_3/fake/c/main/make/operate.c
level_3/fake/c/main/make/operate.h
level_3/firewall/c/private-common.h
level_3/firewall/c/private-firewall.c
level_3/fss_embedded_list_read/c/fss_embedded_list_read.c
level_3/fss_embedded_list_read/c/private-read.c
level_3/fss_embedded_list_read/c/private-read.h
level_3/fss_read/c/main/common/type.h
level_3/fss_read/c/main/print/data.c
level_3/fss_read/c/main/print/data.h
level_3/fss_read/c/main/process_normal.h

index 4600eb9abaecee936237996dabbc577bee1c9d50..79cd64e86d27fec067bbf33dcee043da0df13cd1 100644 (file)
@@ -33,18 +33,18 @@ Consider the following example using the fake dependencies for the stand alone b
 # echo $(cat level_3/fake/data/build/dependencies)
 
 Which prints:
-  # fss-0000 f_type f_status f_memory f_type_array f_string f_utf f_account f_capability f_color f_console f_control_group f_conversion f_directory f_environment f_execute f_file f_fss f_iki f_limit f_network f_path f_pipe f_print f_signal fl_control_group fl_conversion fl_directory fl_environment fl_execute fl_fss fl_iki fl_print fl_string fll_error fll_execute fll_file fll_fss fll_path fll_print fll_program
+  # fss-0000 f_type f_status f_memory f_type_array f_string f_utf f_account f_capability f_color f_compare f_console f_control_group f_conversion f_directory f_environment f_execute f_file f_fss f_iki f_limit f_parse f_path f_pipe f_print f_rip f_signal f_thread fl_control_group fl_conversion fl_directory fl_environment fl_execute fl_fss fl_iki fl_path fl_print fll_error fll_execute fll_file fll_fss fll_print fll_program
 
 From this list, build the level_0:
 
-# for i in f_type f_status f_memory f_type_array f_string f_utf f_account f_capability f_color f_console f_control_group f_conversion f_directory f_environment f_execute f_file f_fss f_iki f_limit f_network f_path f_pipe f_print f_signal ; do if [[ -f build/disable/level_0/$i.h ]] ; then echo >> build/stand_alone/fake.config.h && cat build/disable/level_0/$i.h >> build/stand_alone/fake.config.h ; fi ; done
+# for i in f_type f_status f_memory f_type_array f_string f_utf f_account f_capability f_color f_compare f_console f_control_group f_conversion f_directory f_environment f_execute f_file f_fss f_iki f_limit f_parse f_path f_pipe f_print f_rip f_signal f_thread ; do if [[ -f build/disable/level_0/$i.h ]] ; then echo >> build/stand_alone/fake.config.h && cat build/disable/level_0/$i.h >> build/stand_alone/fake.config.h ; fi ; done
 
 From the list, build the level_1:
 
-# for i in fl_control_group fl_conversion fl_directory fl_environment fl_execute fl_fss fl_iki fl_print fl_string ; do if [[ -f build/disable/level_1/$i.h ]] ; then echo >> build/stand_alone/fake.config.h && cat build/disable/level_1/$i.h >> build/stand_alone/fake.config.h ; fi ; done
+# for i in fl_control_group fl_conversion fl_directory fl_environment fl_execute fl_fss fl_iki fl_path fl_print ; do if [[ -f build/disable/level_1/$i.h ]] ; then echo >> build/stand_alone/fake.config.h && cat build/disable/level_1/$i.h >> build/stand_alone/fake.config.h ; fi ; done
 
 From the list, build the level_2:
 
-# for i in fll_error fll_execute fll_file fll_fss fll_path fll_print fll_program ; do if [[ -f build/disable/level_2/$i.h ]] ; then echo >> build/stand_alone/fake.config.h && cat build/disable/level_2/$i.h >> build/stand_alone/fake.config.h ; fi ; done
+# for i in fll_error fll_execute fll_file fll_fss fll_print fll_program ; do if [[ -f build/disable/level_2/$i.h ]] ; then echo >> build/stand_alone/fake.config.h && cat build/disable/level_2/$i.h >> build/stand_alone/fake.config.h ; fi ; done
 
 Then compile the stand alone build and comment out each disable causing a compile failure until compilation succeeds.
index 9b3ed8faffef3eafb19cf68577fb3a56d9a04b73..d1c2f9756241ba1357af98c6755947b153f0ad50 100644 (file)
@@ -1,17 +1,9 @@
 #define _di_f_fss_apply_delimit_
 #define _di_f_fss_apply_delimit_range_
-#define _di_f_fss_commentss_t_
-#define _di_f_fss_comments_t_
-#define _di_f_fss_comment_t_
 #define _di_f_fss_complete_e_
-#define _di_f_fss_contents_t_
-#define _di_f_fss_content_t_
 #define _di_f_fss_count_lines_
 #define _di_f_fss_count_lines_range_
 #define _di_f_fss_default_d_
-#define _di_f_fss_delimitss_t_
-#define _di_f_fss_delimits_t_
-#define _di_f_fss_delimit_t_
 #define _di_f_fss_e_
 #define _di_f_fss_fail_utf_
 #define _di_f_fss_fail_utf_to_false_
@@ -56,8 +48,6 @@
 #define _di_f_fss_nests_resize_
 #define _di_f_fss_nests_t_
 #define _di_f_fss_nest_t_
-#define _di_f_fss_objects_t_
-#define _di_f_fss_object_t_
 #define _di_f_fss_payload_s_
 #define _di_f_fss_placeholder_s_
 #define _di_f_fss_quote_type_e_
 #define _di_f_fss_sets_resize_
 #define _di_f_fss_sets_t_
 #define _di_f_fss_set_t_
+#define _di_f_fss_simple_packet_d_
+#define _di_f_fss_simple_packet_identify_
+#define _di_f_fss_simple_packet_ranges_adjust_
+#define _di_f_fss_simple_packet_ranges_decimate_by_
+#define _di_f_fss_simple_packet_ranges_decrease_by_
+#define _di_f_fss_simple_packet_ranges_increase_
+#define _di_f_fss_simple_packet_ranges_increase_by_
+#define _di_f_fss_simple_packet_ranges_resize_
+#define _di_f_fss_simple_packet_ranges_t_
+#define _di_f_fss_simple_packet_range_t_
 #define _di_f_fss_skip_past_delimit_
 #define _di_f_fss_skip_past_space_
 #define _di_f_fss_state_flag_e_
index a7cfcc9bce3627a7d5537fa1920cf2fdcf1272fd..2125c2989a09a7dc1d0018ca15dd838d4976f44c 100644 (file)
@@ -44,7 +44,8 @@ build_sources_library directory.c directory/common.c directory/type.c private-di
 build_sources_library environment.c
 build_sources_library execute.c
 build_sources_library file.c private-file.c file/common.c file/stream.c
-build_sources_library fss.c private-fss.c fss/common.c fss/named.c fss/nest.c fss/set.c
+build_sources_library fss.c fss/common.c fss/item.c fss/named.c fss/nest.c fss/quote.c fss/set.c fss/set_quote.c fss/simple_packet.c
+build_sources_library fss/private-item.c fss/private-named.c fss/private-nest.c fss/private-set.c fss/private-set_quote.c fss/private-simple_packet.c
 build_sources_library iki.c iki/common.c iki/data.c private-iki.c iki/private-data.c
 build_sources_library limit.c limit/set.c limit/value.c limit/private-set.c limit/private-value.c
 build_sources_library memory.c private-memory.c memory/structure.c
@@ -102,7 +103,7 @@ build_sources_headers directory.h directory/common.h directory/type.h
 build_sources_headers environment.h environment/common.h
 build_sources_headers execute.h execute/common.h
 build_sources_headers file.h file/common.h file/stream.h
-build_sources_headers fss.h fss/comment.h fss/common.h fss/delimit.h fss/named.h fss/nest.h fss/quote.h fss/set.h
+build_sources_headers fss.h fss/common.h fss/item.h fss/named.h fss/nest.h fss/quote.h fss/set.h fss/set_quote.h fss/simple_packet.h
 build_sources_headers iki.h iki/common.h iki/data.h
 build_sources_headers limit.h limit/set.h limit/value.h
 build_sources_headers memory.h memory/structure.h memory/common.h
index 905ebafc513409e48aeb6f4b0dd49e0357305df8..01034ce6bfb69a8ccdbb797ba574a20314cd635e 100644 (file)
@@ -44,7 +44,8 @@ build_sources_library level_0/directory.c level_0/directory/common.c level_0/dir
 build_sources_library level_0/environment.c
 build_sources_library level_0/execute.c
 build_sources_library level_0/file.c level_0/private-file.c level_0/file/common.c level_0/file/stream.c
-build_sources_library level_0/fss.c level_0/private-fss.c level_0/fss/common.c level_0/fss/named.c level_0/fss/nest.c level_0/fss/set.c
+build_sources_library level_0/fss.c level_0/fss/common.c level_0/fss/item.c level_0/fss/named.c level_0/fss/nest.c level_0/fss/quote.c level_0/fss/set.c level_0/fss/set_quote.c level_0/fss/simple_packet.c
+build_sources_library level_0/fss/private-item.c level_0/fss/private-named.c level_0/fss/private-nest.c level_0/fss/private-set.c level_0/fss/private-set_quote.c level_0/fss/private-simple_packet.c
 build_sources_library level_0/iki.c level_0/iki/common.c level_0/iki/data.c level_0/private-iki.c level_0/iki/private-data.c
 build_sources_library level_0/limit.c level_0/limit/set.c level_0/limit/value.c level_0/limit/private-set.c level_0/limit/private-value.c
 build_sources_library level_0/memory.c level_0/private-memory.c level_0/memory/structure.c
@@ -124,7 +125,7 @@ build_sources_headers level_0/directory.h level_0/directory/common.h level_0/dir
 build_sources_headers level_0/environment.h level_0/environment/common.h
 build_sources_headers level_0/execute.h level_0/execute/common.h
 build_sources_headers level_0/file.h level_0/file/common.h level_0/file/stream.h
-build_sources_headers level_0/fss.h level_0/fss/comment.h level_0/fss/common.h level_0/fss/delimit.h level_0/fss/named.h level_0/fss/nest.h level_0/fss/quote.h level_0/fss/set.h
+build_sources_headers level_0/fss.h level_0/fss/common.h level_0/fss/item.h level_0/fss/named.h level_0/fss/nest.h level_0/fss/quote.h level_0/fss/set.h level_0/fss/set_quote.h level_0/fss/simple_packet.h
 build_sources_headers level_0/iki.h level_0/iki/common.h level_0/iki/data.h
 build_sources_headers level_0/limit.h level_0/limit/set.h level_0/limit/value.h
 build_sources_headers level_0/memory.h level_0/memory/structure.h level_0/memory/common.h
index ecc942aabba2b1a79fc102cccde058994d23f42a..31430571aaaa81d721fe41fd0e2e8f82f58c0042 100644 (file)
 
 //#define _di_f_fss_apply_delimit_
 #define _di_f_fss_apply_delimit_range_
-#define _di_f_fss_commentss_t_
-//#define _di_f_fss_comments_t_
-//#define _di_f_fss_comment_t_
 #define _di_f_fss_complete_e_
-//#define _di_f_fss_contents_t_
-//#define _di_f_fss_content_t_
 //#define _di_f_fss_count_lines_
 #define _di_f_fss_count_lines_range_
 //#define _di_f_fss_default_d_
-#define _di_f_fss_delimitss_t_
-//#define _di_f_fss_delimits_t_
-//#define _di_f_fss_delimit_t_
 #define _di_f_fss_e_
 //#define _di_f_fss_fail_utf_
 //#define _di_f_fss_fail_utf_to_false_
 #define _di_f_fss_nests_resize_
 #define _di_f_fss_nests_t_
 #define _di_f_fss_nest_t_
-//#define _di_f_fss_objects_t_
-//#define _di_f_fss_object_t_
 #define _di_f_fss_payload_s_
 //#define _di_f_fss_placeholder_s_
 //#define _di_f_fss_quote_type_e_
 #define _di_f_fss_sets_resize_
 #define _di_f_fss_sets_t_
 //#define _di_f_fss_set_t_
+#define _di_f_fss_simple_packet_d_
+#define _di_f_fss_simple_packet_identify_
+#define _di_f_fss_simple_packet_ranges_adjust_
+#define _di_f_fss_simple_packet_ranges_decimate_by_
+#define _di_f_fss_simple_packet_ranges_decrease_by_
+#define _di_f_fss_simple_packet_ranges_increase_
+#define _di_f_fss_simple_packet_ranges_increase_by_
+#define _di_f_fss_simple_packet_ranges_resize_
+#define _di_f_fss_simple_packet_ranges_t_
+#define _di_f_fss_simple_packet_range_t_
 //#define _di_f_fss_skip_past_delimit_
 //#define _di_f_fss_skip_past_space_
 //#define _di_f_fss_state_flag_e_
 //#define _di_f_pipe_input_exists_
 #define _di_f_pipe_output_exists_
 
+//#define _di_f_poll_e_
 #define _di_f_polls_adjust_
 #define _di_f_polls_append_
 #define _di_f_polls_append_all_
 #define _di_f_pollss_resize_
 #define _di_f_pollss_t_
 #define _di_f_polls_t_
-//#define _di_f_poll_e_
 //#define _di_f_poll_t_
 //#define _di_f_print_
 #define _di_f_print_character_
 #define _di_f_print_dynamic_to_raw_
 #define _di_f_print_except_
 #define _di_f_print_except_dynamic_
-#define _di_f_print_except_dynamic_in_safely_
 #define _di_f_print_except_dynamic_partial_
 #define _di_f_print_except_dynamic_partial_raw_
 #define _di_f_print_except_dynamic_partial_raw_safely_
index 56fa4e4898d5f118f40756f66508a4b83cfc171b..972b5a5e63d591c0f909ef8bb560547cf249b8bf 100644 (file)
@@ -42,7 +42,8 @@ build_sources_program fll/level_0/directory.c fll/level_0/directory/common.c fll
 build_sources_program fll/level_0/environment.c
 build_sources_program fll/level_0/execute.c
 build_sources_program fll/level_0/file.c fll/level_0/private-file.c fll/level_0/file/common.c fll/level_0/file/stream.c
-build_sources_program fll/level_0/fss.c fll/level_0/private-fss.c fll/level_0/fss/common.c fll/level_0/fss/named.c fll/level_0/fss/nest.c fll/level_0/fss/set.c
+build_sources_program fll/level_0/fss.c fll/level_0/fss/common.c fll/level_0/fss/item.c fll/level_0/fss/named.c fll/level_0/fss/nest.c fll/level_0/fss/quote.c fll/level_0/fss/set.c fll/level_0/fss/set_quote.c fll/level_0/fss/simple_packet.c
+build_sources_program fll/level_0/fss/private-item.c fll/level_0/fss/private-named.c fll/level_0/fss/private-nest.c fll/level_0/fss/private-set.c fll/level_0/fss/private-set_quote.c fll/level_0/fss/private-simple_packet.c
 build_sources_program fll/level_0/iki.c fll/level_0/private-iki.c fll/level_0/iki/common.c fll/level_0/iki/private-data.c fll/level_0/iki/data.c
 build_sources_program fll/level_0/limit.c fll/level_0/limit/set.c fll/level_0/limit/value.c fll/level_0/limit/private-set.c fll/level_0/limit/private-value.c
 build_sources_program fll/level_0/memory.c fll/level_0/private-memory.c fll/level_0/memory/structure.c
index b6e31fc23b7fd6b8f3b54bc23e872820d05978ca..cf861c67f44a36ee278ca41627e8e855a28c8932 100644 (file)
@@ -1,12 +1,11 @@
 #include "fss.h"
-#include "private-fss.h"
 
 #ifdef __cplusplus
 extern "C" {
 #endif
 
 #ifndef _di_f_fss_apply_delimit_
-  void f_fss_apply_delimit(const f_fss_delimits_t delimits, f_string_static_t * const buffer, f_state_t * const state) {
+  void f_fss_apply_delimit(const f_number_unsigneds_t delimits, f_string_static_t * const buffer, f_state_t * const state) {
     #ifndef _di_level_0_parameter_checking_
       if (!state) return;
 
@@ -35,7 +34,7 @@ extern "C" {
 #endif // _di_f_fss_apply_delimit_
 
 #ifndef _di_f_fss_apply_delimit_range_
-  void f_fss_apply_delimit_range(const f_fss_delimits_t delimits, const f_string_range_t range, f_string_static_t * const buffer, f_state_t * const state) {
+  void f_fss_apply_delimit_range(const f_number_unsigneds_t delimits, const f_string_range_t range, f_string_static_t * const buffer, f_state_t * const state) {
     #ifndef _di_level_0_parameter_checking_
       if (!state) return;
 
index 18424a4a4f413a49ca227f30d4dba87d0dcc3016..1ac6cd3a71fdf3df428d8e75148084b6b9d205de 100644 (file)
 #include <fll/level_0/utf.h>
 
 // FLL-0 fss includes.
-#include <fll/level_0/fss/comment.h>
 #include <fll/level_0/fss/common.h>
-#include <fll/level_0/fss/delimit.h>
-#include <fll/level_0/fss/quote.h>
+#include <fll/level_0/fss/item.h>
 #include <fll/level_0/fss/named.h>
 #include <fll/level_0/fss/nest.h>
+#include <fll/level_0/fss/quote.h>
 #include <fll/level_0/fss/set.h>
+#include <fll/level_0/fss/set_quote.h>
+#include <fll/level_0/fss/simple_packet.h>
 
 #ifdef __cplusplus
 extern "C" {
@@ -53,7 +54,7 @@ extern "C" {
  *     F_parameter (with error bit) if a parameter is invalid.
  */
 #ifndef _di_f_fss_apply_delimit_
-  extern void f_fss_apply_delimit(const f_fss_delimits_t delimits, f_string_static_t * const buffer, f_state_t * const state);
+  extern void f_fss_apply_delimit(const f_number_unsigneds_t delimits, f_string_static_t * const buffer, f_state_t * const state);
 #endif // _di_f_fss_apply_delimit_
 
 /**
@@ -77,7 +78,7 @@ extern "C" {
  *     F_parameter (with error bit) if a parameter is invalid.
  */
 #ifndef _di_f_fss_apply_delimit_range_
-  extern void f_fss_apply_delimit_range(const f_fss_delimits_t delimits, const f_string_range_t range, f_string_static_t * const buffer, f_state_t * const state);
+  extern void f_fss_apply_delimit_range(const f_number_unsigneds_t delimits, const f_string_range_t range, f_string_static_t * const buffer, f_state_t * const state);
 #endif // _di_f_fss_apply_delimit_range_
 
 /**
diff --git a/level_0/f_fss/c/fss/comment.h b/level_0/f_fss/c/fss/comment.h
deleted file mode 100644 (file)
index 794716c..0000000
+++ /dev/null
@@ -1,94 +0,0 @@
-/**
- * FLL - Level 0
- *
- * Project: FSS
- * API Version: 0.7
- * Licenses: lgpl-2.1-or-later
- *
- * Defines set data to be used for/by project fss.
- *
- * This is auto-included by fss.h and should not need to be explicitly included.
- */
-#ifndef _F_fss_comment_h
-#define _F_fss_comment_h
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-/**
- * Designate an fss comment location.
- */
-#ifndef _di_f_fss_comment_t_
-  typedef f_string_range_t f_fss_comment_t;
-
-  #define f_fss_comment_t_initialize f_string_range_t_initialize
-
-  #define macro_f_fss_comment_t_initialize_1(length) macro_f_string_range_t_initialize_2(length)
-
-  #define macro_f_fss_comment_t_clear(comment) macro_f_string_range_t_clear(comment)
-#endif // _di_f_fss_comment_t_
-
-/**
- * An array of f_fss_comment_t.
- *
- * array: The array of fss quote.
- * size:  Total amount of allocated space.
- * used:  Total number of allocated spaces used.
- */
-#ifndef _di_f_fss_comments_t_
-  typedef f_string_ranges_t f_fss_comments_t;
-
-  #define f_fss_comments_t_initialize f_string_ranges_t_initialize
-
-  #define macro_f_fss_comments_t_initialize_1(array, size, used) macro_f_string_ranges_t_initialize_1(array, size, used)
-  #define macro_f_fss_comments_t_initialize_2(array, length)     macro_f_string_ranges_t_initialize_2(array, length)
-
-  #define f_fss_comments_t_clear(comments) macro_f_string_ranges_t_clear(comments)
-
-  #define macro_f_fss_comments_t_resize(status, comments, length) macro_f_string_ranges_t_resize(status, comments, length)
-  #define macro_f_fss_comments_t_adjust(status, comments, length) macro_f_string_ranges_t_adjust(status, comments, length)
-
-  #define macro_f_fss_comments_t_delete_simple(comments)  macro_f_string_ranges_t_delete_simple(comments)
-  #define macro_f_fss_comments_t_destroy_simple(comments) macro_f_string_ranges_t_destroy_simple(comments)
-
-  #define macro_f_fss_comments_t_increase(status, step, comments)      macro_f_string_ranges_t_increase(status, step, comments)
-  #define macro_f_fss_comments_t_increase_by(status, comments, amount) macro_f_string_ranges_t_increase_by(status, comments, amount)
-  #define macro_f_fss_comments_t_decrease_by(status, comments, amount) macro_f_string_ranges_t_decrease_by(status, comments, amount)
-  #define macro_f_fss_comments_t_decimate_by(status, comments, amount) macro_f_string_ranges_t_decimate_by(status, comments, amount)
-#endif // _di_f_fss_comments_t_
-
-/**
- * An array of f_fss_comments_t.
- *
- * array: The array of fss quotes.
- * size:  Total amount of allocated space.
- * used:  Total number of allocated spaces used.
- */
-#ifndef _di_f_fss_commentss_t_
-  typedef f_string_rangess_t f_fss_commentss_t;
-
-  #define f_fss_commentss_t_initialize f_string_rangess_t_initialize
-
-  #define macro_f_fss_commentss_t_initialize_1(array, size, used) macro_f_string_rangess_t_initialize_1(array, size, used)
-  #define macro_f_fss_commentss_t_initialize_2(array, length)     macro_f_string_rangess_t_initialize_2(array, length)
-
-  #define macro_f_fss_commentss_t_clear(commentss) macro_f_string_rangess_t_clear(commentss)
-
-  #define macro_f_fss_commentss_t_resize(status, commentss, length) macro_f_string_rangess_t_resize(status, commentss, length)
-  #define macro_f_fss_commentss_t_adjust(status, commentss, length) macro_f_string_rangess_t_adjust(status, commentss, length)
-
-  #define macro_f_fss_commentss_t_delete_simple(commentss)  macro_f_string_rangess_t_delete_simple(commentss)
-  #define macro_f_fss_commentss_t_destroy_simple(commentss) macro_f_string_rangess_t_destroy_simple(commentss)
-
-  #define macro_f_fss_commentss_t_increase(status, step, commentss)      macro_f_string_rangess_t_increase(status, step, commentss)
-  #define macro_f_fss_commentss_t_increase_by(status, commentss, amount) macro_f_string_rangess_t_increase_by(status, commentss, amount)
-  #define macro_f_fss_commentss_t_decrease_by(status, commentss, amount) macro_f_string_rangess_t_decrease_by(status, commentss, amount)
-  #define macro_f_fss_commentss_t_decimate_by(status, commentss, amount) macro_f_string_rangess_t_decimate_by(status, commentss, amount)
-#endif // _di_f_fss_commentss_t_
-
-#ifdef __cplusplus
-} // extern "C"
-#endif
-
-#endif // _F_fss_comment_h
index 604b65817cbb905b323828d9583d3e5038816efa..f212755f1487eb4d25079e49b28b1bab6e2a7d98 100644 (file)
@@ -257,108 +257,6 @@ enum {
 #endif // _di_f_fss_default_d_
 
 /**
- * This is a range that represents an object.
- */
-#ifndef _di_f_fss_object_t_
-  typedef f_string_range_t f_fss_object_t;
-
-  #define f_fss_object_t_initialize f_string_range_t_initialize
-
-  #define macro_f_fss_object_t_initialize_1(length) macro_f_string_range_t_initialize_2(length)
-
-  #define macro_f_fss_object_t_clear(object) macro_f_string_range_t_clear(object)
-#endif // _di_f_fss_object_t_
-
-/**
- * This holds an array of fss_object.
- *
- * array: The array of objects.
- * size:  Total amount of allocated space.
- * used:  Total number of allocated spaces used.
- */
-#ifndef _di_f_fss_objects_t_
-  typedef f_string_ranges_t f_fss_objects_t;
-
-  #define f_fss_objects_t_initialize f_string_ranges_t_initialize
-
-  #define macro_f_fss_objects_t_initialize_1(array, size, used) macro_f_string_ranges_t_initialize_1(array, size, used)
-  #define macro_f_fss_objects_t_initialize_2(array, length)     macro_f_string_ranges_t_initialize_2(array, length)
-
-  #define macro_f_fss_objects_t_clear(objects) macro_f_string_ranges_t_clear(objects)
-
-  #define macro_f_fss_objects_t_resize(status, objects, length) macro_f_string_ranges_t_resize(status, objects, length)
-  #define macro_f_fss_objects_t_adjust(status, objects, length) macro_f_string_ranges_t_adjust(status, objects, length)
-
-  #define macro_f_fss_objects_t_delete_simple(objects)  macro_f_string_ranges_t_delete_simple(objects)
-  #define macro_f_fss_objects_t_destroy_simple(objects) macro_f_string_ranges_t_destroy_simple(objects)
-
-  #define macro_f_fss_objects_t_increase(status, step, objects)      macro_f_string_ranges_t_increase(status, step, objects)
-  #define macro_f_fss_objects_t_increase_by(status, objects, amount) macro_f_string_ranges_t_increase_by(status, objects, amount)
-  #define macro_f_fss_objects_t_decrease_by(status, objects, amount) macro_f_string_ranges_t_decrease_by(status, objects, amount)
-  #define macro_f_fss_objects_t_decimate_by(status, objects, amount) macro_f_string_ranges_t_decimate_by(status, objects, amount)
-#endif // _di_f_fss_objects_t_
-
-/**
- * This holds an array of string ranges that represent the content.
- *
- * The very first string range will represent the first content found.
- *
- * array: The array of content.
- * size:  Total amount of allocated space.
- * used:  Total number of allocated spaces used.
- */
-#ifndef _di_f_fss_content_t_
-  typedef f_string_ranges_t f_fss_content_t;
-
-  #define f_fss_content_t_initialize f_string_ranges_t_initialize
-
-  #define macro_f_fss_content_t_initialize_1(array, size, used) macro_f_string_ranges_t_initialize_1(array, size, used)
-  #define macro_f_fss_content_t_initialize_2(array, length)     macro_f_string_ranges_t_initialize_2(array, length)
-
-  #define macro_f_fss_content_t_clear(content) macro_f_string_ranges_t_clear(content)
-
-  #define macro_f_fss_content_t_resize(status, content, length) macro_f_string_ranges_t_resize(status, content, length)
-  #define macro_f_fss_content_t_adjust(status, content, length) macro_f_string_ranges_t_adjust(status, content, length)
-
-  #define macro_f_fss_content_t_delete_simple(content)  macro_f_string_ranges_t_delete_simple(content)
-  #define macro_f_fss_content_t_destroy_simple(content) macro_f_string_ranges_t_destroy_simple(content)
-
-  #define macro_f_fss_content_t_increase(status, step, content)      macro_f_string_ranges_t_increase(status, step, content)
-  #define macro_f_fss_content_t_increase_by(status, content, amount) macro_f_string_ranges_t_increase_by(status, content, amount)
-  #define macro_f_fss_content_t_decrease_by(status, content, amount) macro_f_string_ranges_t_decrease_by(status, content, amount)
-  #define macro_f_fss_content_t_decimate_by(status, content, amount) macro_f_string_ranges_t_decimate_by(status, content, amount)
-#endif // _di_f_fss_content_t_
-
-/**
- * This holds an array of fss_content.
- *
- * array: The array of content arrays.
- * size:  Total amount of allocated space.
- * used:  Total number of allocated spaces used.
- */
-#ifndef _di_f_fss_contents_t_
-  typedef f_string_rangess_t f_fss_contents_t;
-
-  #define f_fss_contents_t_initialize f_string_rangess_t_initialize
-
-  #define macro_f_fss_contents_t_initialize_1(array, size, used) macro_f_string_rangess_t_initialize_1(array, size, used)
-  #define macro_f_fss_contents_t_initialize_2(array, length)     macro_f_string_rangess_t_initialize_2(array, length)
-
-  #define macro_f_fss_contents_t_clear(contents) macro_f_string_rangess_t_clear(contents)
-
-  #define macro_f_fss_contents_t_resize(status, contents, length) macro_f_string_rangess_t_resize(status, contents, length)
-  #define macro_f_fss_contents_t_adjust(status, contents, length) macro_f_string_rangess_t_adjust(status, contents, length)
-
-  #define macro_f_fss_contents_t_delete_simple(contents)  macro_f_string_rangess_t_delete_simple(contents)
-  #define macro_f_fss_contents_t_destroy_simple(contents) macro_f_string_rangess_t_destroy_simple(contents)
-
-  #define macro_f_fss_contents_t_increase(status, step, contents)      macro_f_string_rangess_t_increase(status, step, contents)
-  #define macro_f_fss_contents_t_increase_by(status, contents, amount) macro_f_string_rangess_t_increase_by(status, contents, amount)
-  #define macro_f_fss_contents_t_decrease_by(status, contents, amount) macro_f_string_rangess_t_decrease_by(status, contents, amount)
-  #define macro_f_fss_contents_t_decimate_by(status, contents, amount) macro_f_string_rangess_t_decimate_by(status, contents, amount)
-#endif // _di_f_fss_contents_t_
-
-/**
  * State flags associated with FSS functions.
  *
  * These flags are meant to be bitwise for the 32-bit f_state_t flag property.
diff --git a/level_0/f_fss/c/fss/delimit.c b/level_0/f_fss/c/fss/delimit.c
deleted file mode 100644 (file)
index 6ee9a40..0000000
+++ /dev/null
@@ -1,9 +0,0 @@
-#include "../fss.h"
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-#ifdef __cplusplus
-} // extern "C"
-#endif
diff --git a/level_0/f_fss/c/fss/delimit.h b/level_0/f_fss/c/fss/delimit.h
deleted file mode 100644 (file)
index 455214f..0000000
+++ /dev/null
@@ -1,92 +0,0 @@
-/**
- * FLL - Level 0
- *
- * Project: FSS
- * API Version: 0.7
- * Licenses: lgpl-2.1-or-later
- *
- * Defines set data to be used for/by project fss.
- *
- * This is auto-included by fss.h and should not need to be explicitly included.
- */
-#ifndef _F_fss_delimit_h
-#define _F_fss_delimit_h
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-/**
- * Designate an fss delimit location.
- */
-#ifndef _di_f_fss_delimit_t_
-  typedef f_number_unsigned_t f_fss_delimit_t;
-
-  #define f_fss_delimit_t_initialize f_number_unsigned_t_initialize
-
-  #define macro_f_fss_delimit_t_initialize_1(delimit) delimit
-#endif // _di_f_fss_delimit_t_
-
-/**
- * An array of f_fss_delimit_t.
- *
- * array: The array of fss quote.
- * size:  Total amount of allocated space.
- * used:  Total number of allocated spaces used.
- */
-#ifndef _di_f_fss_delimits_t_
-  typedef f_number_unsigneds_t f_fss_delimits_t;
-
-  #define f_fss_delimits_t_initialize f_number_unsigneds_t_initialize
-
-  #define macro_f_fss_delimits_t_initialize_1(array, size, used) macro_f_number_unsigneds_t_initialize_1(array, size, used)
-  #define macro_f_fss_delimits_t_initialize_2(array, length)     macro_f_number_unsigneds_t_initialize_2(array, length)
-
-  #define macro_f_fss_delimits_t_clear(delimits) macro_f_number_unsigneds_t_clear(delimits)
-
-  #define macro_f_fss_delimits_t_resize(status, delimits, length) macro_f_number_unsigneds_t_resize(status, delimits, length)
-  #define macro_f_fss_delimits_t_adjust(status, delimits, length) macro_f_number_unsigneds_t_adjust(status, delimits, length)
-
-  #define macro_f_fss_delimits_t_delete_simple(delimits)  macro_f_number_unsigneds_t_delete_simple(delimits)
-  #define macro_f_fss_delimits_t_destroy_simple(delimits) macro_f_number_unsigneds_t_destroy_simple(delimits)
-
-  #define macro_f_fss_delimits_t_increase(status, step, delimits)      macro_f_number_unsigneds_t_increase(status, step, delimits)
-  #define macro_f_fss_delimits_t_increase_by(status, delimits, amount) macro_f_number_unsigneds_t_increase_by(status, delimits, amount)
-  #define macro_f_fss_delimits_t_decrease_by(status, delimits, amount) macro_f_number_unsigneds_t_decrease_by(status, delimits, amount)
-  #define macro_f_fss_delimits_t_decimate_by(status, delimits, amount) macro_f_number_unsigneds_t_decimate_by(status, delimits, amount)
-#endif // _di_f_fss_delimits_t_
-
-/**
- * An array of f_fss_delimits_t.
- *
- * array: The array of fss quotes.
- * size:  Total amount of allocated space.
- * used:  Total number of allocated spaces used.
- */
-#ifndef _di_f_fss_delimitss_t_
-  typedef f_number_unsignedss_t f_fss_delimitss_t;
-
-  #define f_fss_delimitss_t_initialize f_number_unsignedss_t_initialize
-
-  #define macro_f_fss_delimitss_t_initialize_1(array, size, used) macro_f_number_unsignedss_t_initialize_1(array, size, used)
-  #define macro_f_fss_delimitss_t_initialize_2(array, length)     macro_f_number_unsignedss_t_initialize_2(array, length)
-
-  #define macro_f_fss_delimitss_t_clear(delimitss) macro_f_number_unsignedss_t_clear(delimitss)
-
-  #define macro_f_fss_delimitss_t_resize(status, delimitss, length) macro_f_number_unsignedss_t_resize(status, delimitss, length)
-  #define macro_f_fss_delimitss_t_adjust(status, delimitss, length) macro_f_number_unsignedss_t_adjust(status, delimitss, length)
-
-  #define macro_f_fss_delimitss_t_delete_simple(delimitss)  macro_f_number_unsignedss_t_delete_simple(delimitss)
-  #define macro_f_fss_delimitss_t_destroy_simple(delimitss) macro_f_number_unsignedss_t_destroy_simple(delimitss)
-
-  #define macro_f_fss_delimitss_t_increase(status, step, delimitss)      macro_f_number_unsignedss_t_increase(status, step, delimitss)
-  #define macro_f_fss_delimitss_t_increase_by(status, delimitss, amount) macro_f_number_unsignedss_t_increase_by(status, delimitss, amount)
-  #define macro_f_fss_delimitss_t_decrease_by(status, delimitss, amount) macro_f_number_unsignedss_t_decrease_by(status, delimitss, amount)
-  #define macro_f_fss_delimitss_t_decimate_by(status, delimitss, amount) macro_f_number_unsignedss_t_decimate_by(status, delimitss, amount)
-#endif // _di_f_fss_delimitss_t_
-
-#ifdef __cplusplus
-} // extern "C"
-#endif
-
-#endif // _F_fss_delimit_h
diff --git a/level_0/f_fss/c/fss/item.c b/level_0/f_fss/c/fss/item.c
new file mode 100644 (file)
index 0000000..ef6325c
--- /dev/null
@@ -0,0 +1,96 @@
+#include "../fss.h"
+#include "private-item.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+#ifndef _di_f_fss_items_adjust_
+  f_status_t f_fss_items_adjust(const f_number_unsigned_t length, f_fss_items_t * const items) {
+    #ifndef _di_level_0_parameter_checking_
+      if (!items) return F_status_set_error(F_parameter);
+    #endif // _di_level_0_parameter_checking_
+
+    return private_f_fss_items_adjust(length, items);
+  }
+#endif // _di_f_fss_items_adjust_
+
+#ifndef _di_f_fss_items_decimate_by_
+  f_status_t f_fss_items_decimate_by(const f_number_unsigned_t amount, f_fss_items_t * const items) {
+    #ifndef _di_level_0_parameter_checking_
+      if (!items) return F_status_set_error(F_parameter);
+    #endif // _di_level_0_parameter_checking_
+
+    if (!amount) return F_data_not;
+    if (items->size > amount) return private_f_fss_items_adjust(items->size - amount, items);
+
+    return private_f_fss_items_adjust(0, items);
+  }
+#endif // _di_f_fss_items_decimate_by_
+
+#ifndef _di_f_fss_items_decrease_by_
+  f_status_t f_fss_items_decrease_by(const f_number_unsigned_t amount, f_fss_items_t * const items) {
+    #ifndef _di_level_0_parameter_checking_
+      if (!items) return F_status_set_error(F_parameter);
+    #endif // _di_level_0_parameter_checking_
+
+    if (!amount) return F_data_not;
+    if (items->size > amount) return private_f_fss_items_resize(items->size - amount, items);
+
+    return private_f_fss_items_resize(0, items);
+  }
+#endif // _di_f_fss_items_decrease_by_
+
+#ifndef _di_f_fss_items_increase_
+  f_status_t f_fss_items_increase(const f_number_unsigned_t step, f_fss_items_t * const items) {
+    #ifndef _di_level_0_parameter_checking_
+      if (!items) return F_status_set_error(F_parameter);
+    #endif // _di_level_0_parameter_checking_
+
+    if (step && items->used + 1 > items->size) {
+      f_number_unsigned_t size = items->used + step;
+
+      if (size > F_number_t_size_unsigned_d) {
+        if (items->used + 1 > F_number_t_size_unsigned_d) return F_status_set_error(F_array_too_large);
+
+        size = F_number_t_size_unsigned_d;
+      }
+
+      return private_f_fss_items_resize(size, items);
+    }
+
+    return F_data_not;
+  }
+#endif // _di_f_fss_items_increase_
+
+#ifndef _di_f_fss_items_increase_by_
+  f_status_t f_fss_items_increase_by(const f_number_unsigned_t amount, f_fss_items_t * const items) {
+    #ifndef _di_level_0_parameter_checking_
+      if (!items) return F_status_set_error(F_parameter);
+    #endif // _di_level_0_parameter_checking_
+
+    if (!amount) return F_data_not;
+
+    if (items->used + amount > items->size) {
+      if (items->used + amount > F_number_t_size_unsigned_d) return F_status_set_error(F_array_too_large);
+
+      return private_f_fss_items_resize(items->used + amount, items);
+    }
+
+    return F_data_not;
+  }
+#endif // _di_f_fss_items_increase_by_
+
+#ifndef _di_f_fss_items_resize_
+  f_status_t f_fss_items_resize(const f_number_unsigned_t length, f_fss_items_t * const items) {
+    #ifndef _di_level_0_parameter_checking_
+      if (!items) return F_status_set_error(F_parameter);
+    #endif // _di_level_0_parameter_checking_
+
+    return private_f_fss_items_resize(length, items);
+  }
+#endif // _di_f_fss_items_resize_
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
diff --git a/level_0/f_fss/c/fss/item.h b/level_0/f_fss/c/fss/item.h
new file mode 100644 (file)
index 0000000..9f4b58c
--- /dev/null
@@ -0,0 +1,253 @@
+/**
+ * FLL - Level 0
+ *
+ * Project: FSS
+ * API Version: 0.7
+ * Licenses: lgpl-2.1-or-later
+ *
+ * Defines nest data to be used for/by project fss.
+ *
+ * This is auto-included by fss.h and should not need to be explicitly included.
+ */
+#ifndef _F_fss_item_h
+#define _F_fss_item_h
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+/**
+ * This holds a item object and its associated content.
+ *
+ * Child content represents content nested within some other content and never represents the top-most content.
+ *
+ * To designate that either object or content is non-existent, set start position greater than stop position.
+ * In particular, set start to 1 and stop to 0.
+ *
+ * This does not have resize/adjust macros due to multiple things to potentially resize.
+ * Any resizing must be manually performed on each applicable property.
+ *
+ * Properties:
+ *   - object:  The object.
+ *   - content: The content associated with the object.
+ *   - parent:  A location referencing a parrent object or content that this object content is nested under.
+ */
+#ifndef _di_f_fss_item_t_
+  typedef struct {
+    f_string_range_t object;
+    f_string_ranges_t content;
+
+    f_number_unsigned_t parent;
+  } f_fss_item_t;
+
+  #define f_fss_item_t_initialize { f_string_range_t_initialize, f_string_ranges_t_initialize, 0 }
+
+  #define macro_f_fss_item_t_initialize_1(object, content, parent) macro_f_number_unsigneds_t_initialize_1(object, content, parent)
+
+  #define macro_f_fss_item_t_clear(item) \
+    macro_f_string_range_t_clear(item.object); \
+    macro_f_string_ranges_t_clear(item.content); \
+    item.parent = 0;
+
+  #define macro_f_fss_item_t_resize(status, item, length) macro_f_string_ranges_t_resize(status, item.content, length)
+  #define macro_f_fss_item_t_adjust(status, item, length) macro_f_string_ranges_t_adjust(status, item.content, length)
+
+  #define macro_f_fss_item_t_delete_simple(item)  macro_f_string_ranges_t_delete_simple(item.content)
+  #define macro_f_fss_item_t_destroy_simple(item) macro_f_string_ranges_t_destroy_simple(item.content)
+
+  #define macro_f_fss_item_t_increase(status, step, item)      macro_f_string_ranges_t_increase(status, step, item.content)
+  #define macro_f_fss_item_t_increase_by(status, item, amount) macro_f_string_ranges_t_increase_by(status, item.content, amount)
+  #define macro_f_fss_item_t_decrease_by(status, item, amount) macro_f_string_ranges_t_decrease_by(status, item.content, amount)
+  #define macro_f_fss_item_t_decimate_by(status, item, amount) macro_f_string_ranges_t_decimate_by(status, item.content, amount)
+#endif // _di_f_fss_item_t_
+
+/**
+ * This holds an array of fss_item.
+ *
+ * This is designed to be used as a part of f_fss_nest_t.
+ *
+ * For example:
+ *   object {
+ *     fss_basic_content before nested content.
+ *     nested_1 {
+ *        Nested content one.
+ *     }
+ *
+ *     More content in between.
+ *
+ *     nested_2 {
+ *        Nested content two.
+ *        nested_3 {
+ *          Nested content three.
+ *        }
+ *     }
+ *
+ *     More content after.
+ *   }
+ *
+ * Properties:
+ *   - array: The array of object, their associated content, and their associated parent.
+ *   - size:  Total amount of allocated space.
+ *   - used:  Total number of allocated spaces used.
+ */
+#ifndef _di_f_fss_items_t_
+  typedef struct {
+    f_fss_item_t *array;
+
+    f_number_unsigned_t size;
+    f_number_unsigned_t used;
+  } f_fss_items_t;
+
+  #define f_fss_items_t_initialize { 0, 0, 0 }
+
+  #define macro_f_fss_items_t_initialize_1(array, size, used) { array, size, used }
+  #define macro_f_fss_items_t_initialize_2(array, length)     { array, length, length }
+
+  #define macro_f_fss_items_t_clear(items) macro_f_memory_structure_clear(items)
+
+  #define macro_f_fss_items_t_resize(status, items, length) status = f_fss_items_resize(length, &items);
+  #define macro_f_fss_items_t_adjust(status, items, length) status = f_fss_items_adjust(length, &items);
+
+  #define macro_f_fss_items_t_delete_simple(items)  f_fss_items_resize(0, &items);
+  #define macro_f_fss_items_t_destroy_simple(items) f_fss_items_adjust(0, &items);
+
+  #define macro_f_fss_items_t_increase(status, step, items)      status = f_fss_items_increase(step, &items);
+  #define macro_f_fss_items_t_increase_by(status, items, amount) status = f_fss_items_increase_by(amount, &items);
+  #define macro_f_fss_items_t_decrease_by(status, items, amount) status = f_fss_items_decrease_by(amount, &items);
+  #define macro_f_fss_items_t_decimate_by(status, items, amount) status = f_fss_items_decimate_by(amount, &items);
+#endif // _di_f_fss_items_t_
+
+/**
+ * Resize the nest array.
+ *
+ * @param length
+ *   The new size to use.
+ * @param items
+ *   The items array to resize.
+ *
+ * @return
+ *   F_none on success.
+ *
+ *   F_memory_not (with error bit) on out of memory.
+ *   F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_fss_items_adjust_
+  extern f_status_t f_fss_items_adjust(const f_number_unsigned_t length, f_fss_items_t * const items);
+#endif // _di_f_fss_items_adjust_
+
+/**
+ * Resize the nest array to a smaller size.
+ *
+ * This will resize making the array smaller based on (size - given length).
+ * If the given length is too small, then the resize will fail.
+ * This will not shrink the size to less than 0.
+ *
+ * @param amount
+ *   A positive number representing how much to decimate the size by.
+ * @param items
+ *   The items array to resize.
+ *
+ * @return
+ *   F_none on success.
+ *   F_data_not if amount is 0.
+ *
+ *   F_memory_not (with error bit) on out of memory.
+ *   F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_fss_items_decimate_by_
+  extern f_status_t f_fss_items_decimate_by(const f_number_unsigned_t amount, f_fss_items_t * const items);
+#endif // _di_f_fss_items_decimate_by_
+
+/**
+ * Resize the nest array to a smaller size.
+ *
+ * This will resize making the array smaller based on (size - given length).
+ * If the given length is too small, then the resize will fail.
+ * This will not shrink the size to less than 0.
+ *
+ * @param amount
+ *   A positive number representing how much to decrease the size by.
+ * @param items
+ *   The items array to resize.
+ *
+ * @return
+ *   F_none on success.
+ *
+ *   F_memory_not (with error bit) on out of memory.
+ *   F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_fss_items_decrease_by_
+  extern f_status_t f_fss_items_decrease_by(const f_number_unsigned_t amount, f_fss_items_t * const items);
+#endif // _di_f_fss_items_decrease_by_
+
+/**
+ * Increase the size of the items array, but only if necessary.
+ *
+ * If the given length is too large for the buffer, then attempt to set max buffer size (F_number_t_size_unsigned_d).
+ * If already set to the maximum buffer size, then the resize will fail.
+ *
+ * @param step
+ *   The allocation step to use.
+ *   Must be greater than 0.
+ * @param items
+ *   The items array to resize.
+ *
+ * @return
+ *   F_none on success.
+ *   F_data_not on success, but there is no reason to increase size (used + 1 <= size).
+ *
+ *   F_array_too_large (with error bit) if the new array length is too large.
+ *   F_memory_not (with error bit) on out of memory.
+ *   F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_fss_items_increase_
+  extern f_status_t f_fss_items_increase(const f_number_unsigned_t step, f_fss_items_t * const items);
+#endif // _di_f_fss_items_increase_
+
+/**
+ * Resize the items array to a larger size.
+ *
+ * This will resize making the array larger based on the given length.
+ * If the given length is too large for the buffer, then attempt to set max buffer size (F_number_t_size_unsigned_d).
+ * If already set to the maximum buffer size, then the resize will fail.
+ *
+ * @param amount
+ *   A positive number representing how much to increase the size by.
+ * @param items
+ *   The items array to resize.
+ *
+ * @return
+ *   F_none on success.
+ *   F_data_not on success, but there is no reason to increase size (used + amount <= size).
+ *
+ *   F_memory_not (with error bit) on out of memory.
+ *   F_parameter (with error bit) if a parameter is invalid.
+ *   F_array_too_large (with error bit) if the new array length is too large.
+ */
+#ifndef _di_f_fss_items_increase_by_
+  extern f_status_t f_fss_items_increase_by(const f_number_unsigned_t amount, f_fss_items_t * const items);
+#endif // _di_f_fss_items_increase_by_
+
+/**
+ * Resize the items array.
+ *
+ * @param length
+ *   The new size to use.
+ * @param items
+ *   The items array to adjust.
+ *
+ * @return
+ *   F_none on success.
+ *
+ *   F_memory_not (with error bit) on out of memory.
+ *   F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_fss_items_resize_
+  extern f_status_t f_fss_items_resize(const f_number_unsigned_t length, f_fss_items_t * const items);
+#endif // _di_f_fss_items_resize_
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
+
+#endif // _F_fss_item_h
index e13eee9a7dc8e0aaadafa8ebe685241fe9824fed..86f81a354e1031498f52cfd3dab9abe62b3e0c0e 100644 (file)
@@ -1,5 +1,5 @@
 #include "../fss.h"
-#include "../private-fss.h"
+#include "private-named.h"
 
 #ifdef __cplusplus
 extern "C" {
@@ -22,10 +22,7 @@ extern "C" {
     #endif // _di_level_0_parameter_checking_
 
     if (!amount) return F_data_not;
-
-    if (named->objects.size - amount > 0) {
-      return private_f_fss_named_adjust(named->objects.size - amount, named);
-    }
+    if (named->objects.size - amount > 0) return private_f_fss_named_adjust(named->objects.size - amount, named);
 
     return private_f_fss_named_adjust(0, named);
   }
@@ -38,10 +35,7 @@ extern "C" {
     #endif // _di_level_0_parameter_checking_
 
     if (!amount) return F_data_not;
-
-    if (named->objects.size - amount > 0) {
-      return private_f_fss_named_resize(named->objects.size - amount, named);
-    }
+    if (named->objects.size - amount > 0) return private_f_fss_named_resize(named->objects.size - amount, named);
 
     return private_f_fss_named_resize(0, named);
   }
@@ -57,9 +51,7 @@ extern "C" {
       f_number_unsigned_t size = named->objects.used + step;
 
       if (size > F_number_t_size_unsigned_d) {
-        if (named->objects.used + 1 > F_number_t_size_unsigned_d) {
-          return F_status_set_error(F_array_too_large);
-        }
+        if (named->objects.used + 1 > F_number_t_size_unsigned_d) return F_status_set_error(F_array_too_large);
 
         size = F_number_t_size_unsigned_d;
       }
@@ -80,9 +72,7 @@ extern "C" {
     if (!amount) return F_data_not;
 
     if (named->objects.used + amount > named->objects.size) {
-      if (named->objects.used + amount > F_number_t_size_unsigned_d) {
-        return F_status_set_error(F_array_too_large);
-      }
+      if (named->objects.used + amount > F_number_t_size_unsigned_d) return F_status_set_error(F_array_too_large);
 
       return private_f_fss_named_resize(named->objects.used + amount, named);
     }
@@ -118,10 +108,7 @@ extern "C" {
     #endif // _di_level_0_parameter_checking_
 
     if (!amount) return F_data_not;
-
-    if (nameds->size > amount) {
-      return private_f_fss_nameds_adjust(nameds->size - amount, nameds);
-    }
+    if (nameds->size > amount) return private_f_fss_nameds_adjust(nameds->size - amount, nameds);
 
     return private_f_fss_nameds_adjust(0, nameds);
   }
@@ -134,10 +121,7 @@ extern "C" {
     #endif // _di_level_0_parameter_checking_
 
     if (!amount) return F_data_not;
-
-    if (nameds->size > amount) {
-      return private_f_fss_nameds_resize(nameds->size - amount, nameds);
-    }
+    if (nameds->size > amount) return private_f_fss_nameds_resize(nameds->size - amount, nameds);
 
     return private_f_fss_nameds_resize(0, nameds);
   }
@@ -153,9 +137,7 @@ extern "C" {
       f_number_unsigned_t size = nameds->used + step;
 
       if (size > F_number_t_size_unsigned_d) {
-        if (nameds->used + 1 > F_number_t_size_unsigned_d) {
-          return F_status_set_error(F_array_too_large);
-        }
+        if (nameds->used + 1 > F_number_t_size_unsigned_d) return F_status_set_error(F_array_too_large);
 
         size = F_number_t_size_unsigned_d;
       }
@@ -176,9 +158,7 @@ extern "C" {
     if (!amount) return F_data_not;
 
     if (nameds->used + amount > nameds->size) {
-      if (nameds->used + amount > F_number_t_size_unsigned_d) {
-        return F_status_set_error(F_array_too_large);
-      }
+      if (nameds->used + amount > F_number_t_size_unsigned_d) return F_status_set_error(F_array_too_large);
 
       return private_f_fss_nameds_resize(nameds->used + amount, nameds);
     }
index 4a945974e1afd77f61cfe1bd303d8ac4a8c955bd..fbd9da62f1835f4477e119bbd766837683c1ce88 100644 (file)
@@ -30,21 +30,21 @@ extern "C" {
  */
 #ifndef _di_f_fss_named_t_
   typedef struct {
-    f_fss_object_t name;
+    f_string_range_t name;
 
-    f_fss_objects_t objects;
-    f_fss_contents_t contents;
+    f_string_ranges_t objects;
+    f_string_rangess_t contents;
     f_uint8ss_t quotess;
   } f_fss_named_t;
 
-  #define f_fss_named_t_initialize { f_fss_object_t_initialize, f_fss_objects_t_initialize, f_fss_contents_t_initialize, f_uint8ss_t_initialize }
+  #define f_fss_named_t_initialize { f_string_range_t_initialize, f_string_ranges_t_initialize, f_string_rangess_t_initialize, f_uint8ss_t_initialize }
 
   #define macro_f_fss_named_t_initialize_1(name, objects, contents, quotess) macro_f_number_unsigneds_t_initialize_1(name, objects, contents, quotess)
 
   #define macro_f_fss_named_t_clear(named) \
-    macro_f_fss_object_t_clear(named.name) \
-    macro_f_fss_objects_t_clear(named.objects) \
-    macro_f_fss_contents_t_clear(named.contents) \
+    macro_f_string_range_t_clear(named.name) \
+    macro_f_string_ranges_t_clear(named.objects) \
+    macro_f_string_rangess_t_clear(named.contents) \
     macro_f_uint8ss_t_clear(named.quotess)
 
   #define macro_f_fss_named_t_resize(status, named, length) status = f_fss_named_resize(length, &named);
index eebc1d9efee06e2bf711f69f6acc7c4688606368..973e122f178a385856a1d97e37d627bcf73961ce 100644 (file)
 #include "../fss.h"
-#include "../private-fss.h"
+#include "private-item.h"
+#include "private-nest.h"
 
 #ifdef __cplusplus
 extern "C" {
 #endif
 
-#ifndef _di_f_fss_items_adjust_
-  f_status_t f_fss_items_adjust(const f_number_unsigned_t length, f_fss_items_t * const items) {
-    #ifndef _di_level_0_parameter_checking_
-      if (!items) return F_status_set_error(F_parameter);
-    #endif // _di_level_0_parameter_checking_
-
-    return private_f_fss_items_adjust(length, items);
-  }
-#endif // _di_f_fss_items_adjust_
-
-#ifndef _di_f_fss_items_decimate_by_
-  f_status_t f_fss_items_decimate_by(const f_number_unsigned_t amount, f_fss_items_t * const items) {
-    #ifndef _di_level_0_parameter_checking_
-      if (!items) return F_status_set_error(F_parameter);
-    #endif // _di_level_0_parameter_checking_
-
-    if (!amount) return F_data_not;
-
-    if (items->size > amount) {
-      return private_f_fss_items_adjust(items->size - amount, items);
-    }
-
-    return private_f_fss_items_adjust(0, items);
-  }
-#endif // _di_f_fss_items_decimate_by_
-
-#ifndef _di_f_fss_items_decrease_by_
-  f_status_t f_fss_items_decrease_by(const f_number_unsigned_t amount, f_fss_items_t * const items) {
-    #ifndef _di_level_0_parameter_checking_
-      if (!items) return F_status_set_error(F_parameter);
-    #endif // _di_level_0_parameter_checking_
-
-    if (!amount) return F_data_not;
-
-    if (items->size > amount) {
-      return private_f_fss_items_resize(items->size - amount, items);
-    }
-
-    return private_f_fss_items_resize(0, items);
-  }
-#endif // _di_f_fss_items_decrease_by_
-
-#ifndef _di_f_fss_items_increase_
-  f_status_t f_fss_items_increase(const f_number_unsigned_t step, f_fss_items_t * const items) {
-    #ifndef _di_level_0_parameter_checking_
-      if (!items) return F_status_set_error(F_parameter);
-    #endif // _di_level_0_parameter_checking_
-
-    if (step && items->used + 1 > items->size) {
-      f_number_unsigned_t size = items->used + step;
-
-      if (size > F_number_t_size_unsigned_d) {
-        if (items->used + 1 > F_number_t_size_unsigned_d) {
-          return F_status_set_error(F_array_too_large);
-        }
-
-        size = F_number_t_size_unsigned_d;
-      }
-
-      return private_f_fss_items_resize(size, items);
-    }
-
-    return F_data_not;
-  }
-#endif // _di_f_fss_items_increase_
-
-#ifndef _di_f_fss_items_increase_by_
-  f_status_t f_fss_items_increase_by(const f_number_unsigned_t amount, f_fss_items_t * const items) {
-    #ifndef _di_level_0_parameter_checking_
-      if (!items) return F_status_set_error(F_parameter);
-    #endif // _di_level_0_parameter_checking_
-
-    if (!amount) return F_data_not;
-
-    if (items->used + amount > items->size) {
-      if (items->used + amount > F_number_t_size_unsigned_d) {
-        return F_status_set_error(F_array_too_large);
-      }
-
-      return private_f_fss_items_resize(items->used + amount, items);
-    }
-
-    return F_data_not;
-  }
-#endif // _di_f_fss_items_increase_by_
-
-#ifndef _di_f_fss_items_resize_
-  f_status_t f_fss_items_resize(const f_number_unsigned_t length, f_fss_items_t * const items) {
-    #ifndef _di_level_0_parameter_checking_
-      if (!items) return F_status_set_error(F_parameter);
-    #endif // _di_level_0_parameter_checking_
-
-    return private_f_fss_items_resize(length, items);
-  }
-#endif // _di_f_fss_items_resize_
-
 #ifndef _di_f_fss_nest_adjust_
   f_status_t f_fss_nest_adjust(const f_number_unsigned_t length, f_fss_nest_t * const nest) {
     #ifndef _di_level_0_parameter_checking_
@@ -118,10 +23,7 @@ extern "C" {
     #endif // _di_level_0_parameter_checking_
 
     if (!amount) return F_data_not;
-
-    if (nest->size > amount) {
-      return private_f_fss_nest_adjust(nest->size - amount, nest);
-    }
+    if (nest->size > amount) return private_f_fss_nest_adjust(nest->size - amount, nest);
 
     return private_f_fss_nest_adjust(0, nest);
   }
@@ -134,10 +36,7 @@ extern "C" {
     #endif // _di_level_0_parameter_checking_
 
     if (!amount) return F_data_not;
-
-    if (nest->size > amount) {
-      return private_f_fss_nest_resize(nest->size - amount, nest);
-    }
+    if (nest->size > amount) return private_f_fss_nest_resize(nest->size - amount, nest);
 
     return private_f_fss_nest_resize(0, nest);
   }
@@ -153,9 +52,7 @@ extern "C" {
       f_number_unsigned_t size = nest->used + step;
 
       if (size > F_number_t_size_unsigned_d) {
-        if (nest->used + 1 > F_number_t_size_unsigned_d) {
-          return F_status_set_error(F_array_too_large);
-        }
+        if (nest->used + 1 > F_number_t_size_unsigned_d) return F_status_set_error(F_array_too_large);
 
         size = F_number_t_size_unsigned_d;
       }
@@ -176,9 +73,7 @@ extern "C" {
     if (!amount) return F_data_not;
 
     if (nest->used + amount > nest->size) {
-      if (nest->used + amount > F_number_t_size_unsigned_d) {
-        return F_status_set_error(F_array_too_large);
-      }
+      if (nest->used + amount > F_number_t_size_unsigned_d) return F_status_set_error(F_array_too_large);
 
       return private_f_fss_nest_resize(nest->used + amount, nest);
     }
@@ -214,10 +109,7 @@ extern "C" {
     #endif // _di_level_0_parameter_checking_
 
     if (!amount) return F_data_not;
-
-    if (nests->size > amount) {
-      return private_f_fss_nests_adjust(nests->size - amount, nests);
-    }
+    if (nests->size > amount) return private_f_fss_nests_adjust(nests->size - amount, nests);
 
     return private_f_fss_nests_adjust(0, nests);
   }
@@ -230,10 +122,7 @@ extern "C" {
     #endif // _di_level_0_parameter_checking_
 
     if (!amount) return F_data_not;
-
-    if (nests->size > amount) {
-      return private_f_fss_nests_resize(nests->size - amount, nests);
-    }
+    if (nests->size > amount) return private_f_fss_nests_resize(nests->size - amount, nests);
 
     return private_f_fss_nests_resize(0, nests);
   }
@@ -249,9 +138,7 @@ extern "C" {
       f_number_unsigned_t size = nests->used + step;
 
       if (size > F_number_t_size_unsigned_d) {
-        if (nests->used + 1 > F_number_t_size_unsigned_d) {
-          return F_status_set_error(F_array_too_large);
-        }
+        if (nests->used + 1 > F_number_t_size_unsigned_d) return F_status_set_error(F_array_too_large);
 
         size = F_number_t_size_unsigned_d;
       }
@@ -272,9 +159,7 @@ extern "C" {
     if (!amount) return F_data_not;
 
     if (nests->used + amount > nests->size) {
-      if (nests->used + amount > F_number_t_size_unsigned_d) {
-        return F_status_set_error(F_array_too_large);
-      }
+      if (nests->used + amount > F_number_t_size_unsigned_d) return F_status_set_error(F_array_too_large);
 
       return private_f_fss_nests_resize(nests->used + amount, nests);
     }
index bff95e0654c4b39abe99f57cd61d3f504f73803c..497fd8ff06bb95ed8cb60d7dac36b5c75dc8a2c7 100644 (file)
@@ -17,107 +17,6 @@ extern "C" {
 #endif
 
 /**
- * This holds a item object and its associated content.
- *
- * Child content represents content nested within some other content and never represents the top-most content.
- *
- * To designate that either object or content is non-existent, set start position greater than stop position.
- * In particular, set start to 1 and stop to 0.
- *
- * This does not have resize/adjust macros due to multiple things to potentially resize.
- * Any resizing must be manually performed on each applicable property.
- *
- * Properties:
- *   - object:  The object.
- *   - content: The content associated with the object.
- *   - parent:  A location referencing a parrent object or content that this object content is nested under.
- */
-#ifndef _di_f_fss_item_t_
-  typedef struct {
-    f_fss_object_t object;
-    f_fss_content_t content;
-
-    f_number_unsigned_t parent;
-  } f_fss_item_t;
-
-  #define f_fss_item_t_initialize { f_fss_object_t_initialize, f_fss_content_t_initialize, 0 }
-
-  #define macro_f_fss_item_t_initialize_1(object, content, parent) macro_f_number_unsigneds_t_initialize_1(object, content, parent)
-
-  #define macro_f_fss_item_t_clear(item) \
-    macro_f_fss_object_t_clear(item.object); \
-    macro_f_fss_content_t_clear(item.content); \
-    item.parent = 0;
-
-  #define macro_f_fss_item_t_resize(status, item, length) macro_f_fss_content_t_resize(status, item.content, length)
-  #define macro_f_fss_item_t_adjust(status, item, length) macro_f_fss_content_t_adjust(status, item.content, length)
-
-  #define macro_f_fss_item_t_delete_simple(item)  macro_f_fss_content_t_delete_simple(item.content)
-  #define macro_f_fss_item_t_destroy_simple(item) macro_f_fss_content_t_destroy_simple(item.content)
-
-  #define macro_f_fss_item_t_increase(status, step, item)      macro_f_fss_content_t_increase(status, step, item.content)
-  #define macro_f_fss_item_t_increase_by(status, item, amount) macro_f_fss_content_t_increase_by(status, item.content, amount)
-  #define macro_f_fss_item_t_decrease_by(status, item, amount) macro_f_fss_content_t_decrease_by(status, item.content, amount)
-  #define macro_f_fss_item_t_decimate_by(status, item, amount) macro_f_fss_content_t_decimate_by(status, item.content, amount)
-#endif // _di_f_fss_item_t_
-
-/**
- * This holds an array of fss_item.
- *
- * This is designed to be used as a part of f_fss_nest_t.
- *
- * For example:
- *   object {
- *     fss_basic_content before nested content.
- *     nested_1 {
- *        Nested content one.
- *     }
- *
- *     More content in between.
- *
- *     nested_2 {
- *        Nested content two.
- *        nested_3 {
- *          Nested content three.
- *        }
- *     }
- *
- *     More content after.
- *   }
- *
- * Properties:
- *   - array: The array of object, their associated content, and their associated parent.
- *   - size:  Total amount of allocated space.
- *   - used:  Total number of allocated spaces used.
- */
-#ifndef _di_f_fss_items_t_
-  typedef struct {
-    f_fss_item_t *array;
-
-    f_number_unsigned_t size;
-    f_number_unsigned_t used;
-  } f_fss_items_t;
-
-  #define f_fss_items_t_initialize { 0, 0, 0 }
-
-  #define macro_f_fss_items_t_initialize_1(array, size, used) { array, size, used }
-  #define macro_f_fss_items_t_initialize_2(array, length)     { array, length, length }
-
-  #define macro_f_fss_items_t_clear(items) macro_f_memory_structure_clear(items)
-
-  #define macro_f_fss_items_t_resize(status, items, length) status = f_fss_items_resize(length, &items);
-  #define macro_f_fss_items_t_adjust(status, items, length) status = f_fss_items_adjust(length, &items);
-
-  #define macro_f_fss_items_t_delete_simple(items)  f_fss_items_resize(0, &items);
-  #define macro_f_fss_items_t_destroy_simple(items) f_fss_items_adjust(0, &items);
-
-  #define macro_f_fss_items_t_increase(status, step, items)      status = f_fss_items_increase(step, &items);
-  #define macro_f_fss_items_t_increase_by(status, items, amount) status = f_fss_items_increase_by(amount, &items);
-  #define macro_f_fss_items_t_decrease_by(status, items, amount) status = f_fss_items_decrease_by(amount, &items);
-  #define macro_f_fss_items_t_decimate_by(status, items, amount) status = f_fss_items_decimate_by(amount, &items);
-#endif // _di_f_fss_items_t_
-
-/**
  * This holds an array of f_fss_items_t.
  *
  * Each array row represents the nesting depth.
@@ -196,135 +95,6 @@ extern "C" {
  *
  * @param length
  *   The new size to use.
- * @param items
- *   The items array to resize.
- *
- * @return
- *   F_none on success.
- *
- *   F_memory_not (with error bit) on out of memory.
- *   F_parameter (with error bit) if a parameter is invalid.
- */
-#ifndef _di_f_fss_items_adjust_
-  extern f_status_t f_fss_items_adjust(const f_number_unsigned_t length, f_fss_items_t * const items);
-#endif // _di_f_fss_items_adjust_
-
-/**
- * Resize the nest array to a smaller size.
- *
- * This will resize making the array smaller based on (size - given length).
- * If the given length is too small, then the resize will fail.
- * This will not shrink the size to less than 0.
- *
- * @param amount
- *   A positive number representing how much to decimate the size by.
- * @param items
- *   The items array to resize.
- *
- * @return
- *   F_none on success.
- *   F_data_not if amount is 0.
- *
- *   F_memory_not (with error bit) on out of memory.
- *   F_parameter (with error bit) if a parameter is invalid.
- */
-#ifndef _di_f_fss_items_decimate_by_
-  extern f_status_t f_fss_items_decimate_by(const f_number_unsigned_t amount, f_fss_items_t * const items);
-#endif // _di_f_fss_items_decimate_by_
-
-/**
- * Resize the nest array to a smaller size.
- *
- * This will resize making the array smaller based on (size - given length).
- * If the given length is too small, then the resize will fail.
- * This will not shrink the size to less than 0.
- *
- * @param amount
- *   A positive number representing how much to decrease the size by.
- * @param items
- *   The items array to resize.
- *
- * @return
- *   F_none on success.
- *
- *   F_memory_not (with error bit) on out of memory.
- *   F_parameter (with error bit) if a parameter is invalid.
- */
-#ifndef _di_f_fss_items_decrease_by_
-  extern f_status_t f_fss_items_decrease_by(const f_number_unsigned_t amount, f_fss_items_t * const items);
-#endif // _di_f_fss_items_decrease_by_
-
-/**
- * Increase the size of the items array, but only if necessary.
- *
- * If the given length is too large for the buffer, then attempt to set max buffer size (F_number_t_size_unsigned_d).
- * If already set to the maximum buffer size, then the resize will fail.
- *
- * @param step
- *   The allocation step to use.
- *   Must be greater than 0.
- * @param items
- *   The items array to resize.
- *
- * @return
- *   F_none on success.
- *   F_data_not on success, but there is no reason to increase size (used + 1 <= size).
- *
- *   F_array_too_large (with error bit) if the new array length is too large.
- *   F_memory_not (with error bit) on out of memory.
- *   F_parameter (with error bit) if a parameter is invalid.
- */
-#ifndef _di_f_fss_items_increase_
-  extern f_status_t f_fss_items_increase(const f_number_unsigned_t step, f_fss_items_t * const items);
-#endif // _di_f_fss_items_increase_
-
-/**
- * Resize the items array to a larger size.
- *
- * This will resize making the array larger based on the given length.
- * If the given length is too large for the buffer, then attempt to set max buffer size (F_number_t_size_unsigned_d).
- * If already set to the maximum buffer size, then the resize will fail.
- *
- * @param amount
- *   A positive number representing how much to increase the size by.
- * @param items
- *   The items array to resize.
- *
- * @return
- *   F_none on success.
- *   F_data_not on success, but there is no reason to increase size (used + amount <= size).
- *
- *   F_memory_not (with error bit) on out of memory.
- *   F_parameter (with error bit) if a parameter is invalid.
- *   F_array_too_large (with error bit) if the new array length is too large.
- */
-#ifndef _di_f_fss_items_increase_by_
-  extern f_status_t f_fss_items_increase_by(const f_number_unsigned_t amount, f_fss_items_t * const items);
-#endif // _di_f_fss_items_increase_by_
-
-/**
- * Resize the items array.
- *
- * @param length
- *   The new size to use.
- * @param items
- *   The items array to adjust.
- *
- * @return
- *   F_none on success.
- *
- *   F_memory_not (with error bit) on out of memory.
- *   F_parameter (with error bit) if a parameter is invalid.
- */
-#ifndef _di_f_fss_items_resize_
-  extern f_status_t f_fss_items_resize(const f_number_unsigned_t length, f_fss_items_t * const items);
-#endif // _di_f_fss_items_resize_
-
-/**
- * Resize the nest array.
- *
- * @param length
- *   The new size to use.
  * @param nest
  *   The nest array to resize.
  *
diff --git a/level_0/f_fss/c/fss/private-item.c b/level_0/f_fss/c/fss/private-item.c
new file mode 100644 (file)
index 0000000..39c8e39
--- /dev/null
@@ -0,0 +1,58 @@
+#include "../fss.h"
+#include "private-item.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+#if !defined(_di_f_fss_items_adjust_) || !defined(_di_f_fss_items_decimate_by_)
+  f_status_t private_f_fss_items_adjust(const f_number_unsigned_t length, f_fss_items_t * const items) {
+
+    f_status_t status = F_none;
+
+    for (f_number_unsigned_t i = length; i < items->size; ++i) {
+
+      status = f_string_ranges_adjust(0, &items->array[i].content);
+      if (F_status_is_error(status)) return status;
+    } // for
+
+    status = f_memory_adjust(items->size, length, sizeof(f_fss_item_t), (void **) & items->array);
+    if (F_status_is_error(status)) return status;
+
+    items->size = length;
+
+    if (items->used > items->size) {
+      items->used = length;
+    }
+
+    return F_none;
+  }
+#endif // !defined(_di_f_fss_items_adjust_) || !defined(_di_f_fss_items_decimate_by_)
+
+#if !defined(_di_f_fss_items_decrease_by_) || !defined(_di_f_fss_items_increase_) || !defined(_di_f_fss_items_increase_by_) || !defined(_di_f_fss_items_resize_)
+  f_status_t private_f_fss_items_resize(const f_number_unsigned_t length, f_fss_items_t * const items) {
+
+    f_status_t status = F_none;
+
+    for (f_number_unsigned_t i = length; i < items->size; ++i) {
+
+      status = f_string_ranges_resize(0, &items->array[i].content);
+      if (F_status_is_error(status)) return status;
+    } // for
+
+    status = f_memory_resize(items->size, length, sizeof(f_fss_item_t), (void **) & items->array);
+    if (F_status_is_error(status)) return status;
+
+    items->size = length;
+
+    if (items->used > items->size) {
+      items->used = length;
+    }
+
+    return F_none;
+  }
+#endif // !defined(_di_f_fss_items_decrease_by_) || !defined(_di_f_fss_items_increase_) || !defined(_di_f_fss_items_increase_by_) || !defined(_di_f_fss_items_resize_)
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
diff --git a/level_0/f_fss/c/fss/private-item.h b/level_0/f_fss/c/fss/private-item.h
new file mode 100644 (file)
index 0000000..1e6b7cf
--- /dev/null
@@ -0,0 +1,76 @@
+/**
+ * FLL - Level 0
+ *
+ * Project: FSS
+ * API Version: 0.7
+ * Licenses: lgpl-2.1-or-later
+ *
+ * These are provided for internal reduction in redundant code.
+ * These should not be exposed/used outside of this project.
+ */
+#ifndef _PRIVATE_F_fss_item_h
+#define _PRIVATE_F_fss_item_h
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+/**
+ * Private implementation for resizing.
+ *
+ * Intended to be shared to each of the different implementation variations.
+ *
+ * @param length
+ *   The new size to use.
+ * @param items
+ *   The items to adjust.
+ *
+ * @return
+ *   F_none on success.
+ *
+ *   Errors (with error bit) from: macro_f_fss_item_t_adjust().
+ *   Errors (with error bit) from: f_memory_adjust().
+ *
+ * @see macro_f_fss_item_t_adjust()
+ *
+ * @see f_fss_items_adjust()
+ * @see f_fss_items_decimate_by()
+ * @see f_memory_adjust()
+ */
+#if !defined(_di_f_fss_items_adjust_) || !defined(_di_f_fss_items_decimate_by_)
+  extern f_status_t private_f_fss_items_adjust(const f_number_unsigned_t length, f_fss_items_t * const items) F_attribute_visibility_internal_d;
+#endif // !defined(_di_f_fss_items_adjust_) || !defined(_di_f_fss_items_decimate_by_)
+
+/**
+ * Private implementation for resizing.
+ *
+ * Intended to be shared to each of the different implementation variations.
+ *
+ * @param length
+ *   The new size to use.
+ * @param items
+ *   The items to resize.
+ *
+ * @return
+ *   F_none on success.
+ *
+ *   Errors (with error bit) from: macro_f_fss_item_t_resize().
+ *   Errors (with error bit) from: f_memory_resize().
+ *
+ * @see macro_f_fss_item_t_resize()
+ *
+ * @see f_fss_items_decrease_by()
+ * @see f_fss_items_increase()
+ * @see f_fss_items_increase_by()
+ * @see f_fss_items_resize()
+ * @see f_memory_resize()
+ */
+#if !defined(_di_f_fss_items_decrease_by_) || !defined(_di_f_fss_items_increase_) || !defined(_di_f_fss_items_increase_by_) || !defined(_di_f_fss_items_resize_)
+  extern f_status_t private_f_fss_items_resize(const f_number_unsigned_t length, f_fss_items_t * const items) F_attribute_visibility_internal_d;
+#endif // !defined(_di_f_fss_items_decrease_by_) || !defined(_di_f_fss_items_increase_) || !defined(_di_f_fss_items_increase_by_) || !defined(_di_f_fss_items_resize_)
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
+
+#endif // _PRIVATE_F_fss_item_h
diff --git a/level_0/f_fss/c/fss/private-named.c b/level_0/f_fss/c/fss/private-named.c
new file mode 100644 (file)
index 0000000..1c3dddb
--- /dev/null
@@ -0,0 +1,90 @@
+#include "../fss.h"
+#include "private-named.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+#if !defined(_di_f_fss_nameds_adjust_) || !defined(_di_f_fss_nameds_decimate_by_)
+  f_status_t private_f_fss_named_adjust(const f_number_unsigned_t length, f_fss_named_t * const named) {
+
+    f_status_t status = f_string_ranges_adjust(length, &named->objects);
+    if (F_status_is_error(status)) return status;
+
+    status = f_string_rangess_adjust(length, &named->contents);
+    if (F_status_is_error(status)) return status;
+
+    status = f_uint8ss_adjust(length, &named->quotess);
+    if (F_status_is_error(status)) return status;
+
+    return F_none;
+  }
+#endif // !defined(_di_f_fss_nameds_adjust_) || !defined(_di_f_fss_nameds_decimate_by_)
+
+#if !defined(_di_f_fss_nameds_decrease_by_) || !defined(_di_f_fss_nameds_increase_) || !defined(_di_f_fss_nameds_increase_by_) || !defined(_di_f_fss_nameds_resize_)
+  f_status_t private_f_fss_named_resize(const f_number_unsigned_t length, f_fss_named_t * const named) {
+
+    f_status_t status = f_string_ranges_resize(length, &named->objects);
+    if (F_status_is_error(status)) return status;
+
+    status = f_string_rangess_resize(length, &named->contents);
+    if (F_status_is_error(status)) return status;
+
+    status = f_uint8ss_resize(length, &named->quotess);
+    if (F_status_is_error(status)) return status;
+
+    return F_none;
+  }
+#endif // !defined(_di_f_fss_nameds_decrease_by_) || !defined(_di_f_fss_nameds_increase_) || !defined(_di_f_fss_nameds_increase_by_) || !defined(_di_f_fss_nameds_resize_)
+
+#if !defined(_di_f_fss_nameds_adjust_) || !defined(_di_f_fss_nameds_decimate_by_)
+  f_status_t private_f_fss_nameds_adjust(const f_number_unsigned_t length, f_fss_nameds_t * const nameds) {
+
+    f_status_t status = F_none;
+
+    for (f_number_unsigned_t i = length; i < nameds->size; ++i) {
+
+      status = private_f_fss_named_adjust(0, &nameds->array[i]);
+      if (F_status_is_error(status)) return status;
+    } // for
+
+    status = f_memory_adjust(nameds->size, length, sizeof(f_fss_named_t), (void **) & nameds->array);
+    if (F_status_is_error(status)) return status;
+
+    nameds->size = length;
+
+    if (nameds->used > nameds->size) {
+      nameds->used = length;
+    }
+
+    return F_none;
+  }
+#endif // !defined(_di_f_fss_nameds_adjust_) || !defined(_di_f_fss_nameds_decimate_by_)
+
+#if !defined(_di_f_fss_nameds_decrease_by_) || !defined(_di_f_fss_nameds_increase_) || !defined(_di_f_fss_nameds_increase_by_) || !defined(_di_f_fss_nameds_resize_)
+  f_status_t private_f_fss_nameds_resize(const f_number_unsigned_t length, f_fss_nameds_t * const nameds) {
+
+    f_status_t status = F_none;
+
+    for (f_number_unsigned_t i = length; i < nameds->size; ++i) {
+
+      status = private_f_fss_named_resize(0, &nameds->array[i]);
+      if (F_status_is_error(status)) return status;
+    } // for
+
+    status = f_memory_resize(nameds->size, length, sizeof(f_fss_named_t), (void **) & nameds->array);
+    if (F_status_is_error(status)) return status;
+
+    nameds->size = length;
+
+    if (nameds->used > nameds->size) {
+      nameds->used = length;
+    }
+
+    return F_none;
+  }
+#endif // !defined(_di_f_fss_nameds_decrease_by_) || !defined(_di_f_fss_nameds_increase_) || !defined(_di_f_fss_nameds_increase_by_) || !defined(_di_f_fss_nameds_resize_)
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
diff --git a/level_0/f_fss/c/fss/private-named.h b/level_0/f_fss/c/fss/private-named.h
new file mode 100644 (file)
index 0000000..aab003f
--- /dev/null
@@ -0,0 +1,134 @@
+/**
+ * FLL - Level 0
+ *
+ * Project: FSS
+ * API Version: 0.7
+ * Licenses: lgpl-2.1-or-later
+ *
+ * These are provided for internal reduction in redundant code.
+ * These should not be exposed/used outside of this project.
+ */
+#ifndef _PRIVATE_F_fss_named_h
+#define _PRIVATE_F_fss_named_h
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+/**
+ * Private implementation for resizing.
+ *
+ * Intended to be shared to each of the different implementation variations.
+ *
+ * @param length
+ *   The new size to use.
+ * @param named
+ *   The named to adjust.
+ *
+ * @return
+ *   F_none on success.
+ *
+ *   Errors (with error bit) from: macro_f_string_ranges_t_adjust().
+ *   Errors (with error bit) from: macro_f_string_rangess_t_adjust().
+ *   Errors (with error bit) from: macro_f_uint8ss_t_adjust().
+ *
+ * @see macro_f_string_ranges_t_adjust()
+ * @see macro_f_string_rangess_t_adjust()
+ * @see macro_f_uint8ss_t_adjust()
+ *
+ * @see f_fss_nameds_adjust()
+ * @see f_fss_nameds_decimate_by()
+ */
+#if !defined(_di_f_fss_nameds_adjust_) || !defined(_di_f_fss_nameds_decimate_by_)
+  extern f_status_t private_f_fss_named_adjust(const f_number_unsigned_t length, f_fss_named_t * const named) F_attribute_visibility_internal_d;
+#endif // !defined(_di_f_fss_nameds_adjust_) || !defined(_di_f_fss_nameds_decimate_by_)
+
+/**
+ * Private implementation for resizing.
+ *
+ * Intended to be shared to each of the different implementation variations.
+ *
+ * @param length
+ *   The new size to use.
+ * @param named
+ *   The named to resize.
+ *
+ * @return
+ *   F_none on success.
+ *
+ *   Errors (with error bit) from: macro_f_string_ranges_t_resize().
+ *   Errors (with error bit) from: macro_f_string_rangess_t_resize().
+ *   Errors (with error bit) from: macro_f_uint8ss_t_resize().
+ *
+ * @see macro_f_string_ranges_t_resize()
+ * @see macro_f_string_rangess_t_resize()
+ * @see macro_f_uint8ss_t_resize()
+ *
+ * @see f_fss_nameds_decrease_by()
+ * @see f_fss_nameds_incease()
+ * @see f_fss_nameds_incease_by()
+ * @see f_fss_nameds_resize()
+ */
+#if !defined(_di_f_fss_nameds_decrease_by_) || !defined(_di_f_fss_nameds_increase_) || !defined(_di_f_fss_nameds_increase_by_) || !defined(_di_f_fss_nameds_resize_)
+  extern f_status_t private_f_fss_named_resize(const f_number_unsigned_t length, f_fss_named_t * const named) F_attribute_visibility_internal_d;
+#endif // !defined(_di_f_fss_nameds_decrease_by_) || !defined(_di_f_fss_nameds_increase_) || !defined(_di_f_fss_nameds_increase_by_) || !defined(_di_f_fss_nameds_resize_)
+
+/**
+ * Private implementation for resizing.
+ *
+ * Intended to be shared to each of the different implementation variations.
+ *
+ * @param length
+ *   The new size to use.
+ * @param nameds
+ *   The nameds to adjust.
+ *
+ * @return
+ *   F_none on success.
+ *
+ *   Errors (with error bit) from: f_memory_adjust().
+ *   Errors (with error bit) from: private_f_fss_named_adjust().
+ *
+ * @see private_f_fss_named_adjust()
+ *
+ * @see f_fss_nameds_adjust()
+ * @see f_fss_nameds_decimate_by()
+ * @see f_memory_adjust()
+ */
+#if !defined(_di_f_fss_nameds_adjust_) || !defined(_di_f_fss_nameds_decimate_by_)
+  extern f_status_t private_f_fss_nameds_adjust(const f_number_unsigned_t length, f_fss_nameds_t * const nameds) F_attribute_visibility_internal_d;
+#endif // !defined(_di_f_fss_nameds_adjust_) || !defined(_di_f_fss_nameds_decimate_by_)
+
+/**
+ * Private implementation for resizing.
+ *
+ * Intended to be shared to each of the different implementation variations.
+ *
+ * @param length
+ *   The new size to use.
+ * @param nameds
+ *   The nameds to resize.
+ *
+ * @return
+ *   F_none on success.
+ *
+ *   Errors (with error bit) from: f_memory_resize().
+ *   Errors (with error bit) from: private_f_fss_named_resize().
+ *
+ * @see private_f_fss_named_resize()
+ *
+ * @see f_fss_nameds_decrease_by()
+ * @see f_fss_nameds_increase()
+ * @see f_fss_nameds_increase_by()
+ * @see f_fss_nameds_resize()
+ * @see f_memory_resize()
+ */
+#if !defined(_di_f_fss_nameds_decrease_by_) || !defined(_di_f_fss_nameds_increase_) || !defined(_di_f_fss_nameds_increase_by_) || !defined(_di_f_fss_nameds_resize_)
+  extern f_status_t private_f_fss_nameds_resize(const f_number_unsigned_t length, f_fss_nameds_t * const nameds) F_attribute_visibility_internal_d;
+#endif // !defined(_di_f_fss_nameds_decrease_by_) || !defined(_di_f_fss_nameds_increase_) || !defined(_di_f_fss_nameds_increase_by_) || !defined(_di_f_fss_nameds_resize_)
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
+
+#endif // _PRIVATE_F_fss_named_h
diff --git a/level_0/f_fss/c/fss/private-nest.c b/level_0/f_fss/c/fss/private-nest.c
new file mode 100644 (file)
index 0000000..ce719a1
--- /dev/null
@@ -0,0 +1,107 @@
+#include "../fss.h"
+#include "private-item.h"
+#include "private-nest.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+#if !defined(_di_f_fss_nest_adjust_) || !defined(_di_f_fss_nest_decimate_by_)
+  f_status_t private_f_fss_nest_adjust(const f_number_unsigned_t length, f_fss_nest_t * const nest) {
+
+    f_status_t status = F_none;
+
+    for (f_number_unsigned_t i = length; i < nest->size; ++i) {
+
+      status = private_f_fss_items_adjust(0, &nest->depth[i]);
+      if (F_status_is_error(status)) return status;
+    } // for
+
+    status = f_memory_adjust(nest->size, length, sizeof(f_fss_items_t), (void **) & nest->depth);
+    if (F_status_is_error(status)) return status;
+
+    nest->size = length;
+
+    if (nest->used > nest->size) {
+      nest->used = length;
+    }
+
+    return F_none;
+  }
+#endif // !defined(_di_f_fss_nest_adjust_) || !defined(_di_f_fss_nest_decimate_by_)
+
+#if !defined(_di_f_fss_nest_decrease_by_) || !defined(_di_f_fss_nest_increase_) || !defined(_di_f_fss_nest_increase_by_) || !defined(_di_f_fss_nest_resize_)
+  f_status_t private_f_fss_nest_resize(const f_number_unsigned_t length, f_fss_nest_t * const nest) {
+
+    f_status_t status = F_none;
+
+    for (f_number_unsigned_t i = length; i < nest->size; ++i) {
+
+      status = private_f_fss_items_resize(0, &nest->depth[i]);
+      if (F_status_is_error(status)) return status;
+    } // for
+
+    status = f_memory_resize(nest->size, length, sizeof(f_fss_items_t), (void **) & nest->depth);
+    if (F_status_is_error(status)) return status;
+
+    nest->size = length;
+
+    if (nest->used > nest->size) {
+      nest->used = length;
+    }
+
+    return F_none;
+  }
+#endif // !defined(_di_f_fss_nest_decrease_by_) || !defined(_di_f_fss_nest_increase_) || !defined(_di_f_fss_nest_increase_by_) || !defined(_di_f_fss_nest_resize_)
+
+#if !defined(_di_f_fss_nests_adjust_) || !defined(_di_f_fss_nests_decimate_by_)
+  f_status_t private_f_fss_nests_adjust(const f_number_unsigned_t length, f_fss_nests_t *nests) {
+
+    f_status_t status = F_none;
+
+    for (f_number_unsigned_t i = length; i < nests->size; ++i) {
+
+      status = private_f_fss_nest_adjust(0, &nests->array[i]);
+      if (F_status_is_error(status)) return status;
+    } // for
+
+    status = f_memory_adjust(nests->size, length, sizeof(f_fss_nest_t), (void **) & nests->array);
+    if (F_status_is_error(status)) return status;
+
+    nests->size = length;
+
+    if (nests->used > nests->size) {
+      nests->used = length;
+    }
+
+    return F_none;
+  }
+#endif // !defined(_di_f_fss_nests_adjust_) || !defined(_di_f_fss_nests_decimate_by_)
+
+#if !defined(_di_f_fss_nests_decrease_by_) || !defined(_di_f_fss_nests_increase_) || !defined(_di_f_fss_nests_increase_by_) || !defined(_di_f_fss_nests_resize_)
+  f_status_t private_f_fss_nests_resize(const f_number_unsigned_t length, f_fss_nests_t * const nests) {
+
+    f_status_t status = F_none;
+
+    for (f_number_unsigned_t i = length; i < nests->size; ++i) {
+
+      status = private_f_fss_nest_resize(0, &nests->array[i]);
+      if (F_status_is_error(status)) return status;
+    } // for
+
+    status = f_memory_resize(nests->size, length, sizeof(f_fss_nest_t), (void **) & nests->array);
+    if (F_status_is_error(status)) return status;
+
+    nests->size = length;
+
+    if (nests->used > nests->size) {
+      nests->used = length;
+    }
+
+    return F_none;
+  }
+#endif // !defined(_di_f_fss_nests_decrease_by_) || !defined(_di_f_fss_nests_increase_) || !defined(_di_f_fss_nests_increase_by_) || !defined(_di_f_fss_nests_resize_)
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
diff --git a/level_0/f_fss/c/fss/private-nest.h b/level_0/f_fss/c/fss/private-nest.h
new file mode 100644 (file)
index 0000000..c38577e
--- /dev/null
@@ -0,0 +1,130 @@
+/**
+ * FLL - Level 0
+ *
+ * Project: FSS
+ * API Version: 0.7
+ * Licenses: lgpl-2.1-or-later
+ *
+ * These are provided for internal reduction in redundant code.
+ * These should not be exposed/used outside of this project.
+ */
+#ifndef _PRIVATE_F_fss_nest_h
+#define _PRIVATE_F_fss_nest_h
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+/**
+ * Private implementation for resizing.
+ *
+ * Intended to be shared to each of the different implementation variations.
+ *
+ * @param length
+ *   The new size to use.
+ * @param nest
+ *   The nest to adjust.
+ *
+ * @return
+ *   F_none on success.
+ *
+ *   Errors (with error bit) from: f_memory_adjust().
+ *   Errors (with error bit) from: macro_f_fss_nest_t_adjust().
+ *
+ * @see macro_f_fss_nest_t_adjust()
+ *
+ * @see f_fss_nest_adjust()
+ * @see f_fss_nest_decimate_by()
+ * @see f_memory_adjust()
+ */
+#if !defined(_di_f_fss_nest_adjust_) || !defined(_di_f_fss_nest_decimate_by_)
+  extern f_status_t private_f_fss_nest_adjust(const f_number_unsigned_t length, f_fss_nest_t * const nest) F_attribute_visibility_internal_d;
+#endif // !defined(_di_f_fss_nest_adjust_) || !defined(_di_f_fss_nest_decimate_by_)
+
+/**
+ * Private implementation for resizing.
+ *
+ * Intended to be shared to each of the different implementation variations.
+ *
+ * @param length
+ *   The new size to use.
+ * @param nest
+ *   The nest to resize.
+ *
+ * @return
+ *   F_none on success.
+ *
+ *   Errors (with error bit) from: f_memory_resize().
+ *   Errors (with error bit) from: macro_f_fss_nest_t_resize().
+ *
+ * @see macro_f_fss_nest_t_resize()
+ *
+ * @see f_fss_nest_decrease_by()
+ * @see f_fss_nest_increase()
+ * @see f_fss_nest_increase_by()
+ * @see f_fss_nest_resize()
+ * @see f_memory_resize()
+ */
+#if !defined(_di_f_fss_nest_decrease_by_) || !defined(_di_f_fss_nest_increase_) || !defined(_di_f_fss_nest_increase_by_) || !defined(_di_f_fss_nest_resize_)
+  extern f_status_t private_f_fss_nest_resize(const f_number_unsigned_t length, f_fss_nest_t * const nest) F_attribute_visibility_internal_d;
+#endif // !defined(_di_f_fss_nest_decrease_by_) || !defined(_di_f_fss_nest_increase_) || !defined(_di_f_fss_nest_increase_by_) || !defined(_di_f_fss_nest_resize_)
+
+/**
+ * Private implementation for resizing.
+ *
+ * Intended to be shared to each of the different implementation variations.
+ *
+ * @param length
+ *   The new size to use.
+ * @param nests
+ *   The nests to adjust.
+ *
+ * @return
+ *   F_none on success.
+ *
+ *   Errors (with error bit) from: f_memory_adjust().
+ *   Errors (with error bit) from: macro_f_fss_nest_t_adjust().
+ *
+ * @see macro_f_fss_nest_t_adjust()
+ *
+ * @see f_fss_nests_adjust()
+ * @see f_fss_nests_decimate_by()
+ * @see f_memory_adjust()
+ */
+#if !defined(_di_f_fss_nests_adjust_) || !defined(_di_f_fss_nests_decimate_by_)
+  extern f_status_t private_f_fss_nests_adjust(const f_number_unsigned_t length, f_fss_nests_t * const nests) F_attribute_visibility_internal_d;
+#endif // !defined(_di_f_fss_nests_adjust_) || !defined(_di_f_fss_nests_decimate_by_)
+
+/**
+ * Private implementation for resizing.
+ *
+ * Intended to be shared to each of the different implementation variations.
+ *
+ * @param length
+ *   The new size to use.
+ * @param nests
+ *   The nests to resize.
+ *
+ * @return
+ *   F_none on success.
+ *
+ *   Errors (with error bit) from: f_memory_resize().
+ *   Errors (with error bit) from: macro_f_fss_nest_t_resize().
+ *
+ * @see macro_f_fss_nest_t_resize()
+ *
+ * @see f_fss_nests_decrease_by()
+ * @see f_fss_nests_increase()
+ * @see f_fss_nests_increase_by()
+ * @see f_fss_nests_resize()
+ * @see f_memory_resize()
+ */
+#if !defined(_di_f_fss_nests_decrease_by_) || !defined(_di_f_fss_nests_increase_) || !defined(_di_f_fss_nests_increase_by_) || !defined(_di_f_fss_nests_resize_)
+  extern f_status_t private_f_fss_nests_resize(const f_number_unsigned_t length, f_fss_nests_t * const nests) F_attribute_visibility_internal_d;
+#endif // !defined(_di_f_fss_nests_decrease_by_) || !defined(_di_f_fss_nests_increase_) || !defined(_di_f_fss_nests_increase_by_) || !defined(_di_f_fss_nests_resize_)
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
+
+#endif // _PRIVATE_F_fss_nest_h
diff --git a/level_0/f_fss/c/fss/private-set.c b/level_0/f_fss/c/fss/private-set.c
new file mode 100644 (file)
index 0000000..e0472e1
--- /dev/null
@@ -0,0 +1,90 @@
+#include "../fss.h"
+#include "private-set.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+#if !defined(_di_f_fss_set_adjust_) || !defined(_di_f_fss_set_decimate_by_)
+  f_status_t private_f_fss_set_adjust(const f_number_unsigned_t length, f_fss_set_t * const set) {
+
+    f_status_t status = f_string_ranges_adjust(length, &set->objects);
+    if (F_status_is_error(status)) return status;
+
+    status = f_string_rangess_adjust(length, &set->contents);
+    if (F_status_is_error(status)) return status;
+
+    return F_none;
+  }
+#endif // !defined(_di_f_fss_set_adjust_) || !defined(_di_f_fss_set_decimate_by_)
+
+#if !defined(_di_f_fss_set_decrease_by_) || !defined(_di_f_fss_set_increase_) || !defined(_di_f_fss_set_increase_by_) || !defined(_di_f_fss_set_resize_)
+  f_status_t private_f_fss_set_resize(const f_number_unsigned_t length, f_fss_set_t *set) {
+
+    f_status_t status = f_string_ranges_resize(length, &set->objects);
+    if (F_status_is_error(status)) return status;
+
+    status = f_string_rangess_resize(length, &set->contents);
+    if (F_status_is_error(status)) return status;
+
+    return F_none;
+  }
+#endif // !defined(_di_f_fss_set_decrease_by_) || !defined(_di_f_fss_set_increase_) || !defined(_di_f_fss_set_increase_by_) || !defined(_di_f_fss_set_resize_)
+
+#if !defined(_di_f_fss_sets_adjust_) || !defined(_di_f_fss_sets_decimate_by_)
+  f_status_t private_f_fss_sets_adjust(const f_number_unsigned_t length, f_fss_sets_t * const sets) {
+
+    f_status_t status = F_none;
+
+    for (f_number_unsigned_t i = length; i < sets->size; ++i) {
+
+      status = f_string_ranges_adjust(0, &sets->array[i].objects);
+      if (F_status_is_error(status)) return status;
+
+      status = f_string_rangess_adjust(0, &sets->array[i].contents);
+      if (F_status_is_error(status)) return status;
+    } // for
+
+    status = f_memory_adjust(sets->size, length, sizeof(f_fss_set_t), (void **) & sets->array);
+    if (F_status_is_error(status)) return status;
+
+    sets->size = length;
+
+    if (sets->used > sets->size) {
+      sets->used = length;
+    }
+
+    return F_none;
+  }
+#endif // !defined(_di_f_fss_sets_adjust_) || !defined(_di_f_fss_sets_decimate_by_)
+
+#if !defined(_di_f_fss_sets_decrease_by_) || !defined(_di_f_fss_sets_increase_) || !defined(_di_f_fss_sets_increase_by_) || !defined(_di_f_fss_sets_resize_)
+  f_status_t private_f_fss_sets_resize(const f_number_unsigned_t length, f_fss_sets_t * const sets) {
+
+    f_status_t status = F_none;
+
+    for (f_number_unsigned_t i = length; i < sets->size; ++i) {
+
+      status = f_string_ranges_resize(0, &sets->array[i].objects);
+      if (F_status_is_error(status)) return status;
+
+      status = f_string_rangess_resize(0, &sets->array[i].contents);
+      if (F_status_is_error(status)) return status;
+    } // for
+
+    status = f_memory_resize(sets->size, length, sizeof(f_fss_set_t), (void **) & sets->array);
+    if (F_status_is_error(status)) return status;
+
+    sets->size = length;
+
+    if (sets->used > sets->size) {
+      sets->used = length;
+    }
+
+    return F_none;
+  }
+#endif // !defined(_di_f_fss_sets_decrease_by_) || !defined(_di_f_fss_sets_increase_) || !defined(_di_f_fss_sets_increase_by_) || !defined(_di_f_fss_sets_resize_)
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
diff --git a/level_0/f_fss/c/fss/private-set.h b/level_0/f_fss/c/fss/private-set.h
new file mode 100644 (file)
index 0000000..6c67ed3
--- /dev/null
@@ -0,0 +1,134 @@
+/**
+ * FLL - Level 0
+ *
+ * Project: FSS
+ * API Version: 0.7
+ * Licenses: lgpl-2.1-or-later
+ *
+ * These are provided for internal reduction in redundant code.
+ * These should not be exposed/used outside of this project.
+ */
+#ifndef _PRIVATE_F_fss_set_h
+#define _PRIVATE_F_fss_set_h
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+/**
+ * Private implementation for resizing.
+ *
+ * Intended to be shared to each of the different implementation variations.
+ *
+ * @param length
+ *   The new size to use.
+ * @param set
+ *   The set to adjust.
+ *
+ * @return
+ *   F_none on success.
+ *
+ *   Errors (with error bit) from: macro_f_string_rangess_t_adjust().
+ *   Errors (with error bit) from: macro_f_string_ranges_t_adjust().
+ *
+ * @see macro_f_string_rangess_t_adjust()
+ * @see macro_f_string_ranges_t_adjust()
+ *
+ * @see f_fss_set_adjust()
+ * @see f_fss_set_decimate_by()
+ */
+#if !defined(_di_f_fss_set_adjust_) || !defined(_di_f_fss_set_decimate_by_)
+  extern f_status_t private_f_fss_set_adjust(const f_number_unsigned_t length, f_fss_set_t * const set) F_attribute_visibility_internal_d;
+#endif // !defined(_di_f_fss_set_adjust_) || !defined(_di_f_fss_set_decimate_by_)
+
+/**
+ * Private implementation for resizing.
+ *
+ * Intended to be shared to each of the different implementation variations.
+ *
+ * @param length
+ *   The new size to use.
+ * @param set
+ *   The set to resize.
+ *
+ * @return
+ *   F_none on success.
+ *
+ *   Errors (with error bit) from: macro_f_string_rangess_t_resize().
+ *   Errors (with error bit) from: macro_f_string_ranges_t_resize().
+ *
+ * @see macro_f_string_rangess_t_resize()
+ * @see macro_f_string_ranges_t_resize()
+ *
+ * @see f_fss_set_decrease_by()
+ * @see f_fss_set_increase()
+ * @see f_fss_set_increase_by()
+ * @see f_fss_set_resize()
+ */
+#if !defined(_di_f_fss_set_decrease_by_) || !defined(_di_f_fss_set_increase_) || !defined(_di_f_fss_set_increase_by_) || !defined(_di_f_fss_set_resize_)
+  extern f_status_t private_f_fss_set_resize(const f_number_unsigned_t length, f_fss_set_t * const set) F_attribute_visibility_internal_d;
+#endif // !defined(_di_f_fss_set_decrease_by_) || !defined(_di_f_fss_set_increase_) || !defined(_di_f_fss_set_increase_by_) || !defined(_di_f_fss_set_resize_)
+
+/**
+ * Private implementation for resizing.
+ *
+ * Intended to be shared to each of the different implementation variations.
+ *
+ * @param length
+ *   The new size to use.
+ * @param sets
+ *   The sets to adjust.
+ *
+ * @return
+ *   F_none on success.
+ *
+ *   Errors (with error bit) from: macro_f_string_rangess_t_adjust().
+ *   Errors (with error bit) from: macro_f_string_ranges_t_adjust().
+ *   Errors (with error bit) from: f_memory_adjust().
+ *
+ * @see macro_f_string_rangess_t_adjust()
+ * @see macro_f_string_ranges_t_adjust()
+ *
+ * @see f_fss_sets_adjust()
+ * @see f_fss_sets_decimate_by()
+ * @see f_memory_adjust()
+ */
+#if !defined(_di_f_fss_sets_adjust_) || !defined(_di_f_fss_sets_decimate_by_)
+  extern f_status_t private_f_fss_sets_adjust(const f_number_unsigned_t length, f_fss_sets_t * const sets) F_attribute_visibility_internal_d;
+#endif // !defined(_di_f_fss_sets_adjust_) || !defined(_di_f_fss_sets_decimate_by_)
+
+/**
+ * Private implementation for resizing.
+ *
+ * Intended to be shared to each of the different implementation variations.
+ *
+ * @param length
+ *   The new size to use.
+ * @param sets
+ *   The sets to resize.
+ *
+ * @return
+ *   F_none on success.
+ *
+ *   Errors (with error bit) from: macro_f_string_rangess_t_resize().
+ *   Errors (with error bit) from: macro_f_string_ranges_t_resize().
+ *   Errors (with error bit) from: f_memory_resize().
+ *
+ * @see macro_f_string_rangess_t_resize()
+ * @see macro_f_string_ranges_t_resize()
+ *
+ * @see f_fss_sets_decrease_by()
+ * @see f_fss_sets_increase()
+ * @see f_fss_sets_increase_by()
+ * @see f_fss_sets_resize()
+ * @see f_memory_resize()
+ */
+#if !defined(_di_f_fss_sets_decrease_by_) || !defined(_di_f_fss_sets_increase_) || !defined(_di_f_fss_sets_increase_by_) || !defined(_di_f_fss_sets_resize_)
+  extern f_status_t private_f_fss_sets_resize(const f_number_unsigned_t length, f_fss_sets_t * const sets) F_attribute_visibility_internal_d;
+#endif // !defined(_di_f_fss_sets_decrease_by_) || !defined(_di_f_fss_sets_increase_) || !defined(_di_f_fss_sets_increase_by_) || !defined(_di_f_fss_sets_resize_)
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
+
+#endif // _PRIVATE_F_fss_set_h
diff --git a/level_0/f_fss/c/fss/private-set_quote.c b/level_0/f_fss/c/fss/private-set_quote.c
new file mode 100644 (file)
index 0000000..ee93a96
--- /dev/null
@@ -0,0 +1,114 @@
+#include "../fss.h"
+#include "private-set_quote.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+#if !defined(_di_f_fss_set_quote_adjust_) || !defined(_di_f_fss_set_quote_decimate_by_)
+  f_status_t private_f_fss_set_quote_adjust(const f_number_unsigned_t length, f_fss_set_quote_t * const set_quote) {
+
+    f_status_t status = f_string_ranges_adjust(length, &set_quote->objects);
+    if (F_status_is_error(status)) return status;
+
+    status = f_string_rangess_adjust(length, &set_quote->contents);
+    if (F_status_is_error(status)) return status;
+
+    status = f_uint8s_adjust(length, &set_quote->objects_quote);
+    if (F_status_is_error(status)) return status;
+
+    status = f_uint8ss_adjust(length, &set_quote->contents_quote);
+    if (F_status_is_error(status)) return status;
+
+    return F_none;
+  }
+#endif // !defined(_di_f_fss_set_quote_adjust_) || !defined(_di_f_fss_set_quote_decimate_by_)
+
+#if !defined(_di_f_fss_set_quote_decrease_by_) || !defined(_di_f_fss_set_quote_increase_) || !defined(_di_f_fss_set_quote_increase_by_) || !defined(_di_f_fss_set_quote_resize_)
+  f_status_t private_f_fss_set_quote_resize(const f_number_unsigned_t length, f_fss_set_quote_t * const set_quote) {
+
+    f_status_t status = f_string_ranges_resize(length, &set_quote->objects);
+    if (F_status_is_error(status)) return status;
+
+    status = f_string_rangess_resize(length, &set_quote->contents);
+    if (F_status_is_error(status)) return status;
+
+    status = f_uint8s_resize(length, &set_quote->objects_quote);
+    if (F_status_is_error(status)) return status;
+
+    status = f_uint8ss_resize(length, &set_quote->contents_quote);
+    if (F_status_is_error(status)) return status;
+
+    return F_none;
+  }
+#endif // !defined(_di_f_fss_set_quote_decrease_by_) || !defined(_di_f_fss_set_quote_increase_) || !defined(_di_f_fss_set_quote_increase_by_) || !defined(_di_f_fss_set_quote_resize_)
+
+#if !defined(_di_f_fss_set_quotes_adjust_) || !defined(_di_f_fss_set_quotes_decimate_by_)
+  f_status_t private_f_fss_set_quotes_adjust(const f_number_unsigned_t length, f_fss_set_quotes_t * const set_quotes) {
+
+    f_status_t status = F_none;
+
+    for (f_number_unsigned_t i = length; i < set_quotes->size; ++i) {
+
+      status = f_string_ranges_adjust(0, &set_quotes->array[i].objects);
+      if (F_status_is_error(status)) return status;
+
+      status = f_string_rangess_adjust(0, &set_quotes->array[i].contents);
+      if (F_status_is_error(status)) return status;
+
+      status = f_uint8s_adjust(0, &set_quotes->array[i].objects_quote);
+      if (F_status_is_error(status)) return status;
+
+      status = f_uint8ss_adjust(0, &set_quotes->array[i].contents_quote);
+      if (F_status_is_error(status)) return status;
+    } // for
+
+    status = f_memory_adjust(set_quotes->size, length, sizeof(f_fss_set_quote_t), (void **) & set_quotes->array);
+    if (F_status_is_error(status)) return status;
+
+    set_quotes->size = length;
+
+    if (set_quotes->used > set_quotes->size) {
+      set_quotes->used = length;
+    }
+
+    return F_none;
+  }
+#endif // !defined(_di_f_fss_set_quotes_adjust_) || !defined(_di_f_fss_set_quotes_decimate_by_)
+
+#if !defined(_di_f_fss_set_quotes_decrease_by_) || !defined(_di_f_fss_set_quotes_increase_) || !defined(_di_f_fss_set_quotes_increase_by_) || !defined(_di_f_fss_set_quotes_resize_)
+  f_status_t private_f_fss_set_quotes_resize(const f_number_unsigned_t length, f_fss_set_quotes_t * const set_quotes) {
+
+    f_status_t status = F_none;
+
+    for (f_number_unsigned_t i = length; i < set_quotes->size; ++i) {
+
+      status = f_string_ranges_resize(0, &set_quotes->array[i].objects);
+      if (F_status_is_error(status)) return status;
+
+      status = f_string_rangess_resize(0, &set_quotes->array[i].contents);
+      if (F_status_is_error(status)) return status;
+
+      status = f_uint8s_resize(0, &set_quotes->array[i].objects_quote);
+      if (F_status_is_error(status)) return status;
+
+      status = f_uint8ss_resize(0, &set_quotes->array[i].contents_quote);
+      if (F_status_is_error(status)) return status;
+    } // for
+
+    status = f_memory_resize(set_quotes->size, length, sizeof(f_fss_set_quote_t), (void **) & set_quotes->array);
+    if (F_status_is_error(status)) return status;
+
+    set_quotes->size = length;
+
+    if (set_quotes->used > set_quotes->size) {
+      set_quotes->used = length;
+    }
+
+    return F_none;
+  }
+#endif // !defined(_di_f_fss_set_quotes_decrease_by_) || !defined(_di_f_fss_set_quotes_increase_) || !defined(_di_f_fss_set_quotes_increase_by_) || !defined(_di_f_fss_set_quotes_resize_)
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
diff --git a/level_0/f_fss/c/fss/private-set_quote.h b/level_0/f_fss/c/fss/private-set_quote.h
new file mode 100644 (file)
index 0000000..2e285ec
--- /dev/null
@@ -0,0 +1,150 @@
+/**
+ * FLL - Level 0
+ *
+ * Project: FSS
+ * API Version: 0.7
+ * Licenses: lgpl-2.1-or-later
+ *
+ * These are provided for internal reduction in redundant code.
+ * These should not be exposed/used outside of this project.
+ */
+#ifndef _PRIVATE_F_fss_set_quote_h
+#define _PRIVATE_F_fss_set_quote_h
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+/**
+ * Private implementation for resizing.
+ *
+ * Intended to be shared to each of the different implementation variations.
+ *
+ * @param length
+ *   The new size to use.
+ * @param set_quote
+ *   The set_quote to adjust.
+ *
+ * @return
+ *   F_none on success.
+ *
+ *   Errors (with error bit) from: macro_f_string_rangess_t_adjust().
+ *   Errors (with error bit) from: macro_f_string_ranges_t_adjust().
+ *   Errors (with error bit) from: macro_f_uint8s_t_adjust().
+ *   Errors (with error bit) from: macro_f_uint8ss_t_adjust().
+ *
+ * @see macro_f_string_rangess_t_adjust()
+ * @see macro_f_string_ranges_t_adjust()
+ * @see macro_f_uint8s_t_adjust()
+ * @see macro_f_uint8ss_t_adjust()
+ *
+ * @see f_fss_set_quote_adjust()
+ * @see f_fss_set_quote_decimate_by()
+ */
+#if !defined(_di_f_fss_set_quote_adjust_) || !defined(_di_f_fss_set_quote_decimate_by_)
+  extern f_status_t private_f_fss_set_quote_adjust(const f_number_unsigned_t length, f_fss_set_quote_t * const set_quote) F_attribute_visibility_internal_d;
+#endif // !defined(_di_f_fss_set_quote_adjust_) || !defined(_di_f_fss_set_quote_decimate_by_)
+
+/**
+ * Private implementation for resizing.
+ *
+ * Intended to be shared to each of the different implementation variations.
+ *
+ * @param length
+ *   The new size to use.
+ * @param set_quote
+ *   The set_quote to resize.
+ *
+ * @return
+ *   F_none on success.
+ *
+ *   Errors (with error bit) from: macro_f_string_rangess_t_resize().
+ *   Errors (with error bit) from: macro_f_string_ranges_t_resize().
+ *   Errors (with error bit) from: macro_f_uint8s_t_resize().
+ *   Errors (with error bit) from: macro_f_uint8ss_t_resize().
+ *
+ * @see macro_f_string_rangess_t_resize()
+ * @see macro_f_string_ranges_t_resize()
+ * @see macro_f_uint8s_t_resize()
+ * @see macro_f_uint8ss_t_resize()
+ *
+ * @see f_fss_set_quote_decrease_by()
+ * @see f_fss_set_quote_increase()
+ * @see f_fss_set_quote_increase_by()
+ * @see f_fss_set_quote_resize()
+ */
+#if !defined(_di_f_fss_set_quote_decrease_by_) || !defined(_di_f_fss_set_quote_increase_) || !defined(_di_f_fss_set_quote_increase_by_) || !defined(_di_f_fss_set_quote_resize_)
+  extern f_status_t private_f_fss_set_quote_resize(const f_number_unsigned_t length, f_fss_set_quote_t * const set_quote) F_attribute_visibility_internal_d;
+#endif // !defined(_di_f_fss_set_quote_decrease_by_) || !defined(_di_f_fss_set_quote_increase_) || !defined(_di_f_fss_set_quote_increase_by_) || !defined(_di_f_fss_set_quote_resize_)
+
+/**
+ * Private implementation for resizing.
+ *
+ * Intended to be shared to each of the different implementation variations.
+ *
+ * @param length
+ *   The new size to use.
+ * @param set_quotes
+ *   The set_quotes to adjust.
+ *
+ * @return
+ *   F_none on success.
+ *
+ *   Errors (with error bit) from: macro_f_string_rangess_t_adjust().
+ *   Errors (with error bit) from: macro_f_string_ranges_t_adjust().
+ *   Errors (with error bit) from: macro_f_uint8s_t_adjust().
+ *   Errors (with error bit) from: macro_f_uint8ss_t_adjust().
+ *   Errors (with error bit) from: f_memory_adjust().
+ *
+ * @see macro_f_string_rangess_t_adjust()
+ * @see macro_f_string_ranges_t_adjust()
+ * @see macro_f_uint8s_t_adjust()
+ * @see macro_f_uint8ss_t_adjust()
+ *
+ * @see f_fss_set_quotes_adjust()
+ * @see f_fss_set_quotes_decimate_by()
+ * @see f_memory_adjust()
+ */
+#if !defined(_di_f_fss_set_quotes_adjust_) || !defined(_di_f_fss_set_quotes_decimate_by_)
+  extern f_status_t private_f_fss_set_quotes_adjust(const f_number_unsigned_t length, f_fss_set_quotes_t * const set_quotes) F_attribute_visibility_internal_d;
+#endif // !defined(_di_f_fss_set_quotes_adjust_) || !defined(_di_f_fss_set_quotes_decimate_by_)
+
+/**
+ * Private implementation for resizing.
+ *
+ * Intended to be shared to each of the different implementation variations.
+ *
+ * @param length
+ *   The new size to use.
+ * @param set_quotes
+ *   The set_quotes to resize.
+ *
+ * @return
+ *   F_none on success.
+ *
+ *   Errors (with error bit) from: macro_f_string_rangess_t_resize().
+ *   Errors (with error bit) from: macro_f_string_ranges_t_resize().
+ *   Errors (with error bit) from: macro_f_uint8s_t_resize().
+ *   Errors (with error bit) from: macro_f_uint8ss_t_resize().
+ *   Errors (with error bit) from: f_memory_resize().
+ *
+ * @see macro_f_string_rangess_t_resize()
+ * @see macro_f_string_ranges_t_resize()
+ * @see macro_f_uint8s_t_resize()
+ * @see macro_f_uint8ss_t_resize()
+ *
+ * @see f_fss_set_quotes_decrease_by()
+ * @see f_fss_set_quotes_increase()
+ * @see f_fss_set_quotes_increase_by()
+ * @see f_fss_set_quotes_resize()
+ * @see f_memory_resize()
+ */
+#if !defined(_di_f_fss_set_quotes_decrease_by_) || !defined(_di_f_fss_set_quotes_increase_) || !defined(_di_f_fss_set_quotes_increase_by_) || !defined(_di_f_fss_set_quotes_resize_)
+  extern f_status_t private_f_fss_set_quotes_resize(const f_number_unsigned_t length, f_fss_set_quotes_t * const set_quotes) F_attribute_visibility_internal_d;
+#endif // !defined(_di_f_fss_set_quotes_decrease_by_) || !defined(_di_f_fss_set_quotes_increase_) || !defined(_di_f_fss_set_quotes_increase_by_) || !defined(_di_f_fss_set_quotes_resize_)
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
+
+#endif // _PRIVATE_F_fss_set_quote_h
diff --git a/level_0/f_fss/c/fss/private-simple_packet.c b/level_0/f_fss/c/fss/private-simple_packet.c
new file mode 100644 (file)
index 0000000..348d5e1
--- /dev/null
@@ -0,0 +1,42 @@
+#include "../fss.h"
+#include "private-simple_packet.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+#if !defined(_di_f_fss_simple_packet_ranges_adjust_) || !defined(_di_f_fss_simple_packet_ranges_decimate_by_)
+  f_status_t private_f_fss_simple_packet_ranges_adjust(const f_number_unsigned_t length, f_fss_simple_packet_ranges_t * const simple_packet_ranges) {
+
+    const f_status_t status = f_memory_adjust(simple_packet_ranges->size, length, sizeof(f_fss_simple_packet_range_t), (void **) & simple_packet_ranges->array);
+    if (F_status_is_error(status)) return status;
+
+    simple_packet_ranges->size = length;
+
+    if (simple_packet_ranges->used > simple_packet_ranges->size) {
+      simple_packet_ranges->used = length;
+    }
+
+    return F_none;
+  }
+#endif // !defined(_di_f_fss_simple_packet_ranges_adjust_) || !defined(_di_f_fss_simple_packet_ranges_decimate_by_)
+
+#if !defined(_di_f_fss_simple_packet_ranges_decrease_by_) || !defined(_di_f_fss_simple_packet_ranges_increase_) || !defined(_di_f_fss_simple_packet_ranges_increase_by_) || !defined(_di_f_fss_simple_packet_ranges_resize_)
+  f_status_t private_f_fss_simple_packet_ranges_resize(const f_number_unsigned_t length, f_fss_simple_packet_ranges_t * const simple_packet_ranges) {
+
+    const f_status_t status = f_memory_resize(simple_packet_ranges->size, length, sizeof(f_fss_simple_packet_range_t), (void **) & simple_packet_ranges->array);
+    if (F_status_is_error(status)) return status;
+
+    simple_packet_ranges->size = length;
+
+    if (simple_packet_ranges->used > simple_packet_ranges->size) {
+      simple_packet_ranges->used = length;
+    }
+
+    return F_none;
+  }
+#endif // !defined(_di_f_fss_simple_packet_ranges_decrease_by_) || !defined(_di_f_fss_simple_packet_ranges_increase_) || !defined(_di_f_fss_simple_packet_ranges_increase_by_) || !defined(_di_f_fss_simple_packet_ranges_resize_)
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
diff --git a/level_0/f_fss/c/fss/private-simple_packet.h b/level_0/f_fss/c/fss/private-simple_packet.h
new file mode 100644 (file)
index 0000000..e41e417
--- /dev/null
@@ -0,0 +1,88 @@
+/**
+ * FLL - Level 0
+ *
+ * Project: FSS
+ * API Version: 0.7
+ * Licenses: lgpl-2.1-or-later
+ *
+ * These are provided for internal reduction in redundant code.
+ * These should not be exposed/used outside of this project.
+ */
+#ifndef _PRIVATE_F_fss_simple_packet_h
+#define _PRIVATE_F_fss_simple_packet_h
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+/**
+ * Private implementation for resizing.
+ *
+ * Intended to be shared to each of the different implementation variations.
+ *
+ * @param length
+ *   The new size to use.
+ * @param simple_packet_ranges
+ *   The simple_packet_ranges to adjust.
+ *
+ * @return
+ *   F_none on success.
+ *
+ *   Errors (with error bit) from: macro_f_string_rangess_t_adjust().
+ *   Errors (with error bit) from: macro_f_string_ranges_t_adjust().
+ *   Errors (with error bit) from: macro_f_uint8s_t_adjust().
+ *   Errors (with error bit) from: macro_f_uint8ss_t_adjust().
+ *   Errors (with error bit) from: f_memory_adjust().
+ *
+ * @see macro_f_string_rangess_t_adjust()
+ * @see macro_f_string_ranges_t_adjust()
+ * @see macro_f_uint8s_t_adjust()
+ * @see macro_f_uint8ss_t_adjust()
+ *
+ * @see f_fss_simple_packet_ranges_adjust()
+ * @see f_fss_simple_packet_ranges_decimate_by()
+ * @see f_memory_adjust()
+ */
+#if !defined(_di_f_fss_simple_packet_ranges_adjust_) || !defined(_di_f_fss_simple_packet_ranges_decimate_by_)
+  extern f_status_t private_f_fss_simple_packet_ranges_adjust(const f_number_unsigned_t length, f_fss_simple_packet_ranges_t * const simple_packet_ranges) F_attribute_visibility_internal_d;
+#endif // !defined(_di_f_fss_simple_packet_ranges_adjust_) || !defined(_di_f_fss_simple_packet_ranges_decimate_by_)
+
+/**
+ * Private implementation for resizing.
+ *
+ * Intended to be shared to each of the different implementation variations.
+ *
+ * @param length
+ *   The new size to use.
+ * @param simple_packet_ranges
+ *   The simple_packet_ranges to resize.
+ *
+ * @return
+ *   F_none on success.
+ *
+ *   Errors (with error bit) from: macro_f_string_rangess_t_resize().
+ *   Errors (with error bit) from: macro_f_string_ranges_t_resize().
+ *   Errors (with error bit) from: macro_f_uint8s_t_resize().
+ *   Errors (with error bit) from: macro_f_uint8ss_t_resize().
+ *   Errors (with error bit) from: f_memory_resize().
+ *
+ * @see macro_f_string_rangess_t_resize()
+ * @see macro_f_string_ranges_t_resize()
+ * @see macro_f_uint8s_t_resize()
+ * @see macro_f_uint8ss_t_resize()
+ *
+ * @see f_fss_simple_packet_ranges_decrease_by()
+ * @see f_fss_simple_packet_ranges_increase()
+ * @see f_fss_simple_packet_ranges_increase_by()
+ * @see f_fss_simple_packet_ranges_resize()
+ * @see f_memory_resize()
+ */
+#if !defined(_di_f_fss_simple_packet_ranges_decrease_by_) || !defined(_di_f_fss_simple_packet_ranges_increase_) || !defined(_di_f_fss_simple_packet_ranges_increase_by_) || !defined(_di_f_fss_simple_packet_ranges_resize_)
+  extern f_status_t private_f_fss_simple_packet_ranges_resize(const f_number_unsigned_t length, f_fss_simple_packet_ranges_t * const simple_packet_ranges) F_attribute_visibility_internal_d;
+#endif // !defined(_di_f_fss_simple_packet_ranges_decrease_by_) || !defined(_di_f_fss_simple_packet_ranges_increase_) || !defined(_di_f_fss_simple_packet_ranges_increase_by_) || !defined(_di_f_fss_simple_packet_ranges_resize_)
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
+
+#endif // _PRIVATE_F_fss_simple_packet_h
index 2cdac5d05117dceda17239e7a2030f9f683a5343..3f4b59f41f5944dc84b173850468826f29761c5c 100644 (file)
@@ -1,5 +1,5 @@
 #include "../fss.h"
-#include "../private-fss.h"
+#include "private-set.h"
 
 #ifdef __cplusplus
 extern "C" {
@@ -22,10 +22,7 @@ extern "C" {
     #endif // _di_level_0_parameter_checking_
 
     if (!amount) return F_data_not;
-
-    if (set->objects.size - amount > 0) {
-      return private_f_fss_set_adjust(set->objects.size - amount, set);
-    }
+    if (set->objects.size - amount > 0) return private_f_fss_set_adjust(set->objects.size - amount, set);
 
     return private_f_fss_set_adjust(0, set);
   }
@@ -38,10 +35,7 @@ extern "C" {
     #endif // _di_level_0_parameter_checking_
 
     if (!amount) return F_data_not;
-
-    if (set->objects.size - amount > 0) {
-      return private_f_fss_set_resize(set->objects.size - amount, set);
-    }
+    if (set->objects.size - amount > 0) return private_f_fss_set_resize(set->objects.size - amount, set);
 
     return private_f_fss_set_resize(0, set);
   }
@@ -57,9 +51,7 @@ extern "C" {
       f_number_unsigned_t size = set->objects.used + step;
 
       if (size > F_number_t_size_unsigned_d) {
-        if (set->objects.used + 1 > F_number_t_size_unsigned_d) {
-          return F_status_set_error(F_array_too_large);
-        }
+        if (set->objects.used + 1 > F_number_t_size_unsigned_d) return F_status_set_error(F_array_too_large);
 
         size = F_number_t_size_unsigned_d;
       }
@@ -80,9 +72,7 @@ extern "C" {
     if (!amount) return F_data_not;
 
     if (set->objects.used + amount > set->objects.size) {
-      if (set->objects.used + amount > F_number_t_size_unsigned_d) {
-        return F_status_set_error(F_array_too_large);
-      }
+      if (set->objects.used + amount > F_number_t_size_unsigned_d) return F_status_set_error(F_array_too_large);
 
       return private_f_fss_set_resize(set->objects.used + amount, set);
     }
@@ -101,198 +91,6 @@ extern "C" {
   }
 #endif // _di_f_fss_set_resize_
 
-#ifndef _di_f_fss_set_quote_adjust_
-  f_status_t f_fss_set_quote_adjust(const f_number_unsigned_t length, f_fss_set_quote_t * const set_quote) {
-    #ifndef _di_level_0_parameter_checking_
-      if (!set_quote) return F_status_set_error(F_parameter);
-    #endif // _di_level_0_parameter_checking_
-
-    return private_f_fss_set_quote_adjust(length, set_quote);
-  }
-#endif // _di_f_fss_set_quote_adjust_
-
-#ifndef _di_f_fss_set_quote_decimate_by_
-  f_status_t f_fss_set_quote_decimate_by(const f_number_unsigned_t amount, f_fss_set_quote_t * const set_quote) {
-    #ifndef _di_level_0_parameter_checking_
-      if (!set_quote) return F_status_set_error(F_parameter);
-    #endif // _di_level_0_parameter_checking_
-
-    if (!amount) return F_data_not;
-
-    if (set_quote->objects.size - amount > 0) {
-      return private_f_fss_set_quote_adjust(set_quote->objects.size - amount, set_quote);
-    }
-
-    return private_f_fss_set_quote_adjust(0, set_quote);
-  }
-#endif // _di_f_fss_set_quote_decimate_by_
-
-#ifndef _di_f_fss_set_quote_decrease_by_
-  f_status_t f_fss_set_quote_decrease_by(const f_number_unsigned_t amount, f_fss_set_quote_t * const set_quote) {
-    #ifndef _di_level_0_parameter_checking_
-      if (!set_quote) return F_status_set_error(F_parameter);
-    #endif // _di_level_0_parameter_checking_
-
-    if (!amount) return F_data_not;
-
-    if (set_quote->objects.size - amount > 0) {
-      return private_f_fss_set_quote_resize(set_quote->objects.size - amount, set_quote);
-    }
-
-    return private_f_fss_set_quote_resize(0, set_quote);
-  }
-#endif // _di_f_fss_set_quote_decrease_by_
-
-#ifndef _di_f_fss_set_quote_increase_
-  f_status_t f_fss_set_quote_increase(const f_number_unsigned_t step, f_fss_set_quote_t * const set_quote) {
-    #ifndef _di_level_0_parameter_checking_
-      if (!set_quote) return F_status_set_error(F_parameter);
-    #endif // _di_level_0_parameter_checking_
-
-    if (step && set_quote->objects.used + 1 > set_quote->objects.size) {
-      f_number_unsigned_t size = set_quote->objects.used + step;
-
-      if (size > F_number_t_size_unsigned_d) {
-        if (set_quote->objects.used + 1 > F_number_t_size_unsigned_d) {
-          return F_status_set_error(F_array_too_large);
-        }
-
-        size = F_number_t_size_unsigned_d;
-      }
-
-      return private_f_fss_set_quote_resize(size, set_quote);
-    }
-
-    return F_data_not;
-  }
-#endif // _di_f_fss_set_quote_increase_
-
-#ifndef _di_f_fss_set_quote_increase_by_
-  f_status_t f_fss_set_quote_increase_by(const f_number_unsigned_t amount, f_fss_set_quote_t * const set_quote) {
-    #ifndef _di_level_0_parameter_checking_
-      if (!set_quote) return F_status_set_error(F_parameter);
-    #endif // _di_level_0_parameter_checking_
-
-    if (!amount) return F_data_not;
-
-    if (set_quote->objects.used + amount > set_quote->objects.size) {
-      if (set_quote->objects.used + amount > F_number_t_size_unsigned_d) {
-        return F_status_set_error(F_array_too_large);
-      }
-
-      return private_f_fss_set_quote_resize(set_quote->objects.used + amount, set_quote);
-    }
-
-    return F_data_not;
-  }
-#endif // _di_f_fss_set_quote_increase_by_
-
-#ifndef _di_f_fss_set_quote_resize_
-  f_status_t f_fss_set_quote_resize(const f_number_unsigned_t length, f_fss_set_quote_t * const set_quote) {
-    #ifndef _di_level_0_parameter_checking_
-      if (!set_quote) return F_status_set_error(F_parameter);
-    #endif // _di_level_0_parameter_checking_
-
-    return private_f_fss_set_quote_resize(length, set_quote);
-  }
-#endif // _di_f_fss_set_quote_resize_
-
-#ifndef _di_f_fss_set_quotes_adjust_
-  f_status_t f_fss_set_quotes_adjust(const f_number_unsigned_t length, f_fss_set_quotes_t * const set_quotes) {
-    #ifndef _di_level_0_parameter_checking_
-      if (!set_quotes) return F_status_set_error(F_parameter);
-    #endif // _di_level_0_parameter_checking_
-
-    return private_f_fss_set_quotes_adjust(length, set_quotes);
-  }
-#endif // _di_f_fss_set_quotes_adjust_
-
-#ifndef _di_f_fss_set_quotes_decimate_by_
-  f_status_t f_fss_set_quotes_decimate_by(const f_number_unsigned_t amount, f_fss_set_quotes_t * const set_quotes) {
-    #ifndef _di_level_0_parameter_checking_
-      if (!set_quotes) return F_status_set_error(F_parameter);
-    #endif // _di_level_0_parameter_checking_
-
-    if (!amount) return F_data_not;
-
-    if (set_quotes->size - amount > 0) {
-      return private_f_fss_set_quotes_adjust(set_quotes->size - amount, set_quotes);
-    }
-
-    return private_f_fss_set_quotes_adjust(0, set_quotes);
-  }
-#endif // _di_f_fss_set_quotes_decimate_by_
-
-#ifndef _di_f_fss_set_quotes_decrease_by_
-  f_status_t f_fss_set_quotes_decrease_by(const f_number_unsigned_t amount, f_fss_set_quotes_t * const set_quotes) {
-    #ifndef _di_level_0_parameter_checking_
-      if (!set_quotes) return F_status_set_error(F_parameter);
-    #endif // _di_level_0_parameter_checking_
-
-    if (!amount) return F_data_not;
-
-    if (set_quotes->size - amount > 0) {
-      return private_f_fss_set_quotes_resize(set_quotes->size - amount, set_quotes);
-    }
-
-    return private_f_fss_set_quotes_resize(0, set_quotes);
-  }
-#endif // _di_f_fss_set_quotes_decrease_by_
-
-#ifndef _di_f_fss_set_quotes_increase_
-  f_status_t f_fss_set_quotes_increase(const f_number_unsigned_t step, f_fss_set_quotes_t * const set_quotes) {
-    #ifndef _di_level_0_parameter_checking_
-      if (!set_quotes) return F_status_set_error(F_parameter);
-    #endif // _di_level_0_parameter_checking_
-
-    if (step && set_quotes->used + 1 > set_quotes->size) {
-      f_number_unsigned_t size = set_quotes->used + step;
-
-      if (size > F_number_t_size_unsigned_d) {
-        if (set_quotes->used + 1 > F_number_t_size_unsigned_d) {
-          return F_status_set_error(F_array_too_large);
-        }
-
-        size = F_number_t_size_unsigned_d;
-      }
-
-      return private_f_fss_set_quotes_resize(size, set_quotes);
-    }
-
-    return F_data_not;
-  }
-#endif // _di_f_fss_set_quotes_increase_
-
-#ifndef _di_f_fss_set_quotes_increase_by_
-  f_status_t f_fss_set_quotes_increase_by(const f_number_unsigned_t amount, f_fss_set_quotes_t * const set_quotes) {
-    #ifndef _di_level_0_parameter_checking_
-      if (!set_quotes) return F_status_set_error(F_parameter);
-    #endif // _di_level_0_parameter_checking_
-
-    if (!amount) return F_data_not;
-
-    if (set_quotes->used + amount > set_quotes->size) {
-      if (set_quotes->used + amount > F_number_t_size_unsigned_d) {
-        return F_status_set_error(F_array_too_large);
-      }
-
-      return private_f_fss_set_quotes_resize(set_quotes->used + amount, set_quotes);
-    }
-
-    return F_data_not;
-  }
-#endif // _di_f_fss_set_quotes_increase_by_
-
-#ifndef _di_f_fss_set_quotes_resize_
-  f_status_t f_fss_set_quotes_resize(const f_number_unsigned_t length, f_fss_set_quotes_t * const set_quotes) {
-    #ifndef _di_level_0_parameter_checking_
-      if (!set_quotes) return F_status_set_error(F_parameter);
-    #endif // _di_level_0_parameter_checking_
-
-    return private_f_fss_set_quotes_resize(length, set_quotes);
-  }
-#endif // _di_f_fss_set_quotes_resize_
-
 #ifndef _di_f_fss_sets_adjust_
   f_status_t f_fss_sets_adjust(const f_number_unsigned_t length, f_fss_sets_t *sets) {
     #ifndef _di_level_0_parameter_checking_
@@ -310,10 +108,7 @@ extern "C" {
     #endif // _di_level_0_parameter_checking_
 
     if (!amount) return F_data_not;
-
-    if (sets->size - amount > 0) {
-      return private_f_fss_sets_adjust(sets->size - amount, sets);
-    }
+    if (sets->size - amount > 0) return private_f_fss_sets_adjust(sets->size - amount, sets);
 
     return private_f_fss_sets_adjust(0, sets);
   }
@@ -326,10 +121,7 @@ extern "C" {
     #endif // _di_level_0_parameter_checking_
 
     if (!amount) return F_data_not;
-
-    if (sets->size - amount > 0) {
-      return private_f_fss_sets_resize(sets->size - amount, sets);
-    }
+    if (sets->size - amount > 0) return private_f_fss_sets_resize(sets->size - amount, sets);
 
     return private_f_fss_sets_resize(0, sets);
   }
@@ -345,9 +137,7 @@ extern "C" {
       f_number_unsigned_t size = sets->used + step;
 
       if (size > F_number_t_size_unsigned_d) {
-        if (sets->used + 1 > F_number_t_size_unsigned_d) {
-          return F_status_set_error(F_array_too_large);
-        }
+        if (sets->used + 1 > F_number_t_size_unsigned_d) return F_status_set_error(F_array_too_large);
 
         size = F_number_t_size_unsigned_d;
       }
@@ -368,9 +158,7 @@ extern "C" {
     if (!amount) return F_data_not;
 
     if (sets->used + amount > sets->size) {
-      if (sets->used + amount > F_number_t_size_unsigned_d) {
-        return F_status_set_error(F_array_too_large);
-      }
+      if (sets->used + amount > F_number_t_size_unsigned_d) return F_status_set_error(F_array_too_large);
 
       return private_f_fss_sets_resize(sets->used + amount, sets);
     }
index 5343e6f41bb9a3f9a509b51905f9acdaea712db7..cd834fc8c211d749500aa4d41262a90f3fc5afef 100644 (file)
@@ -28,17 +28,17 @@ extern "C" {
  */
 #ifndef _di_f_fss_set_t_
   typedef struct {
-    f_fss_objects_t objects;
-    f_fss_contents_t contents;
+    f_string_ranges_t objects;
+    f_string_rangess_t contents;
   } f_fss_set_t;
 
-  #define f_fss_set_t_initialize { f_fss_objects_t_initialize, f_fss_contents_t_initialize }
+  #define f_fss_set_t_initialize { f_string_ranges_t_initialize, f_string_rangess_t_initialize }
 
   #define macro_f_fss_set_t_initialize_1(objects, contents) { objects, contents }
 
   #define macro_f_fss_set_t_clear(set) \
-    macro_f_fss_objects_t_clear(set.objects) \
-    macro_f_fss_contents_t_clear(set.contents)
+    macro_f_string_ranges_t_clear(set.objects) \
+    macro_f_string_rangess_t_clear(set.contents)
 
   #define macro_f_fss_set_t_resize(status, set, length) status = f_fss_set_resize(length, &set);
   #define macro_f_fss_set_t_adjust(status, set, length) status = f_fss_set_adjust(length, &set);
@@ -88,84 +88,6 @@ extern "C" {
 #endif // _di_f_fss_sets_t_
 
 /**
- * This holds an fss object with a set of fss content, along with their quote types.
- *
- * The objects, contents, and quotes should each be of the same used and size.
- * Any deviation to this would require implementing custom equivelents to the standard management macros.
- *
- * Properties:
- *   - objects:        The array of objects.
- *   - contents:       The array of contents.
- *   - objects_quote:  The array of objects quote types.
- *   - contents_quote: The array of contents quote types.
- */
-#ifndef _di_f_fss_set_quote_t_
-  typedef struct {
-    f_fss_objects_t objects;
-    f_fss_contents_t contents;
-
-    f_uint8s_t objects_quote;
-    f_uint8ss_t contents_quote;
-  } f_fss_set_quote_t;
-
-  #define f_fss_set_quote_t_initialize { f_fss_objects_t_initialize, f_fss_contents_t_initialize, f_uint8s_t_initialize, f_uint8ss_t_initialize }
-
-  #define macro_f_fss_set_quote_t_initialize_1(objects, contents, objects_quote, contents_quote) { objects, contents, objects_quote, contents_quote }
-
-  #define macro_f_fss_set_quote_t_clear(set) \
-    macro_f_fss_objects_t_clear(set.objects) \
-    macro_f_fss_contents_t_clear(set.contents) \
-    macro_f_uint8s_t_clear(set.objects_quote) \
-    macro_f_uint8ss_t_clear(set.contents_quote)
-
-  #define macro_f_fss_set_quote_t_resize(status, set_quote, length) status = f_fss_set_quote_resize(length, &set_quote);
-  #define macro_f_fss_set_quote_t_adjust(status, set_quote, length) status = f_fss_set_quote_adjust(length, &set_quote);
-
-  #define macro_f_fss_set_quote_t_delete_simple(set_quote)  f_fss_set_quote_resize(0, &set_quote);
-  #define macro_f_fss_set_quote_t_destroy_simple(set_quote) f_fss_set_quote_adjust(0, &set_quote);
-
-  #define macro_f_fss_set_quote_t_increase(status, step, set_quote)      status = f_fss_set_quote_increase(step, &set_quote);
-  #define macro_f_fss_set_quote_t_increase_by(status, set_quote, amount) status = f_fss_set_quote_increase_by(amount, &set_quote);
-  #define macro_f_fss_set_quote_t_decrease_by(status, set_quote, amount) status = f_fss_set_quote_decrease_by(amount, &set_quote);
-  #define macro_f_fss_set_quote_t_decimate_by(status, set_quote, amount) status = f_fss_set_quote_decimate_by(amount, &set_quote);
-#endif // _di_f_fss_set_quote_t_
-
-/**
- * This holds an array of f_fss_set_quote_t.
- *
- * Properties:
- *   - array: An array of f_fss_set_quote_t.
- *   - size:  Total amount of allocated space.
- *   - used:  Total number of allocated spaces used.
- */
-#ifndef _di_f_fss_set_quotes_t_
-  typedef struct {
-    f_fss_set_quote_t *array;
-
-    f_number_unsigned_t size;
-    f_number_unsigned_t used;
-  } f_fss_set_quotes_t;
-
-  #define f_fss_set_quotes_t_initialize { 0, 0, 0 }
-
-  #define macro_f_fss_set_quotes_t_initialize_1(array, size, used) { array, size, used }
-  #define macro_f_fss_set_quotes_t_initialize_2(array, length)     { array, length, length }
-
-  #define macro_f_fss_set_quotes_t_clear(nameds) macro_f_memory_structure_clear(nameds)
-
-  #define macro_f_fss_set_quotes_t_resize(status, set_quotes, length) status = f_fss_set_quotes_resize(length, &set_quotes);
-  #define macro_f_fss_set_quotes_t_adjust(status, set_quotes, length) status = f_fss_set_quotes_adjust(length, &set_quotes);
-
-  #define macro_f_fss_set_quotes_t_delete_simple(set_quotes)  f_fss_set_quotes_resize(0, &set_quotes);
-  #define macro_f_fss_set_quotes_t_destroy_simple(set_quotes) f_fss_set_quotes_adjust(0, &set_quotes);
-
-  #define macro_f_fss_set_quotes_t_increase(status, step, set_quotes)      status = f_fss_set_quotes_increase(step, &set_quotes);
-  #define macro_f_fss_set_quotes_t_increase_by(status, set_quotes, amount) status = f_fss_set_quotes_increase_by(amount, &set_quotes);
-  #define macro_f_fss_set_quotes_t_decrease_by(status, set_quotes, amount) status = f_fss_set_quotes_decrease_by(amount, &set_quotes);
-  #define macro_f_fss_set_quotes_t_decimate_by(status, set_quotes, amount) status = f_fss_set_quotes_decimate_by(amount, &set_quotes);
-#endif // _di_f_fss_set_quotes_t_
-
-/**
  * Resize the set array.
  *
  * @param length
@@ -295,264 +217,6 @@ extern "C" {
 #endif // _di_f_fss_set_resize_
 
 /**
- * Resize the set_quote array.
- *
- * @param length
- *   The new size to use.
- * @param set_quote
- *   The set_quote array to resize.
- *
- * @return
- *   F_none on success.
- *
- *   F_memory_not (with error bit) on out of memory.
- *   F_parameter (with error bit) if a parameter is invalid.
- */
-#ifndef _di_f_fss_set_quote_adjust_
-  extern f_status_t f_fss_set_quote_adjust(const f_number_unsigned_t length, f_fss_set_quote_t * const set_quote);
-#endif // _di_f_fss_set_quote_adjust_
-
-/**
- * Resize the set_quote array to a smaller size.
- *
- * This will resize making the array smaller based on (size - given length).
- * If the given length is too small, then the resize will fail.
- * This will not shrink the size to less than 0.
- *
- * @param amount
- *   A positive number representing how much to decimate the size by.
- * @param set_quote
- *   The set_quote array to resize.
- *
- * @return
- *   F_none on success.
- *   F_data_not if amount is 0.
- *
- *   F_memory_not (with error bit) on out of memory.
- *   F_parameter (with error bit) if a parameter is invalid.
- */
-#ifndef _di_f_fss_set_quote_decimate_by_
-  extern f_status_t f_fss_set_quote_decimate_by(const f_number_unsigned_t amount, f_fss_set_quote_t * const set_quote);
-#endif // _di_f_fss_set_quote_decimate_by_
-
-/**
- * Resize the set_quote array to a smaller size.
- *
- * This will resize making the array smaller based on (size - given length).
- * If the given length is too small, then the resize will fail.
- * This will not shrink the size to less than 0.
- *
- * @param amount
- *   A positive number representing how much to decrease the size by.
- * @param set_quote
- *   The set_quote array to resize.
- *
- * @return
- *   F_none on success.
- *
- *   F_memory_not (with error bit) on out of memory.
- *   F_parameter (with error bit) if a parameter is invalid.
- */
-#ifndef _di_f_fss_set_quote_decrease_by_
-  extern f_status_t f_fss_set_quote_decrease_by(const f_number_unsigned_t amount, f_fss_set_quote_t * const set_quote);
-#endif // _di_f_fss_set_quote_decrease_by_
-
-/**
- * Increase the size of the set_quote array, but only if necessary.
- *
- * If the given length is too large for the buffer, then attempt to set_quote max buffer size (F_number_t_size_unsigned_d).
- * If already set_quote to the maximum buffer size, then the resize will fail.
- *
- * @param step
- *   The allocation step to use.
- *   Must be greater than 0.
- * @param set_quote
- *   The set_quote array to resize.
- *
- * @return
- *   F_none on success.
- *   F_data_not on success, but there is no reason to increase size (used + 1 <= size).
- *
- *   F_array_too_large (with error bit) if the new array length is too large.
- *   F_memory_not (with error bit) on out of memory.
- *   F_parameter (with error bit) if a parameter is invalid.
- */
-#ifndef _di_f_fss_set_quote_increase_
-  extern f_status_t f_fss_set_quote_increase(const f_number_unsigned_t step, f_fss_set_quote_t * const set_quote);
-#endif // _di_f_fss_set_quote_increase_
-
-/**
- * Resize the set_quote array to a larger size.
- *
- * This will resize making the array larger based on the given length.
- * If the given length is too large for the buffer, then attempt to set_quote max buffer size (F_number_t_size_unsigned_d).
- * If already set_quote to the maximum buffer size, then the resize will fail.
- *
- * @param amount
- *   A positive number representing how much to increase the size by.
- * @param set_quote
- *   The set_quote array to resize.
- *
- * @return
- *   F_none on success.
- *   F_data_not on success, but there is no reason to increase size (used + amount <= size).
- *
- *   F_memory_not (with error bit) on out of memory.
- *   F_parameter (with error bit) if a parameter is invalid.
- *   F_array_too_large (with error bit) if the new array length is too large.
- */
-#ifndef _di_f_fss_set_quote_increase_by_
-  extern f_status_t f_fss_set_quote_increase_by(const f_number_unsigned_t amount, f_fss_set_quote_t * const set_quote);
-#endif // _di_f_fss_set_quote_increase_by_
-
-/**
- * Resize the set_quote array.
- *
- * @param length
- *   The new size to use.
- * @param set_quote
- *   The set_quote array to adjust.
- *
- * @return
- *   F_none on success.
- *
- *   F_memory_not (with error bit) on out of memory.
- *   F_parameter (with error bit) if a parameter is invalid.
- */
-#ifndef _di_f_fss_set_quote_resize_
-  extern f_status_t f_fss_set_quote_resize(const f_number_unsigned_t length, f_fss_set_quote_t * const set_quote);
-#endif // _di_f_fss_set_quote_resize_
-
-/**
- * Resize the set_quote array.
- *
- * @param length
- *   The new size to use.
- * @param set_quotes
- *   The set_quotes array to resize.
- *
- * @return
- *   F_none on success.
- *
- *   F_memory_not (with error bit) on out of memory.
- *   F_parameter (with error bit) if a parameter is invalid.
- */
-#ifndef _di_f_fss_set_quotes_adjust_
-  extern f_status_t f_fss_set_quotes_adjust(const f_number_unsigned_t length, f_fss_set_quotes_t * const set_quotes);
-#endif // _di_f_fss_set_quotes_adjust_
-
-/**
- * Resize the set_quote array to a smaller size.
- *
- * This will resize making the array smaller based on (size - given length).
- * If the given length is too small, then the resize will fail.
- * This will not shrink the size to less than 0.
- *
- * @param amount
- *   A positive number representing how much to decimate the size by.
- * @param set_quotes
- *   The set_quotes array to resize.
- *
- * @return
- *   F_none on success.
- *   F_data_not if amount is 0.
- *
- *   F_memory_not (with error bit) on out of memory.
- *   F_parameter (with error bit) if a parameter is invalid.
- */
-#ifndef _di_f_fss_set_quotes_decimate_by_
-  extern f_status_t f_fss_set_quotes_decimate_by(const f_number_unsigned_t amount, f_fss_set_quotes_t * const set_quotes);
-#endif // _di_f_fss_set_quotes_decimate_by_
-
-/**
- * Resize the set_quote array to a smaller size.
- *
- * This will resize making the array smaller based on (size - given length).
- * If the given length is too small, then the resize will fail.
- * This will not shrink the size to less than 0.
- *
- * @param amount
- *   A positive number representing how much to decrease the size by.
- * @param set_quotes
- *   The set_quotes array to resize.
- *
- * @return
- *   F_none on success.
- *
- *   F_memory_not (with error bit) on out of memory.
- *   F_parameter (with error bit) if a parameter is invalid.
- */
-#ifndef _di_f_fss_set_quotes_decrease_by_
-  extern f_status_t f_fss_set_quotes_decrease_by(const f_number_unsigned_t amount, f_fss_set_quotes_t * const set_quotes);
-#endif // _di_f_fss_set_quotes_decrease_by_
-
-/**
- * Increase the size of the set_quotes array, but only if necessary.
- *
- * If the given length is too large for the buffer, then attempt to set max buffer size (F_number_t_size_unsigned_d).
- * If already set to the maximum buffer size, then the resize will fail.
- *
- * @param step
- *   The allocation step to use.
- *   Must be greater than 0.
- * @param set_quotes
- *   The set_quotes array to resize.
- *
- * @return
- *   F_none on success.
- *   F_data_not on success, but there is no reason to increase size (used + 1 <= size).
- *
- *   F_array_too_large (with error bit) if the new array length is too large.
- *   F_memory_not (with error bit) on out of memory.
- *   F_parameter (with error bit) if a parameter is invalid.
- */
-#ifndef _di_f_fss_set_quotes_increase_
-  extern f_status_t f_fss_set_quotes_increase(const f_number_unsigned_t step, f_fss_set_quotes_t * const set_quotes);
-#endif // _di_f_fss_set_quotes_increase_
-
-/**
- * Resize the set_quotes array to a larger size.
- *
- * This will resize making the array larger based on the given length.
- * If the given length is too large for the buffer, then attempt to set max buffer size (F_number_t_size_unsigned_d).
- * If already set to the maximum buffer size, then the resize will fail.
- *
- * @param amount
- *   A positive number representing how much to increase the size by.
- * @param set_quotes
- *   The set_quotes array to resize.
- *
- * @return
- *   F_none on success.
- *   F_data_not on success, but there is no reason to increase size (used + amount <= size).
- *
- *   F_memory_not (with error bit) on out of memory.
- *   F_parameter (with error bit) if a parameter is invalid.
- *   F_array_too_large (with error bit) if the new array length is too large.
- */
-#ifndef _di_f_fss_set_quotes_increase_by_
-  extern f_status_t f_fss_set_quotes_increase_by(const f_number_unsigned_t amount, f_fss_set_quotes_t * const set_quotes);
-#endif // _di_f_fss_set_quotes_increase_by_
-
-/**
- * Resize the set_quotes array.
- *
- * @param length
- *   The new size to use.
- * @param set_quotes
- *   The set_quotes array to adjust.
- *
- * @return
- *   F_none on success.
- *
- *   F_memory_not (with error bit) on out of memory.
- *   F_parameter (with error bit) if a parameter is invalid.
- */
-#ifndef _di_f_fss_set_quotes_resize_
-  extern f_status_t f_fss_set_quotes_resize(const f_number_unsigned_t length, f_fss_set_quotes_t * const set_quotes);
-#endif // _di_f_fss_set_quotes_resize_
-
-/**
  * Resize the set array.
  *
  * @param length
diff --git a/level_0/f_fss/c/fss/set_quote.c b/level_0/f_fss/c/fss/set_quote.c
new file mode 100644 (file)
index 0000000..29b74be
--- /dev/null
@@ -0,0 +1,182 @@
+#include "../fss.h"
+#include "private-set_quote.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+#ifndef _di_f_fss_set_quote_adjust_
+  f_status_t f_fss_set_quote_adjust(const f_number_unsigned_t length, f_fss_set_quote_t * const set_quote) {
+    #ifndef _di_level_0_parameter_checking_
+      if (!set_quote) return F_status_set_error(F_parameter);
+    #endif // _di_level_0_parameter_checking_
+
+    return private_f_fss_set_quote_adjust(length, set_quote);
+  }
+#endif // _di_f_fss_set_quote_adjust_
+
+#ifndef _di_f_fss_set_quote_decimate_by_
+  f_status_t f_fss_set_quote_decimate_by(const f_number_unsigned_t amount, f_fss_set_quote_t * const set_quote) {
+    #ifndef _di_level_0_parameter_checking_
+      if (!set_quote) return F_status_set_error(F_parameter);
+    #endif // _di_level_0_parameter_checking_
+
+    if (!amount) return F_data_not;
+    if (set_quote->objects.size - amount > 0) return private_f_fss_set_quote_adjust(set_quote->objects.size - amount, set_quote);
+
+    return private_f_fss_set_quote_adjust(0, set_quote);
+  }
+#endif // _di_f_fss_set_quote_decimate_by_
+
+#ifndef _di_f_fss_set_quote_decrease_by_
+  f_status_t f_fss_set_quote_decrease_by(const f_number_unsigned_t amount, f_fss_set_quote_t * const set_quote) {
+    #ifndef _di_level_0_parameter_checking_
+      if (!set_quote) return F_status_set_error(F_parameter);
+    #endif // _di_level_0_parameter_checking_
+
+    if (!amount) return F_data_not;
+    if (set_quote->objects.size - amount > 0) return private_f_fss_set_quote_resize(set_quote->objects.size - amount, set_quote);
+
+    return private_f_fss_set_quote_resize(0, set_quote);
+  }
+#endif // _di_f_fss_set_quote_decrease_by_
+
+#ifndef _di_f_fss_set_quote_increase_
+  f_status_t f_fss_set_quote_increase(const f_number_unsigned_t step, f_fss_set_quote_t * const set_quote) {
+    #ifndef _di_level_0_parameter_checking_
+      if (!set_quote) return F_status_set_error(F_parameter);
+    #endif // _di_level_0_parameter_checking_
+
+    if (step && set_quote->objects.used + 1 > set_quote->objects.size) {
+      f_number_unsigned_t size = set_quote->objects.used + step;
+
+      if (size > F_number_t_size_unsigned_d) {
+        if (set_quote->objects.used + 1 > F_number_t_size_unsigned_d) return F_status_set_error(F_array_too_large);
+
+        size = F_number_t_size_unsigned_d;
+      }
+
+      return private_f_fss_set_quote_resize(size, set_quote);
+    }
+
+    return F_data_not;
+  }
+#endif // _di_f_fss_set_quote_increase_
+
+#ifndef _di_f_fss_set_quote_increase_by_
+  f_status_t f_fss_set_quote_increase_by(const f_number_unsigned_t amount, f_fss_set_quote_t * const set_quote) {
+    #ifndef _di_level_0_parameter_checking_
+      if (!set_quote) return F_status_set_error(F_parameter);
+    #endif // _di_level_0_parameter_checking_
+
+    if (!amount) return F_data_not;
+
+    if (set_quote->objects.used + amount > set_quote->objects.size) {
+      if (set_quote->objects.used + amount > F_number_t_size_unsigned_d) return F_status_set_error(F_array_too_large);
+
+      return private_f_fss_set_quote_resize(set_quote->objects.used + amount, set_quote);
+    }
+
+    return F_data_not;
+  }
+#endif // _di_f_fss_set_quote_increase_by_
+
+#ifndef _di_f_fss_set_quote_resize_
+  f_status_t f_fss_set_quote_resize(const f_number_unsigned_t length, f_fss_set_quote_t * const set_quote) {
+    #ifndef _di_level_0_parameter_checking_
+      if (!set_quote) return F_status_set_error(F_parameter);
+    #endif // _di_level_0_parameter_checking_
+
+    return private_f_fss_set_quote_resize(length, set_quote);
+  }
+#endif // _di_f_fss_set_quote_resize_
+
+#ifndef _di_f_fss_set_quotes_adjust_
+  f_status_t f_fss_set_quotes_adjust(const f_number_unsigned_t length, f_fss_set_quotes_t * const set_quotes) {
+    #ifndef _di_level_0_parameter_checking_
+      if (!set_quotes) return F_status_set_error(F_parameter);
+    #endif // _di_level_0_parameter_checking_
+
+    return private_f_fss_set_quotes_adjust(length, set_quotes);
+  }
+#endif // _di_f_fss_set_quotes_adjust_
+
+#ifndef _di_f_fss_set_quotes_decimate_by_
+  f_status_t f_fss_set_quotes_decimate_by(const f_number_unsigned_t amount, f_fss_set_quotes_t * const set_quotes) {
+    #ifndef _di_level_0_parameter_checking_
+      if (!set_quotes) return F_status_set_error(F_parameter);
+    #endif // _di_level_0_parameter_checking_
+
+    if (!amount) return F_data_not;
+    if (set_quotes->size - amount > 0) return private_f_fss_set_quotes_adjust(set_quotes->size - amount, set_quotes);
+
+    return private_f_fss_set_quotes_adjust(0, set_quotes);
+  }
+#endif // _di_f_fss_set_quotes_decimate_by_
+
+#ifndef _di_f_fss_set_quotes_decrease_by_
+  f_status_t f_fss_set_quotes_decrease_by(const f_number_unsigned_t amount, f_fss_set_quotes_t * const set_quotes) {
+    #ifndef _di_level_0_parameter_checking_
+      if (!set_quotes) return F_status_set_error(F_parameter);
+    #endif // _di_level_0_parameter_checking_
+
+    if (!amount) return F_data_not;
+    if (set_quotes->size - amount > 0) return private_f_fss_set_quotes_resize(set_quotes->size - amount, set_quotes);
+
+    return private_f_fss_set_quotes_resize(0, set_quotes);
+  }
+#endif // _di_f_fss_set_quotes_decrease_by_
+
+#ifndef _di_f_fss_set_quotes_increase_
+  f_status_t f_fss_set_quotes_increase(const f_number_unsigned_t step, f_fss_set_quotes_t * const set_quotes) {
+    #ifndef _di_level_0_parameter_checking_
+      if (!set_quotes) return F_status_set_error(F_parameter);
+    #endif // _di_level_0_parameter_checking_
+
+    if (step && set_quotes->used + 1 > set_quotes->size) {
+      f_number_unsigned_t size = set_quotes->used + step;
+
+      if (size > F_number_t_size_unsigned_d) {
+        if (set_quotes->used + 1 > F_number_t_size_unsigned_d) return F_status_set_error(F_array_too_large);
+
+        size = F_number_t_size_unsigned_d;
+      }
+
+      return private_f_fss_set_quotes_resize(size, set_quotes);
+    }
+
+    return F_data_not;
+  }
+#endif // _di_f_fss_set_quotes_increase_
+
+#ifndef _di_f_fss_set_quotes_increase_by_
+  f_status_t f_fss_set_quotes_increase_by(const f_number_unsigned_t amount, f_fss_set_quotes_t * const set_quotes) {
+    #ifndef _di_level_0_parameter_checking_
+      if (!set_quotes) return F_status_set_error(F_parameter);
+    #endif // _di_level_0_parameter_checking_
+
+    if (!amount) return F_data_not;
+
+    if (set_quotes->used + amount > set_quotes->size) {
+      if (set_quotes->used + amount > F_number_t_size_unsigned_d) return F_status_set_error(F_array_too_large);
+
+      return private_f_fss_set_quotes_resize(set_quotes->used + amount, set_quotes);
+    }
+
+    return F_data_not;
+  }
+#endif // _di_f_fss_set_quotes_increase_by_
+
+#ifndef _di_f_fss_set_quotes_resize_
+  f_status_t f_fss_set_quotes_resize(const f_number_unsigned_t length, f_fss_set_quotes_t * const set_quotes) {
+    #ifndef _di_level_0_parameter_checking_
+      if (!set_quotes) return F_status_set_error(F_parameter);
+    #endif // _di_level_0_parameter_checking_
+
+    return private_f_fss_set_quotes_resize(length, set_quotes);
+  }
+#endif // _di_f_fss_set_quotes_resize_
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
diff --git a/level_0/f_fss/c/fss/set_quote.h b/level_0/f_fss/c/fss/set_quote.h
new file mode 100644 (file)
index 0000000..cf9480d
--- /dev/null
@@ -0,0 +1,359 @@
+/**
+ * FLL - Level 0
+ *
+ * Project: FSS
+ * API Version: 0.7
+ * Licenses: lgpl-2.1-or-later
+ *
+ * Defines set data to be used for/by project fss.
+ *
+ * This is auto-included by fss.h and should not need to be explicitly included.
+ */
+#ifndef _F_fss_set_quote_h
+#define _F_fss_set_quote_h
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+/**
+ * This holds an fss object with a set of fss content, along with their quote types.
+ *
+ * The objects, contents, and quotes should each be of the same used and size.
+ * Any deviation to this would require implementing custom equivelents to the standard management macros.
+ *
+ * Properties:
+ *   - objects:        The array of objects.
+ *   - contents:       The array of contents.
+ *   - objects_quote:  The array of objects quote types.
+ *   - contents_quote: The array of contents quote types.
+ */
+#ifndef _di_f_fss_set_quote_t_
+  typedef struct {
+    f_string_ranges_t objects;
+    f_string_rangess_t contents;
+
+    f_uint8s_t objects_quote;
+    f_uint8ss_t contents_quote;
+  } f_fss_set_quote_t;
+
+  #define f_fss_set_quote_t_initialize { f_string_ranges_t_initialize, f_string_rangess_t_initialize, f_uint8s_t_initialize, f_uint8ss_t_initialize }
+
+  #define macro_f_fss_set_quote_t_initialize_1(objects, contents, objects_quote, contents_quote) { objects, contents, objects_quote, contents_quote }
+
+  #define macro_f_fss_set_quote_t_clear(set) \
+    macro_f_string_ranges_t_clear(set.objects) \
+    macro_f_string_rangess_t_clear(set.contents) \
+    macro_f_uint8s_t_clear(set.objects_quote) \
+    macro_f_uint8ss_t_clear(set.contents_quote)
+
+  #define macro_f_fss_set_quote_t_resize(status, set_quote, length) status = f_fss_set_quote_resize(length, &set_quote);
+  #define macro_f_fss_set_quote_t_adjust(status, set_quote, length) status = f_fss_set_quote_adjust(length, &set_quote);
+
+  #define macro_f_fss_set_quote_t_delete_simple(set_quote)  f_fss_set_quote_resize(0, &set_quote);
+  #define macro_f_fss_set_quote_t_destroy_simple(set_quote) f_fss_set_quote_adjust(0, &set_quote);
+
+  #define macro_f_fss_set_quote_t_increase(status, step, set_quote)      status = f_fss_set_quote_increase(step, &set_quote);
+  #define macro_f_fss_set_quote_t_increase_by(status, set_quote, amount) status = f_fss_set_quote_increase_by(amount, &set_quote);
+  #define macro_f_fss_set_quote_t_decrease_by(status, set_quote, amount) status = f_fss_set_quote_decrease_by(amount, &set_quote);
+  #define macro_f_fss_set_quote_t_decimate_by(status, set_quote, amount) status = f_fss_set_quote_decimate_by(amount, &set_quote);
+#endif // _di_f_fss_set_quote_t_
+
+/**
+ * This holds an array of f_fss_set_quote_t.
+ *
+ * Properties:
+ *   - array: An array of f_fss_set_quote_t.
+ *   - size:  Total amount of allocated space.
+ *   - used:  Total number of allocated spaces used.
+ */
+#ifndef _di_f_fss_set_quotes_t_
+  typedef struct {
+    f_fss_set_quote_t *array;
+
+    f_number_unsigned_t size;
+    f_number_unsigned_t used;
+  } f_fss_set_quotes_t;
+
+  #define f_fss_set_quotes_t_initialize { 0, 0, 0 }
+
+  #define macro_f_fss_set_quotes_t_initialize_1(array, size, used) { array, size, used }
+  #define macro_f_fss_set_quotes_t_initialize_2(array, length)     { array, length, length }
+
+  #define macro_f_fss_set_quotes_t_clear(nameds) macro_f_memory_structure_clear(nameds)
+
+  #define macro_f_fss_set_quotes_t_resize(status, set_quotes, length) status = f_fss_set_quotes_resize(length, &set_quotes);
+  #define macro_f_fss_set_quotes_t_adjust(status, set_quotes, length) status = f_fss_set_quotes_adjust(length, &set_quotes);
+
+  #define macro_f_fss_set_quotes_t_delete_simple(set_quotes)  f_fss_set_quotes_resize(0, &set_quotes);
+  #define macro_f_fss_set_quotes_t_destroy_simple(set_quotes) f_fss_set_quotes_adjust(0, &set_quotes);
+
+  #define macro_f_fss_set_quotes_t_increase(status, step, set_quotes)      status = f_fss_set_quotes_increase(step, &set_quotes);
+  #define macro_f_fss_set_quotes_t_increase_by(status, set_quotes, amount) status = f_fss_set_quotes_increase_by(amount, &set_quotes);
+  #define macro_f_fss_set_quotes_t_decrease_by(status, set_quotes, amount) status = f_fss_set_quotes_decrease_by(amount, &set_quotes);
+  #define macro_f_fss_set_quotes_t_decimate_by(status, set_quotes, amount) status = f_fss_set_quotes_decimate_by(amount, &set_quotes);
+#endif // _di_f_fss_set_quotes_t_
+
+/**
+ * Resize the set_quote array.
+ *
+ * @param length
+ *   The new size to use.
+ * @param set_quote
+ *   The set_quote array to resize.
+ *
+ * @return
+ *   F_none on success.
+ *
+ *   F_memory_not (with error bit) on out of memory.
+ *   F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_fss_set_quote_adjust_
+  extern f_status_t f_fss_set_quote_adjust(const f_number_unsigned_t length, f_fss_set_quote_t * const set_quote);
+#endif // _di_f_fss_set_quote_adjust_
+
+/**
+ * Resize the set_quote array to a smaller size.
+ *
+ * This will resize making the array smaller based on (size - given length).
+ * If the given length is too small, then the resize will fail.
+ * This will not shrink the size to less than 0.
+ *
+ * @param amount
+ *   A positive number representing how much to decimate the size by.
+ * @param set_quote
+ *   The set_quote array to resize.
+ *
+ * @return
+ *   F_none on success.
+ *   F_data_not if amount is 0.
+ *
+ *   F_memory_not (with error bit) on out of memory.
+ *   F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_fss_set_quote_decimate_by_
+  extern f_status_t f_fss_set_quote_decimate_by(const f_number_unsigned_t amount, f_fss_set_quote_t * const set_quote);
+#endif // _di_f_fss_set_quote_decimate_by_
+
+/**
+ * Resize the set_quote array to a smaller size.
+ *
+ * This will resize making the array smaller based on (size - given length).
+ * If the given length is too small, then the resize will fail.
+ * This will not shrink the size to less than 0.
+ *
+ * @param amount
+ *   A positive number representing how much to decrease the size by.
+ * @param set_quote
+ *   The set_quote array to resize.
+ *
+ * @return
+ *   F_none on success.
+ *
+ *   F_memory_not (with error bit) on out of memory.
+ *   F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_fss_set_quote_decrease_by_
+  extern f_status_t f_fss_set_quote_decrease_by(const f_number_unsigned_t amount, f_fss_set_quote_t * const set_quote);
+#endif // _di_f_fss_set_quote_decrease_by_
+
+/**
+ * Increase the size of the set_quote array, but only if necessary.
+ *
+ * If the given length is too large for the buffer, then attempt to set_quote max buffer size (F_number_t_size_unsigned_d).
+ * If already set_quote to the maximum buffer size, then the resize will fail.
+ *
+ * @param step
+ *   The allocation step to use.
+ *   Must be greater than 0.
+ * @param set_quote
+ *   The set_quote array to resize.
+ *
+ * @return
+ *   F_none on success.
+ *   F_data_not on success, but there is no reason to increase size (used + 1 <= size).
+ *
+ *   F_array_too_large (with error bit) if the new array length is too large.
+ *   F_memory_not (with error bit) on out of memory.
+ *   F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_fss_set_quote_increase_
+  extern f_status_t f_fss_set_quote_increase(const f_number_unsigned_t step, f_fss_set_quote_t * const set_quote);
+#endif // _di_f_fss_set_quote_increase_
+
+/**
+ * Resize the set_quote array to a larger size.
+ *
+ * This will resize making the array larger based on the given length.
+ * If the given length is too large for the buffer, then attempt to set_quote max buffer size (F_number_t_size_unsigned_d).
+ * If already set_quote to the maximum buffer size, then the resize will fail.
+ *
+ * @param amount
+ *   A positive number representing how much to increase the size by.
+ * @param set_quote
+ *   The set_quote array to resize.
+ *
+ * @return
+ *   F_none on success.
+ *   F_data_not on success, but there is no reason to increase size (used + amount <= size).
+ *
+ *   F_memory_not (with error bit) on out of memory.
+ *   F_parameter (with error bit) if a parameter is invalid.
+ *   F_array_too_large (with error bit) if the new array length is too large.
+ */
+#ifndef _di_f_fss_set_quote_increase_by_
+  extern f_status_t f_fss_set_quote_increase_by(const f_number_unsigned_t amount, f_fss_set_quote_t * const set_quote);
+#endif // _di_f_fss_set_quote_increase_by_
+
+/**
+ * Resize the set_quote array.
+ *
+ * @param length
+ *   The new size to use.
+ * @param set_quote
+ *   The set_quote array to adjust.
+ *
+ * @return
+ *   F_none on success.
+ *
+ *   F_memory_not (with error bit) on out of memory.
+ *   F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_fss_set_quote_resize_
+  extern f_status_t f_fss_set_quote_resize(const f_number_unsigned_t length, f_fss_set_quote_t * const set_quote);
+#endif // _di_f_fss_set_quote_resize_
+
+/**
+ * Resize the set_quote array.
+ *
+ * @param length
+ *   The new size to use.
+ * @param set_quotes
+ *   The set_quotes array to resize.
+ *
+ * @return
+ *   F_none on success.
+ *
+ *   F_memory_not (with error bit) on out of memory.
+ *   F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_fss_set_quotes_adjust_
+  extern f_status_t f_fss_set_quotes_adjust(const f_number_unsigned_t length, f_fss_set_quotes_t * const set_quotes);
+#endif // _di_f_fss_set_quotes_adjust_
+
+/**
+ * Resize the set_quote array to a smaller size.
+ *
+ * This will resize making the array smaller based on (size - given length).
+ * If the given length is too small, then the resize will fail.
+ * This will not shrink the size to less than 0.
+ *
+ * @param amount
+ *   A positive number representing how much to decimate the size by.
+ * @param set_quotes
+ *   The set_quotes array to resize.
+ *
+ * @return
+ *   F_none on success.
+ *   F_data_not if amount is 0.
+ *
+ *   F_memory_not (with error bit) on out of memory.
+ *   F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_fss_set_quotes_decimate_by_
+  extern f_status_t f_fss_set_quotes_decimate_by(const f_number_unsigned_t amount, f_fss_set_quotes_t * const set_quotes);
+#endif // _di_f_fss_set_quotes_decimate_by_
+
+/**
+ * Resize the set_quote array to a smaller size.
+ *
+ * This will resize making the array smaller based on (size - given length).
+ * If the given length is too small, then the resize will fail.
+ * This will not shrink the size to less than 0.
+ *
+ * @param amount
+ *   A positive number representing how much to decrease the size by.
+ * @param set_quotes
+ *   The set_quotes array to resize.
+ *
+ * @return
+ *   F_none on success.
+ *
+ *   F_memory_not (with error bit) on out of memory.
+ *   F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_fss_set_quotes_decrease_by_
+  extern f_status_t f_fss_set_quotes_decrease_by(const f_number_unsigned_t amount, f_fss_set_quotes_t * const set_quotes);
+#endif // _di_f_fss_set_quotes_decrease_by_
+
+/**
+ * Increase the size of the set_quotes array, but only if necessary.
+ *
+ * If the given length is too large for the buffer, then attempt to set max buffer size (F_number_t_size_unsigned_d).
+ * If already set to the maximum buffer size, then the resize will fail.
+ *
+ * @param step
+ *   The allocation step to use.
+ *   Must be greater than 0.
+ * @param set_quotes
+ *   The set_quotes array to resize.
+ *
+ * @return
+ *   F_none on success.
+ *   F_data_not on success, but there is no reason to increase size (used + 1 <= size).
+ *
+ *   F_array_too_large (with error bit) if the new array length is too large.
+ *   F_memory_not (with error bit) on out of memory.
+ *   F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_fss_set_quotes_increase_
+  extern f_status_t f_fss_set_quotes_increase(const f_number_unsigned_t step, f_fss_set_quotes_t * const set_quotes);
+#endif // _di_f_fss_set_quotes_increase_
+
+/**
+ * Resize the set_quotes array to a larger size.
+ *
+ * This will resize making the array larger based on the given length.
+ * If the given length is too large for the buffer, then attempt to set max buffer size (F_number_t_size_unsigned_d).
+ * If already set to the maximum buffer size, then the resize will fail.
+ *
+ * @param amount
+ *   A positive number representing how much to increase the size by.
+ * @param set_quotes
+ *   The set_quotes array to resize.
+ *
+ * @return
+ *   F_none on success.
+ *   F_data_not on success, but there is no reason to increase size (used + amount <= size).
+ *
+ *   F_memory_not (with error bit) on out of memory.
+ *   F_parameter (with error bit) if a parameter is invalid.
+ *   F_array_too_large (with error bit) if the new array length is too large.
+ */
+#ifndef _di_f_fss_set_quotes_increase_by_
+  extern f_status_t f_fss_set_quotes_increase_by(const f_number_unsigned_t amount, f_fss_set_quotes_t * const set_quotes);
+#endif // _di_f_fss_set_quotes_increase_by_
+
+/**
+ * Resize the set_quotes array.
+ *
+ * @param length
+ *   The new size to use.
+ * @param set_quotes
+ *   The set_quotes array to adjust.
+ *
+ * @return
+ *   F_none on success.
+ *
+ *   F_memory_not (with error bit) on out of memory.
+ *   F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_fss_set_quotes_resize_
+  extern f_status_t f_fss_set_quotes_resize(const f_number_unsigned_t length, f_fss_set_quotes_t * const set_quotes);
+#endif // _di_f_fss_set_quotes_resize_
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
+
+#endif // _F_fss_set_quote_h
diff --git a/level_0/f_fss/c/fss/simple_packet.c b/level_0/f_fss/c/fss/simple_packet.c
new file mode 100644 (file)
index 0000000..39c8c20
--- /dev/null
@@ -0,0 +1,148 @@
+#include "../fss.h"
+#include "private-simple_packet.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+#ifndef _di_f_fss_simple_packet_identify_
+  f_status_t f_fss_simple_packet_identify(const f_string_static_t buffer, f_fss_simple_packet_range_t * const range) {
+    #ifndef _di_level_0_parameter_checking_
+      if (!range) return F_status_set_error(F_parameter);
+    #endif // _di_level_0_parameter_checking_
+
+    if (!buffer.used) return F_data_not;
+
+    range->control.start = 1;
+    range->control.stop = 0;
+
+    range->size.start = 1;
+    range->size.stop = 0;
+
+    range->payload.start = 1;
+    range->payload.stop = 0;
+
+    if (buffer.used < F_fss_simple_packet_block_control_size_d) return F_partial;
+
+    range->control.start = 0;
+    range->control.stop = 0;
+
+    if (buffer.used < F_fss_simple_packet_block_header_size_d) return F_partial;
+
+    range->size.start = 1;
+    range->size.stop = F_fss_simple_packet_block_size_size_d;
+
+    // The Payload Block can be NULL and if it is, then all values of the Size Block must be of size F_fss_simple_packet_block_header_size_d.
+    if (buffer.used == F_fss_simple_packet_block_size_size_d) {
+
+      // Big endian.
+      if (buffer.string[0] & F_fss_simple_packet_endian_d) {
+        if (buffer.string[2] || buffer.string[3] || !buffer.string[4]) return F_partial;
+        if (buffer.string[1] < F_fss_simple_packet_block_header_size_d) return F_status_set_error(F_valid_not);
+
+        return (buffer.string[1] == F_fss_simple_packet_block_header_size_d) ? F_none : F_partial;
+      }
+
+      // Little endian.
+      if (!buffer.string[1] || buffer.string[2] || buffer.string[3]) return F_partial;
+      if (buffer.string[4] < F_fss_simple_packet_block_header_size_d) return F_status_set_error(F_valid_not);
+
+      return (buffer.string[4] == F_fss_simple_packet_block_header_size_d) ? F_none : F_partial;
+    }
+
+    range->payload.start = F_fss_simple_packet_block_header_size_d;
+    range->payload.stop = (buffer.used - F_fss_simple_packet_block_header_size_d < F_fss_simple_packet_block_payload_size_d) ? buffer.used - 1 : F_fss_simple_packet_block_payload_size_d - 1;
+
+    return F_none;
+  }
+#endif // _di_f_fss_simple_packet_identify_
+
+#ifndef _di_f_fss_simple_packet_ranges_adjust_
+  f_status_t f_fss_simple_packet_ranges_adjust(const f_number_unsigned_t length, f_fss_simple_packet_ranges_t * const simple_packet_ranges) {
+    #ifndef _di_level_0_parameter_checking_
+      if (!simple_packet_ranges) return F_status_set_error(F_parameter);
+    #endif // _di_level_0_parameter_checking_
+
+    return private_f_fss_simple_packet_ranges_adjust(length, simple_packet_ranges);
+  }
+#endif // _di_f_fss_simple_packet_ranges_adjust_
+
+#ifndef _di_f_fss_simple_packet_ranges_decimate_by_
+  f_status_t f_fss_simple_packet_ranges_decimate_by(const f_number_unsigned_t amount, f_fss_simple_packet_ranges_t * const simple_packet_ranges) {
+    #ifndef _di_level_0_parameter_checking_
+      if (!simple_packet_ranges) return F_status_set_error(F_parameter);
+    #endif // _di_level_0_parameter_checking_
+
+    if (!amount) return F_data_not;
+    if (simple_packet_ranges->size > amount) return private_f_fss_simple_packet_ranges_adjust(simple_packet_ranges->size - amount, simple_packet_ranges);
+
+    return private_f_fss_simple_packet_ranges_adjust(0, simple_packet_ranges);
+  }
+#endif // _di_f_fss_simple_packet_ranges_decimate_by_
+
+#ifndef _di_f_fss_simple_packet_ranges_decrease_by_
+  f_status_t f_fss_simple_packet_ranges_decrease_by(const f_number_unsigned_t amount, f_fss_simple_packet_ranges_t * const simple_packet_ranges) {
+    #ifndef _di_level_0_parameter_checking_
+      if (!simple_packet_ranges) return F_status_set_error(F_parameter);
+    #endif // _di_level_0_parameter_checking_
+
+    if (!amount) return F_data_not;
+    if (simple_packet_ranges->size > amount) return private_f_fss_simple_packet_ranges_resize(simple_packet_ranges->size - amount, simple_packet_ranges);
+
+    return private_f_fss_simple_packet_ranges_resize(0, simple_packet_ranges);
+  }
+#endif // _di_f_fss_simple_packet_ranges_decrease_by_
+
+#ifndef _di_f_fss_simple_packet_ranges_increase_
+  f_status_t f_fss_simple_packet_ranges_increase(const f_number_unsigned_t step, f_fss_simple_packet_ranges_t * const simple_packet_ranges) {
+    #ifndef _di_level_0_parameter_checking_
+      if (!simple_packet_ranges) return F_status_set_error(F_parameter);
+    #endif // _di_level_0_parameter_checking_
+
+    if (step && simple_packet_ranges->used + 1 > simple_packet_ranges->size) {
+      f_number_unsigned_t size = simple_packet_ranges->used + step;
+
+      if (size > F_number_t_size_unsigned_d) {
+        if (simple_packet_ranges->used + 1 > F_number_t_size_unsigned_d) return F_status_set_error(F_array_too_large);
+
+        size = F_number_t_size_unsigned_d;
+      }
+
+      return private_f_fss_simple_packet_ranges_resize(size, simple_packet_ranges);
+    }
+
+    return F_data_not;
+  }
+#endif // _di_f_fss_simple_packet_ranges_increase_
+
+#ifndef _di_f_fss_simple_packet_ranges_increase_by_
+  f_status_t f_fss_simple_packet_ranges_increase_by(const f_number_unsigned_t amount, f_fss_simple_packet_ranges_t * const simple_packet_ranges) {
+    #ifndef _di_level_0_parameter_checking_
+      if (!simple_packet_ranges) return F_status_set_error(F_parameter);
+    #endif // _di_level_0_parameter_checking_
+
+    if (!amount) return F_data_not;
+
+    if (simple_packet_ranges->used + amount > simple_packet_ranges->size) {
+      if (simple_packet_ranges->used + amount > F_number_t_size_unsigned_d) return F_status_set_error(F_array_too_large);
+
+      return private_f_fss_simple_packet_ranges_resize(simple_packet_ranges->used + amount, simple_packet_ranges);
+    }
+
+    return F_data_not;
+  }
+#endif // _di_f_fss_simple_packet_ranges_increase_by_
+
+#ifndef _di_f_fss_simple_packet_ranges_resize_
+  f_status_t f_fss_simple_packet_ranges_resize(const f_number_unsigned_t length, f_fss_simple_packet_ranges_t * const simple_packet_ranges) {
+    #ifndef _di_level_0_parameter_checking_
+      if (!simple_packet_ranges) return F_status_set_error(F_parameter);
+    #endif // _di_level_0_parameter_checking_
+
+    return private_f_fss_simple_packet_ranges_resize(length, simple_packet_ranges);
+  }
+#endif // _di_f_fss_simple_packet_ranges_resize_
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
diff --git a/level_0/f_fss/c/fss/simple_packet.h b/level_0/f_fss/c/fss/simple_packet.h
new file mode 100644 (file)
index 0000000..787d950
--- /dev/null
@@ -0,0 +1,255 @@
+/**
+ * FLL - Level 0
+ *
+ * Project: FSS
+ * API Version: 0.7
+ * Licenses: lgpl-2.1-or-later
+ *
+ * Defines set data to be used for/by project fss.
+ *
+ * This is auto-included by fss.h and should not need to be explicitly included.
+ */
+#ifndef _F_fss_simple_packet_h
+#define _F_fss_simple_packet_h
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+/**
+ * FSS-000F (Simple Packet) specific defines.
+ *
+ * F_fss_simple_packet_*_d:
+ *   - endian:             The endian bit for a 8-bit type, generally a character, that when set to 1 is big endian and when set to 0 is little endian.
+ *   - block_control_size: The size of the Control Block in bytes.
+ *   - block_size_size:    The size of the Size Block in bytes.
+ *   - block_header_size:  The size of both the Control Block and the Size Block in bytes.
+ *   - block_payload_size: The maximum block size of the Payload Block in bytes, which is (2^32)-6.
+ */
+#ifndef _di_f_fss_simple_packet_d_
+  #define F_fss_simple_packet_endian_d 0x80
+
+  #define F_fss_simple_packet_block_control_size_d 1
+  #define F_fss_simple_packet_block_size_size_d    4
+  #define F_fss_simple_packet_block_header_size_d  5
+  #define F_fss_simple_packet_block_payload_size_d 4294967290
+#endif // _di_f_fss_simple_packet_d_
+
+/**
+ * A set of string ranges intending to designate the different ranges for a Simple Packet representing each Block.
+ *
+ * Properties:
+ *   - control: The Control Block, which is 1 byte long.
+ *   - size:    The Size Block, which is 4 bytes long.
+ *   - payload: The Payload Block, which is inclusively between 0 and (2^32)-6 bytes long.
+ */
+#ifndef _di_f_fss_simple_packet_range_t_
+  typedef struct {
+    f_string_range_t control;
+    f_string_range_t size;
+    f_string_range_t payload;
+  } f_fss_simple_packet_range_t;
+
+  #define f_fss_simple_packet_range_t_initialize { \
+    f_string_range_t_initialize, \
+    f_string_range_t_initialize, \
+    f_string_range_t_initialize, \
+  }
+
+  #define macro_f_fss_simple_packet_range_t_initialize_1(control, size, payload) { \
+    control, \
+    size, \
+    payload, \
+  }
+#endif // _di_f_fss_simple_packet_range_t_
+
+/**
+ * This holds an array of f_fss_simple_packet_range_t.
+ *
+ * Properties:
+ *   - array: An array of f_fss_simple_packet_range_t.
+ *   - size:  Total amount of allocated space.
+ *   - used:  Total number of allocated spaces used.
+ */
+#ifndef _di_f_fss_simple_packet_ranges_t_
+  typedef struct {
+    f_fss_simple_packet_range_t *array;
+
+    f_number_unsigned_t size;
+    f_number_unsigned_t used;
+  } f_fss_simple_packet_ranges_t;
+
+  #define f_fss_simple_packet_ranges_t_initialize { 0, 0, 0 }
+
+  #define macro_f_fss_simple_packet_ranges_t_initialize_1(array, size, used) { array, size, used }
+  #define macro_f_fss_simple_packet_ranges_t_initialize_2(array, length) { array, length, length }
+
+  #define macro_f_fss_simple_packet_ranges_t_clear(simple_packet_ranges) macro_f_memory_structure_t_clear(simple_packet_range.objects)
+
+  #define macro_f_fss_simple_packet_ranges_t_resize(status, simple_packet_ranges, length) status = f_fss_simple_packet_ranges_resize(length, &simple_packet_ranges);
+  #define macro_f_fss_simple_packet_ranges_t_adjust(status, simple_packet_ranges, length) status = f_fss_simple_packet_ranges_adjust(length, &simple_packet_ranges);
+
+  #define macro_f_fss_simple_packet_ranges_t_delete_simple(simple_packet_ranges)  f_fss_simple_packet_ranges_resize(0, &simple_packet_ranges);
+  #define macro_f_fss_simple_packet_ranges_t_destroy_simple(simple_packet_ranges) f_fss_simple_packet_ranges_adjust(0, &simple_packet_ranges);
+
+  #define macro_f_fss_simple_packet_ranges_t_increase(status, step, simple_packet_ranges)      status = f_fss_simple_packet_ranges_increase(step, &simple_packet_ranges);
+  #define macro_f_fss_simple_packet_ranges_t_increase_by(status, simple_packet_ranges, amount) status = f_fss_simple_packet_ranges_increase_by(amount, &simple_packet_ranges);
+  #define macro_f_fss_simple_packet_ranges_t_decrease_by(status, simple_packet_ranges, amount) status = f_fss_simple_packet_ranges_decrease_by(amount, &simple_packet_ranges);
+  #define macro_f_fss_simple_packet_ranges_t_decimate_by(status, simple_packet_ranges, amount) status = f_fss_simple_packet_ranges_decimate_by(amount, &simple_packet_ranges);
+#endif // _di_f_fss_simple_packet_ranges_t_
+
+/**
+ * Identify the ranges representing the different parts of the FSS-000F (Simple Packet).
+ *
+ * @param buffer
+ *   The string buffer to identify the packet ranges of.
+ *   This buffer is considered binary data and so any NULL found within is treated as a valid part of the buffer.
+ * @param range
+ *   The set of blocks, each representing a range within the buffer.
+ *   If the buffer is too small (including when F_data_not is returned), then the ranges are all set to the out of range values as appropriate.
+ *
+ * @return
+ *   F_none on success (The end of the Payload Block is assumed to be the remainder of the buffer or F_fss_simple_packet_block_payload_size_d, whichever is smaller).
+ *   F_partial on success but not all blocks are identified.
+ *   F_data_not if buffer.used is 0.
+ *
+ *   F_parameter (with error bit) if a parameter is invalid.
+ *   F_valid_not (with error bit) if the data is invalid, which generally only happens when the value of the Size block is less than 5 (and when not returning F_partial).
+ */
+#ifndef _di_f_fss_simple_packet_identify_
+  extern f_status_t f_fss_simple_packet_identify(const f_string_static_t buffer, f_fss_simple_packet_range_t * const range);
+#endif // _di_f_fss_simple_packet_identify_
+
+/**
+ * Resize the simple_packet_range array.
+ *
+ * @param length
+ *   The new size to use.
+ * @param simple_packet_ranges
+ *   The simple_packet_ranges array to resize.
+ *
+ * @return
+ *   F_none on success.
+ *
+ *   F_memory_not (with error bit) on out of memory.
+ *   F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_fss_simple_packet_ranges_adjust_
+  extern f_status_t f_fss_simple_packet_ranges_adjust(const f_number_unsigned_t length, f_fss_simple_packet_ranges_t * const simple_packet_ranges);
+#endif // _di_f_fss_simple_packet_ranges_adjust_
+
+/**
+ * Resize the simple_packet_range array to a smaller size.
+ *
+ * This will resize making the array smaller based on (size - given length).
+ * If the given length is too small, then the resize will fail.
+ * This will not shrink the size to less than 0.
+ *
+ * @param amount
+ *   A positive number representing how much to decimate the size by.
+ * @param simple_packet_ranges
+ *   The simple_packet_ranges array to resize.
+ *
+ * @return
+ *   F_none on success.
+ *
+ *   F_memory_not (with error bit) on out of memory.
+ *   F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_fss_simple_packet_ranges_decimate_by_
+  extern f_status_t f_fss_simple_packet_ranges_decimate_by(const f_number_unsigned_t amount, f_fss_simple_packet_ranges_t * const simple_packet_ranges);
+#endif // _di_f_fss_simple_packet_ranges_decimate_by_
+
+/**
+ * Resize the simple_packet_range array to a smaller size.
+ *
+ * This will resize making the array smaller based on (size - given length).
+ * If the given length is too small, then the resize will fail.
+ * This will not shrink the size to less than 0.
+ *
+ * @param amount
+ *   A positive number representing how much to decrease the size by.
+ * @param simple_packet_ranges
+ *   The simple_packet_ranges array to resize.
+ *
+ * @return
+ *   F_none on success.
+ *
+ *   F_memory_not (with error bit) on out of memory.
+ *   F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_fss_simple_packet_ranges_decrease_by_
+  extern f_status_t f_fss_simple_packet_ranges_decrease_by(const f_number_unsigned_t amount, f_fss_simple_packet_ranges_t * const simple_packet_ranges);
+#endif // _di_f_fss_simple_packet_ranges_decrease_by_
+
+/**
+ * Increase the size of the simple_packet_ranges array, but only if necessary.
+ *
+ * If the given length is too large for the buffer, then attempt to set max buffer size (F_number_t_size_unsigned_d).
+ * If already set to the maximum buffer size, then the resize will fail.
+ *
+ * @param step
+ *   The allocation step to use.
+ *   Must be greater than 0.
+ * @param simple_packet_ranges
+ *   The simple_packet_ranges array to resize.
+ *
+ * @return
+ *   F_none on success.
+ *   F_data_not on success, but there is no reason to increase size (used + 1 <= size).
+ *
+ *   F_array_too_large (with error bit) if the new array length is too large.
+ *   F_memory_not (with error bit) on out of memory.
+ *   F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_fss_simple_packet_ranges_increase_
+  extern f_status_t f_fss_simple_packet_ranges_increase(const f_number_unsigned_t step, f_fss_simple_packet_ranges_t * const simple_packet_ranges);
+#endif // _di_f_fss_simple_packet_ranges_increase_
+
+/**
+ * Resize the simple_packet_ranges array to a larger size.
+ *
+ * This will resize making the array larger based on the given length.
+ * If the given length is too large for the buffer, then attempt to set max buffer size (F_number_t_size_unsigned_d).
+ * If already set to the maximum buffer size, then the resize will fail.
+ *
+ * @param amount
+ *   A positive number representing how much to increase the size by.
+ * @param simple_packet_ranges
+ *   The simple_packet_ranges array to resize.
+ *
+ * @return
+ *   F_none on success.
+ *   F_data_not on success, but there is no reason to increase size (used + amount <= size).
+ *
+ *   F_memory_not (with error bit) on out of memory.
+ *   F_parameter (with error bit) if a parameter is invalid.
+ *   F_array_too_large (with error bit) if the new array length is too large.
+ */
+#ifndef _di_f_fss_simple_packet_ranges_increase_by_
+  extern f_status_t f_fss_simple_packet_ranges_increase_by(const f_number_unsigned_t amount, f_fss_simple_packet_ranges_t * const simple_packet_ranges);
+#endif // _di_f_fss_simple_packet_ranges_increase_by_
+
+/**
+ * Resize the simple_packet_ranges array.
+ *
+ * @param length
+ *   The new size to use.
+ * @param simple_packet_ranges
+ *   The simple_packet_ranges array to adjust.
+ *
+ * @return
+ *   F_none on success.
+ *
+ *   F_memory_not (with error bit) on out of memory.
+ *   F_parameter (with error bit) if a parameter is invalid.
+ */
+#ifndef _di_f_fss_simple_packet_ranges_resize_
+  extern f_status_t f_fss_simple_packet_ranges_resize(const f_number_unsigned_t length, f_fss_simple_packet_ranges_t * const simple_packet_ranges);
+#endif // _di_f_fss_simple_packet_ranges_resize_
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
+
+#endif // _F_fss_simple_packet_h
index 71493b2d3ee22d0a73e54ca08cf485f3c59cba53..be126fd77a807e10f648ad10ca994f4315655e65 100644 (file)
@@ -5,444 +5,6 @@
 extern "C" {
 #endif
 
-#if !defined(_di_f_fss_items_adjust_) || !defined(_di_f_fss_items_decimate_by_)
-  f_status_t private_f_fss_items_adjust(const f_number_unsigned_t length, f_fss_items_t * const items) {
-
-    f_status_t status = F_none;
-
-    for (f_number_unsigned_t i = length; i < items->size; ++i) {
-
-      status = f_string_ranges_adjust(0, &items->array[i].content);
-      if (F_status_is_error(status)) return status;
-    } // for
-
-    status = f_memory_adjust(items->size, length, sizeof(f_fss_item_t), (void **) & items->array);
-
-    if (F_status_is_error_not(status)) {
-      items->size = length;
-
-      if (items->used > items->size) {
-        items->used = length;
-      }
-    }
-
-    if (F_status_is_error(status)) return status;
-
-    return F_none;
-  }
-#endif // !defined(_di_f_fss_items_adjust_) || !defined(_di_f_fss_items_decimate_by_)
-
-#if !defined(_di_f_fss_items_decrease_by_) || !defined(_di_f_fss_items_increase_) || !defined(_di_f_fss_items_increase_by_) || !defined(_di_f_fss_items_resize_)
-  f_status_t private_f_fss_items_resize(const f_number_unsigned_t length, f_fss_items_t * const items) {
-
-    f_status_t status = F_none;
-
-    for (f_number_unsigned_t i = length; i < items->size; ++i) {
-
-      status = f_string_ranges_resize(0, &items->array[i].content);
-      if (F_status_is_error(status)) return status;
-    } // for
-
-    status = f_memory_resize(items->size, length, sizeof(f_fss_item_t), (void **) & items->array);
-    if (F_status_is_error(status)) return status;
-
-    items->size = length;
-
-    if (items->used > items->size) {
-      items->used = length;
-    }
-
-    return F_none;
-  }
-#endif // !defined(_di_f_fss_items_decrease_by_) || !defined(_di_f_fss_items_increase_) || !defined(_di_f_fss_items_increase_by_) || !defined(_di_f_fss_items_resize_)
-
-#if !defined(_di_f_fss_nameds_adjust_) || !defined(_di_f_fss_nameds_decimate_by_)
-  f_status_t private_f_fss_named_adjust(const f_number_unsigned_t length, f_fss_named_t * const named) {
-
-    f_status_t status = F_none;
-
-    status = f_string_ranges_adjust(length, &named->objects);
-    if (F_status_is_error(status)) return status;
-
-    status = f_string_rangess_adjust(length, &named->contents);
-    if (F_status_is_error(status)) return status;
-
-    status = f_uint8ss_adjust(length, &named->quotess);
-    if (F_status_is_error(status)) return status;
-
-    return F_none;
-  }
-#endif // !defined(_di_f_fss_nameds_adjust_) || !defined(_di_f_fss_nameds_decimate_by_)
-
-#if !defined(_di_f_fss_nameds_decrease_by_) || !defined(_di_f_fss_nameds_increase_) || !defined(_di_f_fss_nameds_increase_by_) || !defined(_di_f_fss_nameds_resize_)
-  f_status_t private_f_fss_named_resize(const f_number_unsigned_t length, f_fss_named_t * const named) {
-
-    f_status_t status = F_none;
-
-    status = f_string_ranges_resize(length, &named->objects);
-    if (F_status_is_error(status)) return status;
-
-    status = f_string_rangess_resize(length, &named->contents);
-    if (F_status_is_error(status)) return status;
-
-    status = f_uint8ss_resize(length, &named->quotess);
-    if (F_status_is_error(status)) return status;
-
-    return F_none;
-  }
-#endif // !defined(_di_f_fss_nameds_decrease_by_) || !defined(_di_f_fss_nameds_increase_) || !defined(_di_f_fss_nameds_increase_by_) || !defined(_di_f_fss_nameds_resize_)
-
-#if !defined(_di_f_fss_nameds_adjust_) || !defined(_di_f_fss_nameds_decimate_by_)
-  f_status_t private_f_fss_nameds_adjust(const f_number_unsigned_t length, f_fss_nameds_t * const nameds) {
-
-    f_status_t status = F_none;
-
-    for (f_number_unsigned_t i = length; i < nameds->size; ++i) {
-
-      status = private_f_fss_named_adjust(0, &nameds->array[i]);
-      if (F_status_is_error(status)) return status;
-    } // for
-
-    status = f_memory_adjust(nameds->size, length, sizeof(f_fss_named_t), (void **) & nameds->array);
-
-    if (F_status_is_error_not(status)) {
-      nameds->size = length;
-
-      if (nameds->used > nameds->size) {
-        nameds->used = length;
-      }
-    }
-
-    if (F_status_is_error(status)) return status;
-
-    return F_none;
-  }
-#endif // !defined(_di_f_fss_nameds_adjust_) || !defined(_di_f_fss_nameds_decimate_by_)
-
-#if !defined(_di_f_fss_nameds_decrease_by_) || !defined(_di_f_fss_nameds_increase_) || !defined(_di_f_fss_nameds_increase_by_) || !defined(_di_f_fss_nameds_resize_)
-  f_status_t private_f_fss_nameds_resize(const f_number_unsigned_t length, f_fss_nameds_t * const nameds) {
-
-    f_status_t status = F_none;
-
-    for (f_number_unsigned_t i = length; i < nameds->size; ++i) {
-
-      status = private_f_fss_named_resize(0, &nameds->array[i]);
-      if (F_status_is_error(status)) return status;
-    } // for
-
-    status = f_memory_resize(nameds->size, length, sizeof(f_fss_named_t), (void **) & nameds->array);
-    if (F_status_is_error(status)) return status;
-
-    nameds->size = length;
-
-    if (nameds->used > nameds->size) {
-      nameds->used = length;
-    }
-
-    return F_none;
-  }
-#endif // !defined(_di_f_fss_nameds_decrease_by_) || !defined(_di_f_fss_nameds_increase_) || !defined(_di_f_fss_nameds_increase_by_) || !defined(_di_f_fss_nameds_resize_)
-
-#if !defined(_di_f_fss_nest_adjust_) || !defined(_di_f_fss_nest_decimate_by_)
-  f_status_t private_f_fss_nest_adjust(const f_number_unsigned_t length, f_fss_nest_t * const nest) {
-
-    f_status_t status = F_none;
-
-    for (f_number_unsigned_t i = length; i < nest->size; ++i) {
-
-      status = private_f_fss_items_adjust(0, &nest->depth[i]);
-      if (F_status_is_error(status)) return status;
-    } // for
-
-    status = f_memory_adjust(nest->size, length, sizeof(f_fss_items_t), (void **) & nest->depth);
-
-    if (F_status_is_error_not(status)) {
-      nest->size = length;
-
-      if (nest->used > nest->size) {
-        nest->used = length;
-      }
-    }
-
-    if (F_status_is_error(status)) return status;
-
-    return F_none;
-  }
-#endif // !defined(_di_f_fss_nest_adjust_) || !defined(_di_f_fss_nest_decimate_by_)
-
-#if !defined(_di_f_fss_nest_decrease_by_) || !defined(_di_f_fss_nest_increase_) || !defined(_di_f_fss_nest_increase_by_) || !defined(_di_f_fss_nest_resize_)
-  f_status_t private_f_fss_nest_resize(const f_number_unsigned_t length, f_fss_nest_t * const nest) {
-
-    f_status_t status = F_none;
-
-    for (f_number_unsigned_t i = length; i < nest->size; ++i) {
-
-      status = private_f_fss_items_resize(0, &nest->depth[i]);
-      if (F_status_is_error(status)) return status;
-    } // for
-
-    status = f_memory_resize(nest->size, length, sizeof(f_fss_items_t), (void **) & nest->depth);
-    if (F_status_is_error(status)) return status;
-
-    nest->size = length;
-
-    if (nest->used > nest->size) {
-      nest->used = length;
-    }
-
-    return F_none;
-  }
-#endif // !defined(_di_f_fss_nest_decrease_by_) || !defined(_di_f_fss_nest_increase_) || !defined(_di_f_fss_nest_increase_by_) || !defined(_di_f_fss_nest_resize_)
-
-#if !defined(_di_f_fss_nests_adjust_) || !defined(_di_f_fss_nests_decimate_by_)
-  f_status_t private_f_fss_nests_adjust(const f_number_unsigned_t length, f_fss_nests_t *nests) {
-
-    f_status_t status = F_none;
-
-    for (f_number_unsigned_t i = length; i < nests->size; ++i) {
-
-      status = private_f_fss_nest_adjust(0, &nests->array[i]);
-      if (F_status_is_error(status)) return status;
-    } // for
-
-    status = f_memory_adjust(nests->size, length, sizeof(f_fss_nest_t), (void **) & nests->array);
-
-    if (F_status_is_error_not(status)) {
-      nests->size = length;
-
-      if (nests->used > nests->size) {
-        nests->used = length;
-      }
-    }
-
-    if (F_status_is_error(status)) return status;
-
-    return F_none;
-  }
-#endif // !defined(_di_f_fss_nests_adjust_) || !defined(_di_f_fss_nests_decimate_by_)
-
-#if !defined(_di_f_fss_nests_decrease_by_) || !defined(_di_f_fss_nests_increase_) || !defined(_di_f_fss_nests_increase_by_) || !defined(_di_f_fss_nests_resize_)
-  f_status_t private_f_fss_nests_resize(const f_number_unsigned_t length, f_fss_nests_t * const nests) {
-
-    f_status_t status = F_none;
-
-    for (f_number_unsigned_t i = length; i < nests->size; ++i) {
-
-      status = private_f_fss_nest_resize(0, &nests->array[i]);
-      if (F_status_is_error(status)) return status;
-    } // for
-
-    status = f_memory_resize(nests->size, length, sizeof(f_fss_nest_t), (void **) & nests->array);
-    if (F_status_is_error(status)) return status;
-
-    nests->size = length;
-
-    if (nests->used > nests->size) {
-      nests->used = length;
-    }
-
-    return F_none;
-  }
-#endif // !defined(_di_f_fss_nests_decrease_by_) || !defined(_di_f_fss_nests_increase_) || !defined(_di_f_fss_nests_increase_by_) || !defined(_di_f_fss_nests_resize_)
-
-#if !defined(_di_f_fss_set_adjust_) || !defined(_di_f_fss_set_decimate_by_)
-  f_status_t private_f_fss_set_adjust(const f_number_unsigned_t length, f_fss_set_t * const set) {
-
-    f_status_t status = F_none;
-
-    status = f_string_ranges_adjust(length, &set->objects);
-    if (F_status_is_error(status)) return status;
-
-    status = f_string_rangess_adjust(length, &set->contents);
-    if (F_status_is_error(status)) return status;
-
-    return F_none;
-  }
-#endif // !defined(_di_f_fss_set_adjust_) || !defined(_di_f_fss_set_decimate_by_)
-
-#if !defined(_di_f_fss_set_decrease_by_) || !defined(_di_f_fss_set_increase_) || !defined(_di_f_fss_set_increase_by_) || !defined(_di_f_fss_set_resize_)
-  f_status_t private_f_fss_set_resize(const f_number_unsigned_t length, f_fss_set_t *set) {
-
-    f_status_t status = F_none;
-
-    status = f_string_ranges_resize(length, &set->objects);
-    if (F_status_is_error(status)) return status;
-
-    status = f_string_rangess_resize(length, &set->contents);
-    if (F_status_is_error(status)) return status;
-
-    return F_none;
-  }
-#endif // !defined(_di_f_fss_set_decrease_by_) || !defined(_di_f_fss_set_increase_) || !defined(_di_f_fss_set_increase_by_) || !defined(_di_f_fss_set_resize_)
-
-#if !defined(_di_f_fss_set_quote_adjust_) || !defined(_di_f_fss_set_quote_decimate_by_)
-  f_status_t private_f_fss_set_quote_adjust(const f_number_unsigned_t length, f_fss_set_quote_t * const set_quote) {
-
-    f_status_t status = F_none;
-
-    status = f_string_ranges_adjust(length, &set_quote->objects);
-    if (F_status_is_error(status)) return status;
-
-    status = f_string_rangess_adjust(length, &set_quote->contents);
-    if (F_status_is_error(status)) return status;
-
-    status = f_uint8s_adjust(length, &set_quote->objects_quote);
-    if (F_status_is_error(status)) return status;
-
-    status = f_uint8ss_adjust(length, &set_quote->contents_quote);
-    if (F_status_is_error(status)) return status;
-
-    return F_none;
-  }
-#endif // !defined(_di_f_fss_set_quote_adjust_) || !defined(_di_f_fss_set_quote_decimate_by_)
-
-#if !defined(_di_f_fss_set_quote_decrease_by_) || !defined(_di_f_fss_set_quote_increase_) || !defined(_di_f_fss_set_quote_increase_by_) || !defined(_di_f_fss_set_quote_resize_)
-  f_status_t private_f_fss_set_quote_resize(const f_number_unsigned_t length, f_fss_set_quote_t * const set_quote) {
-
-    f_status_t status = F_none;
-
-    status = f_string_ranges_resize(length, &set_quote->objects);
-    if (F_status_is_error(status)) return status;
-
-    status = f_string_rangess_resize(length, &set_quote->contents);
-    if (F_status_is_error(status)) return status;
-
-    status = f_uint8s_resize(length, &set_quote->objects_quote);
-    if (F_status_is_error(status)) return status;
-
-    status = f_uint8ss_resize(length, &set_quote->contents_quote);
-    if (F_status_is_error(status)) return status;
-
-    return F_none;
-  }
-#endif // !defined(_di_f_fss_set_quote_decrease_by_) || !defined(_di_f_fss_set_quote_increase_) || !defined(_di_f_fss_set_quote_increase_by_) || !defined(_di_f_fss_set_quote_resize_)
-
-#if !defined(_di_f_fss_set_quotes_adjust_) || !defined(_di_f_fss_set_quotes_decimate_by_)
-  f_status_t private_f_fss_set_quotes_adjust(const f_number_unsigned_t length, f_fss_set_quotes_t * const set_quotes) {
-
-    f_status_t status = F_none;
-
-    for (f_number_unsigned_t i = length; i < set_quotes->size; ++i) {
-
-      status = f_string_ranges_adjust(0, &set_quotes->array[i].objects);
-      if (F_status_is_error(status)) return status;
-
-      status = f_string_rangess_adjust(0, &set_quotes->array[i].contents);
-      if (F_status_is_error(status)) return status;
-
-      status = f_uint8s_adjust(0, &set_quotes->array[i].objects_quote);
-      if (F_status_is_error(status)) return status;
-
-      status = f_uint8ss_adjust(0, &set_quotes->array[i].contents_quote);
-      if (F_status_is_error(status)) return status;
-    } // for
-
-    status = f_memory_adjust(set_quotes->size, length, sizeof(f_fss_set_quote_t), (void **) & set_quotes->array);
-
-    if (F_status_is_error_not(status)) {
-      set_quotes->size = length;
-
-      if (set_quotes->used > set_quotes->size) {
-        set_quotes->used = length;
-      }
-    }
-
-    if (F_status_is_error(status)) return status;
-
-    return F_none;
-  }
-#endif // !defined(_di_f_fss_set_quotes_adjust_) || !defined(_di_f_fss_set_quotes_decimate_by_)
-
-#if !defined(_di_f_fss_set_quotes_decrease_by_) || !defined(_di_f_fss_set_quotes_increase_) || !defined(_di_f_fss_set_quotes_increase_by_) || !defined(_di_f_fss_set_quotes_resize_)
-  f_status_t private_f_fss_set_quotes_resize(const f_number_unsigned_t length, f_fss_set_quotes_t * const set_quotes) {
-
-    f_status_t status = F_none;
-
-    for (f_number_unsigned_t i = length; i < set_quotes->size; ++i) {
-
-      status = f_string_ranges_resize(0, &set_quotes->array[i].objects);
-      if (F_status_is_error(status)) return status;
-
-      status = f_string_rangess_resize(0, &set_quotes->array[i].contents);
-      if (F_status_is_error(status)) return status;
-
-      status = f_uint8s_resize(0, &set_quotes->array[i].objects_quote);
-      if (F_status_is_error(status)) return status;
-
-      status = f_uint8ss_resize(0, &set_quotes->array[i].contents_quote);
-      if (F_status_is_error(status)) return status;
-    } // for
-
-    status = f_memory_resize(set_quotes->size, length, sizeof(f_fss_set_quote_t), (void **) & set_quotes->array);
-    if (F_status_is_error(status)) return status;
-
-    set_quotes->size = length;
-
-    if (set_quotes->used > set_quotes->size) {
-      set_quotes->used = length;
-    }
-
-    return F_none;
-  }
-#endif // !defined(_di_f_fss_set_quotes_decrease_by_) || !defined(_di_f_fss_set_quotes_increase_) || !defined(_di_f_fss_set_quotes_increase_by_) || !defined(_di_f_fss_set_quotes_resize_)
-
-#if !defined(_di_f_fss_sets_adjust_) || !defined(_di_f_fss_sets_decimate_by_)
-  f_status_t private_f_fss_sets_adjust(const f_number_unsigned_t length, f_fss_sets_t * const sets) {
-
-    f_status_t status = F_none;
-
-    for (f_number_unsigned_t i = length; i < sets->size; ++i) {
-
-      status = f_string_ranges_adjust(0, &sets->array[i].objects);
-      if (F_status_is_error(status)) return status;
-
-      status = f_string_rangess_adjust(0, &sets->array[i].contents);
-      if (F_status_is_error(status)) return status;
-    } // for
-
-    status = f_memory_adjust(sets->size, length, sizeof(f_fss_set_t), (void **) & sets->array);
-
-    if (F_status_is_error_not(status)) {
-      sets->size = length;
-
-      if (sets->used > sets->size) {
-        sets->used = length;
-      }
-    }
-
-    if (F_status_is_error(status)) return status;
-
-    return F_none;
-  }
-#endif // !defined(_di_f_fss_sets_adjust_) || !defined(_di_f_fss_sets_decimate_by_)
-
-#if !defined(_di_f_fss_sets_decrease_by_) || !defined(_di_f_fss_sets_increase_) || !defined(_di_f_fss_sets_increase_by_) || !defined(_di_f_fss_sets_resize_)
-  f_status_t private_f_fss_sets_resize(const f_number_unsigned_t length, f_fss_sets_t * const sets) {
-
-    f_status_t status = F_none;
-
-    for (f_number_unsigned_t i = length; i < sets->size; ++i) {
-
-      status = f_string_ranges_resize(0, &sets->array[i].objects);
-      if (F_status_is_error(status)) return status;
-
-      status = f_string_rangess_resize(0, &sets->array[i].contents);
-      if (F_status_is_error(status)) return status;
-    } // for
-
-    status = f_memory_resize(sets->size, length, sizeof(f_fss_set_t), (void **) & sets->array);
-    if (F_status_is_error(status)) return status;
-
-    sets->size = length;
-
-    if (sets->used > sets->size) {
-      sets->used = length;
-    }
-
-    return F_none;
-  }
-#endif // !defined(_di_f_fss_sets_decrease_by_) || !defined(_di_f_fss_sets_increase_) || !defined(_di_f_fss_sets_increase_by_) || !defined(_di_f_fss_sets_resize_)
-
 #ifdef __cplusplus
 } // extern "C"
 #endif
index 5761ef0904f044a1569183e5623137c6dfdea578..97fad1eddf3151fcd8cc0057c2af4fdf3717bee1 100644 (file)
 extern "C" {
 #endif
 
-/**
- * Private implementation for resizing.
- *
- * Intended to be shared to each of the different implementation variations.
- *
- * @param length
- *   The new size to use.
- * @param items
- *   The items to adjust.
- *
- * @return
- *   F_none on success.
- *
- *   Errors (with error bit) from: macro_f_fss_item_t_adjust().
- *   Errors (with error bit) from: f_memory_adjust().
- *
- * @see macro_f_fss_item_t_adjust()
- *
- * @see f_fss_items_adjust()
- * @see f_fss_items_decimate_by()
- * @see f_memory_adjust()
- */
-#if !defined(_di_f_fss_items_adjust_) || !defined(_di_f_fss_items_decimate_by_)
-  extern f_status_t private_f_fss_items_adjust(const f_number_unsigned_t length, f_fss_items_t * const items) F_attribute_visibility_internal_d;
-#endif // !defined(_di_f_fss_items_adjust_) || !defined(_di_f_fss_items_decimate_by_)
-
-/**
- * Private implementation for resizing.
- *
- * Intended to be shared to each of the different implementation variations.
- *
- * @param length
- *   The new size to use.
- * @param items
- *   The items to resize.
- *
- * @return
- *   F_none on success.
- *
- *   Errors (with error bit) from: macro_f_fss_item_t_resize().
- *   Errors (with error bit) from: f_memory_resize().
- *
- * @see macro_f_fss_item_t_resize()
- *
- * @see f_fss_items_decrease_by()
- * @see f_fss_items_increase()
- * @see f_fss_items_increase_by()
- * @see f_fss_items_resize()
- * @see f_memory_resize()
- */
-#if !defined(_di_f_fss_items_decrease_by_) || !defined(_di_f_fss_items_increase_) || !defined(_di_f_fss_items_increase_by_) || !defined(_di_f_fss_items_resize_)
-  extern f_status_t private_f_fss_items_resize(const f_number_unsigned_t length, f_fss_items_t * const items) F_attribute_visibility_internal_d;
-#endif // !defined(_di_f_fss_items_decrease_by_) || !defined(_di_f_fss_items_increase_) || !defined(_di_f_fss_items_increase_by_) || !defined(_di_f_fss_items_resize_)
-
-/**
- * Private implementation for resizing.
- *
- * Intended to be shared to each of the different implementation variations.
- *
- * @param length
- *   The new size to use.
- * @param named
- *   The named to adjust.
- *
- * @return
- *   F_none on success.
- *
- *   Errors (with error bit) from: macro_f_string_ranges_t_adjust().
- *   Errors (with error bit) from: macro_f_string_rangess_t_adjust().
- *   Errors (with error bit) from: macro_f_uint8ss_t_adjust().
- *
- * @see macro_f_string_ranges_t_adjust()
- * @see macro_f_string_rangess_t_adjust()
- * @see macro_f_uint8ss_t_adjust()
- *
- * @see f_fss_nameds_adjust()
- * @see f_fss_nameds_decimate_by()
- */
-#if !defined(_di_f_fss_nameds_adjust_) || !defined(_di_f_fss_nameds_decimate_by_)
-  extern f_status_t private_f_fss_named_adjust(const f_number_unsigned_t length, f_fss_named_t * const named) F_attribute_visibility_internal_d;
-#endif // !defined(_di_f_fss_nameds_adjust_) || !defined(_di_f_fss_nameds_decimate_by_)
-
-/**
- * Private implementation for resizing.
- *
- * Intended to be shared to each of the different implementation variations.
- *
- * @param length
- *   The new size to use.
- * @param named
- *   The named to resize.
- *
- * @return
- *   F_none on success.
- *
- *   Errors (with error bit) from: macro_f_string_ranges_t_resize().
- *   Errors (with error bit) from: macro_f_string_rangess_t_resize().
- *   Errors (with error bit) from: macro_f_uint8ss_t_resize().
- *
- * @see macro_f_string_ranges_t_resize()
- * @see macro_f_string_rangess_t_resize()
- * @see macro_f_uint8ss_t_resize()
- *
- * @see f_fss_nameds_decrease_by()
- * @see f_fss_nameds_incease()
- * @see f_fss_nameds_incease_by()
- * @see f_fss_nameds_resize()
- */
-#if !defined(_di_f_fss_nameds_decrease_by_) || !defined(_di_f_fss_nameds_increase_) || !defined(_di_f_fss_nameds_increase_by_) || !defined(_di_f_fss_nameds_resize_)
-  extern f_status_t private_f_fss_named_resize(const f_number_unsigned_t length, f_fss_named_t * const named) F_attribute_visibility_internal_d;
-#endif // !defined(_di_f_fss_nameds_decrease_by_) || !defined(_di_f_fss_nameds_increase_) || !defined(_di_f_fss_nameds_increase_by_) || !defined(_di_f_fss_nameds_resize_)
-
-/**
- * Private implementation for resizing.
- *
- * Intended to be shared to each of the different implementation variations.
- *
- * @param length
- *   The new size to use.
- * @param nameds
- *   The nameds to adjust.
- *
- * @return
- *   F_none on success.
- *
- *   Errors (with error bit) from: f_memory_adjust().
- *   Errors (with error bit) from: private_f_fss_named_adjust().
- *
- * @see private_f_fss_named_adjust()
- *
- * @see f_fss_nameds_adjust()
- * @see f_fss_nameds_decimate_by()
- * @see f_memory_adjust()
- */
-#if !defined(_di_f_fss_nameds_adjust_) || !defined(_di_f_fss_nameds_decimate_by_)
-  extern f_status_t private_f_fss_nameds_adjust(const f_number_unsigned_t length, f_fss_nameds_t * const nameds) F_attribute_visibility_internal_d;
-#endif // !defined(_di_f_fss_nameds_adjust_) || !defined(_di_f_fss_nameds_decimate_by_)
-
-/**
- * Private implementation for resizing.
- *
- * Intended to be shared to each of the different implementation variations.
- *
- * @param length
- *   The new size to use.
- * @param nameds
- *   The nameds to resize.
- *
- * @return
- *   F_none on success.
- *
- *   Errors (with error bit) from: f_memory_resize().
- *   Errors (with error bit) from: private_f_fss_named_resize().
- *
- * @see private_f_fss_named_resize()
- *
- * @see f_fss_nameds_decrease_by()
- * @see f_fss_nameds_increase()
- * @see f_fss_nameds_increase_by()
- * @see f_fss_nameds_resize()
- * @see f_memory_resize()
- */
-#if !defined(_di_f_fss_nameds_decrease_by_) || !defined(_di_f_fss_nameds_increase_) || !defined(_di_f_fss_nameds_increase_by_) || !defined(_di_f_fss_nameds_resize_)
-  extern f_status_t private_f_fss_nameds_resize(const f_number_unsigned_t length, f_fss_nameds_t * const nameds) F_attribute_visibility_internal_d;
-#endif // !defined(_di_f_fss_nameds_decrease_by_) || !defined(_di_f_fss_nameds_increase_) || !defined(_di_f_fss_nameds_increase_by_) || !defined(_di_f_fss_nameds_resize_)
-
-/**
- * Private implementation for resizing.
- *
- * Intended to be shared to each of the different implementation variations.
- *
- * @param length
- *   The new size to use.
- * @param nest
- *   The nest to adjust.
- *
- * @return
- *   F_none on success.
- *
- *   Errors (with error bit) from: f_memory_adjust().
- *   Errors (with error bit) from: macro_f_fss_nest_t_adjust().
- *
- * @see macro_f_fss_nest_t_adjust()
- *
- * @see f_fss_nest_adjust()
- * @see f_fss_nest_decimate_by()
- * @see f_memory_adjust()
- */
-#if !defined(_di_f_fss_nest_adjust_) || !defined(_di_f_fss_nest_decimate_by_)
-  extern f_status_t private_f_fss_nest_adjust(const f_number_unsigned_t length, f_fss_nest_t * const nest) F_attribute_visibility_internal_d;
-#endif // !defined(_di_f_fss_nest_adjust_) || !defined(_di_f_fss_nest_decimate_by_)
-
-/**
- * Private implementation for resizing.
- *
- * Intended to be shared to each of the different implementation variations.
- *
- * @param length
- *   The new size to use.
- * @param nest
- *   The nest to resize.
- *
- * @return
- *   F_none on success.
- *
- *   Errors (with error bit) from: f_memory_resize().
- *   Errors (with error bit) from: macro_f_fss_nest_t_resize().
- *
- * @see macro_f_fss_nest_t_resize()
- *
- * @see f_fss_nest_decrease_by()
- * @see f_fss_nest_increase()
- * @see f_fss_nest_increase_by()
- * @see f_fss_nest_resize()
- * @see f_memory_resize()
- */
-#if !defined(_di_f_fss_nest_decrease_by_) || !defined(_di_f_fss_nest_increase_) || !defined(_di_f_fss_nest_increase_by_) || !defined(_di_f_fss_nest_resize_)
-  extern f_status_t private_f_fss_nest_resize(const f_number_unsigned_t length, f_fss_nest_t * const nest) F_attribute_visibility_internal_d;
-#endif // !defined(_di_f_fss_nest_decrease_by_) || !defined(_di_f_fss_nest_increase_) || !defined(_di_f_fss_nest_increase_by_) || !defined(_di_f_fss_nest_resize_)
-
-/**
- * Private implementation for resizing.
- *
- * Intended to be shared to each of the different implementation variations.
- *
- * @param length
- *   The new size to use.
- * @param nests
- *   The nests to adjust.
- *
- * @return
- *   F_none on success.
- *
- *   Errors (with error bit) from: f_memory_adjust().
- *   Errors (with error bit) from: macro_f_fss_nest_t_adjust().
- *
- * @see macro_f_fss_nest_t_adjust()
- *
- * @see f_fss_nests_adjust()
- * @see f_fss_nests_decimate_by()
- * @see f_memory_adjust()
- */
-#if !defined(_di_f_fss_nests_adjust_) || !defined(_di_f_fss_nests_decimate_by_)
-  extern f_status_t private_f_fss_nests_adjust(const f_number_unsigned_t length, f_fss_nests_t * const nests) F_attribute_visibility_internal_d;
-#endif // !defined(_di_f_fss_nests_adjust_) || !defined(_di_f_fss_nests_decimate_by_)
-
-/**
- * Private implementation for resizing.
- *
- * Intended to be shared to each of the different implementation variations.
- *
- * @param length
- *   The new size to use.
- * @param nests
- *   The nests to resize.
- *
- * @return
- *   F_none on success.
- *
- *   Errors (with error bit) from: f_memory_resize().
- *   Errors (with error bit) from: macro_f_fss_nest_t_resize().
- *
- * @see macro_f_fss_nest_t_resize()
- *
- * @see f_fss_nests_decrease_by()
- * @see f_fss_nests_increase()
- * @see f_fss_nests_increase_by()
- * @see f_fss_nests_resize()
- * @see f_memory_resize()
- */
-#if !defined(_di_f_fss_nests_decrease_by_) || !defined(_di_f_fss_nests_increase_) || !defined(_di_f_fss_nests_increase_by_) || !defined(_di_f_fss_nests_resize_)
-  extern f_status_t private_f_fss_nests_resize(const f_number_unsigned_t length, f_fss_nests_t * const nests) F_attribute_visibility_internal_d;
-#endif // !defined(_di_f_fss_nests_decrease_by_) || !defined(_di_f_fss_nests_increase_) || !defined(_di_f_fss_nests_increase_by_) || !defined(_di_f_fss_nests_resize_)
-
-/**
- * Private implementation for resizing.
- *
- * Intended to be shared to each of the different implementation variations.
- *
- * @param length
- *   The new size to use.
- * @param set
- *   The set to adjust.
- *
- * @return
- *   F_none on success.
- *
- *   Errors (with error bit) from: macro_f_fss_contents_t_adjust().
- *   Errors (with error bit) from: macro_f_fss_objects_t_adjust().
- *
- * @see macro_f_fss_contents_t_adjust()
- * @see macro_f_fss_objects_t_adjust()
- *
- * @see f_fss_set_adjust()
- * @see f_fss_set_decimate_by()
- */
-#if !defined(_di_f_fss_set_adjust_) || !defined(_di_f_fss_set_decimate_by_)
-  extern f_status_t private_f_fss_set_adjust(const f_number_unsigned_t length, f_fss_set_t * const set) F_attribute_visibility_internal_d;
-#endif // !defined(_di_f_fss_set_adjust_) || !defined(_di_f_fss_set_decimate_by_)
-
-/**
- * Private implementation for resizing.
- *
- * Intended to be shared to each of the different implementation variations.
- *
- * @param length
- *   The new size to use.
- * @param set
- *   The set to resize.
- *
- * @return
- *   F_none on success.
- *
- *   Errors (with error bit) from: macro_f_fss_contents_t_resize().
- *   Errors (with error bit) from: macro_f_fss_objects_t_resize().
- *
- * @see macro_f_fss_contents_t_resize()
- * @see macro_f_fss_objects_t_resize()
- *
- * @see f_fss_set_decrease_by()
- * @see f_fss_set_increase()
- * @see f_fss_set_increase_by()
- * @see f_fss_set_resize()
- */
-#if !defined(_di_f_fss_set_decrease_by_) || !defined(_di_f_fss_set_increase_) || !defined(_di_f_fss_set_increase_by_) || !defined(_di_f_fss_set_resize_)
-  extern f_status_t private_f_fss_set_resize(const f_number_unsigned_t length, f_fss_set_t * const set) F_attribute_visibility_internal_d;
-#endif // !defined(_di_f_fss_set_decrease_by_) || !defined(_di_f_fss_set_increase_) || !defined(_di_f_fss_set_increase_by_) || !defined(_di_f_fss_set_resize_)
-
-/**
- * Private implementation for resizing.
- *
- * Intended to be shared to each of the different implementation variations.
- *
- * @param length
- *   The new size to use.
- * @param set_quote
- *   The set_quote to adjust.
- *
- * @return
- *   F_none on success.
- *
- *   Errors (with error bit) from: macro_f_fss_contents_t_adjust().
- *   Errors (with error bit) from: macro_f_fss_objects_t_adjust().
- *   Errors (with error bit) from: macro_f_uint8s_t_adjust().
- *   Errors (with error bit) from: macro_f_uint8ss_t_adjust().
- *
- * @see macro_f_fss_contents_t_adjust()
- * @see macro_f_fss_objects_t_adjust()
- * @see macro_f_uint8s_t_adjust()
- * @see macro_f_uint8ss_t_adjust()
- *
- * @see f_fss_set_quote_adjust()
- * @see f_fss_set_quote_decimate_by()
- */
-#if !defined(_di_f_fss_set_quote_adjust_) || !defined(_di_f_fss_set_quote_decimate_by_)
-  extern f_status_t private_f_fss_set_quote_adjust(const f_number_unsigned_t length, f_fss_set_quote_t * const set_quote) F_attribute_visibility_internal_d;
-#endif // !defined(_di_f_fss_set_quote_adjust_) || !defined(_di_f_fss_set_quote_decimate_by_)
-
-/**
- * Private implementation for resizing.
- *
- * Intended to be shared to each of the different implementation variations.
- *
- * @param length
- *   The new size to use.
- * @param set_quote
- *   The set_quote to resize.
- *
- * @return
- *   F_none on success.
- *
- *   Errors (with error bit) from: macro_f_fss_contents_t_resize().
- *   Errors (with error bit) from: macro_f_fss_objects_t_resize().
- *   Errors (with error bit) from: macro_f_uint8s_t_resize().
- *   Errors (with error bit) from: macro_f_uint8ss_t_resize().
- *
- * @see macro_f_fss_contents_t_resize()
- * @see macro_f_fss_objects_t_resize()
- * @see macro_f_uint8s_t_resize()
- * @see macro_f_uint8ss_t_resize()
- *
- * @see f_fss_set_quote_decrease_by()
- * @see f_fss_set_quote_increase()
- * @see f_fss_set_quote_increase_by()
- * @see f_fss_set_quote_resize()
- */
-#if !defined(_di_f_fss_set_quote_decrease_by_) || !defined(_di_f_fss_set_quote_increase_) || !defined(_di_f_fss_set_quote_increase_by_) || !defined(_di_f_fss_set_quote_resize_)
-  extern f_status_t private_f_fss_set_quote_resize(const f_number_unsigned_t length, f_fss_set_quote_t * const set_quote) F_attribute_visibility_internal_d;
-#endif // !defined(_di_f_fss_set_quote_decrease_by_) || !defined(_di_f_fss_set_quote_increase_) || !defined(_di_f_fss_set_quote_increase_by_) || !defined(_di_f_fss_set_quote_resize_)
-
-/**
- * Private implementation for resizing.
- *
- * Intended to be shared to each of the different implementation variations.
- *
- * @param length
- *   The new size to use.
- * @param set_quotes
- *   The set_quotes to adjust.
- *
- * @return
- *   F_none on success.
- *
- *   Errors (with error bit) from: macro_f_fss_contents_t_adjust().
- *   Errors (with error bit) from: macro_f_fss_objects_t_adjust().
- *   Errors (with error bit) from: macro_f_uint8s_t_adjust().
- *   Errors (with error bit) from: macro_f_uint8ss_t_adjust().
- *   Errors (with error bit) from: f_memory_adjust().
- *
- * @see macro_f_fss_contents_t_adjust()
- * @see macro_f_fss_objects_t_adjust()
- * @see macro_f_uint8s_t_adjust()
- * @see macro_f_uint8ss_t_adjust()
- *
- * @see f_fss_set_quotes_adjust()
- * @see f_fss_set_quotes_decimate_by()
- * @see f_memory_adjust()
- */
-#if !defined(_di_f_fss_set_quotes_adjust_) || !defined(_di_f_fss_set_quotes_decimate_by_)
-  extern f_status_t private_f_fss_set_quotes_adjust(const f_number_unsigned_t length, f_fss_set_quotes_t * const set_quotes) F_attribute_visibility_internal_d;
-#endif // !defined(_di_f_fss_set_quotes_adjust_) || !defined(_di_f_fss_set_quotes_decimate_by_)
-
-/**
- * Private implementation for resizing.
- *
- * Intended to be shared to each of the different implementation variations.
- *
- * @param length
- *   The new size to use.
- * @param set_quotes
- *   The set_quotes to resize.
- *
- * @return
- *   F_none on success.
- *
- *   Errors (with error bit) from: macro_f_fss_contents_t_resize().
- *   Errors (with error bit) from: macro_f_fss_objects_t_resize().
- *   Errors (with error bit) from: macro_f_uint8s_t_resize().
- *   Errors (with error bit) from: macro_f_uint8ss_t_resize().
- *   Errors (with error bit) from: f_memory_resize().
- *
- * @see macro_f_fss_contents_t_resize()
- * @see macro_f_fss_objects_t_resize()
- * @see macro_f_uint8s_t_resize()
- * @see macro_f_uint8ss_t_resize()
- *
- * @see f_fss_set_quotes_decrease_by()
- * @see f_fss_set_quotes_increase()
- * @see f_fss_set_quotes_increase_by()
- * @see f_fss_set_quotes_resize()
- * @see f_memory_resize()
- */
-#if !defined(_di_f_fss_set_quotes_decrease_by_) || !defined(_di_f_fss_set_quotes_increase_) || !defined(_di_f_fss_set_quotes_increase_by_) || !defined(_di_f_fss_set_quotes_resize_)
-  extern f_status_t private_f_fss_set_quotes_resize(const f_number_unsigned_t length, f_fss_set_quotes_t * const set_quotes) F_attribute_visibility_internal_d;
-#endif // !defined(_di_f_fss_set_quotes_decrease_by_) || !defined(_di_f_fss_set_quotes_increase_) || !defined(_di_f_fss_set_quotes_increase_by_) || !defined(_di_f_fss_set_quotes_resize_)
-
-/**
- * Private implementation for resizing.
- *
- * Intended to be shared to each of the different implementation variations.
- *
- * @param length
- *   The new size to use.
- * @param sets
- *   The sets to adjust.
- *
- * @return
- *   F_none on success.
- *
- *   Errors (with error bit) from: macro_f_fss_contents_t_adjust().
- *   Errors (with error bit) from: macro_f_fss_objects_t_adjust().
- *   Errors (with error bit) from: f_memory_adjust().
- *
- * @see macro_f_fss_contents_t_adjust()
- * @see macro_f_fss_objects_t_adjust()
- *
- * @see f_fss_sets_adjust()
- * @see f_fss_sets_decimate_by()
- * @see f_memory_adjust()
- */
-#if !defined(_di_f_fss_sets_adjust_) || !defined(_di_f_fss_sets_decimate_by_)
-  extern f_status_t private_f_fss_sets_adjust(const f_number_unsigned_t length, f_fss_sets_t * const sets) F_attribute_visibility_internal_d;
-#endif // !defined(_di_f_fss_sets_adjust_) || !defined(_di_f_fss_sets_decimate_by_)
-
-/**
- * Private implementation for resizing.
- *
- * Intended to be shared to each of the different implementation variations.
- *
- * @param length
- *   The new size to use.
- * @param sets
- *   The sets to resize.
- *
- * @return
- *   F_none on success.
- *
- *   Errors (with error bit) from: macro_f_fss_contents_t_resize().
- *   Errors (with error bit) from: macro_f_fss_objects_t_resize().
- *   Errors (with error bit) from: f_memory_resize().
- *
- * @see macro_f_fss_contents_t_resize()
- * @see macro_f_fss_objects_t_resize()
- *
- * @see f_fss_sets_decrease_by()
- * @see f_fss_sets_increase()
- * @see f_fss_sets_increase_by()
- * @see f_fss_sets_resize()
- * @see f_memory_resize()
- */
-#if !defined(_di_f_fss_sets_decrease_by_) || !defined(_di_f_fss_sets_increase_) || !defined(_di_f_fss_sets_increase_by_) || !defined(_di_f_fss_sets_resize_)
-  extern f_status_t private_f_fss_sets_resize(const f_number_unsigned_t length, f_fss_sets_t * const sets) F_attribute_visibility_internal_d;
-#endif // !defined(_di_f_fss_sets_decrease_by_) || !defined(_di_f_fss_sets_increase_) || !defined(_di_f_fss_sets_increase_by_) || !defined(_di_f_fss_sets_resize_)
-
 #ifdef __cplusplus
 } // extern "C"
 #endif
index a70d27e9578c8a2bb295561e62746c5809eb6147..1ca3d788de1153f81cca4de5570e956a33538891 100644 (file)
@@ -31,9 +31,10 @@ build_language c
 build_libraries -lc
 build_libraries-individual -lf_memory -lf_string -lf_type_array -lf_utf
 
-build_sources_library fss.c private-fss.c fss/common.c fss/named.c fss/nest.c fss/set.c
+build_sources_library fss.c fss/common.c fss/item.c fss/named.c fss/nest.c fss/quote.c fss/set.c fss/set_quote.c fss/simple_packet.c
+build_sources_library fss/private-item.c fss/private-named.c fss/private-nest.c fss/private-set.c fss/private-set_quote.c fss/private-simple_packet.c
 
-build_sources_headers fss.h fss/comment.h fss/common.h fss/delimit.h fss/named.h fss/nest.h fss/quote.h fss/set.h
+build_sources_headers fss.h fss/common.h fss/item.h fss/named.h fss/nest.h fss/quote.h fss/set.h fss/set_quote.h fss/simple_packet.h
 
 build_script yes
 build_shared yes
index 00aef12d7ba77256308ee325aa6ec9302b4ed203..5ceaed37f75cfc99a367cbbbf09625cfb8b8c970 100644 (file)
@@ -30,9 +30,10 @@ build_language c
 build_libraries -lc
 build_libraries-individual -lf_memory -lf_string -lf_type_array -lf_utf
 
-build_sources_library fss.c private-fss.c fss/common.c fss/named.c fss/nest.c fss/set.c ../../tests/unit/c/mock-fss.c
+build_sources_library fss.c fss/common.c fss/item.c fss/named.c fss/nest.c fss/quote.c fss/set.c fss/set_quote.c fss/simple_packet.c ../../tests/unit/c/mock-fss.c
+build_sources_library fss/private-item.c fss/private-named.c fss/private-nest.c fss/private-set.c fss/private-set_quote.c fss/private-simple_packet.c
 
-build_sources_headers fss.h fss/comment.h fss/common.h fss/delimit.h fss/named.h fss/nest.h fss/quote.h fss/set.h
+build_sources_headers fss.h fss/common.h fss/item.h fss/named.h fss/nest.h fss/quote.h fss/set.h fss/set_quote.h fss/simple_packet.h
 
 build_script yes
 build_shared yes
index 47845959b088f62a127eb2e9dff1257a39a335c1..fc55b4dcf5cb82501d5f4a756ae6a8487ed295a8 100644 (file)
@@ -36,6 +36,7 @@ build_sources_program test-fss-set_adjust.c test-fss-set_decimate_by.c test-fss-
 build_sources_program test-fss-set_quote_adjust.c test-fss-set_quote_decimate_by.c test-fss-set_quote_decrease_by.c test-fss-set_quote_increase.c test-fss-set_quote_increase_by.c test-fss-set_quote_resize.c
 build_sources_program test-fss-set_quotes_adjust.c test-fss-set_quotes_decimate_by.c test-fss-set_quotes_decrease_by.c test-fss-set_quotes_increase.c test-fss-set_quotes_increase_by.c test-fss-set_quotes_resize.c
 build_sources_program test-fss-sets_adjust.c test-fss-sets_decimate_by.c test-fss-sets_decrease_by.c test-fss-sets_increase.c test-fss-sets_increase_by.c test-fss-sets_resize.c
+build_sources_program test-fss-simple_packet_ranges_adjust.c test-fss-simple_packet_ranges_decimate_by.c test-fss-simple_packet_ranges_decrease_by.c test-fss-simple_packet_ranges_increase.c test-fss-simple_packet_ranges_increase_by.c test-fss-simple_packet_ranges_resize.c
 
 build_sources_program test-fss.c
 
index d82d1cee98d79a14f9405cbb02ba6d703577ffee..b5c88ada40b6b64aec2fc48707655a8a821b71c1 100644 (file)
@@ -7,7 +7,7 @@ extern "C" {
 
 void test__f_fss_apply_delimit__parameter_checking(void **state) {
 
-  const f_fss_delimits_t delimits = f_fss_delimits_t_initialize;
+  const f_number_unsigneds_t delimits = f_number_unsigneds_t_initialize;
   f_state_t state_data = f_state_t_initialize;
 
   {
@@ -19,7 +19,7 @@ void test__f_fss_apply_delimit__parameter_checking(void **state) {
 
 void test__f_fss_apply_delimit__returns_data_not(void **state) {
 
-  const f_fss_delimits_t delimits = f_fss_delimits_t_initialize;
+  const f_number_unsigneds_t delimits = f_number_unsigneds_t_initialize;
   f_state_t state_data = f_state_t_initialize;
 
   {
@@ -63,52 +63,52 @@ void test__f_fss_apply_delimit__works(void **state) {
     macro_f_string_static_t_initialize_1("\0\0\0testå…¨\0est", 0, 14),
   };
 
-  f_fss_delimit_t delimits_0[] = {
-    macro_f_fss_delimit_t_initialize_1(tests[0].used + 2),
+  f_number_unsigned_t delimits_0[] = {
+    tests[0].used + 2,
   };
 
-  f_fss_delimit_t delimits_1[] = {
-    macro_f_fss_delimit_t_initialize_1(1),
+  f_number_unsigned_t delimits_1[] = {
+    1,
   };
 
-  f_fss_delimit_t delimits_2[] = {
-    macro_f_fss_delimit_t_initialize_1(1),
-    macro_f_fss_delimit_t_initialize_1(2),
+  f_number_unsigned_t delimits_2[] = {
+    1,
+    2,
   };
 
-  f_fss_delimit_t delimits_3[] = {
-    macro_f_fss_delimit_t_initialize_1(1),
-    macro_f_fss_delimit_t_initialize_1(3),
+  f_number_unsigned_t delimits_3[] = {
+    1,
+    3,
   };
 
-  f_fss_delimit_t delimits_4[] = {
-    macro_f_fss_delimit_t_initialize_1(0),
-    macro_f_fss_delimit_t_initialize_1(1),
-    macro_f_fss_delimit_t_initialize_1(3),
+  f_number_unsigned_t delimits_4[] = {
+    0,
+    1,
+    3,
   };
 
-  f_fss_delimit_t delimits_5[] = {
-    macro_f_fss_delimit_t_initialize_1(0),
-    macro_f_fss_delimit_t_initialize_1(1),
-    macro_f_fss_delimit_t_initialize_1(2),
-    macro_f_fss_delimit_t_initialize_1(3),
+  f_number_unsigned_t delimits_5[] = {
+    0,
+    1,
+    2,
+    3,
   };
 
-  f_fss_delimit_t delimits_6[] = {
-    macro_f_fss_delimit_t_initialize_1(0),
-    macro_f_fss_delimit_t_initialize_1(1),
-    macro_f_fss_delimit_t_initialize_1(2),
-    macro_f_fss_delimit_t_initialize_1(10),
+  f_number_unsigned_t delimits_6[] = {
+    0,
+    1,
+    2,
+    10,
   };
 
-  const f_fss_delimits_t delimitss[] = {
-    macro_f_fss_delimits_t_initialize_1(delimits_0, 0, 1),
-    macro_f_fss_delimits_t_initialize_1(delimits_1, 0, 1),
-    macro_f_fss_delimits_t_initialize_1(delimits_2, 0, 2),
-    macro_f_fss_delimits_t_initialize_1(delimits_3, 0, 2),
-    macro_f_fss_delimits_t_initialize_1(delimits_4, 0, 3),
-    macro_f_fss_delimits_t_initialize_1(delimits_5, 0, 4),
-    macro_f_fss_delimits_t_initialize_1(delimits_6, 0, 4),
+  const f_number_unsigneds_t delimitss[] = {
+    macro_f_number_unsigneds_t_initialize_1(delimits_0, 0, 1),
+    macro_f_number_unsigneds_t_initialize_1(delimits_1, 0, 1),
+    macro_f_number_unsigneds_t_initialize_1(delimits_2, 0, 2),
+    macro_f_number_unsigneds_t_initialize_1(delimits_3, 0, 2),
+    macro_f_number_unsigneds_t_initialize_1(delimits_4, 0, 3),
+    macro_f_number_unsigneds_t_initialize_1(delimits_5, 0, 4),
+    macro_f_number_unsigneds_t_initialize_1(delimits_6, 0, 4),
   };
 
   for (uint8_t i = 0; i < 7; ++i) {
index 1e3760f7cd3387687dd356f441618c6d2145dfeb..41507543e0a19ff9ffbabf07953e4cceb259dd1c 100644 (file)
@@ -7,7 +7,7 @@ extern "C" {
 
 void test__f_fss_apply_delimit_range__parameter_checking(void **state) {
 
-  const f_fss_delimits_t delimits = f_fss_delimits_t_initialize;
+  const f_number_unsigneds_t delimits = f_number_unsigneds_t_initialize;
   f_state_t state_data = f_state_t_initialize;
   const f_string_range_t range = f_string_range_t_initialize;
 
@@ -21,7 +21,7 @@ void test__f_fss_apply_delimit_range__parameter_checking(void **state) {
 void test__f_fss_apply_delimit_range__returns_data_not(void **state) {
 
   f_string_static_t test = macro_f_string_static_t_initialize_1("test", 0, 4);
-  const f_fss_delimits_t delimits = f_fss_delimits_t_initialize;
+  const f_number_unsigneds_t delimits = f_number_unsigneds_t_initialize;
   f_state_t state_data = f_state_t_initialize;
 
   {
@@ -83,52 +83,52 @@ void test__f_fss_apply_delimit_range__works(void **state) {
     macro_f_string_static_t_initialize_1("\0\0\0testå…¨\0est", 0, 14),
   };
 
-  f_fss_delimit_t delimits_0[] = {
-    macro_f_fss_delimit_t_initialize_1(tests[0].used + 2),
+  f_number_unsigned_t delimits_0[] = {
+    tests[0].used + 2,
   };
 
-  f_fss_delimit_t delimits_1[] = {
-    macro_f_fss_delimit_t_initialize_1(1),
+  f_number_unsigned_t delimits_1[] = {
+    1,
   };
 
-  f_fss_delimit_t delimits_2[] = {
-    macro_f_fss_delimit_t_initialize_1(1),
-    macro_f_fss_delimit_t_initialize_1(2),
+  f_number_unsigned_t delimits_2[] = {
+    1,
+    2,
   };
 
-  f_fss_delimit_t delimits_3[] = {
-    macro_f_fss_delimit_t_initialize_1(1),
-    macro_f_fss_delimit_t_initialize_1(3),
+  f_number_unsigned_t delimits_3[] = {
+    1,
+    3,
   };
 
-  f_fss_delimit_t delimits_4[] = {
-    macro_f_fss_delimit_t_initialize_1(0),
-    macro_f_fss_delimit_t_initialize_1(1),
-    macro_f_fss_delimit_t_initialize_1(3),
+  f_number_unsigned_t delimits_4[] = {
+    0,
+    1,
+    3,
   };
 
-  f_fss_delimit_t delimits_5[] = {
-    macro_f_fss_delimit_t_initialize_1(0),
-    macro_f_fss_delimit_t_initialize_1(1),
-    macro_f_fss_delimit_t_initialize_1(2),
-    macro_f_fss_delimit_t_initialize_1(3),
+  f_number_unsigned_t delimits_5[] = {
+    0,
+    1,
+    2,
+    3,
   };
 
-  f_fss_delimit_t delimits_6[] = {
-    macro_f_fss_delimit_t_initialize_1(0),
-    macro_f_fss_delimit_t_initialize_1(1),
-    macro_f_fss_delimit_t_initialize_1(2),
-    macro_f_fss_delimit_t_initialize_1(10),
+  f_number_unsigned_t delimits_6[] = {
+    0,
+    1,
+    2,
+    10,
   };
 
-  const f_fss_delimits_t delimitss[] = {
-    macro_f_fss_delimits_t_initialize_1(delimits_0, 0, 1),
-    macro_f_fss_delimits_t_initialize_1(delimits_1, 0, 1),
-    macro_f_fss_delimits_t_initialize_1(delimits_2, 0, 2),
-    macro_f_fss_delimits_t_initialize_1(delimits_3, 0, 2),
-    macro_f_fss_delimits_t_initialize_1(delimits_4, 0, 3),
-    macro_f_fss_delimits_t_initialize_1(delimits_5, 0, 4),
-    macro_f_fss_delimits_t_initialize_1(delimits_6, 0, 4),
+  const f_number_unsigneds_t delimitss[] = {
+    macro_f_number_unsigneds_t_initialize_1(delimits_0, 0, 1),
+    macro_f_number_unsigneds_t_initialize_1(delimits_1, 0, 1),
+    macro_f_number_unsigneds_t_initialize_1(delimits_2, 0, 2),
+    macro_f_number_unsigneds_t_initialize_1(delimits_3, 0, 2),
+    macro_f_number_unsigneds_t_initialize_1(delimits_4, 0, 3),
+    macro_f_number_unsigneds_t_initialize_1(delimits_5, 0, 4),
+    macro_f_number_unsigneds_t_initialize_1(delimits_6, 0, 4),
   };
 
   for (uint8_t i = 0; i < 7; ++i) {
diff --git a/level_0/f_fss/tests/unit/c/test-fss-simple_packet_ranges_adjust.c b/level_0/f_fss/tests/unit/c/test-fss-simple_packet_ranges_adjust.c
new file mode 100644 (file)
index 0000000..1c6e876
--- /dev/null
@@ -0,0 +1,42 @@
+#include "test-fss.h"
+#include "test-fss-simple_packet_ranges_adjust.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+void test__f_fss_simple_packet_ranges_adjust__parameter_checking(void **state) {
+
+  const int length = 5;
+  f_fss_simple_packet_ranges_t data = f_fss_simple_packet_ranges_t_initialize;
+
+  {
+    const f_status_t status = f_fss_simple_packet_ranges_adjust(length, 0);
+
+    assert_int_equal(status, F_status_set_error(F_parameter));
+    assert_int_equal(data.used, 0);
+    assert_int_equal(data.size, 0);
+  }
+
+  assert_null(data.array);
+}
+
+void test__f_fss_simple_packet_ranges_adjust__works(void **state) {
+
+  const int length = 5;
+  f_fss_simple_packet_ranges_t data = f_fss_simple_packet_ranges_t_initialize;
+
+  {
+    const f_status_t status = f_fss_simple_packet_ranges_adjust(length, &data);
+
+    assert_int_equal(status, F_none);
+    assert_int_equal(data.used, 0);
+    assert_int_equal(data.size, length);
+  }
+
+  free((void *) data.array);
+}
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
diff --git a/level_0/f_fss/tests/unit/c/test-fss-simple_packet_ranges_adjust.h b/level_0/f_fss/tests/unit/c/test-fss-simple_packet_ranges_adjust.h
new file mode 100644 (file)
index 0000000..82c3ee0
--- /dev/null
@@ -0,0 +1,27 @@
+/**
+ * FLL - Level 0
+ *
+ * Project: FSS
+ * API Version: 0.7
+ * Licenses: lgpl-2.1-or-later
+ *
+ * Test set quote adjust in the fss project.
+ */
+#ifndef _TEST__F_fss__simple_packet_range_adjust
+#define _TEST__F_fss__simple_packet_range_adjust
+
+/**
+ * Test that the function correctly fails on invalid parameter.
+ *
+ * @see f_fss_simple_packet_ranges_adjust()
+ */
+extern void test__f_fss_simple_packet_ranges_adjust__parameter_checking(void **state);
+
+/**
+ * Test that the function works.
+ *
+ * @see f_fss_simple_packet_ranges_adjust()
+ */
+extern void test__f_fss_simple_packet_ranges_adjust__works(void **state);
+
+#endif // _TEST__F_fss__simple_packet_range_adjust
diff --git a/level_0/f_fss/tests/unit/c/test-fss-simple_packet_ranges_decimate_by.c b/level_0/f_fss/tests/unit/c/test-fss-simple_packet_ranges_decimate_by.c
new file mode 100644 (file)
index 0000000..e057b15
--- /dev/null
@@ -0,0 +1,73 @@
+#include "test-fss.h"
+#include "test-fss-simple_packet_ranges_decimate_by.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+void test__f_fss_simple_packet_ranges_decimate_by__parameter_checking(void **state) {
+
+  const int length = 5;
+  f_fss_simple_packet_ranges_t data = f_fss_simple_packet_ranges_t_initialize;
+
+  {
+    const f_status_t status = f_fss_simple_packet_ranges_decimate_by(length, 0);
+
+    assert_int_equal(status, F_status_set_error(F_parameter));
+    assert_int_equal(data.size, 0);
+  }
+
+  assert_null(data.array);
+}
+
+void test__f_fss_simple_packet_ranges_decimate_by__returns_data_not(void **state) {
+
+  const int length = 5;
+  f_fss_simple_packet_ranges_t data = f_fss_simple_packet_ranges_t_initialize;
+
+  {
+    const f_status_t status = f_fss_simple_packet_ranges_resize(length, &data);
+
+    assert_int_equal(status, F_none);
+    assert_int_equal(data.used, 0);
+    assert_int_equal(data.size, length);
+  }
+
+  {
+    const f_status_t status = f_fss_simple_packet_ranges_decimate_by(0, &data);
+
+    assert_int_equal(status, F_data_not);
+    assert_int_equal(data.used, 0);
+    assert_int_equal(data.size, length);
+  }
+
+  free((void *) data.array);
+}
+
+void test__f_fss_simple_packet_ranges_decimate_by__works(void **state) {
+
+  const int length = 5;
+  f_fss_simple_packet_ranges_t data = f_fss_simple_packet_ranges_t_initialize;
+
+  {
+    const f_status_t status = f_fss_simple_packet_ranges_resize(length, &data);
+
+    assert_int_equal(status, F_none);
+    assert_int_equal(data.used, 0);
+    assert_int_equal(data.size, length);
+  }
+
+  {
+    const f_status_t status = f_fss_simple_packet_ranges_decimate_by(length, &data);
+
+    assert_int_equal(status, F_none);
+    assert_int_equal(data.used, 0);
+    assert_int_equal(data.size, 0);
+  }
+
+  assert_null(data.array);
+}
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
diff --git a/level_0/f_fss/tests/unit/c/test-fss-simple_packet_ranges_decimate_by.h b/level_0/f_fss/tests/unit/c/test-fss-simple_packet_ranges_decimate_by.h
new file mode 100644 (file)
index 0000000..adda67e
--- /dev/null
@@ -0,0 +1,34 @@
+/**
+ * FLL - Level 0
+ *
+ * Project: FSS
+ * API Version: 0.7
+ * Licenses: lgpl-2.1-or-later
+ *
+ * Test set quote decimate by in the fss project.
+ */
+#ifndef _TEST__F_fss__simple_packet_range_decimate_by
+#define _TEST__F_fss__simple_packet_range_decimate_by
+
+/**
+ * Test that the function correctly fails on invalid parameter.
+ *
+ * @see f_fss_simple_packet_ranges_decimate_by()
+ */
+extern void test__f_fss_simple_packet_ranges_decimate_by__parameter_checking(void **state);
+
+/**
+ * Test that the function returns F_data_not.
+ *
+ * @see f_fss_simple_packet_ranges_decimate_by()
+ */
+extern void test__f_fss_simple_packet_ranges_decimate_by__returns_data_not(void **state);
+
+/**
+ * Test that the function works.
+ *
+ * @see f_fss_simple_packet_ranges_decimate_by()
+ */
+extern void test__f_fss_simple_packet_ranges_decimate_by__works(void **state);
+
+#endif // _TEST__F_fss__simple_packet_range_decimate_by
diff --git a/level_0/f_fss/tests/unit/c/test-fss-simple_packet_ranges_decrease_by.c b/level_0/f_fss/tests/unit/c/test-fss-simple_packet_ranges_decrease_by.c
new file mode 100644 (file)
index 0000000..7e64850
--- /dev/null
@@ -0,0 +1,73 @@
+#include "test-fss.h"
+#include "test-fss-simple_packet_ranges_decrease_by.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+void test__f_fss_simple_packet_ranges_decrease_by__parameter_checking(void **state) {
+
+  const int length = 5;
+  f_fss_simple_packet_ranges_t data = f_fss_simple_packet_ranges_t_initialize;
+
+  {
+    const f_status_t status = f_fss_simple_packet_ranges_decrease_by(length, 0);
+
+    assert_int_equal(status, F_status_set_error(F_parameter));
+    assert_int_equal(data.size, 0);
+  }
+
+  assert_null(data.array);
+}
+
+void test__f_fss_simple_packet_ranges_decrease_by__returns_data_not(void **state) {
+
+  const int length = 5;
+  f_fss_simple_packet_ranges_t data = f_fss_simple_packet_ranges_t_initialize;
+
+  {
+    const f_status_t status = f_fss_simple_packet_ranges_resize(length, &data);
+
+    assert_int_equal(status, F_none);
+    assert_int_equal(data.used, 0);
+    assert_int_equal(data.size, length);
+  }
+
+  {
+    const f_status_t status = f_fss_simple_packet_ranges_decrease_by(0, &data);
+
+    assert_int_equal(status, F_data_not);
+    assert_int_equal(data.used, 0);
+    assert_int_equal(data.size, length);
+  }
+
+  free((void *) data.array);
+}
+
+void test__f_fss_simple_packet_ranges_decrease_by__works(void **state) {
+
+  const int length = 5;
+  f_fss_simple_packet_ranges_t data = f_fss_simple_packet_ranges_t_initialize;
+
+  {
+    const f_status_t status = f_fss_simple_packet_ranges_resize(length, &data);
+
+    assert_int_equal(status, F_none);
+    assert_int_equal(data.used, 0);
+    assert_int_equal(data.size, length);
+  }
+
+  {
+    const f_status_t status = f_fss_simple_packet_ranges_decrease_by(length, &data);
+
+    assert_int_equal(status, F_none);
+    assert_int_equal(data.used, 0);
+    assert_int_equal(data.size, 0);
+  }
+
+  assert_null(data.array);
+}
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
diff --git a/level_0/f_fss/tests/unit/c/test-fss-simple_packet_ranges_decrease_by.h b/level_0/f_fss/tests/unit/c/test-fss-simple_packet_ranges_decrease_by.h
new file mode 100644 (file)
index 0000000..dcc9acf
--- /dev/null
@@ -0,0 +1,34 @@
+/**
+ * FLL - Level 0
+ *
+ * Project: FSS
+ * API Version: 0.7
+ * Licenses: lgpl-2.1-or-later
+ *
+ * Test set quote decrease by in the fss project.
+ */
+#ifndef _TEST__F_fss__simple_packet_range_decrease_by
+#define _TEST__F_fss__simple_packet_range_decrease_by
+
+/**
+ * Test that the function correctly fails on invalid parameter.
+ *
+ * @see f_fss_simple_packet_ranges_decrease_by()
+ */
+extern void test__f_fss_simple_packet_ranges_decrease_by__parameter_checking(void **state);
+
+/**
+ * Test that the function returns F_data_not.
+ *
+ * @see f_fss_simple_packet_ranges_decrease_by()
+ */
+extern void test__f_fss_simple_packet_ranges_decrease_by__returns_data_not(void **state);
+
+/**
+ * Test that the function works.
+ *
+ * @see f_fss_simple_packet_ranges_decrease_by()
+ */
+extern void test__f_fss_simple_packet_ranges_decrease_by__works(void **state);
+
+#endif // _TEST__F_fss__simple_packet_range_decrease_by
diff --git a/level_0/f_fss/tests/unit/c/test-fss-simple_packet_ranges_increase.c b/level_0/f_fss/tests/unit/c/test-fss-simple_packet_ranges_increase.c
new file mode 100644 (file)
index 0000000..119f1f8
--- /dev/null
@@ -0,0 +1,75 @@
+#include "test-fss.h"
+#include "test-fss-simple_packet_ranges_increase.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+void test__f_fss_simple_packet_ranges_increase__parameter_checking(void **state) {
+
+  const int length = 5;
+  f_fss_simple_packet_ranges_t data = f_fss_simple_packet_ranges_t_initialize;
+
+  {
+    const f_status_t status = f_fss_simple_packet_ranges_increase(length, 0);
+
+    assert_int_equal(status, F_status_set_error(F_parameter));
+    assert_int_equal(data.size, 0);
+  }
+
+  assert_null(data.array);
+}
+
+void test__f_fss_simple_packet_ranges_increase__returns_data_not(void **state) {
+
+  const int length = 5;
+  f_fss_simple_packet_ranges_t data = f_fss_simple_packet_ranges_t_initialize;
+
+  {
+    const f_status_t status = f_fss_simple_packet_ranges_resize(length, &data);
+
+    assert_int_equal(status, F_none);
+    assert_int_equal(data.used, 0);
+    assert_int_equal(data.size, length);
+  }
+
+  {
+    const f_status_t status = f_fss_simple_packet_ranges_increase(length, &data);
+
+    assert_int_equal(status, F_data_not);
+    assert_int_equal(data.used, 0);
+    assert_int_equal(data.size, length);
+  }
+
+  free((void *) data.array);
+}
+
+void test__f_fss_simple_packet_ranges_increase__works(void **state) {
+
+  const int length = 5;
+  f_fss_simple_packet_ranges_t data = f_fss_simple_packet_ranges_t_initialize;
+
+  {
+    const f_status_t status = f_fss_simple_packet_ranges_resize(length, &data);
+
+    assert_int_equal(status, F_none);
+    assert_int_equal(data.used, 0);
+    assert_int_equal(data.size, length);
+  }
+
+  {
+    data.used = length;
+
+    const f_status_t status = f_fss_simple_packet_ranges_increase(1, &data);
+
+    assert_int_equal(status, F_none);
+    assert_int_equal(data.used, length);
+    assert_int_equal(data.size, length + 1);
+  }
+
+  free((void *) data.array);
+}
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
diff --git a/level_0/f_fss/tests/unit/c/test-fss-simple_packet_ranges_increase.h b/level_0/f_fss/tests/unit/c/test-fss-simple_packet_ranges_increase.h
new file mode 100644 (file)
index 0000000..c2f8e03
--- /dev/null
@@ -0,0 +1,34 @@
+/**
+ * FLL - Level 0
+ *
+ * Project: FSS
+ * API Version: 0.7
+ * Licenses: lgpl-2.1-or-later
+ *
+ * Test set quote increase in the fss project.
+ */
+#ifndef _TEST__F_fss__simple_packet_range_increase
+#define _TEST__F_fss__simple_packet_range_increase
+
+/**
+ * Test that the function correctly fails on invalid parameter.
+ *
+ * @see f_fss_simple_packet_ranges_increase()
+ */
+extern void test__f_fss_simple_packet_ranges_increase__parameter_checking(void **state);
+
+/**
+ * Test that the function returns F_data_not.
+ *
+ * @see f_fss_simple_packet_ranges_increase()
+ */
+extern void test__f_fss_simple_packet_ranges_increase__returns_data_not(void **state);
+
+/**
+ * Test that the function works.
+ *
+ * @see f_fss_simple_packet_ranges_increase()
+ */
+extern void test__f_fss_simple_packet_ranges_increase__works(void **state);
+
+#endif // _TEST__F_fss__simple_packet_range_increase
diff --git a/level_0/f_fss/tests/unit/c/test-fss-simple_packet_ranges_increase_by.c b/level_0/f_fss/tests/unit/c/test-fss-simple_packet_ranges_increase_by.c
new file mode 100644 (file)
index 0000000..82d4da6
--- /dev/null
@@ -0,0 +1,76 @@
+#include "test-fss.h"
+#include "test-fss-simple_packet_ranges_increase_by.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+void test__f_fss_simple_packet_ranges_increase_by__parameter_checking(void **state) {
+
+  const int length = 5;
+  f_fss_simple_packet_ranges_t data = f_fss_simple_packet_ranges_t_initialize;
+
+  {
+    const f_status_t status = f_fss_simple_packet_ranges_increase_by(length, 0);
+
+    assert_int_equal(status, F_status_set_error(F_parameter));
+    assert_int_equal(data.used, 0);
+    assert_int_equal(data.size, 0);
+  }
+
+  assert_null(data.array);
+}
+
+void test__f_fss_simple_packet_ranges_increase_by__returns_data_not(void **state) {
+
+  const int length = 5;
+  f_fss_simple_packet_ranges_t data = f_fss_simple_packet_ranges_t_initialize;
+
+  {
+    const f_status_t status = f_fss_simple_packet_ranges_resize(length, &data);
+
+    assert_int_equal(status, F_none);
+    assert_int_equal(data.used, 0);
+    assert_int_equal(data.size, length);
+  }
+
+  {
+    const f_status_t status = f_fss_simple_packet_ranges_increase_by(0, &data);
+
+    assert_int_equal(status, F_data_not);
+    assert_int_equal(data.used, 0);
+    assert_int_equal(data.size, length);
+  }
+
+  free((void *) data.array);
+}
+
+void test__f_fss_simple_packet_ranges_increase_by__works(void **state) {
+
+  const int length = 5;
+  f_fss_simple_packet_ranges_t data = f_fss_simple_packet_ranges_t_initialize;
+
+  {
+    const f_status_t status = f_fss_simple_packet_ranges_resize(length, &data);
+
+    assert_int_equal(status, F_none);
+    assert_int_equal(data.used, 0);
+    assert_int_equal(data.size, length);
+  }
+
+  {
+    data.used = length;
+
+    const f_status_t status = f_fss_simple_packet_ranges_increase_by(length, &data);
+
+    assert_int_equal(status, F_none);
+    assert_int_equal(data.used, length);
+    assert_int_equal(data.size, length * 2);
+  }
+
+  free((void *) data.array);
+}
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
diff --git a/level_0/f_fss/tests/unit/c/test-fss-simple_packet_ranges_increase_by.h b/level_0/f_fss/tests/unit/c/test-fss-simple_packet_ranges_increase_by.h
new file mode 100644 (file)
index 0000000..0398704
--- /dev/null
@@ -0,0 +1,34 @@
+/**
+ * FLL - Level 0
+ *
+ * Project: FSS
+ * API Version: 0.7
+ * Licenses: lgpl-2.1-or-later
+ *
+ * Test set quote increase by in the fss project.
+ */
+#ifndef _TEST__F_fss__simple_packet_range_increase_by
+#define _TEST__F_fss__simple_packet_range_increase_by
+
+/**
+ * Test that the function correctly fails on invalid parameter.
+ *
+ * @see f_fss_simple_packet_ranges_increase_by()
+ */
+extern void test__f_fss_simple_packet_ranges_increase_by__parameter_checking(void **state);
+
+/**
+ * Test that the function returns F_data_not.
+ *
+ * @see f_fss_simple_packet_ranges_increase_by()
+ */
+extern void test__f_fss_simple_packet_ranges_increase_by__returns_data_not(void **state);
+
+/**
+ * Test that the function works.
+ *
+ * @see f_fss_simple_packet_ranges_increase_by()
+ */
+extern void test__f_fss_simple_packet_ranges_increase_by__works(void **state);
+
+#endif // _TEST__F_fss__simple_packet_range_increase_by
diff --git a/level_0/f_fss/tests/unit/c/test-fss-simple_packet_ranges_resize.c b/level_0/f_fss/tests/unit/c/test-fss-simple_packet_ranges_resize.c
new file mode 100644 (file)
index 0000000..74c7833
--- /dev/null
@@ -0,0 +1,42 @@
+#include "test-fss.h"
+#include "test-fss-simple_packet_ranges_resize.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+void test__f_fss_simple_packet_ranges_resize__parameter_checking(void **state) {
+
+  const int length = 5;
+  f_fss_simple_packet_ranges_t data = f_fss_simple_packet_ranges_t_initialize;
+
+  {
+    const f_status_t status = f_fss_simple_packet_ranges_resize(length, 0);
+
+    assert_int_equal(status, F_status_set_error(F_parameter));
+    assert_int_equal(data.used, 0);
+    assert_int_equal(data.size, 0);
+  }
+
+  assert_null(data.array);
+}
+
+void test__f_fss_simple_packet_ranges_resize__works(void **state) {
+
+  const int length = 5;
+  f_fss_simple_packet_ranges_t data = f_fss_simple_packet_ranges_t_initialize;
+
+  {
+    const f_status_t status = f_fss_simple_packet_ranges_resize(length, &data);
+
+    assert_int_equal(status, F_none);
+    assert_int_equal(data.used, 0);
+    assert_int_equal(data.size, length);
+  }
+
+  free((void *) data.array);
+}
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
diff --git a/level_0/f_fss/tests/unit/c/test-fss-simple_packet_ranges_resize.h b/level_0/f_fss/tests/unit/c/test-fss-simple_packet_ranges_resize.h
new file mode 100644 (file)
index 0000000..9de1e1c
--- /dev/null
@@ -0,0 +1,27 @@
+/**
+ * FLL - Level 0
+ *
+ * Project: FSS
+ * API Version: 0.7
+ * Licenses: lgpl-2.1-or-later
+ *
+ * Test set quote resize in the fss project.
+ */
+#ifndef _TEST__F_fss__simple_packet_range_resize
+#define _TEST__F_fss__simple_packet_range_resize
+
+/**
+ * Test that the function correctly fails on invalid parameter.
+ *
+ * @see f_fss_simple_packet_ranges_resize()
+ */
+extern void test__f_fss_simple_packet_ranges_resize__parameter_checking(void **state);
+
+/**
+ * Test that the function works.
+ *
+ * @see f_fss_simple_packet_ranges_resize()
+ */
+extern void test__f_fss_simple_packet_ranges_resize__works(void **state);
+
+#endif // _TEST__F_fss__simple_packet_range_resize
index 70c1057fdd05c204cb847b2309b2dbce770908a3..96f28171befffc6d9a3f82f3e969e50064143d6f 100644 (file)
@@ -90,6 +90,11 @@ int main(void) {
     cmocka_unit_test(test__f_fss_sets_increase__returns_data_not),
     cmocka_unit_test(test__f_fss_sets_increase_by__returns_data_not),
 
+    cmocka_unit_test(test__f_fss_simple_packet_ranges_decimate_by__returns_data_not),
+    cmocka_unit_test(test__f_fss_simple_packet_ranges_decrease_by__returns_data_not),
+    cmocka_unit_test(test__f_fss_simple_packet_ranges_increase__returns_data_not),
+    cmocka_unit_test(test__f_fss_simple_packet_ranges_increase_by__returns_data_not),
+
     #ifndef _di_level_0_parameter_checking_
       cmocka_unit_test(test__f_fss_apply_delimit__parameter_checking),
       cmocka_unit_test(test__f_fss_apply_delimit_range__parameter_checking),
@@ -167,6 +172,13 @@ int main(void) {
       cmocka_unit_test(test__f_fss_sets_increase__parameter_checking),
       cmocka_unit_test(test__f_fss_sets_increase_by__parameter_checking),
       cmocka_unit_test(test__f_fss_sets_resize__parameter_checking),
+
+      cmocka_unit_test(test__f_fss_simple_packet_ranges_adjust__parameter_checking),
+      cmocka_unit_test(test__f_fss_simple_packet_ranges_decimate_by__parameter_checking),
+      cmocka_unit_test(test__f_fss_simple_packet_ranges_decrease_by__parameter_checking),
+      cmocka_unit_test(test__f_fss_simple_packet_ranges_increase__parameter_checking),
+      cmocka_unit_test(test__f_fss_simple_packet_ranges_increase_by__parameter_checking),
+      cmocka_unit_test(test__f_fss_simple_packet_ranges_resize__parameter_checking),
     #endif // _di_level_0_parameter_checking_
   };
 
index 8bba3420476f4bf4b333f7deae52c700daacf465..4943df7a354e52ecb1f62316e43104d78844a043 100644 (file)
 #include "test-fss-sets_increase.h"
 #include "test-fss-sets_increase_by.h"
 #include "test-fss-sets_resize.h"
+#include "test-fss-simple_packet_ranges_adjust.h"
+#include "test-fss-simple_packet_ranges_decimate_by.h"
+#include "test-fss-simple_packet_ranges_decrease_by.h"
+#include "test-fss-simple_packet_ranges_increase.h"
+#include "test-fss-simple_packet_ranges_increase_by.h"
+#include "test-fss-simple_packet_ranges_resize.h"
 #include "test-fss-skip_past_delimit.h"
 #include "test-fss-skip_past_space.h"
 
index dccfa6418f8e2116da3b9149087fc95dc3e0889e..59c12c6ded2787649974cb688da0ca8e666a967e 100644 (file)
@@ -396,6 +396,8 @@ extern "C" {
       F_parameter_not,
       F_parent,
       F_parent_not,
+      F_partial,
+      F_partial_not,
       F_payload,
       F_payload_not,
       F_pipe,
index 6ee1e08fc09f3983dda020c66c3030e8c1cb5495..778f449d081c36bcbcf61d3c5b555744e1a83104 100644 (file)
@@ -270,6 +270,8 @@ extern "C" {
     const f_string_static_t f_status_parameter_not_s = macro_f_string_static_t_initialize_1(F_status_parameter_not_s, 0, F_status_parameter_not_s_length);
     const f_string_static_t f_status_parent_s = macro_f_string_static_t_initialize_1(F_status_parent_s, 0, F_status_parent_s_length);
     const f_string_static_t f_status_parent_not_s = macro_f_string_static_t_initialize_1(F_status_parent_not_s, 0, F_status_parent_not_s_length);
+    const f_string_static_t f_status_partial_s = macro_f_string_static_t_initialize_1(F_status_partial_s, 0, F_status_partial_s_length);
+    const f_string_static_t f_status_partial_not_s = macro_f_string_static_t_initialize_1(F_status_partial_not_s, 0, F_status_partial_not_s_length);
     const f_string_static_t f_status_payload_s = macro_f_string_static_t_initialize_1(F_status_payload_s, 0, F_status_payload_s_length);
     const f_string_static_t f_status_payload_not_s = macro_f_string_static_t_initialize_1(F_status_payload_not_s, 0, F_status_payload_not_s_length);
     const f_string_static_t f_status_pipe_s = macro_f_string_static_t_initialize_1(F_status_pipe_s, 0, F_status_pipe_s_length);
@@ -1971,6 +1973,16 @@ extern "C" {
 
           break;
 
+        case F_partial:
+          *name = f_status_partial_s;
+
+          break;
+
+        case F_partial_not:
+          *name = f_status_partial_not_s;
+
+          break;
+
         case F_payload:
           *name = f_status_payload_s;
 
index 5be2fe11f64820efc9086cce22359ade0090a88d..b4c6bd596c23a3ec6383af7f96b7891dfc695a4e 100644 (file)
@@ -423,6 +423,8 @@ extern "C" {
     #define F_status_parameter_not_s     "F_parameter_not"
     #define F_status_parent_s            "F_parent"
     #define F_status_parent_not_s        "F_parent_not"
+    #define F_status_partial_s           "F_partial"
+    #define F_status_partial_not_s       "F_partial_not"
     #define F_status_payload_s           "F_payload"
     #define F_status_payload_not_s       "F_payload_not"
     #define F_status_pipe_s              "F_pipe"
@@ -735,6 +737,8 @@ extern "C" {
     #define F_status_parameter_not_s_length     15
     #define F_status_parent_s_length            8
     #define F_status_parent_not_s_length        12
+    #define F_status_partial_s_length           9
+    #define F_status_partial_not_s_length       13
     #define F_status_payload_s_length           9
     #define F_status_payload_not_s_length       13
     #define F_status_pipe_s_length              6
@@ -1049,6 +1053,8 @@ extern "C" {
     extern const f_string_static_t f_status_parameter_not_s;
     extern const f_string_static_t f_status_parent_s;
     extern const f_string_static_t f_status_parent_not_s;
+    extern const f_string_static_t f_status_partial_s;
+    extern const f_string_static_t f_status_partial_not_s;
     extern const f_string_static_t f_status_payload_s;
     extern const f_string_static_t f_status_payload_not_s;
     extern const f_string_static_t f_status_previous_s;
index 6d7da0072e5d9ebc4c94409546376c911ee136e3..9ea094abdb6bc012b2af3064b74dd9aa22775735 100644 (file)
@@ -288,6 +288,8 @@ void test__f_status_string_to__works(void **state) {
     F_parameter_not,
     F_parent,
     F_parent_not,
+    F_partial,
+    F_partial_not,
     F_payload,
     F_payload_not,
     F_pipe,
@@ -908,6 +910,8 @@ void test__f_status_string_to__works(void **state) {
     f_status_parameter_not_s,
     f_status_parent_s,
     f_status_parent_not_s,
+    f_status_partial_s,
+    f_status_partial_not_s,
     f_status_payload_s,
     f_status_payload_not_s,
     f_status_pipe_s,
@@ -1269,7 +1273,7 @@ void test__f_status_string_to__works(void **state) {
     f_status_status_code_last_s,
   };
 
-  for (uint16_t i = 0; i < 617; ++i) {
+  for (uint16_t i = 0; i < 619; ++i) {
 
     f_string_static_t result = f_string_static_t_initialize;
 
index 76999e60ef9ddd1461b769c782df6c53a1995b7c..9bc7ac4c0ed20069cf11322ba00f3ff12b85fbc4 100644 (file)
@@ -6,7 +6,7 @@ extern "C" {
 #endif
 
 #ifndef _di_fl_fss_basic_content_read_
-  void fl_fss_basic_content_read(const f_string_static_t buffer, f_string_range_t * const range, f_fss_content_t * const found, f_fss_delimits_t * const delimits, f_state_t * const state) {
+  void fl_fss_basic_content_read(const f_string_static_t buffer, f_string_range_t * const range, f_string_ranges_t * const found, f_number_unsigneds_t * const delimits, f_state_t * const state) {
     #ifndef _di_level_1_parameter_checking_
       if (!state) return;
 
@@ -150,7 +150,7 @@ extern "C" {
 #endif // _di_fl_fss_basic_content_write_
 
 #ifndef _di_fl_fss_basic_object_read_
-  void fl_fss_basic_object_read(const f_string_static_t buffer, f_string_range_t * const range, f_fss_object_t * const found, uint8_t * const quote, f_fss_delimits_t * const delimits, f_state_t * const state) {
+  void fl_fss_basic_object_read(const f_string_static_t buffer, f_string_range_t * const range, f_string_range_t * const found, uint8_t * const quote, f_number_unsigneds_t * const delimits, f_state_t * const state) {
     #ifndef _di_level_1_parameter_checking_
       if (!state) return;
 
index d94d5a4a2f8a87b99bc32ca8374f1baf4dbf0c78..0108c7a203bc26d5b22a146f0a1cba043a87db52 100644 (file)
@@ -80,7 +80,7 @@ extern "C" {
  * @see f_utf_buffer_increment()
  */
 #ifndef _di_fl_fss_basic_content_read_
-  extern void fl_fss_basic_content_read(const f_string_static_t buffer, f_string_range_t * const range, f_fss_content_t * const found, f_fss_delimits_t * const delimits, f_state_t * const state);
+  extern void fl_fss_basic_content_read(const f_string_static_t buffer, f_string_range_t * const range, f_string_ranges_t * const found, f_number_unsigneds_t * const delimits, f_state_t * const state);
 #endif // _di_fl_fss_basic_content_read_
 
 /**
@@ -201,7 +201,7 @@ extern "C" {
  * @see f_utf_buffer_increment()
  */
 #ifndef _di_fl_fss_basic_object_read_
-  extern void fl_fss_basic_object_read(const f_string_static_t buffer, f_string_range_t * const range, f_fss_object_t * const found, uint8_t * const quote, f_fss_delimits_t * const delimits, f_state_t * const state);
+  extern void fl_fss_basic_object_read(const f_string_static_t buffer, f_string_range_t * const range, f_string_range_t * const found, uint8_t * const quote, f_number_unsigneds_t * const delimits, f_state_t * const state);
 #endif // _di_fl_fss_basic_object_read_
 
 /**
index a3c0c84fc2b4ce2a71b021ef82e7845224766931..c4604edde8296a5c9072924009a697fc7b97ce5f 100644 (file)
@@ -6,7 +6,7 @@ extern "C" {
 #endif
 
 #ifndef _di_fl_fss_basic_list_content_read_
-  void fl_fss_basic_list_content_read(const f_string_static_t buffer, f_string_range_t * const range, f_fss_content_t * const found, f_fss_delimits_t * const delimits, f_fss_comments_t * const comments, f_state_t * const state) {
+  void fl_fss_basic_list_content_read(const f_string_static_t buffer, f_string_range_t * const range, f_string_ranges_t * const found, f_number_unsigneds_t * const delimits, f_string_ranges_t * const comments, f_state_t * const state) {
     #ifndef _di_level_1_parameter_checking_
       if (!state) return;
 
@@ -540,7 +540,7 @@ extern "C" {
 #endif // _di_fl_fss_basic_list_content_write_
 
 #ifndef _di_fl_fss_basic_list_object_read_
-  void fl_fss_basic_list_object_read(const f_string_static_t buffer, f_string_range_t * const range, f_fss_object_t * const found, f_fss_delimits_t * const delimits, f_state_t * const state) {
+  void fl_fss_basic_list_object_read(const f_string_static_t buffer, f_string_range_t * const range, f_string_range_t * const found, f_number_unsigneds_t * const delimits, f_state_t * const state) {
     #ifndef _di_level_1_parameter_checking_
       if (!state) return;
 
index 51722cdb4d8efdd0bf739be1e51fc73292b9d501..74fb4313a6f61a9c0aa749cda2e5dc52be4d6678 100644 (file)
@@ -91,7 +91,7 @@ extern "C" {
  * @see f_utf_buffer_increment()
  */
 #ifndef _di_fl_fss_basic_list_content_read_
-  extern void fl_fss_basic_list_content_read(const f_string_static_t buffer, f_string_range_t * const range, f_fss_content_t * const found, f_fss_delimits_t * const delimits, f_fss_comments_t * const comments, f_state_t * const state);
+  extern void fl_fss_basic_list_content_read(const f_string_static_t buffer, f_string_range_t * const range, f_string_ranges_t * const found, f_number_unsigneds_t * const delimits, f_string_ranges_t * const comments, f_state_t * const state);
 #endif // _di_fl_fss_basic_list_content_read_
 
 /**
@@ -219,7 +219,7 @@ extern "C" {
  * @see f_utf_buffer_increment()
  */
 #ifndef _di_fl_fss_basic_list_object_read_
-  extern void fl_fss_basic_list_object_read(const f_string_static_t buffer, f_string_range_t * const range, f_fss_object_t * const found, f_fss_delimits_t * const delimits, f_state_t * const state);
+  extern void fl_fss_basic_list_object_read(const f_string_static_t buffer, f_string_range_t * const range, f_string_range_t * const found, f_number_unsigneds_t * const delimits, f_state_t * const state);
 #endif // _di_fl_fss_basic_list_object_read_
 
 /**
index fb5f78d6d2354b69317b6fbc19ca8871b1f497dd..0e3f2d48fd569c35f89f68601d5bb06345ad0786 100644 (file)
@@ -6,7 +6,7 @@ extern "C" {
 #endif
 
 #ifndef _di_fl_fss_embedded_list_content_read_
-  void fl_fss_embedded_list_content_read(const f_string_static_t buffer, f_string_range_t * const range, f_fss_nest_t * const found, f_fss_delimits_t * const delimits, f_fss_comments_t * const comments, f_state_t * const state) {
+  void fl_fss_embedded_list_content_read(const f_string_static_t buffer, f_string_range_t * const range, f_fss_nest_t * const found, f_number_unsigneds_t * const delimits, f_string_ranges_t * const comments, f_state_t * const state) {
     #ifndef _di_level_1_parameter_checking_
       if (!state) return;
 
@@ -30,7 +30,7 @@ extern "C" {
     state->status = f_number_unsigneds_increase(state->step_small, &positions_start);
     if (F_status_is_error(state->status)) return;
 
-    f_fss_objects_t objects = f_fss_objects_t_initialize;
+    f_string_ranges_t objects = f_string_ranges_t_initialize;
 
     state->status = f_string_ranges_increase(state->step_small, &objects);
 
@@ -1087,7 +1087,7 @@ extern "C" {
 #endif // _di_fl_fss_embedded_list_content_write_
 
 #ifndef _di_fl_fss_embedded_list_object_read_
-  void fl_fss_embedded_list_object_read(const f_string_static_t buffer, f_string_range_t * const range, f_fss_object_t * const found, f_fss_delimits_t * const delimits, f_state_t * const state) {
+  void fl_fss_embedded_list_object_read(const f_string_static_t buffer, f_string_range_t * const range, f_string_range_t * const found, f_number_unsigneds_t * const delimits, f_state_t * const state) {
     #ifndef _di_level_1_parameter_checking_
       if (!state) return;
 
index 68cf7851c80e8350eb57d402fc2d350a48344fc1..1254c5077d23decf39a3f2e65252213b3c86c513 100644 (file)
@@ -97,7 +97,7 @@ extern "C" {
  * @see f_utf_buffer_increment()
  */
 #ifndef _di_fl_fss_embedded_list_content_read_
-  extern void fl_fss_embedded_list_content_read(const f_string_static_t buffer, f_string_range_t * const range, f_fss_nest_t * const found, f_fss_delimits_t * const delimits, f_fss_comments_t * const comments, f_state_t * const state);
+  extern void fl_fss_embedded_list_content_read(const f_string_static_t buffer, f_string_range_t * const range, f_fss_nest_t * const found, f_number_unsigneds_t * const delimits, f_string_ranges_t * const comments, f_state_t * const state);
 #endif // _di_fl_fss_embedded_list_content_read_
 
 /**
@@ -229,7 +229,7 @@ extern "C" {
  * @see f_utf_buffer_increment()
  */
 #ifndef _di_fl_fss_embedded_list_object_read_
-  extern void fl_fss_embedded_list_object_read(const f_string_static_t buffer, f_string_range_t * const range, f_fss_object_t * const found, f_fss_delimits_t * const delimits, f_state_t * const state);
+  extern void fl_fss_embedded_list_object_read(const f_string_static_t buffer, f_string_range_t * const range, f_string_range_t * const found, f_number_unsigneds_t * const delimits, f_state_t * const state);
 #endif // _di_fl_fss_embedded_list_object_read_
 
 /**
index 6813e72d3ff53b56e45d0cefcabcd627bbee2cac..dea677f82bf1459c96fdfb50469cc1384cef18d9 100644 (file)
@@ -6,7 +6,7 @@ extern "C" {
 #endif
 
 #ifndef _di_fl_fss_extended_content_read_
-  void fl_fss_extended_content_read(const f_string_static_t buffer, f_string_range_t * const range, f_fss_content_t * const found, f_uint8s_t * const quotes, f_fss_delimits_t * const delimits, f_state_t * const state) {
+  void fl_fss_extended_content_read(const f_string_static_t buffer, f_string_range_t * const range, f_string_ranges_t * const found, f_uint8s_t * const quotes, f_number_unsigneds_t * const delimits, f_state_t * const state) {
     #ifndef _di_level_1_parameter_checking_
       if (!state) return;
 
@@ -208,7 +208,7 @@ extern "C" {
 #endif // _di_fl_fss_extended_content_write_
 
 #ifndef _di_fl_fss_extended_object_read_
-  void fl_fss_extended_object_read(const f_string_static_t buffer, f_string_range_t * const range, f_fss_object_t * const found, uint8_t * const quote, f_fss_delimits_t * const delimits, f_state_t * const state) {
+  void fl_fss_extended_object_read(const f_string_static_t buffer, f_string_range_t * const range, f_string_range_t * const found, uint8_t * const quote, f_number_unsigneds_t * const delimits, f_state_t * const state) {
     #ifndef _di_level_1_parameter_checking_
       if (!state) return;
 
index 22bbe8f8e9a8df8e530c723bd5e75eee857b9fee..9f047c8b289feb9e9d33843559416802a53d191e 100644 (file)
@@ -94,7 +94,7 @@ extern "C" {
  * @see fl_fss_extended_content_read()
  */
 #ifndef _di_fl_fss_extended_content_read_
-  extern void fl_fss_extended_content_read(const f_string_static_t buffer, f_string_range_t * const range, f_fss_content_t * const found, f_uint8s_t * const quotes, f_fss_delimits_t * const delimits, f_state_t * const state);
+  extern void fl_fss_extended_content_read(const f_string_static_t buffer, f_string_range_t * const range, f_string_ranges_t * const found, f_uint8s_t * const quotes, f_number_unsigneds_t * const delimits, f_state_t * const state);
 #endif // _di_fl_fss_extended_content_read_
 
 /**
@@ -233,7 +233,7 @@ extern "C" {
  * @see fl_fss_extended_content_read()
  */
 #ifndef _di_fl_fss_extended_object_read_
-  extern void fl_fss_extended_object_read(const f_string_static_t buffer, f_string_range_t * const range, f_fss_object_t * const found, uint8_t * const quote, f_fss_delimits_t * const delimits, f_state_t * const state);
+  extern void fl_fss_extended_object_read(const f_string_static_t buffer, f_string_range_t * const range, f_string_range_t * const found, uint8_t * const quote, f_number_unsigneds_t * const delimits, f_state_t * const state);
 #endif // _di_fl_fss_extended_object_read_
 
 /**
index 5c112bf232af21eb58df3693312775464ee43e51..aa5dc2d99cebe828640a9feeb5e88052e1158940 100644 (file)
@@ -6,7 +6,7 @@ extern "C" {
 #endif
 
 #ifndef _di_fl_fss_extended_list_content_read_
-  void fl_fss_extended_list_content_read(const f_string_static_t buffer, f_string_range_t * const range, f_fss_content_t * const found, f_fss_delimits_t * const delimits, f_fss_comments_t * const comments, f_state_t * const state) {
+  void fl_fss_extended_list_content_read(const f_string_static_t buffer, f_string_range_t * const range, f_string_ranges_t * const found, f_number_unsigneds_t * const delimits, f_string_ranges_t * const comments, f_state_t * const state) {
     #ifndef _di_level_1_parameter_checking_
       if (!state) return;
 
@@ -527,7 +527,7 @@ extern "C" {
 #endif // _di_fl_fss_extended_list_content_write_
 
 #ifndef _di_fl_fss_extended_list_object_read_
-  void fl_fss_extended_list_object_read(const f_string_static_t buffer, f_string_range_t * const range, f_fss_object_t * const found, f_fss_delimits_t * const delimits, f_state_t * const state) {
+  void fl_fss_extended_list_object_read(const f_string_static_t buffer, f_string_range_t * const range, f_string_range_t * const found, f_number_unsigneds_t * const delimits, f_state_t * const state) {
     #ifndef _di_level_1_parameter_checking_
       if (!state) return;
 
index 051c60533f948d6d8ba530a80d41d131413f87ac..f03eb811c4871925b95251c432d134b7d249a835 100644 (file)
@@ -93,7 +93,7 @@ extern "C" {
  * @see f_utf_buffer_increment()
  */
 #ifndef _di_fl_fss_extended_list_content_read_
-  extern void fl_fss_extended_list_content_read(const f_string_static_t buffer, f_string_range_t * const range, f_fss_content_t * const found, f_fss_delimits_t * const delimits, f_fss_comments_t * const comments, f_state_t * const state);
+  extern void fl_fss_extended_list_content_read(const f_string_static_t buffer, f_string_range_t * const range, f_string_ranges_t * const found, f_number_unsigneds_t * const delimits, f_string_ranges_t * const comments, f_state_t * const state);
 #endif // _di_fl_fss_extended_list_content_read_
 
 /**
@@ -225,7 +225,7 @@ extern "C" {
  * @see f_utf_buffer_increment()
  */
 #ifndef _di_fl_fss_extended_list_object_read_
-  extern void fl_fss_extended_list_object_read(const f_string_static_t buffer, f_string_range_t * const range, f_fss_object_t * const found, f_fss_delimits_t * const delimits, f_state_t * const state);
+  extern void fl_fss_extended_list_object_read(const f_string_static_t buffer, f_string_range_t * const range, f_string_range_t * const found, f_number_unsigneds_t * const delimits, f_state_t * const state);
 #endif // _di_fl_fss_extended_list_object_read_
 
 /**
index a60e44c3ed58fe6f55099e3e7fcabadb2a90199b..883c278e3614b012babc3be6efa98adf2e4c872f 100644 (file)
@@ -111,7 +111,7 @@ extern "C" {
 #endif // !defined(_di_fl_fss_basic_list_object_write_) || !defined(_di_fl_fss_extended_list_object_write_)
 
 #if !defined(_di_fl_fss_basic_object_read_) || !defined(_di_fl_fss_extended_object_read_) || !defined(_di_fl_fss_extended_content_read_)
-  void private_fl_fss_basic_read(const f_string_static_t buffer, const bool object_as, f_string_range_t * const range, f_fss_object_t * const found, uint8_t * const quote, f_fss_delimits_t * const delimits, f_state_t * const state) {
+  void private_fl_fss_basic_read(const f_string_static_t buffer, const bool object_as, f_string_range_t * const range, f_string_range_t * const found, uint8_t * const quote, f_number_unsigneds_t * const delimits, f_state_t * const state) {
 
     f_fss_skip_past_space(buffer, range, state);
     if (F_status_is_error(state->status)) return;
index 3c5b1e878d4d9ad8bd0c536fb6b6a205c08060e3..7578c2e94eab8dd3af860a977e043fa3497f023b 100644 (file)
@@ -156,7 +156,7 @@ extern "C" {
  * @see fl_fss_extended_content_read()
  */
 #if !defined(_di_fl_fss_basic_object_read_) || !defined(_di_fl_fss_extended_object_read_) || !defined(_di_fl_fss_extended_content_read_)
-  extern void private_fl_fss_basic_read(const f_string_static_t buffer, const bool object_as, f_string_range_t * const range, f_fss_object_t * const found, uint8_t * const quote, f_fss_delimits_t * const delimits, f_state_t * const state) F_attribute_visibility_internal_d;
+  extern void private_fl_fss_basic_read(const f_string_static_t buffer, const bool object_as, f_string_range_t * const range, f_string_range_t * const found, uint8_t * const quote, f_number_unsigneds_t * const delimits, f_state_t * const state) F_attribute_visibility_internal_d;
 #endif // !defined(_di_fl_fss_basic_object_read_) || !defined(_di_fl_fss_extended_object_read_) || !defined(_di_fl_fss_extended_content_read_)
 
 /**
index 9485b26a4630a97a1fed804beba955050a2795dc..48b9bd47207e35b3a0a3ff33905536a15ee816c0 100644 (file)
@@ -1571,6 +1571,18 @@ extern "C" {
         return F_none;
       }
 
+      if (f_compare_dynamic(name, f_status_partial_s) == F_equal_to) {
+        *code = F_partial;
+
+        return F_none;
+      }
+
+      if (f_compare_dynamic(name, f_status_partial_not_s) == F_equal_to) {
+        *code = F_partial_not;
+
+        return F_none;
+      }
+
       if (f_compare_dynamic(name, f_status_payload_s) == F_equal_to) {
         *code = F_payload;
 
index 8e4f1fbf00c564b88909db64af2acdaaef8b713d..9feaef6aa07c10925aa10f35c354410f017a8692 100644 (file)
@@ -304,6 +304,8 @@ void test__fl_status_string_from__works(void **state) {
     F_parameter_not,
     F_parent,
     F_parent_not,
+    F_partial,
+    F_partial_not,
     F_payload,
     F_payload_not,
     F_pipe,
@@ -924,6 +926,8 @@ void test__fl_status_string_from__works(void **state) {
     f_status_parameter_not_s,
     f_status_parent_s,
     f_status_parent_not_s,
+    f_status_partial_s,
+    f_status_partial_not_s,
     f_status_payload_s,
     f_status_payload_not_s,
     f_status_pipe_s,
@@ -1285,7 +1289,7 @@ void test__fl_status_string_from__works(void **state) {
     f_status_status_code_last_s,
   };
 
-  for (uint16_t i = 0; i < 617; ++i) {
+  for (uint16_t i = 0; i < 619; ++i) {
 
     f_status_t result = F_none;
 
index e440234210c7de7e92e38bd36308a408b8d52dc1..1cb75a225203a5491da9f60eecfcd3440fb17162 100644 (file)
@@ -165,7 +165,7 @@ extern "C" {
 #endif // _di_fll_fss_identify_
 
 #ifndef _di_fll_fss_snatch_
-  f_status_t fll_fss_snatch(const f_string_static_t buffer, const f_fss_objects_t objects, const f_fss_contents_t contents, const f_string_static_t names[], const f_number_unsigned_t size, f_string_dynamic_t * const values[], bool matches[], f_number_unsigned_t * const indexs[]) {
+  f_status_t fll_fss_snatch(const f_string_static_t buffer, const f_string_ranges_t objects, const f_string_rangess_t contents, const f_string_static_t names[], const f_number_unsigned_t size, f_string_dynamic_t * const values[], bool matches[], f_number_unsigned_t * const indexs[]) {
     #ifndef _di_level_2_parameter_checking_
       if (!size) return F_status_set_error(F_parameter);
       if (objects.used != contents.used) return F_status_set_error(F_parameter);
@@ -218,7 +218,7 @@ extern "C" {
 #endif // _di_fll_fss_snatch_
 
 #ifndef _di_fll_fss_snatch_apart_
-  f_status_t fll_fss_snatch_apart(const f_string_static_t buffer, const f_fss_objects_t objects, const f_fss_contents_t contents, const f_string_static_t names[], const f_number_unsigned_t size, f_string_dynamics_t * const values[], bool matches[], f_number_unsigneds_t * const indexs[]) {
+  f_status_t fll_fss_snatch_apart(const f_string_static_t buffer, const f_string_ranges_t objects, const f_string_rangess_t contents, const f_string_static_t names[], const f_number_unsigned_t size, f_string_dynamics_t * const values[], bool matches[], f_number_unsigneds_t * const indexs[]) {
     #ifndef _di_level_2_parameter_checking_
       if (!size) return F_status_set_error(F_parameter);
       if (objects.used != contents.used) return F_status_set_error(F_parameter);
@@ -230,7 +230,7 @@ extern "C" {
     if (!contents.used) return F_data_not;
 
     f_status_t status = F_none;
-    f_fss_content_t *content = 0;
+    f_string_ranges_t *content = 0;
 
     f_number_unsigned_t i = 0;
     f_number_unsigned_t j = 0;
@@ -284,7 +284,7 @@ extern "C" {
 #endif // _di_fll_fss_snatch_apart_
 
 #ifndef _di_fll_fss_snatch_map_
-  f_status_t fll_fss_snatch_map(const f_string_static_t buffer, const f_fss_objects_t objects, const f_fss_contents_t contents, const f_string_static_t names[], const f_number_unsigned_t size, f_string_maps_t * const values[], bool matches[], f_number_unsigneds_t * const indexs[]) {
+  f_status_t fll_fss_snatch_map(const f_string_static_t buffer, const f_string_ranges_t objects, const f_string_rangess_t contents, const f_string_static_t names[], const f_number_unsigned_t size, f_string_maps_t * const values[], bool matches[], f_number_unsigneds_t * const indexs[]) {
     #ifndef _di_level_2_parameter_checking_
       if (!size) return F_status_set_error(F_parameter);
       if (objects.used != contents.used) return F_status_set_error(F_parameter);
@@ -427,7 +427,7 @@ extern "C" {
 #endif // _di_fll_fss_snatch_map_
 
 #ifndef _di_fll_fss_snatch_map_apart_
-  f_status_t fll_fss_snatch_map_apart(const f_string_static_t buffer, const f_fss_objects_t objects, const f_fss_contents_t contents, const f_string_static_t names[], const f_number_unsigned_t size, f_string_map_multis_t * const values[], bool matches[], f_number_unsigneds_t * const indexs[]) {
+  f_status_t fll_fss_snatch_map_apart(const f_string_static_t buffer, const f_string_ranges_t objects, const f_string_rangess_t contents, const f_string_static_t names[], const f_number_unsigned_t size, f_string_map_multis_t * const values[], bool matches[], f_number_unsigneds_t * const indexs[]) {
     #ifndef _di_level_2_parameter_checking_
       if (!size) return F_status_set_error(F_parameter);
       if (objects.used != contents.used) return F_status_set_error(F_parameter);
@@ -501,7 +501,7 @@ extern "C" {
 #endif // _di_fll_fss_snatch_map_apart_
 
 #ifndef _di_fll_fss_snatch_map_mash_
-  f_status_t fll_fss_snatch_map_mash(const f_string_static_t buffer, const f_fss_objects_t objects, const f_fss_contents_t contents, const f_string_static_t names[], const f_number_unsigned_t size, const f_string_static_t glue, f_string_maps_t * const values[], bool matches[], f_number_unsigneds_t * const indexs[]) {
+  f_status_t fll_fss_snatch_map_mash(const f_string_static_t buffer, const f_string_ranges_t objects, const f_string_rangess_t contents, const f_string_static_t names[], const f_number_unsigned_t size, const f_string_static_t glue, f_string_maps_t * const values[], bool matches[], f_number_unsigneds_t * const indexs[]) {
     #ifndef _di_level_2_parameter_checking_
       if (!size) return F_status_set_error(F_parameter);
       if (objects.used != contents.used) return F_status_set_error(F_parameter);
@@ -570,7 +570,7 @@ extern "C" {
 #endif // _di_fll_fss_snatch_map_mash_
 
 #ifndef _di_fll_fss_snatch_map_mash_apart_
-  f_status_t fll_fss_snatch_map_mash_apart(const f_string_static_t buffer, const f_fss_objects_t objects, const f_fss_contents_t contents, const f_string_static_t names[], const f_number_unsigned_t size, const f_string_static_t glue, f_string_map_multis_t * const values[], bool matches[], f_number_unsigneds_t * const indexs[]) {
+  f_status_t fll_fss_snatch_map_mash_apart(const f_string_static_t buffer, const f_string_ranges_t objects, const f_string_rangess_t contents, const f_string_static_t names[], const f_number_unsigned_t size, const f_string_static_t glue, f_string_map_multis_t * const values[], bool matches[], f_number_unsigneds_t * const indexs[]) {
     #ifndef _di_level_2_parameter_checking_
       if (!size) return F_status_set_error(F_parameter);
       if (objects.used != contents.used) return F_status_set_error(F_parameter);
@@ -687,7 +687,7 @@ extern "C" {
 #endif // _di_fll_fss_snatch_map_mash_apart_
 
 #ifndef _di_fll_fss_snatch_map_together_
-  f_status_t fll_fss_snatch_map_together(const f_string_static_t buffer, const f_fss_objects_t objects, const f_fss_contents_t contents, const f_string_static_t names[], const f_number_unsigned_t size, const f_string_static_t glue, f_string_maps_t * const values[], bool matches[], f_number_unsigneds_t * const indexs[]) {
+  f_status_t fll_fss_snatch_map_together(const f_string_static_t buffer, const f_string_ranges_t objects, const f_string_rangess_t contents, const f_string_static_t names[], const f_number_unsigned_t size, const f_string_static_t glue, f_string_maps_t * const values[], bool matches[], f_number_unsigneds_t * const indexs[]) {
     #ifndef _di_level_2_parameter_checking_
       if (!size) return F_status_set_error(F_parameter);
       if (objects.used != contents.used) return F_status_set_error(F_parameter);
@@ -801,7 +801,7 @@ extern "C" {
 #endif // _di_fll_fss_snatch_map_together_
 
 #ifndef _di_fll_fss_snatch_mash_
-  f_status_t fll_fss_snatch_mash(const f_string_static_t buffer, const f_fss_objects_t objects, const f_fss_contents_t contents, const f_string_static_t names[], const f_number_unsigned_t size, const f_string_static_t glue, f_string_dynamic_t * const values[], bool matches[], f_number_unsigned_t * const indexs[]) {
+  f_status_t fll_fss_snatch_mash(const f_string_static_t buffer, const f_string_ranges_t objects, const f_string_rangess_t contents, const f_string_static_t names[], const f_number_unsigned_t size, const f_string_static_t glue, f_string_dynamic_t * const values[], bool matches[], f_number_unsigned_t * const indexs[]) {
     #ifndef _di_level_2_parameter_checking_
       if (!size) return F_status_set_error(F_parameter);
       if (objects.used != contents.used) return F_status_set_error(F_parameter);
@@ -856,7 +856,7 @@ extern "C" {
 #endif // _di_fll_fss_snatch_mash_
 
 #ifndef _di_fll_fss_snatch_mash_apart_
-  f_status_t fll_fss_snatch_mash_apart(const f_string_static_t buffer, const f_fss_objects_t objects, const f_fss_contents_t contents, const f_string_static_t names[], const f_number_unsigned_t size, const f_string_static_t glue, f_string_dynamics_t * const values[], bool matches[], f_number_unsigneds_t * const indexs[]) {
+  f_status_t fll_fss_snatch_mash_apart(const f_string_static_t buffer, const f_string_ranges_t objects, const f_string_rangess_t contents, const f_string_static_t names[], const f_number_unsigned_t size, const f_string_static_t glue, f_string_dynamics_t * const values[], bool matches[], f_number_unsigneds_t * const indexs[]) {
     #ifndef _di_level_2_parameter_checking_
       if (!size) return F_status_set_error(F_parameter);
       if (objects.used != contents.used) return F_status_set_error(F_parameter);
@@ -914,7 +914,7 @@ extern "C" {
 #endif // _di_fll_fss_snatch_mash_apart_
 
 #ifndef _di_fll_fss_snatch_together_
-  f_status_t fll_fss_snatch_together(const f_string_static_t buffer, const f_fss_objects_t objects, const f_fss_contents_t contents, const f_string_static_t names[], const f_number_unsigned_t size, const f_string_static_t glue, f_string_dynamic_t * const values[], bool matches[], f_number_unsigned_t * const indexs[]) {
+  f_status_t fll_fss_snatch_together(const f_string_static_t buffer, const f_string_ranges_t objects, const f_string_rangess_t contents, const f_string_static_t names[], const f_number_unsigned_t size, const f_string_static_t glue, f_string_dynamic_t * const values[], bool matches[], f_number_unsigned_t * const indexs[]) {
     #ifndef _di_level_2_parameter_checking_
       if (!size) return F_status_set_error(F_parameter);
       if (objects.used != contents.used) return F_status_set_error(F_parameter);
index 77c02c3c2162a3d6453d63cd7fbb3088414dae89..6f5a03369b03a70413b4ee6ca04197a9ba2021ab 100644 (file)
@@ -119,7 +119,7 @@ extern "C" {
  * @see f_compare_trim()
  */
 #ifndef _di_fll_fss_snatch_
-  extern f_status_t fll_fss_snatch(const f_string_static_t buffer, const f_fss_objects_t objects, const f_fss_contents_t contents, const f_string_static_t names[], const f_number_unsigned_t size, f_string_dynamic_t * const values[], bool matches[], f_number_unsigned_t * const indexs[]);
+  extern f_status_t fll_fss_snatch(const f_string_static_t buffer, const f_string_ranges_t objects, const f_string_rangess_t contents, const f_string_static_t names[], const f_number_unsigned_t size, f_string_dynamic_t * const values[], bool matches[], f_number_unsigned_t * const indexs[]);
 #endif // _di_fll_fss_snatch_
 
 /**
@@ -167,7 +167,7 @@ extern "C" {
  * @see f_compare_trim()
  */
 #ifndef _di_fll_fss_snatch_apart_
-  extern f_status_t fll_fss_snatch_apart(const f_string_static_t buffer, const f_fss_objects_t objects, const f_fss_contents_t contents, const f_string_static_t names[], const f_number_unsigned_t size, f_string_dynamics_t * const values[], bool matches[], f_number_unsigneds_t * const indexs[]);
+  extern f_status_t fll_fss_snatch_apart(const f_string_static_t buffer, const f_string_ranges_t objects, const f_string_rangess_t contents, const f_string_static_t names[], const f_number_unsigned_t size, f_string_dynamics_t * const values[], bool matches[], f_number_unsigneds_t * const indexs[]);
 #endif // _di_fll_fss_snatch_apart_
 
 /**
@@ -217,7 +217,7 @@ extern "C" {
  * @see f_compare_trim()
  */
 #ifndef _di_fll_fss_snatch_map_
-  extern f_status_t fll_fss_snatch_map(const f_string_static_t buffer, const f_fss_objects_t objects, const f_fss_contents_t contents, const f_string_static_t names[], const f_number_unsigned_t size, f_string_maps_t * const values[], bool matches[], f_number_unsigneds_t * const indexs[]);
+  extern f_status_t fll_fss_snatch_map(const f_string_static_t buffer, const f_string_ranges_t objects, const f_string_rangess_t contents, const f_string_static_t names[], const f_number_unsigned_t size, f_string_maps_t * const values[], bool matches[], f_number_unsigneds_t * const indexs[]);
 #endif // _di_fll_fss_snatch_map_
 
 /**
@@ -269,7 +269,7 @@ extern "C" {
  * @see f_compare_trim()
  */
 #ifndef _di_fll_fss_snatch_map_apart_
-  extern f_status_t fll_fss_snatch_map_apart(const f_string_static_t buffer, const f_fss_objects_t objects, const f_fss_contents_t contents, const f_string_static_t names[], const f_number_unsigned_t size, f_string_map_multis_t * const values[], bool matches[], f_number_unsigneds_t * const indexs[]);
+  extern f_status_t fll_fss_snatch_map_apart(const f_string_static_t buffer, const f_string_ranges_t objects, const f_string_rangess_t contents, const f_string_static_t names[], const f_number_unsigned_t size, f_string_map_multis_t * const values[], bool matches[], f_number_unsigneds_t * const indexs[]);
 #endif // _di_fll_fss_snatch_map_apart_
 
 /**
@@ -319,7 +319,7 @@ extern "C" {
  *   Errors (with error bit) from: f_compare_dynamic_partial_trim_string().
  */
 #ifndef _di_fll_fss_snatch_map_mash_
-  extern f_status_t fll_fss_snatch_map_mash(const f_string_static_t buffer, const f_fss_objects_t objects, const f_fss_contents_t contents, const f_string_static_t names[], const f_number_unsigned_t size, const f_string_static_t glue, f_string_maps_t * const values[], bool matches[], f_number_unsigneds_t * const indexs[]);
+  extern f_status_t fll_fss_snatch_map_mash(const f_string_static_t buffer, const f_string_ranges_t objects, const f_string_rangess_t contents, const f_string_static_t names[], const f_number_unsigned_t size, const f_string_static_t glue, f_string_maps_t * const values[], bool matches[], f_number_unsigneds_t * const indexs[]);
 #endif // _di_fll_fss_snatch_map_mash_
 
 /**
@@ -373,7 +373,7 @@ extern "C" {
  * @see f_compare_trim()
  */
 #ifndef _di_fll_fss_snatch_map_mash_apart_
-  extern f_status_t fll_fss_snatch_map_mash_apart(const f_string_static_t buffer, const f_fss_objects_t objects, const f_fss_contents_t contents, const f_string_static_t names[], const f_number_unsigned_t size, const f_string_static_t glue, f_string_map_multis_t * const values[], bool matches[], f_number_unsigneds_t * const indexs[]);
+  extern f_status_t fll_fss_snatch_map_mash_apart(const f_string_static_t buffer, const f_string_ranges_t objects, const f_string_rangess_t contents, const f_string_static_t names[], const f_number_unsigned_t size, const f_string_static_t glue, f_string_map_multis_t * const values[], bool matches[], f_number_unsigneds_t * const indexs[]);
 #endif // _di_fll_fss_snatch_map_mash_apart_
 
 /**
@@ -426,7 +426,7 @@ extern "C" {
  * @see f_compare_trim()
  */
 #ifndef _di_fll_fss_snatch_map_together_
-  extern f_status_t fll_fss_snatch_map_together(const f_string_static_t buffer, const f_fss_objects_t objects, const f_fss_contents_t contents, const f_string_static_t names[], const f_number_unsigned_t size, const f_string_static_t glue, f_string_maps_t * const values[], bool matches[], f_number_unsigneds_t * const indexs[]);
+  extern f_status_t fll_fss_snatch_map_together(const f_string_static_t buffer, const f_string_ranges_t objects, const f_string_rangess_t contents, const f_string_static_t names[], const f_number_unsigned_t size, const f_string_static_t glue, f_string_maps_t * const values[], bool matches[], f_number_unsigneds_t * const indexs[]);
 #endif // _di_fll_fss_snatch_map_together_
 
 /**
@@ -473,7 +473,7 @@ extern "C" {
  *   Errors (with error bit) from: f_compare_dynamic_partial_trim_string().
  */
 #ifndef _di_fll_fss_snatch_mash_
-  extern f_status_t fll_fss_snatch_mash(const f_string_static_t buffer, const f_fss_objects_t objects, const f_fss_contents_t contents, const f_string_static_t names[], const f_number_unsigned_t size, const f_string_static_t glue, f_string_dynamic_t * const values[], bool matches[], f_number_unsigned_t * const indexs[]);
+  extern f_status_t fll_fss_snatch_mash(const f_string_static_t buffer, const f_string_ranges_t objects, const f_string_rangess_t contents, const f_string_static_t names[], const f_number_unsigned_t size, const f_string_static_t glue, f_string_dynamic_t * const values[], bool matches[], f_number_unsigned_t * const indexs[]);
 #endif // _di_fll_fss_snatch_mash_
 
 /**
@@ -524,7 +524,7 @@ extern "C" {
  * @see f_compare_trim()
  */
 #ifndef _di_fll_fss_snatch_mash_apart_
-  extern f_status_t fll_fss_snatch_mash_apart(const f_string_static_t buffer, const f_fss_objects_t objects, const f_fss_contents_t contents, const f_string_static_t names[], const f_number_unsigned_t size, const f_string_static_t glue, f_string_dynamics_t * const values[], bool matches[], f_number_unsigneds_t * const indexs[]);
+  extern f_status_t fll_fss_snatch_mash_apart(const f_string_static_t buffer, const f_string_ranges_t objects, const f_string_rangess_t contents, const f_string_static_t names[], const f_number_unsigned_t size, const f_string_static_t glue, f_string_dynamics_t * const values[], bool matches[], f_number_unsigneds_t * const indexs[]);
 #endif // _di_fll_fss_snatch_mash_apart_
 
 /**
@@ -572,7 +572,7 @@ extern "C" {
  * @see f_compare_trim()
  */
 #ifndef _di_fll_fss_snatch_together_
-  extern f_status_t fll_fss_snatch_together(const f_string_static_t buffer, const f_fss_objects_t objects, const f_fss_contents_t contents, const f_string_static_t names[], const f_number_unsigned_t size, const f_string_static_t glue, f_string_dynamic_t * const values[], bool matches[], f_number_unsigned_t * const indexs[]);
+  extern f_status_t fll_fss_snatch_together(const f_string_static_t buffer, const f_string_ranges_t objects, const f_string_rangess_t contents, const f_string_static_t names[], const f_number_unsigned_t size, const f_string_static_t glue, f_string_dynamic_t * const values[], bool matches[], f_number_unsigned_t * const indexs[]);
 #endif // _di_fll_fss_snatch_together_
 
 #ifdef __cplusplus
index bddd2bcb9703aef64cdc4c63b4bd7652204848f7..d20cababd416a8d753a9ebbb0b315e9070416a4b 100644 (file)
@@ -5,7 +5,7 @@ extern "C" {
 #endif
 
 #ifndef _di_fll_fss_basic_read_
-  void fll_fss_basic_read(const f_string_static_t buffer, f_string_range_t * const range, f_fss_objects_t * const objects, f_fss_contents_t * const contents, f_uint8s_t * const objects_quoted, f_fss_delimits_t * const objects_delimits, f_fss_delimits_t * const contents_delimits, f_state_t * const state) {
+  void fll_fss_basic_read(const f_string_static_t buffer, f_string_range_t * const range, f_string_ranges_t * const objects, f_string_rangess_t * const contents, f_uint8s_t * const objects_quoted, f_number_unsigneds_t * const objects_delimits, f_number_unsigneds_t * const contents_delimits, f_state_t * const state) {
     #ifndef _di_level_2_parameter_checking_
       if (!state) return;
 
index efca82702fbbe71043c776a7fe178d976e0e0419..2df31bf065d0127294815a3bb541344abfc9bcb2 100644 (file)
@@ -82,7 +82,7 @@ extern "C" {
  * @see fl_fss_basic_object_read()
  */
 #ifndef _di_fll_fss_basic_read_
-  extern void fll_fss_basic_read(const f_string_static_t buffer, f_string_range_t * const range, f_fss_objects_t * const objects, f_fss_contents_t * const contents, f_uint8s_t * const objects_quoted, f_fss_delimits_t * const objects_delimits, f_fss_delimits_t * const contents_delimits, f_state_t * const state);
+  extern void fll_fss_basic_read(const f_string_static_t buffer, f_string_range_t * const range, f_string_ranges_t * const objects, f_string_rangess_t * const contents, f_uint8s_t * const objects_quoted, f_number_unsigneds_t * const objects_delimits, f_number_unsigneds_t * const contents_delimits, f_state_t * const state);
 #endif // _di_fll_fss_basic_read_
 
 /**
index db377359782b547054849cd6a51b62defa2d974f..b42f65d3b5cf3d0301b8d6a83f2ad35222e449d5 100644 (file)
@@ -5,7 +5,7 @@ extern "C" {
 #endif
 
 #ifndef _di_fll_fss_basic_list_read_
-  void fll_fss_basic_list_read(const f_string_static_t buffer, f_string_range_t * const range, f_fss_objects_t * const objects, f_fss_contents_t * const contents, f_fss_delimits_t * const objects_delimits, f_fss_delimits_t * const contents_delimits, f_fss_comments_t * const comments, f_state_t * const state) {
+  void fll_fss_basic_list_read(const f_string_static_t buffer, f_string_range_t * const range, f_string_ranges_t * const objects, f_string_rangess_t * const contents, f_number_unsigneds_t * const objects_delimits, f_number_unsigneds_t * const contents_delimits, f_string_ranges_t * const comments, f_state_t * const state) {
     #ifndef _di_level_2_parameter_checking_
       if (!state) return;
 
index 1cecc29ffa7339ba671eb51a4287e736584950e7..7f6fc5321589a87a148627aef9f54030ddf67dc9 100644 (file)
@@ -81,7 +81,7 @@ extern "C" {
  * @see fl_fss_basic_list_object_read()
  */
 #ifndef _di_fll_fss_basic_list_read_
-  extern void fll_fss_basic_list_read(const f_string_static_t buffer, f_string_range_t * const range, f_fss_objects_t * const objects, f_fss_contents_t * const contents, f_fss_delimits_t * const objects_delimits, f_fss_delimits_t * const contents_delimits, f_fss_comments_t * const comments, f_state_t * const state);
+  extern void fll_fss_basic_list_read(const f_string_static_t buffer, f_string_range_t * const range, f_string_ranges_t * const objects, f_string_rangess_t * const contents, f_number_unsigneds_t * const objects_delimits, f_number_unsigneds_t * const contents_delimits, f_string_ranges_t * const comments, f_state_t * const state);
 #endif // _di_fll_fss_basic_list_read_
 
 /**
index fcde9b1f2e6f8c105bd725751bd738bbd34692fe..b95675182a8aa2b8d6ecf72d82895deca761b101 100644 (file)
@@ -5,7 +5,7 @@ extern "C" {
 #endif
 
 #ifndef _di_fll_fss_embedded_list_read_
-  void fll_fss_embedded_list_read(const f_string_static_t buffer, f_string_range_t * const range, f_fss_nest_t * const nest, f_fss_delimits_t * const objects_delimits, f_fss_delimits_t * const contents_delimits, f_fss_comments_t * const comments, f_state_t * const state) {
+  void fll_fss_embedded_list_read(const f_string_static_t buffer, f_string_range_t * const range, f_fss_nest_t * const nest, f_number_unsigneds_t * const objects_delimits, f_number_unsigneds_t * const contents_delimits, f_string_ranges_t * const comments, f_state_t * const state) {
     #ifndef _di_level_2_parameter_checking_
       if (!state) return;
 
index 5f8f6f031357cc2d26b7e206f61aea9a47e4caad..0dd2cb5882712a7758e500c2cacf30f56f1180be 100644 (file)
@@ -81,7 +81,7 @@ extern "C" {
  * @see fl_fss_embedded_list_object_read()
  */
 #ifndef _di_fll_fss_embedded_list_read_
-  extern void fll_fss_embedded_list_read(const f_string_static_t buffer, f_string_range_t * const range, f_fss_nest_t * const nest, f_fss_delimits_t * const objects_delimits, f_fss_delimits_t * const contents_delimits, f_fss_comments_t * const comments, f_state_t * const state);
+  extern void fll_fss_embedded_list_read(const f_string_static_t buffer, f_string_range_t * const range, f_fss_nest_t * const nest, f_number_unsigneds_t * const objects_delimits, f_number_unsigneds_t * const contents_delimits, f_string_ranges_t * const comments, f_state_t * const state);
 #endif // _di_fll_fss_embedded_list_read_
 
 /**
index 3749296b493b5db4d903f63094d14b2ad00783f9..c05848207047133cdc7ed8e522c840cea881725f 100644 (file)
@@ -5,7 +5,7 @@ extern "C" {
 #endif
 
 #ifndef _di_fll_fss_extended_read_
-  void fll_fss_extended_read(const f_string_static_t buffer, f_string_range_t * const range, f_fss_objects_t * const objects, f_fss_contents_t * const contents, f_uint8s_t * const objects_quoted, f_uint8ss_t * const contents_quoted, f_fss_delimits_t * const objects_delimits, f_fss_delimits_t * const contents_delimits, f_state_t * const state) {
+  void fll_fss_extended_read(const f_string_static_t buffer, f_string_range_t * const range, f_string_ranges_t * const objects, f_string_rangess_t * const contents, f_uint8s_t * const objects_quoted, f_uint8ss_t * const contents_quoted, f_number_unsigneds_t * const objects_delimits, f_number_unsigneds_t * const contents_delimits, f_state_t * const state) {
     #ifndef _di_level_2_parameter_checking_
       if (!state) return;
 
index 6df690e83da18f19ec7008c73fdd8a69c932b46e..7fb7030e3b9be4ce44eaa1fe6debe0162b8863e4 100644 (file)
@@ -85,7 +85,7 @@ extern "C" {
  * @see fl_fss_extended_object_read()
  */
 #ifndef _di_fll_fss_extended_read_
-  extern void fll_fss_extended_read(const f_string_static_t buffer, f_string_range_t * const range, f_fss_objects_t * const objects, f_fss_contents_t * const contents, f_uint8s_t * const objects_quoted, f_uint8ss_t * const contents_quoted, f_fss_delimits_t * const objects_delimits, f_fss_delimits_t * const contents_delimits, f_state_t * const state);
+  extern void fll_fss_extended_read(const f_string_static_t buffer, f_string_range_t * const range, f_string_ranges_t * const objects, f_string_rangess_t * const contents, f_uint8s_t * const objects_quoted, f_uint8ss_t * const contents_quoted, f_number_unsigneds_t * const objects_delimits, f_number_unsigneds_t * const contents_delimits, f_state_t * const state);
 #endif // _di_fll_fss_extended_read_
 
 /**
index 0589b83beb705e2951135acc90483612c90172fb..08ae998b23446a543a3b6ab753d261dadb37c76d 100644 (file)
@@ -5,7 +5,7 @@ extern "C" {
 #endif
 
 #ifndef _di_fll_fss_extended_list_read_
-  void fll_fss_extended_list_read(const f_string_static_t buffer, f_string_range_t * const range, f_fss_objects_t * const objects, f_fss_contents_t * const contents, f_fss_delimits_t * const objects_delimits, f_fss_delimits_t * const contents_delimits, f_fss_comments_t * const comments, f_state_t * const state) {
+  void fll_fss_extended_list_read(const f_string_static_t buffer, f_string_range_t * const range, f_string_ranges_t * const objects, f_string_rangess_t * const contents, f_number_unsigneds_t * const objects_delimits, f_number_unsigneds_t * const contents_delimits, f_string_ranges_t * const comments, f_state_t * const state) {
     #ifndef _di_level_2_parameter_checking_
       if (!state) return;
 
index 0c3767c0566137b3f4d371d5ca42dd5b1a75ac9f..371b61d49f2286b5ecf748254adf461e40e7992d 100644 (file)
@@ -85,7 +85,7 @@ extern "C" {
  * @see fl_fss_extended_list_object_read()
  */
 #ifndef _di_fll_fss_extended_list_read_
-  extern void fll_fss_extended_list_read(const f_string_static_t buffer, f_string_range_t * const range, f_fss_objects_t * const objects, f_fss_contents_t * const contents, f_fss_delimits_t * const objects_delimits, f_fss_delimits_t * const contents_delimits, f_fss_comments_t * const comments, f_state_t * const state);
+  extern void fll_fss_extended_list_read(const f_string_static_t buffer, f_string_range_t * const range, f_string_ranges_t * const objects, f_string_rangess_t * const contents, f_number_unsigneds_t * const objects_delimits, f_number_unsigneds_t * const contents_delimits, f_string_ranges_t * const comments, f_state_t * const state);
 #endif // _di_fll_fss_extended_list_read_
 
 /**
index 1246931c7111b7eee0a047b047d10f8b7ef14a41..a601f0275c9228bb69e73baa96bf49c90051df5c 100644 (file)
@@ -5,7 +5,7 @@ extern "C" {
 #endif
 
 #ifndef _di_fll_fss_payload_read_
-  void fll_fss_payload_read(const f_string_static_t buffer, f_string_range_t * const range, f_fss_objects_t * const objects, f_fss_contents_t * const contents, f_fss_delimits_t * const objects_delimits, f_fss_delimits_t * const contents_delimits, f_fss_comments_t * const comments, f_state_t * const state) {
+  void fll_fss_payload_read(const f_string_static_t buffer, f_string_range_t * const range, f_string_ranges_t * const objects, f_string_rangess_t * const contents, f_number_unsigneds_t * const objects_delimits, f_number_unsigneds_t * const contents_delimits, f_string_ranges_t * const comments, f_state_t * const state) {
     #ifndef _di_level_2_parameter_checking_
       if (!state) return;
 
index c5d51e335cc5b417a866514fc2e45efcc76e1944..cfc5cdc7057bd558a799ce0dfdc7732269eb039f 100644 (file)
@@ -98,7 +98,7 @@ extern "C" {
  * @see fl_fss_basic_list_object_read()
  */
 #ifndef _di_fll_fss_payload_read_
-  extern void fll_fss_payload_read(const f_string_static_t buffer, f_string_range_t * const range, f_fss_objects_t * const objects, f_fss_contents_t * const contents, f_fss_delimits_t * const objects_delimits, f_fss_delimits_t * const contents_delimits, f_fss_comments_t * const comments, f_state_t * const state);
+  extern void fll_fss_payload_read(const f_string_static_t buffer, f_string_range_t * const range, f_string_ranges_t * const objects, f_string_rangess_t * const contents, f_number_unsigneds_t * const objects_delimits, f_number_unsigneds_t * const contents_delimits, f_string_ranges_t * const comments, f_state_t * const state);
 #endif // _di_fll_fss_payload_read_
 
 /**
index 8dc883c2e7f7448ce53ee7fdd4cdc727c27c3417..89505dd2717935db83d711aef44cfa4ef49a4d49 100644 (file)
@@ -241,13 +241,13 @@ extern "C" {
     f_string_dynamic_t small;
     f_string_dynamic_t packet;
 
-    f_fss_objects_t packet_objects;
-    f_fss_contents_t packet_contents;
+    f_string_ranges_t packet_objects;
+    f_string_rangess_t packet_contents;
 
-    f_fss_objects_t header_objects;
-    f_fss_contents_t header_contents;
+    f_string_ranges_t header_objects;
+    f_string_rangess_t header_contents;
 
-    f_fss_delimits_t delimits;
+    f_number_unsigneds_t delimits;
   } control_cache_t;
 
   #define control_cache_initialize \
@@ -255,11 +255,11 @@ extern "C" {
       f_string_dynamic_t_initialize, \
       f_string_dynamic_t_initialize, \
       f_string_dynamic_t_initialize, \
-      f_fss_objects_t_initialize, \
-      f_fss_contents_t_initialize, \
-      f_fss_objects_t_initialize, \
-      f_fss_contents_t_initialize, \
-      f_fss_delimits_t_initialize, \
+      f_string_ranges_t_initialize, \
+      f_string_rangess_t_initialize, \
+      f_string_ranges_t_initialize, \
+      f_string_rangess_t_initialize, \
+      f_number_unsigneds_t_initialize, \
     }
 #endif // _di_control_cache_t_
 
index 20a480c34e6f758615668f16e1ff991436825857..43868e399ac704f82f68d1b99984b0c40761a243 100644 (file)
@@ -654,9 +654,9 @@ extern "C" {
 
     f_state_t state = f_state_t_initialize;
     f_string_range_t range = f_string_range_t_initialize;
-    f_fss_objects_t objects = f_fss_objects_t_initialize;
-    f_fss_contents_t contents = f_fss_contents_t_initialize;
-    f_fss_delimits_t delimits = f_fss_delimits_t_initialize;
+    f_string_ranges_t objects = f_string_ranges_t_initialize;
+    f_string_rangess_t contents = f_string_rangess_t_initialize;
+    f_number_unsigneds_t delimits = f_number_unsigneds_t_initialize;
 
     status = fll_fss_extended_read(data->cache.large, state, &range, &objects, &contents, 0, 0, &delimits, 0);
 
index 6e221bbdde42fa8913084714d9957c472aba7acd..7df5c5ee16a571bb41108e2b6499392134fafe80 100644 (file)
@@ -81,14 +81,14 @@ extern "C" {
     f_number_unsigneds_t ats;
     f_number_unsigneds_t stack;
 
-    f_fss_comments_t comments;
-    f_fss_delimits_t delimits;
+    f_string_ranges_t comments;
+    f_number_unsigneds_t delimits;
 
-    f_fss_content_t content_action;
-    f_fss_contents_t content_actions;
-    f_fss_contents_t content_items;
-    f_fss_objects_t object_actions;
-    f_fss_objects_t object_items;
+    f_string_ranges_t content_action;
+    f_string_rangess_t content_actions;
+    f_string_rangess_t content_items;
+    f_string_ranges_t object_actions;
+    f_string_ranges_t object_items;
 
     f_string_dynamic_t buffer_file;
     f_string_dynamic_t buffer_item;
@@ -104,13 +104,13 @@ extern "C" {
     f_string_range_t_initialize, \
     f_number_unsigneds_t_initialize, \
     f_number_unsigneds_t_initialize, \
-    f_fss_comments_t_initialize, \
-    f_fss_delimits_t_initialize, \
-    f_fss_content_t_initialize, \
-    f_fss_contents_t_initialize, \
-    f_fss_contents_t_initialize, \
-    f_fss_objects_t_initialize, \
-    f_fss_objects_t_initialize, \
+    f_string_ranges_t_initialize, \
+    f_number_unsigneds_t_initialize, \
+    f_string_ranges_t_initialize, \
+    f_string_rangess_t_initialize, \
+    f_string_rangess_t_initialize, \
+    f_string_ranges_t_initialize, \
+    f_string_ranges_t_initialize, \
     f_string_dynamic_t_initialize, \
     f_string_dynamic_t_initialize, \
     f_string_dynamic_t_initialize, \
@@ -138,7 +138,7 @@ extern "C" {
  *   The cache to deallocate.
  *
  * @see macro_f_number_unsigneds_t_delete_simple()
- * @see macro_f_fss_delimits_t_delete_simple()
+ * @see macro_f_number_unsigneds_t_delete_simple()
  *
  * @see controller_cache_action_delete_simple()
  * @see f_string_dynamic_resize()
index ed521db8dfcbfb30a2d8ed1265902457d7ad70b2..66a5019d6b05c0260e7e70022a2d8496a34f7df7 100644 (file)
@@ -60,7 +60,7 @@ extern "C" {
 #endif // _di_controller_rule_find_
 
 #ifndef _di_controller_rule_parameters_read_
-  f_status_t controller_rule_parameters_read(const controller_global_t global, const f_string_static_t buffer, f_fss_object_t * const object, f_fss_content_t * const content, controller_rule_action_t * const action, f_state_t * const state) {
+  f_status_t controller_rule_parameters_read(const controller_global_t global, const f_string_static_t buffer, f_string_range_t * const object, f_string_ranges_t * const content, controller_rule_action_t * const action, f_state_t * const state) {
 
     f_status_t status = F_none;
 
index abc4d8e35d6c2ee756e382e2fccf0745e8a45085..eba8634929f98a272cb22d69e1a68262e2b7b48e 100644 (file)
@@ -101,7 +101,7 @@ extern "C" {
  * @see fl_iki_read()
  */
 #ifndef _di_controller_rule_parameters_read_
-  extern f_status_t controller_rule_parameters_read(const controller_global_t global, const f_string_static_t buffer, f_fss_object_t * const object, f_fss_content_t * const content, controller_rule_action_t * const action, f_state_t * const state) F_attribute_visibility_internal_d;
+  extern f_status_t controller_rule_parameters_read(const controller_global_t global, const f_string_static_t buffer, f_string_range_t * const object, f_string_ranges_t * const content, controller_rule_action_t * const action, f_state_t * const state) F_attribute_visibility_internal_d;
 #endif // _di_controller_rule_parameters_read_
 
 /**
index 25fdd07a7821ba829496f97dc92acce876af26e6..37f3a2cc674c5a66d8d44706c8cef84f7ae9cc1c 100644 (file)
@@ -129,8 +129,8 @@ extern "C" {
 
     {
       f_string_dynamic_t buffer = f_string_dynamic_t_initialize;
-      f_fss_objects_t objects = f_fss_objects_t_initialize;
-      f_fss_contents_t contents = f_fss_contents_t_initialize;
+      f_string_ranges_t objects = f_string_ranges_t_initialize;
+      f_string_rangess_t contents = f_string_rangess_t_initialize;
 
       if (process_pipe) {
         fake_pipe_buffer(data, &buffer);
@@ -151,7 +151,7 @@ extern "C" {
 
       if (F_status_is_error_not(main->setting.state.status)) {
         f_string_range_t range = macro_f_string_range_t_initialize_2(buffer.used);
-        f_fss_delimits_t delimits = f_fss_delimits_t_initialize;
+        f_number_unsigneds_t delimits = f_number_unsigneds_t_initialize;
 
         fll_fss_extended_read(buffer, &range, &objects, &contents, 0, 0, &delimits, 0, &main->setting.state);
 
@@ -169,13 +169,13 @@ extern "C" {
           }
         }
 
-        macro_f_fss_delimits_t_delete_simple(delimits);
+        macro_f_number_unsigneds_t_delete_simple(delimits);
       }
 
       f_string_dynamic_resize(0, &buffer);
 
-      macro_f_fss_objects_t_delete_simple(objects);
-      macro_f_fss_contents_t_delete_simple(contents);
+      macro_f_string_ranges_t_delete_simple(objects);
+      macro_f_string_rangess_t_delete_simple(contents);
     }
 
     // Error when required settings are not specified.
@@ -213,7 +213,7 @@ extern "C" {
 #endif // _di_fake_build_load_setting_
 
 #ifndef _di_fake_build_load_setting_process_
-  void fake_build_load_setting_process(fake_data_t * const data, const bool checks, const f_string_static_t path_file, const f_string_statics_t * const modes_custom, const f_string_static_t buffer, const f_fss_objects_t objects, const f_fss_contents_t contents, fake_build_setting_t * const setting) {
+  void fake_build_load_setting_process(fake_data_t * const data, const bool checks, const f_string_static_t path_file, const f_string_statics_t * const modes_custom, const f_string_static_t buffer, const f_string_ranges_t objects, const f_string_rangess_t contents, fake_build_setting_t * const setting) {
 
     if (!data || !data->main || !setting) return;
     if (F_status_is_error(data->main->setting.state.status) && buffer.used) return;
index a8a6488b1f8ecebc3eab0813df898163ab5fdc86..40de6a45b8884615e1bf89a119b07fb21f1effcf 100644 (file)
@@ -156,7 +156,7 @@ extern "C" {
  * @see fll_fss_snatch_apart()
  */
 #ifndef _di_fake_build_load_setting_process_
-  extern void fake_build_load_setting_process(fake_data_t * const data, const bool checks, const f_string_static_t path_file, const f_string_statics_t * const modes_custom, const f_string_static_t buffer, const f_fss_objects_t objects, const f_fss_contents_t contents, fake_build_setting_t * const setting);
+  extern void fake_build_load_setting_process(fake_data_t * const data, const bool checks, const f_string_static_t path_file, const f_string_statics_t * const modes_custom, const f_string_static_t buffer, const f_string_ranges_t objects, const f_string_rangess_t contents, fake_build_setting_t * const setting);
 #endif // _di_fake_build_load_setting_process_
 
 /**
index 319a1628b50e9f58ca65e1843bdb4ec3d055d6e2..d9595409464d0d6f7b56fc8c9440005b69b86407 100644 (file)
@@ -36,13 +36,13 @@ extern "C" {
       return;
     }
 
-    f_fss_objects_t list_objects = f_fss_objects_t_initialize;
-    f_fss_contents_t list_contents = f_fss_contents_t_initialize;
-    f_fss_delimits_t delimits = f_fss_delimits_t_initialize;
+    f_string_ranges_t list_objects = f_string_ranges_t_initialize;
+    f_string_rangess_t list_contents = f_string_rangess_t_initialize;
+    f_number_unsigneds_t delimits = f_number_unsigneds_t_initialize;
 
     {
       f_string_range_t range = macro_f_string_range_t_initialize_2(data_make->main->buffer.used);
-      f_fss_comments_t comments = f_fss_comments_t_initialize;
+      f_string_ranges_t comments = f_string_ranges_t_initialize;
 
       fll_fss_basic_list_read(data_make->main->buffer, &range, &list_objects, &list_contents, &delimits, 0, &comments, &data_make->main->setting.state);
 
@@ -298,7 +298,7 @@ extern "C" {
 #endif // _di_fake_make_load_fakefile_
 
 #ifndef _di_fake_make_load_fakefile_setting_build_
-  void fake_make_load_fakefile_setting_build(fake_make_data_t * const data_make, f_fss_object_t * const object, f_fss_content_t * const content) {
+  void fake_make_load_fakefile_setting_build(fake_make_data_t * const data_make, f_string_range_t * const object, f_string_ranges_t * const content) {
 
     if (!data_make || !data_make->data || !data_make->main || !object || !content) return;
 
@@ -324,7 +324,7 @@ extern "C" {
 #endif // _di_fake_make_load_fakefile_setting_build_
 
 #ifndef _di_fake_make_load_fakefile_setting_compiler_
-  void fake_make_load_fakefile_setting_compiler(fake_make_data_t * const data_make, f_fss_object_t * const object, f_fss_content_t * const content, f_string_range_t **range_compiler) {
+  void fake_make_load_fakefile_setting_compiler(fake_make_data_t * const data_make, f_string_range_t * const object, f_string_ranges_t * const content, f_string_range_t **range_compiler) {
 
     if (!data_make || !data_make->data || !data_make->main || !object || !content || !range_compiler) return;
 
@@ -426,7 +426,7 @@ extern "C" {
 #endif // _di_fake_make_load_fakefile_setting_define_and_parameter_
 
 #ifndef _di_fake_make_load_fakefile_setting_environment_
-  void fake_make_load_fakefile_setting_environment(fake_make_data_t * const data_make, f_fss_content_t * const content) {
+  void fake_make_load_fakefile_setting_environment(fake_make_data_t * const data_make, f_string_ranges_t * const content) {
 
     if (!data_make || !data_make->data || !data_make->data || !data_make->main || !content) return;
 
@@ -512,7 +512,7 @@ extern "C" {
 #endif // _di_fake_make_load_fakefile_setting_environment_
 
 #ifndef _di_fake_make_load_fakefile_setting_fail_
-  void fake_make_load_fakefile_setting_fail(fake_make_data_t * const data_make, f_fss_object_t * const object, f_fss_content_t * const content) {
+  void fake_make_load_fakefile_setting_fail(fake_make_data_t * const data_make, f_string_range_t * const object, f_string_ranges_t * const content) {
 
     if (!data_make || !data_make->data || !data_make->data || !data_make->main || !object || !content) return;
 
@@ -541,7 +541,7 @@ extern "C" {
 #endif // _di_fake_make_load_fakefile_setting_fail_
 
 #ifndef _di_fake_make_load_fakefile_setting_indexer_
-  void fake_make_load_fakefile_setting_indexer(fake_make_data_t * const data_make, f_fss_object_t * const object, f_fss_content_t * const content, f_string_range_t **range_indexer) {
+  void fake_make_load_fakefile_setting_indexer(fake_make_data_t * const data_make, f_string_range_t * const object, f_string_ranges_t * const content, f_string_range_t **range_indexer) {
 
     if (!data_make || !data_make->data || !data_make->data || !data_make->main || !object || !content || !range_indexer) return;
 
@@ -559,7 +559,7 @@ extern "C" {
 #endif // _di_fake_make_load_fakefile_setting_indexer_
 
 #ifndef _di_fake_make_load_fakefile_setting_parameter_
-  void fake_make_load_fakefile_setting_parameter(fake_make_data_t * const data_make, f_fss_object_t * const object, f_fss_content_t * const content) {
+  void fake_make_load_fakefile_setting_parameter(fake_make_data_t * const data_make, f_string_range_t * const object, f_string_ranges_t * const content) {
 
     if (!data_make || !data_make->data || !data_make->data || !data_make->main || !object || !content) return;
 
index 080051fe212f8ffa90369e16695c014c4298a5f2..6a5c1411c49bf357768567efcf323744c2bad536 100644 (file)
@@ -89,7 +89,7 @@ extern "C" {
  *   The setting content.
  */
 #ifndef _di_fake_make_load_fakefile_setting_build_
-  extern void fake_make_load_fakefile_setting_build(fake_make_data_t * const data_make, f_fss_object_t * const object, f_fss_content_t * const content);
+  extern void fake_make_load_fakefile_setting_build(fake_make_data_t * const data_make, f_string_range_t * const object, f_string_ranges_t * const content);
 #endif // _di_fake_make_load_fakefile_setting_build_
 
 /**
@@ -107,7 +107,7 @@ extern "C" {
  *   A pointer to the range that representing the compiler setting within the buffer.
  */
 #ifndef _di_fake_make_load_fakefile_setting_compiler_
-  extern void fake_make_load_fakefile_setting_compiler(fake_make_data_t * const data_make, f_fss_object_t * const object, f_fss_content_t * const content, f_string_range_t **range_compiler);
+  extern void fake_make_load_fakefile_setting_compiler(fake_make_data_t * const data_make, f_string_range_t * const object, f_string_ranges_t * const content, f_string_range_t **range_compiler);
 #endif // _di_fake_make_load_fakefile_setting_compiler_
 
 /**
@@ -165,7 +165,7 @@ extern "C" {
  * @see f_string_dynamics_increase()
  */
 #ifndef _di_fake_make_load_fakefile_setting_environment_
-  extern void fake_make_load_fakefile_setting_environment(fake_make_data_t * const data_make, f_fss_content_t * const content);
+  extern void fake_make_load_fakefile_setting_environment(fake_make_data_t * const data_make, f_string_ranges_t * const content);
 #endif // _di_fake_make_load_fakefile_setting_environment_
 
 /**
@@ -181,7 +181,7 @@ extern "C" {
  *   The setting content.
  */
 #ifndef _di_fake_make_load_fakefile_setting_fail_
-  extern void fake_make_load_fakefile_setting_fail(fake_make_data_t * const data_make, f_fss_object_t * const object, f_fss_content_t * const content);
+  extern void fake_make_load_fakefile_setting_fail(fake_make_data_t * const data_make, f_string_range_t * const object, f_string_ranges_t * const content);
 #endif // _di_fake_make_load_fakefile_setting_fail_
 
 /**
@@ -199,7 +199,7 @@ extern "C" {
  *   A pointer to the range that representing the indexer setting within the buffer.
  */
 #ifndef _di_fake_make_load_fakefile_setting_indexer_
-  extern void fake_make_load_fakefile_setting_indexer(fake_make_data_t * const data_make, f_fss_object_t * const object, f_fss_content_t * const content, f_string_range_t **range_indexer);
+  extern void fake_make_load_fakefile_setting_indexer(fake_make_data_t * const data_make, f_string_range_t * const object, f_string_ranges_t * const content, f_string_range_t **range_indexer);
 #endif // _di_fake_make_load_fakefile_setting_indexer_
 
 /**
@@ -230,7 +230,7 @@ extern "C" {
  * @see fake_make_load_fakefile_setting_define_and_parameter()
  */
 #ifndef _di_fake_make_load_fakefile_setting_parameter_
-  extern void fake_make_load_fakefile_setting_parameter(fake_make_data_t * const data_make, f_fss_object_t * const object, f_fss_content_t * const content);
+  extern void fake_make_load_fakefile_setting_parameter(fake_make_data_t * const data_make, f_string_range_t * const object, f_string_ranges_t * const content);
 #endif // _di_fake_make_load_fakefile_setting_parameter_
 
 #ifdef __cplusplus
index ea9b77fa9fdad95f94b282e47a7cb739fd566805..8f5421ff49339b9ab055e89b11c2305953b7f444 100644 (file)
@@ -217,7 +217,7 @@ extern "C" {
 #endif // _di_fake_make_operate_
 
 #ifndef _di_fake_make_operate_expand_
-  void fake_make_operate_expand(fake_make_data_t * const data_make, const f_string_range_t section_name, const f_fss_content_t content, const f_uint8s_t quotes) {
+  void fake_make_operate_expand(fake_make_data_t * const data_make, const f_string_range_t section_name, const f_string_ranges_t content, const f_uint8s_t quotes) {
 
     if (!data_make || !data_make->main) return;
     if (F_status_is_error(data_make->main->setting.state.status)) return;
index ba307395a7f08abddd2a09a90431f7552d0378a1..4eab83644e5f176247d73a76115b0a22d21efda4 100644 (file)
@@ -103,7 +103,7 @@ extern "C" {
  * @see fake_make_operate_expand_environment()
  */
 #ifndef _di_fake_make_operate_expand_
-  extern void fake_make_operate_expand(fake_make_data_t * const data_make, const f_string_range_t section_name, const f_fss_content_t content, const f_uint8s_t quotes);
+  extern void fake_make_operate_expand(fake_make_data_t * const data_make, const f_string_range_t section_name, const f_string_ranges_t content, const f_uint8s_t quotes);
 #endif // _di_fake_make_operate_expand_
 
 /**
index 6a9aba87029c1ce2119151c90c083730deb51706..9252930a2286e66f52b37c492355802524893f6d 100644 (file)
@@ -23,10 +23,10 @@ typedef struct {
   f_string_dynamic_t buffer;
   f_number_unsigned_t chain;
   f_number_unsigneds_t chain_ids;
-  f_fss_objects_t chain_objects;
-  f_fss_contents_t chain_contents;
-  f_fss_objects_t rule_objects;
-  f_fss_contents_t rule_contents;
+  f_string_ranges_t chain_objects;
+  f_string_rangess_t chain_contents;
+  f_string_ranges_t rule_objects;
+  f_string_rangess_t rule_contents;
 } firewall_local_data_t;
 
 #define firewall_local_data_t_initialize \
@@ -39,10 +39,10 @@ typedef struct {
     f_string_dynamic_t_initialize, \
     0, \
     f_number_unsigneds_t_initialize, \
-    f_fss_objects_t_initialize, \
-    f_fss_contents_t_initialize, \
-    f_fss_objects_t_initialize, \
-    f_fss_contents_t_initialize, \
+    f_string_ranges_t_initialize, \
+    f_string_rangess_t_initialize, \
+    f_string_ranges_t_initialize, \
+    f_string_rangess_t_initialize, \
   }
 
 typedef struct {
index b293b06ec38a942862be72c71ea5af01caf86de9..64e9815b52f3afc0222cfe21f2134e0d4da712d8 100644 (file)
@@ -535,8 +535,8 @@ f_status_t firewall_perform_commands(firewall_data_t * const data, firewall_loca
           f_string_dynamic_t path_file = f_string_dynamic_t_initialize;
           f_string_dynamic_t local_buffer = f_string_dynamic_t_initialize;
 
-          f_fss_objects_t basic_objects = f_fss_objects_t_initialize;
-          f_fss_contents_t basic_contents = f_fss_objects_t_initialize;
+          f_string_ranges_t basic_objects = f_string_ranges_t_initialize;
+          f_string_rangess_t basic_contents = f_string_ranges_t_initialize;
 
           status = f_string_dynamic_append(firewall_network_path_s, &path_file);
 
@@ -612,7 +612,7 @@ f_status_t firewall_perform_commands(firewall_data_t * const data, firewall_loca
               }
             }
             else {
-              f_fss_delimits_t delimits = f_fss_delimits_t_initialize;
+              f_number_unsigneds_t delimits = f_number_unsigneds_t_initialize;
 
               {
                 f_state_t state = f_state_t_initialize;
@@ -1201,8 +1201,8 @@ f_status_t firewall_buffer_rules(firewall_data_t * const data, const f_string_st
     return status;
   }
 
-  f_fss_delimits_t delimits = f_fss_delimits_t_initialize;
-  f_fss_comments_t comments = f_fss_comments_t_initialize;
+  f_number_unsigneds_t delimits = f_number_unsigneds_t_initialize;
+  f_string_range_t comments = f_string_range_t_initialize;
   f_state_t state = f_state_t_initialize;
 
   {
@@ -1237,8 +1237,8 @@ f_status_t firewall_buffer_rules(firewall_data_t * const data, const f_string_st
     }
   }
 
-  macro_f_fss_delimits_t_delete_simple(delimits);
-  macro_f_fss_comments_t_delete_simple(comments);
+  macro_f_number_unsigneds_t_delete_simple(delimits);
+  macro_f_string_range_t_delete_simple(comments);
 
   return status;
 }
@@ -1248,7 +1248,7 @@ f_status_t firewall_process_rules(firewall_data_t * const data, f_string_range_t
   if (!data || !range || !local) return F_status_set_error(F_parameter);
 
   f_status_t status = F_none;
-  f_fss_delimits_t delimits = f_fss_delimits_t_initialize;
+  f_number_unsigneds_t delimits = f_number_unsigneds_t_initialize;
   f_state_t state = f_state_t_initialize;
 
   status = fll_fss_extended_read(local->buffer, state, range, &local->rule_objects, &local->rule_contents, 0, 0, &delimits, 0);
@@ -1261,7 +1261,7 @@ f_status_t firewall_process_rules(firewall_data_t * const data, f_string_range_t
     }
   }
 
-  macro_f_fss_delimits_t_delete_simple(delimits);
+  macro_f_number_unsigneds_t_delete_simple(delimits);
 
   if (F_status_is_error_not(status)) {
     status = firewall_perform_commands(data, local);
index 4d723670d11d9cedeab7561043d863d8b40acc84..b01be29ac096252b1d7c1f49d60628c52f246906 100644 (file)
@@ -249,9 +249,9 @@ extern "C" {
 
       fss_embedded_list_read_depths_t depths = fss_embedded_list_read_depths_t_initialize;
 
-      f_fss_delimits_t objects_delimits = f_fss_delimits_t_initialize;
-      f_fss_delimits_t contents_delimits = f_fss_delimits_t_initialize;
-      f_fss_comments_t comments = f_fss_comments_t_initialize;
+      f_number_unsigneds_t objects_delimits = f_number_unsigneds_t_initialize;
+      f_number_unsigneds_t contents_delimits = f_number_unsigneds_t_initialize;
+      f_string_range_t comments = f_string_range_t_initialize;
 
       if (F_status_is_error_not(status)) {
         status = fss_embedded_list_read_main_preprocess_depth(&data, &depths);
index 393e3c839f2debb6e9dd0e00ae0d4d440a327bdf..cd29e46e87746a66a58b1adde062144bdadaab6c 100644 (file)
@@ -240,7 +240,7 @@ extern "C" {
 #endif // _di_fss_embedded_list_read_main_preprocess_depth_
 
 #ifndef _di_fss_embedded_list_read_main_process_file_
-  f_status_t fss_embedded_list_read_main_process_file(fss_embedded_list_read_data_t * const data, const f_string_static_t filename, const fss_embedded_list_read_depths_t depths, f_fss_delimits_t *objects_delimits, f_fss_delimits_t *contents_delimits, f_fss_comments_t *comments) {
+  f_status_t fss_embedded_list_read_main_process_file(fss_embedded_list_read_data_t * const data, const f_string_static_t filename, const fss_embedded_list_read_depths_t depths, f_number_unsigneds_t *objects_delimits, f_number_unsigneds_t *contents_delimits, f_string_range_t *comments) {
 
     f_status_t status = F_none;
 
@@ -336,7 +336,7 @@ extern "C" {
 
 
     if (data->main->parameters.array[fss_embedded_list_read_parameter_original_e].result & f_console_result_found_e) {
-      f_fss_delimits_t except_none = f_fss_delimits_t_initialize;
+      f_number_unsigneds_t except_none = f_number_unsigneds_t_initialize;
 
       return fss_embedded_list_read_main_process_for_depth(data, filename, depths, 0, line, parents, &except_none, &except_none);
     }
@@ -346,7 +346,7 @@ extern "C" {
 #endif // _di_fss_embedded_list_read_main_process_file_
 
 #ifndef _di_fss_embedded_list_read_main_process_for_depth_
-  f_status_t fss_embedded_list_read_main_process_for_depth(fss_embedded_list_read_data_t * const data, const f_string_static_t filename, const fss_embedded_list_read_depths_t depths, const f_number_unsigned_t depths_index, const f_number_unsigned_t line, const fss_embedded_list_read_skip_t parents, f_fss_delimits_t *objects_delimits, f_fss_delimits_t *contents_delimits) {
+  f_status_t fss_embedded_list_read_main_process_for_depth(fss_embedded_list_read_data_t * const data, const f_string_static_t filename, const fss_embedded_list_read_depths_t depths, const f_number_unsigned_t depths_index, const f_number_unsigned_t line, const fss_embedded_list_read_skip_t parents, f_number_unsigneds_t *objects_delimits, f_number_unsigneds_t *contents_delimits) {
 
     f_fss_items_t *items = &data->nest.depth[depths.array[depths_index].depth];
 
@@ -680,7 +680,7 @@ extern "C" {
 #endif // _di_fss_embedded_list_read_main_process_for_depth_
 
 #ifndef _di_fss_embedded_list_read_process_delimits_
-  void fss_embedded_list_read_process_delimits(fss_embedded_list_read_data_t * const data, f_fss_delimits_t *objects_delimits, f_fss_delimits_t *contents_delimits) {
+  void fss_embedded_list_read_process_delimits(fss_embedded_list_read_data_t * const data, f_number_unsigneds_t *objects_delimits, f_number_unsigneds_t *contents_delimits) {
 
     if (!data->nest.used) return;
 
@@ -754,7 +754,7 @@ extern "C" {
 #endif // _di_fss_embedded_list_read_process_delimits_
 
 #ifndef _di_fss_embedded_list_read_process_delimits_contents_
-  void fss_embedded_list_read_process_delimits_contents(fss_embedded_list_read_data_t * const data, const f_number_unsigned_t depth, const f_number_unsigned_t original_delimits[], const f_number_unsigned_t original_used, f_fss_delimits_t *delimits) {
+  void fss_embedded_list_read_process_delimits_contents(fss_embedded_list_read_data_t * const data, const f_number_unsigned_t depth, const f_number_unsigned_t original_delimits[], const f_number_unsigned_t original_used, f_number_unsigneds_t *delimits) {
 
     if (!original_used) return;
 
@@ -807,7 +807,7 @@ extern "C" {
 #endif // _di_fss_embedded_list_read_process_delimits_contents_
 
 #ifndef _di_fss_embedded_list_read_process_delimits_objects_
-  void fss_embedded_list_read_process_delimits_objects(fss_embedded_list_read_data_t * const data, const f_number_unsigned_t depth, const f_number_unsigned_t original_delimits[], const f_number_unsigned_t original_used, f_fss_delimits_t *delimits) {
+  void fss_embedded_list_read_process_delimits_objects(fss_embedded_list_read_data_t * const data, const f_number_unsigned_t depth, const f_number_unsigned_t original_delimits[], const f_number_unsigned_t original_used, f_number_unsigneds_t *delimits) {
 
     if (!original_used) return;
 
index ea0d0ad7db03deebcd7379b372abecdeec67694a..e8a935437f31384edf76272b0afa395ed710f7cb 100644 (file)
@@ -57,7 +57,7 @@ extern "C" {
  *   Status codes (with error bit) are returned on any problem.
  */
 #ifndef _di_fss_embedded_list_read_main_process_file_
-  extern f_status_t fss_embedded_list_read_main_process_file(fss_embedded_list_read_data_t * const data, const f_string_static_t file_name, const fss_embedded_list_read_depths_t depths, f_fss_delimits_t *objects_delimits, f_fss_delimits_t *contents_delimits, f_fss_comments_t *comments) F_attribute_visibility_internal_d;
+  extern f_status_t fss_embedded_list_read_main_process_file(fss_embedded_list_read_data_t * const data, const f_string_static_t file_name, const fss_embedded_list_read_depths_t depths, f_number_unsigneds_t *objects_delimits, f_number_unsigneds_t *contents_delimits, f_string_range_t *comments) F_attribute_visibility_internal_d;
 #endif // _di_fss_embedded_list_read_main_process_file_
 
 /**
@@ -91,7 +91,7 @@ extern "C" {
  * @see fss_embedded_list_read_main_process_file()
  */
 #ifndef _di_fss_embedded_list_read_main_process_for_depth_
-  extern f_status_t fss_embedded_list_read_main_process_for_depth(fss_embedded_list_read_data_t * const data, const f_string_static_t filename, const fss_embedded_list_read_depths_t depths, const f_number_unsigned_t depths_index, const f_number_unsigned_t line, const fss_embedded_list_read_skip_t parents, f_fss_delimits_t *objects_delimits, f_fss_delimits_t *contents_delimits) F_attribute_visibility_internal_d;
+  extern f_status_t fss_embedded_list_read_main_process_for_depth(fss_embedded_list_read_data_t * const data, const f_string_static_t filename, const fss_embedded_list_read_depths_t depths, const f_number_unsigned_t depths_index, const f_number_unsigned_t line, const fss_embedded_list_read_skip_t parents, f_number_unsigneds_t *objects_delimits, f_number_unsigneds_t *contents_delimits) F_attribute_visibility_internal_d;
 #endif // _di_fss_embedded_list_read_main_process_for_depth_
 
 /**
@@ -107,7 +107,7 @@ extern "C" {
  * @see fss_embedded_list_read_main_process_file()
  */
 #ifndef _di_fss_embedded_list_read_process_delimits_
-  extern void fss_embedded_list_read_process_delimits(fss_embedded_list_read_data_t * const data, f_fss_delimits_t *objects_delimits, f_fss_delimits_t *contents_delimits) F_attribute_visibility_internal_d;
+  extern void fss_embedded_list_read_process_delimits(fss_embedded_list_read_data_t * const data, f_number_unsigneds_t *objects_delimits, f_number_unsigneds_t *contents_delimits) F_attribute_visibility_internal_d;
 #endif // _di_fss_embedded_list_read_process_delimits_
 
 /**
@@ -127,7 +127,7 @@ extern "C" {
  * @see fss_embedded_list_read_process_delimits()
  */
 #ifndef _di_fss_embedded_list_read_process_delimits_contents_
-  extern void fss_embedded_list_read_process_delimits_contents(fss_embedded_list_read_data_t * const data, const f_number_unsigned_t depth, const f_number_unsigned_t original_delimits[], const f_number_unsigned_t original_used, f_fss_delimits_t *delimits) F_attribute_visibility_internal_d;
+  extern void fss_embedded_list_read_process_delimits_contents(fss_embedded_list_read_data_t * const data, const f_number_unsigned_t depth, const f_number_unsigned_t original_delimits[], const f_number_unsigned_t original_used, f_number_unsigneds_t *delimits) F_attribute_visibility_internal_d;
 #endif // _di_fss_embedded_list_read_process_delimits_contents_
 
 /**
@@ -147,7 +147,7 @@ extern "C" {
  * @see fss_embedded_list_read_process_delimits()
  */
 #ifndef _di_fss_embedded_list_read_process_delimits_objects_
-  extern void fss_embedded_list_read_process_delimits_objects(fss_embedded_list_read_data_t * const data, const f_number_unsigned_t depth, const f_number_unsigned_t original_delimits[], const f_number_unsigned_t original_used, f_fss_delimits_t *delimits) F_attribute_visibility_internal_d;
+  extern void fss_embedded_list_read_process_delimits_objects(fss_embedded_list_read_data_t * const data, const f_number_unsigned_t depth, const f_number_unsigned_t original_delimits[], const f_number_unsigned_t original_used, f_number_unsigneds_t *delimits) F_attribute_visibility_internal_d;
 #endif // _di_fss_embedded_list_read_process_delimits_objects_
 
 /**
index d0d97b9d2ae2ad77ce543f3fe0c0d44117cefa7d..6548de7f771adaf4dd008b854e6eb86823401f7d 100644 (file)
@@ -144,16 +144,16 @@ extern "C" {
     void (*process_last_line)(void * const main);
     void (*process_normal)(void * const main);
 
-    void (*process_at)(void * const main, const bool names[], const f_fss_delimits_t delimits_object, const f_fss_delimits_t delimits_content);
+    void (*process_at)(void * const main, const bool names[], const f_number_unsigneds_t delimits_object, const f_number_unsigneds_t delimits_content);
     void (*process_at_line)(void * const void_main, const f_number_unsigned_t at, const f_number_unsigneds_t delimits_object, const f_number_unsigneds_t delimits_content, f_number_unsigned_t * const line);
     void (*process_columns)(void * const main, const bool names[]);
     void (*process_load)(void * const main);
     void (*process_name)(void * const main, bool names[]);
     void (*process_total)(void * const main, const bool names[]);
 
-    f_status_t (*print_at)(fl_print_t * const print, const f_number_unsigned_t at, const f_fss_delimits_t delimits_object, const f_fss_delimits_t delimits_content);
-    f_status_t (*print_object)(fl_print_t * const print, const f_number_unsigned_t at, const f_fss_delimits_t delimits);
-    f_status_t (*print_content)(fl_print_t * const print, const f_string_range_t range, const uint8_t quote, const f_fss_delimits_t delimits);
+    f_status_t (*print_at)(fl_print_t * const print, const f_number_unsigned_t at, const f_number_unsigneds_t delimits_object, const f_number_unsigneds_t delimits_content);
+    f_status_t (*print_object)(fl_print_t * const print, const f_number_unsigned_t at, const f_number_unsigneds_t delimits);
+    f_status_t (*print_content)(fl_print_t * const print, const f_string_range_t range, const uint8_t quote, const f_number_unsigneds_t delimits);
     f_status_t (*print_content_ignore)(fl_print_t * const print);
     f_status_t (*print_content_next)(fl_print_t * const print);
     f_status_t (*print_object_end)(fl_print_t * const print);
@@ -236,12 +236,12 @@ extern "C" {
     f_string_static_t standard;
     f_string_dynamic_t buffer;
 
-    f_fss_comments_t comments;
-    f_fss_contents_t contents;
-    f_fss_delimits_t delimits_object;
-    f_fss_delimits_t delimits_content;
+    f_string_ranges_t comments;
+    f_string_rangess_t contents;
+    f_number_unsigneds_t delimits_object;
+    f_number_unsigneds_t delimits_content;
     f_fss_nest_t nest;
-    f_fss_objects_t objects;
+    f_string_ranges_t objects;
 
     f_uint8s_t quotes_object;
     f_uint8ss_t quotes_content;
@@ -261,12 +261,12 @@ extern "C" {
       fss_read_depths_t_initialize, \
       f_string_static_t_initialize, \
       f_string_dynamic_t_initialize, \
-      f_fss_comments_t_initialize, \
-      f_fss_contents_t_initialize, \
-      f_fss_delimits_t_initialize, \
-      f_fss_delimits_t_initialize, \
+      f_string_ranges_t_initialize, \
+      f_string_rangess_t_initialize, \
+      f_number_unsigneds_t_initialize, \
+      f_number_unsigneds_t_initialize, \
       f_fss_nest_t_initialize, \
-      f_fss_objects_t_initialize, \
+      f_string_ranges_t_initialize, \
       f_uint8s_t_initialize, \
       f_uint8ss_t_initialize, \
     }
index 5efc8270e5c0fef0fb634c104c3b26d293a140c6..648f011cb3b9702a3e3d53b28ec1b94006183ee1 100644 (file)
@@ -5,7 +5,7 @@ extern "C" {
 #endif
 
 #ifndef _di_fss_read_print_at_
-  f_status_t fss_read_print_at(fl_print_t * const print, const f_number_unsigned_t at, const f_fss_delimits_t delimits_object, const f_fss_delimits_t delimits_content) {
+  f_status_t fss_read_print_at(fl_print_t * const print, const f_number_unsigned_t at, const f_number_unsigneds_t delimits_object, const f_number_unsigneds_t delimits_content) {
 
     if (!print || !print->custom) return F_status_set_error(F_output_not);
 
@@ -64,7 +64,7 @@ extern "C" {
 #endif // _di_fss_read_print_at_
 
 #ifndef _di_fss_read_print_content_
-  f_status_t fss_read_print_content(fl_print_t * const print, const f_string_range_t range, const uint8_t quote, const f_fss_delimits_t delimits) {
+  f_status_t fss_read_print_content(fl_print_t * const print, const f_string_range_t range, const uint8_t quote, const f_number_unsigneds_t delimits) {
 
     if (!print || !print->custom) return F_status_set_error(F_output_not);
 
@@ -123,7 +123,7 @@ extern "C" {
 #endif // _di_fss_read_print_number_
 
 #ifndef _di_fss_read_print_object_
-  f_status_t fss_read_print_object(fl_print_t * const print, const f_number_unsigned_t at, const f_fss_delimits_t delimits) {
+  f_status_t fss_read_print_object(fl_print_t * const print, const f_number_unsigned_t at, const f_number_unsigneds_t delimits) {
 
     if (!print || !print->custom) return F_status_set_error(F_output_not);
 
index 80ce1339f8f0f43de1d1639d4a7e074f41cd3763..96c857c9ba1f945f882bf7f4843ab5df095f54a1 100644 (file)
@@ -55,7 +55,7 @@ extern "C" {
  * @see main.callback.print_set_end()
  */
 #ifndef _di_fss_read_print_at_
-  extern f_status_t fss_read_print_at(fl_print_t * const print, const f_number_unsigned_t at, const f_fss_delimits_t delimits_object, const f_fss_delimits_t delimits_content);
+  extern f_status_t fss_read_print_at(fl_print_t * const print, const f_number_unsigned_t at, const f_number_unsigneds_t delimits_object, const f_number_unsigneds_t delimits_content);
 #endif // _di_fss_read_print_at_
 
 /**
@@ -91,7 +91,7 @@ extern "C" {
  * @see main.callback.print_set_end()
  */
 #ifndef _di_fss_read_print_content_
-  extern f_status_t fss_read_print_content(fl_print_t * const print, const f_string_range_t range, const uint8_t quote, const f_fss_delimits_t delimits);
+  extern f_status_t fss_read_print_content(fl_print_t * const print, const f_string_range_t range, const uint8_t quote, const f_number_unsigneds_t delimits);
 #endif // _di_fss_read_print_content_
 
 /**
@@ -177,7 +177,7 @@ extern "C" {
  * @see fss_read_print_quote()
  */
 #ifndef _di_fss_read_print_object_
-  extern f_status_t fss_read_print_object(fl_print_t * const print, const f_number_unsigned_t at, const f_fss_delimits_t delimits);
+  extern f_status_t fss_read_print_object(fl_print_t * const print, const f_number_unsigned_t at, const f_number_unsigneds_t delimits);
 #endif // _di_fss_read_print_object_
 
 /**
index 44c7273ac2ceea42b39f782a04931b015d91411d..7774c24e8292daeb1f32c2ca4093564e2caef83e 100644 (file)
@@ -73,7 +73,7 @@ extern "C" {
  * @see fss_read_signal_check()
  */
 #ifndef _di_fss_read_process_normal_at_
-  extern void fss_read_process_normal_at(void * const main, const bool names[], const f_fss_delimits_t delimits_object, const f_fss_delimits_t delimits_content);
+  extern void fss_read_process_normal_at(void * const main, const bool names[], const f_number_unsigneds_t delimits_object, const f_number_unsigneds_t delimits_content);
 #endif // _di_fss_read_process_normal_at_
 
 /**