<?xml version="1.0"?>
<?xml-stylesheet type="text/css" href="http://www.programmingexamples.net/w/skins/common/feed.css?303"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
		<id>http://www.programmingexamples.net/w/index.php?action=history&amp;feed=atom&amp;title=Qt%2FFileInfo</id>
		<title>Qt/FileInfo - Revision history</title>
		<link rel="self" type="application/atom+xml" href="http://www.programmingexamples.net/w/index.php?action=history&amp;feed=atom&amp;title=Qt%2FFileInfo"/>
		<link rel="alternate" type="text/html" href="http://www.programmingexamples.net/w/index.php?title=Qt/FileInfo&amp;action=history"/>
		<updated>2026-04-30T15:54:14Z</updated>
		<subtitle>Revision history for this page on the wiki</subtitle>
		<generator>MediaWiki 1.23.5</generator>

	<entry>
		<id>http://www.programmingexamples.net/w/index.php?title=Qt/FileInfo&amp;diff=1012&amp;oldid=prev</id>
		<title>Daviddoria at 20:43, 13 February 2011</title>
		<link rel="alternate" type="text/html" href="http://www.programmingexamples.net/w/index.php?title=Qt/FileInfo&amp;diff=1012&amp;oldid=prev"/>
				<updated>2011-02-13T20:43:21Z</updated>
		
		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;table class='diff diff-contentalign-left'&gt;
				&lt;col class='diff-marker' /&gt;
				&lt;col class='diff-content' /&gt;
				&lt;col class='diff-marker' /&gt;
				&lt;col class='diff-content' /&gt;
				&lt;tr style='vertical-align: top;'&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;Revision as of 20:43, 13 February 2011&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 13:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 13:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#160;&amp;#160; &amp;#160; std::cout &amp;lt;&amp;lt; &amp;quot;fileName: &amp;quot; &amp;lt;&amp;lt; myFile.fileName().toStdString() &amp;lt;&amp;lt; std::endl;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#160;&amp;#160; &amp;#160; std::cout &amp;lt;&amp;lt; &amp;quot;fileName: &amp;quot; &amp;lt;&amp;lt; myFile.fileName().toStdString() &amp;lt;&amp;lt; std::endl;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#160;&amp;#160; &amp;#160; std::cout &amp;lt;&amp;lt; &amp;quot;filePath: &amp;quot; &amp;lt;&amp;lt; myFile.filePath().toStdString() &amp;lt;&amp;lt; std::endl;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#160;&amp;#160; &amp;#160; std::cout &amp;lt;&amp;lt; &amp;quot;filePath: &amp;quot; &amp;lt;&amp;lt; myFile.filePath().toStdString() &amp;lt;&amp;lt; std::endl;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;#160;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;&amp;#160; &amp;#160; std::cout &amp;lt;&amp;lt; &amp;quot;absolutePath: &amp;quot; &amp;lt;&amp;lt; myFile.absolutePath().toStdString() &amp;lt;&amp;lt; std::endl;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#160;&amp;#160; &amp;#160; std::cout &amp;lt;&amp;lt; &amp;quot;baseName: &amp;quot; &amp;lt;&amp;lt; myFile.baseName().toStdString() &amp;lt;&amp;lt; std::endl;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#160;&amp;#160; &amp;#160; std::cout &amp;lt;&amp;lt; &amp;quot;baseName: &amp;quot; &amp;lt;&amp;lt; myFile.baseName().toStdString() &amp;lt;&amp;lt; std::endl;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;#160;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;&amp;#160; &amp;#160; std::cout &amp;lt;&amp;lt; &amp;quot;extension: &amp;quot; &amp;lt;&amp;lt; myFile.suffix().toStdString() &amp;lt;&amp;lt; std::endl;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#160;&amp;#160; &amp;#160; }&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#160;&amp;#160; &amp;#160; }&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#160;&amp;#160; else&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#160;&amp;#160; else&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>Daviddoria</name></author>	</entry>

	<entry>
		<id>http://www.programmingexamples.net/w/index.php?title=Qt/FileInfo&amp;diff=642&amp;oldid=prev</id>
		<title>Daviddoria: Created page with '==File.cpp== &lt;source lang=&quot;cpp&quot;&gt; #include &lt;iostream&gt;  #include &lt;QFileInfo&gt;  int main(int, char *[]) {   QFileInfo myFile(&quot;CMakeLists.txt&quot;);   if(myFile.exists())     {     std::c…'</title>
		<link rel="alternate" type="text/html" href="http://www.programmingexamples.net/w/index.php?title=Qt/FileInfo&amp;diff=642&amp;oldid=prev"/>
				<updated>2011-02-06T19:05:43Z</updated>
		
		<summary type="html">&lt;p&gt;Created page with &amp;#039;==File.cpp== &amp;lt;source lang=&amp;quot;cpp&amp;quot;&amp;gt; #include &amp;lt;iostream&amp;gt;  #include &amp;lt;QFileInfo&amp;gt;  int main(int, char *[]) {   QFileInfo myFile(&amp;quot;CMakeLists.txt&amp;quot;);   if(myFile.exists())     {     std::c…&amp;#039;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;==File.cpp==&lt;br /&gt;
&amp;lt;source lang=&amp;quot;cpp&amp;quot;&amp;gt;&lt;br /&gt;
#include &amp;lt;iostream&amp;gt;&lt;br /&gt;
&lt;br /&gt;
#include &amp;lt;QFileInfo&amp;gt;&lt;br /&gt;
&lt;br /&gt;
int main(int, char *[])&lt;br /&gt;
{&lt;br /&gt;
  QFileInfo myFile(&amp;quot;CMakeLists.txt&amp;quot;);&lt;br /&gt;
  if(myFile.exists())&lt;br /&gt;
    {&lt;br /&gt;
    std::cout &amp;lt;&amp;lt; &amp;quot;File exists&amp;quot; &amp;lt;&amp;lt; std::endl;&lt;br /&gt;
    std::cout &amp;lt;&amp;lt; &amp;quot;fileName: &amp;quot; &amp;lt;&amp;lt; myFile.fileName().toStdString() &amp;lt;&amp;lt; std::endl;&lt;br /&gt;
    std::cout &amp;lt;&amp;lt; &amp;quot;filePath: &amp;quot; &amp;lt;&amp;lt; myFile.filePath().toStdString() &amp;lt;&amp;lt; std::endl;&lt;br /&gt;
    std::cout &amp;lt;&amp;lt; &amp;quot;baseName: &amp;quot; &amp;lt;&amp;lt; myFile.baseName().toStdString() &amp;lt;&amp;lt; std::endl;&lt;br /&gt;
    }&lt;br /&gt;
  else&lt;br /&gt;
    {&lt;br /&gt;
    std::cout &amp;lt;&amp;lt; &amp;quot;File does not exist&amp;quot; &amp;lt;&amp;lt; std::endl;&lt;br /&gt;
    return 0;&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
  return 0;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==CMakeLists.txt==&lt;br /&gt;
&amp;lt;source lang=&amp;quot;cmake&amp;quot;&amp;gt;&lt;br /&gt;
cmake_minimum_required(VERSION 2.6)&lt;br /&gt;
&lt;br /&gt;
PROJECT(FileInfo)&lt;br /&gt;
&lt;br /&gt;
FIND_PACKAGE(Qt4 REQUIRED)&lt;br /&gt;
INCLUDE(${QT_USE_FILE})&lt;br /&gt;
&lt;br /&gt;
include_directories(${include_directories} ${CMAKE_CURRENT_SOURCE_DIR} ${CMAKE_CURRENT_BINARY_DIR})&lt;br /&gt;
&lt;br /&gt;
ADD_EXECUTABLE(FileInfo FileInfo.cpp)&lt;br /&gt;
TARGET_LINK_LIBRARIES(FileInfo ${QT_LIBRARIES})&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;/div&gt;</summary>
		<author><name>Daviddoria</name></author>	</entry>

	</feed>