Made more changes, replacing Max types with Java types when I can for
simplicity reasons.