Symbian3/PDK/Source/GUID-52151070-626D-5F14-B53F-7B46BCBD633E.dita
changeset 3 46218c8b8afa
parent 1 25a17d01db0c
child 5 f345bda72bc4
--- a/Symbian3/PDK/Source/GUID-52151070-626D-5F14-B53F-7B46BCBD633E.dita	Thu Mar 11 15:24:26 2010 +0000
+++ b/Symbian3/PDK/Source/GUID-52151070-626D-5F14-B53F-7B46BCBD633E.dita	Thu Mar 11 18:02:22 2010 +0000
@@ -1,34 +1,34 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
-<!-- This component and the accompanying materials are made available under the terms of the License 
-"Eclipse Public License v1.0" which accompanies this distribution, 
-and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
-<!-- Initial Contributors:
-    Nokia Corporation - initial contribution.
-Contributors: 
--->
-<!DOCTYPE concept
-  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
-<concept id="GUID-52151070-626D-5F14-B53F-7B46BCBD633E" xml:lang="en"><title>Using
-TAutoClose</title><shortdesc>Example code showing how <codeph>TAutoClose</codeph> can be used
-to clean up when an object goes out of scope.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
-<p>A simple example shows how this class can be used.</p>
-<codeblock id="GUID-468EE01A-8EC1-5D8E-845A-710D5BE3BBBC" xml:space="preserve">TInt ReadFile(const TDesC&amp; aFile)
-//
-// Read a file
-//
-    {
-    TAutoClose&lt;RFile&gt; file;
-    TInt r=file.iObj.Open(aFile,KFileStreamText|EFileExclusive);
-    if (r!=KErrNone)
-        return(r);
-    TBuf&lt;100&gt; b;
-    if ((r=file.iObj.Read(b))!=KErrNone)
-        return(r);
-    ...
-    }</codeblock>
-<p>The object <codeph>file</codeph> goes out of scope when the function completes,
-and the compiler automatically destroys it, calling the <xref href="GUID-3377FA4B-FDC8-3B25-8C5F-34675F6BEA12.dita"><apiname>TAutoClose</apiname></xref> destructor
-in the process. The destructor calls <codeph>Close()</codeph> on the <codeph>RFile</codeph> member
-of <codeph>TAutoClose</codeph>.</p>
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
+<!-- This component and the accompanying materials are made available under the terms of the License 
+"Eclipse Public License v1.0" which accompanies this distribution, 
+and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
+<!-- Initial Contributors:
+    Nokia Corporation - initial contribution.
+Contributors: 
+-->
+<!DOCTYPE concept
+  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
+<concept id="GUID-52151070-626D-5F14-B53F-7B46BCBD633E" xml:lang="en"><title>Using
+TAutoClose</title><shortdesc>Example code showing how <codeph>TAutoClose</codeph> can be used
+to clean up when an object goes out of scope.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
+<p>A simple example shows how this class can be used.</p>
+<codeblock id="GUID-468EE01A-8EC1-5D8E-845A-710D5BE3BBBC" xml:space="preserve">TInt ReadFile(const TDesC&amp; aFile)
+//
+// Read a file
+//
+    {
+    TAutoClose&lt;RFile&gt; file;
+    TInt r=file.iObj.Open(aFile,KFileStreamText|EFileExclusive);
+    if (r!=KErrNone)
+        return(r);
+    TBuf&lt;100&gt; b;
+    if ((r=file.iObj.Read(b))!=KErrNone)
+        return(r);
+    ...
+    }</codeblock>
+<p>The object <codeph>file</codeph> goes out of scope when the function completes,
+and the compiler automatically destroys it, calling the <xref href="GUID-3377FA4B-FDC8-3B25-8C5F-34675F6BEA12.dita"><apiname>TAutoClose</apiname></xref> destructor
+in the process. The destructor calls <codeph>Close()</codeph> on the <codeph>RFile</codeph> member
+of <codeph>TAutoClose</codeph>.</p>
 </conbody></concept>
\ No newline at end of file