/* +----------------------------------------------------------------------+ | unknown license: | +----------------------------------------------------------------------+ +----------------------------------------------------------------------+ */ /* $ Id: $ */ #include "php_uuid.h" #include "uuid/uuid.h" #if HAVE_UUID /* {{{ uuid_functions[] */ function_entry uuid_functions[] = { PHP_FE(uuid , NULL) { NULL, NULL, NULL } }; /* }}} */ /* {{{ uuid_module_entry */ zend_module_entry uuid_module_entry = { STANDARD_MODULE_HEADER, "uuid", uuid_functions, PHP_MINIT(uuid), /* Replace with NULL if there is nothing to do at php startup */ PHP_MSHUTDOWN(uuid), /* Replace with NULL if there is nothing to do at php shutdown */ PHP_RINIT(uuid), /* Replace with NULL if there is nothing to do at request start */ PHP_RSHUTDOWN(uuid), /* Replace with NULL if there is nothing to do at request end */ PHP_MINFO(uuid), "0.0.1", STANDARD_MODULE_PROPERTIES }; /* }}} */ #ifdef COMPILE_DL_UUID ZEND_GET_MODULE(uuid) #endif /* {{{ PHP_MINIT_FUNCTION */ PHP_MINIT_FUNCTION(uuid) { /* add your stuff here */ return SUCCESS; } /* }}} */ /* {{{ PHP_MSHUTDOWN_FUNCTION */ PHP_MSHUTDOWN_FUNCTION(uuid) { /* add your stuff here */ return SUCCESS; } /* }}} */ /* {{{ PHP_RINIT_FUNCTION */ PHP_RINIT_FUNCTION(uuid) { /* add your stuff here */ return SUCCESS; } /* }}} */ /* {{{ PHP_RSHUTDOWN_FUNCTION */ PHP_RSHUTDOWN_FUNCTION(uuid) { /* add your stuff here */ return SUCCESS; } /* }}} */ /* {{{ PHP_MINFO_FUNCTION */ PHP_MINFO_FUNCTION(uuid) { php_info_print_box_start(0); php_printf("

The unknown extension

\n"); php_printf("

Version 0.0.1devel (2007-03-30)

\n"); php_info_print_box_end(); /* add your stuff here */ } /* }}} */ /* {{{ proto string uuid() */ PHP_FUNCTION(uuid) { if (ZEND_NUM_ARGS()>0) { WRONG_PARAM_COUNT; } uuid_t uu; char str[37]; uuid_generate(uu); uuid_unparse(uu, str); RETURN_STRING(str, 1); } /* }}} uuid */ #endif /* HAVE_UUID */ /* * Local variables: * tab-width: 4 * c-basic-offset: 4 * End: * vim600: noet sw=4 ts=4 fdm=marker * vim<600: noet sw=4 ts=4 */