Aws::String CreateStageRequest::SerializePayload() const { JsonValue payload; if(m_stageNameHasBeenSet) { payload.WithString("stageName", m_stageName); } if(m_deploymentIdHasBeenSet) { payload.WithString("deploymentId", m_deploymentId); } if(m_descriptionHasBeenSet) { payload.WithString("description", m_description); } if(m_cacheClusterEnabledHasBeenSet) { payload.WithBool("cacheClusterEnabled", m_cacheClusterEnabled); } if(m_cacheClusterSizeHasBeenSet) { payload.WithString("cacheClusterSize", CacheClusterSizeMapper::GetNameForCacheClusterSize(m_cacheClusterSize)); } if(m_variablesHasBeenSet) { JsonValue variablesJsonMap; for(auto& variablesItem : m_variables) { variablesJsonMap.WithString(variablesItem.first, variablesItem.second); } payload.WithObject("variables", std::move(variablesJsonMap)); } if(m_documentationVersionHasBeenSet) { payload.WithString("documentationVersion", m_documentationVersion); } if(m_canarySettingsHasBeenSet) { payload.WithObject("canarySettings", m_canarySettings.Jsonize()); } if(m_tracingEnabledHasBeenSet) { payload.WithBool("tracingEnabled", m_tracingEnabled); } if(m_tagsHasBeenSet) { JsonValue tagsJsonMap; for(auto& tagsItem : m_tags) { tagsJsonMap.WithString(tagsItem.first, tagsItem.second); } payload.WithObject("tags", std::move(tagsJsonMap)); } return payload.View().WriteReadable(); }
JsonValue ElasticsearchDestinationConfiguration::Jsonize() const { JsonValue payload; if(m_roleARNHasBeenSet) { payload.WithString("RoleARN", m_roleARN); } if(m_domainARNHasBeenSet) { payload.WithString("DomainARN", m_domainARN); } if(m_indexNameHasBeenSet) { payload.WithString("IndexName", m_indexName); } if(m_typeNameHasBeenSet) { payload.WithString("TypeName", m_typeName); } if(m_indexRotationPeriodHasBeenSet) { payload.WithString("IndexRotationPeriod", ElasticsearchIndexRotationPeriodMapper::GetNameForElasticsearchIndexRotationPeriod(m_indexRotationPeriod)); } if(m_bufferingHintsHasBeenSet) { payload.WithObject("BufferingHints", m_bufferingHints.Jsonize()); } if(m_retryOptionsHasBeenSet) { payload.WithObject("RetryOptions", m_retryOptions.Jsonize()); } if(m_s3BackupModeHasBeenSet) { payload.WithString("S3BackupMode", ElasticsearchS3BackupModeMapper::GetNameForElasticsearchS3BackupMode(m_s3BackupMode)); } if(m_s3ConfigurationHasBeenSet) { payload.WithObject("S3Configuration", m_s3Configuration.Jsonize()); } if(m_cloudWatchLoggingOptionsHasBeenSet) { payload.WithObject("CloudWatchLoggingOptions", m_cloudWatchLoggingOptions.Jsonize()); } return payload; }
JsonValue StepExecution::Jsonize() const { JsonValue payload; if(m_stepNameHasBeenSet) { payload.WithString("StepName", m_stepName); } if(m_actionHasBeenSet) { payload.WithString("Action", m_action); } if(m_executionStartTimeHasBeenSet) { payload.WithDouble("ExecutionStartTime", m_executionStartTime.SecondsWithMSPrecision()); } if(m_executionEndTimeHasBeenSet) { payload.WithDouble("ExecutionEndTime", m_executionEndTime.SecondsWithMSPrecision()); } if(m_stepStatusHasBeenSet) { payload.WithString("StepStatus", AutomationExecutionStatusMapper::GetNameForAutomationExecutionStatus(m_stepStatus)); } if(m_responseCodeHasBeenSet) { payload.WithString("ResponseCode", m_responseCode); } if(m_inputsHasBeenSet) { JsonValue inputsJsonMap; for(auto& inputsItem : m_inputs) { inputsJsonMap.WithString(inputsItem.first, inputsItem.second); } payload.WithObject("Inputs", std::move(inputsJsonMap)); } if(m_outputsHasBeenSet) { JsonValue outputsJsonMap; for(auto& outputsItem : m_outputs) { Array<JsonValue> automationParameterValueListJsonList(outputsItem.second.size()); for(unsigned automationParameterValueListIndex = 0; automationParameterValueListIndex < automationParameterValueListJsonList.GetLength(); ++automationParameterValueListIndex) { automationParameterValueListJsonList[automationParameterValueListIndex].AsString(outputsItem.second[automationParameterValueListIndex]); } outputsJsonMap.WithArray(outputsItem.first, std::move(automationParameterValueListJsonList)); } payload.WithObject("Outputs", std::move(outputsJsonMap)); } if(m_responseHasBeenSet) { payload.WithString("Response", m_response); } if(m_failureMessageHasBeenSet) { payload.WithString("FailureMessage", m_failureMessage); } if(m_failureDetailsHasBeenSet) { payload.WithObject("FailureDetails", m_failureDetails.Jsonize()); } return payload; }
Aws::String ListClosedWorkflowExecutionsRequest::SerializePayload() const { JsonValue payload; if(m_domainHasBeenSet) { payload.WithString("domain", m_domain); } if(m_startTimeFilterHasBeenSet) { payload.WithObject("startTimeFilter", m_startTimeFilter.Jsonize()); } if(m_closeTimeFilterHasBeenSet) { payload.WithObject("closeTimeFilter", m_closeTimeFilter.Jsonize()); } if(m_executionFilterHasBeenSet) { payload.WithObject("executionFilter", m_executionFilter.Jsonize()); } if(m_closeStatusFilterHasBeenSet) { payload.WithObject("closeStatusFilter", m_closeStatusFilter.Jsonize()); } if(m_typeFilterHasBeenSet) { payload.WithObject("typeFilter", m_typeFilter.Jsonize()); } if(m_tagFilterHasBeenSet) { payload.WithObject("tagFilter", m_tagFilter.Jsonize()); } if(m_nextPageTokenHasBeenSet) { payload.WithString("nextPageToken", m_nextPageToken); } if(m_maximumPageSizeHasBeenSet) { payload.WithInteger("maximumPageSize", m_maximumPageSize); } if(m_reverseOrderHasBeenSet) { payload.WithBool("reverseOrder", m_reverseOrder); } return payload.WriteReadable(); }
JsonValue BatchWriteOperation::Jsonize() const { JsonValue payload; if(m_createObjectHasBeenSet) { payload.WithObject("CreateObject", m_createObject.Jsonize()); } if(m_attachObjectHasBeenSet) { payload.WithObject("AttachObject", m_attachObject.Jsonize()); } if(m_detachObjectHasBeenSet) { payload.WithObject("DetachObject", m_detachObject.Jsonize()); } if(m_updateObjectAttributesHasBeenSet) { payload.WithObject("UpdateObjectAttributes", m_updateObjectAttributes.Jsonize()); } if(m_deleteObjectHasBeenSet) { payload.WithObject("DeleteObject", m_deleteObject.Jsonize()); } if(m_addFacetToObjectHasBeenSet) { payload.WithObject("AddFacetToObject", m_addFacetToObject.Jsonize()); } if(m_removeFacetFromObjectHasBeenSet) { payload.WithObject("RemoveFacetFromObject", m_removeFacetFromObject.Jsonize()); } if(m_attachPolicyHasBeenSet) { payload.WithObject("AttachPolicy", m_attachPolicy.Jsonize()); } if(m_detachPolicyHasBeenSet) { payload.WithObject("DetachPolicy", m_detachPolicy.Jsonize()); } if(m_createIndexHasBeenSet) { payload.WithObject("CreateIndex", m_createIndex.Jsonize()); } if(m_attachToIndexHasBeenSet) { payload.WithObject("AttachToIndex", m_attachToIndex.Jsonize()); } if(m_detachFromIndexHasBeenSet) { payload.WithObject("DetachFromIndex", m_detachFromIndex.Jsonize()); } if(m_attachTypedLinkHasBeenSet) { payload.WithObject("AttachTypedLink", m_attachTypedLink.Jsonize()); } if(m_detachTypedLinkHasBeenSet) { payload.WithObject("DetachTypedLink", m_detachTypedLink.Jsonize()); } if(m_updateLinkAttributesHasBeenSet) { payload.WithObject("UpdateLinkAttributes", m_updateLinkAttributes.Jsonize()); } return payload; }
JsonValue JobOutput::Jsonize() const { JsonValue payload; if(m_idHasBeenSet) { payload.WithString("Id", m_id); } if(m_keyHasBeenSet) { payload.WithString("Key", m_key); } if(m_thumbnailPatternHasBeenSet) { payload.WithString("ThumbnailPattern", m_thumbnailPattern); } if(m_thumbnailEncryptionHasBeenSet) { payload.WithObject("ThumbnailEncryption", m_thumbnailEncryption.Jsonize()); } if(m_rotateHasBeenSet) { payload.WithString("Rotate", m_rotate); } if(m_presetIdHasBeenSet) { payload.WithString("PresetId", m_presetId); } if(m_segmentDurationHasBeenSet) { payload.WithString("SegmentDuration", m_segmentDuration); } if(m_statusHasBeenSet) { payload.WithString("Status", m_status); } if(m_statusDetailHasBeenSet) { payload.WithString("StatusDetail", m_statusDetail); } if(m_durationHasBeenSet) { payload.WithInt64("Duration", m_duration); } if(m_widthHasBeenSet) { payload.WithInteger("Width", m_width); } if(m_heightHasBeenSet) { payload.WithInteger("Height", m_height); } if(m_frameRateHasBeenSet) { payload.WithString("FrameRate", m_frameRate); } if(m_fileSizeHasBeenSet) { payload.WithInt64("FileSize", m_fileSize); } if(m_durationMillisHasBeenSet) { payload.WithInt64("DurationMillis", m_durationMillis); } if(m_watermarksHasBeenSet) { Array<JsonValue> watermarksJsonList(m_watermarks.size()); for(unsigned watermarksIndex = 0; watermarksIndex < watermarksJsonList.GetLength(); ++watermarksIndex) { watermarksJsonList[watermarksIndex].AsObject(m_watermarks[watermarksIndex].Jsonize()); } payload.WithArray("Watermarks", std::move(watermarksJsonList)); } if(m_albumArtHasBeenSet) { payload.WithObject("AlbumArt", m_albumArt.Jsonize()); } if(m_compositionHasBeenSet) { Array<JsonValue> compositionJsonList(m_composition.size()); for(unsigned compositionIndex = 0; compositionIndex < compositionJsonList.GetLength(); ++compositionIndex) { compositionJsonList[compositionIndex].AsObject(m_composition[compositionIndex].Jsonize()); } payload.WithArray("Composition", std::move(compositionJsonList)); } if(m_captionsHasBeenSet) { payload.WithObject("Captions", m_captions.Jsonize()); } if(m_encryptionHasBeenSet) { payload.WithObject("Encryption", m_encryption.Jsonize()); } if(m_appliedColorSpaceConversionHasBeenSet) { payload.WithString("AppliedColorSpaceConversion", m_appliedColorSpaceConversion); } return payload; }
Aws::String CreateFunctionRequest::SerializePayload() const { JsonValue payload; if(m_functionNameHasBeenSet) { payload.WithString("FunctionName", m_functionName); } if(m_runtimeHasBeenSet) { payload.WithString("Runtime", RuntimeMapper::GetNameForRuntime(m_runtime)); } if(m_roleHasBeenSet) { payload.WithString("Role", m_role); } if(m_handlerHasBeenSet) { payload.WithString("Handler", m_handler); } if(m_codeHasBeenSet) { payload.WithObject("Code", m_code.Jsonize()); } if(m_descriptionHasBeenSet) { payload.WithString("Description", m_description); } if(m_timeoutHasBeenSet) { payload.WithInteger("Timeout", m_timeout); } if(m_memorySizeHasBeenSet) { payload.WithInteger("MemorySize", m_memorySize); } if(m_publishHasBeenSet) { payload.WithBool("Publish", m_publish); } if(m_vpcConfigHasBeenSet) { payload.WithObject("VpcConfig", m_vpcConfig.Jsonize()); } if(m_deadLetterConfigHasBeenSet) { payload.WithObject("DeadLetterConfig", m_deadLetterConfig.Jsonize()); } if(m_environmentHasBeenSet) { payload.WithObject("Environment", m_environment.Jsonize()); } if(m_kMSKeyArnHasBeenSet) { payload.WithString("KMSKeyArn", m_kMSKeyArn); } return payload.WriteReadable(); }
JsonValue RDSDataSpec::Jsonize() const { JsonValue payload; if(m_databaseInformationHasBeenSet) { payload.WithObject("DatabaseInformation", m_databaseInformation.Jsonize()); } if(m_selectSqlQueryHasBeenSet) { payload.WithString("SelectSqlQuery", m_selectSqlQuery); } if(m_databaseCredentialsHasBeenSet) { payload.WithObject("DatabaseCredentials", m_databaseCredentials.Jsonize()); } if(m_s3StagingLocationHasBeenSet) { payload.WithString("S3StagingLocation", m_s3StagingLocation); } if(m_dataRearrangementHasBeenSet) { payload.WithString("DataRearrangement", m_dataRearrangement); } if(m_dataSchemaHasBeenSet) { payload.WithString("DataSchema", m_dataSchema); } if(m_dataSchemaUriHasBeenSet) { payload.WithString("DataSchemaUri", m_dataSchemaUri); } if(m_resourceRoleHasBeenSet) { payload.WithString("ResourceRole", m_resourceRole); } if(m_serviceRoleHasBeenSet) { payload.WithString("ServiceRole", m_serviceRole); } if(m_subnetIdHasBeenSet) { payload.WithString("SubnetId", m_subnetId); } if(m_securityGroupIdsHasBeenSet) { Array<JsonValue> securityGroupIdsJsonList(m_securityGroupIds.size()); for(unsigned securityGroupIdsIndex = 0; securityGroupIdsIndex < securityGroupIdsJsonList.GetLength(); ++securityGroupIdsIndex) { securityGroupIdsJsonList[securityGroupIdsIndex].AsString(m_securityGroupIds[securityGroupIdsIndex]); } payload.WithArray("SecurityGroupIds", std::move(securityGroupIdsJsonList)); } return payload; }
JsonValue ReplicationTask::Jsonize() const { JsonValue payload; if(m_replicationTaskIdentifierHasBeenSet) { payload.WithString("ReplicationTaskIdentifier", m_replicationTaskIdentifier); } if(m_sourceEndpointArnHasBeenSet) { payload.WithString("SourceEndpointArn", m_sourceEndpointArn); } if(m_targetEndpointArnHasBeenSet) { payload.WithString("TargetEndpointArn", m_targetEndpointArn); } if(m_replicationInstanceArnHasBeenSet) { payload.WithString("ReplicationInstanceArn", m_replicationInstanceArn); } if(m_migrationTypeHasBeenSet) { payload.WithString("MigrationType", MigrationTypeValueMapper::GetNameForMigrationTypeValue(m_migrationType)); } if(m_tableMappingsHasBeenSet) { payload.WithString("TableMappings", m_tableMappings); } if(m_replicationTaskSettingsHasBeenSet) { payload.WithString("ReplicationTaskSettings", m_replicationTaskSettings); } if(m_statusHasBeenSet) { payload.WithString("Status", m_status); } if(m_lastFailureMessageHasBeenSet) { payload.WithString("LastFailureMessage", m_lastFailureMessage); } if(m_replicationTaskCreationDateHasBeenSet) { payload.WithDouble("ReplicationTaskCreationDate", m_replicationTaskCreationDate.SecondsWithMSPrecision()); } if(m_replicationTaskStartDateHasBeenSet) { payload.WithDouble("ReplicationTaskStartDate", m_replicationTaskStartDate.SecondsWithMSPrecision()); } if(m_replicationTaskArnHasBeenSet) { payload.WithString("ReplicationTaskArn", m_replicationTaskArn); } if(m_replicationTaskStatsHasBeenSet) { payload.WithObject("ReplicationTaskStats", m_replicationTaskStats.Jsonize()); } return payload; }
JsonValue TableDescription::Jsonize() const { JsonValue payload; if(m_attributeDefinitionsHasBeenSet) { Array<JsonValue> attributeDefinitionsJsonList(m_attributeDefinitions.size()); for(unsigned attributeDefinitionsIndex = 0; attributeDefinitionsIndex < attributeDefinitionsJsonList.GetLength(); ++attributeDefinitionsIndex) { attributeDefinitionsJsonList[attributeDefinitionsIndex].AsObject(m_attributeDefinitions[attributeDefinitionsIndex].Jsonize()); } payload.WithArray("AttributeDefinitions", std::move(attributeDefinitionsJsonList)); } if(m_tableNameHasBeenSet) { payload.WithString("TableName", m_tableName); } if(m_keySchemaHasBeenSet) { Array<JsonValue> keySchemaJsonList(m_keySchema.size()); for(unsigned keySchemaIndex = 0; keySchemaIndex < keySchemaJsonList.GetLength(); ++keySchemaIndex) { keySchemaJsonList[keySchemaIndex].AsObject(m_keySchema[keySchemaIndex].Jsonize()); } payload.WithArray("KeySchema", std::move(keySchemaJsonList)); } if(m_tableStatusHasBeenSet) { payload.WithString("TableStatus", TableStatusMapper::GetNameForTableStatus(m_tableStatus)); } if(m_creationDateTimeHasBeenSet) { payload.WithString("CreationDateTime", m_creationDateTime); } if(m_provisionedThroughputHasBeenSet) { payload.WithObject("ProvisionedThroughput", m_provisionedThroughput.Jsonize()); } if(m_tableSizeBytesHasBeenSet) { payload.WithInt64("TableSizeBytes", m_tableSizeBytes); } if(m_itemCountHasBeenSet) { payload.WithInt64("ItemCount", m_itemCount); } if(m_tableArnHasBeenSet) { payload.WithString("TableArn", m_tableArn); } if(m_localSecondaryIndexesHasBeenSet) { Array<JsonValue> localSecondaryIndexesJsonList(m_localSecondaryIndexes.size()); for(unsigned localSecondaryIndexesIndex = 0; localSecondaryIndexesIndex < localSecondaryIndexesJsonList.GetLength(); ++localSecondaryIndexesIndex) { localSecondaryIndexesJsonList[localSecondaryIndexesIndex].AsObject(m_localSecondaryIndexes[localSecondaryIndexesIndex].Jsonize()); } payload.WithArray("LocalSecondaryIndexes", std::move(localSecondaryIndexesJsonList)); } if(m_globalSecondaryIndexesHasBeenSet) { Array<JsonValue> globalSecondaryIndexesJsonList(m_globalSecondaryIndexes.size()); for(unsigned globalSecondaryIndexesIndex = 0; globalSecondaryIndexesIndex < globalSecondaryIndexesJsonList.GetLength(); ++globalSecondaryIndexesIndex) { globalSecondaryIndexesJsonList[globalSecondaryIndexesIndex].AsObject(m_globalSecondaryIndexes[globalSecondaryIndexesIndex].Jsonize()); } payload.WithArray("GlobalSecondaryIndexes", std::move(globalSecondaryIndexesJsonList)); } if(m_streamSpecificationHasBeenSet) { payload.WithObject("StreamSpecification", m_streamSpecification.Jsonize()); } if(m_latestStreamLabelHasBeenSet) { payload.WithString("LatestStreamLabel", m_latestStreamLabel); } if(m_latestStreamArnHasBeenSet) { payload.WithString("LatestStreamArn", m_latestStreamArn); } return std::move(payload); }
JsonValue ScheduleActivityTaskDecisionAttributes::Jsonize() const { JsonValue payload; if(m_activityTypeHasBeenSet) { payload.WithObject("activityType", m_activityType.Jsonize()); } if(m_activityIdHasBeenSet) { payload.WithString("activityId", m_activityId); } if(m_controlHasBeenSet) { payload.WithString("control", m_control); } if(m_inputHasBeenSet) { payload.WithString("input", m_input); } if(m_scheduleToCloseTimeoutHasBeenSet) { payload.WithString("scheduleToCloseTimeout", m_scheduleToCloseTimeout); } if(m_taskListHasBeenSet) { payload.WithObject("taskList", m_taskList.Jsonize()); } if(m_taskPriorityHasBeenSet) { payload.WithString("taskPriority", m_taskPriority); } if(m_scheduleToStartTimeoutHasBeenSet) { payload.WithString("scheduleToStartTimeout", m_scheduleToStartTimeout); } if(m_startToCloseTimeoutHasBeenSet) { payload.WithString("startToCloseTimeout", m_startToCloseTimeout); } if(m_heartbeatTimeoutHasBeenSet) { payload.WithString("heartbeatTimeout", m_heartbeatTimeout); } return payload; }
JsonValue Stack::Jsonize() const { JsonValue payload; if(m_stackIdHasBeenSet) { payload.WithString("StackId", m_stackId); } if(m_nameHasBeenSet) { payload.WithString("Name", m_name); } if(m_arnHasBeenSet) { payload.WithString("Arn", m_arn); } if(m_regionHasBeenSet) { payload.WithString("Region", m_region); } if(m_vpcIdHasBeenSet) { payload.WithString("VpcId", m_vpcId); } if(m_attributesHasBeenSet) { JsonValue attributesJsonMap; for(auto& attributesItem : m_attributes) { attributesJsonMap.WithString(StackAttributesKeysMapper::GetNameForStackAttributesKeys(attributesItem.first), attributesItem.second); } payload.WithObject("Attributes", std::move(attributesJsonMap)); } if(m_serviceRoleArnHasBeenSet) { payload.WithString("ServiceRoleArn", m_serviceRoleArn); } if(m_defaultInstanceProfileArnHasBeenSet) { payload.WithString("DefaultInstanceProfileArn", m_defaultInstanceProfileArn); } if(m_defaultOsHasBeenSet) { payload.WithString("DefaultOs", m_defaultOs); } if(m_hostnameThemeHasBeenSet) { payload.WithString("HostnameTheme", m_hostnameTheme); } if(m_defaultAvailabilityZoneHasBeenSet) { payload.WithString("DefaultAvailabilityZone", m_defaultAvailabilityZone); } if(m_defaultSubnetIdHasBeenSet) { payload.WithString("DefaultSubnetId", m_defaultSubnetId); } if(m_customJsonHasBeenSet) { payload.WithString("CustomJson", m_customJson); } if(m_configurationManagerHasBeenSet) { payload.WithObject("ConfigurationManager", m_configurationManager.Jsonize()); } if(m_chefConfigurationHasBeenSet) { payload.WithObject("ChefConfiguration", m_chefConfiguration.Jsonize()); } if(m_useCustomCookbooksHasBeenSet) { payload.WithBool("UseCustomCookbooks", m_useCustomCookbooks); } if(m_useOpsworksSecurityGroupsHasBeenSet) { payload.WithBool("UseOpsworksSecurityGroups", m_useOpsworksSecurityGroups); } if(m_customCookbooksSourceHasBeenSet) { payload.WithObject("CustomCookbooksSource", m_customCookbooksSource.Jsonize()); } if(m_defaultSshKeyNameHasBeenSet) { payload.WithString("DefaultSshKeyName", m_defaultSshKeyName); } if(m_createdAtHasBeenSet) { payload.WithString("CreatedAt", m_createdAt); } if(m_defaultRootDeviceTypeHasBeenSet) { payload.WithString("DefaultRootDeviceType", RootDeviceTypeMapper::GetNameForRootDeviceType(m_defaultRootDeviceType)); } if(m_agentVersionHasBeenSet) { payload.WithString("AgentVersion", m_agentVersion); } return payload; }
JsonValue Disk::Jsonize() const { JsonValue payload; if(m_nameHasBeenSet) { payload.WithString("name", m_name); } if(m_arnHasBeenSet) { payload.WithString("arn", m_arn); } if(m_supportCodeHasBeenSet) { payload.WithString("supportCode", m_supportCode); } if(m_createdAtHasBeenSet) { payload.WithDouble("createdAt", m_createdAt.SecondsWithMSPrecision()); } if(m_locationHasBeenSet) { payload.WithObject("location", m_location.Jsonize()); } if(m_resourceTypeHasBeenSet) { payload.WithString("resourceType", ResourceTypeMapper::GetNameForResourceType(m_resourceType)); } if(m_sizeInGbHasBeenSet) { payload.WithInteger("sizeInGb", m_sizeInGb); } if(m_gbInUseHasBeenSet) { payload.WithInteger("gbInUse", m_gbInUse); } if(m_isSystemDiskHasBeenSet) { payload.WithBool("isSystemDisk", m_isSystemDisk); } if(m_iopsHasBeenSet) { payload.WithInteger("iops", m_iops); } if(m_pathHasBeenSet) { payload.WithString("path", m_path); } if(m_attachedToHasBeenSet) { payload.WithString("attachedTo", m_attachedTo); } if(m_isAttachedHasBeenSet) { payload.WithBool("isAttached", m_isAttached); } if(m_attachmentStateHasBeenSet) { payload.WithString("attachmentState", m_attachmentState); } return payload; }
Aws::String CreateClusterRequest::SerializePayload() const { JsonValue payload; if(m_clusterNameHasBeenSet) { payload.WithString("ClusterName", m_clusterName); } if(m_nodeTypeHasBeenSet) { payload.WithString("NodeType", m_nodeType); } if(m_descriptionHasBeenSet) { payload.WithString("Description", m_description); } if(m_replicationFactorHasBeenSet) { payload.WithInteger("ReplicationFactor", m_replicationFactor); } if(m_availabilityZonesHasBeenSet) { Array<JsonValue> availabilityZonesJsonList(m_availabilityZones.size()); for(unsigned availabilityZonesIndex = 0; availabilityZonesIndex < availabilityZonesJsonList.GetLength(); ++availabilityZonesIndex) { availabilityZonesJsonList[availabilityZonesIndex].AsString(m_availabilityZones[availabilityZonesIndex]); } payload.WithArray("AvailabilityZones", std::move(availabilityZonesJsonList)); } if(m_subnetGroupNameHasBeenSet) { payload.WithString("SubnetGroupName", m_subnetGroupName); } if(m_securityGroupIdsHasBeenSet) { Array<JsonValue> securityGroupIdsJsonList(m_securityGroupIds.size()); for(unsigned securityGroupIdsIndex = 0; securityGroupIdsIndex < securityGroupIdsJsonList.GetLength(); ++securityGroupIdsIndex) { securityGroupIdsJsonList[securityGroupIdsIndex].AsString(m_securityGroupIds[securityGroupIdsIndex]); } payload.WithArray("SecurityGroupIds", std::move(securityGroupIdsJsonList)); } if(m_preferredMaintenanceWindowHasBeenSet) { payload.WithString("PreferredMaintenanceWindow", m_preferredMaintenanceWindow); } if(m_notificationTopicArnHasBeenSet) { payload.WithString("NotificationTopicArn", m_notificationTopicArn); } if(m_iamRoleArnHasBeenSet) { payload.WithString("IamRoleArn", m_iamRoleArn); } if(m_parameterGroupNameHasBeenSet) { payload.WithString("ParameterGroupName", m_parameterGroupName); } if(m_tagsHasBeenSet) { Array<JsonValue> tagsJsonList(m_tags.size()); for(unsigned tagsIndex = 0; tagsIndex < tagsJsonList.GetLength(); ++tagsIndex) { tagsJsonList[tagsIndex].AsObject(m_tags[tagsIndex].Jsonize()); } payload.WithArray("Tags", std::move(tagsJsonList)); } if(m_sSESpecificationHasBeenSet) { payload.WithObject("SSESpecification", m_sSESpecification.Jsonize()); } return payload.View().WriteReadable(); }
JsonValue JobData::Jsonize() const { JsonValue payload; if(m_actionTypeIdHasBeenSet) { payload.WithObject("actionTypeId", m_actionTypeId.Jsonize()); } if(m_actionConfigurationHasBeenSet) { payload.WithObject("actionConfiguration", m_actionConfiguration.Jsonize()); } if(m_pipelineContextHasBeenSet) { payload.WithObject("pipelineContext", m_pipelineContext.Jsonize()); } if(m_inputArtifactsHasBeenSet) { Array<JsonValue> inputArtifactsJsonList(m_inputArtifacts.size()); for(unsigned inputArtifactsIndex = 0; inputArtifactsIndex < inputArtifactsJsonList.GetLength(); ++inputArtifactsIndex) { inputArtifactsJsonList[inputArtifactsIndex].AsObject(m_inputArtifacts[inputArtifactsIndex].Jsonize()); } payload.WithArray("inputArtifacts", std::move(inputArtifactsJsonList)); } if(m_outputArtifactsHasBeenSet) { Array<JsonValue> outputArtifactsJsonList(m_outputArtifacts.size()); for(unsigned outputArtifactsIndex = 0; outputArtifactsIndex < outputArtifactsJsonList.GetLength(); ++outputArtifactsIndex) { outputArtifactsJsonList[outputArtifactsIndex].AsObject(m_outputArtifacts[outputArtifactsIndex].Jsonize()); } payload.WithArray("outputArtifacts", std::move(outputArtifactsJsonList)); } if(m_artifactCredentialsHasBeenSet) { payload.WithObject("artifactCredentials", m_artifactCredentials.Jsonize()); } if(m_continuationTokenHasBeenSet) { payload.WithString("continuationToken", m_continuationToken); } if(m_encryptionKeyHasBeenSet) { payload.WithObject("encryptionKey", m_encryptionKey.Jsonize()); } return payload; }
TEST_F(PersistentCognitoIdentityProvider_JsonImpl_Test, TestPersistance) { JsonValue someOtherIdentityPool; someOtherIdentityPool.WithString("IdentityId", "SomeOtherIdentity"); JsonValue identityDoc; identityDoc.WithObject("SomeOtherIdentityPool", someOtherIdentityPool); Aws::String filePath = tempFile; FileSystemUtils::RemoveFileIfExists(filePath.c_str()); std::ofstream identityFile(filePath.c_str()); identityFile << identityDoc.WriteReadable(); identityFile.close(); Aws::Map<Aws::String, LoginAccessTokens> loginsMap; LoginAccessTokens loginAccessTokens; loginAccessTokens.accessToken = "LoginValue"; loginAccessTokens.longTermTokenExpiry = 1001; loginAccessTokens.longTermToken = "LongTermToken"; loginsMap["LoginName"] = loginAccessTokens; //scope it to kill the cache and force it to reload from file. { PersistentCognitoIdentityProvider_JsonFileImpl identityProvider("IdentityPoolWeWant", "accountId", filePath.c_str()); EXPECT_FALSE(identityProvider.HasIdentityId()); EXPECT_FALSE(identityProvider.HasLogins()); bool identityCallbackFired = false; bool loginsCallbackFired = false; identityProvider.SetIdentityIdUpdatedCallback( [&](const PersistentCognitoIdentityProvider&){ identityCallbackFired = true; }); identityProvider.SetLoginsUpdatedCallback([&](const PersistentCognitoIdentityProvider&){ loginsCallbackFired = true; }); identityProvider.PersistIdentityId("IdentityWeWant"); identityProvider.PersistLogins(loginsMap); ASSERT_TRUE(identityCallbackFired); ASSERT_TRUE(loginsCallbackFired); } PersistentCognitoIdentityProvider_JsonFileImpl identityProvider("IdentityPoolWeWant", "accountId", filePath.c_str()); EXPECT_EQ("IdentityWeWant", identityProvider.GetIdentityId()); EXPECT_EQ("LoginName", identityProvider.GetLogins().begin()->first); EXPECT_EQ(loginAccessTokens.accessToken, identityProvider.GetLogins().begin()->second.accessToken); EXPECT_EQ(loginAccessTokens.longTermToken, identityProvider.GetLogins().begin()->second.longTermToken); EXPECT_EQ(loginAccessTokens.longTermTokenExpiry, identityProvider.GetLogins().begin()->second.longTermTokenExpiry); std::ifstream identityFileInput(filePath.c_str()); JsonValue finalIdentityDoc(identityFileInput); identityFileInput.close(); FileSystemUtils::RemoveFileIfExists(filePath.c_str()); ASSERT_TRUE(finalIdentityDoc.ValueExists("SomeOtherIdentityPool")); ASSERT_TRUE(finalIdentityDoc.ValueExists("IdentityPoolWeWant")); JsonValue ourIdentityPool = finalIdentityDoc.GetObject("IdentityPoolWeWant"); ASSERT_EQ("IdentityWeWant", ourIdentityPool.GetString("IdentityId")); ASSERT_EQ("LoginName", ourIdentityPool.GetObject("Logins").GetAllObjects().begin()->first); ASSERT_EQ(loginAccessTokens.accessToken, ourIdentityPool.GetObject("Logins").GetAllObjects().begin()->second.GetString("AccessToken")); ASSERT_EQ(loginAccessTokens.longTermToken, ourIdentityPool.GetObject("Logins").GetAllObjects().begin()->second.GetString("LongTermToken")); ASSERT_EQ(loginAccessTokens.longTermTokenExpiry, ourIdentityPool.GetObject("Logins").GetAllObjects().begin()->second.GetInt64("Expiry")); }
JsonValue Evaluation::Jsonize() const { JsonValue payload; if(m_evaluationIdHasBeenSet) { payload.WithString("EvaluationId", m_evaluationId); } if(m_mLModelIdHasBeenSet) { payload.WithString("MLModelId", m_mLModelId); } if(m_evaluationDataSourceIdHasBeenSet) { payload.WithString("EvaluationDataSourceId", m_evaluationDataSourceId); } if(m_inputDataLocationS3HasBeenSet) { payload.WithString("InputDataLocationS3", m_inputDataLocationS3); } if(m_createdByIamUserHasBeenSet) { payload.WithString("CreatedByIamUser", m_createdByIamUser); } if(m_createdAtHasBeenSet) { payload.WithDouble("CreatedAt", m_createdAt.SecondsWithMSPrecision()); } if(m_lastUpdatedAtHasBeenSet) { payload.WithDouble("LastUpdatedAt", m_lastUpdatedAt.SecondsWithMSPrecision()); } if(m_nameHasBeenSet) { payload.WithString("Name", m_name); } if(m_statusHasBeenSet) { payload.WithString("Status", EntityStatusMapper::GetNameForEntityStatus(m_status)); } if(m_performanceMetricsHasBeenSet) { payload.WithObject("PerformanceMetrics", m_performanceMetrics.Jsonize()); } if(m_messageHasBeenSet) { payload.WithString("Message", m_message); } return payload; }
JsonValue App::Jsonize() const { JsonValue payload; if(m_appIdHasBeenSet) { payload.WithString("AppId", m_appId); } if(m_stackIdHasBeenSet) { payload.WithString("StackId", m_stackId); } if(m_shortnameHasBeenSet) { payload.WithString("Shortname", m_shortname); } if(m_nameHasBeenSet) { payload.WithString("Name", m_name); } if(m_descriptionHasBeenSet) { payload.WithString("Description", m_description); } if(m_dataSourcesHasBeenSet) { Array<JsonValue> dataSourcesJsonList(m_dataSources.size()); for(unsigned dataSourcesIndex = 0; dataSourcesIndex < dataSourcesJsonList.GetLength(); ++dataSourcesIndex) { dataSourcesJsonList[dataSourcesIndex].AsObject(m_dataSources[dataSourcesIndex].Jsonize()); } payload.WithArray("DataSources", std::move(dataSourcesJsonList)); } if(m_typeHasBeenSet) { payload.WithString("Type", AppTypeMapper::GetNameForAppType(m_type)); } if(m_appSourceHasBeenSet) { payload.WithObject("AppSource", m_appSource.Jsonize()); } if(m_domainsHasBeenSet) { Array<JsonValue> domainsJsonList(m_domains.size()); for(unsigned domainsIndex = 0; domainsIndex < domainsJsonList.GetLength(); ++domainsIndex) { domainsJsonList[domainsIndex].AsString(m_domains[domainsIndex]); } payload.WithArray("Domains", std::move(domainsJsonList)); } if(m_enableSslHasBeenSet) { payload.WithBool("EnableSsl", m_enableSsl); } if(m_sslConfigurationHasBeenSet) { payload.WithObject("SslConfiguration", m_sslConfiguration.Jsonize()); } if(m_attributesHasBeenSet) { JsonValue attributesJsonMap; for(auto& attributesItem : m_attributes) { attributesJsonMap.WithString(AppAttributesKeysMapper::GetNameForAppAttributesKeys(attributesItem.first), attributesItem.second); } payload.WithObject("Attributes", std::move(attributesJsonMap)); } if(m_createdAtHasBeenSet) { payload.WithString("CreatedAt", m_createdAt); } if(m_environmentHasBeenSet) { Array<JsonValue> environmentJsonList(m_environment.size()); for(unsigned environmentIndex = 0; environmentIndex < environmentJsonList.GetLength(); ++environmentIndex) { environmentJsonList[environmentIndex].AsObject(m_environment[environmentIndex].Jsonize()); } payload.WithArray("Environment", std::move(environmentJsonList)); } return std::move(payload); }
JsonValue ReplicationInstance::Jsonize() const { JsonValue payload; if(m_replicationInstanceIdentifierHasBeenSet) { payload.WithString("ReplicationInstanceIdentifier", m_replicationInstanceIdentifier); } if(m_replicationInstanceClassHasBeenSet) { payload.WithString("ReplicationInstanceClass", m_replicationInstanceClass); } if(m_replicationInstanceStatusHasBeenSet) { payload.WithString("ReplicationInstanceStatus", m_replicationInstanceStatus); } if(m_allocatedStorageHasBeenSet) { payload.WithInteger("AllocatedStorage", m_allocatedStorage); } if(m_instanceCreateTimeHasBeenSet) { payload.WithDouble("InstanceCreateTime", m_instanceCreateTime.SecondsWithMSPrecision()); } if(m_vpcSecurityGroupsHasBeenSet) { Array<JsonValue> vpcSecurityGroupsJsonList(m_vpcSecurityGroups.size()); for(unsigned vpcSecurityGroupsIndex = 0; vpcSecurityGroupsIndex < vpcSecurityGroupsJsonList.GetLength(); ++vpcSecurityGroupsIndex) { vpcSecurityGroupsJsonList[vpcSecurityGroupsIndex].AsObject(m_vpcSecurityGroups[vpcSecurityGroupsIndex].Jsonize()); } payload.WithArray("VpcSecurityGroups", std::move(vpcSecurityGroupsJsonList)); } if(m_availabilityZoneHasBeenSet) { payload.WithString("AvailabilityZone", m_availabilityZone); } if(m_replicationSubnetGroupHasBeenSet) { payload.WithObject("ReplicationSubnetGroup", m_replicationSubnetGroup.Jsonize()); } if(m_preferredMaintenanceWindowHasBeenSet) { payload.WithString("PreferredMaintenanceWindow", m_preferredMaintenanceWindow); } if(m_pendingModifiedValuesHasBeenSet) { payload.WithObject("PendingModifiedValues", m_pendingModifiedValues.Jsonize()); } if(m_engineVersionHasBeenSet) { payload.WithString("EngineVersion", m_engineVersion); } if(m_autoMinorVersionUpgradeHasBeenSet) { payload.WithBool("AutoMinorVersionUpgrade", m_autoMinorVersionUpgrade); } if(m_kmsKeyIdHasBeenSet) { payload.WithString("KmsKeyId", m_kmsKeyId); } if(m_replicationInstanceArnHasBeenSet) { payload.WithString("ReplicationInstanceArn", m_replicationInstanceArn); } if(m_replicationInstancePublicIpAddressHasBeenSet) { payload.WithString("ReplicationInstancePublicIpAddress", m_replicationInstancePublicIpAddress); } if(m_replicationInstancePrivateIpAddressHasBeenSet) { payload.WithString("ReplicationInstancePrivateIpAddress", m_replicationInstancePrivateIpAddress); } if(m_publiclyAccessibleHasBeenSet) { payload.WithBool("PubliclyAccessible", m_publiclyAccessible); } return payload; }
JsonValue JobFlowInstancesDetail::Jsonize() const { JsonValue payload; if(m_masterInstanceTypeHasBeenSet) { payload.WithString("MasterInstanceType", m_masterInstanceType); } if(m_masterPublicDnsNameHasBeenSet) { payload.WithString("MasterPublicDnsName", m_masterPublicDnsName); } if(m_masterInstanceIdHasBeenSet) { payload.WithString("MasterInstanceId", m_masterInstanceId); } if(m_slaveInstanceTypeHasBeenSet) { payload.WithString("SlaveInstanceType", m_slaveInstanceType); } if(m_instanceCountHasBeenSet) { payload.WithInteger("InstanceCount", m_instanceCount); } if(m_instanceGroupsHasBeenSet) { Array<JsonValue> instanceGroupsJsonList(m_instanceGroups.size()); for(unsigned instanceGroupsIndex = 0; instanceGroupsIndex < instanceGroupsJsonList.GetLength(); ++instanceGroupsIndex) { instanceGroupsJsonList[instanceGroupsIndex].AsObject(m_instanceGroups[instanceGroupsIndex].Jsonize()); } payload.WithArray("InstanceGroups", std::move(instanceGroupsJsonList)); } if(m_normalizedInstanceHoursHasBeenSet) { payload.WithInteger("NormalizedInstanceHours", m_normalizedInstanceHours); } if(m_ec2KeyNameHasBeenSet) { payload.WithString("Ec2KeyName", m_ec2KeyName); } if(m_ec2SubnetIdHasBeenSet) { payload.WithString("Ec2SubnetId", m_ec2SubnetId); } if(m_placementHasBeenSet) { payload.WithObject("Placement", m_placement.Jsonize()); } if(m_keepJobFlowAliveWhenNoStepsHasBeenSet) { payload.WithBool("KeepJobFlowAliveWhenNoSteps", m_keepJobFlowAliveWhenNoSteps); } if(m_terminationProtectedHasBeenSet) { payload.WithBool("TerminationProtected", m_terminationProtected); } if(m_hadoopVersionHasBeenSet) { payload.WithString("HadoopVersion", m_hadoopVersion); } return payload; }
JsonValue InstanceGroup::Jsonize() const { JsonValue payload; if(m_idHasBeenSet) { payload.WithString("Id", m_id); } if(m_nameHasBeenSet) { payload.WithString("Name", m_name); } if(m_marketHasBeenSet) { payload.WithString("Market", MarketTypeMapper::GetNameForMarketType(m_market)); } if(m_instanceGroupTypeHasBeenSet) { payload.WithString("InstanceGroupType", InstanceGroupTypeMapper::GetNameForInstanceGroupType(m_instanceGroupType)); } if(m_bidPriceHasBeenSet) { payload.WithString("BidPrice", m_bidPrice); } if(m_instanceTypeHasBeenSet) { payload.WithString("InstanceType", m_instanceType); } if(m_requestedInstanceCountHasBeenSet) { payload.WithInteger("RequestedInstanceCount", m_requestedInstanceCount); } if(m_runningInstanceCountHasBeenSet) { payload.WithInteger("RunningInstanceCount", m_runningInstanceCount); } if(m_statusHasBeenSet) { payload.WithObject("Status", m_status.Jsonize()); } if(m_configurationsHasBeenSet) { Array<JsonValue> configurationsJsonList(m_configurations.size()); for(unsigned configurationsIndex = 0; configurationsIndex < configurationsJsonList.GetLength(); ++configurationsIndex) { configurationsJsonList[configurationsIndex].AsObject(m_configurations[configurationsIndex].Jsonize()); } payload.WithArray("Configurations", std::move(configurationsJsonList)); } if(m_ebsBlockDevicesHasBeenSet) { Array<JsonValue> ebsBlockDevicesJsonList(m_ebsBlockDevices.size()); for(unsigned ebsBlockDevicesIndex = 0; ebsBlockDevicesIndex < ebsBlockDevicesJsonList.GetLength(); ++ebsBlockDevicesIndex) { ebsBlockDevicesJsonList[ebsBlockDevicesIndex].AsObject(m_ebsBlockDevices[ebsBlockDevicesIndex].Jsonize()); } payload.WithArray("EbsBlockDevices", std::move(ebsBlockDevicesJsonList)); } if(m_ebsOptimizedHasBeenSet) { payload.WithBool("EbsOptimized", m_ebsOptimized); } if(m_shrinkPolicyHasBeenSet) { payload.WithObject("ShrinkPolicy", m_shrinkPolicy.Jsonize()); } return payload; }
Aws::String ModifyEndpointRequest::SerializePayload() const { JsonValue payload; if(m_endpointArnHasBeenSet) { payload.WithString("EndpointArn", m_endpointArn); } if(m_endpointIdentifierHasBeenSet) { payload.WithString("EndpointIdentifier", m_endpointIdentifier); } if(m_endpointTypeHasBeenSet) { payload.WithString("EndpointType", ReplicationEndpointTypeValueMapper::GetNameForReplicationEndpointTypeValue(m_endpointType)); } if(m_engineNameHasBeenSet) { payload.WithString("EngineName", m_engineName); } if(m_usernameHasBeenSet) { payload.WithString("Username", m_username); } if(m_passwordHasBeenSet) { payload.WithString("Password", m_password); } if(m_serverNameHasBeenSet) { payload.WithString("ServerName", m_serverName); } if(m_portHasBeenSet) { payload.WithInteger("Port", m_port); } if(m_databaseNameHasBeenSet) { payload.WithString("DatabaseName", m_databaseName); } if(m_extraConnectionAttributesHasBeenSet) { payload.WithString("ExtraConnectionAttributes", m_extraConnectionAttributes); } if(m_certificateArnHasBeenSet) { payload.WithString("CertificateArn", m_certificateArn); } if(m_sslModeHasBeenSet) { payload.WithString("SslMode", DmsSslModeValueMapper::GetNameForDmsSslModeValue(m_sslMode)); } if(m_serviceAccessRoleArnHasBeenSet) { payload.WithString("ServiceAccessRoleArn", m_serviceAccessRoleArn); } if(m_externalTableDefinitionHasBeenSet) { payload.WithString("ExternalTableDefinition", m_externalTableDefinition); } if(m_dynamoDbSettingsHasBeenSet) { payload.WithObject("DynamoDbSettings", m_dynamoDbSettings.Jsonize()); } if(m_s3SettingsHasBeenSet) { payload.WithObject("S3Settings", m_s3Settings.Jsonize()); } if(m_dmsTransferSettingsHasBeenSet) { payload.WithObject("DmsTransferSettings", m_dmsTransferSettings.Jsonize()); } if(m_mongoDbSettingsHasBeenSet) { payload.WithObject("MongoDbSettings", m_mongoDbSettings.Jsonize()); } return payload.View().WriteReadable(); }
JsonValue TraceSummary::Jsonize() const { JsonValue payload; if(m_idHasBeenSet) { payload.WithString("Id", m_id); } if(m_durationHasBeenSet) { payload.WithDouble("Duration", m_duration); } if(m_responseTimeHasBeenSet) { payload.WithDouble("ResponseTime", m_responseTime); } if(m_hasFaultHasBeenSet) { payload.WithBool("HasFault", m_hasFault); } if(m_hasErrorHasBeenSet) { payload.WithBool("HasError", m_hasError); } if(m_hasThrottleHasBeenSet) { payload.WithBool("HasThrottle", m_hasThrottle); } if(m_isPartialHasBeenSet) { payload.WithBool("IsPartial", m_isPartial); } if(m_httpHasBeenSet) { payload.WithObject("Http", m_http.Jsonize()); } if(m_annotationsHasBeenSet) { JsonValue annotationsJsonMap; for(auto& annotationsItem : m_annotations) { Array<JsonValue> valuesWithServiceIdsJsonList(annotationsItem.second.size()); for(unsigned valuesWithServiceIdsIndex = 0; valuesWithServiceIdsIndex < valuesWithServiceIdsJsonList.GetLength(); ++valuesWithServiceIdsIndex) { valuesWithServiceIdsJsonList[valuesWithServiceIdsIndex].AsObject(annotationsItem.second[valuesWithServiceIdsIndex].Jsonize()); } annotationsJsonMap.WithArray(annotationsItem.first, std::move(valuesWithServiceIdsJsonList)); } payload.WithObject("Annotations", std::move(annotationsJsonMap)); } if(m_usersHasBeenSet) { Array<JsonValue> usersJsonList(m_users.size()); for(unsigned usersIndex = 0; usersIndex < usersJsonList.GetLength(); ++usersIndex) { usersJsonList[usersIndex].AsObject(m_users[usersIndex].Jsonize()); } payload.WithArray("Users", std::move(usersJsonList)); } if(m_serviceIdsHasBeenSet) { Array<JsonValue> serviceIdsJsonList(m_serviceIds.size()); for(unsigned serviceIdsIndex = 0; serviceIdsIndex < serviceIdsJsonList.GetLength(); ++serviceIdsIndex) { serviceIdsJsonList[serviceIdsIndex].AsObject(m_serviceIds[serviceIdsIndex].Jsonize()); } payload.WithArray("ServiceIds", std::move(serviceIdsJsonList)); } return payload; }
JsonValue ContinueAsNewWorkflowExecutionDecisionAttributes::Jsonize() const { JsonValue payload; if(m_inputHasBeenSet) { payload.WithString("input", m_input); } if(m_executionStartToCloseTimeoutHasBeenSet) { payload.WithString("executionStartToCloseTimeout", m_executionStartToCloseTimeout); } if(m_taskListHasBeenSet) { payload.WithObject("taskList", m_taskList.Jsonize()); } if(m_taskPriorityHasBeenSet) { payload.WithString("taskPriority", m_taskPriority); } if(m_taskStartToCloseTimeoutHasBeenSet) { payload.WithString("taskStartToCloseTimeout", m_taskStartToCloseTimeout); } if(m_childPolicyHasBeenSet) { payload.WithString("childPolicy", ChildPolicyMapper::GetNameForChildPolicy(m_childPolicy)); } if(m_tagListHasBeenSet) { Array<JsonValue> tagListJsonList(m_tagList.size()); for(unsigned tagListIndex = 0; tagListIndex < tagListJsonList.GetLength(); ++tagListIndex) { tagListJsonList[tagListIndex].AsString(m_tagList[tagListIndex]); } payload.WithArray("tagList", std::move(tagListJsonList)); } if(m_workflowTypeVersionHasBeenSet) { payload.WithString("workflowTypeVersion", m_workflowTypeVersion); } if(m_lambdaRoleHasBeenSet) { payload.WithString("lambdaRole", m_lambdaRole); } return payload; }
JsonValue UserPoolClientType::Jsonize() const { JsonValue payload; if(m_userPoolIdHasBeenSet) { payload.WithString("UserPoolId", m_userPoolId); } if(m_clientNameHasBeenSet) { payload.WithString("ClientName", m_clientName); } if(m_clientIdHasBeenSet) { payload.WithString("ClientId", m_clientId); } if(m_clientSecretHasBeenSet) { payload.WithString("ClientSecret", m_clientSecret); } if(m_lastModifiedDateHasBeenSet) { payload.WithDouble("LastModifiedDate", m_lastModifiedDate.SecondsWithMSPrecision()); } if(m_creationDateHasBeenSet) { payload.WithDouble("CreationDate", m_creationDate.SecondsWithMSPrecision()); } if(m_refreshTokenValidityHasBeenSet) { payload.WithInteger("RefreshTokenValidity", m_refreshTokenValidity); } if(m_readAttributesHasBeenSet) { Array<JsonValue> readAttributesJsonList(m_readAttributes.size()); for(unsigned readAttributesIndex = 0; readAttributesIndex < readAttributesJsonList.GetLength(); ++readAttributesIndex) { readAttributesJsonList[readAttributesIndex].AsString(m_readAttributes[readAttributesIndex]); } payload.WithArray("ReadAttributes", std::move(readAttributesJsonList)); } if(m_writeAttributesHasBeenSet) { Array<JsonValue> writeAttributesJsonList(m_writeAttributes.size()); for(unsigned writeAttributesIndex = 0; writeAttributesIndex < writeAttributesJsonList.GetLength(); ++writeAttributesIndex) { writeAttributesJsonList[writeAttributesIndex].AsString(m_writeAttributes[writeAttributesIndex]); } payload.WithArray("WriteAttributes", std::move(writeAttributesJsonList)); } if(m_explicitAuthFlowsHasBeenSet) { Array<JsonValue> explicitAuthFlowsJsonList(m_explicitAuthFlows.size()); for(unsigned explicitAuthFlowsIndex = 0; explicitAuthFlowsIndex < explicitAuthFlowsJsonList.GetLength(); ++explicitAuthFlowsIndex) { explicitAuthFlowsJsonList[explicitAuthFlowsIndex].AsString(ExplicitAuthFlowsTypeMapper::GetNameForExplicitAuthFlowsType(m_explicitAuthFlows[explicitAuthFlowsIndex])); } payload.WithArray("ExplicitAuthFlows", std::move(explicitAuthFlowsJsonList)); } if(m_supportedIdentityProvidersHasBeenSet) { Array<JsonValue> supportedIdentityProvidersJsonList(m_supportedIdentityProviders.size()); for(unsigned supportedIdentityProvidersIndex = 0; supportedIdentityProvidersIndex < supportedIdentityProvidersJsonList.GetLength(); ++supportedIdentityProvidersIndex) { supportedIdentityProvidersJsonList[supportedIdentityProvidersIndex].AsString(m_supportedIdentityProviders[supportedIdentityProvidersIndex]); } payload.WithArray("SupportedIdentityProviders", std::move(supportedIdentityProvidersJsonList)); } if(m_callbackURLsHasBeenSet) { Array<JsonValue> callbackURLsJsonList(m_callbackURLs.size()); for(unsigned callbackURLsIndex = 0; callbackURLsIndex < callbackURLsJsonList.GetLength(); ++callbackURLsIndex) { callbackURLsJsonList[callbackURLsIndex].AsString(m_callbackURLs[callbackURLsIndex]); } payload.WithArray("CallbackURLs", std::move(callbackURLsJsonList)); } if(m_logoutURLsHasBeenSet) { Array<JsonValue> logoutURLsJsonList(m_logoutURLs.size()); for(unsigned logoutURLsIndex = 0; logoutURLsIndex < logoutURLsJsonList.GetLength(); ++logoutURLsIndex) { logoutURLsJsonList[logoutURLsIndex].AsString(m_logoutURLs[logoutURLsIndex]); } payload.WithArray("LogoutURLs", std::move(logoutURLsJsonList)); } if(m_defaultRedirectURIHasBeenSet) { payload.WithString("DefaultRedirectURI", m_defaultRedirectURI); } if(m_allowedOAuthFlowsHasBeenSet) { Array<JsonValue> allowedOAuthFlowsJsonList(m_allowedOAuthFlows.size()); for(unsigned allowedOAuthFlowsIndex = 0; allowedOAuthFlowsIndex < allowedOAuthFlowsJsonList.GetLength(); ++allowedOAuthFlowsIndex) { allowedOAuthFlowsJsonList[allowedOAuthFlowsIndex].AsString(OAuthFlowTypeMapper::GetNameForOAuthFlowType(m_allowedOAuthFlows[allowedOAuthFlowsIndex])); } payload.WithArray("AllowedOAuthFlows", std::move(allowedOAuthFlowsJsonList)); } if(m_allowedOAuthScopesHasBeenSet) { Array<JsonValue> allowedOAuthScopesJsonList(m_allowedOAuthScopes.size()); for(unsigned allowedOAuthScopesIndex = 0; allowedOAuthScopesIndex < allowedOAuthScopesJsonList.GetLength(); ++allowedOAuthScopesIndex) { allowedOAuthScopesJsonList[allowedOAuthScopesIndex].AsString(m_allowedOAuthScopes[allowedOAuthScopesIndex]); } payload.WithArray("AllowedOAuthScopes", std::move(allowedOAuthScopesJsonList)); } if(m_allowedOAuthFlowsUserPoolClientHasBeenSet) { payload.WithBool("AllowedOAuthFlowsUserPoolClient", m_allowedOAuthFlowsUserPoolClient); } if(m_analyticsConfigurationHasBeenSet) { payload.WithObject("AnalyticsConfiguration", m_analyticsConfiguration.Jsonize()); } return payload; }
Aws::String RegisterWorkflowTypeRequest::SerializePayload() const { JsonValue payload; if(m_domainHasBeenSet) { payload.WithString("domain", m_domain); } if(m_nameHasBeenSet) { payload.WithString("name", m_name); } if(m_versionHasBeenSet) { payload.WithString("version", m_version); } if(m_descriptionHasBeenSet) { payload.WithString("description", m_description); } if(m_defaultTaskStartToCloseTimeoutHasBeenSet) { payload.WithString("defaultTaskStartToCloseTimeout", m_defaultTaskStartToCloseTimeout); } if(m_defaultExecutionStartToCloseTimeoutHasBeenSet) { payload.WithString("defaultExecutionStartToCloseTimeout", m_defaultExecutionStartToCloseTimeout); } if(m_defaultTaskListHasBeenSet) { payload.WithObject("defaultTaskList", m_defaultTaskList.Jsonize()); } if(m_defaultTaskPriorityHasBeenSet) { payload.WithString("defaultTaskPriority", m_defaultTaskPriority); } if(m_defaultChildPolicyHasBeenSet) { payload.WithString("defaultChildPolicy", ChildPolicyMapper::GetNameForChildPolicy(m_defaultChildPolicy)); } if(m_defaultLambdaRoleHasBeenSet) { payload.WithString("defaultLambdaRole", m_defaultLambdaRole); } return payload.WriteReadable(); }
Aws::String CreateJobRequest::SerializePayload() const { JsonValue payload; if(m_jobTypeHasBeenSet) { payload.WithString("JobType", JobTypeMapper::GetNameForJobType(m_jobType)); } if(m_resourcesHasBeenSet) { payload.WithObject("Resources", m_resources.Jsonize()); } if(m_descriptionHasBeenSet) { payload.WithString("Description", m_description); } if(m_addressIdHasBeenSet) { payload.WithString("AddressId", m_addressId); } if(m_kmsKeyARNHasBeenSet) { payload.WithString("KmsKeyARN", m_kmsKeyARN); } if(m_roleARNHasBeenSet) { payload.WithString("RoleARN", m_roleARN); } if(m_snowballCapacityPreferenceHasBeenSet) { payload.WithString("SnowballCapacityPreference", SnowballCapacityMapper::GetNameForSnowballCapacity(m_snowballCapacityPreference)); } if(m_shippingOptionHasBeenSet) { payload.WithString("ShippingOption", ShippingOptionMapper::GetNameForShippingOption(m_shippingOption)); } if(m_notificationHasBeenSet) { payload.WithObject("Notification", m_notification.Jsonize()); } if(m_clusterIdHasBeenSet) { payload.WithString("ClusterId", m_clusterId); } if(m_snowballTypeHasBeenSet) { payload.WithString("SnowballType", SnowballTypeMapper::GetNameForSnowballType(m_snowballType)); } if(m_forwardingAddressIdHasBeenSet) { payload.WithString("ForwardingAddressId", m_forwardingAddressId); } return payload.WriteReadable(); }
JsonValue Finding::Jsonize() const { JsonValue payload; if(m_findingArnHasBeenSet) { payload.WithString("findingArn", m_findingArn); } if(m_runArnHasBeenSet) { payload.WithString("runArn", m_runArn); } if(m_rulesPackageArnHasBeenSet) { payload.WithString("rulesPackageArn", m_rulesPackageArn); } if(m_ruleNameHasBeenSet) { payload.WithString("ruleName", m_ruleName); } if(m_agentIdHasBeenSet) { payload.WithString("agentId", m_agentId); } if(m_autoScalingGroupHasBeenSet) { payload.WithString("autoScalingGroup", m_autoScalingGroup); } if(m_severityHasBeenSet) { payload.WithString("severity", m_severity); } if(m_findingHasBeenSet) { payload.WithObject("finding", m_finding.Jsonize()); } if(m_descriptionHasBeenSet) { payload.WithObject("description", m_description.Jsonize()); } if(m_recommendationHasBeenSet) { payload.WithObject("recommendation", m_recommendation.Jsonize()); } if(m_attributesHasBeenSet) { Array<JsonValue> attributesJsonList(m_attributes.size()); for(unsigned attributesIndex = 0; attributesIndex < attributesJsonList.GetLength(); ++attributesIndex) { attributesJsonList[attributesIndex].AsObject(m_attributes[attributesIndex].Jsonize()); } payload.WithArray("attributes", std::move(attributesJsonList)); } if(m_userAttributesHasBeenSet) { Array<JsonValue> userAttributesJsonList(m_userAttributes.size()); for(unsigned userAttributesIndex = 0; userAttributesIndex < userAttributesJsonList.GetLength(); ++userAttributesIndex) { userAttributesJsonList[userAttributesIndex].AsObject(m_userAttributes[userAttributesIndex].Jsonize()); } payload.WithArray("userAttributes", std::move(userAttributesJsonList)); } return payload; }
JsonValue GrantListEntry::Jsonize() const { JsonValue payload; if(m_keyIdHasBeenSet) { payload.WithString("KeyId", m_keyId); } if(m_grantIdHasBeenSet) { payload.WithString("GrantId", m_grantId); } if(m_nameHasBeenSet) { payload.WithString("Name", m_name); } if(m_creationDateHasBeenSet) { payload.WithDouble("CreationDate", m_creationDate.SecondsWithMSPrecision()); } if(m_granteePrincipalHasBeenSet) { payload.WithString("GranteePrincipal", m_granteePrincipal); } if(m_retiringPrincipalHasBeenSet) { payload.WithString("RetiringPrincipal", m_retiringPrincipal); } if(m_issuingAccountHasBeenSet) { payload.WithString("IssuingAccount", m_issuingAccount); } if(m_operationsHasBeenSet) { Array<JsonValue> operationsJsonList(m_operations.size()); for(unsigned operationsIndex = 0; operationsIndex < operationsJsonList.GetLength(); ++operationsIndex) { operationsJsonList[operationsIndex].AsString(GrantOperationMapper::GetNameForGrantOperation(m_operations[operationsIndex])); } payload.WithArray("Operations", std::move(operationsJsonList)); } if(m_constraintsHasBeenSet) { payload.WithObject("Constraints", m_constraints.Jsonize()); } return payload; }
Aws::String CreateAssociationRequest::SerializePayload() const { JsonValue payload; if(m_nameHasBeenSet) { payload.WithString("Name", m_name); } if(m_documentVersionHasBeenSet) { payload.WithString("DocumentVersion", m_documentVersion); } if(m_instanceIdHasBeenSet) { payload.WithString("InstanceId", m_instanceId); } if(m_parametersHasBeenSet) { JsonValue parametersJsonMap; for(auto& parametersItem : m_parameters) { Array<JsonValue> parameterValueListJsonList(parametersItem.second.size()); for(unsigned parameterValueListIndex = 0; parameterValueListIndex < parameterValueListJsonList.GetLength(); ++parameterValueListIndex) { parameterValueListJsonList[parameterValueListIndex].AsString(parametersItem.second[parameterValueListIndex]); } parametersJsonMap.WithArray(parametersItem.first, std::move(parameterValueListJsonList)); } payload.WithObject("Parameters", std::move(parametersJsonMap)); } if(m_targetsHasBeenSet) { Array<JsonValue> targetsJsonList(m_targets.size()); for(unsigned targetsIndex = 0; targetsIndex < targetsJsonList.GetLength(); ++targetsIndex) { targetsJsonList[targetsIndex].AsObject(m_targets[targetsIndex].Jsonize()); } payload.WithArray("Targets", std::move(targetsJsonList)); } if(m_scheduleExpressionHasBeenSet) { payload.WithString("ScheduleExpression", m_scheduleExpression); } if(m_outputLocationHasBeenSet) { payload.WithObject("OutputLocation", m_outputLocation.Jsonize()); } return payload.WriteReadable(); }