File tree Expand file tree Collapse file tree 3 files changed +17
-3
lines changed
src/Networking/v2/Extensions/SecurityGroups Expand file tree Collapse file tree 3 files changed +17
-3
lines changed Original file line number Diff line number Diff line change @@ -24,7 +24,10 @@ public function getSecurityGroups()
24
24
return [
25
25
'method ' => 'GET ' ,
26
26
'path ' => $ this ->pathPrefix .'/security-groups ' ,
27
- 'params ' => [],
27
+ 'params ' => [
28
+ 'tenantId ' => $ this ->params ->queryTenantId (),
29
+ 'name ' => $ this ->params ->filterName (),
30
+ ],
28
31
];
29
32
}
30
33
Original file line number Diff line number Diff line change @@ -89,4 +89,13 @@ public function tenantIdJson()
89
89
'description ' => 'The UUID of the tenant who owns the security group rule. Only administrative users can specify a tenant UUID other than their own. ' ,
90
90
];
91
91
}
92
+
93
+ public function filterName (): array
94
+ {
95
+ return [
96
+ 'description ' => sprintf ('Filter the list result by the human-readable name of the resource ' ),
97
+ 'type ' => self ::STRING_TYPE ,
98
+ 'location ' => self ::QUERY ,
99
+ ];
100
+ }
92
101
}
Original file line number Diff line number Diff line change @@ -22,11 +22,13 @@ private function securityGroupRule(array $info = []): SecurityGroupRule
22
22
}
23
23
24
24
/**
25
+ * @param array $options
26
+ *
25
27
* @return \Generator
26
28
*/
27
- public function listSecurityGroups (): \Generator
29
+ public function listSecurityGroups (array $ options = [] ): \Generator
28
30
{
29
- return $ this ->securityGroup ()->enumerate ($ this ->api ->getSecurityGroups ());
31
+ return $ this ->securityGroup ()->enumerate ($ this ->api ->getSecurityGroups (), $ options );
30
32
}
31
33
32
34
/**
You can’t perform that action at this time.
0 commit comments