538
C-Level Extensibility
unsigned short *(*valueToString)(JSContext *cx, jsval v, unsigned int
*pLength);
unsigned char *(*valueToBytes)(JSContext *cx, jsval v, unsigned int
*pLength);
JSBool (*valueToInteger)(JSContext *cx, jsval v, long *lp);
JSBool (*valueToDouble)(JSContext *cx, jsval v, double *dp);
JSBool (*valueToBoolean)(JSContext *cx, jsval v, JSBool *bp);
JSBool (*valueToObject)(JSContext *cx, jsval v, JSObject **op);
JSBool (*stringToValue)(JSContext *cx, unsigned short *b, unsigned int
sz, jsval *vp);
JSBool (*bytesToValue)(JSContext *cx, unsigned char *b, unsigned int sz,
jsval *vp);
JSBool (*doubleToValue)(JSContext *cx, double dv, jsval *vp);
unsigned short *(*objectType)(JSObject *obj);
JSObject *(*newArrayObject)(JSContext *cx, unsigned int length, jsval
*vp);
long (*getArrayLength)(JSContext *cx, JSObject *obj);
JSBool (*getElement)(JSContext *cx, JSObject *obj, unsigned int idx,
jsval *vp);
JSBool (*setElement)(JSContext *cx, JSObject *obj, unsigned int idx,
jsval *vp);
JSBool (*executeScript)(JSContext *cx, JSObject *obj, unsigned short
*script,
unsigned int sz, unsigned short *file, unsigned int lineNum, jsval
*rval);
JSBool (*reportError)(JSContext *cx, unsigned short *error, unsigned int
sz);
} MM_Environment;
extern MM_Environment mmEnv;
// Declare the external entry point and linkage.
#ifdef _WIN32
# ifndef _MAC
// Windows
__declspec( dllexport ) void MM_InitWrapper( MM_Environment *env, unsigned
int envSize );
# else
// Mac with MSVC++ Win32 portability lib
extern void MM_InitWrapper( MM_Environment *env, unsigned int envSize );
# endif
#else
// Codewarrior
# pragma export on
extern void MM_InitWrapper( MM_Environment *env, unsigned int envSize );
# pragma export off
#endif
#define MM_STATE \
Содержание FLASH 8-EXTENDING FLASH
Страница 1: ...Extending Flash...
Страница 38: ...38 Top Level Functions and Methods...
Страница 532: ...532 Objects...
Страница 554: ...554 C Level Extensibility...