def get_attribute(self, name, value, trait, meta):
        """Return the attribute dictionary for this variable. This dict is
        used by the GUI to populate the edit UI. Slots also return an
        attribute dictionary for the slot pane.

        name: str
          Name of variable

        value: object
          The value of the variable

        trait: CTrait
          The variable's trait

        meta: dict
          Dictionary of metadata for this variable
        """

        io_attr = {}
        io_attr['name'] = name
        io_attr['type'] = trait.trait_type.klass.__name__
        io_attr['ttype'] = 'slot'

        slot_attr = {}
        slot_attr['name'] = name

        if value is None:
            slot_attr['filled'] = None
        elif value is []:
            slot_attr['filled'] = []
        else:
            slot_attr['filled'] = type(value).__name__

        slot_attr['klass'] = io_attr['type']
        slot_attr['containertype'] = 'singleton'

        for field in meta:
            if field not in gui_excludes:
                slot_attr[field] = meta[field]
                io_attr[field] = meta[field]

        return io_attr, slot_attr
dataset/ETHPy150Open OpenMDAO/OpenMDAO-Framework/openmdao.main/src/openmdao/main/datatypes/slot.py/Slot.get_attribute/original