.. _package-rst-generic:
=====================
Package rst.generic
=====================
Message which are capable of handling dynamic data types.
This is not the preferred way of using RST, but cannot be avoided in certain
cases. If possible, use semantically-defined data types.
Messages
========
.. container:: mess4ge-multi
.. container:: mess4ge-graph
.. digraph:: message_graph
fontname="Arial";
fontsize=11;
stylesheet="../_static/graphs.css";
node [fontsize=11,fontname="Arial"]
edge [fontsize=11,fontname="Arial"]
"6" [label=<
| MethodCall |
|
OCTET-VECTOR | name |
Value | arguments |
>,shape=box,style=filled,fillcolor="white"];
"1" [label=< | KeyValuePair |
|
ASCII-STRING | key |
Value | value |
>,shape=box,style=filled,fillcolor="white"];
"2" [label=< | Value |
|
Type | type |
INT64 | int |
FLOAT64 | double |
ASCII-STRING | string |
BOOL | bool |
OCTET-VECTOR | binary |
Value | array |
>,shape=box,style=filled,fillcolor="white"];
"4" [label=< | Value |
|
Type | type |
INT64 | int |
FLOAT64 | double |
ASCII-STRING | string |
BOOL | bool |
OCTET-VECTOR | binary |
>,shape=box,style=filled,fillcolor="white"];
"5" [label=< | Type |
|
VOID | 1 |
INT | 2 |
DOUBLE | 3 |
STRING | 4 |
BOOL | 5 |
BINARY | 6 |
ARRAY | 7 |
>,shape=box,style=filled,fillcolor="white"];
"3" [label=< | Type |
|
VOID | 1 |
INT | 2 |
DOUBLE | 3 |
STRING | 4 |
BOOL | 5 |
BINARY | 6 |
ARRAY | 7 |
>,shape=box,style=filled,fillcolor="white"];
"6":arguments -> "2" [];
"1":value -> "2" [];
"2" -> "3" [];
"2":array -> "4" [];
"2":type -> "3" [];
"4" -> "5" [];
"4":type -> "5" [];
.. container:: mess4ge-list
.. container:: messages
* :ref:`KeyValuePair `
* :ref:`MethodCall `
* :ref:`Value `
.. container:: clearer
clearer: should be made invisible via css
.. _message-rst-generic-keyvaluepair:
Message KeyValuePair
--------------------
.. container:: message-rst-generic-keyvaluepair-multi
.. container:: message-rst-generic-keyvaluepair-documentation
.. py:class:: rst.generic.KeyValuePair
Combines a generic value with an identifying string key.
.. codeauthor:: Arne Nordmann
.. py:attribute:: key
:type: :py:class:`ASCII-STRING`
The key of this entry.
.. py:attribute:: value
:type: :py:class:`rst.generic.Value`
The value.
.. container:: message-rst-generic-keyvaluepair-source
:download:`Download this file /home/jenkins/workspace/rst-manual-0.12/rst-manual/../rst-proto/proto/stable/rst/generic/KeyValuePair.proto>`
.. literalinclude:: //home/jenkins/workspace/rst-manual-0.12/rst-manual/../rst-proto/proto/stable/rst/generic/KeyValuePair.proto
:lines: 12-24
:language: protobuf
:emphasize-lines: 6-6,11-11
.. _message-rst-generic-methodcall:
Message MethodCall
------------------
.. container:: message-rst-generic-methodcall-multi
.. container:: message-rst-generic-methodcall-documentation
.. py:class:: rst.generic.MethodCall
Represents a call to a named method with multiple as arguments.
.. codeauthor:: Johannes Wienke
.. py:attribute:: name
:type: :py:class:`OCTET-VECTOR`
Name of the method to call.
ASCII string.
.. py:attribute:: arguments
:type: array of :py:class:`rst.generic.Value`
The method arguments.
.. container:: message-rst-generic-methodcall-source
:download:`Download this file /home/jenkins/workspace/rst-manual-0.12/rst-manual/../rst-proto/proto/stable/rst/generic/MethodCall.proto>`
.. literalinclude:: //home/jenkins/workspace/rst-manual-0.12/rst-manual/../rst-proto/proto/stable/rst/generic/MethodCall.proto
:lines: 12-26
:language: protobuf
:emphasize-lines: 8-8,13-13
.. _message-rst-generic-value:
Message Value
-------------
.. container:: message-rst-generic-value-multi
.. container:: message-rst-generic-value-documentation
.. py:class:: rst.generic.Value
A representation of a generic value with a dynamic type.
Each value has a declared type in :py:attr:`type ` indicating which of the
remaining type-specific fields contains the value, expect for
:ref:`VOID `, where no value is transported at all (most useful for return
types).
.. codeauthor:: Johannes Wienke
A representation of a generic value with a dynamic type.
Each value has a declared type in :py:attr:`type ` indicating which of the
remaining type-specific fields contains the value, expect for
:ref:`VOID `, where no value is transported at all (most useful for return
types).
.. codeauthor:: Johannes Wienke
.. py:attribute:: type
:type: :py:class:`rst.generic.Value.Type`
The type of the value transported in this message.
.. py:attribute:: int
:type: :py:class:`INT64`
*Not documented*
.. py:attribute:: double
:type: :py:class:`FLOAT64`
*Not documented*
.. py:attribute:: string
:type: :py:class:`ASCII-STRING`
*Not documented*
.. py:attribute:: bool
:type: :py:class:`BOOL`
*Not documented*
.. py:attribute:: binary
:type: :py:class:`OCTET-VECTOR`
*Not documented*
.. py:attribute:: array
:type: array of :py:class:`Value`
Contained elements can be of different types and ordering is important.
.. container:: message-rst-generic-value-source
:download:`Download this file /home/jenkins/workspace/rst-manual-0.12/rst-manual/../rst-proto/proto/stable/rst/generic/Value.proto>`
.. literalinclude:: //home/jenkins/workspace/rst-manual-0.12/rst-manual/../rst-proto/proto/stable/rst/generic/Value.proto
:lines: 15-49
:language: protobuf
:emphasize-lines: 23-23,25-25,26-26,27-27,28-28,29-29,33-33
.. _message-rst-generic-value-type:
Message Type
------------
.. container:: message-rst-generic-value-type-multi
.. container:: message-rst-generic-value-type-documentation
.. py:class:: rst.generic.Value.Type
The list of supported types.
.. py:attribute:: VOID
= 1
*Not documented*
.. py:attribute:: INT
= 2
*Not documented*
.. py:attribute:: DOUBLE
= 3
*Not documented*
.. py:attribute:: STRING
= 4
*Not documented*
.. py:attribute:: BOOL
= 5
*Not documented*
.. py:attribute:: BINARY
= 6
*Not documented*
.. py:attribute:: ARRAY
= 7
Indicate that a list of Values is contained in
representing an array.
.. container:: message-rst-generic-value-type-source
:download:`Download this file /home/jenkins/workspace/rst-manual-0.12/rst-manual/../rst-proto/proto/stable/rst/generic/Value.proto>`
.. literalinclude:: //home/jenkins/workspace/rst-manual-0.12/rst-manual/../rst-proto/proto/stable/rst/generic/Value.proto
:lines: 20-32
:language: protobuf
:emphasize-lines: 2-2,3-3,4-4,5-5,6-6,7-7,12-12