Get all items of a certain type
    Example: get_all(content, vim.Datastore) return all datastore objects

def get_all(content, container, object_type):
    '''
    Get all items of a certain type
    Example: get_all(content, vim.Datastore) return all datastore objects
    '''
    obj_list = list()
    view_manager = content.viewManager
    object_view = view_manager.CreateContainerView(
        container, [object_type], True
    )
    for obj in object_view.view:
        if isinstance(obj, object_type):
            obj_list.append(obj)
    object_view.Destroy()
    return obj_list