json_file_module Module


File encoding preprocessor macro.



This C preprocessor macro will take a procedure name as an input, and output either that same procedure name if the code is compiled without USE_UCS4 being defined or it will expand the procedure name to the original procedure name, followed by a comma and then the original procedure name with 'wrap_' prepended to it. This is suitable for creating overloaded interfaces that will accept UCS4 character actual arguments as well as DEFAULT/ASCII character arguments, based on whether or not ISO 10646 is supported and requested.







































































































Interfaces

public interface json_file

  • private function initialize_json_file(p, verbose, compact_reals, print_signs, real_format, spaces_per_tab, strict_type_checking, trailing_spaces_significant, case_sensitive_keys) result(file_object)

    Arguments

    Type IntentOptional AttributesName
    type(json_value), intent(in), optional pointer:: p

    json_value object to cast as a json_file object

    logical(kind=LK), intent(in), optional :: verbose

    mainly useful for debugging (default is false)

    logical(kind=LK), intent(in), optional :: compact_reals

    to compact the real number strings for output (default is true)

    logical(kind=LK), intent(in), optional :: print_signs

    always print numeric sign (default is false)

    character(kind=CDK,len=*), intent(in), optional :: real_format

    Real number format: 'E' [default], '*', 'G', 'EN', or 'ES'

    integer(kind=IK), intent(in), optional :: spaces_per_tab

    number of spaces per tab for indenting (default is 2)

    logical(kind=LK), intent(in), optional :: strict_type_checking

    if true, no integer, double, or logical type conversions are done for the get routines (default is false)

    logical(kind=LK), intent(in), optional :: trailing_spaces_significant

    for name and path comparisons, is trailing space to be considered significant.

    logical(kind=LK), intent(in), optional :: case_sensitive_keys

    for name and path comparisons, are they case sensitive.

    Return Value type(json_file)

  • private function initialize_json_file_v2(json_value_object, json_core_object) result(file_object)

    Arguments

    Type IntentOptional AttributesName
    type(json_value), intent(in), pointer:: json_value_object
    type(json_core), intent(in) :: json_core_object

    Return Value type(json_file)


Derived Types

type, public :: json_file

Constructor

private function initialize_json_file(p, verbose, compact_reals, print_signs, real_format, spaces_per_tab, strict_type_checking, trailing_spaces_significant, case_sensitive_keys)
private function initialize_json_file_v2(json_value_object, json_core_object)

Type-Bound Procedures

procedure, public :: initialize => initialize_json_core_in_file
procedure, public :: load_file => json_file_load
generic, public :: load_from_string => json_file_load_from_string
procedure, public :: destroy => json_file_destroy
procedure, public :: move => json_file_move_pointer
generic, public :: info => json_file_variable_info
procedure, public :: failed => json_file_failed
procedure, public :: print_error_message => json_file_print_error_message
procedure, public :: check_for_errors => json_file_check_for_errors
procedure, public :: clear_exceptions => json_file_clear_exceptions
procedure, public :: print_to_string => json_file_print_to_string
generic, public :: print_file => json_file_print_to_console, json_file_print_1, json_file_print_2
generic, public :: get => json_file_get_object, json_file_get_integer, json_file_get_double, json_file_get_logical, json_file_get_string, json_file_get_integer_vec, json_file_get_double_vec, json_file_get_logical_vec, json_file_get_string_vec, json_file_get_root
generic, public :: update => json_file_update_integer, json_file_update_logical, json_file_update_real, json_file_update_string
procedure, public :: json_file_load_from_string
procedure, public :: json_file_variable_info
procedure, public :: json_file_get_object
procedure, public :: json_file_get_integer
procedure, public :: json_file_get_double
procedure, public :: json_file_get_logical
procedure, public :: json_file_get_string
procedure, public :: json_file_get_integer_vec
procedure, public :: json_file_get_double_vec
procedure, public :: json_file_get_logical_vec
procedure, public :: json_file_get_string_vec
procedure, public :: json_file_get_root
procedure, public :: json_file_update_integer
procedure, public :: json_file_update_logical
procedure, public :: json_file_update_real
procedure, public :: json_file_update_string
procedure, public :: json_file_print_to_console
procedure, public :: json_file_print_1
procedure, public :: json_file_print_2