PHP PHP bytecode Compiler Functions

EditRocket provides the following information on PHP bytecode Compiler functions in the PHP source code builder.

bool bcompiler_load ( string $filename ) - Reads data from a bzcompressed file and creates classes from the bytecodes.

bool bcompiler_load_exe ( string $filename ) - Reads data from a bcompiler exe file and creates classes from the bytecodes.

bool bcompiler_parse_class ( string $class , string $callback ) - Reads the bytecodes of a class and calls back to a user function.

bool bcompiler_read ( resource $filehandle ) - Reads data from a open file handle and creates classes from the bytecodes.

bool bcompiler_write_class ( resource $filehandle , string $className [, string $extends ] ) - Reads the bytecodes from PHP for an existing class, and writes them to the open file handle.

bool bcompiler_write_constant ( resource $filehandle , string $constantName ) - Reads the bytecodes from PHP for an existing constant, and writes them to the open file handle.

bool bcompiler_write_exe_footer ( resource $filehandle , int $startpos ) - An EXE (or self executable) file consists of 3 parts: The stub (executable code, e.g. a compiled C program) that loads PHP interpreter, bcompiler extension, stored Bytecodes and initiates a call for the specified function (e.g. main) or class method (e.g. main::main). The Bytecodes (uncompressed only for the moment). The bcompiler EXE footer.

bool bcompiler_write_file ( resource $filehandle , string $filename ) - This function complies specified source file into bytecodes, and writes them to the open file handle.

bool bcompiler_write_footer ( resource $filehandle ) - Writes the single character \x00 to indicate End of compiled data.

bool bcompiler_write_function ( resource $filehandle , string $functionName ) - Reads the bytecodes from PHP for an existing function, and writes them to the open file handle. Order is not important, (eg. if function b uses function a, and you compile it like the example below, it will work perfectly OK).

bool bcompiler_write_functions_from_file ( resource $filehandle , string $fileName ) - Searches for all functions declared in the given file, and writes their correspondent bytecodes to the open file handle.

bool bcompiler_write_header ( resource $filehandle [, string $write_ver ] ) - Writes the header part of a bcompiler file.

bool bcompiler_write_included_filename ( resource $filehandle , string $filename ) -