/* * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * * Licensed under the Apache License, Version 2.0 (the "License"). * You may not use this file except in compliance with the License. * A copy of the License is located at * * http://aws.amazon.com/apache2.0 * * or in the "license" file accompanying this file. This file is distributed * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either * express or implied. See the License for the specific language governing * permissions and limitations under the License. */ /* * Do not modify this file. This file is generated from the glue-2017-03-31.normal.json service model. */ using System; using System.Collections.Generic; using System.Globalization; using System.IO; using System.Text; using System.Xml.Serialization; using Amazon.Glue.Model; using Amazon.Runtime; using Amazon.Runtime.Internal; using Amazon.Runtime.Internal.Transform; using Amazon.Runtime.Internal.Util; using ThirdParty.Json.LitJson; namespace Amazon.Glue.Model.Internal.MarshallTransformations { /// /// JobUpdate Marshaller /// public class JobUpdateMarshaller : IRequestMarshaller { /// /// Unmarshaller the response from the service to the response class. /// /// /// /// public void Marshall(JobUpdate requestObject, JsonMarshallerContext context) { if(requestObject.IsSetAllocatedCapacity()) { context.Writer.WritePropertyName("AllocatedCapacity"); context.Writer.Write(requestObject.AllocatedCapacity); } if(requestObject.IsSetCodeGenConfigurationNodes()) { context.Writer.WritePropertyName("CodeGenConfigurationNodes"); context.Writer.WriteObjectStart(); foreach (var requestObjectCodeGenConfigurationNodesKvp in requestObject.CodeGenConfigurationNodes) { context.Writer.WritePropertyName(requestObjectCodeGenConfigurationNodesKvp.Key); var requestObjectCodeGenConfigurationNodesValue = requestObjectCodeGenConfigurationNodesKvp.Value; context.Writer.WriteObjectStart(); var marshaller = CodeGenConfigurationNodeMarshaller.Instance; marshaller.Marshall(requestObjectCodeGenConfigurationNodesValue, context); context.Writer.WriteObjectEnd(); } context.Writer.WriteObjectEnd(); } if(requestObject.IsSetCommand()) { context.Writer.WritePropertyName("Command"); context.Writer.WriteObjectStart(); var marshaller = JobCommandMarshaller.Instance; marshaller.Marshall(requestObject.Command, context); context.Writer.WriteObjectEnd(); } if(requestObject.IsSetConnections()) { context.Writer.WritePropertyName("Connections"); context.Writer.WriteObjectStart(); var marshaller = ConnectionsListMarshaller.Instance; marshaller.Marshall(requestObject.Connections, context); context.Writer.WriteObjectEnd(); } if(requestObject.IsSetDefaultArguments()) { context.Writer.WritePropertyName("DefaultArguments"); context.Writer.WriteObjectStart(); foreach (var requestObjectDefaultArgumentsKvp in requestObject.DefaultArguments) { context.Writer.WritePropertyName(requestObjectDefaultArgumentsKvp.Key); var requestObjectDefaultArgumentsValue = requestObjectDefaultArgumentsKvp.Value; context.Writer.Write(requestObjectDefaultArgumentsValue); } context.Writer.WriteObjectEnd(); } if(requestObject.IsSetDescription()) { context.Writer.WritePropertyName("Description"); context.Writer.Write(requestObject.Description); } if(requestObject.IsSetExecutionClass()) { context.Writer.WritePropertyName("ExecutionClass"); context.Writer.Write(requestObject.ExecutionClass); } if(requestObject.IsSetExecutionProperty()) { context.Writer.WritePropertyName("ExecutionProperty"); context.Writer.WriteObjectStart(); var marshaller = ExecutionPropertyMarshaller.Instance; marshaller.Marshall(requestObject.ExecutionProperty, context); context.Writer.WriteObjectEnd(); } if(requestObject.IsSetGlueVersion()) { context.Writer.WritePropertyName("GlueVersion"); context.Writer.Write(requestObject.GlueVersion); } if(requestObject.IsSetLogUri()) { context.Writer.WritePropertyName("LogUri"); context.Writer.Write(requestObject.LogUri); } if(requestObject.IsSetMaxCapacity()) { context.Writer.WritePropertyName("MaxCapacity"); context.Writer.Write(requestObject.MaxCapacity); } if(requestObject.IsSetMaxRetries()) { context.Writer.WritePropertyName("MaxRetries"); context.Writer.Write(requestObject.MaxRetries); } if(requestObject.IsSetNonOverridableArguments()) { context.Writer.WritePropertyName("NonOverridableArguments"); context.Writer.WriteObjectStart(); foreach (var requestObjectNonOverridableArgumentsKvp in requestObject.NonOverridableArguments) { context.Writer.WritePropertyName(requestObjectNonOverridableArgumentsKvp.Key); var requestObjectNonOverridableArgumentsValue = requestObjectNonOverridableArgumentsKvp.Value; context.Writer.Write(requestObjectNonOverridableArgumentsValue); } context.Writer.WriteObjectEnd(); } if(requestObject.IsSetNotificationProperty()) { context.Writer.WritePropertyName("NotificationProperty"); context.Writer.WriteObjectStart(); var marshaller = NotificationPropertyMarshaller.Instance; marshaller.Marshall(requestObject.NotificationProperty, context); context.Writer.WriteObjectEnd(); } if(requestObject.IsSetNumberOfWorkers()) { context.Writer.WritePropertyName("NumberOfWorkers"); context.Writer.Write(requestObject.NumberOfWorkers); } if(requestObject.IsSetRole()) { context.Writer.WritePropertyName("Role"); context.Writer.Write(requestObject.Role); } if(requestObject.IsSetSecurityConfiguration()) { context.Writer.WritePropertyName("SecurityConfiguration"); context.Writer.Write(requestObject.SecurityConfiguration); } if(requestObject.IsSetSourceControlDetails()) { context.Writer.WritePropertyName("SourceControlDetails"); context.Writer.WriteObjectStart(); var marshaller = SourceControlDetailsMarshaller.Instance; marshaller.Marshall(requestObject.SourceControlDetails, context); context.Writer.WriteObjectEnd(); } if(requestObject.IsSetTimeout()) { context.Writer.WritePropertyName("Timeout"); context.Writer.Write(requestObject.Timeout); } if(requestObject.IsSetWorkerType()) { context.Writer.WritePropertyName("WorkerType"); context.Writer.Write(requestObject.WorkerType); } } /// /// Singleton Marshaller. /// public readonly static JobUpdateMarshaller Instance = new JobUpdateMarshaller(); } }