def _GetInstNicParam(name):
  def fn(ctx, index, _):
    """Get a NIC's bridge.

    @type ctx: L{InstanceQueryData}
    @type inst: L{objects.Instance}
    @param inst: Instance object
    @type nic: L{objects.NIC}
    @param nic: NIC object

    """
    assert len(ctx.inst_nicparams) >= index
    return ctx.inst_nicparams[index][name]

  return fn
Return a file-like representation or raise a KeyError.
dataset/ETHPy150Open ganeti/ganeti/lib/query.py/_GetInstNicParam--crossover with--dataset/ETHPy150Open babble/babble/include/jython/Lib/mailbox.py/Maildir.get_file