OpenScop
0.9.0
|
Go to the source code of this file.
Data Structures | |
struct | osl_extbody |
Defines | |
#define | OSL_URI_EXTBODY "extbody" |
Typedefs | |
typedef struct osl_extbody | osl_extbody_t |
typedef struct osl_extbody * | osl_extbody_p |
typedef struct osl_extbody const | osl_const_extbody_t |
typedef struct osl_extbody *const | osl_extbody_const_p |
typedef struct osl_extbody const * | osl_const_extbody_p |
typedef struct osl_extbody const *const | osl_const_extbody_const_p |
Functions | |
void | osl_extbody_idump (FILE *, osl_extbody_p, int) |
void | osl_extbody_dump (FILE *, osl_extbody_p) |
char * | osl_extbody_sprint (osl_extbody_p) |
osl_extbody_p | osl_extbody_sread (char **) |
osl_extbody_p | osl_extbody_malloc () |
void | osl_extbody_free (osl_extbody_p) |
osl_extbody_p | osl_extbody_clone (osl_extbody_p) |
int | osl_extbody_equal (osl_extbody_p, osl_extbody_p) |
osl_interface_p | osl_extbody_interface () |
void | osl_extbody_add (osl_extbody_p, int, int) |
#define OSL_URI_EXTBODY "extbody" |
Definition at line 78 of file extbody.h.
Referenced by osl_extbody_interface(), and osl_statement_get_body().
typedef struct osl_extbody const* const osl_const_extbody_const_p |
typedef struct osl_extbody const* osl_const_extbody_p |
typedef struct osl_extbody const osl_const_extbody_t |
typedef struct osl_extbody* const osl_extbody_const_p |
typedef struct osl_extbody* osl_extbody_p |
typedef struct osl_extbody osl_extbody_t |
void osl_extbody_add | ( | osl_extbody_p | ebody, |
int | start, | ||
int | length | ||
) |
osl_extbody_add function: This function add an entry in the list of coordinates
Definition at line 383 of file extbody.c.
References osl_extbody::length, osl_extbody::nb_access, OSL_realloc, and osl_extbody::start.
osl_extbody_p osl_extbody_clone | ( | osl_extbody_p | ebody | ) |
osl_extbody_clone function: this function builds and returns a "hard copy" (not a pointer copy) of an osl_extbody_t data structure.
[in] | ebody | The pointer to the extbody structure to clone. |
Definition at line 286 of file extbody.c.
References osl_extbody::body, osl_extbody::length, osl_extbody::nb_access, osl_body_clone(), osl_extbody_malloc(), OSL_malloc, and osl_extbody::start.
Referenced by osl_extbody_interface().
void osl_extbody_dump | ( | FILE * | file, |
osl_extbody_p | ebody | ||
) |
osl_extbody_dump function: this function prints the content of an osl_extbody_t structure (*ebody) into a file (file, possibly stdout).
[in] | file | The file where the information has to be printed. |
[in] | ebody | The ebody structure to print. |
Definition at line 137 of file extbody.c.
References osl_extbody_idump().
int osl_extbody_equal | ( | osl_extbody_p | e1, |
osl_extbody_p | e2 | ||
) |
osl_extbody_equal function: this function returns true if the two extbody structures are the same (content-wise), false otherwise. This functions considers two extbody structures as equal if the order of the array start/length differ, however the identifiers, start and length must be the same.
[in] | e1 | The first extbody structure. |
[in] | e2 | The second extbody structure. |
Definition at line 319 of file extbody.c.
References osl_extbody::body, osl_extbody::length, osl_extbody::nb_access, osl_body_equal(), OSL_info, and osl_extbody::start.
Referenced by osl_extbody_interface().
void osl_extbody_free | ( | osl_extbody_p | ebody | ) |
osl_extbody_free function: this function frees the allocated memory for an ebody structure.
[in,out] | ebody | The pointer to the extbody structure we want to free. |
Definition at line 264 of file extbody.c.
References osl_extbody::body, osl_extbody::length, osl_body_free(), and osl_extbody::start.
Referenced by osl_extbody_interface().
void osl_extbody_idump | ( | FILE * | file, |
osl_extbody_p | ebody, | ||
int | level | ||
) |
osl_extbody_idump function: this function displays an osl_extbody_t structure (*extbody) into a file (file, possibly stdout) in a way that trends to be understandable. It includes an indentation level (level) in order to work with others idump functions.
[in] | file | The file where the information has to be printed. |
[in] | ebody | The ebody structure to print. |
[in] | level | Number of spaces before printing, for each line. |
Definition at line 89 of file extbody.c.
References osl_extbody::body, osl_extbody::length, osl_extbody::nb_access, osl_body_idump(), and osl_extbody::start.
Referenced by osl_extbody_dump(), and osl_extbody_interface().
osl_extbody_interface function: this function creates an interface structure corresponding to the extbody extension and returns it.
Definition at line 363 of file extbody.c.
References osl_extbody_clone(), osl_extbody_equal(), osl_extbody_free(), osl_extbody_idump(), osl_extbody_malloc(), osl_extbody_sprint(), osl_extbody_sread(), osl_interface_malloc(), OSL_strdup, and OSL_URI_EXTBODY.
Referenced by osl_interface_get_default_registry().
osl_extbody_malloc function: this function allocates the memory space for an osl_extbody_t structure and sets its fields with default values. Then it returns a pointer to the allocated space.
Definition at line 246 of file extbody.c.
References osl_extbody::body, osl_extbody::length, osl_extbody::nb_access, OSL_malloc, and osl_extbody::start.
Referenced by osl_extbody_clone(), osl_extbody_interface(), and osl_extbody_sread().
char* osl_extbody_sprint | ( | osl_extbody_p | ebody | ) |
osl_extbody_sprint function: this function prints the content of an osl_extbody_t structure (*ebody) into a string (returned) in the OpenScop textual format.
[in] | ebody | The ebody structure to print. |
Definition at line 149 of file extbody.c.
References osl_extbody::body, osl_extbody::length, osl_extbody::nb_access, osl_body_sprint(), OSL_malloc, OSL_MAX_STRING, osl_util_safe_strcat(), and osl_extbody::start.
Referenced by osl_extbody_interface().
osl_extbody_p osl_extbody_sread | ( | char ** | input | ) |
osl_extbody_sread function: this function reads an extbody structure from a string complying to the OpenScop textual format and returns a pointer to this extbody structure. The string should contain only one textual format of an extbody structure. The input parameter is updated to the position in the input string this function reach right after reading the comment structure.
[in,out] | input | The input string where to find an extbody structure. Updated to the position after what has been read. |
Definition at line 201 of file extbody.c.
References osl_extbody::body, osl_extbody::length, osl_extbody::nb_access, osl_body_sread(), OSL_debug, osl_extbody_malloc(), OSL_malloc, osl_util_read_int(), and osl_extbody::start.
Referenced by osl_extbody_interface().