-
Notifications
You must be signed in to change notification settings - Fork 141
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[W5.11r][T16-B1] Qiu Haoze #769
base: master
Are you sure you want to change the base?
Conversation
/** | ||
* Sorts all persons in the list according to their full name | ||
*/ | ||
public void sort(){ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
coding style violation. read this
* Sorts all persons in the list according to their full name | ||
*/ | ||
public void sort(){ | ||
internalList.sort((person1, person2) -> (person1.getName().fullName.toLowerCase().compareTo( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
whats the difference between using getName()
and fullName
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
getName() gets a Name object, and fullName, a string, is an attribute of class Name.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
and how is a Name
object compared?
Great work! |
Add sort command to addressbook-level3, with test and documentation updated