title: Java Arraylist change one attribute value in all objects at the same time
body: <p>I have a model with this attribute</p>
  
  <pre><code>public class Audit extends BaseModel implements Comparable {
  @Column
  @PrimaryKey
  @SerializedName("audit_id")
  private int id;
  
  @Column
  @SerializedName("address_line_1")
  private String addressLine1;
  
  @Column
  @SerializedName("address_line_2")
  private String addressLine2;
  
  @Column
  @SerializedName("city_name")
  private String city;
  
  @Column
  @SerializedName("zip_code")
  private String zipcode;
  
  @Column
  @SerializedName("company_id")
  private int companyId;
  
  @Column
  @SerializedName("company_name")
  private String companyName;
  
  @Column
  @SerializedName("loc_name")
  private String location;
  
  @Column
  @SerializedName("inspection_date_time")
  private OffsetDateTime inspectionTime;
  
  @Column
  @SerializedName("inspection_number")
  private String inspectionNumber;
  
  @Column(defaultValue = "0")
  private int auditStatus;
  
  @Column(defaultValue = "0")
  private int userId;
  
  public int getId() {
      return id;
  }
  
  public String getAddressLine1() {
      return addressLine1;
  }
  
  public String getAddressLine2() {
      return addressLine2;
  }
  
  public String getCity() {
      return city;
  }
  
  public String getZipcode() {
      return zipcode;
  }
  
  public int getCompanyId() {
      return companyId;
  }
  
  public String getCompanyName() {
      return companyName;
  }
  
  public String getLocation() {
      return location;
  }
  
  public OffsetDateTime getInspectionTime() {
      return inspectionTime;
  }
  
  public String getInspectionNumber() {
      return inspectionNumber;
  }
  
  public void setId(int id) {
      this.id = id;
  }
  
  public void setAddressLine1(String addressLine1) {
      this.addressLine1 = addressLine1;
  }
  
  public void setAddressLine2(String addressLine2) {
      this.addressLine2 = addressLine2;
  }
  
  public void setCity(String city) {
      this.city = city;
  }
  
  public void setZipcode(String zipcode) {
      this.zipcode = zipcode;
  }
  
  public void setCompanyId(int companyId) {
      this.companyId = companyId;
  }
  
  public void setCompanyName(String companyName) {
      this.companyName = companyName;
  }
  
  public void setLocation(String location) {
      this.location = location;
  }
  
  public void setInspectionTime(OffsetDateTime inspectionTime) {
      this.inspectionTime = inspectionTime;
  }
  
  public void setInspectionNumber(String inspectionNumber) {
      this.inspectionNumber = inspectionNumber;
  }
  
  @Override
  public int compareTo(@NonNull Object audits) {
      int result = -1;
      if (audits instanceof Audit) {
          Audit audit = (Audit) audits;
          if (this.getInspectionTime().isEqual(audit.getInspectionTime())) {
              result = 0;
          } else if 
   (this.getInspectionTime().isAfter(audit.getInspectionTime())) {
              result = 1;
          }
      }
      return result;
  }
  
  public int getAuditStatus() {
      return auditStatus;
  }
  
  public void setAuditStatus(int auditStatus) {
      this.auditStatus = auditStatus;
  }
  
  public int getUserId() {
      return userId;
  }
  
  public void setUserId(int userId) {
      this.userId = userId;
  }
  </code></pre>
  
  <p>In here I get all values to Arraylist using this model</p>
  
  <pre><code>List&lt;Audit&gt; auditList
  </code></pre>
  
  <p>My list is "auditList", It contains Audit objects, In this auditList I want to chnge one attribute 
  for ex: I want to change userId value to "3" in all objects, How can I do it once, Is there any solution please Help Me</p>