def list_datastores_full(service_instance):
    '''
    Returns a list of datastores associated with a given service instance.
    The list contains basic information about the datastore:
        name, type, url, capacity, free, used, usage, hosts

    service_instance
        The Service Instance Object from which to obtain datastores.
    '''
    datastores_list = list_objects(service_instance, vim.Datastore)

    datastores = {}
    for datastore in datastores_list:
        datastores[datastore] = list_datastore_full(service_instance, datastore)

    return datastores
def list_datastores_full ( service_instance ) : datastores_list = list_objects ( service_instance , vim . Datastore ) datastores = { } for datastore in datastores_list : datastores [ datastore ] = list_datastore_full ( service_instance , datastore ) return datastores
Returns a list of datastores associated with a given service instance.
    The list contains basic information about the datastore:
        name, type, url, capacity, free, used, usage, hosts

    service_instance
        The Service Instance Object from which to obtain datastores.