CrossFramework Library

XBase/StringTraits.hpp

説明を見る。
00001 
00006 #if defined(XBASE_INCLUDED_CHARTRAITS_HPP)
00007 #else
00008 #define XBASE_INCLUDED_CHARTRAITS_HPP
00009 
00010 //------------------------------------------------------------
00011 #include <cstdarg>
00012 #include <XBase/BuiltInTypes.hpp>
00013 
00014 //------------------------------------------------------------
00015 namespace XBase {
00017 
00018 
00027     template< typename CharType >
00028     struct StringTraits
00029     {
00031         struct WriteResult
00032         {
00033             bool   isSuccess; 
00034             pword_t length;    
00035         };
00036 
00041         static pword_t Length( const CharType* aStr );
00042         
00051         static const WriteResult NCopyStrict( CharType* aBuffer , pword_t aBufferLength , const CharType* aStr );
00052         
00063         static const WriteResult NCopy( CharType* aBuffer , pword_t aBufferLength , const CharType* aStr );
00064          
00073         static const WriteResult SNPrintfStrict( CharType* aBuffer , pword_t aBufferLength , const CharType* aFormat , ... );
00074 
00085         static const WriteResult SNPrintf( CharType* aBuffer , pword_t aBufferLength , const CharType* aFormat , ... );
00086          
00096         static const WriteResult VSNPrintfStrict( CharType* aBuffer , pword_t aBufferLength , const CharType* aFormat , va_list aArg );
00097 
00109         static const WriteResult VSNPrintf( CharType* aBuffer , pword_t aBufferLength , const CharType* aFormat , va_list aArg );
00110     };
00112 }
00113 //------------------------------------------------------------
00114 #endif
00115 // EOF
 全て クラス ネームスペース ファイル 関数 変数 型定義 列挙型 列挙型の値 マクロ定義