Skip to content

Commit 1eb7aba

Browse files
Jenkinsopenstack-gerrit
authored andcommitted
Merge "Add i18n module to openstackclient"
2 parents 97d1bbd + 258798c commit 1eb7aba

1 file changed

Lines changed: 31 additions & 0 deletions

File tree

‎openstackclient/i18n.py‎

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
# Copyright 2012-2013 OpenStack Foundation
2+
#
3+
# Licensed under the Apache License, Version 2.0 (the "License"); you may
4+
# not use this file except in compliance with the License. You may obtain
5+
# a copy of the License at
6+
#
7+
# http://www.apache.org/licenses/LICENSE-2.0
8+
#
9+
# Unless required by applicable law or agreed to in writing, software
10+
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
11+
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
12+
# License for the specific language governing permissions and limitations
13+
# under the License.
14+
#
15+
16+
from oslo import i18n
17+
18+
_translators = i18n.TranslatorFactory(domain='openstackclient')
19+
20+
# The primary translation function using the well-known name "_"
21+
_ = _translators.primary
22+
23+
# Translators for log levels.
24+
#
25+
# The abbreviated names are meant to reflect the usual use of a short
26+
# name like '_'. The "L" is for "log" and the other letter comes from
27+
# the level.
28+
_LI = _translators.log_info
29+
_LW = _translators.log_warning
30+
_LE = _translators.log_error
31+
_LC = _translators.log_critical

0 commit comments

Comments
 (0)