Skip to content

Commit

Permalink
Updated Charity
Browse files Browse the repository at this point in the history
Added parameters for the new SQL entries to the Charity object.
  • Loading branch information
roaraf committed Apr 8, 2026
1 parent b3832e9 commit 5638e8f
Showing 1 changed file with 46 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -31,10 +31,18 @@ public class Charity {
/* Category for the charity */
private String category;

/* Description for the charity */
private String description;

/* URL for the logo of the charity */
private String logoURL;

/* Key values for the charity */
private String keyValues;

/* List that contains the charity's Feedbacks */
private List<Feedback> feedbacks;


/**
* Contructor for creating a new charity. Taylored to match data given from Api. Other attributes
* will just be initialized as empty
Expand Down Expand Up @@ -78,8 +86,11 @@ public Charity(
this.url = link;
this.is_pre_approved = is_pre_approved;
this.status = status;
this.feedbacks = new ArrayList<>();
this.category = "";
this.description = "";
this.logoURL = "";
this.keyValues = "";
this.feedbacks = new ArrayList<>();
}

/** Getters for the charity's attributes. */
Expand Down Expand Up @@ -112,7 +123,19 @@ public String getName() {
}

public String getURL() {
return this.url;
return this.url;
}

public String getDescription() {
return this.description;
}

public String getLogoURL() {
return this.logoURL;
}

public String getKeyValues() {
return this.keyValues;
}

/** Setter for verification status. This one sets the charity as verified. */
Expand All @@ -124,4 +147,24 @@ public void setVerified() {
public void setUnverified() {
this.status = "Veto";
}

/** Setter for categories. */
public void setCategory(String category) {
this.category = category;
}

/** Setter for description. */
public void setDescription(String description) {
this.description = description;
}

/** Setter for the URL of the charity's logo. */
public void setLogoURL(String url) {
this.logoURL = url;
}

/** Setter for the charity's key values. */
public void setKeyValues(String values) {
this.keyValues = values;
}
}

0 comments on commit 5638e8f

Please sign in to comment.