From b5600756124d4f2f2762501962e8b283b36be3d1 Mon Sep 17 00:00:00 2001 From: Akihito Koriyama Date: Mon, 16 Jan 2017 19:32:32 +0900 Subject: [PATCH] remove deprecated class --- src-deprecated/ReactJsModule.php | 51 ---------------------- src-deprecated/ReduxServerSideRenderer.php | 44 ------------------- src-deprecated/ReduxSsr.php | 35 --------------- tests/ReactJsModuleTest.php | 21 --------- 4 files changed, 151 deletions(-) delete mode 100644 src-deprecated/ReactJsModule.php delete mode 100644 src-deprecated/ReduxServerSideRenderer.php delete mode 100644 src-deprecated/ReduxSsr.php delete mode 100644 tests/ReactJsModuleTest.php diff --git a/src-deprecated/ReactJsModule.php b/src-deprecated/ReactJsModule.php deleted file mode 100644 index d489098..0000000 --- a/src-deprecated/ReactJsModule.php +++ /dev/null @@ -1,51 +0,0 @@ -reactLibsrc = $reactLibsrc; - $this->reactAppSrc = $reactAppSrc; - } - - /** - * {@inheritdoc} - */ - protected function configure() - { - $this->bind()->annotatedWith('reactBundleSrc')->toInstance(file_get_contents($this->reactAppSrc)); - $this->bind()->annotatedWith('appBundleSrc')->toInstance(file_get_contents($this->reactLibsrc)); - $this->bind(ReduxSsrInterface::class)->toConstructor(ReduxReactSsr::class, 'reactBundleSrc=reactBundleSrc,appBundleSrc=appBundleSrc'); - $this->bind(RenderInterface::class)->annotatedWith(ReduxSsrInject::class)->to(ReduxServerSideRenderer::class)->in(Scope::SINGLETON); - } -} diff --git a/src-deprecated/ReduxServerSideRenderer.php b/src-deprecated/ReduxServerSideRenderer.php deleted file mode 100644 index 3118fb4..0000000 --- a/src-deprecated/ReduxServerSideRenderer.php +++ /dev/null @@ -1,44 +0,0 @@ -ssr = $ssr; - } - - /** - * {@inheritdoc} - * - * @SuppressWarnings(PHPMD.UnusedLocalVariable) - */ - public function render(ResourceObject $ro) - { - $file = $ro instanceof WeavedInterface ? (new \ReflectionClass($ro))->getParentClass()->getFileName() : (new \ReflectionClass($ro))->getFileName(); - $template = substr($file, 0, -4) . '.html.php'; - $ssr = $this->ssr; - $ro->view = require $template; - - return $ro->view; - } -} diff --git a/src-deprecated/ReduxSsr.php b/src-deprecated/ReduxSsr.php deleted file mode 100644 index d574507..0000000 --- a/src-deprecated/ReduxSsr.php +++ /dev/null @@ -1,35 +0,0 @@ -renderer = $renderer; - } -} diff --git a/tests/ReactJsModuleTest.php b/tests/ReactJsModuleTest.php deleted file mode 100644 index cb4e888..0000000 --- a/tests/ReactJsModuleTest.php +++ /dev/null @@ -1,21 +0,0 @@ -getInstance(RenderInterface::class, ReduxSsrInject::class); - $this->assertInstanceOf(ReduxServerSideRenderer::class, $renderer); - } -}