/** * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0. */ #include #include #include using namespace Aws::Utils::Json; using namespace Aws::Utils; namespace Aws { namespace CodePipeline { namespace Model { Job::Job() : m_idHasBeenSet(false), m_dataHasBeenSet(false), m_nonceHasBeenSet(false), m_accountIdHasBeenSet(false) { } Job::Job(JsonView jsonValue) : m_idHasBeenSet(false), m_dataHasBeenSet(false), m_nonceHasBeenSet(false), m_accountIdHasBeenSet(false) { *this = jsonValue; } Job& Job::operator =(JsonView jsonValue) { if(jsonValue.ValueExists("id")) { m_id = jsonValue.GetString("id"); m_idHasBeenSet = true; } if(jsonValue.ValueExists("data")) { m_data = jsonValue.GetObject("data"); m_dataHasBeenSet = true; } if(jsonValue.ValueExists("nonce")) { m_nonce = jsonValue.GetString("nonce"); m_nonceHasBeenSet = true; } if(jsonValue.ValueExists("accountId")) { m_accountId = jsonValue.GetString("accountId"); m_accountIdHasBeenSet = true; } return *this; } JsonValue Job::Jsonize() const { JsonValue payload; if(m_idHasBeenSet) { payload.WithString("id", m_id); } if(m_dataHasBeenSet) { payload.WithObject("data", m_data.Jsonize()); } if(m_nonceHasBeenSet) { payload.WithString("nonce", m_nonce); } if(m_accountIdHasBeenSet) { payload.WithString("accountId", m_accountId); } return payload; } } // namespace Model } // namespace CodePipeline } // namespace Aws