@@ -20,6 +20,23 @@ module json_parameters
20
20
21
21
character (kind= CDK,len=* ),parameter :: json_ext = ' .json' ! ! JSON file extension
22
22
23
+ ! The types of JSON data.
24
+ integer (IK),parameter :: json_unknown = 0 ! ! Unknown JSON data type
25
+ ! ! (see [[json_file_variable_info]] and [[json_info]])
26
+ integer (IK),parameter :: json_null = 1 ! ! Null JSON data type
27
+ ! ! (see [[json_file_variable_info]] and [[json_info]])
28
+ integer (IK),parameter :: json_object = 2 ! ! Object JSON data type
29
+ ! ! (see [[json_file_variable_info]] and [[json_info]])
30
+ integer (IK),parameter :: json_array = 3 ! ! Array JSON data type
31
+ ! ! (see [[json_file_variable_info]] and [[json_info]])
32
+ integer (IK),parameter :: json_logical = 4 ! ! Logical JSON data type
33
+ ! ! (see [[json_file_variable_info]] and [[json_info]])
34
+ integer (IK),parameter :: json_integer = 5 ! ! Integer JSON data type
35
+ ! ! (see [[json_file_variable_info]] and [[json_info]])
36
+ integer (IK),parameter :: json_double = 6 ! ! Double JSON data type
37
+ ! ! (see [[json_file_variable_info]] and [[json_info]])
38
+ integer (IK),parameter :: json_string = 7 ! ! String JSON data type
39
+
23
40
! special JSON characters
24
41
character (kind= CK,len=* ),parameter :: space = ' '
25
42
character (kind= CK,len=* ),parameter :: start_object = ' {'
@@ -42,20 +59,20 @@ module json_parameters
42
59
character (kind= CK,len=* ),parameter :: slash = achar (47 )
43
60
character (kind= CK,len=* ),parameter :: backslash = achar (92 )
44
61
45
- character (kind= CDK,len=* ),parameter , public :: default_real_fmt = ' (ss,E26.16E4)'
62
+ character (kind= CDK,len=* ),parameter :: default_real_fmt = ' (ss,E26.16E4)'
46
63
! ! default real number format statement (for writing real values to strings and files).
47
64
! ! Note that this can be overridden by calling [[json_initialize]].
48
65
49
- character (kind= CK,len=* ),parameter , public :: star = ' *' ! ! for invalid numbers and
66
+ character (kind= CK,len=* ),parameter :: star = ' *' ! ! for invalid numbers and
50
67
! ! list-directed real output
51
68
52
69
#if defined __GFORTRAN__
53
70
! not parameters due to gfortran bug (https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65141)
54
71
character (kind= CK,len= 26 ),protected :: upper = ' ABCDEFGHIJKLMNOPQRSTUVWXYZ' ! ! uppercase characters
55
72
character (kind= CK,len= 26 ),protected :: lower = ' abcdefghijklmnopqrstuvwxyz' ! ! lowercase characters
56
73
#else
57
- character (kind= CK,len=* ),parameter , public :: upper = ' ABCDEFGHIJKLMNOPQRSTUVWXYZ' ! ! uppercase characters
58
- character (kind= CK,len=* ),parameter , public :: lower = ' abcdefghijklmnopqrstuvwxyz' ! ! lowercase characters
74
+ character (kind= CK,len=* ),parameter :: upper = ' ABCDEFGHIJKLMNOPQRSTUVWXYZ' ! ! uppercase characters
75
+ character (kind= CK,len=* ),parameter :: lower = ' abcdefghijklmnopqrstuvwxyz' ! ! lowercase characters
59
76
#endif
60
77
61
78
#if defined __GFORTRAN__
@@ -64,9 +81,9 @@ module json_parameters
64
81
character (kind= CK,len= 4 ),protected :: true_str = ' true' ! ! JSON logical True string
65
82
character (kind= CK,len= 5 ),protected :: false_str = ' false' ! ! JSON logical False string
66
83
#else
67
- character (kind= CK,len=* ),parameter , public :: null_str = ' null' ! ! JSON Null variable string
68
- character (kind= CK,len=* ),parameter , public :: true_str = ' true' ! ! JSON logical True string
69
- character (kind= CK,len=* ),parameter , public :: false_str = ' false' ! ! JSON logical False string
84
+ character (kind= CK,len=* ),parameter :: null_str = ' null' ! ! JSON Null variable string
85
+ character (kind= CK,len=* ),parameter :: true_str = ' true' ! ! JSON logical True string
86
+ character (kind= CK,len=* ),parameter :: false_str = ' false' ! ! JSON logical False string
70
87
#endif
71
88
72
89
integer , private :: i_ ! ! just a counter for `control_chars` array
@@ -96,9 +113,9 @@ module json_parameters
96
113
! ! output to strings rather than files.
97
114
! ! See 9.5.6.12 in the F2003/08 standard
98
115
99
- integer (IK),parameter , public :: seq_chunk_size = 256_IK ! ! chunk size for reading sequential files
116
+ integer (IK),parameter :: seq_chunk_size = 256_IK ! ! chunk size for reading sequential files
100
117
101
- integer (IK),parameter , public :: pushed_char_size = 10_IK ! ! magic number
118
+ integer (IK),parameter :: pushed_char_size = 10_IK ! ! magic number
102
119
103
120
end module json_parameters
104
121
! *****************************************************************************************
0 commit comments