Project

General

Profile

Up

_7zCallback

Call a function for each extracted file, with or without error.
Note : the ObjLZMA object is automatically created, you must NOT use
lzmaCreate.
Warning : the prototype is only __callback__ and __user_parameter__, no lzma object !

Prototype :

fun [fun [ObjLZMA u0 S S I I I] u1 u0] ObjLZMA

  • fun [ObjLZMA u0 S S I I I] u1 : the callback

    • ObjLZMA : usually not applicable
    • u0 : a user parameter, at your convenience
    • S : the name of the archive (by example, "archive.7z")
    • S : the name of the extracted item
    • I : 0 if the current item is a file, 1 if it is a directory
    • I : the size of the extracted item (0 if it is a directory)
    • I : the state : 0 if the current item extraction is a success, otherwise an error code number.

  • u0 : a user parameter, at your convenience

Return : ObjLZMA usually not applicable.

See also

Example

fun cb7z (blurb, user_parameter, archive, item, isdir, size, state)=
	// do something
	0;;

fun main ()=
	_showconsole;
	...
	lzmaCallback @cb7z "CB";
	...