simphony / simphony-mayavi

The mayavi adapters to the simphony framework
BSD 2-Clause "Simplified" License
0 stars 1 forks source link

Implement CUDSDataExtractor #15

Closed itziakos closed 9 years ago

itziakos commented 9 years ago

A CUDSDataSelector is a class that operates on a CUDS container item iterator is described as follows:


class CUDSDataExtractor(HasStrictTraits):
   """
   """

    #: The function to call that iterates over the desired items. Iteration 
    #: should return a tuple of (uid, data).
    function = Callable

    # The list of keys to restrict the data extraction.
    keys = Either(None, List(UUID))

    #: The list of cuba keys that are available (read only)
    available = Property(List(CUBA), depends_on='function')

    #: Currently selected CUBA key
    selected = Instance(CUBA)

    #: The dictionary mapping uid to the extracted value.
    data = Property(Dict(Instance(UUID), Any), depends_on='selected, available')