arjuna.tpi.data.reference module

class arjuna.tpi.data.reference.ContextualDataReference(path)

Bases: object

Base class for autoloaded Contextual data references in Arjuna.

Parameters

path – Path of the contextual data reference file.

Note

It behaves like a Python dictionary. So, you get items by names/keys and loop over it.

as_json()
enumerate()

Print all items in this data reference.

items()

Items iterator for this reference.

keys()

Names of contexts/keys in this reference.

property name

Name of this reference.

property path

Path of this reference file.

class arjuna.tpi.data.reference.IndexedDataReference(pydict)

Bases: object

Base class for autoloaded Indexed Data References in Arjuna.

Parameters

pydict – A python repr of a list with indices as keys.

Note

It behaves like a Python tuple. So, you get items by index and loop over it.

enumerate()

Print all items in this data reference.

first()

First item in this data reference.

last()

Last item in this data reference.

random()

Random item in this data reference.