forked from tvondra/shared_ispell
-
Notifications
You must be signed in to change notification settings - Fork 1
/
shared_ispell--1.1.0.sql
55 lines (45 loc) · 1.55 KB
/
shared_ispell--1.1.0.sql
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
CREATE FUNCTION shared_ispell_init(internal)
RETURNS internal
AS 'MODULE_PATHNAME', 'dispell_init'
LANGUAGE C IMMUTABLE;
CREATE FUNCTION shared_ispell_lexize(internal,internal,internal,internal)
RETURNS internal
AS 'MODULE_PATHNAME', 'dispell_lexize'
LANGUAGE C IMMUTABLE;
CREATE FUNCTION shared_ispell_reset()
RETURNS void
AS 'MODULE_PATHNAME', 'dispell_reset'
LANGUAGE C IMMUTABLE;
CREATE FUNCTION shared_ispell_mem_used()
RETURNS integer
AS 'MODULE_PATHNAME', 'dispell_mem_used'
LANGUAGE C IMMUTABLE;
CREATE FUNCTION shared_ispell_mem_available()
RETURNS integer
AS 'MODULE_PATHNAME', 'dispell_mem_available'
LANGUAGE C IMMUTABLE;
CREATE FUNCTION shared_ispell_dicts( OUT dict_name VARCHAR, OUT affix_name VARCHAR, OUT words INT, OUT affixes INT, OUT bytes INT)
RETURNS SETOF record
AS 'MODULE_PATHNAME', 'dispell_list_dicts'
LANGUAGE C IMMUTABLE;
CREATE FUNCTION shared_ispell_stoplists( OUT stop_name VARCHAR, OUT words INT, OUT bytes INT)
RETURNS SETOF record
AS 'MODULE_PATHNAME', 'dispell_list_stoplists'
LANGUAGE C IMMUTABLE;
CREATE TEXT SEARCH TEMPLATE shared_ispell (
INIT = shared_ispell_init,
LEXIZE = shared_ispell_lexize
);
/*
CREATE TEXT SEARCH DICTIONARY czech_shared (
TEMPLATE = shared_ispell,
DictFile = czech,
AffFile = czech,
StopWords = czech
);
CREATE TEXT SEARCH CONFIGURATION public.czech_shared ( COPY = pg_catalog.simple );
ALTER TEXT SEARCH CONFIGURATION czech_shared
ALTER MAPPING FOR asciiword, asciihword, hword_asciipart,
word, hword, hword_part
WITH czech_shared;
*/