This repository has been archived on 2025-09-14. You can view files and clone it, but cannot push or open issues or pull requests.
Files
pxz-hos-client-cpp-module/support/aws-sdk-cpp-master/aws-cpp-sdk-sagemaker/source/model/AwsManagedHumanLoopRequestSource.cpp

71 lines
2.6 KiB
C++
Raw Normal View History

/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#include <aws/sagemaker/model/AwsManagedHumanLoopRequestSource.h>
#include <aws/core/utils/HashingUtils.h>
#include <aws/core/Globals.h>
#include <aws/core/utils/EnumParseOverflowContainer.h>
using namespace Aws::Utils;
namespace Aws
{
namespace SageMaker
{
namespace Model
{
namespace AwsManagedHumanLoopRequestSourceMapper
{
static const int AWS_Rekognition_DetectModerationLabels_Image_V3_HASH = HashingUtils::HashString("AWS/Rekognition/DetectModerationLabels/Image/V3");
static const int AWS_Textract_AnalyzeDocument_Forms_V1_HASH = HashingUtils::HashString("AWS/Textract/AnalyzeDocument/Forms/V1");
AwsManagedHumanLoopRequestSource GetAwsManagedHumanLoopRequestSourceForName(const Aws::String& name)
{
int hashCode = HashingUtils::HashString(name.c_str());
if (hashCode == AWS_Rekognition_DetectModerationLabels_Image_V3_HASH)
{
return AwsManagedHumanLoopRequestSource::AWS_Rekognition_DetectModerationLabels_Image_V3;
}
else if (hashCode == AWS_Textract_AnalyzeDocument_Forms_V1_HASH)
{
return AwsManagedHumanLoopRequestSource::AWS_Textract_AnalyzeDocument_Forms_V1;
}
EnumParseOverflowContainer* overflowContainer = Aws::GetEnumOverflowContainer();
if(overflowContainer)
{
overflowContainer->StoreOverflow(hashCode, name);
return static_cast<AwsManagedHumanLoopRequestSource>(hashCode);
}
return AwsManagedHumanLoopRequestSource::NOT_SET;
}
Aws::String GetNameForAwsManagedHumanLoopRequestSource(AwsManagedHumanLoopRequestSource enumValue)
{
switch(enumValue)
{
case AwsManagedHumanLoopRequestSource::AWS_Rekognition_DetectModerationLabels_Image_V3:
return "AWS/Rekognition/DetectModerationLabels/Image/V3";
case AwsManagedHumanLoopRequestSource::AWS_Textract_AnalyzeDocument_Forms_V1:
return "AWS/Textract/AnalyzeDocument/Forms/V1";
default:
EnumParseOverflowContainer* overflowContainer = Aws::GetEnumOverflowContainer();
if(overflowContainer)
{
return overflowContainer->RetrieveOverflow(static_cast<int>(enumValue));
}
return {};
}
}
} // namespace AwsManagedHumanLoopRequestSourceMapper
} // namespace Model
} // namespace SageMaker
} // namespace Aws