describeLifecycleHooks method
Gets information about the lifecycle hooks for the specified Auto Scaling group.
May throw ResourceContentionFault.
Parameter autoScalingGroupName :
The name of the Auto Scaling group.
Parameter lifecycleHookNames :
The names of one or more lifecycle hooks. If you omit this property, all
lifecycle hooks are described.
Implementation
Future<DescribeLifecycleHooksAnswer> describeLifecycleHooks({
required String autoScalingGroupName,
List<String>? lifecycleHookNames,
}) async {
final $request = <String, String>{
'AutoScalingGroupName': autoScalingGroupName,
if (lifecycleHookNames != null)
if (lifecycleHookNames.isEmpty)
'LifecycleHookNames': ''
else
for (var i1 = 0; i1 < lifecycleHookNames.length; i1++)
'LifecycleHookNames.member.${i1 + 1}': lifecycleHookNames[i1],
};
final $result = await _protocol.send(
$request,
action: 'DescribeLifecycleHooks',
version: '2011-01-01',
method: 'POST',
requestUri: '/',
exceptionFnMap: _exceptionFns,
resultWrapper: 'DescribeLifecycleHooksResult',
);
return DescribeLifecycleHooksAnswer.fromXml($result);
}