Skip to content
Snippets Groups Projects
Commit 785de67d authored by Vadim Justus's avatar Vadim Justus
Browse files

#17 Remove return types and type hints for factory generation

parent f375cfbe
No related branches found
No related tags found
1 merge request!21#17 Fix type hint issues in Magento 2.1 and 2.2
...@@ -14,50 +14,50 @@ interface EntryInterface ...@@ -14,50 +14,50 @@ interface EntryInterface
/** /**
* @return string * @return string
*/ */
public function getKey(): string; public function getKey();
/** /**
* @param string $key * @param string $key
*/ */
public function setKey(string $key): void; public function setKey($key);
/** /**
* @return bool * @return bool
*/ */
public function isMaintained(): bool; public function isMaintained();
/** /**
* @param bool $isMaintained * @param bool $isMaintained
*/ */
public function setIsMaintained(bool $isMaintained): void; public function setIsMaintained($isMaintained);
/** /**
* @return array * @return array
*/ */
public function getStores(): array; public function getStores();
/** /**
* @param array $stores * @param array $stores
*/ */
public function setStores(array $stores): void; public function setStores(array $stores);
/** /**
* @return string * @return string
*/ */
public function getMediaDirectory(): string; public function getMediaDirectory();
/** /**
* @param string $path * @param string $path
*/ */
public function setMediaDirectory(string $path): void; public function setMediaDirectory($path);
/** /**
* @return array * @return array
*/ */
public function getMediaFiles(): array; public function getMediaFiles();
/** /**
* @param array $files * @param array $files
*/ */
public function setMediaFiles(array $files): void; public function setMediaFiles(array $files);
} }
...@@ -11,7 +11,7 @@ class BlockEntry extends Block implements BlockEntryInterface ...@@ -11,7 +11,7 @@ class BlockEntry extends Block implements BlockEntryInterface
/** /**
* @return string * @return string
*/ */
public function getKey(): string public function getKey()
{ {
return (string)$this->getData(BlockEntryInterface::KEY); return (string)$this->getData(BlockEntryInterface::KEY);
} }
...@@ -19,7 +19,7 @@ class BlockEntry extends Block implements BlockEntryInterface ...@@ -19,7 +19,7 @@ class BlockEntry extends Block implements BlockEntryInterface
/** /**
* @param string $key * @param string $key
*/ */
public function setKey(string $key): void public function setKey($key)
{ {
$this->setData(BlockEntryInterface::KEY, $key); $this->setData(BlockEntryInterface::KEY, $key);
} }
...@@ -27,7 +27,7 @@ class BlockEntry extends Block implements BlockEntryInterface ...@@ -27,7 +27,7 @@ class BlockEntry extends Block implements BlockEntryInterface
/** /**
* @return bool * @return bool
*/ */
public function isMaintained(): bool public function isMaintained()
{ {
return (bool)$this->getData(BlockEntryInterface::IS_MAINTAINED); return (bool)$this->getData(BlockEntryInterface::IS_MAINTAINED);
} }
...@@ -35,7 +35,7 @@ class BlockEntry extends Block implements BlockEntryInterface ...@@ -35,7 +35,7 @@ class BlockEntry extends Block implements BlockEntryInterface
/** /**
* @param bool $isMaintained * @param bool $isMaintained
*/ */
public function setIsMaintained(bool $isMaintained): void public function setIsMaintained($isMaintained)
{ {
$this->setData(BlockEntryInterface::IS_MAINTAINED, $isMaintained); $this->setData(BlockEntryInterface::IS_MAINTAINED, $isMaintained);
} }
...@@ -43,7 +43,7 @@ class BlockEntry extends Block implements BlockEntryInterface ...@@ -43,7 +43,7 @@ class BlockEntry extends Block implements BlockEntryInterface
/** /**
* @return array * @return array
*/ */
public function getStores(): array public function getStores()
{ {
return (array)$this->getData(BlockEntryInterface::STORES); return (array)$this->getData(BlockEntryInterface::STORES);
} }
...@@ -51,7 +51,7 @@ class BlockEntry extends Block implements BlockEntryInterface ...@@ -51,7 +51,7 @@ class BlockEntry extends Block implements BlockEntryInterface
/** /**
* @param array $stores * @param array $stores
*/ */
public function setStores(array $stores): void public function setStores(array $stores)
{ {
$this->setData(BlockEntryInterface::STORES, $stores); $this->setData(BlockEntryInterface::STORES, $stores);
} }
...@@ -59,7 +59,7 @@ class BlockEntry extends Block implements BlockEntryInterface ...@@ -59,7 +59,7 @@ class BlockEntry extends Block implements BlockEntryInterface
/** /**
* @return string * @return string
*/ */
public function getMediaDirectory(): string public function getMediaDirectory()
{ {
return (string)$this->getData(BlockEntryInterface::MEDIA_DIRECTORY); return (string)$this->getData(BlockEntryInterface::MEDIA_DIRECTORY);
} }
...@@ -67,7 +67,7 @@ class BlockEntry extends Block implements BlockEntryInterface ...@@ -67,7 +67,7 @@ class BlockEntry extends Block implements BlockEntryInterface
/** /**
* @param string $path * @param string $path
*/ */
public function setMediaDirectory(string $path): void public function setMediaDirectory($path)
{ {
$this->setData(BlockEntryInterface::MEDIA_DIRECTORY, $path); $this->setData(BlockEntryInterface::MEDIA_DIRECTORY, $path);
} }
...@@ -75,7 +75,7 @@ class BlockEntry extends Block implements BlockEntryInterface ...@@ -75,7 +75,7 @@ class BlockEntry extends Block implements BlockEntryInterface
/** /**
* @return array * @return array
*/ */
public function getMediaFiles(): array public function getMediaFiles()
{ {
return (array)$this->getData(BlockEntryInterface::MEDIA_FILES); return (array)$this->getData(BlockEntryInterface::MEDIA_FILES);
} }
...@@ -83,7 +83,7 @@ class BlockEntry extends Block implements BlockEntryInterface ...@@ -83,7 +83,7 @@ class BlockEntry extends Block implements BlockEntryInterface
/** /**
* @param array $files * @param array $files
*/ */
public function setMediaFiles(array $files): void public function setMediaFiles(array $files)
{ {
$this->setData(BlockEntryInterface::MEDIA_FILES, $files); $this->setData(BlockEntryInterface::MEDIA_FILES, $files);
} }
......
...@@ -11,7 +11,7 @@ class PageEntry extends Page implements PageEntryInterface ...@@ -11,7 +11,7 @@ class PageEntry extends Page implements PageEntryInterface
/** /**
* @return string * @return string
*/ */
public function getKey(): string public function getKey()
{ {
return (string)$this->getData(PageEntryInterface::KEY); return (string)$this->getData(PageEntryInterface::KEY);
} }
...@@ -19,7 +19,7 @@ class PageEntry extends Page implements PageEntryInterface ...@@ -19,7 +19,7 @@ class PageEntry extends Page implements PageEntryInterface
/** /**
* @param string $key * @param string $key
*/ */
public function setKey(string $key): void public function setKey($key)
{ {
$this->setData(PageEntryInterface::KEY, $key); $this->setData(PageEntryInterface::KEY, $key);
} }
...@@ -27,7 +27,7 @@ class PageEntry extends Page implements PageEntryInterface ...@@ -27,7 +27,7 @@ class PageEntry extends Page implements PageEntryInterface
/** /**
* @return bool * @return bool
*/ */
public function isMaintained(): bool public function isMaintained()
{ {
return (bool)$this->getData(PageEntryInterface::IS_MAINTAINED); return (bool)$this->getData(PageEntryInterface::IS_MAINTAINED);
} }
...@@ -35,7 +35,7 @@ class PageEntry extends Page implements PageEntryInterface ...@@ -35,7 +35,7 @@ class PageEntry extends Page implements PageEntryInterface
/** /**
* @param bool $isMaintained * @param bool $isMaintained
*/ */
public function setIsMaintained(bool $isMaintained): void public function setIsMaintained($isMaintained)
{ {
$this->setData(PageEntryInterface::IS_MAINTAINED, $isMaintained); $this->setData(PageEntryInterface::IS_MAINTAINED, $isMaintained);
} }
...@@ -43,7 +43,7 @@ class PageEntry extends Page implements PageEntryInterface ...@@ -43,7 +43,7 @@ class PageEntry extends Page implements PageEntryInterface
/** /**
* @return array * @return array
*/ */
public function getStores(): array public function getStores()
{ {
return (array)$this->getData(PageEntryInterface::STORES); return (array)$this->getData(PageEntryInterface::STORES);
} }
...@@ -51,7 +51,7 @@ class PageEntry extends Page implements PageEntryInterface ...@@ -51,7 +51,7 @@ class PageEntry extends Page implements PageEntryInterface
/** /**
* @param array $stores * @param array $stores
*/ */
public function setStores(array $stores): void public function setStores(array $stores)
{ {
$this->setData(PageEntryInterface::STORES, $stores); $this->setData(PageEntryInterface::STORES, $stores);
} }
...@@ -59,7 +59,7 @@ class PageEntry extends Page implements PageEntryInterface ...@@ -59,7 +59,7 @@ class PageEntry extends Page implements PageEntryInterface
/** /**
* @return string * @return string
*/ */
public function getMediaDirectory(): string public function getMediaDirectory()
{ {
return (string)$this->getData(PageEntryInterface::MEDIA_DIRECTORY); return (string)$this->getData(PageEntryInterface::MEDIA_DIRECTORY);
} }
...@@ -67,7 +67,7 @@ class PageEntry extends Page implements PageEntryInterface ...@@ -67,7 +67,7 @@ class PageEntry extends Page implements PageEntryInterface
/** /**
* @param string $path * @param string $path
*/ */
public function setMediaDirectory(string $path): void public function setMediaDirectory(string $path)
{ {
$this->setData(PageEntryInterface::MEDIA_DIRECTORY, $path); $this->setData(PageEntryInterface::MEDIA_DIRECTORY, $path);
} }
...@@ -75,7 +75,7 @@ class PageEntry extends Page implements PageEntryInterface ...@@ -75,7 +75,7 @@ class PageEntry extends Page implements PageEntryInterface
/** /**
* @return array * @return array
*/ */
public function getMediaFiles(): array public function getMediaFiles()
{ {
return (array)$this->getData(PageEntryInterface::MEDIA_FILES); return (array)$this->getData(PageEntryInterface::MEDIA_FILES);
} }
...@@ -83,7 +83,7 @@ class PageEntry extends Page implements PageEntryInterface ...@@ -83,7 +83,7 @@ class PageEntry extends Page implements PageEntryInterface
/** /**
* @param array $files * @param array $files
*/ */
public function setMediaFiles(array $files): void public function setMediaFiles(array $files)
{ {
$this->setData(PageEntryInterface::MEDIA_FILES, $files); $this->setData(PageEntryInterface::MEDIA_FILES, $files);
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment