Use lambdas when possible

Replace anonymous inner classes with lambda declarations (when possible
using method references).

See gh-9781
This commit is contained in:
Emanuel Campolo
2017-07-24 23:11:47 -07:00
committed by Phillip Webb
parent d16af43664
commit 2626a3a795
150 changed files with 983 additions and 2596 deletions

View File

@@ -36,14 +36,7 @@ public interface FieldValuesParser {
/**
* Implementation of {@link FieldValuesParser} that always returns an empty result.
*/
FieldValuesParser NONE = new FieldValuesParser() {
@Override
public Map<String, Object> getFieldValues(TypeElement element) {
return Collections.emptyMap();
}
};
FieldValuesParser NONE = (element) -> Collections.emptyMap();
/**
* Return the field values for the given element.