29 #ifndef __SB_STRINGBUNDLE_H__
30 #define __SB_STRINGBUNDLE_H__
46 #include <sbIStringBundleService.h>
50 #include <nsCOMArray.h>
52 #include <nsIStringBundle.h>
126 nsString
Get(
const nsAString& aKey,
129 nsString
Get(
const char* aKey,
130 const char* aDefault = nsnull);
146 nsString
Format(
const nsAString& aKey,
147 nsTArray<nsString>& aParams,
150 nsString
Format(
const char* aKey,
151 nsTArray<nsString>& aParams,
152 const char* aDefault = nsnull);
154 nsString
Format(
const nsAString& aKey,
155 const nsAString& aParam,
158 nsString
Format(
const char* aKey,
159 const nsAString& aParam,
160 const char* aDefault = nsnull);
176 nsCOMPtr<sbIStringBundleService>
177 mStringBundleService;
178 nsCOMArray<nsIStringBundle> mBundleList;
185 nsresult LoadBundle(
const char* aURI);
187 nsresult LoadBundle(nsIStringBundle* aBundle);
189 nsresult ApplySubstitutions(nsAString& aString);
193 #endif // __SB_STRINGBUNDLE_H__
nsString Get(const nsAString &aKey, const nsAString &aDefault=SBVoidString())
nsString Format(const nsAString &aKey, nsTArray< nsString > &aParams, const nsAString &aDefault=SBVoidString())