Search in sources :

Example 6 with OSTenantRestRep

use of com.emc.storageos.model.keystone.OSTenantRestRep in project coprhd-controller by CoprHD.

the class Tenants method tenantsListToRemoveJson.

public static void tenantsListToRemoveJson() {
    OpenStackTenantsUtils.synchronizeOpenStackTenants();
    List<OpenStackTenantsDataTable.OpenStackTenant> tenants = Lists.newArrayList();
    for (OSTenantRestRep tenant : OpenStackTenantsUtils.getOpenStackTenantsFromDataBase()) {
        if (!tenant.getExcluded()) {
            tenants.add(new OpenStackTenantsDataTable.OpenStackTenant(tenant));
        }
    }
    renderJSON(DataTablesSupport.createJSON(tenants, params));
}
Also used : OpenStackTenantsDataTable(models.datatable.OpenStackTenantsDataTable) OSTenantRestRep(com.emc.storageos.model.keystone.OSTenantRestRep)

Aggregations

OSTenantRestRep (com.emc.storageos.model.keystone.OSTenantRestRep)6 OSTenantListRestRep (com.emc.storageos.model.keystone.OSTenantListRestRep)3 ArrayList (java.util.ArrayList)2 OpenStackTenantsDataTable (models.datatable.OpenStackTenantsDataTable)2 URIQueryResultList (com.emc.storageos.db.client.constraint.URIQueryResultList)1 CheckPermission (com.emc.storageos.security.authorization.CheckPermission)1 URI (java.net.URI)1