com.amazonaws.services.databasemigrationservice.model.transform.RecommendationMarshaller Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of aws-java-sdk-dms Show documentation
Show all versions of aws-java-sdk-dms Show documentation
The AWS Java SDK for AWS Database Migration Service module holds the client classes that are used for communicating with AWS Database Migration Service.
The newest version!
/*
* Copyright 2019-2024 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.
*/
package com.amazonaws.services.databasemigrationservice.model.transform;
import javax.annotation.Generated;
import com.amazonaws.SdkClientException;
import com.amazonaws.services.databasemigrationservice.model.*;
import com.amazonaws.protocol.*;
import com.amazonaws.annotation.SdkInternalApi;
/**
* RecommendationMarshaller
*/
@Generated("com.amazonaws:aws-java-sdk-code-generator")
@SdkInternalApi
public class RecommendationMarshaller {
private static final MarshallingInfo DATABASEID_BINDING = MarshallingInfo.builder(MarshallingType.STRING)
.marshallLocation(MarshallLocation.PAYLOAD).marshallLocationName("DatabaseId").build();
private static final MarshallingInfo ENGINENAME_BINDING = MarshallingInfo.builder(MarshallingType.STRING)
.marshallLocation(MarshallLocation.PAYLOAD).marshallLocationName("EngineName").build();
private static final MarshallingInfo CREATEDDATE_BINDING = MarshallingInfo.builder(MarshallingType.STRING)
.marshallLocation(MarshallLocation.PAYLOAD).marshallLocationName("CreatedDate").build();
private static final MarshallingInfo STATUS_BINDING = MarshallingInfo.builder(MarshallingType.STRING).marshallLocation(MarshallLocation.PAYLOAD)
.marshallLocationName("Status").build();
private static final MarshallingInfo PREFERRED_BINDING = MarshallingInfo.builder(MarshallingType.BOOLEAN)
.marshallLocation(MarshallLocation.PAYLOAD).marshallLocationName("Preferred").build();
private static final MarshallingInfo SETTINGS_BINDING = MarshallingInfo.builder(MarshallingType.STRUCTURED)
.marshallLocation(MarshallLocation.PAYLOAD).marshallLocationName("Settings").build();
private static final MarshallingInfo DATA_BINDING = MarshallingInfo.builder(MarshallingType.STRUCTURED)
.marshallLocation(MarshallLocation.PAYLOAD).marshallLocationName("Data").build();
private static final RecommendationMarshaller instance = new RecommendationMarshaller();
public static RecommendationMarshaller getInstance() {
return instance;
}
/**
* Marshall the given parameter object.
*/
public void marshall(Recommendation recommendation, ProtocolMarshaller protocolMarshaller) {
if (recommendation == null) {
throw new SdkClientException("Invalid argument passed to marshall(...)");
}
try {
protocolMarshaller.marshall(recommendation.getDatabaseId(), DATABASEID_BINDING);
protocolMarshaller.marshall(recommendation.getEngineName(), ENGINENAME_BINDING);
protocolMarshaller.marshall(recommendation.getCreatedDate(), CREATEDDATE_BINDING);
protocolMarshaller.marshall(recommendation.getStatus(), STATUS_BINDING);
protocolMarshaller.marshall(recommendation.getPreferred(), PREFERRED_BINDING);
protocolMarshaller.marshall(recommendation.getSettings(), SETTINGS_BINDING);
protocolMarshaller.marshall(recommendation.getData(), DATA_BINDING);
} catch (Exception e) {
throw new SdkClientException("Unable to marshall request to JSON: " + e.getMessage(), e);
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy