The result
The result of executing the second expression in Figure 1
is:
- A new class that implements interfaceName is defined
- A new object of the new class is instantiated
- The expression is replaced by a reference to the new object
- That reference is handed over to the surrounding expression to be used
appropriately.