public List<String> getNames() {
        if (this.isEmpty()) {
            return Collections.emptyList();
        } else {
            final List<String> names = new ArrayList<>(this.size());
            for (final T i : this) {
                names.add(i.getName());
            }
            return names;
        }
    }
public List < String > getNames ( ) { if ( this . isEmpty ( ) ) { return Collections . emptyList ( ) ; } else { final List < String > names = new ArrayList < > ( this . size ( ) ) ; for ( final T i : this ) { names . add ( i . getName ( ) ) ; } return names ; } }
Get the names of all items in this list, by calling {@code getName()} on each item in the list.

@return The names of all items in this list, by calling {@code getName()} on each item in the list.