Skip to content

Commit

Permalink
Make AbstractNamedBean.getDisplayName() final
Browse files Browse the repository at this point in the history
  • Loading branch information
danielb987 committed Jan 18, 2019
1 parent c083cae commit f54e4be
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 14 deletions.
6 changes: 1 addition & 5 deletions java/src/jmri/implementation/AbstractNamedBean.java
Expand Up @@ -84,15 +84,11 @@ final public void setComment(String comment) {

/**
* {@inheritDoc}
* <p>
* It would be good to eventually make this final to
* keep it consistent system-wide, but
* we have some existing classes to update first.
*
* @return user name if not null or empty, else return system name
*/
@Override
public String getDisplayName() {
final public String getDisplayName() {
String name = getUserName();
if (name != null && !name.isEmpty()) {
return name;
Expand Down
9 changes: 0 additions & 9 deletions java/src/jmri/jmrit/entryexit/DestinationPoints.java
Expand Up @@ -97,15 +97,6 @@ public void propertyChange(PropertyChangeEvent e) {
};
}

@Override
public String getDisplayName() {
String uName = getUserName();
if (uName != null) {
return uName;
}
return getSystemName();
}

String getUniqueId() {
return getSystemName();
}
Expand Down

0 comments on commit f54e4be

Please sign in to comment.