throw new UserRoleException( Messages.getInstance().getErrorString(
"UserRoleWebService.ERROR_0006_ROLE_UPDATE_FAILED", roleName ) ); //$NON-NLS-1$
}
Set<String> users = new HashSet<String>();
for ( String username : usernames ) {
IPentahoUser user = getDao().getUser( null, username );
if ( user == null ) {
throw new UserRoleException( Messages.getInstance().getErrorString(
"UserRoleWebService.ERROR_0006_ROLE_UPDATE_FAILED", roleName ) ); //$NON-NLS-1$
}
users.add( user.getUsername() );
}
getDao().setRoleDescription( null, roleName, description );
getDao().setRoleMembers( null, roleName, users.toArray( new String[0] ) );
}