forked from proycon/python-frog
-
Notifications
You must be signed in to change notification settings - Fork 0
/
frog_classes.pxd
68 lines (52 loc) · 1.73 KB
/
frog_classes.pxd
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
56
57
58
59
60
61
62
63
64
65
66
67
68
#*****************************
# Python-frog
# by Maarten van Gompel
# Centre for Language Studies
# Radboud University Nijmegen
#
# Licensed under GPLv3
#****************************/
from libcpp.string cimport string
from libcpp.vector cimport vector
from libcpp cimport bool
from libc.stdint cimport *
from libfolia_classes cimport Document
cdef extern from "<iostream>" namespace "std":
cdef cppclass ostream:
ostream()
cdef cppclass istream:
pass
extern ostream cout
extern ostream cerr
cdef extern from "ticcutils/Configuration.h" namespace "TiCC":
cdef cppclass Configuration:
Configuration()
bool fill( string filename )
bool hasSection( string section )
str configDir()
string setatt(string&, string&, string&)
string setatt(string&, string&)
cdef extern from "ticcutils/LogStream.h" namespace "TiCC":
cdef cppclass LogStream:
LogStream()
LogStream(string prefix)
cdef extern from "ticcutils/CommandLine.h" namespace "TiCC":
cdef cppclass CL_Options:
CL_Options()
void insert(string&, string&)
void insert(char, string&, bool)
bool is_present(string&)
bool is_present(char)
cdef extern from "frog/Frog-util.h":
cdef cppclass TimerBlock:
pass
cdef extern from "frog/ucto_tokenizer_mod.h":
cdef cppclass UctoTokenizer:
Document * tokenizehelper( string)
cdef extern from "frog/FrogAPI.h":
cdef cppclass FrogAPI:
UctoTokenizer * tokenizer
FrogAPI(CL_Options& options, LogStream * logstream, LogStream * debuglogstream)
string Frogtostring(string s)
string defaultConfigDir(string lang)
string defaultConfigFile(string lang)