Been a while since I used Java and was wondering if this was a decent or even correct way of setting this up.
FYI, userResults refers to a JDBI variable that isn't present in the code below.
Feel free to suggest a better method, thanks.
public class Stat() { private int current; private int max; public int getCurrent() {return current;} public void setCurrent(int current) {this.current = current;} public int getMax() {return max;} public void setMax(int max) {this.max = max;} } public class Character() { Stat hp = new Stat(); Stat mp = new Stat(); } Character thisCharacter = new Character(); thisCharacter.hp.setCurrent((Integer) userResults.get("hpColumn1")); thisCharacter.hp.setMax((Integer) userResults.get("hpColumn2"));