import queue


def drain_queue(collection, given_queue):
    """
    Get all available elements from the given queue without waiting.

    :param collection: List.
    :param given_queue: multiprocessing.Queue
    :return: False - no elements will come, True - otherwise
    """
    try:
        while True:
            element = given_queue.get_nowait()
            if element is None:
                given_queue.close()
                return False
            collection.append(element)
    except queue.Empty:
        return True