Anonymous class implementation