Back to index

lightning-sunbird  0.9+nobinonly
xpt_struct.h
Go to the documentation of this file.
00001 /* -*- Mode: C; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
00002 /* ***** BEGIN LICENSE BLOCK *****
00003  * Version: MPL 1.1/GPL 2.0/LGPL 2.1
00004  *
00005  * The contents of this file are subject to the Mozilla Public License Version
00006  * 1.1 (the "License"); you may not use this file except in compliance with
00007  * the License. You may obtain a copy of the License at
00008  * http://www.mozilla.org/MPL/
00009  *
00010  * Software distributed under the License is distributed on an "AS IS" basis,
00011  * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
00012  * for the specific language governing rights and limitations under the
00013  * License.
00014  *
00015  * The Original Code is mozilla.org code.
00016  *
00017  * The Initial Developer of the Original Code is
00018  * Netscape Communications Corporation.
00019  * Portions created by the Initial Developer are Copyright (C) 1998
00020  * the Initial Developer. All Rights Reserved.
00021  *
00022  * Contributor(s):
00023  *
00024  * Alternatively, the contents of this file may be used under the terms of
00025  * either of the GNU General Public License Version 2 or later (the "GPL"),
00026  * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
00027  * in which case the provisions of the GPL or the LGPL are applicable instead
00028  * of those above. If you wish to allow use of your version of this file only
00029  * under the terms of either the GPL or the LGPL, and not to allow others to
00030  * use your version of this file under the terms of the MPL, indicate your
00031  * decision by deleting the provisions above and replace them with the notice
00032  * and other provisions required by the GPL or the LGPL. If you do not delete
00033  * the provisions above, a recipient may use your version of this file under
00034  * the terms of any one of the MPL, the GPL or the LGPL.
00035  *
00036  * ***** END LICENSE BLOCK ***** */
00037 
00038 /*
00039  * Structures matching the in-memory representation of typelib structures.
00040  * http://www.mozilla.org/scriptable/typelib_file.html
00041  */
00042 
00043 #ifndef __xpt_struct_h__
00044 #define __xpt_struct_h__
00045 
00046 #include "xpt_arena.h"
00047 
00048 PR_BEGIN_EXTERN_C
00049 
00050 /*
00051  * Originally, I was going to have structures that exactly matched the on-disk
00052  * representation, but that proved difficult: different compilers can pack
00053  * their structs differently, and that makes overlaying them atop a
00054  * read-from-disk byte buffer troublesome.  So now I just have some structures
00055  * that are used in memory, and we're going to write a nice XDR library to
00056  * write them to disk and stuff.  It is pure joy. -- shaver
00057  */
00058 
00059 /* Structures for the typelib components */
00060 
00061 typedef struct XPTHeader XPTHeader;
00062 typedef struct XPTInterfaceDirectoryEntry XPTInterfaceDirectoryEntry;
00063 typedef struct XPTInterfaceDescriptor XPTInterfaceDescriptor;
00064 typedef struct XPTConstDescriptor XPTConstDescriptor;
00065 typedef struct XPTMethodDescriptor XPTMethodDescriptor;
00066 typedef struct XPTParamDescriptor XPTParamDescriptor;
00067 typedef struct XPTTypeDescriptor XPTTypeDescriptor;
00068 typedef struct XPTTypeDescriptorPrefix XPTTypeDescriptorPrefix;
00069 typedef struct XPTString XPTString;
00070 typedef struct XPTAnnotation XPTAnnotation;
00071 #ifndef nsID_h__
00072 /*
00073  * We can't include nsID.h, because it's full of C++ goop and we're not doing
00074  * C++ here, so we define our own minimal struct.  We protect against multiple
00075  * definitions of this struct, though, and use the same field naming.
00076  */
00077 struct nsID {
00078     PRUint32 m0;
00079     PRUint16 m1;
00080     PRUint16 m2;
00081     PRUint8  m3[8];
00082 };
00083 
00084 typedef struct nsID nsID;
00085 #endif
00086 
00087 #define XPT_COPY_IID(to, from)                                                \
00088   (to).m0 = (from).m0;                                                        \
00089   (to).m1 = (from).m1;                                                        \
00090   (to).m2 = (from).m2;                                                        \
00091   (to).m3[0] = (from).m3[0];                                                  \
00092   (to).m3[1] = (from).m3[1];                                                  \
00093   (to).m3[2] = (from).m3[2];                                                  \
00094   (to).m3[3] = (from).m3[3];                                                  \
00095   (to).m3[4] = (from).m3[4];                                                  \
00096   (to).m3[5] = (from).m3[5];                                                  \
00097   (to).m3[6] = (from).m3[6];                                                  \
00098   (to).m3[7] = (from).m3[7];
00099 
00100 
00101 /*
00102  * Every XPCOM typelib file begins with a header.
00103  */
00104 struct XPTHeader {
00105     PRUint8                     magic[16];
00106     PRUint8                     major_version;
00107     PRUint8                     minor_version;
00108     PRUint16                    num_interfaces;
00109     PRUint32                    file_length;
00110     XPTInterfaceDirectoryEntry  *interface_directory;
00111     PRUint32                    data_pool;
00112     XPTAnnotation               *annotations;
00113 };
00114 
00115 #define XPT_MAGIC "XPCOM\nTypeLib\r\n\032"
00116 /* For error messages. */
00117 #define XPT_MAGIC_STRING "XPCOM\\nTypeLib\\r\\n\\032"
00118 #define XPT_MAJOR_VERSION 0x01
00119 #define XPT_MINOR_VERSION 0x02
00120 
00121 /* Any file with a major version number of XPT_MAJOR_INCOMPATIBLE_VERSION 
00122  * or higher is to be considered incompatible by this version of xpt and
00123  * we will refuse to read it. We will return a header with magic, major and
00124  * minor versions set from the file. num_interfaces and file_length will be
00125  * set to zero to confirm our inability to read the file; i.e. even if some
00126  * client of this library gets out of sync with us regarding the agreed upon
00127  * value for XPT_MAJOR_INCOMPATIBLE_VERSION, anytime num_interfaces and
00128  * file_length are both zero we *know* that this library refused to read the 
00129  * file due to version imcompatibility.  
00130  */
00131 #define XPT_MAJOR_INCOMPATIBLE_VERSION 0x02
00132 
00133 /*
00134  * The "[-t version number]" cmd line parameter to the XPIDL compiler and XPT
00135  * linker specifies the major and minor version number of the output 
00136  * type library.
00137  * 
00138  * The goal is for the compiler to check that the input IDL file only uses 
00139  * constructs that are supported in the version specified. The linker will
00140  * check that all typelib files it reads are of the version specified or
00141  * below.
00142  * 
00143  * Both the compiler and the linker will report errors and abort if these
00144  * checks fail.
00145  * 
00146  * When you rev up major or minor versions of the type library in the future,
00147  * think about the new stuff that you added to the type library and add checks
00148  * to make sure that occurrences of that new "stuff" will get caught when [-t
00149  * version number] is used with the compiler. Here's what you'll probably
00150  * have to do each time you rev up major/minor versions:
00151  * 
00152  *   1) Add the current version number string (before your change) to the
00153  *   XPT_TYPELIB_VERSIONS list.
00154  * 
00155  *   2) Do your changes add new features to XPIDL? Ensure that those new
00156  *   features are rejected by the XPIDL compiler when any version number in
00157  *   the XPT_TYPELIB_VERSIONS list is specified on the command line. The
00158  *   one place that currently does this kind of error checking is the function
00159  *   verify_type_fits_version() in xpidl_util.c. It currently checks
00160  *   attribute types, parameter types, and return types. You'll probably have
00161  *   to add to it or generalize it further based on what kind of changes you
00162  *   are making.
00163  *
00164  *   3) You will probably NOT need to make any changes to the error checking
00165  *   in the linker.
00166  */
00167   
00168 #define XPT_VERSION_UNKNOWN     0
00169 #define XPT_VERSION_UNSUPPORTED 1
00170 #define XPT_VERSION_OLD         2
00171 #define XPT_VERSION_CURRENT     3
00172 
00173 typedef struct {
00174     const char* str;
00175     PRUint8     major;
00176     PRUint8     minor;
00177     PRUint16    code;
00178 } XPT_TYPELIB_VERSIONS_STRUCT; 
00179 
00180 /* Currently accepted list of versions for typelibs */
00181 #define XPT_TYPELIB_VERSIONS {                                                \
00182     {"1.0", 1, 0, XPT_VERSION_UNSUPPORTED},                                   \
00183     {"1.1", 1, 1, XPT_VERSION_OLD},                                           \
00184     {"1.2", 1, 2, XPT_VERSION_CURRENT}                                        \
00185 }
00186 
00187 extern XPT_PUBLIC_API(PRUint16)
00188 XPT_ParseVersionString(const char* str, PRUint8* major, PRUint8* minor);
00189 
00190 extern XPT_PUBLIC_API(XPTHeader *)
00191 XPT_NewHeader(XPTArena *arena, PRUint16 num_interfaces, 
00192               PRUint8 major_version, PRUint8 minor_version);
00193 
00194 extern XPT_PUBLIC_API(void)
00195 XPT_FreeHeader(XPTArena *arena, XPTHeader* aHeader);
00196 
00197 /* size of header and annotations */
00198 extern XPT_PUBLIC_API(PRUint32)
00199 XPT_SizeOfHeader(XPTHeader *header);
00200 
00201 /* size of header and annotations and InterfaceDirectoryEntries */
00202 extern XPT_PUBLIC_API(PRUint32)
00203 XPT_SizeOfHeaderBlock(XPTHeader *header);
00204 
00205 /*
00206  * A contiguous array of fixed-size InterfaceDirectoryEntry records begins at 
00207  * the byte offset identified by the interface_directory field in the file 
00208  * header.  The array is used to quickly locate an interface description 
00209  * using its IID.  No interface should appear more than once in the array.
00210  */
00211 struct XPTInterfaceDirectoryEntry {
00212     nsID                   iid;
00213     char                   *name;
00214     char                   *name_space;
00215     XPTInterfaceDescriptor *interface_descriptor;
00216 
00217 #if 0 /* not yet */
00218     /* not stored on disk */
00219     PRUint32                 offset; /* the offset for an ID still to be read */
00220 #endif
00221 };
00222 
00223 extern XPT_PUBLIC_API(PRBool)
00224 XPT_FillInterfaceDirectoryEntry(XPTArena *arena, 
00225                                 XPTInterfaceDirectoryEntry *ide,
00226                                 nsID *iid, char *name, char *name_space,
00227                                 XPTInterfaceDescriptor *descriptor);
00228 
00229 extern XPT_PUBLIC_API(void)
00230 XPT_DestroyInterfaceDirectoryEntry(XPTArena *arena, 
00231                                    XPTInterfaceDirectoryEntry* ide);
00232 
00233 /*
00234  * An InterfaceDescriptor is a variable-size record used to describe a 
00235  * single XPCOM interface, including all of its methods. 
00236  */
00237 struct XPTInterfaceDescriptor {
00238     PRUint16                parent_interface;
00239     PRUint16                num_methods;
00240     XPTMethodDescriptor     *method_descriptors;
00241     PRUint16                num_constants;
00242     XPTConstDescriptor      *const_descriptors;
00243     PRUint8                 flags;
00244 
00245     /* additional_types are used for arrays where we may need multiple
00246     *  XPTTypeDescriptors for a single XPTMethodDescriptor. Since we still
00247     *  want to have a simple array of XPTMethodDescriptor (each with a single
00248     *  embedded XPTTypeDescriptor), a XPTTypeDescriptor can have a reference
00249     *  to an 'additional_type'. That reference is an index in this 
00250     *  "additional_types" array. So a given XPTMethodDescriptor might have 
00251     *  a whole chain of these XPTTypeDescriptors to represent, say, a multi
00252     *  dimensional array.
00253     *
00254     *  Note that in the typelib file these additional types are stored 'inline'
00255     *  in the MethodDescriptor. But, in the typelib MethodDescriptors can be 
00256     *  of varying sizes, where in XPT's in memory mapping of the data we want 
00257     *  them to be of fixed size. This additional_types scheme is here to allow 
00258     *  for that.
00259     */
00260 
00261     XPTTypeDescriptor       *additional_types;
00262     PRUint16                num_additional_types;
00263 };
00264 
00265 #define XPT_ID_SCRIPTABLE           0x80
00266 #define XPT_ID_FUNCTION             0x40
00267 #define XPT_ID_FLAGMASK             0xc0
00268 #define XPT_ID_TAGMASK              (~XPT_ID_FLAGMASK)
00269 #define XPT_ID_TAG(id)              ((id).flags & XPT_ID_TAGMASK)
00270 
00271 #define XPT_ID_IS_SCRIPTABLE(flags) (flags & XPT_ID_SCRIPTABLE)
00272 #define XPT_ID_IS_FUNCTION(flags) (flags & XPT_ID_FUNCTION)
00273 
00274 extern XPT_PUBLIC_API(PRBool)
00275 XPT_GetInterfaceIndexByName(XPTInterfaceDirectoryEntry *ide_block,
00276                             PRUint16 num_interfaces, char *name, 
00277                             PRUint16 *indexp);
00278 
00279 extern XPT_PUBLIC_API(XPTInterfaceDescriptor *)
00280 XPT_NewInterfaceDescriptor(XPTArena *arena, 
00281                            PRUint16 parent_interface, PRUint16 num_methods,
00282                            PRUint16 num_constants, PRUint8 flags);
00283 
00284 extern XPT_PUBLIC_API(void)
00285 XPT_FreeInterfaceDescriptor(XPTArena *arena, XPTInterfaceDescriptor* id);
00286 
00287 extern XPT_PUBLIC_API(PRBool)
00288 XPT_InterfaceDescriptorAddTypes(XPTArena *arena, XPTInterfaceDescriptor *id, 
00289                                 PRUint16 num);
00290 
00291 extern XPT_PUBLIC_API(PRBool)
00292 XPT_InterfaceDescriptorAddMethods(XPTArena *arena, XPTInterfaceDescriptor *id, 
00293                                   PRUint16 num);
00294 
00295 extern XPT_PUBLIC_API(PRBool)
00296 XPT_InterfaceDescriptorAddConsts(XPTArena *arena, XPTInterfaceDescriptor *id, 
00297                                  PRUint16 num);
00298 
00299 /*
00300  * This is our special string struct with a length value associated with it,
00301  * which means that it can contains embedded NULs.
00302  */
00303 struct XPTString {
00304     PRUint16 length;
00305     char   *bytes;
00306 };
00307 
00308 extern XPT_PUBLIC_API(XPTString *)
00309 XPT_NewString(XPTArena *arena, PRUint16 length, char *bytes);
00310 
00311 extern XPT_PUBLIC_API(XPTString *)
00312 XPT_NewStringZ(XPTArena *arena, char *bytes);
00313 
00314 /* 
00315  * A TypeDescriptor is a variable-size record used to identify the type of a 
00316  * method argument or return value. 
00317  *
00318  * There are three types of TypeDescriptors:
00319  *
00320  * SimpleTypeDescriptor
00321  * InterfaceTypeDescriptor
00322  * InterfaceIsTypeDescriptor
00323  *
00324  * The tag field in the prefix indicates which of the variant TypeDescriptor 
00325  * records is being used, and hence the way any remaining fields should be 
00326  * parsed. Values from 0 to 17 refer to SimpleTypeDescriptors. The value 18 
00327  * designates an InterfaceTypeDescriptor, while 19 represents an 
00328  * InterfaceIsTypeDescriptor.
00329  */
00330 
00331 /* why bother with a struct?  - other code relies on this being a struct */
00332 struct XPTTypeDescriptorPrefix {
00333     PRUint8 flags;
00334 };
00335 
00336 /* flag bits -- fur and jband were right, I was miserably wrong */
00337 #define XPT_TDP_POINTER          0x80
00338 #define XPT_TDP_UNIQUE_POINTER   0x40
00339 #define XPT_TDP_REFERENCE        0x20
00340 #define XPT_TDP_FLAGMASK         0xe0
00341 #define XPT_TDP_TAGMASK          (~XPT_TDP_FLAGMASK)
00342 #define XPT_TDP_TAG(tdp)         ((tdp).flags & XPT_TDP_TAGMASK)
00343 
00344 #define XPT_TDP_IS_POINTER(flags)        (flags & XPT_TDP_POINTER)
00345 #define XPT_TDP_IS_UNIQUE_POINTER(flags) (flags & XPT_TDP_UNIQUE_POINTER)
00346 #define XPT_TDP_IS_REFERENCE(flags)      (flags & XPT_TDP_REFERENCE)
00347 
00348 /* 
00349  * The following enum maps mnemonic names to the different numeric values 
00350  * of XPTTypeDescriptor->tag.
00351  */
00352 enum XPTTypeDescriptorTags {
00353     TD_INT8              = 0,
00354     TD_INT16             = 1,
00355     TD_INT32             = 2,
00356     TD_INT64             = 3,
00357     TD_UINT8             = 4,
00358     TD_UINT16            = 5,
00359     TD_UINT32            = 6,
00360     TD_UINT64            = 7,
00361     TD_FLOAT             = 8, 
00362     TD_DOUBLE            = 9,
00363     TD_BOOL              = 10,  
00364     TD_CHAR              = 11,  
00365     TD_WCHAR             = 12, 
00366     TD_VOID              = 13,  
00367     TD_PNSIID            = 14,
00368     TD_DOMSTRING         = 15,
00369     TD_PSTRING           = 16,
00370     TD_PWSTRING          = 17,
00371     TD_INTERFACE_TYPE    = 18,
00372     TD_INTERFACE_IS_TYPE = 19,
00373     TD_ARRAY             = 20,
00374     TD_PSTRING_SIZE_IS   = 21,
00375     TD_PWSTRING_SIZE_IS  = 22,
00376     TD_UTF8STRING        = 23,
00377     TD_CSTRING           = 24,
00378     TD_ASTRING           = 25
00379 };
00380 
00381 struct XPTTypeDescriptor {
00382     XPTTypeDescriptorPrefix prefix;
00383     PRUint8 argnum;                 /* used for iid_is and size_is */
00384     PRUint8 argnum2;                /* used for length_is */
00385     union {                         
00386         PRUint16 iface;             /* used for TD_INTERFACE_TYPE */
00387         PRUint16 additional_type;   /* used for TD_ARRAY */
00388     } type;
00389 };
00390 
00391 #define XPT_COPY_TYPE(to, from)                                               \
00392   (to).prefix.flags = (from).prefix.flags;                                    \
00393   (to).argnum = (from).argnum;                                                \
00394   (to).argnum2 = (from).argnum2;                                              \
00395   (to).type.additional_type = (from).type.additional_type;
00396 
00397 /*
00398  * A ConstDescriptor is a variable-size record that records the name and 
00399  * value of a scoped interface constant. 
00400  *
00401  * The types of the method parameter are restricted to the following subset 
00402  * of TypeDescriptors: 
00403  *
00404  * int8, uint8, int16, uint16, int32, uint32, 
00405  * int64, uint64, wchar_t, char, string
00406  * 
00407  * The type (and thus the size) of the value record is determined by the 
00408  * contents of the associated TypeDescriptor record. For instance, if type 
00409  * corresponds to int16, then value is a two-byte record consisting of a 
00410  * 16-bit signed integer.  For a ConstDescriptor type of string, the value 
00411  * record is of type String*, i.e. an offset within the data pool to a 
00412  * String record containing the constant string.
00413  */
00414 union XPTConstValue {
00415     PRInt8    i8;
00416     PRUint8   ui8; 
00417     PRInt16   i16; 
00418     PRUint16  ui16;
00419     PRInt32   i32; 
00420     PRUint32  ui32;
00421     PRInt64   i64; 
00422     PRUint64  ui64; 
00423     float     flt;
00424     double    dbl;
00425     PRBool    bul;
00426     char      ch; 
00427     PRUint16  wch;
00428     nsID      *iid;
00429     XPTString *string;
00430     char      *str;
00431     PRUint16  *wstr;
00432 }; /* varies according to type */
00433 
00434 struct XPTConstDescriptor {
00435     char                *name;
00436     XPTTypeDescriptor   type;
00437     union XPTConstValue value;
00438 };
00439 
00440 /*
00441  * A ParamDescriptor is a variable-size record used to describe either a 
00442  * single argument to a method or a method's result.
00443  */
00444 struct XPTParamDescriptor {
00445     PRUint8           flags;
00446     XPTTypeDescriptor type;
00447 };
00448 
00449 /* flag bits -- jband and fur were right, and I was miserably wrong */
00450 #define XPT_PD_IN       0x80
00451 #define XPT_PD_OUT      0x40
00452 #define XPT_PD_RETVAL   0x20
00453 #define XPT_PD_SHARED   0x10
00454 #define XPT_PD_DIPPER   0x08
00455 #define XPT_PD_FLAGMASK 0xf8
00456 
00457 #define XPT_PD_IS_IN(flags)     (flags & XPT_PD_IN)
00458 #define XPT_PD_IS_OUT(flags)    (flags & XPT_PD_OUT)
00459 #define XPT_PD_IS_RETVAL(flags) (flags & XPT_PD_RETVAL)
00460 #define XPT_PD_IS_SHARED(flags) (flags & XPT_PD_SHARED)
00461 #define XPT_PD_IS_DIPPER(flags) (flags & XPT_PD_DIPPER)
00462 
00463 extern XPT_PUBLIC_API(PRBool)
00464 XPT_FillParamDescriptor(XPTArena *arena, 
00465                         XPTParamDescriptor *pd, PRUint8 flags,
00466                         XPTTypeDescriptor *type);
00467 
00468 /*
00469  * A MethodDescriptor is a variable-size record used to describe a single 
00470  * interface method.
00471  */
00472 struct XPTMethodDescriptor {
00473     char                *name;
00474     XPTParamDescriptor  *params;
00475     XPTParamDescriptor  *result;
00476     PRUint8             flags;
00477     PRUint8             num_args;
00478 };
00479 
00480 /* flag bits -- jband and fur were right, and I was miserably wrong */
00481 #define XPT_MD_GETTER   0x80
00482 #define XPT_MD_SETTER   0x40
00483 #define XPT_MD_NOTXPCOM 0x20
00484 #define XPT_MD_CTOR     0x10
00485 #define XPT_MD_HIDDEN   0x08
00486 #define XPT_MD_FLAGMASK 0xf8
00487 
00488 #define XPT_MD_IS_GETTER(flags)     (flags & XPT_MD_GETTER)
00489 #define XPT_MD_IS_SETTER(flags)     (flags & XPT_MD_SETTER)
00490 #define XPT_MD_IS_NOTXPCOM(flags)   (flags & XPT_MD_NOTXPCOM)
00491 #define XPT_MD_IS_CTOR(flags)       (flags & XPT_MD_CTOR)
00492 #define XPT_MD_IS_HIDDEN(flags)     (flags & XPT_MD_HIDDEN)
00493 
00494 extern XPT_PUBLIC_API(PRBool)
00495 XPT_FillMethodDescriptor(XPTArena *arena, 
00496                          XPTMethodDescriptor *meth, PRUint8 flags, char *name,
00497                          PRUint8 num_args);
00498 
00499 /*
00500  * Annotation records are variable-size records used to store secondary 
00501  * information about the typelib, e.g. such as the name of the tool that 
00502  * generated the typelib file, the date it was generated, etc.  The 
00503  * information is stored with very loose format requirements so as to 
00504  * allow virtually any private data to be stored in the typelib.
00505  *
00506  * There are two types of Annotations:
00507  *
00508  * EmptyAnnotation
00509  * PrivateAnnotation
00510  *
00511  * The tag field of the prefix discriminates among the variant record 
00512  * types for Annotation's.  If the tag is 0, this record is an 
00513  * EmptyAnnotation. EmptyAnnotation's are ignored - they're only used to 
00514  * indicate an array of Annotation's that's completely empty.  If the tag 
00515  * is 1, the record is a PrivateAnnotation. 
00516  */
00517 
00518 struct XPTAnnotation {
00519     XPTAnnotation *next;
00520     PRUint8       flags;
00521     /* remaining fields are present in typelib iff XPT_ANN_IS_PRIVATE */
00522     XPTString     *creator;
00523     XPTString     *private_data;
00524 };
00525 
00526 #define XPT_ANN_LAST                 0x80
00527 #define XPT_ANN_IS_LAST(flags)          (flags & XPT_ANN_LAST)
00528 #define XPT_ANN_PRIVATE                 0x40
00529 #define XPT_ANN_IS_PRIVATE(flags)       (flags & XPT_ANN_PRIVATE)
00530 
00531 extern XPT_PUBLIC_API(XPTAnnotation *)
00532 XPT_NewAnnotation(XPTArena *arena, PRUint8 flags, XPTString *creator, 
00533                   XPTString *private_data);
00534 
00535 PR_END_EXTERN_C
00536 
00537 #endif /* __xpt_struct_h__ */