src/mappers/JobPermissionDeleteMapper.php 1 location
|
@@ 13-27 (lines=15) @@
|
10 |
|
use mcorten87\rabbitmq_api\objects\Url; |
11 |
|
use mcorten87\rabbitmq_api\services\MqManagementConfig; |
12 |
|
|
13 |
|
class JobPermissionDeleteMapper extends BaseMapper |
14 |
|
{ |
15 |
|
|
16 |
|
protected function mapMethod(JobBase $job) : Method { |
17 |
|
return new Method(Method::METHOD_DELETE); |
18 |
|
} |
19 |
|
|
20 |
|
/** |
21 |
|
* @param JobPermissionCreate $job |
22 |
|
* @return Url |
23 |
|
*/ |
24 |
|
protected function mapUrl(JobBase $job) : Url { |
25 |
|
return new Url('permissions/'.urlencode($job->getVirtualHost()).'/'.urlencode($job->getUser())); |
26 |
|
} |
27 |
|
} |
28 |
|
|
src/mappers/JobQueueDeleteMapper.php 1 location
|
@@ 12-22 (lines=11) @@
|
9 |
|
use mcorten87\rabbitmq_api\objects\Url; |
10 |
|
use mcorten87\rabbitmq_api\services\MqManagementConfig; |
11 |
|
|
12 |
|
class JobQueueDeleteMapper extends BaseMapper |
13 |
|
{ |
14 |
|
|
15 |
|
protected function mapMethod(JobBase $job) : Method { |
16 |
|
return new Method(Method::METHOD_DELETE); |
17 |
|
} |
18 |
|
|
19 |
|
protected function mapUrl(JobBase $job) : Url { |
20 |
|
return new Url('queues/'.urlencode($job->getVirtualHost()).'/'.urlencode($job->getQueueName())); |
21 |
|
} |
22 |
|
} |
23 |
|
|
src/mappers/JobVirtualHostCreateMapper.php 1 location
|
@@ 11-21 (lines=11) @@
|
8 |
|
use mcorten87\rabbitmq_api\objects\Url; |
9 |
|
use mcorten87\rabbitmq_api\services\MqManagementConfig; |
10 |
|
|
11 |
|
class JobVirtualHostCreateMapper extends BaseMapper |
12 |
|
{ |
13 |
|
|
14 |
|
protected function mapMethod(JobBase $job) : Method { |
15 |
|
return new Method(Method::METHOD_PUT); |
16 |
|
} |
17 |
|
|
18 |
|
protected function mapUrl(JobBase $job) : Url { |
19 |
|
return new Url('vhosts/'.urlencode($job->getVirtualHost())); |
20 |
|
} |
21 |
|
} |
22 |
|
|
src/mappers/JobVirtualHostDeleteMapper.php 1 location
|
@@ 13-23 (lines=11) @@
|
10 |
|
use mcorten87\rabbitmq_api\objects\Url; |
11 |
|
use mcorten87\rabbitmq_api\services\MqManagementConfig; |
12 |
|
|
13 |
|
class JobVirtualHostDeleteMapper extends BaseMapper |
14 |
|
{ |
15 |
|
|
16 |
|
protected function mapMethod(JobBase $job) : Method { |
17 |
|
return new Method(Method::METHOD_DELETE); |
18 |
|
} |
19 |
|
|
20 |
|
protected function mapUrl(JobBase $job) : Url { |
21 |
|
return new Url('vhosts/'.urlencode($job->getVirtualHost())); |
22 |
|
} |
23 |
|
} |
24 |
|
|