当前位置: 首页>>代码示例>>C++>>正文


C++ JsonValue::WithBool方法代码示例

本文整理汇总了C++中JsonValue::WithBool方法的典型用法代码示例。如果您正苦于以下问题:C++ JsonValue::WithBool方法的具体用法?C++ JsonValue::WithBool怎么用?C++ JsonValue::WithBool使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在JsonValue的用法示例。


在下文中一共展示了JsonValue::WithBool方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。

示例1: Jsonize

JsonValue AssessmentsFilter::Jsonize() const
{
  JsonValue payload;

  if(m_assessmentNamePatternsHasBeenSet)
  {
   Array<JsonValue> assessmentNamePatternsJsonList(m_assessmentNamePatterns.size());
   for(unsigned assessmentNamePatternsIndex = 0; assessmentNamePatternsIndex < assessmentNamePatternsJsonList.GetLength(); ++assessmentNamePatternsIndex)
   {
     assessmentNamePatternsJsonList[assessmentNamePatternsIndex].AsString(m_assessmentNamePatterns[assessmentNamePatternsIndex]);
   }
   payload.WithArray("assessmentNamePatterns", std::move(assessmentNamePatternsJsonList));

  }

  if(m_assessmentStatesHasBeenSet)
  {
   Array<JsonValue> assessmentStatesJsonList(m_assessmentStates.size());
   for(unsigned assessmentStatesIndex = 0; assessmentStatesIndex < assessmentStatesJsonList.GetLength(); ++assessmentStatesIndex)
   {
     assessmentStatesJsonList[assessmentStatesIndex].AsString(m_assessmentStates[assessmentStatesIndex]);
   }
   payload.WithArray("assessmentStates", std::move(assessmentStatesJsonList));

  }

  if(m_dataCollectedHasBeenSet)
  {
   payload.WithBool("dataCollected", m_dataCollected);

  }

  if(m_startTimeRangeHasBeenSet)
  {
   payload.WithObject("startTimeRange", m_startTimeRange.Jsonize());

  }

  if(m_endTimeRangeHasBeenSet)
  {
   payload.WithObject("endTimeRange", m_endTimeRange.Jsonize());

  }

  if(m_durationRangeHasBeenSet)
  {
   payload.WithObject("durationRange", m_durationRange.Jsonize());

  }

  return payload;
}
开发者ID:ukjhsa,项目名称:aws-sdk-cpp,代码行数:52,代码来源:AssessmentsFilter.cpp

示例2: Jsonize

JsonValue ProfileData::Jsonize() const
{
  JsonValue payload;

  if(m_profileArnHasBeenSet)
  {
   payload.WithString("ProfileArn", m_profileArn);

  }

  if(m_profileNameHasBeenSet)
  {
   payload.WithString("ProfileName", m_profileName);

  }

  if(m_isDefaultHasBeenSet)
  {
   payload.WithBool("IsDefault", m_isDefault);

  }

  if(m_addressHasBeenSet)
  {
   payload.WithString("Address", m_address);

  }

  if(m_timezoneHasBeenSet)
  {
   payload.WithString("Timezone", m_timezone);

  }

  if(m_distanceUnitHasBeenSet)
  {
   payload.WithString("DistanceUnit", DistanceUnitMapper::GetNameForDistanceUnit(m_distanceUnit));
  }

  if(m_temperatureUnitHasBeenSet)
  {
   payload.WithString("TemperatureUnit", TemperatureUnitMapper::GetNameForTemperatureUnit(m_temperatureUnit));
  }

  if(m_wakeWordHasBeenSet)
  {
   payload.WithString("WakeWord", WakeWordMapper::GetNameForWakeWord(m_wakeWord));
  }

  return payload;
}
开发者ID:aws,项目名称:aws-sdk-cpp,代码行数:51,代码来源:ProfileData.cpp

示例3: Jsonize

JsonValue ConfigurationRecorderStatus::Jsonize() const
{
  JsonValue payload;

  if(m_nameHasBeenSet)
  {
   payload.WithString("name", m_name);

  }

  if(m_lastStartTimeHasBeenSet)
  {
   payload.WithDouble("lastStartTime", m_lastStartTime.SecondsWithMSPrecision());
  }

  if(m_lastStopTimeHasBeenSet)
  {
   payload.WithDouble("lastStopTime", m_lastStopTime.SecondsWithMSPrecision());
  }

  if(m_recordingHasBeenSet)
  {
   payload.WithBool("recording", m_recording);

  }

  if(m_lastStatusHasBeenSet)
  {
   payload.WithString("lastStatus", RecorderStatusMapper::GetNameForRecorderStatus(m_lastStatus));
  }

  if(m_lastErrorCodeHasBeenSet)
  {
   payload.WithString("lastErrorCode", m_lastErrorCode);

  }

  if(m_lastErrorMessageHasBeenSet)
  {
   payload.WithString("lastErrorMessage", m_lastErrorMessage);

  }

  if(m_lastStatusChangeTimeHasBeenSet)
  {
   payload.WithDouble("lastStatusChangeTime", m_lastStatusChangeTime.SecondsWithMSPrecision());
  }

  return payload;
}
开发者ID:jliang1010,项目名称:aws-sdk-cpp,代码行数:50,代码来源:ConfigurationRecorderStatus.cpp

示例4: Jsonize

JsonValue Permission::Jsonize() const
{
  JsonValue payload;

  if(m_stackIdHasBeenSet)
  {
   payload.WithString("StackId", m_stackId);

  }

  if(m_iamUserArnHasBeenSet)
  {
   payload.WithString("IamUserArn", m_iamUserArn);

  }

  if(m_allowSshHasBeenSet)
  {
   payload.WithBool("AllowSsh", m_allowSsh);

  }

  if(m_allowSudoHasBeenSet)
  {
   payload.WithBool("AllowSudo", m_allowSudo);

  }

  if(m_levelHasBeenSet)
  {
   payload.WithString("Level", m_level);

  }

  return payload;
}
开发者ID:Fahrenheit2539,项目名称:aws-sdk-cpp,代码行数:36,代码来源:Permission.cpp

示例5: SerializePayload

Aws::String SetPermissionRequest::SerializePayload() const
{
  JsonValue payload;

  if(m_stackIdHasBeenSet)
  {
   payload.WithString("StackId", m_stackId);

  }

  if(m_iamUserArnHasBeenSet)
  {
   payload.WithString("IamUserArn", m_iamUserArn);

  }

  if(m_allowSshHasBeenSet)
  {
   payload.WithBool("AllowSsh", m_allowSsh);

  }

  if(m_allowSudoHasBeenSet)
  {
   payload.WithBool("AllowSudo", m_allowSudo);

  }

  if(m_levelHasBeenSet)
  {
   payload.WithString("Level", m_level);

  }

  return payload.WriteReadable();
}
开发者ID:wrtcoder,项目名称:aws-sdk-cpp,代码行数:36,代码来源:SetPermissionRequest.cpp

示例6: SerializePayload

Aws::String GetLogEventsRequest::SerializePayload() const
{
  JsonValue payload;

  if(m_logGroupNameHasBeenSet)
  {
   payload.WithString("logGroupName", m_logGroupName);

  }

  if(m_logStreamNameHasBeenSet)
  {
   payload.WithString("logStreamName", m_logStreamName);

  }

  if(m_startTimeHasBeenSet)
  {
   payload.WithInt64("startTime", m_startTime);

  }

  if(m_endTimeHasBeenSet)
  {
   payload.WithInt64("endTime", m_endTime);

  }

  if(m_nextTokenHasBeenSet)
  {
   payload.WithString("nextToken", m_nextToken);

  }

  if(m_limitHasBeenSet)
  {
   payload.WithInteger("limit", m_limit);

  }

  if(m_startFromHeadHasBeenSet)
  {
   payload.WithBool("startFromHead", m_startFromHead);

  }

  return payload.WriteReadable();
}
开发者ID:Bu11etmagnet,项目名称:aws-sdk-cpp,代码行数:48,代码来源:GetLogEventsRequest.cpp

示例7: SerializePayload

Aws::String ListCommandInvocationsRequest::SerializePayload() const
{
  JsonValue payload;

  if(m_commandIdHasBeenSet)
  {
   payload.WithString("CommandId", m_commandId);

  }

  if(m_instanceIdHasBeenSet)
  {
   payload.WithString("InstanceId", m_instanceId);

  }

  if(m_maxResultsHasBeenSet)
  {
   payload.WithInteger("MaxResults", m_maxResults);

  }

  if(m_nextTokenHasBeenSet)
  {
   payload.WithString("NextToken", m_nextToken);

  }

  if(m_filtersHasBeenSet)
  {
   Array<JsonValue> filtersJsonList(m_filters.size());
   for(unsigned filtersIndex = 0; filtersIndex < filtersJsonList.GetLength(); ++filtersIndex)
   {
     filtersJsonList[filtersIndex].AsObject(m_filters[filtersIndex].Jsonize());
   }
   payload.WithArray("Filters", std::move(filtersJsonList));

  }

  if(m_detailsHasBeenSet)
  {
   payload.WithBool("Details", m_details);

  }

  return payload.WriteReadable();
}
开发者ID:capeanalytics,项目名称:aws-sdk-cpp,代码行数:47,代码来源:ListCommandInvocationsRequest.cpp

示例8: SerializePayload

Aws::String ListDiscoveredResourcesRequest::SerializePayload() const
{
  JsonValue payload;

  if(m_resourceTypeHasBeenSet)
  {
   payload.WithString("resourceType", ResourceTypeMapper::GetNameForResourceType(m_resourceType));
  }

  if(m_resourceIdsHasBeenSet)
  {
   Array<JsonValue> resourceIdsJsonList(m_resourceIds.size());
   for(unsigned resourceIdsIndex = 0; resourceIdsIndex < resourceIdsJsonList.GetLength(); ++resourceIdsIndex)
   {
     resourceIdsJsonList[resourceIdsIndex].AsString(m_resourceIds[resourceIdsIndex]);
   }
   payload.WithArray("resourceIds", std::move(resourceIdsJsonList));

  }

  if(m_resourceNameHasBeenSet)
  {
   payload.WithString("resourceName", m_resourceName);

  }

  if(m_limitHasBeenSet)
  {
   payload.WithInteger("limit", m_limit);

  }

  if(m_includeDeletedResourcesHasBeenSet)
  {
   payload.WithBool("includeDeletedResources", m_includeDeletedResources);

  }

  if(m_nextTokenHasBeenSet)
  {
   payload.WithString("nextToken", m_nextToken);

  }

  return payload.WriteReadable();
}
开发者ID:Bu11etmagnet,项目名称:aws-sdk-cpp,代码行数:46,代码来源:ListDiscoveredResourcesRequest.cpp

示例9: SerializePayload

Aws::String CreateDeploymentRequest::SerializePayload() const
{
  JsonValue payload;

  if(m_stageNameHasBeenSet)
  {
   payload.WithString("stageName", m_stageName);

  }

  if(m_stageDescriptionHasBeenSet)
  {
   payload.WithString("stageDescription", m_stageDescription);

  }

  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));

  }

  return payload.WriteReadable();
}
开发者ID:chadbrewbaker,项目名称:aws-sdk-cpp,代码行数:46,代码来源:CreateDeploymentRequest.cpp

示例10: Jsonize

JsonValue DockerVolumeConfiguration::Jsonize() const
{
  JsonValue payload;

  if(m_scopeHasBeenSet)
  {
   payload.WithString("scope", ScopeMapper::GetNameForScope(m_scope));
  }

  if(m_autoprovisionHasBeenSet)
  {
   payload.WithBool("autoprovision", m_autoprovision);

  }

  if(m_driverHasBeenSet)
  {
   payload.WithString("driver", m_driver);

  }

  if(m_driverOptsHasBeenSet)
  {
   JsonValue driverOptsJsonMap;
   for(auto& driverOptsItem : m_driverOpts)
   {
     driverOptsJsonMap.WithString(driverOptsItem.first, driverOptsItem.second);
   }
   payload.WithObject("driverOpts", std::move(driverOptsJsonMap));

  }

  if(m_labelsHasBeenSet)
  {
   JsonValue labelsJsonMap;
   for(auto& labelsItem : m_labels)
   {
     labelsJsonMap.WithString(labelsItem.first, labelsItem.second);
   }
   payload.WithObject("labels", std::move(labelsJsonMap));

  }

  return payload;
}
开发者ID:marcomagdy,项目名称:aws-sdk-cpp,代码行数:45,代码来源:DockerVolumeConfiguration.cpp

示例11: SerializePayload

Aws::String DeleteTrustRequest::SerializePayload() const
{
  JsonValue payload;

  if(m_trustIdHasBeenSet)
  {
   payload.WithString("TrustId", m_trustId);

  }

  if(m_deleteAssociatedConditionalForwarderHasBeenSet)
  {
   payload.WithBool("DeleteAssociatedConditionalForwarder", m_deleteAssociatedConditionalForwarder);

  }

  return payload.View().WriteReadable();
}
开发者ID:marcomagdy,项目名称:aws-sdk-cpp,代码行数:18,代码来源:DeleteTrustRequest.cpp

示例12: Jsonize

JsonValue TimeToLiveSpecification::Jsonize() const
{
  JsonValue payload;

  if(m_enabledHasBeenSet)
  {
   payload.WithBool("Enabled", m_enabled);

  }

  if(m_attributeNameHasBeenSet)
  {
   payload.WithString("AttributeName", m_attributeName);

  }

  return payload;
}
开发者ID:marcomagdy,项目名称:aws-sdk-cpp,代码行数:18,代码来源:TimeToLiveSpecification.cpp

示例13: SerializePayload

Aws::String GetBundlesRequest::SerializePayload() const
{
  JsonValue payload;

  if(m_includeInactiveHasBeenSet)
  {
   payload.WithBool("includeInactive", m_includeInactive);

  }

  if(m_pageTokenHasBeenSet)
  {
   payload.WithString("pageToken", m_pageToken);

  }

  return payload.WriteReadable();
}
开发者ID:capeanalytics,项目名称:aws-sdk-cpp,代码行数:18,代码来源:GetBundlesRequest.cpp

示例14: Jsonize

JsonValue Beard::Jsonize() const
{
  JsonValue payload;

  if(m_valueHasBeenSet)
  {
   payload.WithBool("Value", m_value);

  }

  if(m_confidenceHasBeenSet)
  {
   payload.WithDouble("Confidence", m_confidence);

  }

  return payload;
}
开发者ID:chadbrewbaker,项目名称:aws-sdk-cpp,代码行数:18,代码来源:Beard.cpp

示例15: Jsonize

JsonValue SMSChannelRequest::Jsonize() const
{
  JsonValue payload;

  if(m_enabledHasBeenSet)
  {
   payload.WithBool("Enabled", m_enabled);

  }

  if(m_senderIdHasBeenSet)
  {
   payload.WithString("SenderId", m_senderId);

  }

  return payload;
}
开发者ID:svagionitis,项目名称:aws-sdk-cpp,代码行数:18,代码来源:SMSChannelRequest.cpp


注:本文中的JsonValue::WithBool方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。