def configure_connection(obj, inp):
    if hasattr(inp, 'output_port'):
        obj.input_connection = inp.output_port
    elif inp.has_output_port():
        obj.input_connection = inp.get_output_object()
    else:
        configure_input(obj, inp.outputs[0])
Configure topology for vtk pipeline obj.
dataset/ETHPy150Open enthought/mayavi/tvtk/common.py/configure_connection