toJson method
Implementation
Map<String, dynamic> toJson() {
final maxCapacity = this.maxCapacity;
final minCapacity = this.minCapacity;
final resourceId = this.resourceId;
final scalableDimension = this.scalableDimension;
final serviceNamespace = this.serviceNamespace;
final targetTrackingConfigurations = this.targetTrackingConfigurations;
final customizedLoadMetricSpecification =
this.customizedLoadMetricSpecification;
final disableDynamicScaling = this.disableDynamicScaling;
final predefinedLoadMetricSpecification =
this.predefinedLoadMetricSpecification;
final predictiveScalingMaxCapacityBehavior =
this.predictiveScalingMaxCapacityBehavior;
final predictiveScalingMaxCapacityBuffer =
this.predictiveScalingMaxCapacityBuffer;
final predictiveScalingMode = this.predictiveScalingMode;
final scalingPolicyUpdateBehavior = this.scalingPolicyUpdateBehavior;
final scheduledActionBufferTime = this.scheduledActionBufferTime;
return {
'MaxCapacity': maxCapacity,
'MinCapacity': minCapacity,
'ResourceId': resourceId,
'ScalableDimension': scalableDimension.toValue(),
'ServiceNamespace': serviceNamespace.toValue(),
'TargetTrackingConfigurations': targetTrackingConfigurations,
if (customizedLoadMetricSpecification != null)
'CustomizedLoadMetricSpecification': customizedLoadMetricSpecification,
if (disableDynamicScaling != null)
'DisableDynamicScaling': disableDynamicScaling,
if (predefinedLoadMetricSpecification != null)
'PredefinedLoadMetricSpecification': predefinedLoadMetricSpecification,
if (predictiveScalingMaxCapacityBehavior != null)
'PredictiveScalingMaxCapacityBehavior':
predictiveScalingMaxCapacityBehavior.toValue(),
if (predictiveScalingMaxCapacityBuffer != null)
'PredictiveScalingMaxCapacityBuffer':
predictiveScalingMaxCapacityBuffer,
if (predictiveScalingMode != null)
'PredictiveScalingMode': predictiveScalingMode.toValue(),
if (scalingPolicyUpdateBehavior != null)
'ScalingPolicyUpdateBehavior': scalingPolicyUpdateBehavior.toValue(),
if (scheduledActionBufferTime != null)
'ScheduledActionBufferTime': scheduledActionBufferTime,
};
}