RetroArch
Typedefs | Functions
libretrodb.h File Reference
#include <stdint.h>
#include <unistd.h>
#include <retro_common_api.h>
#include "query.h"
#include "rmsgpack_dom.h"
Include dependency graph for libretrodb.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Typedefs

typedef typedefRETRO_BEGIN_DECLS struct libretrodb libretrodb_t
 
typedef struct libretrodb_cursor libretrodb_cursor_t
 
typedef struct libretrodb_index libretrodb_index_t
 
typedef int(* libretrodb_value_provider) (void *ctx, struct rmsgpack_dom_value *out)
 

Functions

int libretrodb_create (RFILE *fd, libretrodb_value_provider value_provider, void *ctx)
 
void libretrodb_close (libretrodb_t *db)
 
int libretrodb_open (const char *path, libretrodb_t *db)
 
int libretrodb_create_index (libretrodb_t *db, const char *name, const char *field_name)
 
int libretrodb_find_entry (libretrodb_t *db, const char *index_name, const void *key, struct rmsgpack_dom_value *out)
 
libretrodb_tlibretrodb_new (void)
 
void libretrodb_free (libretrodb_t *db)
 
libretrodb_cursor_tlibretrodb_cursor_new (void)
 
void libretrodb_cursor_free (libretrodb_cursor_t *dbc)
 
int libretrodb_cursor_open (libretrodb_t *db, libretrodb_cursor_t *cursor, libretrodb_query_t *query)
 
int libretrodb_cursor_reset (libretrodb_cursor_t *cursor)
 
void libretrodb_cursor_close (libretrodb_cursor_t *cursor)
 
voidlibretrodb_query_compile (libretrodb_t *db, const char *query, size_t buff_len, const char **error)
 
void libretrodb_query_free (void *q)
 
int libretrodb_cursor_read_item (libretrodb_cursor_t *cursor, struct rmsgpack_dom_value *out)
 

Typedef Documentation

◆ libretrodb_cursor_t

◆ libretrodb_index_t

◆ libretrodb_t

typedef typedefRETRO_BEGIN_DECLS struct libretrodb libretrodb_t

◆ libretrodb_value_provider

typedef int(* libretrodb_value_provider) (void *ctx, struct rmsgpack_dom_value *out)

Function Documentation

◆ libretrodb_close()

void libretrodb_close ( libretrodb_t db)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ libretrodb_create()

int libretrodb_create ( RFILE fd,
libretrodb_value_provider  value_provider,
void ctx 
)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ libretrodb_create_index()

int libretrodb_create_index ( libretrodb_t db,
const char *  name,
const char *  field_name 
)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ libretrodb_cursor_close()

void libretrodb_cursor_close ( libretrodb_cursor_t cursor)

libretrodb_cursor_close: : Handle to database cursor.

Closes cursor and frees up allocated memory.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ libretrodb_cursor_free()

void libretrodb_cursor_free ( libretrodb_cursor_t dbc)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ libretrodb_cursor_new()

libretrodb_cursor_t* libretrodb_cursor_new ( void  )
Here is the caller graph for this function:

◆ libretrodb_cursor_open()

int libretrodb_cursor_open ( libretrodb_t db,
libretrodb_cursor_t cursor,
libretrodb_query_t q 
)

libretrodb_cursor_open: : Handle to database. : Handle to database cursor. : Query to execute.

Opens cursor to database based on query .

Returns: 0 if successful, otherwise negative.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ libretrodb_cursor_read_item()

int libretrodb_cursor_read_item ( libretrodb_cursor_t cursor,
struct rmsgpack_dom_value out 
)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ libretrodb_cursor_reset()

int libretrodb_cursor_reset ( libretrodb_cursor_t cursor)

libretrodb_cursor_reset: : Handle to database cursor.

Resets cursor.

Returns: ???.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ libretrodb_find_entry()

int libretrodb_find_entry ( libretrodb_t db,
const char *  index_name,
const void key,
struct rmsgpack_dom_value out 
)
Here is the call graph for this function:

◆ libretrodb_free()

void libretrodb_free ( libretrodb_t db)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ libretrodb_new()

libretrodb_t* libretrodb_new ( void  )
Here is the caller graph for this function:

◆ libretrodb_open()

int libretrodb_open ( const char *  path,
libretrodb_t db 
)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ libretrodb_query_compile()

void* libretrodb_query_compile ( libretrodb_t db,
const char *  query,
size_t  buff_len,
const char **  error 
)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ libretrodb_query_free()

void libretrodb_query_free ( void q)
Here is the call graph for this function:
Here is the caller graph for this function: