mirror of
https://github.com/brunofontes/Memsource-API.git
synced 2024-11-23 19:00:50 +00:00
feat: added new Async and TM modules on main file
This commit is contained in:
parent
1788befec6
commit
adfea614ad
@ -13,6 +13,8 @@ use \BrunoFontes\Memsource\FetchApi;
|
||||
use \BrunoFontes\Memsource\Jobs;
|
||||
use \BrunoFontes\Memsource\Oauth;
|
||||
use \BrunoFontes\Memsource\Project;
|
||||
use \BrunoFontes\Memsource\TM;
|
||||
use \BrunoFontes\Memsource\Async;
|
||||
|
||||
/**
|
||||
* Memsource API class
|
||||
@ -26,6 +28,8 @@ class Memsource
|
||||
private $_bilingualFile;
|
||||
private $_jobs;
|
||||
private $_project;
|
||||
private $_tm;
|
||||
private $_async;
|
||||
private $_fetchApi;
|
||||
|
||||
public function __construct(string $token = null, string $memsourceBaseUrl = 'https://cloud.memsource.com/web')
|
||||
@ -72,4 +76,24 @@ class Memsource
|
||||
{
|
||||
return $this->_project ?? $this->_project = new Project($this->_fetchApi);
|
||||
}
|
||||
|
||||
/**
|
||||
* Memsource API Async related functions
|
||||
*
|
||||
* @return Async
|
||||
*/
|
||||
public function async(): Async
|
||||
{
|
||||
return $this->_async ?? $this->_async = new Async($this->_fetchApi);
|
||||
}
|
||||
|
||||
/**
|
||||
* Memsource API TM related functions
|
||||
*
|
||||
* @return TM
|
||||
*/
|
||||
public function tm(): TM
|
||||
{
|
||||
return $this->_tm ?? $this->_tm = new TM($this->_fetchApi);
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user