Commit 0eb27e48 authored by Thomas Löffler's avatar Thomas Löffler

Append Service to all service classes

parent 623411ac
Pipeline #2768 passed with stages
in 3 minutes and 57 seconds
......@@ -26,7 +26,7 @@ abstract class AbstractTerBasedController extends \T3o\TerFe2\Controller\Abstrac
protected $frontendUser = array();
/**
* @var \T3o\TerFe2\Service\Ter
* @var \T3o\TerFe2\Service\TerService
*/
protected $terConnection;
......@@ -97,7 +97,7 @@ abstract class AbstractTerBasedController extends \T3o\TerFe2\Controller\Abstrac
/**
* Create a connection to the TER server
*
* @return \T3o\TerFe2\Service\Ter The TER connection
* @return \T3o\TerFe2\Service\TerService The TER connection
* @throws \Exception
*/
protected function getTerConnection()
......@@ -113,6 +113,6 @@ abstract class AbstractTerBasedController extends \T3o\TerFe2\Controller\Abstrac
// Create connection
$wsdl = $this->terSettings['wsdl'];
return $this->objectManager->get(\T3o\TerFe2\Service\Ter::class, $wsdl, $this->terAccount['username'], $this->terAccount['password'], $this->terSettings['httpAuth']);
return $this->objectManager->get(\T3o\TerFe2\Service\TerService::class, $wsdl, $this->terAccount['username'], $this->terAccount['password'], $this->terSettings['httpAuth']);
}
}
......@@ -195,8 +195,8 @@ class ExtensionController extends \T3o\TerFe2\Controller\AbstractController
$this->view->assign('extension', $extension);
$this->view->assign('versionHistory', $versionHistory);
/** @var \T3o\TerFe2\Service\Documentation $documentationService */
$documentationService = \TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance(\T3o\TerFe2\Service\Documentation::class);
/** @var \T3o\TerFe2\Service\DocumentationService $documentationService */
$documentationService = \TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance(\T3o\TerFe2\Service\DocumentationService::class);
$documentationLink = $documentationService->getDocumentationLink($extension->getExtKey(), $extension->getLastVersion()->getVersionString());
$this->view->assign('documentationLink', $documentationLink);
......
......@@ -21,7 +21,7 @@ class MirrorProvider extends \T3o\TerFe2\Provider\FileProvider
{
/**
* @var \T3o\TerFe2\Service\Mirror
* @var \T3o\TerFe2\Service\MirrorService
*/
protected $mirrorService;
......@@ -53,7 +53,7 @@ class MirrorProvider extends \T3o\TerFe2\Provider\FileProvider
}
// Get mirror service
$this->mirrorService = $this->objectManager->get(\T3o\TerFe2\Service\Mirror::class);
$this->mirrorService = $this->objectManager->get(\T3o\TerFe2\Service\MirrorService::class);
$this->mirrorService->setRepositoryId($repositoryId);
}
......
......@@ -41,7 +41,7 @@ class SoapProvider extends \T3o\TerFe2\Provider\AbstractProvider
protected $getDownloadCountFunc;
/**
* @var \T3o\TerFe2\Service\Soap
* @var \T3o\TerFe2\Service\SoapService
*/
protected $soapService;
......@@ -62,7 +62,7 @@ class SoapProvider extends \T3o\TerFe2\Provider\AbstractProvider
$password = (empty($this->configuration['password']) ? $this->configuration['password'] : '');
$httpAuth['login'] = $this->configuration['httpAuth']['login'] ?: '';
$httpAuth['password'] = $this->configuration['httpAuth']['password'] ?: '';
$this->soapService = $this->objectManager->get(\T3o\TerFe2\Service\Soap::class);
$this->soapService = $this->objectManager->get(\T3o\TerFe2\Service\SoapService::class);
$this->soapService->connect($this->configuration['wsdlUrl'], $username, $password, $httpAuth);
// Set getExtensionsFunc
......
......@@ -20,7 +20,7 @@ namespace T3o\TerFe2\Service;
* @package TerFe2
* @author Thomas Löffler <thomas.loeffler@typo3.org>
*/
class Documentation implements \TYPO3\CMS\Core\SingletonInterface
class DocumentationService implements \TYPO3\CMS\Core\SingletonInterface
{
/**
......
......@@ -17,7 +17,7 @@ namespace T3o\TerFe2\Service;
/**
* Service for flattr buttons
*/
class Flattr implements \TYPO3\CMS\Core\SingletonInterface
class FlattrService implements \TYPO3\CMS\Core\SingletonInterface
{
/**
......
......@@ -17,7 +17,7 @@ namespace T3o\TerFe2\Service;
/**
* Service to handle mirrors
*/
class Mirror implements \TYPO3\CMS\Core\SingletonInterface
class MirrorService implements \TYPO3\CMS\Core\SingletonInterface
{
/**
......
......@@ -17,7 +17,7 @@ namespace T3o\TerFe2\Service;
/**
* Service to handle soap requests
*/
class Soap implements \TYPO3\CMS\Core\SingletonInterface
class SoapService implements \TYPO3\CMS\Core\SingletonInterface
{
/**
......
......@@ -17,7 +17,7 @@ namespace T3o\TerFe2\Service;
/**
* Service for TER operations
*/
class Ter
class TerService
{
/**
......@@ -36,7 +36,7 @@ class Ter
protected $objectManager;
/**
* @var \T3o\TerFe2\Service\Soap
* @var \T3o\TerFe2\Service\SoapService
*/
protected $soapService;
......@@ -57,7 +57,7 @@ class Ter
'password' => $password,
);
$objectManager = \TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance(\TYPO3\CMS\Extbase\Object\ObjectManager::class);
$this->soapService = $objectManager->get(\T3o\TerFe2\Service\Soap::class);
$this->soapService = $objectManager->get(\T3o\TerFe2\Service\SoapService::class);
$this->soapService->connect($this->wsdlUrl, '', '', true, $httpAuth);
}
......
......@@ -119,8 +119,8 @@ class TerIndexer extends \ApacheSolrForTypo3\Solr\IndexQueue\Indexer
$document->setField('extensionIcon_stringS', $extensionIcon);
// add documentation link
/** @var \T3o\TerFe2\Service\Documentation $documentationService */
$documentationService = GeneralUtility::makeInstance(\T3o\TerFe2\Service\Documentation::class);
/** @var \T3o\TerFe2\Service\DocumentationService $documentationService */
$documentationService = GeneralUtility::makeInstance(\T3o\TerFe2\Service\DocumentationService::class);
$documentationLink = $documentationService->getDocumentationLink($extension->getExtKey(), $extension->getLastVersion()->getVersionString(), true);
$document->setField('extensionDocumentationLink_stringS', $documentationLink);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment