Adobe.com
Contents Suites Classes Class Index Member Index

AIStringFormatUtils.h

Go to the documentation of this file.
00001 #ifndef __AIStringFormatUtils__
00002 #define __AIStringFormatUtils__
00003 
00004 /*
00005  *        Name: AIStringFormatUtils.h
00006  *   $Revision: 6 $
00007  *      Author:
00008  *        Date:
00009  *     Purpose: Adobe Illustrator String Format Utilities Suite.
00010  *
00011  * ADOBE SYSTEMS INCORPORATED
00012  * Copyright 2004-2007 Adobe Systems Incorporated.
00013  * All rights reserved.
00014  *
00015  * NOTICE:  Adobe permits you to use, modify, and distribute this file 
00016  * in accordance with the terms of the Adobe license agreement 
00017  * accompanying it. If you have received this file from a source other 
00018  * than Adobe, then your use, modification, or distribution of it 
00019  * requires the prior written permission of Adobe.
00020  *
00021  */
00022 
00023 
00024 /*******************************************************************************
00025  **
00026  **     Imports
00027  **
00028  **/
00029 
00030 #include "IAIStringFormatUtils.h"
00031 
00032 #include "AIHeaderBegin.h"
00033 
00036 /*******************************************************************************
00037  **
00038  ** Constants
00039  **
00040  **/
00041 
00042 #define kAIStringFormatUtilsSuite                       "AI String Format Utils Suite"
00043 #define kAIStringFormatUtilsSuiteVersion        AIAPI_VERSION(3)
00044 #define kAIStringFormatUtilsVersion                     kAIStringFormatUtilsSuiteVersion
00045 
00046 /*******************************************************************************
00047  **
00048  ** Types
00049  **
00050  **/
00051 
00054 #define kCannotParseStringError                 'NF!P'
00055 
00056 
00057 /*******************************************************************************
00058  **
00059  **     Suite
00060  **
00061  **/
00062 
00070 struct AIStringFormatUtilsSuite {
00071 
00072         /* Locale class support */
00073 
00078         AIAPI AIErr (*GetLocaleString)(const ai::LocaleID id, ai::AutoBuffer<char>& locale);
00079 
00084         AIAPI AIErr (*GetLocaleID)(const char* locale, ai::LocaleID& id );
00085 
00086 
00087         /* Number format creation & destruction */
00088 
00093         AIAPI AIErr (*Initialize) (ai::NumberFormat& format, const ai::LocaleID locale);
00094 
00099         AIAPI AIErr (*InitializeDefaultInstance) (ai::NumberFormat& format);
00100 
00107         AIAPI AIErr (*Copy) (ai::NumberFormat& format, const ai::NumberFormat& format2);
00108 
00112         AIAPI AIErr (*Destroy) (ai::NumberFormat& format);
00113 
00114         /* Basic operations */
00115 
00126         AIAPI AIErr (*RealToString) (ai::NumberFormat& format, const float value, const ai::int32 precision,
00127                                                                         AIBoolean padToPrecision, ai::UnicodeString& str);
00128 
00134         AIAPI AIErr (*IntegerToString) (ai::NumberFormat& format, const ai::int32 value, ai::UnicodeString& str);
00135 
00146         AIAPI AIErr (*DoubleToString) (ai::NumberFormat& format, const double value, const ai::int32 precision,
00147                                                                         AIBoolean padToPrecision, ai::UnicodeString& str);
00148 
00156         AIAPI AIErr (*StringToReal) (ai::NumberFormat& format, const ai::UnicodeString& str, float& value);
00157 
00165         AIAPI AIErr (*StringToInteger) (ai::NumberFormat& format, const ai::UnicodeString& str, ai::int32& value);
00166 
00174         AIAPI AIErr (*StringToDouble) (ai::NumberFormat& format, const ai::UnicodeString& str, double& value);
00175 
00180         AIAPI AIErr (*GetDecimalSeparator) (ai::NumberFormat& format, ai::UnicodeString& str);
00181 
00186         AIAPI AIErr (*GetThousandsSeparator) (ai::NumberFormat& format, ai::UnicodeString& str);
00187 };
00188 
00189 
00190 #include "AIHeaderEnd.h"
00191 
00192 
00193 
00194 #endif // __AIStringFormatUtils__


Contents Suites Classes Class Index Member Index
Adobe Solutions Network
 
Copyright © 2014 Adobe Systems Incorporated. All rights reserved.
Terms of Use Online Privacy Policy Adobe and accessibility Avoid software piracy Permissions and Trademarks