Filtering the Collection
private Employee emp = list.stream().filter(t -> t.getId().equals(id)).findFirst().get();
All about technologies
Filtering the Collection
private Employee emp = list.stream().filter(t -> t.getId().equals(id)).findFirst().get();