Small updates to Interfaces and abstract classes

+ Removed extra spaces from method definitions
This commit is contained in:
Benjamin Blake
2020-02-28 18:53:39 -07:00
parent cdbee13e11
commit 7cf7d59a54
4 changed files with 6 additions and 6 deletions

View File

@ -99,7 +99,7 @@ abstract class AbstractApiRequester implements ApiRequesterInterface, RequestCha
* @param Client $client * @param Client $client
* @param object|null $caller * @param object|null $caller
*/ */
public function __construct(Client &$client , ?object $caller) public function __construct(Client &$client, ?object $caller)
{ {
$this->setClient($client); $this->setClient($client);
$this->setCaller($caller); $this->setCaller($caller);

View File

@ -15,7 +15,7 @@ interface ApiRequesterInterface
* @param Client $client * @param Client $client
* @param object|null $caller * @param object|null $caller
*/ */
public function __construct(Client &$client , ?object $caller); public function __construct(Client &$client, ?object $caller);
/** /**
* Get the gitea client (by reference) * Get the gitea client (by reference)

View File

@ -28,7 +28,7 @@ abstract class AbstractApiModel implements ApiModelInterface, JsonSerializable,
* @param object|null $caller The object that called this method * @param object|null $caller The object that called this method
* @param mixed $args The organization visibility. * @param mixed $args The organization visibility.
*/ */
public function __construct(Client &$client , ?object $caller, ...$args) { public function __construct(Client &$client, ?object $caller, ...$args) {
$this->setClient($client); $this->setClient($client);
$this->setCaller($caller); $this->setCaller($caller);
} }
@ -59,7 +59,7 @@ abstract class AbstractApiModel implements ApiModelInterface, JsonSerializable,
* @param object|null $caller The object that called this method * @param object|null $caller The object that called this method
* @param object $map A JSON data object * @param object $map A JSON data object
*/ */
static function fromJson(object &$client , ?object $caller, object $map) { static function fromJson(object &$client, ?object $caller, object $map) {
trigger_error("The abstract 'fromJson()' method must be overwritten"); trigger_error("The abstract 'fromJson()' method must be overwritten");
return false; return false;
} }

View File

@ -19,7 +19,7 @@ interface ApiModelInterface
* @param object|null $caller The object that called this method * @param object|null $caller The object that called this method
* @param mixed $args The organization visibility. * @param mixed $args The organization visibility.
*/ */
public function __construct(Client &$client , ?object $caller, ...$args); public function __construct(Client &$client, ?object $caller, ...$args);
/** /**
* Create a new API model object from a JSON map object * Create a new API model object from a JSON map object
@ -39,7 +39,7 @@ interface ApiModelInterface
* @param object|null $caller The object that called this method * @param object|null $caller The object that called this method
* @param object $map A JSON data object * @param object $map A JSON data object
*/ */
static function fromJson(object &$client , ?object $caller, object $map); static function fromJson(object &$client, ?object $caller, object $map);
/** /**
* Convert this Api model object to a JSON map. * Convert this Api model object to a JSON map.