. * */ namespace Friendica\Test\Util\Hooks\InstanceMocks; class FakeInstanceDecorator implements IAmADecoratedInterface { public static $countInstance = 0; /** @var IAmADecoratedInterface */ protected $orig; protected $prefix = ''; public function __construct(IAmADecoratedInterface $orig, string $prefix = '') { $this->orig = $orig; $this->prefix = $prefix; self::$countInstance++; } public function createSomething(string $aText, bool $cBool, string $bText): string { return $this->orig->createSomething($aText, $cBool, $bText); } public function getAText(): ?string { return $this->prefix . $this->orig->getAText(); } public function getBText(): ?string { return $this->prefix . $this->orig->getBText(); } public function getCBool(): ?bool { return $this->prefix . $this->orig->getCBool(); } }