<?php
return new class($controller) implements Page {
public function __construct($controller) {
/* ... */
}
/* ... */
};
class MyObject extends MyStuff {
public function getInterface() {
return new class implements MyInterface {
/* ... */
};
}
}
?>