[API CHANGE] Remove unused css.resource.XLocale
It had been present ever since at least 88c437c597b604524d50f450506285a594bd03a5 "moved from api" from 2000, but was apparently never implemented nor used at least in OOo/LO itself. It is problematic as it uses reserved identifiers ("getDisplayLanguage_Default" etc.) that contain underscores and start with a lowercase letter, and a planned change to unoidl-write will no longer tolerate usage of such reserved identifiers (see the TODO in unoidl/source/sourceprovider-scanner.l). Change-Id: I76a3a3da7b7c1f4c109ca7a12c9f07857ca1be1d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/123544 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
This commit is contained in:
parent
58c3dab9e3
commit
a74d15adce
@ -3119,7 +3119,6 @@ $(eval $(call gb_UnoApi_add_idlfiles,offapi,com/sun/star/report/meta,\
|
|||||||
))
|
))
|
||||||
$(eval $(call gb_UnoApi_add_idlfiles,offapi,com/sun/star/resource,\
|
$(eval $(call gb_UnoApi_add_idlfiles,offapi,com/sun/star/resource,\
|
||||||
MissingResourceException \
|
MissingResourceException \
|
||||||
XLocale \
|
|
||||||
XStringResourceManager \
|
XStringResourceManager \
|
||||||
XStringResourcePersistence \
|
XStringResourcePersistence \
|
||||||
XStringResourceResolver \
|
XStringResourceResolver \
|
||||||
|
@ -1,208 +0,0 @@
|
|||||||
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
|
|
||||||
/*
|
|
||||||
* This file is part of the LibreOffice project.
|
|
||||||
*
|
|
||||||
* This Source Code Form is subject to the terms of the Mozilla Public
|
|
||||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
|
||||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
|
||||||
*
|
|
||||||
* This file incorporates work covered by the following license notice:
|
|
||||||
*
|
|
||||||
* Licensed to the Apache Software Foundation (ASF) under one or more
|
|
||||||
* contributor license agreements. See the NOTICE file distributed
|
|
||||||
* with this work for additional information regarding copyright
|
|
||||||
* ownership. The ASF licenses this file to you under the Apache
|
|
||||||
* License, Version 2.0 (the "License"); you may not use this file
|
|
||||||
* except in compliance with the License. You may obtain a copy of
|
|
||||||
* the License at http://www.apache.org/licenses/LICENSE-2.0 .
|
|
||||||
*/
|
|
||||||
#ifndef __com_sun_star_resource_XLocale_idl__
|
|
||||||
#define __com_sun_star_resource_XLocale_idl__
|
|
||||||
|
|
||||||
#include <com/sun/star/uno/XInterface.idl>
|
|
||||||
|
|
||||||
#include <com/sun/star/lang/Locale.idl>
|
|
||||||
|
|
||||||
#include <com/sun/star/resource/MissingResourceException.idl>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
module com { module sun { module star { module resource {
|
|
||||||
|
|
||||||
/** offers some operations on com::sun::star::lang::Locale
|
|
||||||
structures.
|
|
||||||
@see Locale
|
|
||||||
*/
|
|
||||||
published interface XLocale: com::sun::star::uno::XInterface
|
|
||||||
{
|
|
||||||
/** creates a locale from language, country, and variant.
|
|
||||||
|
|
||||||
<p>NOTE: ISO 639 is not a stable standard; some of the
|
|
||||||
language codes it defines (specifically iw, ji, and in) have
|
|
||||||
changed. This constructor accepts both the old codes (iw, ji,
|
|
||||||
and in) and the new codes (he, yi, and id), but all other API
|
|
||||||
on XLocale will return only the <b>NEW</b> codes.
|
|
||||||
</p>
|
|
||||||
<p>Note: The Java class <code>Locale</code> returns the <strong>old</strong> codes.
|
|
||||||
|
|
||||||
</p>
|
|
||||||
*/
|
|
||||||
com::sun::star::lang::Locale create( [in] string aLanguage,
|
|
||||||
[in] string aCountry,
|
|
||||||
[in] string aVariant );
|
|
||||||
|
|
||||||
/** the common method of getting the current default locale.
|
|
||||||
|
|
||||||
<p>It is used for the presentation (for menus, dialogs, etc.).
|
|
||||||
It is, generally, set once when your applet or application is
|
|
||||||
initialized, then never reset. (If you do reset the default
|
|
||||||
locale, you probably want to reload your GUI, so that the
|
|
||||||
change is reflected in your interface.)
|
|
||||||
</p>
|
|
||||||
<p>More advanced programs allow users to use different locales
|
|
||||||
for different fields, for example, in a spreadsheet.
|
|
||||||
|
|
||||||
<br>Note that the initial setting will match the host system.</p>
|
|
||||||
*/
|
|
||||||
com::sun::star::lang::Locale getDefault();
|
|
||||||
|
|
||||||
/** sets the default locale for the whole environment.
|
|
||||||
|
|
||||||
<p>It is normally set once at the beginning of an application,
|
|
||||||
then never reset. <code>setDefault</code> does not reset the host
|
|
||||||
locale.
|
|
||||||
|
|
||||||
</p>
|
|
||||||
*/
|
|
||||||
void setDefault( [in] com::sun::star::lang::Locale newLocale );
|
|
||||||
|
|
||||||
/** @returns
|
|
||||||
a sequence of all locales which are available in the system.
|
|
||||||
*/
|
|
||||||
sequence<com::sun::star::lang::Locale> getAvailableLocales();
|
|
||||||
|
|
||||||
/** @returns
|
|
||||||
a sequence of all ISO country codes known to the component.
|
|
||||||
*/
|
|
||||||
sequence<string> getISOCountries();
|
|
||||||
|
|
||||||
/** @returns
|
|
||||||
a sequence of all ISO language codes known to the component.
|
|
||||||
*/
|
|
||||||
sequence<string> getISOLanguages();
|
|
||||||
|
|
||||||
/** @returns
|
|
||||||
a sequence for language codes which are valid within the
|
|
||||||
given country.
|
|
||||||
*/
|
|
||||||
sequence<string> getLanguagesForCountry( [in] string country );
|
|
||||||
|
|
||||||
/** @returns
|
|
||||||
the ISO language code for the specified locale.
|
|
||||||
*/
|
|
||||||
string getISO3Language( [in] com::sun::star::lang::Locale locale )
|
|
||||||
raises( com::sun::star::resource::MissingResourceException );
|
|
||||||
|
|
||||||
/** @returns
|
|
||||||
the ISO country code for the specified locale.
|
|
||||||
*/
|
|
||||||
string getISO3Country( [in] com::sun::star::lang::Locale locale )
|
|
||||||
raises( com::sun::star::resource::MissingResourceException );
|
|
||||||
|
|
||||||
/** @returns
|
|
||||||
language code for display of field to user. If the localized
|
|
||||||
name is not found, returns the ISO code. The desired user language
|
|
||||||
is from the default locale.
|
|
||||||
*/
|
|
||||||
string getDisplayLanguage_Default( [in] com::sun::star::lang::Locale locale );
|
|
||||||
|
|
||||||
|
|
||||||
/** @return
|
|
||||||
language code for display of field to user. If the localized
|
|
||||||
name is not found, returns the ISO codes.
|
|
||||||
|
|
||||||
@param locale the locale.
|
|
||||||
|
|
||||||
@param inLocale
|
|
||||||
specifies the desired user language.
|
|
||||||
*/
|
|
||||||
string getDisplayLanguage( [in] com::sun::star::lang::Locale locale,
|
|
||||||
[in] com::sun::star::lang::Locale inLocale );
|
|
||||||
|
|
||||||
/** @returns
|
|
||||||
country code for display of field to user. If the localized
|
|
||||||
name is not found, returns the ISO code. The desired user country
|
|
||||||
is from the default locale.
|
|
||||||
*/
|
|
||||||
string getDisplayCountry_Default( [in] com::sun::star::lang::Locale locale );
|
|
||||||
|
|
||||||
/** @returns
|
|
||||||
country code for display of field to user. If the localized
|
|
||||||
name is not found, returns the ISO codes.
|
|
||||||
|
|
||||||
@param locale the locale.
|
|
||||||
|
|
||||||
@param inLocale
|
|
||||||
specifies the desired user country.
|
|
||||||
*/
|
|
||||||
string getDisplayCountry( [in] com::sun::star::lang::Locale locale,
|
|
||||||
[in] com::sun::star::lang::Locale inLocale );
|
|
||||||
|
|
||||||
/** @returns
|
|
||||||
variant code for display of field to user. The desired user variant
|
|
||||||
is from the default locale.
|
|
||||||
*/
|
|
||||||
string getDisplayVariant_Default( [in] com::sun::star::lang::Locale locale );
|
|
||||||
|
|
||||||
/** @returns
|
|
||||||
variant code for display of field to user. If the localized
|
|
||||||
name is not found, returns the ISO codes.
|
|
||||||
|
|
||||||
@param locale the locale.
|
|
||||||
|
|
||||||
@param inLocale
|
|
||||||
specifies the desired user variant.
|
|
||||||
*/
|
|
||||||
string getDisplayVariant( [in] com::sun::star::lang::Locale locale,
|
|
||||||
[in] com::sun::star::lang::Locale inLocale );
|
|
||||||
|
|
||||||
/** @returns
|
|
||||||
a string to display the entire locale to user. If the localized
|
|
||||||
name is not found, uses the ISO codes. The default locale is used
|
|
||||||
for the presentation language.
|
|
||||||
|
|
||||||
@param locale the locale.
|
|
||||||
*/
|
|
||||||
string getDisplayName_Default( [in] com::sun::star::lang::Locale locale );
|
|
||||||
|
|
||||||
/** @returns
|
|
||||||
a string to display the entire locale to user. If the localized
|
|
||||||
name is not found, uses the ISO codes.
|
|
||||||
|
|
||||||
@param locale the locale.
|
|
||||||
|
|
||||||
@param inLocale
|
|
||||||
specifies the desired user locale.
|
|
||||||
*/
|
|
||||||
string getDisplayName( [in] com::sun::star::lang::Locale locale,
|
|
||||||
[in] com::sun::star::lang::Locale inLocale );
|
|
||||||
|
|
||||||
/** @returns
|
|
||||||
`TRUE` if the com::sun::star::lang::Locale <var>l1</var> is equal to the
|
|
||||||
other one.
|
|
||||||
|
|
||||||
<p>A locale is deemed equal to another locale with identical
|
|
||||||
language, country, and variant, and unequal to all other
|
|
||||||
objects.
|
|
||||||
*/
|
|
||||||
boolean equals( [in] com::sun::star::lang::Locale l1,
|
|
||||||
[in] com::sun::star::lang::Locale l2 );
|
|
||||||
|
|
||||||
};
|
|
||||||
|
|
||||||
|
|
||||||
}; }; }; };
|
|
||||||
|
|
||||||
#endif
|
|
||||||
|
|
||||||
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
|
|
@ -9766,27 +9766,6 @@ module com {
|
|||||||
module resource {
|
module resource {
|
||||||
published exception MissingResourceException: ::com::sun::star::uno::RuntimeException {
|
published exception MissingResourceException: ::com::sun::star::uno::RuntimeException {
|
||||||
};
|
};
|
||||||
published interface XLocale {
|
|
||||||
interface ::com::sun::star::uno::XInterface;
|
|
||||||
::com::sun::star::lang::Locale create([in] string aLanguage, [in] string aCountry, [in] string aVariant);
|
|
||||||
::com::sun::star::lang::Locale getDefault();
|
|
||||||
void setDefault([in] ::com::sun::star::lang::Locale newLocale);
|
|
||||||
sequence< ::com::sun::star::lang::Locale > getAvailableLocales();
|
|
||||||
sequence< string > getISOCountries();
|
|
||||||
sequence< string > getISOLanguages();
|
|
||||||
sequence< string > getLanguagesForCountry([in] string country);
|
|
||||||
string getISO3Language([in] ::com::sun::star::lang::Locale locale) raises (::com::sun::star::resource::MissingResourceException);
|
|
||||||
string getISO3Country([in] ::com::sun::star::lang::Locale locale) raises (::com::sun::star::resource::MissingResourceException);
|
|
||||||
string getDisplayLanguage_Default([in] ::com::sun::star::lang::Locale locale);
|
|
||||||
string getDisplayLanguage([in] ::com::sun::star::lang::Locale locale, [in] ::com::sun::star::lang::Locale inLocale);
|
|
||||||
string getDisplayCountry_Default([in] ::com::sun::star::lang::Locale locale);
|
|
||||||
string getDisplayCountry([in] ::com::sun::star::lang::Locale locale, [in] ::com::sun::star::lang::Locale inLocale);
|
|
||||||
string getDisplayVariant_Default([in] ::com::sun::star::lang::Locale locale);
|
|
||||||
string getDisplayVariant([in] ::com::sun::star::lang::Locale locale, [in] ::com::sun::star::lang::Locale inLocale);
|
|
||||||
string getDisplayName_Default([in] ::com::sun::star::lang::Locale locale);
|
|
||||||
string getDisplayName([in] ::com::sun::star::lang::Locale locale, [in] ::com::sun::star::lang::Locale inLocale);
|
|
||||||
boolean equals([in] ::com::sun::star::lang::Locale l1, [in] ::com::sun::star::lang::Locale l2);
|
|
||||||
};
|
|
||||||
};
|
};
|
||||||
module scanner {
|
module scanner {
|
||||||
published enum ScanError {
|
published enum ScanError {
|
||||||
|
@ -33,16 +33,6 @@ module com { module sun { module star { module lang {
|
|||||||
displaying a number is a locale-sensitive operation; the number
|
displaying a number is a locale-sensitive operation; the number
|
||||||
should be formatted according to the customs/conventions of the
|
should be formatted according to the customs/conventions of the
|
||||||
user's native country, region, or culture. </p>
|
user's native country, region, or culture. </p>
|
||||||
|
|
||||||
<p> Because a <code>Locale</code> object is just an identifier for a
|
|
||||||
region, no validity check is performed. If you want to see whether
|
|
||||||
particular resources are available for the <code>Locale</code>, use
|
|
||||||
the com::sun::star::resource::XLocale::getAvailableLocales() method to ask for the
|
|
||||||
locales it supports.</p>
|
|
||||||
|
|
||||||
<p> Each implementation that performs locale-sensitive operations
|
|
||||||
allows you to get all the available objects of that type. Use the
|
|
||||||
com::sun::star::resource::XLocale interface to set the locale. </p>
|
|
||||||
*/
|
*/
|
||||||
published struct Locale
|
published struct Locale
|
||||||
{
|
{
|
||||||
|
Loading…
x
Reference in New Issue
Block a user