ICU-6118 Export less internal API.

X-SVN-Rev: 23173
This commit is contained in:
George Rhoten 2008-01-04 08:45:10 +00:00
parent 49763cd5c8
commit c05bd41d42
13 changed files with 452 additions and 470 deletions

View file

@ -1,6 +1,6 @@
/*
**********************************************************************
* Copyright (C) 1999-2007, International Business Machines
* Copyright (C) 1999-2008, International Business Machines
* Corporation and others. All Rights Reserved.
**********************************************************************
* file name: ustr_imp.h
@ -32,7 +32,7 @@
* and memcmp/UnicodeString style (at least one length >=0).
* @internal
*/
U_CAPI int32_t U_EXPORT2
U_CFUNC int32_t U_EXPORT2
uprv_strCompare(const UChar *s1, int32_t length1,
const UChar *s2, int32_t length2,
UBool strncmpStyle, UBool codePointOrder);

View file

@ -1,7 +1,7 @@
/*
******************************************************************************
*
* Copyright (C) 1998-2007, International Business Machines
* Copyright (C) 1998-2008, International Business Machines
* Corporation and others. All Rights Reserved.
*
******************************************************************************
@ -679,7 +679,7 @@ u_strcmp(const UChar *s1,
return (int32_t)c1 - (int32_t)c2;
}
U_CAPI int32_t U_EXPORT2
U_CFUNC int32_t U_EXPORT2
uprv_strCompare(const UChar *s1, int32_t length1,
const UChar *s2, int32_t length2,
UBool strncmpStyle, UBool codePointOrder) {

File diff suppressed because it is too large Load diff

View file

@ -1,5 +1,5 @@
/************************************************************************
* Copyright (C) 1996-2007, International Business Machines Corporation *
* Copyright (C) 1996-2008, International Business Machines Corporation *
* and others. All Rights Reserved. *
************************************************************************
* 2003-nov-07 srl Port from Java
@ -668,44 +668,6 @@ public:
// Other utility methods
//-------------------------------------------------------------------------
private:
/***
* Given 'value', add or subtract 'range' until 0 <= 'value' < range.
* The modulus operator.
*/
inline static double normalize(double value, double range) {
return value - range * Math::floorDivide(value, range);
}
/**
* Normalize an angle so that it's in the range 0 - 2pi.
* For positive angles this is just (angle % 2pi), but the Java
* mod operator doesn't work that way for negative numbers....
*/
inline static double norm2PI(double angle) {
return normalize(angle, CalendarAstronomer::PI * 2.0);
}
/**
* Normalize an angle into the range -PI - PI
*/
inline static double normPI(double angle) {
return normalize(angle + PI, CalendarAstronomer::PI * 2.0) - PI;
}
/**
* Find the "true anomaly" (longitude) of an object from
* its mean anomaly and the eccentricity of its orbit. This uses
* an iterative solution to Kepler's equation.
*
* @param meanAnomaly The object's longitude calculated as if it were in
* a regular, circular orbit, measured in radians
* from the point of perigee.
*
* @param eccentricity The eccentricity of the orbit
*
* @return The true anomaly (longitude) measured in radians
*/
double trueAnomaly(double meanAnomaly, double eccentricity);
/**
* Return the obliquity of the ecliptic (the angle between the ecliptic

View file

@ -1,7 +1,7 @@
/*
*******************************************************************************
*
* Copyright (C) 2001-2007, International Business Machines
* Copyright (C) 2001-2008, International Business Machines
* Corporation and others. All Rights Reserved.
*
*******************************************************************************
@ -81,7 +81,7 @@ utrans_rep_caseContextIterator(void *context, int8_t dir)
U_NAMESPACE_BEGIN
UOBJECT_DEFINE_RTTI_IMPLEMENTATION(CaseMapTransliterator)
UOBJECT_DEFINE_ABSTRACT_RTTI_IMPLEMENTATION(CaseMapTransliterator)
/**
* Constructs a transliterator.
@ -126,9 +126,9 @@ CaseMapTransliterator::CaseMapTransliterator(const CaseMapTransliterator& o) :
/**
* Transliterator API.
*/
Transliterator* CaseMapTransliterator::clone(void) const {
/*Transliterator* CaseMapTransliterator::clone(void) const {
return new CaseMapTransliterator(*this);
}
}*/
/**
* Implements {@link Transliterator#handleTransliterate}.

View file

@ -1,7 +1,7 @@
/*
*******************************************************************************
*
* Copyright (C) 2001-2007, International Business Machines
* Copyright (C) 2001-2008, International Business Machines
* Corporation and others. All Rights Reserved.
*
*******************************************************************************
@ -32,7 +32,7 @@ U_NAMESPACE_BEGIN
* A transliterator that performs locale-sensitive
* case mapping.
*/
class U_I18N_API CaseMapTransliterator : public Transliterator {
class CaseMapTransliterator : public Transliterator {
public:
/**
* Constructs a transliterator.
@ -56,17 +56,17 @@ public:
* Transliterator API.
* @return a copy of the object.
*/
virtual Transliterator* clone(void) const;
virtual Transliterator* clone(void) const = 0;
/**
* ICU "poor man's RTTI", returns a UClassID for the actual class.
*/
virtual UClassID getDynamicClassID() const;
//virtual UClassID getDynamicClassID() const;
/**
* ICU "poor man's RTTI", returns a UClassID for this class.
*/
static UClassID U_EXPORT2 getStaticClassID();
U_I18N_API static UClassID U_EXPORT2 getStaticClassID();
protected:
/**

View file

@ -1,8 +1,7 @@
/*
*******************************************************************************
*
* Copyright (C) 2001-2007, International Business Machines
* Copyright (C) 2001-2008, International Business Machines
* Corporation and others. All Rights Reserved.
*
*******************************************************************************
@ -214,7 +213,7 @@ allocation_failure:
return NULL;
}
U_CAPI tempUCATable* U_EXPORT2
static tempUCATable* U_EXPORT2
uprv_uca_cloneTempTable(tempUCATable *t, UErrorCode *status) {
if(U_FAILURE(*status)) {
return NULL;
@ -1880,7 +1879,7 @@ uprv_uca_addTailCanonicalClosures(tempUCATable *t,
}
}
U_CAPI int32_t U_EXPORT2
U_CFUNC int32_t U_EXPORT2
uprv_uca_canonicalClosure(tempUCATable *t,
UColTokenParser *src,
UErrorCode *status)

View file

@ -1,7 +1,7 @@
/*
*******************************************************************************
*
* Copyright (C) 2000-2006, International Business Machines
* Copyright (C) 2000-2008, International Business Machines
* Corporation and others. All Rights Reserved.
*
*******************************************************************************
@ -132,12 +132,10 @@ typedef struct {
}tempTailorContext;
U_CAPI tempUCATable * U_EXPORT2 uprv_uca_initTempTable(UCATableHeader *image, UColOptionSet *opts, const UCollator *UCA, UColCETags initTag, UColCETags supplementaryInitTag, UErrorCode *status);
U_CAPI tempUCATable * U_EXPORT2 uprv_uca_cloneTempTable(tempUCATable *t, UErrorCode *status);
U_CAPI void U_EXPORT2 uprv_uca_closeTempTable(tempUCATable *t);
U_CAPI uint32_t U_EXPORT2 uprv_uca_addAnElement(tempUCATable *t, UCAElements *element, UErrorCode *status);
U_CAPI UCATableHeader * U_EXPORT2 uprv_uca_assembleTable(tempUCATable *t, UErrorCode *status);
U_CAPI int32_t U_EXPORT2
uprv_uca_canonicalClosure(tempUCATable *t, UColTokenParser *src, UErrorCode *status);
U_CAPI int32_t U_EXPORT2 uprv_uca_canonicalClosure(tempUCATable *t, UColTokenParser *src, UErrorCode *status);
#define paddedsize(something) ((something)+((((something)%4)!=0)?(4-(something)%4):0))
#define headersize (paddedsize(sizeof(UCATableHeader))+paddedsize(sizeof(UColOptionSet)))

View file

@ -1,7 +1,7 @@
/*
*******************************************************************************
*
* Copyright (C) 1998-2007, International Business Machines
* Copyright (C) 1998-2008, International Business Machines
* Corporation and others. All Rights Reserved.
*
*******************************************************************************
@ -479,7 +479,7 @@ ucol_getSortKeySize(const UCollator *coll, collIterate *s,
* @return memory, owned by the caller, of size 'length' bytes.
* @internal INTERNAL USE ONLY
*/
U_CAPI uint8_t* U_EXPORT2
U_CFUNC uint8_t* U_EXPORT2
ucol_cloneRuleData(const UCollator *coll, int32_t *length, UErrorCode *status);
/**

View file

@ -1,7 +1,7 @@
/*
*******************************************************************************
*
* Copyright (C) 2001-2007, International Business Machines
* Copyright (C) 2001-2008, International Business Machines
* Corporation and others. All Rights Reserved.
*
*******************************************************************************
@ -170,12 +170,12 @@ U_CAPI int32_t U_EXPORT2 ucol_inv_getNextCE(const UColTokenParser *src,
uint32_t CE, uint32_t contCE,
uint32_t *nextCE, uint32_t *nextContCE,
uint32_t strength);
U_CAPI int32_t U_EXPORT2 ucol_inv_getPrevCE(const UColTokenParser *src,
U_CFUNC int32_t U_EXPORT2 ucol_inv_getPrevCE(const UColTokenParser *src,
uint32_t CE, uint32_t contCE,
uint32_t *prevCE, uint32_t *prevContCE,
uint32_t strength);
U_CAPI uint32_t U_EXPORT2 ucol_getCEStrengthDifference(uint32_t CE, uint32_t contCE,
U_CFUNC uint32_t U_EXPORT2 ucol_getCEStrengthDifference(uint32_t CE, uint32_t contCE,
uint32_t prevCE, uint32_t prevContCE);

View file

@ -1,6 +1,6 @@
/*
**********************************************************************
* Copyright (c) 2002-2007, International Business Machines
* Copyright (c) 2002-2008, International Business Machines
* Corporation and others. All Rights Reserved.
**********************************************************************
*/
@ -544,7 +544,7 @@ ucurr_getName(const UChar* currency,
return currency;
}
U_CAPI void
U_CFUNC void
uprv_parseCurrency(const char* locale,
const U_NAMESPACE_QUALIFIER UnicodeString& text,
U_NAMESPACE_QUALIFIER ParsePosition& pos,
@ -684,7 +684,7 @@ uprv_parseCurrency(const char* locale,
* This is used for backward compatibility with old currency logic in
* DecimalFormat and DecimalFormatSymbols.
*/
U_CAPI void
U_CFUNC void
uprv_getStaticCurrencyName(const UChar* iso, const char* loc,
U_NAMESPACE_QUALIFIER UnicodeString& result, UErrorCode& ec)
{

View file

@ -1,6 +1,6 @@
/*
**********************************************************************
* Copyright (c) 2002-2006, International Business Machines
* Copyright (c) 2002-2008, International Business Machines
* Corporation and others. All Rights Reserved.
**********************************************************************
*/
@ -22,7 +22,7 @@
* This is used for backward compatibility with old currency logic in
* DecimalFormat and DecimalFormatSymbols.
*/
U_CAPI void
U_CFUNC void
uprv_getStaticCurrencyName(const UChar* iso, const char* loc,
U_NAMESPACE_QUALIFIER UnicodeString& result, UErrorCode& ec);
@ -45,7 +45,7 @@ uprv_getStaticCurrencyName(const UChar* iso, const char* loc,
*
* @internal
*/
U_CAPI void
U_CFUNC void
uprv_parseCurrency(const char* locale,
const U_NAMESPACE_QUALIFIER UnicodeString& text,
U_NAMESPACE_QUALIFIER ParsePosition& pos,

View file

@ -307,7 +307,7 @@ void UObjectTest::testIDs()
TESTCLASSID_TRANSLIT(UnescapeTransliterator, "Hex-Any");
TESTCLASSID_TRANSLIT(UnicodeNameTransliterator, "Any-Name");
TESTCLASSID_TRANSLIT(UppercaseTransliterator, "Upper");
TESTCLASSID_CTOR(CaseMapTransliterator, (UnicodeString(), NULL));
TESTCLASSID_ABSTRACT(CaseMapTransliterator);
TESTCLASSID_ABSTRACT(Transliterator);
TESTCLASSID_FACTORY_HIDDEN(TransliteratorRegistry::Enumeration, Transliterator::getAvailableIDs(status));