diff options
author | brunsch <brunsch@ae88bc3d-4319-0410-8dbf-d08b4c9d3795> | 2000-07-09 21:26:26 +0000 |
---|---|---|
committer | brunsch <brunsch@ae88bc3d-4319-0410-8dbf-d08b4c9d3795> | 2000-07-09 21:26:26 +0000 |
commit | 4feb2a1c0d29666edb225594c886537f16d61367 (patch) | |
tree | 459c5833991d45bfe7e5e4e264e7b8837e023a6d | |
parent | 46cee8c01a1ecfb7a942e7a6a8f8b65cbe352891 (diff) | |
download | ATCD-4feb2a1c0d29666edb225594c886537f16d61367.tar.gz |
ChangeLogTag:Sun Jul 09 14:20:42 2000 Darrell Brunsch <brunsch@uci.edu>
-rw-r--r-- | ChangeLog | 116 | ||||
-rw-r--r-- | ChangeLogs/ChangeLog-02a | 116 | ||||
-rw-r--r-- | ChangeLogs/ChangeLog-03a | 116 | ||||
-rw-r--r-- | ace/ace_wchar.h | 23 |
4 files changed, 210 insertions, 161 deletions
diff --git a/ChangeLog b/ChangeLog index 69902781294..cf2141a39f7 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,55 +1,67 @@ -Sun Jul 09 14:00:34 2000 Darrell Brunsch <brunsch@uci.edu> - - * ace/ace_wchar.h: - - Added two macros for straight out conversion of strings: - ACE_TEXT_CHAR_TO_WCHAR and ACE_TEXT_WCHAR_TO_CHAR. - - * ace/adapter/README - * ace/adapter/ace/ACE.h - * ace/adapter/ace/ARGV.h - * ace/adapter/ace/Arg_Shifter.h - * ace/adapter/ace/ATM_Addr.h - * ace/adapter/ace/DEV_Addr.h - * ace/adapter/ace/Dirent.h - * ace/adapter/ace/DLL.h - * ace/adapter/ace/Dynamic_Service.h - * ace/adapter/ace/FIFO.h - * ace/adapter/ace/FIFO_Recv.h - * ace/adapter/ace/FIFO_Recv_Msg.h - * ace/adapter/ace/FIFO_Send.h - * ace/adapter/ace/FIFO_Send_Msg.h - * ace/adapter/ace/FILE_Addr.h - * ace/adapter/ace/Functor.h - * ace/adapter/ace/High_Res_Timer.h - * ace/adapter/ace/INET_Addr.h - * ace/adapter/ace/Malloc_T.h - * ace/adapter/ace/Memory_Pool.h - * ace/adapter/ace/MEM_Addr.h - * ace/adapter/ace/OS_Dirent.h - * ace/adapter/ace/OS_String.h - * ace/adapter/ace/Service_Config.h - * ace/adapter/ace/Service_Object.h - * ace/adapter/ace/SOCK_Dgram_Bcast.h - * ace/adapter/ace/SOCK_Dgram_Mcast.h - * ace/adapter/ace/SPIPE_Addr.h - * ace/adapter/ace/System_Time.h - * ace/adapter/ace/Task_T.h - * ace/adapter/ace/Trace.h - - This is a initial shot at the implementation of an adaptation - layer for ACE that provides a Wide character interface with - a character library and vice versa. - - Right now the above files contain classes ending with _W that - correspond to the actual classes (such as ACE_W). This class - will have methods that take in wchar_t instead of char, and - then convert the parameters and return value when calling - the actual char implementation. - - Note, this is an initial implementation that isn't complete - across all interfaces and there are memory managment issues that - still must be dealt with. +Sun Jul 09 14:20:42 2000 Darrell Brunsch <brunsch@uci.edu> + + * ace/ace_wchar.h: + + Added support for wchar_t on VxWorks. It now compiles, but + unfortunately VxWorks doesn't come with any C library support + beyond conversion to/from multi-byte character strings. + + This will only take effect when ACE_HAS_WCHAR is defined (it + isn't by default). Emulation for the missing str* functions + will be added soon. + +Sun Jul 09 14:00:42 2000 Darrell Brunsch <brunsch@uci.edu> + + * ace/ace_wchar.h: + + Added two macros for straight out conversion of strings: + ACE_TEXT_CHAR_TO_WCHAR and ACE_TEXT_WCHAR_TO_CHAR. + + * ace/adapter/README: (Added) + * ace/adapter/ace/ACE.h: (Added) + * ace/adapter/ace/ARGV.h: (Added) + * ace/adapter/ace/Arg_Shifter.h: (Added) + * ace/adapter/ace/ATM_Addr.h: (Added) + * ace/adapter/ace/DEV_Addr.h: (Added) + * ace/adapter/ace/Dirent.h: (Added) + * ace/adapter/ace/DLL.h: (Added) + * ace/adapter/ace/Dynamic_Service.h: (Added) + * ace/adapter/ace/FIFO.h: (Added) + * ace/adapter/ace/FIFO_Recv.h: (Added) + * ace/adapter/ace/FIFO_Recv_Msg.h: (Added) + * ace/adapter/ace/FIFO_Send.h: (Added) + * ace/adapter/ace/FIFO_Send_Msg.h: (Added) + * ace/adapter/ace/FILE_Addr.h: (Added) + * ace/adapter/ace/Functor.h: (Added) + * ace/adapter/ace/High_Res_Timer.h: (Added) + * ace/adapter/ace/INET_Addr.h: (Added) + * ace/adapter/ace/Malloc_T.h: (Added) + * ace/adapter/ace/Memory_Pool.h: (Added) + * ace/adapter/ace/MEM_Addr.h: (Added) + * ace/adapter/ace/OS_Dirent.h: (Added) + * ace/adapter/ace/OS_String.h: (Added) + * ace/adapter/ace/Service_Config.h: (Added) + * ace/adapter/ace/Service_Object.h: (Added) + * ace/adapter/ace/SOCK_Dgram_Bcast.h: (Added) + * ace/adapter/ace/SOCK_Dgram_Mcast.h: (Added) + * ace/adapter/ace/SPIPE_Addr.h: (Added) + * ace/adapter/ace/System_Time.h: (Added) + * ace/adapter/ace/Task_T.h: (Added) + * ace/adapter/ace/Trace.h: (Added) + + This is a initial shot at the implementation of an adaptation + layer for ACE that provides a Wide character interface with + a character library and vice versa. + + Right now the above files contain classes ending with _W that + correspond to the actual classes (such as ACE_W). This class + will have methods that take in wchar_t instead of char, and + then convert the parameters and return value when calling + the actual char implementation. + + Note, this is an initial implementation that isn't complete + across all interfaces and there are memory management issues that + still must be dealt with. Sat Jul 08 14:50:34 2000 David L. Levine <levine@cs.wustl.edu> diff --git a/ChangeLogs/ChangeLog-02a b/ChangeLogs/ChangeLog-02a index 69902781294..cf2141a39f7 100644 --- a/ChangeLogs/ChangeLog-02a +++ b/ChangeLogs/ChangeLog-02a @@ -1,55 +1,67 @@ -Sun Jul 09 14:00:34 2000 Darrell Brunsch <brunsch@uci.edu> - - * ace/ace_wchar.h: - - Added two macros for straight out conversion of strings: - ACE_TEXT_CHAR_TO_WCHAR and ACE_TEXT_WCHAR_TO_CHAR. - - * ace/adapter/README - * ace/adapter/ace/ACE.h - * ace/adapter/ace/ARGV.h - * ace/adapter/ace/Arg_Shifter.h - * ace/adapter/ace/ATM_Addr.h - * ace/adapter/ace/DEV_Addr.h - * ace/adapter/ace/Dirent.h - * ace/adapter/ace/DLL.h - * ace/adapter/ace/Dynamic_Service.h - * ace/adapter/ace/FIFO.h - * ace/adapter/ace/FIFO_Recv.h - * ace/adapter/ace/FIFO_Recv_Msg.h - * ace/adapter/ace/FIFO_Send.h - * ace/adapter/ace/FIFO_Send_Msg.h - * ace/adapter/ace/FILE_Addr.h - * ace/adapter/ace/Functor.h - * ace/adapter/ace/High_Res_Timer.h - * ace/adapter/ace/INET_Addr.h - * ace/adapter/ace/Malloc_T.h - * ace/adapter/ace/Memory_Pool.h - * ace/adapter/ace/MEM_Addr.h - * ace/adapter/ace/OS_Dirent.h - * ace/adapter/ace/OS_String.h - * ace/adapter/ace/Service_Config.h - * ace/adapter/ace/Service_Object.h - * ace/adapter/ace/SOCK_Dgram_Bcast.h - * ace/adapter/ace/SOCK_Dgram_Mcast.h - * ace/adapter/ace/SPIPE_Addr.h - * ace/adapter/ace/System_Time.h - * ace/adapter/ace/Task_T.h - * ace/adapter/ace/Trace.h - - This is a initial shot at the implementation of an adaptation - layer for ACE that provides a Wide character interface with - a character library and vice versa. - - Right now the above files contain classes ending with _W that - correspond to the actual classes (such as ACE_W). This class - will have methods that take in wchar_t instead of char, and - then convert the parameters and return value when calling - the actual char implementation. - - Note, this is an initial implementation that isn't complete - across all interfaces and there are memory managment issues that - still must be dealt with. +Sun Jul 09 14:20:42 2000 Darrell Brunsch <brunsch@uci.edu> + + * ace/ace_wchar.h: + + Added support for wchar_t on VxWorks. It now compiles, but + unfortunately VxWorks doesn't come with any C library support + beyond conversion to/from multi-byte character strings. + + This will only take effect when ACE_HAS_WCHAR is defined (it + isn't by default). Emulation for the missing str* functions + will be added soon. + +Sun Jul 09 14:00:42 2000 Darrell Brunsch <brunsch@uci.edu> + + * ace/ace_wchar.h: + + Added two macros for straight out conversion of strings: + ACE_TEXT_CHAR_TO_WCHAR and ACE_TEXT_WCHAR_TO_CHAR. + + * ace/adapter/README: (Added) + * ace/adapter/ace/ACE.h: (Added) + * ace/adapter/ace/ARGV.h: (Added) + * ace/adapter/ace/Arg_Shifter.h: (Added) + * ace/adapter/ace/ATM_Addr.h: (Added) + * ace/adapter/ace/DEV_Addr.h: (Added) + * ace/adapter/ace/Dirent.h: (Added) + * ace/adapter/ace/DLL.h: (Added) + * ace/adapter/ace/Dynamic_Service.h: (Added) + * ace/adapter/ace/FIFO.h: (Added) + * ace/adapter/ace/FIFO_Recv.h: (Added) + * ace/adapter/ace/FIFO_Recv_Msg.h: (Added) + * ace/adapter/ace/FIFO_Send.h: (Added) + * ace/adapter/ace/FIFO_Send_Msg.h: (Added) + * ace/adapter/ace/FILE_Addr.h: (Added) + * ace/adapter/ace/Functor.h: (Added) + * ace/adapter/ace/High_Res_Timer.h: (Added) + * ace/adapter/ace/INET_Addr.h: (Added) + * ace/adapter/ace/Malloc_T.h: (Added) + * ace/adapter/ace/Memory_Pool.h: (Added) + * ace/adapter/ace/MEM_Addr.h: (Added) + * ace/adapter/ace/OS_Dirent.h: (Added) + * ace/adapter/ace/OS_String.h: (Added) + * ace/adapter/ace/Service_Config.h: (Added) + * ace/adapter/ace/Service_Object.h: (Added) + * ace/adapter/ace/SOCK_Dgram_Bcast.h: (Added) + * ace/adapter/ace/SOCK_Dgram_Mcast.h: (Added) + * ace/adapter/ace/SPIPE_Addr.h: (Added) + * ace/adapter/ace/System_Time.h: (Added) + * ace/adapter/ace/Task_T.h: (Added) + * ace/adapter/ace/Trace.h: (Added) + + This is a initial shot at the implementation of an adaptation + layer for ACE that provides a Wide character interface with + a character library and vice versa. + + Right now the above files contain classes ending with _W that + correspond to the actual classes (such as ACE_W). This class + will have methods that take in wchar_t instead of char, and + then convert the parameters and return value when calling + the actual char implementation. + + Note, this is an initial implementation that isn't complete + across all interfaces and there are memory management issues that + still must be dealt with. Sat Jul 08 14:50:34 2000 David L. Levine <levine@cs.wustl.edu> diff --git a/ChangeLogs/ChangeLog-03a b/ChangeLogs/ChangeLog-03a index 69902781294..cf2141a39f7 100644 --- a/ChangeLogs/ChangeLog-03a +++ b/ChangeLogs/ChangeLog-03a @@ -1,55 +1,67 @@ -Sun Jul 09 14:00:34 2000 Darrell Brunsch <brunsch@uci.edu> - - * ace/ace_wchar.h: - - Added two macros for straight out conversion of strings: - ACE_TEXT_CHAR_TO_WCHAR and ACE_TEXT_WCHAR_TO_CHAR. - - * ace/adapter/README - * ace/adapter/ace/ACE.h - * ace/adapter/ace/ARGV.h - * ace/adapter/ace/Arg_Shifter.h - * ace/adapter/ace/ATM_Addr.h - * ace/adapter/ace/DEV_Addr.h - * ace/adapter/ace/Dirent.h - * ace/adapter/ace/DLL.h - * ace/adapter/ace/Dynamic_Service.h - * ace/adapter/ace/FIFO.h - * ace/adapter/ace/FIFO_Recv.h - * ace/adapter/ace/FIFO_Recv_Msg.h - * ace/adapter/ace/FIFO_Send.h - * ace/adapter/ace/FIFO_Send_Msg.h - * ace/adapter/ace/FILE_Addr.h - * ace/adapter/ace/Functor.h - * ace/adapter/ace/High_Res_Timer.h - * ace/adapter/ace/INET_Addr.h - * ace/adapter/ace/Malloc_T.h - * ace/adapter/ace/Memory_Pool.h - * ace/adapter/ace/MEM_Addr.h - * ace/adapter/ace/OS_Dirent.h - * ace/adapter/ace/OS_String.h - * ace/adapter/ace/Service_Config.h - * ace/adapter/ace/Service_Object.h - * ace/adapter/ace/SOCK_Dgram_Bcast.h - * ace/adapter/ace/SOCK_Dgram_Mcast.h - * ace/adapter/ace/SPIPE_Addr.h - * ace/adapter/ace/System_Time.h - * ace/adapter/ace/Task_T.h - * ace/adapter/ace/Trace.h - - This is a initial shot at the implementation of an adaptation - layer for ACE that provides a Wide character interface with - a character library and vice versa. - - Right now the above files contain classes ending with _W that - correspond to the actual classes (such as ACE_W). This class - will have methods that take in wchar_t instead of char, and - then convert the parameters and return value when calling - the actual char implementation. - - Note, this is an initial implementation that isn't complete - across all interfaces and there are memory managment issues that - still must be dealt with. +Sun Jul 09 14:20:42 2000 Darrell Brunsch <brunsch@uci.edu> + + * ace/ace_wchar.h: + + Added support for wchar_t on VxWorks. It now compiles, but + unfortunately VxWorks doesn't come with any C library support + beyond conversion to/from multi-byte character strings. + + This will only take effect when ACE_HAS_WCHAR is defined (it + isn't by default). Emulation for the missing str* functions + will be added soon. + +Sun Jul 09 14:00:42 2000 Darrell Brunsch <brunsch@uci.edu> + + * ace/ace_wchar.h: + + Added two macros for straight out conversion of strings: + ACE_TEXT_CHAR_TO_WCHAR and ACE_TEXT_WCHAR_TO_CHAR. + + * ace/adapter/README: (Added) + * ace/adapter/ace/ACE.h: (Added) + * ace/adapter/ace/ARGV.h: (Added) + * ace/adapter/ace/Arg_Shifter.h: (Added) + * ace/adapter/ace/ATM_Addr.h: (Added) + * ace/adapter/ace/DEV_Addr.h: (Added) + * ace/adapter/ace/Dirent.h: (Added) + * ace/adapter/ace/DLL.h: (Added) + * ace/adapter/ace/Dynamic_Service.h: (Added) + * ace/adapter/ace/FIFO.h: (Added) + * ace/adapter/ace/FIFO_Recv.h: (Added) + * ace/adapter/ace/FIFO_Recv_Msg.h: (Added) + * ace/adapter/ace/FIFO_Send.h: (Added) + * ace/adapter/ace/FIFO_Send_Msg.h: (Added) + * ace/adapter/ace/FILE_Addr.h: (Added) + * ace/adapter/ace/Functor.h: (Added) + * ace/adapter/ace/High_Res_Timer.h: (Added) + * ace/adapter/ace/INET_Addr.h: (Added) + * ace/adapter/ace/Malloc_T.h: (Added) + * ace/adapter/ace/Memory_Pool.h: (Added) + * ace/adapter/ace/MEM_Addr.h: (Added) + * ace/adapter/ace/OS_Dirent.h: (Added) + * ace/adapter/ace/OS_String.h: (Added) + * ace/adapter/ace/Service_Config.h: (Added) + * ace/adapter/ace/Service_Object.h: (Added) + * ace/adapter/ace/SOCK_Dgram_Bcast.h: (Added) + * ace/adapter/ace/SOCK_Dgram_Mcast.h: (Added) + * ace/adapter/ace/SPIPE_Addr.h: (Added) + * ace/adapter/ace/System_Time.h: (Added) + * ace/adapter/ace/Task_T.h: (Added) + * ace/adapter/ace/Trace.h: (Added) + + This is a initial shot at the implementation of an adaptation + layer for ACE that provides a Wide character interface with + a character library and vice versa. + + Right now the above files contain classes ending with _W that + correspond to the actual classes (such as ACE_W). This class + will have methods that take in wchar_t instead of char, and + then convert the parameters and return value when calling + the actual char implementation. + + Note, this is an initial implementation that isn't complete + across all interfaces and there are memory management issues that + still must be dealt with. Sat Jul 08 14:50:34 2000 David L. Levine <levine@cs.wustl.edu> diff --git a/ace/ace_wchar.h b/ace/ace_wchar.h index 9c8fc06de0a..a75851d0297 100644 --- a/ace/ace_wchar.h +++ b/ace/ace_wchar.h @@ -66,7 +66,12 @@ typedef char TCHAR; #endif /* ACE_ONLY_LATEST_AND_GREATEST */ #if defined (ACE_HAS_WCHAR) -# if defined (ACE_HAS_STANDARD_CPP_LIBRARY) && \ +# if defined (VXWORKS) +# include /**/ <types/vxTypes.h> /* For wchar_t */ +# include /**/ <stdlib.h> /* For mbstowcs, etc. */ +# include /**/ <string.h> /* For strlen */ +# define wint_t unsigned int /* VxWorks has wchar_t but not wint_t */ +# elif defined (ACE_HAS_STANDARD_CPP_LIBRARY) && \ (ACE_HAS_STANDARD_CPP_LIBRARY != 0) # include /**/ <cwchar> # elif !defined (__BORLANDC__) && !defined (ACE_HAS_WINCE) @@ -78,10 +83,6 @@ typedef char TCHAR; // Define the unicode/wchar related macros correctly -#if defined ACE_HAS_WCHAR -# define ACE_TEXT_CHAR_TO_WCHAR(STRING) ACE_Ascii_To_Wide (STRING).wchar_rep () -# define ACE_TEXT_WCHAR_TO_CHAR(STRING) ACE_Wide_To_Ascii (STRING).char_rep () -#endif /* ACE_HAS_WCHAR */ #if defined (ACE_USES_WCHAR) typedef wchar_t ACE_TCHAR; @@ -121,6 +122,14 @@ public: # if defined (ACE_WIN32) size_t len = ::WideCharToMultiByte (CP_OEMCP, 0, wstr, -1, NULL, 0, NULL, NULL); +# elif defined (VXWORKS) + // @@ we should use a different macro than VXWORKS here, ACE_LACKS_WCSLEN? + + const wchar_t *wtemp = wstr; + while (wtemp != 0) + ++wtemp; + + size_t len = wtemp - wstr + 1; # else size_t len = ::wcslen (wstr) + 1; # endif @@ -129,6 +138,8 @@ public: # if defined (ACE_WIN32) ::WideCharToMultiByte (CP_OEMCP, 0, wstr, -1, str, len, NULL, NULL); +# elif defined (VXWORKS) + ::wcstombs (str, wstr, len); # else /* ACE_WIN32 */ for (size_t i = 0; i < len; i++) { @@ -181,6 +192,8 @@ public: # if defined (ACE_WIN32) ::MultiByteToWideChar (CP_OEMCP, 0, str, -1, wstr, len); +# elif defined (VXWORKS) + ::mbstowcs (wstr, str, len); # else /* ACE_WIN32 */ for (size_t i = 0; i < len; i++) { |