protected synchronized WildflyGroupPropertiesManager getGroupsPropertiesManager() { try { return (WildflyGroupPropertiesManager) userSystemManager.groups(); } catch (ClassCastException e) { return null; } }
public Collection<String> getConstrainedGroups() { return groupManagerSettings != null ? groupManagerSettings.getConstrainedGroups() : null; }
public Collection<UserManager.UserAttribute> getUserSupportedAttributes() { return userManagerSettings.getSupportedAttributes(); }
public UserManager.UserAttribute getUserSupportedAttribute(final String attributeName) { if (attributeName != null && userManagerSettings != null && userManagerSettings.getSupportedAttributes() != null) { for (final UserManager.UserAttribute attribute : userManagerSettings.getSupportedAttributes()) { if (attributeName.equals(attribute.getName())) { return attribute; } } } return null; }
@Override public SearchResponse<User> search(SearchRequest request) { final UserManager serviceImpl = getService(); // Delegate to the current service provider implementation. if (request.getPage() == 0) { throw new IllegalArgumentException("First page must be 1."); } return serviceImpl.search(request); }
@Override public GroupManagerSettings getSettings() { final GroupManager serviceImpl = getService(); final GroupManagerSettings settings = serviceImpl.getSettings(); if (null != settings) { settings.setConstrainedGroups(SecurityManagementUtils.getRegisteredRoleNames()); } return settings; }
@Override public Group get(String identifier) throws SecurityManagementException { final GroupManager serviceImpl = getService(); return serviceImpl.get(identifier); }
@Override public void assignGroups(String username, Collection<String> groups) { final UserManager serviceImpl = getService(); serviceImpl.assignGroups(username, groups); }
@Override public User create(User entity) { final UserManager serviceImpl = getService(); return serviceImpl.create(entity); }
@Override public User update(User entity) { final UserManager serviceImpl = getService(); return serviceImpl.update(entity); }
public boolean isCapabilityEnabled(final Map<Capability, CapabilityStatus> capabilities, final Capability capability) { if (capabilities != null) { final CapabilityStatus status = capabilities.get(capability); return status != null && CapabilityStatus.ENABLED.equals(status); } return false; }
@Override public void delete(String... identifiers) throws SecurityManagementException { final RoleManager serviceImpl = getService(); serviceImpl.delete(identifiers); }
public boolean isGroupCapabilityEnabled(final Capability capability) { if (groupManagerSettings != null) { return isCapabilityEnabled(groupManagerSettings.getCapabilities(), capability); } return false; }
public UserManager.UserAttribute getUserSupportedAttribute(final String attributeName) { if (attributeName != null && userManagerSettings != null && userManagerSettings.getSupportedAttributes() != null) { for (final UserManager.UserAttribute attribute : userManagerSettings.getSupportedAttributes()) { if (attributeName.equals(attribute.getName())) { return attribute; } } } return null; }
public synchronized BaseWildflyGroupPropertiesManager getGroupsPropertiesManager() { try { return (BaseWildflyGroupPropertiesManager) userSystemManager.groups(); } catch (ClassCastException e) { return null; } }
public Collection<UserManager.UserAttribute> getUserSupportedAttributes() { return userManagerSettings.getSupportedAttributes(); }
public Collection<String> getConstrainedGroups() { return groupManagerSettings != null ? groupManagerSettings.getConstrainedGroups() : null; }
public boolean isCapabilityEnabled(final Map<Capability, CapabilityStatus> capabilities, final Capability capability) { if (capabilities != null) { final CapabilityStatus status = capabilities.get(capability); return status != null && CapabilityStatus.ENABLED.equals(status); } return false; }
protected synchronized WildflyGroupPropertiesManager getGroupsPropertiesManager() { try { return (WildflyGroupPropertiesManager) userSystemManager.groups(); } catch (ClassCastException e) { return null; } }