*
* ============LICENSE_END============================================
*
- * ECOMP is a trademark and service mark of AT&T Intellectual Property.
+ *
*/
package org.onap.portalapp.portal.service;
import java.util.List;
+import java.util.Set;
import org.onap.portalapp.portal.domain.EPApp;
import org.onap.portalapp.portal.domain.EPRole;
import org.onap.portalapp.portal.domain.EPUser;
+import org.onap.portalapp.portal.exceptions.RoleFunctionException;
import org.onap.portalapp.portal.transport.AppsListWithAdminRole;
public interface AdminRolesService {
public boolean setAppsWithAdminRoleStateForUser(AppsListWithAdminRole newAppsListWithAdminRoles);
/**
- * Attention! User roles in ECOMP PORTAL cannot be managed by this function.
+ * Attention! User roles in ONAP PORTAL cannot be managed by this function.
* @param user
- * @return 'true' if user has Super Administrator role SYS_ADMIN_ROLE_ID (1 for now) in ECOMP PORTAL, 'false' otherwise
+ * @return 'true' if user has Super Administrator role SYS_ADMIN_ROLE_ID (1 for now) in ONAP PORTAL, 'false' otherwise
*/
public boolean isSuperAdmin(EPUser user);
/**
- * Attention! User roles in ECOMP PORTAL cannot be managed by this function.
+ * Attention! User roles in ONAP PORTAL cannot be managed by this function.
* @param user
- * @return 'true' if user has Account Administrator role ACCOUNT_ADMIN_ROLE_ID (999 for now) for any application except ECOMP Portal, 'false' otherwise
+ * @return 'true' if user has Account Administrator role ACCOUNT_ADMIN_ROLE_ID (999 for now) for any application except ONAP Portal, 'false' otherwise
*/
public boolean isAccountAdmin(EPUser user);
+
+ public boolean isRoleAdmin(EPUser user);
+
+
/**
- * Attention! User roles in ECOMP PORTAL cannot be managed by this function.
+ * Attention! User roles in ONAP PORTAL cannot be managed by this function.
* @param user
- * @return 'true' if user has any remote(!) role within any application (ECOMP Portal roles are not included), 'false' otherwise
+ * @return 'true' if user has any remote(!) role within any application (ONAP Portal roles are not included), 'false' otherwise
*/
public boolean isUser(EPUser user);
List<EPRole> getRolesByApp(EPUser user, Long appId);
public boolean isAccountAdminOfApplication(EPUser user, EPApp app);
+ public Set<String> getAllAppsFunctionsOfUser(String OrgUserId)throws RoleFunctionException;
+
+ boolean isAccountAdminOfAnyActiveorInactiveApplication(EPUser user, EPApp app);
}