| IOLink Python 1.11.0

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

## Public Member Functions
| __init__ (self, *args, **kwargs)
| open_stream_access (self, resourceId, capabilities)
| open_random_access (self, resourceId, capabilities)
| get_source (self)

## Properties
| thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
| source = property(get_source, doc=get_source.__doc__)

## Detailed Description

    Describes a data source, that manages and opens DataAccess instances.

## Member Function Documentation

## ◆ get_source()

iolink.iolink.DataStorage.get_source | ( |  | self | ) |

        Return a string that describe the storage's source of data.

        Usually has the form of an URI, for example:
         - "file:/home/user/folder" for a filesystem storage
         - "http://amazing.website.net" for an HTTP storage

## ◆ open_random_access()

iolink.iolink.DataStorage.open_random_access | ( |  | self,
|  |  | resourceId,
|  |  | capabilities
| ) |  |

        Open an array-like accessor to a given resource.

        :type resourceId: string
        :param resourceId: The resource name
        :type capabilities: int
        :param capabilities: The capabilities you want the accessor to support

        :rtype: std::shared_ptr< RandomAccess >
        :return: The opened random-access accessor.

        :raises: Error if the storage can not access to the resource.
        :raises: Error if the resource does not support the request capabilities.

        See also: DataAccess::resourceId for more info on this identifier.

## ◆ open_stream_access()

iolink.iolink.DataStorage.open_stream_access | ( |  | self,
|  |  | resourceId,
|  |  | capabilities
| ) |  |

        Open a stream-like accessor to a given resource.

        :type resourceId: string
        :param resourceId: The resource name
        :type capabilities: int
        :param capabilities: The capabilities you want the accessor to support

        :rtype: std::shared_ptr< StreamAccess >
        :return: The opened stream accessor.

        :raises: Error if the storage can not access to the resource.
        :raises: Error if the resource does not support the requested capabilities.

        See also: DataAccess::resourceId for more info on this identifier.

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

- Release/python/iolink/iolink.py