Example usage,
map.values().
.stream()
.map(Enum::toString)
.toArray(String[]::new);
-
map(Enum::toString)
This raises JavaSyntaxError "Expected ';'", the parse is expecting a ';' between the 'Enum' and 'toString'
-
toArray(String[]::new) -->
This raises JavaSyntaxError "Expected '.'" , the parse is expecting a '.' between the '[]' and 'new'