1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/intl/uconv/ucvja/nsUnicodeToISO2022JP.h Wed Dec 31 06:09:35 2014 +0100 1.3 @@ -0,0 +1,52 @@ 1.4 +/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ 1.5 +/* This Source Code Form is subject to the terms of the Mozilla Public 1.6 + * License, v. 2.0. If a copy of the MPL was not distributed with this 1.7 + * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ 1.8 + 1.9 +#ifndef nsUnicodeToISO2022JP_h___ 1.10 +#define nsUnicodeToISO2022JP_h___ 1.11 + 1.12 +#include "nsUCSupport.h" 1.13 + 1.14 +//---------------------------------------------------------------------- 1.15 +// Class nsUnicodeToISO2022JP [declaration] 1.16 + 1.17 +/** 1.18 + * A character set converter from Unicode to ISO2022JP. 1.19 + * 1.20 + * @created 17/Feb/1999 1.21 + * @author Catalin Rotaru [CATA] 1.22 + */ 1.23 +class nsUnicodeToISO2022JP : public nsEncoderSupport 1.24 +{ 1.25 +public: 1.26 + 1.27 + /** 1.28 + * Class constructor. 1.29 + */ 1.30 + nsUnicodeToISO2022JP(); 1.31 + 1.32 + /** 1.33 + * Class destructor. 1.34 + */ 1.35 + virtual ~nsUnicodeToISO2022JP(); 1.36 + 1.37 +protected: 1.38 + 1.39 + int32_t mCharset; // current character set 1.40 + 1.41 + nsresult ChangeCharset(int32_t aCharset, char * aDest, 1.42 + int32_t * aDestLength); 1.43 + nsresult ConvertHankaku(const char16_t *aSrc, int32_t * aSrcLength, 1.44 + char *aDest, int32_t * aDestLength); 1.45 + 1.46 + //-------------------------------------------------------------------- 1.47 + // Subclassing of nsEncoderSupport class [declaration] 1.48 + 1.49 + NS_IMETHOD ConvertNoBuffNoErr(const char16_t * aSrc, int32_t * aSrcLength, 1.50 + char * aDest, int32_t * aDestLength); 1.51 + NS_IMETHOD FinishNoBuff(char * aDest, int32_t * aDestLength); 1.52 + NS_IMETHOD Reset(); 1.53 +}; 1.54 + 1.55 +#endif /* nsUnicodeToISO2022JP_h___ */