Skip to content

Instantly share code, notes, and snippets.

Last active Feb 11, 2016
What would you like to do?
Lombok generic builder
import lombok.Builder;
import lombok.Data;
public class Entity<T> {
private T body;
public static void main(String[] args) {
//Line 11 does not compile
Entity<Integer> entity = Entity.<Integer>builder().body(1).build();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment