public ThrottleSettings unmarshall(JsonUnmarshallerContext context) throws Exception { ThrottleSettings throttleSettings = new ThrottleSettings(); int originalDepth = context.getCurrentDepth(); String currentParentElement = context.getCurrentParentElement(); int targetDepth = originalDepth + 1; JsonToken token = context.getCurrentToken(); if (token == null) token = context.nextToken(); if (token == VALUE_NULL) return null; while (true) { if (token == null) break; if (token == FIELD_NAME || token == START_OBJECT) { if (context.testExpression("burstLimit", targetDepth)) { context.nextToken(); throttleSettings.setBurstLimit( context.getUnmarshaller(Integer.class).unmarshall(context)); } if (context.testExpression("rateLimit", targetDepth)) { context.nextToken(); throttleSettings.setRateLimit(context.getUnmarshaller(Double.class).unmarshall(context)); } } else if (token == END_ARRAY || token == END_OBJECT) { if (context.getLastParsedParentElement() == null || context.getLastParsedParentElement().equals(currentParentElement)) { if (context.getCurrentDepth() <= originalDepth) break; } } token = context.nextToken(); } return throttleSettings; }
public CreateRestApiResult unmarshall(JsonUnmarshallerContext context) throws Exception { CreateRestApiResult createRestApiResult = new CreateRestApiResult(); int originalDepth = context.getCurrentDepth(); String currentParentElement = context.getCurrentParentElement(); int targetDepth = originalDepth + 1; JsonToken token = context.getCurrentToken(); if (token == null) token = context.nextToken(); if (token == VALUE_NULL) return null; while (true) { if (token == null) break; if (token == FIELD_NAME || token == START_OBJECT) { if (context.testExpression("id", targetDepth)) { context.nextToken(); createRestApiResult.setId(context.getUnmarshaller(String.class).unmarshall(context)); } if (context.testExpression("name", targetDepth)) { context.nextToken(); createRestApiResult.setName(context.getUnmarshaller(String.class).unmarshall(context)); } if (context.testExpression("description", targetDepth)) { context.nextToken(); createRestApiResult.setDescription( context.getUnmarshaller(String.class).unmarshall(context)); } if (context.testExpression("createdDate", targetDepth)) { context.nextToken(); createRestApiResult.setCreatedDate( context.getUnmarshaller(java.util.Date.class).unmarshall(context)); } if (context.testExpression("version", targetDepth)) { context.nextToken(); createRestApiResult.setVersion(context.getUnmarshaller(String.class).unmarshall(context)); } if (context.testExpression("warnings", targetDepth)) { context.nextToken(); createRestApiResult.setWarnings( new ListUnmarshaller<String>(context.getUnmarshaller(String.class)) .unmarshall(context)); } if (context.testExpression("binaryMediaTypes", targetDepth)) { context.nextToken(); createRestApiResult.setBinaryMediaTypes( new ListUnmarshaller<String>(context.getUnmarshaller(String.class)) .unmarshall(context)); } } else if (token == END_ARRAY || token == END_OBJECT) { if (context.getLastParsedParentElement() == null || context.getLastParsedParentElement().equals(currentParentElement)) { if (context.getCurrentDepth() <= originalDepth) break; } } token = context.nextToken(); } return createRestApiResult; }
public DocumentationVersion unmarshall(JsonUnmarshallerContext context) throws Exception { DocumentationVersion documentationVersion = new DocumentationVersion(); int originalDepth = context.getCurrentDepth(); String currentParentElement = context.getCurrentParentElement(); int targetDepth = originalDepth + 1; JsonToken token = context.getCurrentToken(); if (token == null) token = context.nextToken(); if (token == VALUE_NULL) return null; while (true) { if (token == null) break; if (token == FIELD_NAME || token == START_OBJECT) { if (context.testExpression("version", targetDepth)) { context.nextToken(); documentationVersion.setVersion( context.getUnmarshaller(String.class).unmarshall(context)); } if (context.testExpression("createdDate", targetDepth)) { context.nextToken(); documentationVersion.setCreatedDate( context.getUnmarshaller(java.util.Date.class).unmarshall(context)); } if (context.testExpression("description", targetDepth)) { context.nextToken(); documentationVersion.setDescription( context.getUnmarshaller(String.class).unmarshall(context)); } } else if (token == END_ARRAY || token == END_OBJECT) { if (context.getLastParsedParentElement() == null || context.getLastParsedParentElement().equals(currentParentElement)) { if (context.getCurrentDepth() <= originalDepth) break; } } token = context.nextToken(); } return documentationVersion; }
public MethodSnapshot unmarshall(JsonUnmarshallerContext context) throws Exception { MethodSnapshot methodSnapshot = new MethodSnapshot(); int originalDepth = context.getCurrentDepth(); String currentParentElement = context.getCurrentParentElement(); int targetDepth = originalDepth + 1; JsonToken token = context.getCurrentToken(); if (token == null) token = context.nextToken(); if (token == VALUE_NULL) return null; while (true) { if (token == null) break; if (token == FIELD_NAME || token == START_OBJECT) { if (context.testExpression("authorizationType", targetDepth)) { context.nextToken(); methodSnapshot.setAuthorizationType( context.getUnmarshaller(String.class).unmarshall(context)); } if (context.testExpression("apiKeyRequired", targetDepth)) { context.nextToken(); methodSnapshot.setApiKeyRequired( context.getUnmarshaller(Boolean.class).unmarshall(context)); } } else if (token == END_ARRAY || token == END_OBJECT) { if (context.getLastParsedParentElement() == null || context.getLastParsedParentElement().equals(currentParentElement)) { if (context.getCurrentDepth() <= originalDepth) break; } } token = context.nextToken(); } return methodSnapshot; }
public GetAccountResult unmarshall(JsonUnmarshallerContext context) throws Exception { GetAccountResult getAccountResult = new GetAccountResult(); int originalDepth = context.getCurrentDepth(); String currentParentElement = context.getCurrentParentElement(); int targetDepth = originalDepth + 1; JsonToken token = context.getCurrentToken(); if (token == null) token = context.nextToken(); if (token == VALUE_NULL) return null; while (true) { if (token == null) break; if (token == FIELD_NAME || token == START_OBJECT) { if (context.testExpression("cloudwatchRoleArn", targetDepth)) { context.nextToken(); getAccountResult.setCloudwatchRoleArn( StringJsonUnmarshaller.getInstance().unmarshall(context)); } if (context.testExpression("throttleSettings", targetDepth)) { context.nextToken(); getAccountResult.setThrottleSettings( ThrottleSettingsJsonUnmarshaller.getInstance().unmarshall(context)); } } else if (token == END_ARRAY || token == END_OBJECT) { if (context.getLastParsedParentElement() == null || context.getLastParsedParentElement().equals(currentParentElement)) { if (context.getCurrentDepth() <= originalDepth) break; } } token = context.nextToken(); } return getAccountResult; }
public UpdateDeploymentResult unmarshall(JsonUnmarshallerContext context) throws Exception { UpdateDeploymentResult updateDeploymentResult = new UpdateDeploymentResult(); int originalDepth = context.getCurrentDepth(); String currentParentElement = context.getCurrentParentElement(); int targetDepth = originalDepth + 1; JsonToken token = context.getCurrentToken(); if (token == null) token = context.nextToken(); if (token == VALUE_NULL) return null; while (true) { if (token == null) break; if (token == FIELD_NAME || token == START_OBJECT) { if (context.testExpression("id", targetDepth)) { context.nextToken(); updateDeploymentResult.setId(StringJsonUnmarshaller.getInstance().unmarshall(context)); } if (context.testExpression("description", targetDepth)) { context.nextToken(); updateDeploymentResult.setDescription( StringJsonUnmarshaller.getInstance().unmarshall(context)); } if (context.testExpression("createdDate", targetDepth)) { context.nextToken(); updateDeploymentResult.setCreatedDate( DateJsonUnmarshaller.getInstance().unmarshall(context)); } if (context.testExpression("apiSummary", targetDepth)) { context.nextToken(); updateDeploymentResult.setApiSummary( new MapUnmarshaller<String, java.util.Map<String, MethodSnapshot>>( StringJsonUnmarshaller.getInstance(), new MapUnmarshaller<String, MethodSnapshot>( StringJsonUnmarshaller.getInstance(), MethodSnapshotJsonUnmarshaller.getInstance())) .unmarshall(context)); } } else if (token == END_ARRAY || token == END_OBJECT) { if (context.getLastParsedParentElement() == null || context.getLastParsedParentElement().equals(currentParentElement)) { if (context.getCurrentDepth() <= originalDepth) break; } } token = context.nextToken(); } return updateDeploymentResult; }
public GetDomainNameResult unmarshall(JsonUnmarshallerContext context) throws Exception { GetDomainNameResult getDomainNameResult = new GetDomainNameResult(); int originalDepth = context.getCurrentDepth(); String currentParentElement = context.getCurrentParentElement(); int targetDepth = originalDepth + 1; JsonToken token = context.getCurrentToken(); if (token == null) token = context.nextToken(); if (token == VALUE_NULL) return null; while (true) { if (token == null) break; if (token == FIELD_NAME || token == START_OBJECT) { if (context.testExpression("domainName", targetDepth)) { context.nextToken(); getDomainNameResult.setDomainName( context.getUnmarshaller(String.class).unmarshall(context)); } if (context.testExpression("certificateName", targetDepth)) { context.nextToken(); getDomainNameResult.setCertificateName( context.getUnmarshaller(String.class).unmarshall(context)); } if (context.testExpression("certificateUploadDate", targetDepth)) { context.nextToken(); getDomainNameResult.setCertificateUploadDate( context.getUnmarshaller(java.util.Date.class).unmarshall(context)); } if (context.testExpression("distributionDomainName", targetDepth)) { context.nextToken(); getDomainNameResult.setDistributionDomainName( context.getUnmarshaller(String.class).unmarshall(context)); } } else if (token == END_ARRAY || token == END_OBJECT) { if (context.getLastParsedParentElement() == null || context.getLastParsedParentElement().equals(currentParentElement)) { if (context.getCurrentDepth() <= originalDepth) break; } } token = context.nextToken(); } return getDomainNameResult; }
public MethodSetting unmarshall(JsonUnmarshallerContext context) throws Exception { MethodSetting methodSetting = new MethodSetting(); int originalDepth = context.getCurrentDepth(); String currentParentElement = context.getCurrentParentElement(); int targetDepth = originalDepth + 1; JsonToken token = context.getCurrentToken(); if (token == null) token = context.nextToken(); if (token == VALUE_NULL) return null; while (true) { if (token == null) break; if (token == FIELD_NAME || token == START_OBJECT) { if (context.testExpression("metricsEnabled", targetDepth)) { context.nextToken(); methodSetting.setMetricsEnabled( BooleanJsonUnmarshaller.getInstance().unmarshall(context)); } if (context.testExpression("loggingLevel", targetDepth)) { context.nextToken(); methodSetting.setLoggingLevel(StringJsonUnmarshaller.getInstance().unmarshall(context)); } if (context.testExpression("dataTraceEnabled", targetDepth)) { context.nextToken(); methodSetting.setDataTraceEnabled( BooleanJsonUnmarshaller.getInstance().unmarshall(context)); } if (context.testExpression("throttlingBurstLimit", targetDepth)) { context.nextToken(); methodSetting.setThrottlingBurstLimit( IntegerJsonUnmarshaller.getInstance().unmarshall(context)); } if (context.testExpression("throttlingRateLimit", targetDepth)) { context.nextToken(); methodSetting.setThrottlingRateLimit( DoubleJsonUnmarshaller.getInstance().unmarshall(context)); } if (context.testExpression("cachingEnabled", targetDepth)) { context.nextToken(); methodSetting.setCachingEnabled( BooleanJsonUnmarshaller.getInstance().unmarshall(context)); } if (context.testExpression("cacheTtlInSeconds", targetDepth)) { context.nextToken(); methodSetting.setCacheTtlInSeconds( IntegerJsonUnmarshaller.getInstance().unmarshall(context)); } if (context.testExpression("cacheDataEncrypted", targetDepth)) { context.nextToken(); methodSetting.setCacheDataEncrypted( BooleanJsonUnmarshaller.getInstance().unmarshall(context)); } } else if (token == END_ARRAY || token == END_OBJECT) { if (context.getLastParsedParentElement() == null || context.getLastParsedParentElement().equals(currentParentElement)) { if (context.getCurrentDepth() <= originalDepth) break; } } token = context.nextToken(); } return methodSetting; }
public Method unmarshall(JsonUnmarshallerContext context) throws Exception { Method method = new Method(); int originalDepth = context.getCurrentDepth(); String currentParentElement = context.getCurrentParentElement(); int targetDepth = originalDepth + 1; JsonToken token = context.getCurrentToken(); if (token == null) token = context.nextToken(); if (token == VALUE_NULL) return null; while (true) { if (token == null) break; if (token == FIELD_NAME || token == START_OBJECT) { if (context.testExpression("httpMethod", targetDepth)) { context.nextToken(); method.setHttpMethod(StringJsonUnmarshaller.getInstance().unmarshall(context)); } if (context.testExpression("authorizationType", targetDepth)) { context.nextToken(); method.setAuthorizationType(StringJsonUnmarshaller.getInstance().unmarshall(context)); } if (context.testExpression("apiKeyRequired", targetDepth)) { context.nextToken(); method.setApiKeyRequired(BooleanJsonUnmarshaller.getInstance().unmarshall(context)); } if (context.testExpression("requestParameters", targetDepth)) { context.nextToken(); method.setRequestParameters( new MapUnmarshaller<String, Boolean>( StringJsonUnmarshaller.getInstance(), BooleanJsonUnmarshaller.getInstance()) .unmarshall(context)); } if (context.testExpression("requestModels", targetDepth)) { context.nextToken(); method.setRequestModels( new MapUnmarshaller<String, String>( StringJsonUnmarshaller.getInstance(), StringJsonUnmarshaller.getInstance()) .unmarshall(context)); } if (context.testExpression("methodResponses", targetDepth)) { context.nextToken(); method.setMethodResponses( new MapUnmarshaller<String, MethodResponse>( StringJsonUnmarshaller.getInstance(), MethodResponseJsonUnmarshaller.getInstance()) .unmarshall(context)); } if (context.testExpression("methodIntegration", targetDepth)) { context.nextToken(); method.setMethodIntegration( IntegrationJsonUnmarshaller.getInstance().unmarshall(context)); } } else if (token == END_ARRAY || token == END_OBJECT) { if (context.getLastParsedParentElement() == null || context.getLastParsedParentElement().equals(currentParentElement)) { if (context.getCurrentDepth() <= originalDepth) break; } } token = context.nextToken(); } return method; }