public class RosterOrganizer { // 2.8.8 RosterOrganizer // Organizing Class Roster 2.8.8 private String student; public RosterOrganizer(String studentName) { student = studentName; } // Returns the word public String getStudent() { return student; } // Returns true if student comes // before otherStudent. // Returns false otherwise. public boolean placeBefore(String otherStudent) { return student.compareTo(otherStudent) < 0; } // Returns true if student comes // after otherStudent. // Returns false otherwise. public boolean placeAfter(String otherStudent) { return student.compareTo(otherStudent) > 0; } // Returns true if student is equal to otherStudent. // Returns false otherwise. public boolean isEqual(String otherStudent) { return student.equals(otherStudent); } }