Edit File by line
/home/barbar84/public_h.../wp-conte.../plugins/sujqvwi/ShExBy/shex_roo.../usr/include/python2....
File: cStringIO.h
#ifndef Py_CSTRINGIO_H
[0] Fix | Delete
#define Py_CSTRINGIO_H
[1] Fix | Delete
#ifdef __cplusplus
[2] Fix | Delete
extern "C" {
[3] Fix | Delete
#endif
[4] Fix | Delete
/*
[5] Fix | Delete
[6] Fix | Delete
This header provides access to cStringIO objects from C.
[7] Fix | Delete
Functions are provided for calling cStringIO objects and
[8] Fix | Delete
macros are provided for testing whether you have cStringIO
[9] Fix | Delete
objects.
[10] Fix | Delete
[11] Fix | Delete
Before calling any of the functions or macros, you must initialize
[12] Fix | Delete
the routines with:
[13] Fix | Delete
[14] Fix | Delete
PycString_IMPORT
[15] Fix | Delete
[16] Fix | Delete
This would typically be done in your init function.
[17] Fix | Delete
[18] Fix | Delete
*/
[19] Fix | Delete
[20] Fix | Delete
#define PycStringIO_CAPSULE_NAME "cStringIO.cStringIO_CAPI"
[21] Fix | Delete
[22] Fix | Delete
#define PycString_IMPORT \
[23] Fix | Delete
PycStringIO = ((struct PycStringIO_CAPI*)PyCapsule_Import(\
[24] Fix | Delete
PycStringIO_CAPSULE_NAME, 0))
[25] Fix | Delete
[26] Fix | Delete
/* Basic functions to manipulate cStringIO objects from C */
[27] Fix | Delete
[28] Fix | Delete
static struct PycStringIO_CAPI {
[29] Fix | Delete
[30] Fix | Delete
/* Read a string from an input object. If the last argument
[31] Fix | Delete
is -1, the remainder will be read.
[32] Fix | Delete
*/
[33] Fix | Delete
int(*cread)(PyObject *, char **, Py_ssize_t);
[34] Fix | Delete
[35] Fix | Delete
/* Read a line from an input object. Returns the length of the read
[36] Fix | Delete
line as an int and a pointer inside the object buffer as char** (so
[37] Fix | Delete
the caller doesn't have to provide its own buffer as destination).
[38] Fix | Delete
*/
[39] Fix | Delete
int(*creadline)(PyObject *, char **);
[40] Fix | Delete
[41] Fix | Delete
/* Write a string to an output object*/
[42] Fix | Delete
int(*cwrite)(PyObject *, const char *, Py_ssize_t);
[43] Fix | Delete
[44] Fix | Delete
/* Get the output object as a Python string (returns new reference). */
[45] Fix | Delete
PyObject *(*cgetvalue)(PyObject *);
[46] Fix | Delete
[47] Fix | Delete
/* Create a new output object */
[48] Fix | Delete
PyObject *(*NewOutput)(int);
[49] Fix | Delete
[50] Fix | Delete
/* Create an input object from a Python string
[51] Fix | Delete
(copies the Python string reference).
[52] Fix | Delete
*/
[53] Fix | Delete
PyObject *(*NewInput)(PyObject *);
[54] Fix | Delete
[55] Fix | Delete
/* The Python types for cStringIO input and output objects.
[56] Fix | Delete
Note that you can do input on an output object.
[57] Fix | Delete
*/
[58] Fix | Delete
PyTypeObject *InputType, *OutputType;
[59] Fix | Delete
[60] Fix | Delete
} *PycStringIO;
[61] Fix | Delete
[62] Fix | Delete
/* These can be used to test if you have one */
[63] Fix | Delete
#define PycStringIO_InputCheck(O) \
[64] Fix | Delete
(Py_TYPE(O)==PycStringIO->InputType)
[65] Fix | Delete
#define PycStringIO_OutputCheck(O) \
[66] Fix | Delete
(Py_TYPE(O)==PycStringIO->OutputType)
[67] Fix | Delete
[68] Fix | Delete
#ifdef __cplusplus
[69] Fix | Delete
}
[70] Fix | Delete
#endif
[71] Fix | Delete
#endif /* !Py_CSTRINGIO_H */
[72] Fix | Delete
[73] Fix | Delete
It is recommended that you Edit text format, this type of Fix handles quite a lot in one request
Function