axl main logo
 All Data Structures Functions Variables Typedefs Enumerations Enumerator Modules Pages
axl_bool axl_stack_foreach ( axlStack stack,
axlStackForeach2  func,
axlPointer  user_data,
axlPointer  user_data2 

Allows to perform a foreach operation from the head of the stack (the next item to be poped) to the tail of the stack (the very first item pushed).

The foreach process is non intrusive: it doesn't perform any change of the stack, but allows to traverse all items in the natural order in which items are stored (push) and removed (pop).

The function provided to perform the foreach operation will be called providing the stack data found, and the two user defined pointers provided.

stackThe stack where the foreach operation will be performed.
funcThe foreach function to be called for each item found in the stack.
user_dataUser defined pointer to be passed to the function provided.
user_data2User defined pointer to be passed to the function provided.
axl_true if the foreach process was performed completely through all items inside the stack or axl_false if not. The function will also return axl_false to indicate a failure the stack and func parameters are null.