1 /* 2 * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. 3 * 4 * Licensed under the Apache License, Version 2.0 (the "License"). 5 * You may not use this file except in compliance with the License. 6 * A copy of the License is located at 7 * 8 * http://aws.amazon.com/apache2.0 9 * 10 * or in the "license" file accompanying this file. This file is distributed 11 * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either 12 * express or implied. See the License for the specific language governing 13 * permissions and limitations under the License. 14 */ 15 16 package software.amazon.awssdk.codegen.model.rules.endpoints; 17 18 import com.fasterxml.jackson.core.TreeNode; 19 import java.util.List; 20 import java.util.Map; 21 import software.amazon.awssdk.utils.ToString; 22 23 public class ExpectModel { 24 private String error; 25 private Endpoint endpoint; 26 getError()27 public String getError() { 28 return error; 29 } 30 setError(String error)31 public void setError(String error) { 32 this.error = error; 33 } 34 getEndpoint()35 public Endpoint getEndpoint() { 36 return endpoint; 37 } 38 setEndpoint(Endpoint endpoint)39 public void setEndpoint(Endpoint endpoint) { 40 this.endpoint = endpoint; 41 } 42 43 @Override toString()44 public String toString() { 45 return ToString.builder("ExpectModel") 46 .add("error", error) 47 .add("endpoint", endpoint) 48 .build(); 49 } 50 51 public static class Endpoint { 52 private String url; 53 private Map<String, List<String>> headers; 54 private Map<String, TreeNode> properties; 55 getUrl()56 public String getUrl() { 57 return url; 58 } 59 setUrl(String url)60 public void setUrl(String url) { 61 this.url = url; 62 } 63 getHeaders()64 public Map<String, List<String>> getHeaders() { 65 return headers; 66 } 67 setHeaders(Map<String, List<String>> headers)68 public void setHeaders(Map<String, List<String>> headers) { 69 this.headers = headers; 70 } 71 getProperties()72 public Map<String, TreeNode> getProperties() { 73 return properties; 74 } 75 setProperties(Map<String, TreeNode> properties)76 public void setProperties(Map<String, TreeNode> properties) { 77 this.properties = properties; 78 } 79 80 @Override toString()81 public String toString() { 82 return ToString.builder("Endpoint") 83 .add("url", url) 84 .add("headers", headers) 85 .add("properties", properties) 86 .build(); 87 } 88 } 89 } 90