Sophie

Sophie

distrib > Mageia > 7 > i586 > media > core-release > by-pkgid > a2116f36018873d572acbcadddb8e994 > files > 584

clanlib0.8-docs-0.8.1-22.mga7.i586.rpm


<!-- clanlib header begin -->
<HTML>
<HEAD>
<TITLE>CL_DirectoryScanner - ClanLib Game SDK</TITLE>
<STYLE TYPE="text/css"><!--
HTML BODY
{
	font-family: verdana, helvetica, sans-serif;
	font-size: 12px;
}
H1 { font-size: 22px; }
H2 { font-size: 18px; }
H3 { font-size: 16px; }
H4 { font-size: 14px; }
P { font-size: 12px; }
LI { font-size: 12px; }
--></STYLE>
</HEAD>

<body bgcolor=white text=black link=blue vlink=#800080>

<center>
<img src="http://clanlib.org/gfx/clanlib.png">
</center>
<!-- clanlib header end -->

<center>
<p>
<a href="http://clanlib.org/docs.html">Home</a> |
<a href="classes.html">All Classes</a> |
<a href="modules.html">Grouped Classes</a> |
<a href="index.html">Index</a> |
<a href="search.html">Search</a>
</p>
</center>
<h1>Class CL_DirectoryScanner</h1>
<p>  Directory scanning class. <a href="#description">More...</a></p>
<p>Derived from:
<i>none</i>
<br>
Derived by:
<i>none</i>
<br>Group: Core (I/O Data)</p>
<p>
#include &lt;ClanLib/core.h&gt;
<p>
<table border=0 width=100%>
</table>
<p><b>Construction:</b></p>
<table border=0 width=100%>
<tr><td width=30% valign=top><p><a href="CL_DirectoryScanner__CL_DirectoryScanner.html">CL_DirectoryScanner</a></p></td><td valign=top><p>  Constructs directory scanner for iterating over a directory.</p></td></tr></table>
<p><b>Attributes:</b></p>
<table border=0 width=100%>
<tr><td width=30% valign=top><p><a href="CL_DirectoryScanner__get_directory_path.html">get_directory_path</a></p></td><td valign=top><p>  Gets the directory being scanned.</p></td></tr><tr><td width=30% valign=top><p><a href="CL_DirectoryScanner__get_name.html">get_name</a></p></td><td valign=top><p>  Gets the name of the current file.</p></td></tr><tr><td width=30% valign=top><p><a href="CL_DirectoryScanner__get_size.html">get_size</a></p></td><td valign=top><p>  Gets the size of the current file.</p></td></tr><tr><td width=30% valign=top><p><a href="CL_DirectoryScanner__get_pathname.html">get_pathname</a></p></td><td valign=top><p>  Gets the pathname of the current file.</p></td></tr><tr><td width=30% valign=top><p><a href="CL_DirectoryScanner__is_directory.html">is_directory</a></p></td><td valign=top><p>  Returns true if the current file is a directory.</p></td></tr><tr><td width=30% valign=top><p><a href="CL_DirectoryScanner__is_hidden.html">is_hidden</a></p></td><td valign=top><p>  Returns true if the file is hidden.</p></td></tr><tr><td width=30% valign=top><p><a href="CL_DirectoryScanner__is_readable.html">is_readable</a></p></td><td valign=top><p>  Returns true if the file is readable by the current user.</p></td></tr><tr><td width=30% valign=top><p><a href="CL_DirectoryScanner__is_writable.html">is_writable</a></p></td><td valign=top><p>  Returns true if the file is writable by the current user.</p></td></tr></table>
<p><b>Operations:</b></p>
<table border=0 width=100%>
<tr><td width=30% valign=top><p><a href="CL_DirectoryScanner__scan.html">scan</a></p></td><td valign=top><p>  Selects the directory to scan through.</p></td></tr><tr><td width=30% valign=top><p><a href="CL_DirectoryScanner__next.html">next</a></p></td><td valign=top><p>  Find next file in directory scan. </p></td></tr></table>
<a name="#description"><p><b>Detailed description:</b></p>
  !group=Core/IO Data!
  !header=core.h!
  <p>CL_DirectoryScanner is used to parse through directory trees and return information about files.</p>

  <p>Example that prints all files and directories found in the root directory:</p>
  <pre>
  CL_DirectoryScanner scanner;
  if (scanner.scan("/", "*"))
  {
  		while (scanner.next())
  		{
  				std::cout << scanner.get_name() << std::endl;
  		}
  }
  </pre>


<!-- clanlib footer begin -->

<center><br><br><font color="#a0a0a0">
Questions or comments, write to the <a href="http://clanlib.org/contact.html">ClanLib mailing list</a>.
</font></center>

</body>
</html>
<!-- clanlib footer end -->