com.geotab.model.serialization.ListIdConverter Maven / Gradle / Ivy
package com.geotab.model.serialization;
import com.fasterxml.jackson.databind.util.StdConverter;
import com.geotab.model.Id;
import java.util.List;
import java.util.stream.Collectors;
public class ListIdConverter extends StdConverter, List> {
@Override
public List convert(List users) {
return users.stream().map(Id::getId).collect(Collectors.toList());
}
}