Error Handling API

SYNOPSIS

# Error API
 
ll_error($errObj,1 | 2 );
 
or 
 
ll_error(1 | 2);

DESCRIPTION

The error handling API takes an error object and prints an error message, the location depends on the parameter

  • 1 - print error message to stdout
  • 2 - print error message to stderr
  • Any other value - no error message printed

The errObj is now being returned in the package global $IBM::LoadLeveler::errObj and not via the return. The reasons for doing this are:

  • It's an error, why would you want more than one ?
  • All you can do with it is pass it to ll_error
  • If you pass an errObj to the API ll_error function it is deleted
  • It makes the code much neater.

Your choices for ll_error are now:

ll_error($IBM::LoadLeveler::errObj,2);
 
 
or
 
ll_error(2)
 
error_handling_api.txt · Last modified: 2007/07/09 11:12 by mike
 
Recent changes RSS feed Creative Commons License Donate Powered by PHP Valid XHTML 1.0 Valid CSS Driven by DokuWiki