2003-04-07 20:02:06 +00:00
|
|
|
#ifndef __ruamoko_plist_h
|
|
|
|
#define __ruamoko_plist_h
|
|
|
|
|
2004-11-11 22:42:00 +00:00
|
|
|
struct plitem_s {integer [2] dummy;};
|
|
|
|
#define PL_TEST(item) (item.dummy[0] || item.dummy[1])
|
2003-07-30 04:11:45 +00:00
|
|
|
typedef struct plitem_s plitem_t;
|
2004-11-11 22:42:00 +00:00
|
|
|
typedef enum {QFDictionary, QFArray, QFBinary, QFString} pltype_t; // possible types
|
2003-04-07 20:02:06 +00:00
|
|
|
|
2003-04-07 21:15:45 +00:00
|
|
|
@extern plitem_t (string str) PL_GetPropertyList;
|
2004-11-11 22:42:00 +00:00
|
|
|
@extern string (plitem_t pl) PL_WritePropertyList;
|
|
|
|
@extern pltype_t (plitem_t str) PL_Type;
|
|
|
|
@extern string (plitem_t str) PL_String;
|
2003-04-07 21:15:45 +00:00
|
|
|
@extern plitem_t (plitem_t item, string key) PL_ObjectForKey;
|
|
|
|
@extern plitem_t (plitem_t item, integer index) PL_ObjectAtIndex;
|
2004-11-11 22:42:00 +00:00
|
|
|
@extern plitem_t (plitem_t item) PL_D_AllKeys;
|
|
|
|
@extern integer (plitem_t item) PL_D_NumKeys;
|
2006-12-09 06:00:36 +00:00
|
|
|
@extern integer (plitem_t dict, string key, plitem_t value) PL_D_AddObject;
|
2004-01-07 06:19:11 +00:00
|
|
|
@extern integer (plitem_t array_item, plitem_t item) PL_A_AddObject;
|
2004-11-11 22:42:00 +00:00
|
|
|
@extern integer (plitem_t item) PL_A_NumObjects;
|
2004-01-07 06:19:11 +00:00
|
|
|
@extern integer (plitem_t array_item, plitem_t item, integer index) PL_A_InsertObjectAtIndex;
|
2003-04-07 21:15:45 +00:00
|
|
|
@extern plitem_t () PL_NewDictionary;
|
|
|
|
@extern plitem_t () PL_NewArray;
|
2004-11-11 22:42:00 +00:00
|
|
|
@extern plitem_t (void []data, integer len) PL_NewData;
|
2003-04-07 21:15:45 +00:00
|
|
|
@extern plitem_t (string str) PL_NewString;
|
2004-11-11 22:42:00 +00:00
|
|
|
@extern void (plitem_t pl) PL_Free;
|
2003-04-07 20:02:06 +00:00
|
|
|
|
|
|
|
#endif//__ruamoko_plist_h
|