Main Page   Compound List   File List   Compound Members   File Members   Related Pages  

poppidb.h File Reference

#include <PalmOS.h>
#include "db.h"
#include "poppi.h"

Include dependency graph for poppidb.h:

Include dependency graph

This graph shows which files directly or indirectly include this file:

Included by dependency graph

Go to the source code of this file.

Compounds

union  unique_id
 A bitfield structure for Poppi record unique IDs. More...


Defines

#define get_record_details(i, n, d)   get_record_details_db(i, n, d, db_p, false)
 Get record details. More...

#define get_key_details(i, t, c)   get_key_details_db(i, t, c, db_p, false)
 Get key details. More...


Functions

Err get_record_details_db (UInt16 index, Char **name, Char **desc, DmOpenRef _db_p, Boolean local)
 Get record details from a specific open db. More...

Err get_key_details_db (UInt16 index, UInt32 **dest, Char ***desc, DmOpenRef _db_p, Boolean local)
 Get key details from a specific open db. More...


Variables

DmOpenRef db_p
 reference to currently open db. More...

UInt16 current_record


Define Documentation

#define get_key_details i,
t,
     get_key_details_db(i, t, c, db_p, false)
 

Get key details.

Uses the global open database reference.

Definition at line 45 of file poppidb.h.

Referenced by key_load().

#define get_record_details i,
n,
     get_record_details_db(i, n, d, db_p, false)
 

Get record details.

Uses the global open database reference.

Definition at line 38 of file poppidb.h.

Referenced by display_init(), and list_draw_item().


Function Documentation

Err get_key_details_db UInt16    index,
UInt32 **    dest,
Char ***    desc,
DmOpenRef    _db_p,
Boolean    local
 

Get key details from a specific open db.

Parameters:
index  Index of the record to get details from.
dest  Pointer to a two-element UInt32 array for the destination UIDs, or NULL.
desc  Pointer to a two-element Char pointer array for the descriptions, or NULL.
_db_p  Reference to an open database
local  true if no global variables should be used
Returns:
errNone if no error; otherwise: a non-zero error value.

Definition at line 109 of file poppidb.c.

References inflate_string_ref().

Err get_record_details_db UInt16    index,
Char **    name,
Char **    desc,
DmOpenRef    _db_p,
Boolean    local
 

Get record details from a specific open db.

Parameters:
index  Index of the record to get details from.
name  Pointer to a Char pointer for the name, or NULL.
desc  Pointer to a Char pointer for the description, or NULL.
_db_p  Reference to an open database
local  true if no global variables should be used
If NULL is passed for the name or desc parameters that parameter will not be retrieved.

Returns:
errNone if no error; otherwise: a non-zero error value.

Definition at line 29 of file poppidb.c.

References inflate_string_ref().

Referenced by find().


Variable Documentation

UInt16 current_record
 

Definition at line 9 of file poppidb.h.

Referenced by init_db().

DmOpenRef db_p
 

reference to currently open db.

Definition at line 8 of file poppidb.h.

Referenced by close_db(), get_list(), get_list_len(), get_list_match(), init_db(), and open_db().