| IOLink Python 1.11.0

Loading...
Searching...
No Matches
Public Member Functions | Static Public Attributes | Properties | List of all members
iolink.iolink.VariantDataValue Class Reference
Inheritance diagram for iolink.iolink.VariantDataValue:

## Public Member Functions
| __init__ (self, *args, **kwargs)
| clone (self)
| get_type (self)
| get_count (self)
| raw (self)
| __getitem__ (self, key)
| __repr__ (self)

## Static Public Attributes
int | indexStart = 0
int | indexStop = 0
| indexStart = key.start
| indexStop = self.count
list | result = []

## Properties
| thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
| type = property(get_type, doc=get_type.__doc__)
| count = property(get_count, doc=get_count.__doc__)

## Detailed Description

    Stores metadata heterogeneous type value.

    This interfaces only give access to the type of data stored, and how many
    of elements are stored. Values can be accessed by casting the raw pointer to
    the corresponding type.

## Member Function Documentation

## ◆ __getitem__()

iolink.iolink.VariantDataValue.__getitem__ | ( |  | self,
|  |  | key
| ) |  |

    Returns the n-th value stored.
    For Datatype instances with a dimension greater than one, this method will
    return value as if the type was the corresponding scalar type.
    Example: A VariantDataValue stores two Vector3u64, (1, 2, 3) and (4, 5, 6).
      calling value[0] will return 1, value[2] will return 3, and value[4]
      will return 5.

## ◆ clone()

iolink.iolink.VariantDataValue.clone | ( |  | self | ) |

    Copies this value.

## ◆ get_count()

iolink.iolink.VariantDataValue.get_count | ( |  | self | ) |

    Returns the number of values of the specified type stored.

## ◆ get_type()

iolink.iolink.VariantDataValue.get_type | ( |  | self | ) |

    Returns the type of the values stored.

## ◆ raw()

iolink.iolink.VariantDataValue.raw | ( |  | self | ) |

        Returns a pointer to the location where all the values are stored continuously.

        To ease raw value decoding, a helper called VariantDataValueConverter is available
        to simply convert this VariantDataValue to basic types.

        See also: VariantDataValueConverter

The documentation for this class was generated from the following file:

- Release/python/iolink/iolink.py