4 %include
"std_string.i"
14 char
*_VERSION
= VERSION
;
17 libquviVersion
= QUVI_VERSION
,
18 libquviVersionLong
= QUVI_VERSION_LONG
,
22 static char
* version
(quviVersion n
=ModuleVersion
) {
23 if
(n
== ModuleVersion
) return _VERSION
;
24 return quvi_version
((QUVIversion
)n
);
28 * A manual copy of QUVIcode. If there's a better way to do this
,
29 * I'd like to know it too. This will need to be maintained manually
30 * if there are any changes to the QUVIcode enum list in quvi.h file.
32 * The reason we don't simply
"%include <quvi/quvi.h>" and
33 * get the constants is because that would clutter the wrapper.
35 * We have renamed the constants to avoid any conflicts with those
36 * defined in
<quvi
/quvi.h
> which is included by the wrapper.
49 PcreError
= 0x40, /* QUVI_PCRE
*/
51 CurlError
, /* QUVI_CURL
*/
52 IconvError
, /* QUVI_ICONV
*/
53 LuaError
, /* QUVI_LUA
*/
62 std
::string user_agent
;
63 std
::string http_proxy
;
74 std
::string content_type
;
75 std
::string file_suffix
;
93 /* Query
::_init throws std
::runtime_error if quvi_init fails.
*/
97 catch
(const std
::runtime_error
& e)
98 { SWIG_exception
(SWIG_RuntimeError
, e.what
()); }
101 %apply std
::string
&OUTPUT { std::string &domain, std::string &formats };
108 Video parse
(const std
::string
&, const Options&);
109 int next_website
(std
::string
&domain, std::string &formats);
112 std
::string last_error
;