code: public CMASpaceMembership setRoles(CMALink... roles) {
      if (roles == null) {
        throw new IllegalArgumentException("Roles cannot be null!");
      }
      if (roles.length <= 0) {
        throw new IllegalArgumentException("Roles cannot be empty!");
      }
  
      this.roles = new ArrayList<CMALink>(Arrays.asList(roles));
      return this;
    }
docs: Replace all roles with the given argument.
  
  @param roles the roles to be used.
  @return this instance of membership for ease of chaining.
  @throws IllegalArgumentException if roles is null.
  @throws IllegalArgumentException if roles does not contain any elements.