Changes between Version 5 and Version 6 of Docs/Prog/Manual/ApplicationLibraries/lib825ev/File/CFile


Ignore:
Timestamp:
08/23/10 07:37:34 (14 years ago)
Author:
Don Wilson
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • Docs/Prog/Manual/ApplicationLibraries/lib825ev/File/CFile

    v5 v6  
    77== Constructors ==
    88
    9  * CFile(void);
    10  * CFile(const string& strFilename);
    11  * CFile(const char* pszfilename);
    12 
     9{{{
     10CFile(void);
     11CFile(const string& strFilename);
     12CFile(const char* pszfilename);
     13}}}
    1314These constructors just create a CFile object without opening a file.
    14 
    15  * CFile(const string& strFilename, const string& strMode);
    16  * CFile(const string& strFilename, const char* pszMode);
    17  * CFile(const char* pszFilename, const string& strMode);
    18  * CFile(const char* pszFilename, const char* pszMode);
    19 
     15{{{
     16CFile(const string& strFilename, const string& strMode);
     17CFile(const string& strFilename, const char* pszMode);
     18CFile(const char* pszFilename, const string& strMode);
     19CFile(const char* pszFilename, const char* pszMode);
     20}}}
    2021These constructors construct the file object and attempt to open the file.
    2122
     
    2930}}}
    3031
     32==== Parameters ====
     33 * strFilename - filename
     34 * pszFilename - filename
     35 * strMode - mode
     36 * pszMode - mode
     37
    3138== Member Functions ==
    3239
     
    3441Opens a specified file, or using the filename already stored in the object.
    3542
    36  * bool Open(const string& strFilename, const string& strMode);
    37  * bool Open(const string& strFilename, const char* pszMode);
    38  * bool Open(const char* pszFilename, const string& strMode);
    39  * bool Open(const char* pszFilename, const char* pszMode);
    40  * bool Open(const char* pszMode);
     43{{{
     44bool Open(const string& strFilename, const string& strMode);
     45bool Open(const string& strFilename, const char* pszMode);
     46bool Open(const char* pszFilename, const string& strMode);
     47bool Open(const char* pszFilename, const char* pszMode);
     48bool Open(const char* pszMode);
     49}}}
    4150
    4251==== Parameters ====
     
    4655 * pszMode - mode
    4756
    48 ==== Return ====
     57==== Return Value ====
    4958
    5059Returns true if successful or false if unsuccessful.
    5160
     61==== Remarks ====
     62
     63==== Example ====
     64
     65{{{
     66CFile file;
     67if(file.Open("/tmp/tmpfile", "w") == false)
     68{
     69    DisplayText(0, 0, "Error writing temporary file");
     70}
     71
     72}}}
    5273
    5374=== Close ===
    5475Closes the file
    55  * void Close(void);
     76{{{
     77void Close(void);
     78}}}
    5679
    5780==== Parameters ====
     
    80103
    81104=== IsReady ===
     105Check the state of the serial CTS input
     106{{{
     107bool IsReady(void);
     108}}}
     109==== Parameters ====
    82110
    83  * bool IsReady(void);
     111Function does not accept any parameters.
     112
     113==== Return Value ====
     114
     115Function returns true if CTS is active, false if CTS is inactive.
     116
     117==== Remarks ====
     118
     119==== Example ====
     120
     121{{{
     122CFile fileLogOutput("/dev/ttyS1", "w");
     123if(fileLogOutput.IsOpen())
     124{
     125   fileLogOutput.SetRTS(true);
     126   if(fileLogOutput.IsReady() == false)
     127   {
     128      DisplayText(0, 0, "Printer offline, or disconnected");
     129   }
     130}
     131}}}
     132
    84133
    85134=== SetRTS ===
     135Set the state of the serial RTS output
    86136
    87  * bool SetRTS(bool on = true);
     137{{{
     138bool SetRTS(bool bRTSOn = true);
     139}}}
     140
     141==== Parameters ====
     142
     143 * bRTSOn - true to turn on RTS output, false to turn off RTS output
     144
     145==== Return Value ====
     146
     147 * Returns true if successfully set RTS state, false otherwise.
     148
     149==== Remarks ====
     150
     151==== Example ====
     152
     153{{{
     154CFile fileLogOutput("/dev/ttyS1", "w");
     155fileLogOutput.SetRTS(true);
     156}}}
     157
     158
    88159
    89160=== GetFile ===