»Core Development>Code coverage>Modules/_sqlite/prepare_protocol.c

Python code coverage for Modules/_sqlite/prepare_protocol.c

#countcontent
1n/a/* prepare_protocol.c - the protocol for preparing values for SQLite
2n/a *
3n/a * Copyright (C) 2005-2010 Gerhard Häring <gh@ghaering.de>
4n/a *
5n/a * This file is part of pysqlite.
6n/a *
7n/a * This software is provided 'as-is', without any express or implied
8n/a * warranty. In no event will the authors be held liable for any damages
9n/a * arising from the use of this software.
10n/a *
11n/a * Permission is granted to anyone to use this software for any purpose,
12n/a * including commercial applications, and to alter it and redistribute it
13n/a * freely, subject to the following restrictions:
14n/a *
15n/a * 1. The origin of this software must not be misrepresented; you must not
16n/a * claim that you wrote the original software. If you use this software
17n/a * in a product, an acknowledgment in the product documentation would be
18n/a * appreciated but is not required.
19n/a * 2. Altered source versions must be plainly marked as such, and must not be
20n/a * misrepresented as being the original software.
21n/a * 3. This notice may not be removed or altered from any source distribution.
22n/a */
23n/a
24n/a#include "prepare_protocol.h"
25n/a
26n/aint pysqlite_prepare_protocol_init(pysqlite_PrepareProtocol* self, PyObject* args, PyObject* kwargs)
27n/a{
28n/a return 0;
29n/a}
30n/a
31n/avoid pysqlite_prepare_protocol_dealloc(pysqlite_PrepareProtocol* self)
32n/a{
33n/a Py_TYPE(self)->tp_free((PyObject*)self);
34n/a}
35n/a
36n/aPyTypeObject pysqlite_PrepareProtocolType= {
37n/a PyVarObject_HEAD_INIT(NULL, 0)
38n/a MODULE_NAME ".PrepareProtocol", /* tp_name */
39n/a sizeof(pysqlite_PrepareProtocol), /* tp_basicsize */
40n/a 0, /* tp_itemsize */
41n/a (destructor)pysqlite_prepare_protocol_dealloc, /* tp_dealloc */
42n/a 0, /* tp_print */
43n/a 0, /* tp_getattr */
44n/a 0, /* tp_setattr */
45n/a 0, /* tp_reserved */
46n/a 0, /* tp_repr */
47n/a 0, /* tp_as_number */
48n/a 0, /* tp_as_sequence */
49n/a 0, /* tp_as_mapping */
50n/a 0, /* tp_hash */
51n/a 0, /* tp_call */
52n/a 0, /* tp_str */
53n/a 0, /* tp_getattro */
54n/a 0, /* tp_setattro */
55n/a 0, /* tp_as_buffer */
56n/a Py_TPFLAGS_DEFAULT, /* tp_flags */
57n/a 0, /* tp_doc */
58n/a 0, /* tp_traverse */
59n/a 0, /* tp_clear */
60n/a 0, /* tp_richcompare */
61n/a 0, /* tp_weaklistoffset */
62n/a 0, /* tp_iter */
63n/a 0, /* tp_iternext */
64n/a 0, /* tp_methods */
65n/a 0, /* tp_members */
66n/a 0, /* tp_getset */
67n/a 0, /* tp_base */
68n/a 0, /* tp_dict */
69n/a 0, /* tp_descr_get */
70n/a 0, /* tp_descr_set */
71n/a 0, /* tp_dictoffset */
72n/a (initproc)pysqlite_prepare_protocol_init, /* tp_init */
73n/a 0, /* tp_alloc */
74n/a 0, /* tp_new */
75n/a 0 /* tp_free */
76n/a};
77n/a
78n/aextern int pysqlite_prepare_protocol_setup_types(void)
79n/a{
80n/a pysqlite_PrepareProtocolType.tp_new = PyType_GenericNew;
81n/a Py_TYPE(&pysqlite_PrepareProtocolType)= &PyType_Type;
82n/a return PyType_Ready(&pysqlite_PrepareProtocolType);
83n/a}