@@ -93,13 +93,45 @@ and then do the usual stuff, e.g.
93
93
or whatever you want.
94
94
95
95
96
- Resetting the dictionary
97
- ------------------------
98
- If you need to reset the dictionary (e.g. so that you can reload the
99
- updated files from disk), use shared_ispell_reset() function. Eveyone
100
- who already uses the dictionaries will be forced to reinitialize the
101
- data (first one will rebuild the dictionary in shared segment, the
102
- other ones will use this).
96
+ Available functions
97
+ -------------------
98
+ The extension provides five management functions, that allow you to
99
+ manage and get info about the preloaded dictionaries. The first two
100
+ functions
101
+
102
+ shared_ispell_mem_used()
103
+ shared_ispell_mem_available()
104
+
105
+ allow you to get info about the shared segment (used and free memory)
106
+ e.g. to properly size the segment (max_size). Then there are functions
107
+ return list of dictionaries / stop lists loaded in the shared segment
108
+
109
+ shared_ispell_dicts()
110
+ shared_ispell_stoplists()
111
+
112
+ e.g. like this
113
+
114
+ SELECT * FROM shared_ispell_dicts();
115
+
116
+ dict_name | affix_name | words | affixes | bytes
117
+ -----------+------------+-------+---------+----------
118
+ bulgarian | bulgarian | 79267 | 12 | 7622128
119
+ czech | czech | 96351 | 2544 | 12715000
120
+ (2 rows)
121
+
122
+
123
+ SELECT * FROM shared_ispell_stoplists();
124
+
125
+ stop_name | words | bytes
126
+ -----------+-------+-------
127
+ czech | 259 | 4552
128
+ (1 row)
129
+
130
+ The last function allows you to reset the dictionary (e.g. so that you
131
+ can reload the updated files from disk). The sessions that already use
132
+ the dictionaries will be forced to reinitialize them (the first one
133
+ will rebuild and copy them in the shared segment, the other ones will
134
+ use this prepared data).
103
135
104
136
SELECT shared_ispell_reset();
105
137