<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/> <title>libkate: Error codes</title> <link href="tabs.css" rel="stylesheet" type="text/css"/> <link href="doxygen.css" rel="stylesheet" type="text/css"/> </head> <body> <!-- Generated by Doxygen 1.6.1 --> <div class="navigation" id="top"> <div class="tabs"> <ul> <li><a href="index.html"><span>Main Page</span></a></li> <li class="current"><a href="pages.html"><span>Related Pages</span></a></li> <li><a href="modules.html"><span>Modules</span></a></li> <li><a href="annotated.html"><span>Data Structures</span></a></li> <li><a href="files.html"><span>Files</span></a></li> <li><a href="examples.html"><span>Examples</span></a></li> </ul> </div> </div> <div class="contents"> <h1><a class="anchor" id="errors">Error codes </a></h1><p>Most of the functions in the libkate API return an integer value so errors can be flagged for the client code to check.</p> <p>When a function succeeds, the return code will usually be 0, or in some cases positive, when extra status information needs to be returned. An error will be marked by returning a negative value. See each function's documentation more information.</p> <p>It is <b>strongly</b> recommended that the client code checks return codes for errors.</p> <p>These are the error codes that the libkate API can return:</p> <ul> <li><code>KATE_E_NOT_FOUND</code> The item that was requested was not found </li> <li><code>KATE_E_INVALID_PARAMETER</code> A parameter passed to the libkate API was invalid. This can be a NULL parameter, a negative granulepos or time, etc </li> <li><code>KATE_E_OUT_OF_MEMORY</code> There was not enough memory to perform the requested operation </li> <li><code>KATE_E_BAD_GRANULE</code> A negative granule was encountered, or a a granule decreased when it should not have </li> <li><code>KATE_E_INIT</code> An object was initialized twice, or not initialized when it should have been </li> <li><code>KATE_E_BAD_PACKET</code> An invalid value was read from a Kate packet. This may mean the stream is corrupted, or is not a Kate stream </li> <li><code>KATE_E_TEXT</code> A text handled by libkate was found to be invalid. This can be an invalid character or sequence of characters in the text, or trying to read and/or write beyond the size of the string. </li> <li><code>KATE_E_LIMIT</code> An limit was exceeded (a string too long, a pixel value above what can fit in a bitmap's bit depth, etc) </li> <li><code>KATE_E_VERSION</code> The bitstream version is not supported by this version of libkate </li> <li><code>KATE_E_NOT_KATE</code> The packet passed the the libkate API is not a Kate packet </li> <li><code>KATE_E_BAD_TAG</code> A tag passed to the comment API does not comply with Vorbis comment rules </li> <li><code>KATE_E_IMPL</code> The requested operation is not implemented </li> </ul> </div> <hr size="1"/><address style="text-align: right;"><small>Generated on Wed Dec 23 04:05:07 2009 for libkate by <a href="http://www.doxygen.org/index.html"> <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.6.1 </small></address> </body> </html>