Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVA

model mapper to list stream

List<UserDTO> dtos = users
  .stream()
  .map(user -> modelMapper.map(user, UserDTO.class))
  .collect(Collectors.toList());
 
PREVIOUS NEXT
Tagged: #model #mapper #list #stream
ADD COMMENT
Topic
Name
7+4 =