File: LocalizableMessage.rst

package info (click to toggle)
python-pyvmomi 6.7.1-3
  • links: PTS, VCS
  • area: main
  • in suites: bullseye
  • size: 14,980 kB
  • sloc: python: 9,206; xml: 77; makefile: 9
file content (67 lines) | stat: -rw-r--r-- 2,285 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
.. _str: https://docs.python.org/2/library/stdtypes.html

.. _message: ../vmodl/LocalizableMessage.rst#message

.. _vSphere API 4.0: ../vim/version.rst#vmodlversionversion1

.. _vmodl.KeyAnyValue: ../vmodl/KeyAnyValue.rst

.. _vmodl.DynamicData: ../vmodl/DynamicData.rst

.. _LocalizableMessage: ../vmodl/LocalizableMessage.rst


vmodl.LocalizableMessage
========================
  Message data which is intended to be displayed according to the locale of a client.A `LocalizableMessage`_ contains both a formatted, localized version of the text and the data needed to perform localization in conjunction with localization catalogs.Clients of the VIM API may use vim.SessionManager.setLocale() to cause the server to emit a localized `message`_ , or may perform client-side localization based on message catalogs provided by the server.
   * If the substition variable is a string, no further lookup is required.
   * 
   * `arg`_
   * = [("address" = "127.0.0.1")]
   * CATALOG(locmsg,
   * `key`_
   * ) = "IP address is {address}"
   * ==
   * 
   * `message`_
   * = "IP address is 127.0.0.1"
   * If the substitution variable is an integer, value is a lookup key.
   * 
   * `arg`_
   * = [("1" = "button.cancel"), ("2" = "msg.revert")]
   * CATALOG(locmsg,
   * `key`_
   * ) = "Select '{1}' to {2}"
   * CATALOG(locmsg, button.cancel) = "Cancel"
   * CATALOG(locmsg, msg.revert) = "revert"
   * ==
   * 
   * `message`_
   * = "Select 'Cancel' to revert"
   * If the variable contains '@', value is a label lookup in another catalog, where {name.@CATALOG.prefix} looks up prefix.
   * `arg`_
   * [name].label in CATALOG.
   * 
   * `arg`_
   * = [("field" = "queued")]
   * CATALOG(locmsg,
   * `key`_
   * ) = "State is {field.@enum.TaskInfo.State}"
   * CATALOG(enum, TaskInfo.State.queued.label) is "Queued"
   * ==
   * 
   * `message`_
   * = "State is Queued"
:extends: vmodl.DynamicData_
:since: `vSphere API 4.0`_

Attributes:
    key (`str`_):

       Unique key identifying the message in the localized message catalog.
    arg ([`vmodl.KeyAnyValue`_], optional):

       Substitution arguments for variables in the localized message.
    message (`str`_, optional):

       Message in session locale. Use vim.SessionManager.setLocale() to change the session locale.