class UpdateJobParameters in TMGMT Translator Smartling 8.4
Same name and namespace in other branches
- 8.3 vendor/smartling/api-sdk-php/src/Jobs/Params/UpdateJobParameters.php \Smartling\Jobs\Params\UpdateJobParameters
Class UpdateJobParameters @package Jobs\Params
Hierarchy
- class \Smartling\Parameters\BaseParameters implements ParameterInterface
- class \Smartling\Jobs\Params\UpdateJobParameters
Expanded class hierarchy of UpdateJobParameters
4 files declare their use of UpdateJobParameters
- JobsApi.php in vendor/
smartling/ api-sdk-php/ src/ Jobs/ JobsApi.php - JobsApiFunctionalTest.php in vendor/
smartling/ api-sdk-php/ tests/ functional/ JobsApiFunctionalTest.php - JobsApiTest.php in vendor/
smartling/ api-sdk-php/ tests/ unit/ JobsApiTest.php - SmartlingApiWrapper.php in src/
Smartling/ SmartlingApiWrapper.php - SmartlingApiWrapper.php.
File
- vendor/
smartling/ api-sdk-php/ src/ Jobs/ Params/ UpdateJobParameters.php, line 11
Namespace
Smartling\Jobs\ParamsView source
class UpdateJobParameters extends BaseParameters {
public function setName($jobName) {
if (mb_strlen($jobName, 'UTF-8') >= 170) {
throw new \InvalidArgumentException('Job name should be less than 170 characters.');
}
$this
->set('jobName', $jobName);
}
public function setDescription($description) {
if (mb_strlen($description, 'UTF-8') >= 2000) {
throw new \InvalidArgumentException('Job description should be less than 2000 characters.');
}
$this
->set('description', $description);
}
public function setDueDate(\DateTime $dueDate) {
if ($dueDate
->getTimestamp() < time()) {
throw new \InvalidArgumentException('Job Due Date cannot be in the past.');
}
$this
->set('dueDate', $dueDate
->format('Y-m-d\\TH:i:s\\Z'));
}
}
Members
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
BaseParameters:: |
protected | property | ||
BaseParameters:: |
public | function |
@inheritdoc Overrides ParameterInterface:: |
1 |
BaseParameters:: |
public | function |
@inheritdoc Overrides ParameterInterface:: |
|
UpdateJobParameters:: |
public | function | ||
UpdateJobParameters:: |
public | function | ||
UpdateJobParameters:: |
public | function |