@@ -18,7 +18,6 @@ |
||
| 18 | 18 | /** |
| 19 | 19 | * Create the command factory for the ScaleEngine API requests. |
| 20 | 20 | * |
| 21 | - * @param string $apiKey The API secret used to sign requests. |
|
| 22 | 21 | * @param ServiceDescriptionInterface $description Service description. |
| 23 | 22 | * @param InflectorInterface $inflector Optional inflector to use if the |
| 24 | 23 | * command is not at first found. |
@@ -3,7 +3,6 @@ |
||
| 3 | 3 | |
| 4 | 4 | use DateTime; |
| 5 | 5 | use DateTimeZone; |
| 6 | -use Exception; |
|
| 7 | 6 | use Guzzle\Service\Resource\Model; |
| 8 | 7 | |
| 9 | 8 | /** |
@@ -22,7 +22,7 @@ |
||
| 22 | 22 | * reply is not successful. |
| 23 | 23 | * |
| 24 | 24 | * @param OperationCommand $command The API call being executed. |
| 25 | - * @param string|array $resultPath The path to the actual result model. If |
|
| 25 | + * @param string $resultPath The path to the actual result model. If |
|
| 26 | 26 | * not provided, this will return the entire JSON response. |
| 27 | 27 | * @return array The top-level result JSON from the API call. |
| 28 | 28 | * @throws Exception if the result was not successful. |
@@ -19,7 +19,7 @@ |
||
| 19 | 19 | * @param OperationCommand $command The GetTicketStatus API call made. |
| 20 | 20 | * @param ScaleEngineTicketFactory $modelFactory The factory to use to |
| 21 | 21 | * create tickets. Will be created if not given. |
| 22 | - * @return ScaleEngineTicket The ticket returned from the API request. |
|
| 22 | + * @return ScaleEngineTicketFactory The ticket returned from the API request. |
|
| 23 | 23 | */ |
| 24 | 24 | public static function fromCommand(OperationCommand $command, ScaleEngineTicketFactory $modelFactory = null) |
| 25 | 25 | { |
@@ -19,7 +19,7 @@ |
||
| 19 | 19 | * @param OperationCommand $command The RequestTicket API call made. |
| 20 | 20 | * @param ScaleEngineTicketFactory $modelFactory The factory to use to |
| 21 | 21 | * create tickets. Will be created if not given. |
| 22 | - * @return ScaleEngineTicket The ticket returned from the API request. |
|
| 22 | + * @return ScaleEngineTicketFactory The ticket returned from the API request. |
|
| 23 | 23 | */ |
| 24 | 24 | public static function fromCommand(OperationCommand $command, ScaleEngineTicketFactory $modelFactory = null) |
| 25 | 25 | { |
@@ -23,7 +23,7 @@ |
||
| 23 | 23 | /** |
| 24 | 24 | * Create the visitor, initializing the SPL Object Storage. |
| 25 | 25 | * |
| 26 | - * @param string $apiKey The API secret used to sign requests. |
|
| 26 | + * @param string $apiSecret |
|
| 27 | 27 | */ |
| 28 | 28 | public function __construct($apiSecret) |
| 29 | 29 | { |
@@ -46,10 +46,10 @@ |
||
| 46 | 46 | } |
| 47 | 47 | } |
| 48 | 48 | |
| 49 | - $parsedData['active'] = (bool)$parsedData['active']; |
|
| 49 | + $parsedData['active'] = (bool) $parsedData['active']; |
|
| 50 | 50 | $parsedData['createdDate'] = $this->convertDate($parsedData['createdDate']); |
| 51 | 51 | $parsedData['usedDate'] = $this->convertDate($parsedData['usedDate']); |
| 52 | - $parsedData['uses'] = (int)$parsedData['uses']; |
|
| 52 | + $parsedData['uses'] = (int) $parsedData['uses']; |
|
| 53 | 53 | |
| 54 | 54 | return $parsedData; |
| 55 | 55 | } |
@@ -40,7 +40,7 @@ |
||
| 40 | 40 | |
| 41 | 41 | $client = parent::factory($config); |
| 42 | 42 | |
| 43 | - $description = ServiceDescription::factory(__DIR__ . '/service/main.json'); |
|
| 43 | + $description = ServiceDescription::factory(__DIR__ . '/service/main.json'); |
|
| 44 | 44 | $client->setCommandFactory( |
| 45 | 45 | new ScaleEngineCommandFactory($config['apiSecret'], $description) |
| 46 | 46 | ); |