'Restore the state of this node from a structure previously generated
by saveState().'

def restoreState(self, state):

    pos = state.get('pos', (0, 0))
    self.graphicsItem().setPos(*pos)
    self.bypass(state.get('bypass', False))
    if ('terminals' in state):
        self.restoreTerminals(state['terminals'])
