diff options
author | brunsch <brunsch@ae88bc3d-4319-0410-8dbf-d08b4c9d3795> | 2000-04-23 04:43:59 +0000 |
---|---|---|
committer | brunsch <brunsch@ae88bc3d-4319-0410-8dbf-d08b4c9d3795> | 2000-04-23 04:43:59 +0000 |
commit | a7c03cabf931b077d70c6f80ec02c7728a429f49 (patch) | |
tree | 61d38d262d43ac77fc2ad94c9e7e850cd5607622 /docs/ACE-guidelines.html | |
parent | 2aa7b10780ad7c670f588dce4ec341351a0646aa (diff) | |
download | ATCD-a7c03cabf931b077d70c6f80ec02c7728a429f49.tar.gz |
ChangeLogTag:Sat Apr 22 20:53:11 2000 Darrell Brunsch <brunsch@uci.edu>
Diffstat (limited to 'docs/ACE-guidelines.html')
-rw-r--r-- | docs/ACE-guidelines.html | 132 |
1 files changed, 4 insertions, 128 deletions
diff --git a/docs/ACE-guidelines.html b/docs/ACE-guidelines.html index 6851457c7f6..24d1bc08e1c 100644 --- a/docs/ACE-guidelines.html +++ b/docs/ACE-guidelines.html @@ -709,135 +709,11 @@ Foo::bar () <code>%ld</code> of any other multicharacter format.<p> </ul> - <li><strong>UNICODE conformity</strong><p> - - <ul> - <li>Define strings as <strong><code>ASYS_TCHAR</code></strong> if - they need to be passed into system API. It expands to - <code>wchar_t</code> only when - <code>ACE_HAS_MOSTLY_UNICODE_APIS</code> is defined.<p> - - <li>Use <strong><code>ASYS_TEXT</code></strong> and - <strong><code>ASYS_WIDE_STRING</code></strong> for format - strings and other string arguments passed to - <code>ACE_DEBUG</code> or <code>ACE_ERROR</code>. For - example,<p> - <pre> - void - ACE_FOO::ace_bar (int err, ASYS_TCHAR *astr) - { - ACE_TRACE ("ACE_FOO::ace_bar"); - - ACE_DEBUG ((LM_DEBUG, ASYS_TEXT ("From ACE_FOO::ace_bar"))); - - if (err) - ACE_ERROR ((LM_ERROR, - ASYS_TEXT ("(%P) Printing this string %s\n"), - astr)); - } - </pre> - <p> - This is because ACE also support platforms which use UNICODE - in most of their APIs. On these platforms, ACE also uses - UNICODE as its system string type.<p> - - Notice that when spaning a string literal across several lines, - you must apply <code>ASYS_TEXT</code> to <strong>every</strong> - line. For example, it is <font color=red>illegal</font> to do this: - <pre> - ACE_ERROR ((LM_ERROR, - ASYS_TEXT ("%p\n"), - ASYS_TEXT ("\nerror: x is a null pointer in " - "ACE_RB_Tree<EXT_ID, INT_ID>::" - "RB_rotate_left\n"))); - </pre></p> - - <p>Instead, this should be written like this: - <pre> - ACE_ERROR ((LM_ERROR, - ASYS_TEXT ("%p\n"), - ASYS_TEXT ("\nerror: x is a null pointer in ") - ASYS_TEXT ("ACE_RB_Tree<EXT_ID, INT_ID>::") - ASYS_TEXT ("RB_rotate_left\n"))); - </pre></p> - - <li><strong><code>ACE_TRACE</code></strong> handles conversion - between char strings and UNICODE strings automatically.<p> - - <li>Other helper macros include - <strong><code>ASYS_MULTIBYTE_STRING</code></strong> and - <strong><code>ASYS_ONLY_MULTIBYTE_STRING</code></strong>. See - the end of <a href="../ace/OS.h">OS.h</a> for more details.<p> - - <li>Here is a brief breakdown:<p> - <table BORDER=2 CELLSPACING=2 CELLPADDING=0> - <tr> - <th Align=left>Macro Name</th> - <td>NONE </td> - <td>UNICODE</td> - <td>MOSTLY</td> - <td>Remark</td> - </tr> - <tr> - <th align=left><code>ACE_WIDE_STRING</code></th> - <td>NOP</td> - <td>C 2 W</td> - <td>C 2 W</td> - <td> </td> - </tr> - <tr> - <th align=left><code>ACE_MULTIBYTE_STRING</code> - <td>NOP</td> - <td>W 2 C</td> - <td>W 2 C</td> - <td> </td> - </tr> - <tr> - <th align=left><code>ASYS_WIDE_STRING</code></th> - <td>NOP</td> - <td>NOP</td> - <td>C 2 W</td> - <td>Convert char strings to where ASYS_TCHAR strings are - expected.</td> - </tr> - <tr> - <th align=left><code>ASYS_MULTIBYTE_STRING</code></th> - <td>NOP</td> - <td>W 2 C</td> - <td>NOP</td> - <td>Convert LPTCSTR or LPTSTR strings to where ASYS_TCHAR - strings are expected.</td> - </tr> - <tr> - <th align=left><code>ASYS_ONLY_WIDE_STRING</code></th> - <td>NOP</td> - <td>C 2 W</td> - <td>NOP</td> - <td>Convert ASYS_TCHAR stirngs to where wchar strings are - expected.</td> - </tr> - <tr> - <th align=left><code>ASYS_ONLY_MULTIBYTE_STRING</code></th> - <td>NOP</td> - <td>NOP</td> - <td>W 2 C</td> - <td>Convert ASYS_TCHAR strings to where</td> - </tr> - </table><p> - Where: - - <ul> - <li>UNICODE: When <code>UNICODE</code> is defined. - <li>MOSTLY: When <code>ACE_HAS_MOSTLY_UNICODE_APIS</code> is - defined - <li>C: char * - <li>W: wchar * - <li>T: ASYS_TCHAR* (T == W) only when MOSTLY is defined, - otherwise, (T == C) - <li>NOP: No operation. - </ul><p> - </ul><p> + <li><strong>WCHAR conformity</strong><p> + <!-- @@ UNICODE: update --> + For now, don't worry about it. + <li><strong>Exceptions</strong><p> <ul> |