55 lines
1.3 KiB
C++
55 lines
1.3 KiB
C++
/**
|
|
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
* SPDX-License-Identifier: Apache-2.0.
|
|
*/
|
|
|
|
#include <aws/workdocs/model/UpdateDocumentVersionRequest.h>
|
|
#include <aws/core/utils/json/JsonSerializer.h>
|
|
#include <aws/core/utils/memory/stl/AWSStringStream.h>
|
|
|
|
#include <utility>
|
|
|
|
using namespace Aws::WorkDocs::Model;
|
|
using namespace Aws::Utils::Json;
|
|
using namespace Aws::Utils;
|
|
|
|
UpdateDocumentVersionRequest::UpdateDocumentVersionRequest() :
|
|
m_authenticationTokenHasBeenSet(false),
|
|
m_documentIdHasBeenSet(false),
|
|
m_versionIdHasBeenSet(false),
|
|
m_versionStatus(DocumentVersionStatus::NOT_SET),
|
|
m_versionStatusHasBeenSet(false)
|
|
{
|
|
}
|
|
|
|
Aws::String UpdateDocumentVersionRequest::SerializePayload() const
|
|
{
|
|
JsonValue payload;
|
|
|
|
if(m_versionStatusHasBeenSet)
|
|
{
|
|
payload.WithString("VersionStatus", DocumentVersionStatusMapper::GetNameForDocumentVersionStatus(m_versionStatus));
|
|
}
|
|
|
|
return payload.View().WriteReadable();
|
|
}
|
|
|
|
Aws::Http::HeaderValueCollection UpdateDocumentVersionRequest::GetRequestSpecificHeaders() const
|
|
{
|
|
Aws::Http::HeaderValueCollection headers;
|
|
Aws::StringStream ss;
|
|
if(m_authenticationTokenHasBeenSet)
|
|
{
|
|
ss << m_authenticationToken;
|
|
headers.emplace("authentication", ss.str());
|
|
ss.str("");
|
|
}
|
|
|
|
return headers;
|
|
|
|
}
|
|
|
|
|
|
|
|
|