public static ImmutableList < Expression < ? > > distinctList ( Expression < ? > ... args ) { final ImmutableList . Builder < Expression < ? > > builder = ImmutableList . builder ( ) ; final Set < Expression < ? > > set = new HashSet < Expression < ? > > ( args . length ) ; for ( Expression < ? > arg : args ) { if ( set . add ( arg ) ) { builder . add ( arg ) ; } } return builder . build ( ) ; }
Create a distinct list of the given args