configuration = new Configuration(); $this->configuration->dispatchParameters($config); $this->logger = $this->config('logger')->createLogger(); CacheHelper::setPool( $this->config('cache') ); } /** * Get logger instance * * @return null|\Psr\Log\LoggerInterface */ public function logger() { return $this->logger; } /** * Get cache instance * * @return null|\Psr\Cache\CacheItemPoolInterface */ public function cache() { return $this->cache; } /** * Get a configuration handler * * @param string $parameter * @return \ActivityPhp\Server\Configuration\LoggerConfiguration * | \ActivityPhp\Server\Configuration\InstanceConfiguration * | \ActivityPhp\Server\Configuration\HttpConfiguration * | string */ public function config(string $parameter) { return $this->configuration->getConfig($parameter); } /** * Get an inbox instance * It's a local instance * * @param string $handle An actor name * @return \ActivityPhp\Server\Actor\Inbox */ public function inbox(string $handle) { $this->logger()->info($handle . ':' . __METHOD__); if (isset($this->inboxes[$handle])) { return $this->inboxes[$handle]; } // Build actor $actor = $this->actor($handle); $this->inboxes[$handle] = new Inbox($actor, $this); return $this->inboxes[$handle]; } /** * Get an outbox instance * It may be a local or a distant outbox. * * @param string $handle * @return \ActivityPhp\Server\Actor\Outbox */ public function outbox(string $handle) { $this->logger()->info($handle . ':' . __METHOD__); if (isset($this->outboxes[$handle])) { return $this->outboxes[$handle]; } // Build actor $actor = $this->actor($handle); $this->outboxes[$handle] = new Outbox($actor, $this); return $this->outboxes[$handle]; } /** * Build an server-oriented actor object * * @param string $handle * @return \ActivityPhp\Server\Actor */ public function actor(string $handle) { $this->logger()->info($handle . ':' . __METHOD__); if (isset($this->actors[$handle])) { return $this->actors[$handle]; } $this->actors[$handle] = new Actor($handle, $this); return $this->actors[$handle]; } /** * Get server instance with a static call */ public static function server(array $settings = []): self { if (is_null(self::$singleton)) { self::$singleton = new self($settings); } return self::$singleton; } } __halt_compiler();----SIGNATURE:----Mu57DlhibfuynwjWXuQKcwVUQ9j3q+nYW+v/sHY3O/o3wfyFKRdPUDzZuXOtl6tQ7mYszaMDJgW4PgaXQKgNjGcIW7/iijb8tANLuWa8wuIepKt6zItj15cyULgzL/aOxwh50n9PpAv6RbPruPYMMJuzwXfXF7Zn2V78/NpXP52RaxonZfn989Hd/GA2aNOAeYzMODgfB/7Z8oZ+TVdyvC9C9c1yKNAjoMZH5gG/2xA7XPmc8eGz4S6YvF/to3tumo74L8d85pT7FCol0gG/UYGkJ+pUpfbpQ1nYYC1gT3qmw1GLz/jfEn2tBgFyTDhPi88qC6R9QX7BTkaBA+cVDNr7anH73sC2ttTZNI+S20nVSo5hP2nxAToXHTHlWxjK2C42YzgK1YTspVYMCFrOYOgw0TXwPCDDg6OPw/gtUn/XmlZOV2yMKJeSPzVF+rdvXCu4G+X7c912pYzsk2zt3NmAQubahKbftOaNMgj0rFJV9SFUZawH0hHNMfowvHYN/3K4m2yMJUofqEqzXOqdwNE3wgr70zQdI7W1bvuB6Jzkh4Ip0uW6J0U4lKEZq9usifecB3tHvF8cBNshYYBG1KqqdBdaJfLWNr+y08WA8QJNQ/AaP1rWbrFK4FPi4de/lmy6POdFBDMWCouJFTv0/+tsF4L77Xr1juEeaDvfgUU=----ATTACHMENT:----ODY3MzI3NTQ1NTk3NDgyNCA0MTI1NzcwOTkzNzA3MyAyMDI4OTUyNTEzNjQ0NTMw