code: def get_medium(self, name, controller_port, device):
          
          if not isinstance(name, basestring):
              raise TypeError("name can only be an instance of type basestring")
          if not isinstance(controller_port, baseinteger):
              raise TypeError("controller_port can only be an instance of type baseinteger")
          if not isinstance(device, baseinteger):
              raise TypeError("device can only be an instance of type baseinteger")
          medium = self._call("getMedium",
                       in_p=[name, controller_port, device])
          medium = IMedium(medium)
          return medium
docs: Returns the virtual medium attached to a device slot of the specified
          bus.
          
          Note that if the medium was indirectly attached by
          :py:func:`mount_medium`  to the given device slot then this
          method will return not the same object as passed to the
          :py:func:`mount_medium`  call. See :py:class:`IMedium`  for
          more detailed information about mounting a medium.
  
          in name of type str
              Name of the storage controller the medium is attached to.
  
          in controller_port of type int
              Port to query.
  
          in device of type int
              Device slot in the given port to query.
  
          return medium of type :class:`IMedium`
              Attached medium object.
  
          raises :class:`VBoxErrorObjectNotFound`
              No medium attached to given slot/bus.